[PATCH 1/3] pci: add "fundamental reset" quirk

Alexey Kardashevskiy aik at ozlabs.ru
Fri Jan 17 16:09:49 EST 2014


Rats. Please ignore this patchset.


On 01/17/2014 04:08 PM, Alexey Kardashevskiy wrote:
> From: Thadeu Lima de Souza Cascardo <cascardo at linux.vnet.ibm.com>
> 
> Signed-off-by: Thadeu Lima de Souza Cascardo <cascardo at linux.vnet.ibm.com>
> ---
>  drivers/pci/quirks.c | 21 +++++++++++++++++++++
>  1 file changed, 21 insertions(+)
> 
> diff --git a/drivers/pci/quirks.c b/drivers/pci/quirks.c
> index f6c31fa..f3eedbf 100644
> --- a/drivers/pci/quirks.c
> +++ b/drivers/pci/quirks.c
> @@ -3271,6 +3271,19 @@ static int reset_chelsio_generic_dev(struct pci_dev *dev, int probe)
>  	return 0;
>  }
>  
> +static int reset_fundamental(struct pci_dev *dev, int probe)
> +{
> +	if (probe)
> +		return 0;
> +
> +	pci_set_pcie_reset_state(dev, pcie_hot_reset);
> +	msleep(250);
> +	pci_set_pcie_reset_state(dev, pcie_deassert_reset);
> +	msleep(1800);
> +
> +	return 0;
> +}
> +
>  #define PCI_DEVICE_ID_INTEL_82599_SFP_VF   0x10ed
>  #define PCI_DEVICE_ID_INTEL_IVB_M_VGA      0x0156
>  #define PCI_DEVICE_ID_INTEL_IVB_M2_VGA     0x0166
> @@ -3286,6 +3299,14 @@ static const struct pci_dev_reset_methods pci_dev_reset_methods[] = {
>  		reset_intel_generic_dev },
>  	{ PCI_VENDOR_ID_CHELSIO, PCI_ANY_ID,
>  		reset_chelsio_generic_dev },
> +
> +	{ PCI_VENDOR_ID_IBM, PCI_ANY_ID,
> +		reset_fundamental },
> +	{ PCI_VENDOR_ID_MELLANOX, PCI_ANY_ID,
> +		reset_fundamental },
> +	{ PCI_VENDOR_ID_TI, PCI_ANY_ID,
> +		reset_fundamental },
> +
>  	{ 0 }
>  };
>  
> 


-- 
Alexey


More information about the Linuxppc-dev mailing list