ice: save PCI state in probe

Save state to correct recovery memory and I/O BARs address
after PCI bus reset. Without this after reset kernel can't
read device registers.

Signed-off-by: Michal Swiatkowski <michal.swiatkowski@intel.com>
Tested-by: Andrew Bowers <andrewx.bowers@intel.com>
Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
This commit is contained in:
Michal Swiatkowski 2019-10-09 07:09:46 -07:00 committed by Jeff Kirsher
parent b2883dfe1f
commit 4e56802e0e
1 changed files with 2 additions and 0 deletions

View File

@ -3152,6 +3152,8 @@ ice_probe(struct pci_dev *pdev, const struct pci_device_id __always_unused *ent)
hw = &pf->hw;
hw->hw_addr = pcim_iomap_table(pdev)[ICE_BAR0];
pci_save_state(pdev);
hw->back = pf;
hw->vendor_id = pdev->vendor;
hw->device_id = pdev->device;