]> 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)
commit62de16c7ee1073cd51aa484e7a36d175febf8902
tree7aefc77b7aa07da52ebea0f6a0e6dda6a58463e3
parent62d2463406eca151aa21091fda90f8d71b843c39
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