Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754170AbdHUQvS (ORCPT ); Mon, 21 Aug 2017 12:51:18 -0400 Received: from mail-pg0-f68.google.com ([74.125.83.68]:35087 "EHLO mail-pg0-f68.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753636AbdHUQvR (ORCPT ); Mon, 21 Aug 2017 12:51:17 -0400 From: Arvind Yadav To: lgirdwood@gmail.com, broonie@kernel.org Cc: linux-kernel@vger.kernel.org Subject: [PATCH] regulator: ltc3589: constify i2c_device_id Date: Mon, 21 Aug 2017 22:21:08 +0530 Message-Id: X-Mailer: git-send-email 2.7.4 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 800 Lines: 24 i2c_device_id are not supposed to change at runtime. All functions working with i2c_device_id provided by work with const i2c_device_id. So mark the non-const structs as const. Signed-off-by: Arvind Yadav --- drivers/regulator/ltc3589.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/regulator/ltc3589.c b/drivers/regulator/ltc3589.c index 853a06a..18d5b01 100644 --- a/drivers/regulator/ltc3589.c +++ b/drivers/regulator/ltc3589.c @@ -539,7 +539,7 @@ static int ltc3589_probe(struct i2c_client *client, return 0; } -static struct i2c_device_id ltc3589_i2c_id[] = { +static const struct i2c_device_id ltc3589_i2c_id[] = { { "ltc3589", LTC3589 }, { "ltc3589-1", LTC3589_1 }, { "ltc3589-2", LTC3589_2 }, -- 2.7.4