From: Colin Ian King Date: Mon, 17 Mar 2025 16:58:45 +0000 (+0000) Subject: regulator: rtq6752: make const read-only array fault_mask static X-Git-Tag: v6.15-rc1~183^2~3 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=502d16c0bd8fa40ba194f00ccac4bc205a5c253f;p=thirdparty%2Flinux.git regulator: rtq6752: make const read-only array fault_mask static Don't populate the const read-only array fault_mask on the stack at run time, instead make it static. Signed-off-by: Colin Ian King Link: https://patch.msgid.link/20250317165845.525593-1-colin.i.king@gmail.com Signed-off-by: Mark Brown --- diff --git a/drivers/regulator/rtq6752-regulator.c b/drivers/regulator/rtq6752-regulator.c index d35d844eff3b8..618904ede72c4 100644 --- a/drivers/regulator/rtq6752-regulator.c +++ b/drivers/regulator/rtq6752-regulator.c @@ -105,7 +105,7 @@ static int rtq6752_get_error_flags(struct regulator_dev *rdev, unsigned int *flags) { unsigned int val, events = 0; - const unsigned int fault_mask[] = { + static const unsigned int fault_mask[] = { RTQ6752_PAVDDF_MASK, RTQ6752_NAVDDF_MASK }; int rid = rdev_get_id(rdev), ret;