net/mlx4_en: Doorbell is byteswapped in Little Endian archs
authorAmir Vadai <amirv@mellanox.com>
Mon, 22 Dec 2014 08:21:57 +0000 (10:21 +0200)
committerDavid S. Miller <davem@davemloft.net>
Mon, 22 Dec 2014 21:33:10 +0000 (16:33 -0500)
commit492f5add4be84652bbe13da8a250d60c6856a5c5
tree2be9bbac102868cb3d3bcac57bcc60ed222a4395
parentea3c9e13afe739f1ff31130cea57084cfe8c5dcd
net/mlx4_en: Doorbell is byteswapped in Little Endian archs

iowrite32() will byteswap it's argument on big endian archs.
iowrite32be() will byteswap on little endian archs.
Since we don't want to do this unnecessary byteswap on the fast path,
doorbell is stored in the NIC's native endianness. Using the right
iowrite() according to the arch endianness.

CC: Wei Yang <weiyang@linux.vnet.ibm.com>
CC: David Laight <david.laight@aculab.com>
Fixes: 6a4e812 ("net/mlx4_en: Avoid calling bswap in tx fast path")
Signed-off-by: Amir Vadai <amirv@mellanox.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/mellanox/mlx4/en_tx.c