From: Thomas Richard Date: Wed, 19 Jun 2024 10:15:13 +0000 (+0200) Subject: PCI: Add T_PERST_CLK_US macro X-Git-Tag: v6.12-rc1~96^2~12^2~2 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=6aa9c09f1bcd339749b249830c604871740df268;p=thirdparty%2Fkernel%2Flinux.git PCI: Add T_PERST_CLK_US macro The "Power Sequencing and Reset Signal Timings" table of the PCI Express Card Electromechanical Specification, Revision 5.1, Section 2.9.2, indicates PERST# should be deasserted after minimum of 100us once REFCLK is stable (symbol T_PERST-CLK). Add a macro so that PCIe controller drivers can use it. Link: https://lore.kernel.org/linux-pci/20240102-j7200-pcie-s2r-v7-5-a2f9156da6c3@bootlin.com Signed-off-by: Thomas Richard [kwilczynski: commit log, update sleep interval macros code comments] Signed-off-by: Krzysztof WilczyƄski --- diff --git a/drivers/pci/pci.h b/drivers/pci/pci.h index 79c8398f39384..abfe0b3d5f1e6 100644 --- a/drivers/pci/pci.h +++ b/drivers/pci/pci.h @@ -13,9 +13,24 @@ #define PCIE_LINK_RETRAIN_TIMEOUT_MS 1000 -/* Power stable to PERST# inactive from PCIe card Electromechanical Spec */ +/* + * Power stable to PERST# inactive. + * + * See the "Power Sequencing and Reset Signal Timings" table of the PCI Express + * Card Electromechanical Specification, Revision 5.1, Section 2.9.2, Symbol + * "T_PVPERL". + */ #define PCIE_T_PVPERL_MS 100 +/* + * REFCLK stable before PERST# inactive. + * + * See the "Power Sequencing and Reset Signal Timings" table of the PCI Express + * Card Electromechanical Specification, Revision 5.1, Section 2.9.2, Symbol + * "T_PERST-CLK". + */ +#define PCIE_T_PERST_CLK_US 100 + /* * End of conventional reset (PERST# de-asserted) to first configuration * request (device able to respond with a "Request Retry Status" completion),