Skip to contentSkip to conversation

pinctrl: sirf: make const array rsc_ids static

PATCH New Colin King 1 participant 1 message Oct 4, 2018

Subsystems (3)
lore
Share & tools
lore

Colin King

author
#0 lore raw

PATCH 1/1 pinctrl: sirf: make const array rsc_ids static

From: Colin Ian King <[email protected]>

The const array rsc_ids can be made static, saves populating it on the stack and will make it read-only.

---
 drivers/pinctrl/sirf/pinctrl-sirf.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/pinctrl/sirf/pinctrl-sirf.c +1 -1
index 2e42d738b589..2a44b911018e 100644
@@ -246,7 +246,7 @@ static struct pinctrl_desc sirfsoc_pinmux_desc = {
 
 static void __iomem *sirfsoc_rsc_of_iomap(void)
 {
-	const struct of_device_id rsc_ids[]  = {
+	static const struct of_device_id rsc_ids[]  = {
 		{ .compatible = "sirf,prima2-rsc" },
 		{}
 	};
Signature · 1 line
2.17.1