From patchwork Sun Aug 6 07:41:23 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Arvind Yadav X-Patchwork-Id: 9883567 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id 64ADF602B6 for ; Sun, 6 Aug 2017 07:43:16 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 54D622860D for ; Sun, 6 Aug 2017 07:43:16 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 49BA528645; Sun, 6 Aug 2017 07:43:16 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-6.3 required=2.0 tests=BAYES_00, DKIM_ADSP_CUSTOM_MED, DKIM_SIGNED, FREEMAIL_FROM, RCVD_IN_DNSWL_HI, RCVD_IN_SORBS_SPAM, T_DKIM_INVALID autolearn=ham version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id CAEDD2860D for ; Sun, 6 Aug 2017 07:43:15 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751987AbdHFHnC (ORCPT ); Sun, 6 Aug 2017 03:43:02 -0400 Received: from mail-pf0-f196.google.com ([209.85.192.196]:34288 "EHLO mail-pf0-f196.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751506AbdHFHlw (ORCPT ); Sun, 6 Aug 2017 03:41:52 -0400 Received: by mail-pf0-f196.google.com with SMTP id t86so6017050pfe.1; Sun, 06 Aug 2017 00:41:52 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=V8G11qthLI8l712u60KfswCZwWvINQaKD/oVqTbIdUI=; b=c3YfNGSHlx5h1osrtrgbZDdlrC2IoflU1tk+6CTY1Vm7NsgxLXPx+K2W87vQjVFLs+ Twy5uyK9+QvyCgJkTp6wRuEmDeo2NPWN/HwtfWLbdJyZTvwrvTjR6AmNgK7CkAmJKeJa PgdwUzPH1Lh+ZV8GeLI0hV6hYm6YqJIVlZwGPUIjs50RVObm9q54UywAYy2882agU1ja uRAhZc0Sa6ST3IuRzlUf8DXPC6vBu0s8/Qo9lHsREV2EpAZDvbr8oF9wjo8GlrbTvT4X OzEMCu5yIW7sL0++bs8CWspYLoQST9SBBaKv/f98lqq36KVT1tdVqisRujtOm6o+q819 EXQg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=V8G11qthLI8l712u60KfswCZwWvINQaKD/oVqTbIdUI=; b=W1cbNI3zxS/vVTs88miE6nUjM9aJIPLR+tdpV1oVXPJnMt570tMPAYcDpWSU/R8WC/ W10/2g+1m8QF7jCQixIwNqb2HqZob00Bhsk4EeToBLtzQkssv2hQaxMvjplGYfU88ggs RB3E1Miw3/RmM93w5+UnK+cYGPTyMKJvZcrw8tizvlnz2CMmtIs0tzwNKA8blyQvQuVi /tlttmI2myNF9IejruUjK8PvOhtnVDSFzACbp9/Nz0WLk8PxScvn7WU9C80waz5wgtq6 u+Kww2b6yBpAlMAsdbI0pSUs1IvgO+nhAhWBC08DitZU7MUE1cBeBpNBGnxzkDksDU7K 03PQ== X-Gm-Message-State: AIVw111HImkQaTfWnD2O9t23IPqPKs/+417bx8mcD2Jh/iLEORt3lGKf 3LlaahgbhVE3wg== X-Received: by 10.84.198.1 with SMTP id o1mr9298061pld.33.1502005312222; Sun, 06 Aug 2017 00:41:52 -0700 (PDT) Received: from localhost.localdomain ([103.16.68.81]) by smtp.gmail.com with ESMTPSA id v11sm9166222pfl.101.2017.08.06.00.41.50 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Sun, 06 Aug 2017 00:41:51 -0700 (PDT) From: Arvind Yadav To: dmitry.torokhov@gmail.com Cc: linux-input@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH 4/8] Input: powermate: constify usb_device_id and fix space before '[' error. Date: Sun, 6 Aug 2017 13:11:23 +0530 Message-Id: <1502005287-17705-5-git-send-email-arvind.yadav.cs@gmail.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1502005287-17705-1-git-send-email-arvind.yadav.cs@gmail.com> References: <1502005287-17705-1-git-send-email-arvind.yadav.cs@gmail.com> Sender: linux-input-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-input@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP usb_device_id are not supposed to change at runtime. All functions working with usb_device_id provided by work with const usb_device_id. So mark the non-const structs as const. Fix checkpatch.pl error: ERROR: space prohibited before open square bracket '['. Signed-off-by: Arvind Yadav --- drivers/input/misc/powermate.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/input/misc/powermate.c b/drivers/input/misc/powermate.c index 84909a1..056091b 100644 --- a/drivers/input/misc/powermate.c +++ b/drivers/input/misc/powermate.c @@ -432,7 +432,7 @@ static void powermate_disconnect(struct usb_interface *intf) } } -static struct usb_device_id powermate_devices [] = { +static const struct usb_device_id powermate_devices[] = { { USB_DEVICE(POWERMATE_VENDOR, POWERMATE_PRODUCT_NEW) }, { USB_DEVICE(POWERMATE_VENDOR, POWERMATE_PRODUCT_OLD) }, { USB_DEVICE(CONTOUR_VENDOR, CONTOUR_JOG) },