Merge pull request #9616 from bergzand/pr/at86rf2xx/always_set_channel

at86rf2xx: Always set channel on device
This commit is contained in:
Peter Kietzmann 2018-07-31 18:33:44 +02:00 committed by GitHub
commit e897826cc7
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -140,11 +140,11 @@ uint8_t at86rf2xx_get_chan(const at86rf2xx_t *dev)
void at86rf2xx_set_chan(at86rf2xx_t *dev, uint8_t channel)
{
if ((channel > AT86RF2XX_MAX_CHANNEL) ||
if ((channel > AT86RF2XX_MAX_CHANNEL)
#if AT86RF2XX_MIN_CHANNEL /* is zero for sub-GHz */
(channel < AT86RF2XX_MIN_CHANNEL) ||
|| (channel < AT86RF2XX_MIN_CHANNEL)
#endif
(dev->netdev.chan == channel)) {
) {
return;
}