[PATCH v5 05/12] powerpc/eeh: EEH for pSeries hot plug

Nathan Lynch nathanl at linux.ibm.com
Tue Sep 24 04:01:55 AEST 2019


Sam Bobroff <sbobroff at linux.ibm.com> writes:
> Thanks, this does look like a bug to me. I couldn't replicate your crash
> (even with CONFIG_SLUB_DEBUG_ON) but I think I do see a bug there.
>
> Does the below patch also fix it for you?

Yes, this works as well, thanks.


> diff --git a/arch/powerpc/kernel/eeh.c b/arch/powerpc/kernel/eeh.c
> index 0a91dee51245..f8aa65cb2931 100644
> --- a/arch/powerpc/kernel/eeh.c
> +++ b/arch/powerpc/kernel/eeh.c
> @@ -1207,10 +1207,11 @@ void eeh_add_device_late(struct pci_dev *dev)
>         if (eeh_has_flag(EEH_PROBE_MODE_DEV))
>                 eeh_ops->probe(pdn, NULL);
>
> -       edev->pdev = dev;
> -       dev->dev.archdata.edev = edev;
> -
> -       eeh_addr_cache_insert_dev(dev);
> +       if (eeh_enabled()) {
> +               edev->pdev = dev;
> +               dev->dev.archdata.edev = edev;
> +               eeh_addr_cache_insert_dev(dev);
> +       }
>  }
>
>  /**


More information about the Linuxppc-dev mailing list