iavf: Add helper function to go from pci_dev to adapter
authorKaren Sornek <karen.sornek@intel.com>
Wed, 15 Sep 2021 06:41:23 +0000 (08:41 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Tue, 8 Mar 2022 18:12:51 +0000 (19:12 +0100)
commit200366d1a5836a9cae28459066a8c54858072b9f
treea3879adf935996faf177db40a454eb67fbbe031d
parent23901462c301574b4f79c3360b61fcb1c8c9a6e6
iavf: Add helper function to go from pci_dev to adapter

[ Upstream commit 247aa001b72b6c8a89df9d108a2ec6f274a6b64d ]

Add helper function to go from pci_dev to adapter to make work simple -
to go from a pci_dev to the adapter structure and make netdev assignment
instead of having to go to the net_device then the adapter.

Signed-off-by: Brett Creeley <brett.creeley@intel.com>
Signed-off-by: Karen Sornek <karen.sornek@intel.com>
Tested-by: Konrad Jankowski <konrad0.jankowski@intel.com>
Signed-off-by: Tony Nguyen <anthony.l.nguyen@intel.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/net/ethernet/intel/iavf/iavf_main.c