1. 27 May, 2020 1 commit
    • Cao jin's avatar
      igb: use igb_adapter->io_addr instead of e1000_hw->hw_addr · 0b3bc1fb
      Cao jin authored
      commit 629823b8 upstream.
      
      When running as guest, under certain condition, it will oops as following.
      writel() in igb_configure_tx_ring() results in oops, because hw->hw_addr
      is NULL. While other register access won't oops kernel because they use
      wr32/rd32 which have a defense against NULL pointer.
      
          [  141.225449] pcieport 0000:00:1c.0: AER: Multiple Uncorrected (Fatal)
          error received: id=0101
          [  141.225523] igb 0000:01:00.1: PCIe Bus Error:
          severity=Uncorrected (Fatal), type=Unaccessible,
          id=0101(Unregistered Agent ID)
          [  141.299442] igb 0000:01:00.1: broadcast error_detected message
          [  141.300539] igb 0000:01:00.0 enp1s0f0: PCIe link lost, device now
          detached
          [  141.351019] igb 0000:01:00.1 enp1s0f1: PCIe link lost, device now
          detached
          [  143.465904] pcieport 0000:00:1c.0: Root Port link has been reset
          [  143.465994] igb 0000:01:00.1: broadcast slot_reset message
          [  143.466039] igb 0000:01:00.0: enabling device (0000 -> 0002)
          [  144.389078] igb 0000:01:00.1: enabling device (0000 -> 0002)
          [  145.312078] igb 0000:01:00.1: broadcast resume message
          [  145.322211] BUG: unable to handle kernel paging request at
          0000000000003818
          [  145.361275] IP: [<ffffffffa02fd38d>]
          igb_configure_tx_ring+0x14d/0x280 [igb]
          [  145.400048] PGD 0
          [  145.438007] Oops: 0002 [#1] SMP
      
      A similar issue & solution could be found at:
          http://patchwork.ozlabs.org/patch/689592/Signed-off-by: default avatarCao jin <caoj.fnst@cn.fujitsu.com>
      Acked-by: default avatarAlexander Duyck <alexander.h.duyck@intel.com>
      Tested-by: default avatarAaron Brown <aaron.f.brown@intel.com>
      Signed-off-by: default avatarJeff Kirsher <jeffrey.t.kirsher@intel.com>
      Cc: Guenter Roeck <linux@roeck-us.net>
      Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
      0b3bc1fb
  2. 20 May, 2020 39 commits