Skip to content

Support additional CCS PLL features, C-PHY

Sakari Ailus linux-media 1 version New

Get series with b4
b4 am [email protected]

Versions newest first

  1. v1 Latest38 patches 0 repliesNew

Patches in v1 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/38ccs-pll: Don't use div_u64 to divide a 32-bit numberdrivers/media/i2c/ccs-pll.c+1 -10 replies
2/38ccs-pll: Split limits and PLL configuration into front and back partsdrivers/media/i2c/ccs-pll.c drivers/media/i2c/ccs-pll.h drivers/media/i2c/ccs/ccs-core.c+209 -1880 replies
3/38ccs-pll: Use correct VT divisor for calculating VT SYS divisordrivers/media/i2c/ccs-pll.c+2 -20 replies
4/38ccs-pll: End search if there are no better values availabledrivers/media/i2c/ccs-pll.c+8 -20 replies
5/38ccs-pll: Remove parallel bus supportdrivers/media/i2c/ccs-pll.c drivers/media/i2c/ccs-pll.h+4 -150 replies
6/38ccs-pll: Differentiate between CSI-2 D-PHY and C-PHYdrivers/media/i2c/ccs-pll.c drivers/media/i2c/ccs-pll.h drivers/media/i2c/ccs/ccs-core.c+4 -30 replies
7/38ccs-pll: Move the flags field down, away from 8-bit fieldsdrivers/media/i2c/ccs-pll.h+1 -10 replies
8/38ccs-pll: Document the structs in the header as well as the functiondrivers/media/i2c/ccs-pll.h+89 -00 replies
9/38ccs-pll: Use the BIT macrodrivers/media/i2c/ccs-pll.h+5 -20 replies
10/38ccs-pll: Begin calculation from OP system clock frequencydrivers/media/i2c/ccs-pll.c+4 -80 replies
11/38ccs-pll: Fix condition for pre-PLL divider lower bounddrivers/media/i2c/ccs-pll.c+1 -10 replies
12/38ccs-pll: Avoid overflow in pre-PLL divisor lower bound searchdrivers/media/i2c/ccs-pll.c+9 -20 replies
13/38ccs-pll: Fix comment on check against maximum PLL multiplierdrivers/media/i2c/ccs-pll.c+1 -10 replies
14/38ccs-pll: Fix check for PLL multiplier upper bounddrivers/media/i2c/ccs-pll.c+1 -20 replies
15/38ccs-pll: Use explicit 32-bit unsigned typedrivers/media/i2c/ccs-pll.c+2 -20 replies
16/38ccs-pll: Add support for lane speed modeldrivers/media/i2c/ccs-pll.c drivers/media/i2c/ccs-pll.h+31 -110 replies
17/38ccs: Add support for lane speed modeldrivers/media/i2c/ccs/ccs-core.c+10 -10 replies
18/38ccs-pll: Add support for decoupled OP domain calculationdrivers/media/i2c/ccs-pll.c drivers/media/i2c/ccs-pll.h drivers/media/i2c/ccs/ccs-core.c +1 more+23 -190 replies
19/38ccs-pll: Add support for extended input PLL clock dividerdrivers/media/i2c/ccs-pll.c drivers/media/i2c/ccs-pll.h drivers/media/i2c/ccs/ccs-core.c+7 -10 replies
20/38ccs-pll: Support two cycles per pixel on OP domaindrivers/media/i2c/ccs-pll.c drivers/media/i2c/ccs-pll.h drivers/media/i2c/ccs/ccs-core.c+16 -60 replies
21/38ccs-pll: Add support flexible OP PLL pixel clock dividerdrivers/media/i2c/ccs-pll.c drivers/media/i2c/ccs-pll.h drivers/media/i2c/ccs/ccs-core.c+23 -80 replies
22/38ccs-pll: Add sanity checksdrivers/media/i2c/ccs-pll.c+9 -00 replies
23/38ccs-pll: Add C-PHY supportdrivers/media/i2c/ccs-pll.c+26 -90 replies
24/38ccs-pll: Split off VT subtree calculationdrivers/media/i2c/ccs-pll.c+131 -1240 replies
25/38ccs-pll: Check for derating and overrating, support non-derating sensorsdrivers/media/i2c/ccs-pll.c drivers/media/i2c/ccs-pll.h drivers/media/i2c/ccs/ccs-core.c+64 -290 replies
26/38ccs-pll: Better separate OP and VT sub-tree calculationdrivers/media/i2c/ccs-pll.c+31 -230 replies
27/38ccs-pll: Print relevant information on PLL treedrivers/media/i2c/ccs-pll.c+66 -190 replies
28/38ccs-pll: Rework bounds checksdrivers/media/i2c/ccs-pll.c drivers/media/i2c/ccs-pll.h+95 -570 replies
29/38ccs-pll: Make VT divisors 16-bitdrivers/media/i2c/ccs-pll.c+25 -260 replies
30/38ccs-pll: Fix VT post-PLL divisor calculationdrivers/media/i2c/ccs-pll.c+7 -50 replies
31/38ccs-pll: Separate VT divisor limit calculation from the restdrivers/media/i2c/ccs-pll.c+37 -270 replies
32/38ccs-pll: Add trivial dual PLL supportdrivers/media/i2c/ccs-pll.c drivers/media/i2c/ccs-pll.h+196 -220 replies
33/38ccs: Dual PLL supportdrivers/media/i2c/ccs-pll.c drivers/media/i2c/ccs/ccs-core.c+51 -30 replies
34/38ccs-pll: Add support for DDR OP system and pixel clocksdrivers/media/i2c/ccs-pll.c drivers/media/i2c/ccs-pll.h+46 -200 replies
35/38ccs: Add support for DDR OP SYS and OP PIX clocksdrivers/media/i2c/ccs/ccs-core.c+8 -10 replies
36/38ccs: Print written register valuesdrivers/media/i2c/ccs/ccs-reg-access.c+4 -00 replies
37/38ccs-pll: Print pixel ratesdrivers/media/i2c/ccs-pll.c+5 -00 replies
38/38ccs: Add support for obtaining C-PHY configuration from firmwaredrivers/media/i2c/ccs/ccs-core.c+4 -00 replies

