Hej Sakari, On 2023-07-29 20:03:17 +0000, Sakari Ailus wrote: > Hejssan Niklas, > > On Sat, Jul 15, 2023 at 10:12:39PM +0200, Niklas Söderlund wrote: > > Add support for C-PHY on R-Car V4H. While the V4H supports both D-PHY > > and C-PHY this patch only adds support for the C-PHY mode due to lack of > > documentation and hardware to test on. > > > > The V4H is the first Gen4 device that is enabled in the rcar-csi2 > > driver. There is much overlap with the Gen3 driver, the primary > > difference is in how the receiver is started. The V4H have a much larger > > register space and some addresses overlap with Gen3. > > > > Signed-off-by: Niklas Söderlund <niklas.soderlund+renesas@xxxxxxxxxxxx> > > I've made this change to the patch, it won't build otherwise (arm arch): Super, thanks a bunch! Sorry I did not test this. > > diff --git a/drivers/media/platform/renesas/rcar-vin/rcar-csi2.c b/drivers/media/platform/renesas/rcar-vin/rcar-csi2.c > index 99d190a9e637..f6326df0b09b 100644 > --- a/drivers/media/platform/renesas/rcar-vin/rcar-csi2.c > +++ b/drivers/media/platform/renesas/rcar-vin/rcar-csi2.c > @@ -756,7 +756,7 @@ static int rcsi2_calc_mbps(struct rcar_csi2 *priv, unsigned int bpp, > > /* Adjust for C-PHY, divide by 2.8. */ > if (priv->cphy) > - mbps = (mbps * 5) / 14; > + mbps = div_u64(mbps * 5, 14); > > return mbps; > } > > -- > Sakari Ailus -- Kind Regards, Niklas Söderlund