From patchwork Wed Jul 5 11:34:04 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Arvind Yadav X-Patchwork-Id: 9826359 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 20F2060237 for ; Wed, 5 Jul 2017 11:34:29 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 0F7FA283FB for ; Wed, 5 Jul 2017 11:34:29 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 028A328434; Wed, 5 Jul 2017 11:34:28 +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.8 required=2.0 tests=BAYES_00, DKIM_ADSP_CUSTOM_MED, DKIM_SIGNED, FREEMAIL_FROM, RCVD_IN_DNSWL_HI, 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 95FDA283FB for ; Wed, 5 Jul 2017 11:34:28 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751637AbdGELe1 (ORCPT ); Wed, 5 Jul 2017 07:34:27 -0400 Received: from mail-pf0-f193.google.com ([209.85.192.193]:36162 "EHLO mail-pf0-f193.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750909AbdGELe0 (ORCPT ); Wed, 5 Jul 2017 07:34:26 -0400 Received: by mail-pf0-f193.google.com with SMTP id z6so35178686pfk.3; Wed, 05 Jul 2017 04:34:26 -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; bh=qbEelOLzLuFbFqRJvgcF5XwBEvI/sgm0QaV7ErGzaLY=; b=QhTGwbDD3+30nfO9RWv6Vx8O9VXI4DxAWsGboNnl7ElbK53Qn3pYWfUolReL+VufQO GDNV+ftXq6jEAwwNb8kfyvTWqDT3CatKDSdA5QOPlTjw10htYpLViiGyISMpMMLk5GRh oiHoN1OstyR/pT4wWNk1VXrv8+NfVeSmVBXZNFCvN72A50hYuAQMvUkvxFMgJSBSmZb6 U01ASeSrsaYl5p4T1X8dDNKEUnk3ZAYWjb62N1Z8PYaXVvZduzlXXI9Bi5HhUJJOI7Pk rtsyMy332KAG/KQ2KTleKlH43J/ThDQGJUQhkwQo0wtt5dDM8UHclKGCpkR91CspBE8O MKEA== 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; bh=qbEelOLzLuFbFqRJvgcF5XwBEvI/sgm0QaV7ErGzaLY=; b=RePfo07G4qSgGvHwTCx5WDkDYINxzZ+5LezIs6wshaH3kno0qrkJWCJF3CzV2QkH0X vGdkqcu4qvurjtdreCpFIfpvwjbruRS7Y2axCb927n9roWLhp2yPWnnitHhic0Z6o8no db0DtRWOXEY+oMHwSHoSzEW6KMSGfpK56mWfii4Xqu4urNTgWuVyHbTN8y3Z7URK5fKu ssL5yNNHJbtDpyAJn3xWCPMnQ2cr2+CGfrXmCtl4Mw+Ej1ajb9sEGhimQJEN3VAsuAf4 KD1gOyhAgvOEa9vWENSlQ2+U4pYDPs+hkCXxJHASPY/e99W0nBoGjkuTYfmhZ4u5sdP8 ZqcQ== X-Gm-Message-State: AIVw1120xmXz7AHYRpiGX4aEc7nySrVHZ7Rfmqdn9s/7MxFSOPB3TgJ2 +VEp0bty3e8IBg== X-Received: by 10.98.152.25 with SMTP id q25mr19619241pfd.47.1499254460726; Wed, 05 Jul 2017 04:34:20 -0700 (PDT) Received: from symbol-HP-Z420-Workstation.zebra.lan ([223.31.70.102]) by smtp.googlemail.com with ESMTPSA id r28sm56430389pfd.4.2017.07.05.04.34.18 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Wed, 05 Jul 2017 04:34:20 -0700 (PDT) From: Arvind Yadav To: dmitry.torokhov@gmail.com, linux@roeck-us.net Cc: linux-input@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH] input: raydium_i2c_ts: constify attribute_group structures. Date: Wed, 5 Jul 2017 17:04:04 +0530 Message-Id: X-Mailer: git-send-email 1.9.1 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 attribute_groups are not supposed to change at runtime. All functions working with attribute_groups provided by work with const attribute_group. So mark the non-const structs as const. File size before: text data bss dec hex filename 7801 560 0 8361 20a9 drivers/input/touchscreen/raydium_i2c_ts.o File size After adding 'const': text data bss dec hex filename 7849 496 0 8345 2099 drivers/input/touchscreen/raydium_i2c_ts.o Signed-off-by: Arvind Yadav --- drivers/input/touchscreen/raydium_i2c_ts.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/input/touchscreen/raydium_i2c_ts.c b/drivers/input/touchscreen/raydium_i2c_ts.c index 1252e49..4f1d3fd 100644 --- a/drivers/input/touchscreen/raydium_i2c_ts.c +++ b/drivers/input/touchscreen/raydium_i2c_ts.c @@ -939,7 +939,7 @@ static ssize_t raydium_i2c_calibrate_store(struct device *dev, NULL }; -static struct attribute_group raydium_i2c_attribute_group = { +static const struct attribute_group raydium_i2c_attribute_group = { .attrs = raydium_i2c_attributes, };