vmxnet3: set the DMA mask before the first DMA map operation
authorhpreg@vmware.com <hpreg@vmware.com>
Mon, 14 May 2018 12:14:34 +0000 (08:14 -0400)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Fri, 25 May 2018 14:17:25 +0000 (16:17 +0200)
commit74327eda43d039a47ff8d35e3524ab145f8cdbaf
tree0c6d10a9154038190f14c520c4f0bcec3a024877
parentc89d534301a028125432e7d9a39edb08cfd90480
vmxnet3: set the DMA mask before the first DMA map operation

[ Upstream commit 61aeecea40afb2b89933e27cd4adb10fc2e75cfd ]

The DMA mask must be set before, not after, the first DMA map operation, or
the first DMA map operation could in theory fail on some systems.

Fixes: b0eb57cb97e78 ("VMXNET3: Add support for virtual IOMMU")
Signed-off-by: Regis Duchesne <hpreg@vmware.com>
Acked-by: Ronak Doshi <doshir@vmware.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/net/vmxnet3/vmxnet3_drv.c