From patchwork Wed Jul 19 05:16:55 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Arvind Yadav X-Patchwork-Id: 9850517 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 AEEC560388 for ; Wed, 19 Jul 2017 05:17:36 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 9E5FE28607 for ; Wed, 19 Jul 2017 05:17:36 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 935ED2860D; Wed, 19 Jul 2017 05:17:36 +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 4055128607 for ; Wed, 19 Jul 2017 05:17:36 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751364AbdGSFRf (ORCPT ); Wed, 19 Jul 2017 01:17:35 -0400 Received: from mail-pf0-f195.google.com ([209.85.192.195]:35071 "EHLO mail-pf0-f195.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751233AbdGSFRe (ORCPT ); Wed, 19 Jul 2017 01:17:34 -0400 Received: by mail-pf0-f195.google.com with SMTP id q85so5142541pfq.2; Tue, 18 Jul 2017 22:17:34 -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=utqkLX82yQXaQ+dRtyvOjSZeSruX0IuY/WQi2oySeoY=; b=mLf5NW8HvEsK6YrODHH+SYsjTmSdShwWEucfyIMcMRvnA10hwE0FYJEu8OXs09AI5J pJge1+tGiIR5e6gvfMdlCkusw6QIpcagVhNnF4f+bRZxbfzMTrz25oDPoPlzmTb0jwyZ bjm/QDdwO5arXQe7w5g1Sn5SXLp/uEqCasefZJoskCmkHhWfUhoJiFMmhcdiMRyoomzh 5EXhXEA0p3s/e+zuFTpZICfneGLxPcEsH+S0NpCCkg/fqviA98CKbzejj5apZ1Cta0Tb IYPWha0pa+LI7l40VzhVspXGtkuPFEKcl9ocS37OZba9rrPrpNw54M0/+mInuNM/iW5h njRQ== 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=utqkLX82yQXaQ+dRtyvOjSZeSruX0IuY/WQi2oySeoY=; b=kOTaV9hltqc+uZUsZWZQzMYFPJEZB/XAwfFHpiPI0mS7higI3pB/3TyoxjbJ6vlfMy 3x1usyBSQWT372r4y2Nb9BCSSHFjjqi6JqFFiDohLl9h8MoYzh8SEPKKMTBVgXr/tQUa ZOIcDYwQE1oKuNtY4OOGGRyjQ63NJXK8bzk2zNGtkxDGJ81ChY/l58YHYS/fmVdaljzr o/XdVkeFM8/GmHpcb23XkHPSggtHkAvOY2EbNhKnhCfOfUjx/8Xw5jta2198yii9BQ8k Wo7J8YgbD62wyd73GbZvw7Y5mECx8+iKVcip5QLvtqYAHJMIfUQy99B/upr2XoCGA4yA bVAw== X-Gm-Message-State: AIVw112D1aaROzSYkF4ysnB8D6TTnOGy9sQnVKpS+EtZQFWM9gNiCQfD dU1ll6o0S6cQxmE7kHI= X-Received: by 10.98.87.93 with SMTP id l90mr1220853pfb.3.1500441454095; Tue, 18 Jul 2017 22:17:34 -0700 (PDT) Received: from symbol-HP-Z420-Workstation.zebra.lan ([223.31.70.102]) by smtp.googlemail.com with ESMTPSA id o1sm8132064pgq.10.2017.07.18.22.17.31 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Tue, 18 Jul 2017 22:17:33 -0700 (PDT) From: Arvind Yadav To: spock@gentoo.org, b.zolnierkie@samsung.com Cc: linux-fbdev@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH] video: fbdev: uvesafb: constify attribute_group structures. Date: Wed, 19 Jul 2017 10:46:55 +0530 Message-Id: X-Mailer: git-send-email 1.9.1 Sender: linux-fbdev-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-fbdev@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP attribute_group are not supposed to change at runtime. All functions working with attribute_group provided by work with const attribute_group. So mark the non-const structs as const. File size before: text data bss dec hex filename 15426 4952 187 20565 5055 drivers/video/fbdev/uvesafb.o File size After adding 'const': text data bss dec hex filename 15490 4888 187 20565 5055 drivers/video/fbdev/uvesafb.o Signed-off-by: Arvind Yadav --- drivers/video/fbdev/uvesafb.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/video/fbdev/uvesafb.c b/drivers/video/fbdev/uvesafb.c index dc0e8d9..ad05d25f 100644 --- a/drivers/video/fbdev/uvesafb.c +++ b/drivers/video/fbdev/uvesafb.c @@ -1666,7 +1666,7 @@ static DEVICE_ATTR(nocrtc, S_IRUGO | S_IWUSR, uvesafb_show_nocrtc, NULL, }; -static struct attribute_group uvesafb_dev_attgrp = { +static const struct attribute_group uvesafb_dev_attgrp = { .name = NULL, .attrs = uvesafb_dev_attrs, };