[PATCH v4 0/5] phy: qcom-mipi-csi2: Add D-PHY support for sa8775p, qcs8300 and sc7280

From: Anusha Arun Nandi

Date: Tue Dec 01 2026 - 16:02:21 EST


This series extends the generic Qualcomm MIPI CSI2 PHY driver
(drivers/phy/qualcomm/phy-qcom-mipi-csi2-*) with three additional
CSIPHY variants: SA8775P, QCS8300 and SC7280. The driver currently
only supports x1e80100; these SoCs let CAMSS consume the CSIPHY through
the common PHY framework instead of the CSIPHY logic embedded in the
legacy in-tree CAMSS driver.

QCS8300 shares the same CSIPHY D-PHY hardware as SA8775P, so it does
not need its own of_device_id entry: the qcom,csi2-phy.yaml binding
declares "qcom,sa8775p-csi2-phy" as QCS8300's fallback compatible, and
QCS8300 CSIPHY nodes bind through patch 4's existing
"qcom,sa8775p-csi2-phy" match entry.

Patch 3 restructures phy-qcom-mipi-csi2-3ph-dphy.c before sa8775p and
sc7280 land in patches 4-5. Up to now that one file held both the only
D-PHY register-programming code the driver has, and every SoC's
register data (x1e80100's lane_regs[]/soc_cfg so far), fine for a
single SoC, but adding two more would mean two more multi-hundred-line
register tables piling into the same file as the programming logic,
with no line between "code a reviewer needs to read" and "data a
reviewer just needs to skim for correct addresses/values". Patch 3
splits that: the programming functions move into
phy-qcom-mipi-csi2-core.c, next to the rest of the PHY-framework glue,
so there's a single file for all D-PHY logic, the register tables move
into a new, pure-data phy-qcom-mipi-csi2-dphy-regs.h, #included at the
top of core.c. Patches 4 and 5 then add sa8775p's and sc7280's tables
straight into that data header instead of the old mixed file. No
functional change in patch 3 itself, register addresses, values, and
param_type tags are unchanged, only relocated.
The restructured files looks something like this -

camss.c
|
v
phy-core.c
|
v
phy-qcom-mipi-csi2-core.c
^
| (#include)
+--------------+--------------+
| | |
D-PHY.h C-PHY.h Future Modes
| | |
+--------------+--------------+
Mode-specific register headers
phy-qcom-mipi-csi2-dphy-regs.h
phy-qcom-mipi-csi2-cphy-regs.h

Tested on sa8775p, qcs8300 and sc7280.

Changes in v4:
- Added patch 3, "restructure D-PHY into core.c and dphy-regs.h" (see
above for why).
- Dropped the "Reviewed-by: Jigarkumar Zala" tags from patches 1 and
5: that review happened internally, not on this list, and Krzysztof
pointed out in v3 that a Reviewed-by with no public lore link isn't
verifiable.
- Patch 2 are otherwise unchanged from v3.
- Patches 4 and 5 are now in the header file.

Link to v3: https://lore.kernel.org/all/20261105235137.2635442-1-anusha.nandi@xxxxxxxxxxxxxxxx/

Depends-on: https://lore.kernel.org/all/20261102213936.1251316-1-anusha.nandi@xxxxxxxxxxxxxxxx/

Anusha Arun Nandi (5):
dt-bindings: phy: qcom: Add common qcom,csi2-phy
phy: qcom-mipi-csi2: Make OPP table optional
phy: qcom-mipi-csi2: restructure D-PHY into core.c and dphy-regs.h
phy: qcom-mipi-csi2: Add sa8775p D-PHY support
phy: qcom-mipi-csi2: Add sc7280 D-PHY provider

Jigarkumar Zala (5):
dt-bindings: phy: qcom: Add common qcom,csi2-phy
phy: qcom-mipi-csi2: Make OPP table optional
phy: qcom-mipi-csi2: restructure D-PHY into core.c and dphy-regs.h
phy: qcom-mipi-csi2: Add sa8775p D-PHY support
phy: qcom-mipi-csi2: Add sc7280 D-PHY provider

.../bindings/phy/qcom,csi2-phy.yaml | 201 +++++++++
drivers/phy/qualcomm/Makefile | 3 +-
.../qualcomm/phy-qcom-mipi-csi2-3ph-dphy.c | 385 -----------------
.../phy/qualcomm/phy-qcom-mipi-csi2-core.c | 306 ++++++++++++--
.../qualcomm/phy-qcom-mipi-csi2-dphy-regs.h | 388 ++++++++++++++++++
drivers/phy/qualcomm/phy-qcom-mipi-csi2.h | 24 +-
6 files changed, 875 insertions(+), 432 deletions(-)
create mode 100644 Documentation/devicetree/bindings/phy/qcom,csi2-phy.yaml
delete mode 100644 drivers/phy/qualcomm/phy-qcom-mipi-csi2-3ph-dphy.c
create mode 100644 drivers/phy/qualcomm/phy-qcom-mipi-csi2-dphy-regs.h

Best regards,
--
Anusha Arun Nandi <anusha.nandi@xxxxxxxxxxxxxxxx>
--
2.34.1