Re: [PATCH v1 4/5] pwm: Unify coding style of of_device_id arrays
Chen Wang <[email protected]> Mon, 6 Jul 2026 08:33:47 +0800
| Newsgroups | dev.linux.lists.sophgo,dev.linux.lists.asahi,dev.linux.lists.chrome-platform,dev.linux.lists.imx,dev.linux.lists.linux-sunxi,org.infradead.lists.linux-amlogic,org.infradead.lists.linux-mediatek,org.infradead.lists.linux-riscv,org.infradead.lists.linux-rockchip,org.kernel.vger.linux-kernel,org.kernel.vger.linux-mips,org.kernel.vger.linux-pwm,org.kernel.vger.linux-renesas-soc,org.kernel.vger.linux-samsung-soc |
|---|---|
| Message-ID | <[email protected]> |
On 7/5/2026 11:14 PM, Uwe Kleine-König (The Capable Hub) wrote:
> - Use a single space in a of_device_id array terminator; A single space
> after the opening { and before the closing } in non-empty
> initializers;
> - No comma after an array terminator;
> - Also no trailing comma after a named initializer iff the
iff -> if
> closing } is on the same line;
>
> Signed-off-by: Uwe Kleine-König (The Capable Hub) <[email protected]>
[......]
> diff --git a/drivers/pwm/pwm-sophgo-sg2042.c b/drivers/pwm/pwm-sophgo-sg2042.c
> index 7d07b0ca7d29..0b6461172e6a 100644
> --- a/drivers/pwm/pwm-sophgo-sg2042.c
> +++ b/drivers/pwm/pwm-sophgo-sg2042.c
> @@ -225,11 +225,10 @@ static const struct sg2042_chip_data sg2044_chip_data = {
> static const struct of_device_id sg2042_pwm_ids[] = {
> {
> .compatible = "sophgo,sg2042-pwm",
> - .data = &sg2042_chip_data
> - },
> - {
> + .data = &sg2042_chip_data,
> + }, {
> .compatible = "sophgo,sg2044-pwm",
> - .data = &sg2044_chip_data
> + .data = &sg2044_chip_data,
> },
> { }
> };
Changes to sophgo related files:
Reviewed-by: Chen Wang <[email protected]>
Thanks,
Chen
[......]