Reviews trailers per patch

No Reviewed-by, Acked-by or Tested-by trailers for v1 yet.

Read the v1 thread

Cover letter [PATCH 00/38] Support additional CCS PLL features, C-PHY

Hello everyone,

Here's a set of patches that turn the existing SMIA driver into a MIPI CCS driver while maintaining SMIA support. A number of bugs in the existing code are fixed in this set, too.

The changes at this point are primarily focused on dealing with new mandatory driver features related to PLL configuration (as CCS allows for much more variation there) and things such as integer conversion from U16.U16 format instead of float. There are some other new features as well such as digital gain and support for getting device specific analogue gain coefficients.

A new feature in CCS is CCS static data which makes it possible to obtain sensor's capabilities and limits from a file chosen based on sensor identification. CCS static data is used also for storing MSR registers so supporting new, CCS compliant devices requires no driver changes.

Also DT bindings are updated accordingly and converted to YAML format.

More information on MIPI CCS can be found here:

<URL:https://www.mipi.org/specifications/camera-command-set>

Comments are welcome.

since the big, big patchset (v2):

- Split into more easily reviewable chunks (this is the first of maybe three). The cover page describes the entire big set. This set contains support for additional CCS PLL features as well as making the CCS driver support them, including trivial dual PLL and C-PHY support --- as the first upstream sensor driver supporting C-PHY.

- Fix kerneldoc comments in CCS PLL documentation.

Sakari Ailus (38):
ccs-pll: Don't use div_u64 to divide a 32-bit number
ccs-pll: Split limits and PLL configuration into front and back parts
ccs-pll: Use correct VT divisor for calculating VT SYS divisor
ccs-pll: End search if there are no better values available
ccs-pll: Remove parallel bus support
ccs-pll: Differentiate between CSI-2 D-PHY and C-PHY
ccs-pll: Move the flags field down, away from 8-bit fields
ccs-pll: Document the structs in the header as well as the function
ccs-pll: Use the BIT macro
ccs-pll: Begin calculation from OP system clock frequency
ccs-pll: Fix condition for pre-PLL divider lower bound
ccs-pll: Avoid overflow in pre-PLL divisor lower bound search
ccs-pll: Fix comment on check against maximum PLL multiplier
ccs-pll: Fix check for PLL multiplier upper bound
ccs-pll: Use explicit 32-bit unsigned type
ccs-pll: Add support for lane speed model
ccs: Add support for lane speed model
ccs-pll: Add support for decoupled OP domain calculation
ccs-pll: Add support for extended input PLL clock divider
ccs-pll: Support two cycles per pixel on OP domain
ccs-pll: Add support flexible OP PLL pixel clock divider
ccs-pll: Add sanity checks
ccs-pll: Add C-PHY support
ccs-pll: Split off VT subtree calculation
ccs-pll: Check for derating and overrating, support non-derating
sensors
ccs-pll: Better separate OP and VT sub-tree calculation
ccs-pll: Print relevant information on PLL tree
ccs-pll: Rework bounds checks
ccs-pll: Make VT divisors 16-bit
ccs-pll: Fix VT post-PLL divisor calculation
ccs-pll: Separate VT divisor limit calculation from the rest
ccs-pll: Add trivial dual PLL support
ccs: Dual PLL support
ccs-pll: Add support for DDR OP system and pixel clocks
ccs: Add support for DDR OP SYS and OP PIX clocks
ccs: Print written register values
ccs-pll: Print pixel rates
ccs: Add support for obtaining C-PHY configuration from firmware

 drivers/media/i2c/ccs-pll.c            | 986 +++++++++++++++++--------
 drivers/media/i2c/ccs-pll.h            | 177 ++++-
 drivers/media/i2c/ccs/ccs-core.c       | 161 +++-
 drivers/media/i2c/ccs/ccs-quirk.c      |   5 +-
 drivers/media/i2c/ccs/ccs-reg-access.c |   4 +
 5 files changed, 974 insertions(+), 359 deletions(-)
Signature · 1 line
2.27.0