[PATCH 1/1] net: bna: use correct type specifier (2)

Subsystems: brocade bna 10 gigabit ethernet driver, networking drivers, the rest

STALE3689d

2 messages, 2 authors, 2016-08-01 · open the first message on its own page

[PATCH 1/1] net: bna: use correct type specifier (2)

From: Heinrich Schuchardt <hidden>
Date: 2016-07-31 09:01:37

add and val are read with
sscanf(kern_buf, "%x:%x", &addr, &val);
and used as arguments for bna_reg_offset_check and writel
so they have to be unsigned.

Signed-off-by: Heinrich Schuchardt <redacted>
---
 drivers/net/ethernet/brocade/bna/bnad_debugfs.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/drivers/net/ethernet/brocade/bna/bnad_debugfs.c b/drivers/net/ethernet/brocade/bna/bnad_debugfs.c
index cfcb00c..05c1c1d 100644
--- a/drivers/net/ethernet/brocade/bna/bnad_debugfs.c
+++ b/drivers/net/ethernet/brocade/bna/bnad_debugfs.c
@@ -373,7 +373,8 @@ bnad_debugfs_write_regwr(struct file *file, const char __user *buf,
 	struct bnad_debug_info *debug = file->private_data;
 	struct bnad *bnad = (struct bnad *)debug->i_private;
 	struct bfa_ioc *ioc = &bnad->bna.ioceth.ioc;
-	int addr, val, rc;
+	int rc;
+	u32 addr, val;
 	void __iomem *reg_addr;
 	unsigned long flags;
 	void *kern_buf;
-- 
2.8.1

Re: [PATCH 1/1] net: bna: use correct type specifier (2)

From: David Miller <davem@davemloft.net>
Date: 2016-08-01 20:45:40

From: Heinrich Schuchardt <redacted>
Date: Sun, 31 Jul 2016 11:01:20 +0200
add and val are read with
sscanf(kern_buf, "%x:%x", &addr, &val);
and used as arguments for bna_reg_offset_check and writel
so they have to be unsigned.

Signed-off-by: Heinrich Schuchardt <redacted>
Applied.
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help