[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-Id: <20220502150133.6052-1-srini.raju@purelifi.com>
Date: Mon, 2 May 2022 16:01:32 +0100
From: Srinivasan Raju <srini.raju@...elifi.com>
To: unlisted-recipients:; (no To-header on input)
Cc: Srinivasan Raju <srini.raju@...elifi.com>,
kernel test robot <lkp@...el.com>,
Kalle Valo <kvalo@...nel.org>,
"David S. Miller" <davem@...emloft.net>,
Jakub Kicinski <kuba@...nel.org>,
Paolo Abeni <pabeni@...hat.com>,
linux-wireless@...r.kernel.org (open list:PURELIFI PLFXLC DRIVER),
netdev@...r.kernel.org (open list:NETWORKING DRIVERS),
linux-kernel@...r.kernel.org (open list)
Subject: [PATCH] [v4] plfxlc: fix le16_to_cpu warning for beacon_interval
Fix the following sparse warnings:
drivers/net/wireless/purelifi/plfxlc/chip.c:36:31: sparse: expected unsigned short [usertype] beacon_interval
drivers/net/wireless/purelifi/plfxlc/chip.c:36:31: sparse: got restricted __le16 [usertype]
Reported-by: kernel test robot <lkp@...el.com>
Signed-off-by: Srinivasan Raju <srini.raju@...elifi.com>
---
drivers/net/wireless/purelifi/plfxlc/chip.c | 5 ++---
1 file changed, 2 insertions(+), 3 deletions(-)
diff --git a/drivers/net/wireless/purelifi/plfxlc/chip.c b/drivers/net/wireless/purelifi/plfxlc/chip.c
index a5ec10b66ed5..f4ef9ff97146 100644
--- a/drivers/net/wireless/purelifi/plfxlc/chip.c
+++ b/drivers/net/wireless/purelifi/plfxlc/chip.c
@@ -29,11 +29,10 @@ int plfxlc_set_beacon_interval(struct plfxlc_chip *chip, u16 interval,
u8 dtim_period, int type)
{
if (!interval ||
- (chip->beacon_set &&
- le16_to_cpu(chip->beacon_interval) == interval))
+ (chip->beacon_set && chip->beacon_interval == interval))
return 0;
- chip->beacon_interval = cpu_to_le16(interval);
+ chip->beacon_interval = interval;
chip->beacon_set = true;
return plfxlc_usb_wreq(chip->usb.ez_usb,
&chip->beacon_interval,
--
2.25.1
Powered by blists - more mailing lists