lkml.org 
[lkml]   [2023]   [Jul]   [21]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH v2 6/8] media: i2c: ds90ub953: Restructure clkout management
On Thu, Jul 20, 2023 at 01:30:37PM +0300, Tomi Valkeinen wrote:
> Separate clkout calculations and register writes into two functions:
> ub953_calc_clkout_params and ub953_write_clkout_regs, and add a struct
> ub953_clkout_data that is used to store the clkout parameters.
>
> This simplifies the clkout management.

...

> +struct ub953_clkout_data {
> + u32 hs_div;
> + u32 m;
> + u32 n;

I don't think it makes driver worse. The V4L2 UAPI has similar struct which is
used widely, hence I see no issues in using u32_fract here.

OTOH I'm not a maintainer, so...

> + unsigned long rate;
> +};

--
With Best Regards,
Andy Shevchenko


\
 
 \ /
  Last update: 2023-07-21 12:30    [W:0.605 / U:0.264 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site