lkml.org 
[lkml]   [2022]   [Jul]   [5]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
Date
SubjectRe: [PATCH v3 5/6] leds: is31fl319x: Move chipset-specific values in chipdef struct
On Tue, Jul 5, 2022 at 6:33 PM Vincent Knecht <vincent.knecht@mailoo.org> wrote:
>
> Allow setting chips' specifics in chipdef struct by adding fields for:
> - the reset register address
> - a pointer to a regmap_config struct
> - a pointer to a brightness_set function
> - current default, min and max values
> - a boolean to distinguish 319{0,1,3} and 319{6,9} chips
> and use those fields in places where distinction has to be made.
>
> The fields for 319{0,1,3} still point to 319{6,9} values.
> No functional change.

...

> +static bool is31fl319x_readable_reg(struct device *dev, unsigned int reg)
> +{ /* we have no readable registers */

Non-standard place for comments.

> + return false;
> +}

...

> +static const struct reg_default is31fl3196_reg_defaults[] = {
> + { IS31FL3196_CONFIG1, 0x00},
> + { IS31FL3196_CONFIG2, 0x00},
> + { IS31FL3196_PWM(0), 0x00},
> + { IS31FL3196_PWM(1), 0x00},
> + { IS31FL3196_PWM(2), 0x00},
> + { IS31FL3196_PWM(3), 0x00},
> + { IS31FL3196_PWM(4), 0x00},
> + { IS31FL3196_PWM(5), 0x00},
> + { IS31FL3196_PWM(6), 0x00},
> + { IS31FL3196_PWM(7), 0x00},
> + { IS31FL3196_PWM(8), 0x00},

Missed space before }.

> };

--
With Best Regards,
Andy Shevchenko

\
 
 \ /
  Last update: 2022-07-05 20:53    [W:0.055 / U:0.308 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site