phy: qcom: uniphy-pcie-28lp: Rename the PHY type enum values
Subsystems (3)
PATCH 1/1 phy: qcom: uniphy-pcie-28lp: Rename the PHY type enum values
Commit b28eecc89399 ("include: linux: phy: Add phy attribute "type" and associated helpers") makes <linux/phy/phy.h> include <dt-bindings/phy/phy.h>, which defines PHY_TYPE_PCIE. That clashes with the driver's own enum, and the build fails:
include/dt-bindings/phy/phy.h:15:33: error: expected identifier before numeric constant drivers/phy/qualcomm/phy-qcom-uniphy-pcie-28lp.c:127:27: error: 'PHY_TYPE_PCIE_GEN2' undeclared here (not in a function); did you mean 'PHY_TYPE_PCIE'? drivers/phy/qualcomm/phy-qcom-uniphy-pcie-28lp.c:135:27: error: 'PHY_TYPE_PCIE_GEN3' undeclared here (not in a function); did you mean 'PHY_TYPE_PCIE'?
Give the enum values a QCOM_UNIPHY_ prefix.
---
Against usb-next. The driver needs ARCH_QCOM and is not in arm64 defconfig.
drivers/phy/qualcomm/phy-qcom-uniphy-pcie-28lp.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-)
drivers/phy/qualcomm/phy-qcom-uniphy-pcie-28lp.c +5 -5
@@ -44,9 +44,9 @@#define PHY_CFG_GEN3_ALIGN_HOLDOFF_TIME 0x3e8enum qcom_uniphy_pcie_type { -PHY_TYPE_PCIE =1 , -PHY_TYPE_PCIE_GEN2 , -PHY_TYPE_PCIE_GEN3 , +QCOM_UNIPHY_PCIE =1 , +QCOM_UNIPHY_PCIE_GEN2 , +QCOM_UNIPHY_PCIE_GEN3 , };struct qcom_uniphy_pcie_regs {
@@ -124,7 +124,7 @@ static const struct qcom_uniphy_pcie_regs ipq5332_regs[] = {static const struct qcom_uniphy_pcie_data ipq5018_data = { .lane_offset =0x800 , - .phy_type =PHY_TYPE_PCIE_GEN2 , + .phy_type =QCOM_UNIPHY_PCIE_GEN2 , .init_seq = ipq5018_regs, .init_seq_num =ARRAY_SIZE (ipq5018_regs), .pipe_clk_rate =125 *MEGA ,
@@ -132,7 +132,7 @@ static const struct qcom_uniphy_pcie_data ipq5018_data = {static const struct qcom_uniphy_pcie_data ipq5332_data = { .lane_offset =0x800 , - .phy_type =PHY_TYPE_PCIE_GEN3 , + .phy_type =QCOM_UNIPHY_PCIE_GEN3 , .init_seq = ipq5332_regs, .init_seq_num =ARRAY_SIZE (ipq5332_regs), .pipe_clk_rate =250 *MEGA ,
base-commit: 8e31dedb9ad496ea7dd7064d77d6f7d459c1c90f
Signature · 1 line
2.53.0
[email protected]
AI reviewSashiko has reviewed this patch and found no issues.
Quoted 5 lines
Commit
b28eecc89399("include: linux: phy: Add phy attribute "type" and associated helpers") makes <linux/phy/phy.h> include <dt-bindings/phy/phy.h>, which definesPHY_TYPE_PCIE. That clashes with the driver's own enum, and the build fails:
Quoted 8 lines
include/dt-bindings/phy/phy.h:15:33: error: expected identifier before numeric constantdrivers/phy/qualcomm/phy-qcom-uniphy-pcie-28lp.c:127:27: error: 'PHY_TYPE_PCIE_GEN2' undeclared here (not in a function); did you mean 'PHY_TYPE_PCIE'?drivers/phy/qualcomm/phy-qcom-uniphy-pcie-28lp.c:135:27: error: 'PHY_TYPE_PCIE_GEN3' undeclared here (not in a function); did you mean 'PHY_TYPE_PCIE'?Give the enum values a
QCOM_UNIPHY_prefix.Fixes b28eecc89399 ("include: linux: phy: Add phy attribute "type" and associated helpers")Signed-off-by Sasha Levin <[email protected]>
Sashiko has reviewed this patch and found no issues.
Signature · 1 line
Sashiko AI review · https://sashiko.dev/#/patchset/[email protected]?part=1