aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAlexander Aring <alex.aring@gmail.com>2014-11-02 04:18:32 +0100
committerMarcel Holtmann <marcel@holtmann.org>2014-11-02 04:51:06 +0100
commitfe23bcd920015bfb655f4b3d129a9368ce8e660c (patch)
tree812839d4dfa8db7aa5655af202a0786e2c050819
parentBluetooth: Fix hci_sync missing wakeup interrupt (diff)
downloadlinux-dev-fe23bcd920015bfb655f4b3d129a9368ce8e660c.tar.xz
linux-dev-fe23bcd920015bfb655f4b3d129a9368ce8e660c.zip
at86rf230: fix page parameter constraints
Since commit e37d2ec82a222f1819e7793a27bc052999a379fb ("mac802154: ops: declare channel and page as u8") the page parameter can't be below zero. This patch fix a kbuild test robot warning. Furthermore this check should be removed and handled by netlink 802.15.4 interface. Signed-off-by: Alexander Aring <alex.aring@gmail.com> Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
-rw-r--r--drivers/net/ieee802154/at86rf230.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/net/ieee802154/at86rf230.c b/drivers/net/ieee802154/at86rf230.c
index 9ad2d432ef43..624080d97209 100644
--- a/drivers/net/ieee802154/at86rf230.c
+++ b/drivers/net/ieee802154/at86rf230.c
@@ -1047,7 +1047,7 @@ at86rf230_channel(struct ieee802154_hw *hw, u8 page, u8 channel)
struct at86rf230_local *lp = hw->priv;
int rc;
- if (page < 0 || page > 31 ||
+ if (page > 31 ||
!(lp->hw->phy->channels_supported[page] & BIT(channel))) {
WARN_ON(1);
return -EINVAL;