diff options
author | Krzysztof Kozlowski <krzk@kernel.org> | 2020-01-04 17:31:43 +0300 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2020-01-07 00:30:03 +0300 |
commit | 00c0688cecadbf7ac2f5b4cdb36d912a2d3f0cca (patch) | |
tree | e80d05974f90dbb82042a1a86de8c33a85547552 /drivers/net/wan | |
parent | be7a7729207797476b6666f046d765bdf9630407 (diff) | |
download | linux-00c0688cecadbf7ac2f5b4cdb36d912a2d3f0cca.tar.xz |
net: wan: sdla: Fix cast from pointer to integer of different size
Since net_device.mem_start is unsigned long, it should not be cast to
int right before casting to pointer. This fixes warning (compile
testing on alpha architecture):
drivers/net/wan/sdla.c: In function ‘sdla_transmit’:
drivers/net/wan/sdla.c:711:13: warning:
cast to pointer from integer of different size [-Wint-to-pointer-cast]
Signed-off-by: Krzysztof Kozlowski <krzk@kernel.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/wan')
-rw-r--r-- | drivers/net/wan/sdla.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/net/wan/sdla.c b/drivers/net/wan/sdla.c index e2e679a01b65..77ccf3672ede 100644 --- a/drivers/net/wan/sdla.c +++ b/drivers/net/wan/sdla.c @@ -708,7 +708,7 @@ static netdev_tx_t sdla_transmit(struct sk_buff *skb, spin_lock_irqsave(&sdla_lock, flags); SDLA_WINDOW(dev, addr); - pbuf = (void *)(((int) dev->mem_start) + (addr & SDLA_ADDR_MASK)); + pbuf = (void *)(dev->mem_start + (addr & SDLA_ADDR_MASK)); __sdla_write(dev, pbuf->buf_addr, skb->data, skb->len); SDLA_WINDOW(dev, addr); pbuf->opp_flag = 1; |