Skip to content

Commit

Permalink
pinctrl: apple-gpio: fix flexible_array.cocci warnings
Browse files Browse the repository at this point in the history
Zero-length and one-element arrays are deprecated, see
Documentation/process/deprecated.rst
Flexible-array members should be used instead.

Generated by: scripts/coccinelle/misc/flexible_array.cocci

CC: Joey Gouly <joey.gouly@arm.com>
Reported-by: kernel test robot <lkp@intel.com>
Signed-off-by: kernel test robot <lkp@intel.com>
Signed-off-by: Julia Lawall <julia.lawall@inria.fr>
Link: https://lore.kernel.org/r/alpine.DEB.2.22.394.2111271859250.2864@hadrien
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
  • Loading branch information
kernel test robot authored and Linus Walleij committed Dec 2, 2021
1 parent 9f9d17c commit f3e3e63
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion drivers/pinctrl/pinctrl-apple-gpio.c
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ struct apple_gpio_pinctrl {
struct pinctrl_desc pinctrl_desc;
struct gpio_chip gpio_chip;
struct irq_chip irq_chip;
u8 irqgrps[0];
u8 irqgrps[];
};

#define REG_GPIO(x) (4 * (x))
Expand Down

0 comments on commit f3e3e63

Please sign in to comment.