]> git.baikalelectronics.ru Git - kernel.git/commit
net/mlx5: Avoid passing dma address 0 to firmware
authorNoa Osherovich <noaos@mellanox.com>
Tue, 25 Oct 2016 15:36:35 +0000 (18:36 +0300)
committerDavid S. Miller <davem@davemloft.net>
Sat, 29 Oct 2016 16:00:39 +0000 (12:00 -0400)
commit57bc82ad572c217baf78fe92de37169eb688b11f
tree2fbd8a81031683406fa5fbd8a50f310aea4be4fc
parent9f80fd994eab3c807301f08a952adf1a1861dc90
net/mlx5: Avoid passing dma address 0 to firmware

Currently the firmware can't work with a page with dma address 0.
Passing such an address to the firmware will cause the give_pages
command to fail.

To avoid this, in case we get a 0 dma address of a page from the
dma engine, we avoid passing it to FW by remapping to get an address
other than 0.

Fixes: 9b640ba030ac ('mlx5: Support communicating arbitrary host...')
Signed-off-by: Noa Osherovich <noaos@mellanox.com>
Signed-off-by: Saeed Mahameed <saeedm@mellanox.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/mellanox/mlx5/core/pagealloc.c