Skip to content

Commit 61fef29

Browse files
lategoodbyelinusw
authored andcommitted
pinctrl: bcm2835: Fix permissions of persist_gpio_outputs
The commit 8ff0598 ("pinctrl: bcm2835: Make pin freeing behavior configurable") unintentionally made the module parameter persist_gpio_outputs changeable at runtime. So drop the write permission in order to make the freeing behavior predictable for user applications. Fixes: 8ff0598 ("pinctrl: bcm2835: Make pin freeing behavior configurable") Reported-by: Andy Shevchenko <[email protected]> Closes: https://lore.kernel.org/linux-gpio/[email protected]/ Signed-off-by: Stefan Wahren <[email protected]> Acked-by: Florian Fainelli <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Linus Walleij <[email protected]>
1 parent 03ecbe4 commit 61fef29

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

drivers/pinctrl/bcm/pinctrl-bcm2835.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -245,7 +245,7 @@ static const char * const irq_type_names[] = {
245245
};
246246

247247
static bool persist_gpio_outputs;
248-
module_param(persist_gpio_outputs, bool, 0644);
248+
module_param(persist_gpio_outputs, bool, 0444);
249249
MODULE_PARM_DESC(persist_gpio_outputs, "Enable GPIO_OUT persistence when pin is freed");
250250

251251
static inline u32 bcm2835_gpio_rd(struct bcm2835_pinctrl *pc, unsigned reg)

0 commit comments

Comments
 (0)