Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752501AbdHMLiA (ORCPT ); Sun, 13 Aug 2017 07:38:00 -0400 Received: from mail-pg0-f65.google.com ([74.125.83.65]:34621 "EHLO mail-pg0-f65.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750897AbdHMLh7 (ORCPT ); Sun, 13 Aug 2017 07:37:59 -0400 From: Arvind Yadav To: gregkh@linuxfoundation.org, andrey.shvetsov@k2l.de, christian.gromm@microchip.com Cc: linux-kernel@vger.kernel.org, devel@driverdev.osuosl.org Subject: [PATCH] staging: most: hdm-dim2: constify platform_device_id Date: Sun, 13 Aug 2017 17:07:35 +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: 857 Lines: 25 platform_device_id are not supposed to change at runtime. All functions working with platform_device_id provided by work with const platform_device_id. So mark the non-const structs as const. Signed-off-by: Arvind Yadav --- drivers/staging/most/hdm-dim2/dim2_hdm.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/staging/most/hdm-dim2/dim2_hdm.c b/drivers/staging/most/hdm-dim2/dim2_hdm.c index 4607d03..b1567c80 100644 --- a/drivers/staging/most/hdm-dim2/dim2_hdm.c +++ b/drivers/staging/most/hdm-dim2/dim2_hdm.c @@ -894,7 +894,7 @@ static int dim2_remove(struct platform_device *pdev) return 0; } -static struct platform_device_id dim2_id[] = { +static const struct platform_device_id dim2_id[] = { { "medialb_dim2" }, { }, /* Terminating entry */ }; -- 2.7.4