Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753164AbdHQL4w (ORCPT ); Thu, 17 Aug 2017 07:56:52 -0400 Received: from mail-pg0-f68.google.com ([74.125.83.68]:33704 "EHLO mail-pg0-f68.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753136AbdHQL4g (ORCPT ); Thu, 17 Aug 2017 07:56:36 -0400 From: Arvind Yadav To: mchehab@kernel.org, hverkuil@xs4all.nl Cc: linux-kernel@vger.kernel.org, linux-media@vger.kernel.org Subject: [PATCH] [media] usb: rainshadow-cec: constify serio_device_id Date: Thu, 17 Aug 2017 17:26:24 +0530 Message-Id: X-Mailer: git-send-email 2.7.4 In-Reply-To: References: In-Reply-To: References: Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 915 Lines: 24 serio_device_id are not supposed to change at runtime. All functions working with serio_device_id provided by work with const serio_device_id. So mark the non-const structs as const. Signed-off-by: Arvind Yadav --- drivers/media/usb/rainshadow-cec/rainshadow-cec.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/media/usb/rainshadow-cec/rainshadow-cec.c b/drivers/media/usb/rainshadow-cec/rainshadow-cec.c index f203699..b82e37c 100644 --- a/drivers/media/usb/rainshadow-cec/rainshadow-cec.c +++ b/drivers/media/usb/rainshadow-cec/rainshadow-cec.c @@ -361,7 +361,7 @@ static int rain_connect(struct serio *serio, struct serio_driver *drv) return err; } -static struct serio_device_id rain_serio_ids[] = { +static const struct serio_device_id rain_serio_ids[] = { { .type = SERIO_RS232, .proto = SERIO_RAINSHADOW_CEC, -- 2.7.4