summaryrefslogtreecommitdiff
path: root/drivers/power
diff options
context:
space:
mode:
authorColin Ian King <colin.i.king@gmail.com>2022-10-05 17:13:48 +0100
committerSebastian Reichel <sebastian.reichel@collabora.com>2022-10-28 15:53:46 +0200
commit2e5632aef677cc2e22cbc76704526b51e29b3a7b (patch)
treeb698234cbadf4ea9631db2c37ab82c0a23940129 /drivers/power
parent9abf2313adc1ca1b6180c508c25f22f9395cc780 (diff)
power: supply: lp8788: make const array name static
Don't populate the read-only array name on the stack but instead make it static. Since the data and the pointers don't change also add in a missing const. Also makes the object code a little smaller. Signed-off-by: Colin Ian King <colin.i.king@gmail.com> Signed-off-by: Sebastian Reichel <sebastian.reichel@collabora.com>
Diffstat (limited to 'drivers/power')
-rw-r--r--drivers/power/supply/lp8788-charger.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/power/supply/lp8788-charger.c b/drivers/power/supply/lp8788-charger.c
index 56c57529c2287..f5f47a0aa1e3d 100644
--- a/drivers/power/supply/lp8788-charger.c
+++ b/drivers/power/supply/lp8788-charger.c
@@ -520,7 +520,7 @@ err_free_irq:
static int lp8788_irq_register(struct platform_device *pdev,
struct lp8788_charger *pchg)
{
- const char *name[] = {
+ static const char * const name[] = {
LP8788_CHG_IRQ, LP8788_PRSW_IRQ, LP8788_BATT_IRQ
};
int i;