summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMarc Kleine-Budde <mkl@pengutronix.de>2021-03-04 15:23:19 +0100
committerMarc Kleine-Budde <mkl@pengutronix.de>2021-03-30 11:14:52 +0200
commitdd477500c70b9e721bcf612bce1ddf5752a2de2b (patch)
treee7ae8856f642b71781ebf11ad43162e76b8dd777
parent995380f3fbfbce3d700293f375aae0a1ddad3266 (diff)
can: c_can: fix remaining checkpatch warnings
This patch fixes the remaining checkpatch warnings in the driver. Link: https://lore.kernel.org/r/20210304154240.2747987-7-mkl@pengutronix.de Signed-off-by: Marc Kleine-Budde <mkl@pengutronix.de>
-rw-r--r--drivers/net/can/c_can/c_can.c3
-rw-r--r--drivers/net/can/c_can/c_can_pci.c2
2 files changed, 3 insertions, 2 deletions
diff --git a/drivers/net/can/c_can/c_can.c b/drivers/net/can/c_can/c_can.c
index 7d63b227275d..eeef1f7b53c7 100644
--- a/drivers/net/can/c_can/c_can.c
+++ b/drivers/net/can/c_can/c_can.c
@@ -753,7 +753,8 @@ static u32 c_can_adjust_pending(u32 pend)
/* Find the first set bit after the gap. We walk backwards
* from the last set bit.
*/
- for (lasts--; pend & (1 << (lasts - 1)); lasts--);
+ for (lasts--; pend & (1 << (lasts - 1)); lasts--)
+ ;
return pend & ~((1 << lasts) - 1);
}
diff --git a/drivers/net/can/c_can/c_can_pci.c b/drivers/net/can/c_can/c_can_pci.c
index 8a3628f76594..9a8d5e8eb645 100644
--- a/drivers/net/can/c_can/c_can_pci.c
+++ b/drivers/net/can/c_can/c_can_pci.c
@@ -267,7 +267,7 @@ static const struct c_can_pci_data c_can_pch = {
#define C_CAN_ID(_vend, _dev, _driverdata) { \
PCI_DEVICE(_vend, _dev), \
- .driver_data = (unsigned long)&_driverdata, \
+ .driver_data = (unsigned long)&(_driverdata), \
}
static const struct pci_device_id c_can_pci_tbl[] = {