From patchwork Wed Jul 5 09:59: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: 9826227 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 1F4D4603B5 for ; Wed, 5 Jul 2017 09:59:44 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id EB6A320683 for ; Wed, 5 Jul 2017 09:59:43 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id DCD7927DCD; Wed, 5 Jul 2017 09:59:43 +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 78F0D20683 for ; Wed, 5 Jul 2017 09:59:43 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751696AbdGEJ7m (ORCPT ); Wed, 5 Jul 2017 05:59:42 -0400 Received: from mail-pf0-f196.google.com ([209.85.192.196]:35063 "EHLO mail-pf0-f196.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751672AbdGEJ7l (ORCPT ); Wed, 5 Jul 2017 05:59:41 -0400 Received: by mail-pf0-f196.google.com with SMTP id q85so5355613pfq.2; Wed, 05 Jul 2017 02:59:41 -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=Mm6j7+12TQ5k/2Hp9gNydqboG2628WV6gJ0L5jGftq8=; b=h1L3r26imvCNJQgKvJXvwJFMqGC/2gelalcSprpGiBSIwhjF5vl4dyL+BytNiTi3M6 7I81n3NVzC6UxWAjYZufis5OmsVXjNQ/Dk+UAbRyOvSlCMwn0TBsEGoM/PNhckAA3pkq w6dAv79tnXd1D1wEo/YMdyJJji8WXjP5jkBplWH8E3WPwtY5+Vf1Iywx6ysqgNREyNTd 3qwLeLLbc4kUpmMFFZZw9VehlLGAf9kjFsdqYg64nSEiVIwuYX9rAXK/X7ejrqHzh5YF PAT3YWzbsjWeiQYrtG04XFLKDpb84GILH7LseNDTk919zHw6AE9VHW+JUboJRZ/aZKqW 3htg== 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=Mm6j7+12TQ5k/2Hp9gNydqboG2628WV6gJ0L5jGftq8=; b=fbl9mAgPJ+H/7/nkmv0YD3AUwy23na3L4AhLV4ARNO1/YRYKt0iymtLJd8848ugPMh CtD2AOGXtAgm1lb5SbQ/F1a1SWdz7VfZ/xdgl+iIsWi0an1h8NR58VLOHxlABvftnQOY RzZvwjTGQy6ZAK98oyH9ttaexQLB/+KM7nNQ6DYYLDr2KP+4dibfMtpQkxxZkOIgNddC VYlkrnCOsMdsRXUbkwbSpR53RVoGRYQzcSxyLcObbNQVeHESPZNidgCjkpel7tXm5uKz nYMBLh9wiAzu75U7QOVK1TqdMz9RBqbmnRhqoWpBKH2n1e9EFzme5nYWLG+9ZvOHC9Gd A21Q== X-Gm-Message-State: AIVw112ip97Pv8yLr/BbDtggVCYLrmGDw0szoJEKPVlyzKiLT6lF+WJq AjQuaxpES+Hh3w== X-Received: by 10.84.149.139 with SMTP id m11mr21572449pla.138.1499248780869; Wed, 05 Jul 2017 02:59:40 -0700 (PDT) Received: from symbol-HP-Z420-Workstation.zebra.lan ([223.31.70.102]) by smtp.googlemail.com with ESMTPSA id o6sm41634142pgs.43.2017.07.05.02.59.39 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Wed, 05 Jul 2017 02:59:40 -0700 (PDT) From: Arvind Yadav To: dmitry.torokhov@gmail.com Cc: linux-input@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH] input: aiptek: constify attribute_group structures. Date: Wed, 5 Jul 2017 15:29:23 +0530 Message-Id: <4233d44c46760d064233b0d38372c62d2ac92161.1499247975.git.arvind.yadav.cs@gmail.com> 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 9941 1560 0 11501 2ced drivers/input/tablet/aiptek.o File size After adding 'const': text data bss dec hex filename 10005 1496 0 11501 2ced drivers/input/tablet/aiptek.o Signed-off-by: Arvind Yadav --- drivers/input/tablet/aiptek.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/input/tablet/aiptek.c b/drivers/input/tablet/aiptek.c index d67547b..0b55e1f 100644 --- a/drivers/input/tablet/aiptek.c +++ b/drivers/input/tablet/aiptek.c @@ -1676,7 +1676,7 @@ static ssize_t show_firmwareCode(struct device *dev, struct device_attribute *at NULL }; -static struct attribute_group aiptek_attribute_group = { +static const struct attribute_group aiptek_attribute_group = { .attrs = aiptek_attributes, };