net: hns3: use dma_zalloc_coherent instead of kzalloc/dma_map_single
authorHuazhong Tan <tanhuazhong@huawei.com>
Mon, 2 Jul 2018 07:50:25 +0000 (15:50 +0800)
committerDavid S. Miller <davem@davemloft.net>
Mon, 2 Jul 2018 13:49:14 +0000 (22:49 +0900)
commit024cc792f9309f1342a2fd7bd5840e112b333687
tree152a2efbf7c972cecef8680ea29e0dc1a4d64e21
parent7a7056e3dfa6636989b821d890448ae49375bd22
net: hns3: use dma_zalloc_coherent instead of kzalloc/dma_map_single

Reference to Documentation/DMA-API-HOWTO.txt,
Streaming DMA mappings which are usually mapped for one DMA transfer,
Network card DMA ring descriptors should use Consistent DMA mappings.

Signed-off-by: Huazhong Tan <tanhuazhong@huawei.com>
Signed-off-by: Peng Li <lipeng321@huawei.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/hisilicon/hns3/hns3_enet.c
drivers/net/ethernet/hisilicon/hns3/hns3pf/hclge_cmd.c
drivers/net/ethernet/hisilicon/hns3/hns3vf/hclgevf_cmd.c