Skip to content

Commit 25cff25

Browse files
YueHaibinggregkh
authored andcommitted
net: xilinx_emaclite: Do not print real IOMEM pointer
commit d0d62ba upstream. Printing kernel pointers is discouraged because they might leak kernel memory layout. This fixes smatch warning: drivers/net/ethernet/xilinx/xilinx_emaclite.c:1191 xemaclite_of_probe() warn: argument 4 to %08lX specifier is cast from pointer Signed-off-by: YueHaibing <yuehaibing@huawei.com> Signed-off-by: David S. Miller <davem@davemloft.net> Signed-off-by: Pavel Machek (CIP) <pavel@denx.de> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
1 parent 6a002d4 commit 25cff25

1 file changed

Lines changed: 2 additions & 3 deletions

File tree

‎drivers/net/ethernet/xilinx/xilinx_emaclite.c‎

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1191,9 +1191,8 @@ static int xemaclite_of_probe(struct platform_device *ofdev)
11911191
}
11921192

11931193
dev_info(dev,
1194-
"Xilinx EmacLite at 0x%08X mapped to 0x%08X, irq=%d\n",
1195-
(unsigned int __force)ndev->mem_start,
1196-
(unsigned int __force)lp->base_addr, ndev->irq);
1194+
"Xilinx EmacLite at 0x%08X mapped to 0x%p, irq=%d\n",
1195+
(unsigned int __force)ndev->mem_start, lp->base_addr, ndev->irq);
11971196
return 0;
11981197

11991198
error:

0 commit comments

Comments
 (0)