]> git.baikalelectronics.ru Git - kernel.git/commit
fm10k: use dma_set_mask_and_coherent in fm10k_probe
authorJacob Keller <jacob.e.keller@intel.com>
Tue, 16 Jun 2015 20:41:43 +0000 (13:41 -0700)
committerJeff Kirsher <jeffrey.t.kirsher@intel.com>
Wed, 17 Jun 2015 21:21:10 +0000 (14:21 -0700)
commit0a166422d3d822673937ed180f51509a523a2395
tree7aefc77b7aa07da52ebea0f6a0e6dda6a58463e3
parent8173f3e1873c67035d4011ef52c7f2061739b012
fm10k: use dma_set_mask_and_coherent in fm10k_probe

This patch cleans up the use of dma_get_required_mask and uses the
simpler dma_set_mask_and_coherent function instead of doing these as
separate steps.

I removed the dma_get_required_mask call because based on some minimal
testing it appears that either (a) we're not doing the right thing with
the call or (b) we don't need it anyways. If the value returned is
<48bits, we'll end up trying with 48 bits anyways. If it's over 48bits,
fm10k can't support that anyways, and we should try 48bits. If 48bits
fails, we'll fallback to 32bits. This cleans up some very funky code.

Signed-off-by: Jacob Keller <jacob.e.keller@intel.com>
Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
drivers/net/ethernet/intel/fm10k/fm10k_pci.c