[igt-dev] [PATCH i-g-t v3 2/5] lib/igt_pci: Add PCIe slot cap

Nilawar, Badal badal.nilawar at intel.com
Tue Nov 29 14:43:23 UTC 2022


Hi Anshuman,

With a comment this is
Reviewed-by: Badal Nilawar <badal.nilawar at intel.com>
On 23-11-2022 14:24, Anshuman Gupta wrote:
> Adding PCIe slot cap register offset and Power Controller Present
> bit mask macros.
> 
> Signed-off-by: Anshuman Gupta <anshuman.gupta at intel.com>
> ---
>   lib/igt_pci.h | 3 +++
>   1 file changed, 3 insertions(+)
> 
> diff --git a/lib/igt_pci.h b/lib/igt_pci.h
> index 68afd2dacb..5c2863d657 100644
> --- a/lib/igt_pci.h
> +++ b/lib/igt_pci.h
> @@ -21,6 +21,9 @@ enum pci_cap_id {
>   	PCI_EXPRESS_CAP_ID = 0x10
>   };
>   
> +#define PCI_SLOT_CAP_OFFSET 0x14  /* PCIe specs chapter 7.8.9 */
I think lets avoid adding comment about chapter number. Chapter number 
can change as specs keep updating.

Regards,
Badal
> +#define  PCI_SLOT_PWR_CTRL_PRESENT (1 << 1)
> +
>   int find_pci_cap_offset_at(struct pci_device *dev, enum pci_cap_id cap_id,
>   			   int start_offset);
>   


More information about the igt-dev mailing list