From patchwork Thu Jul 20 17:39:27 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Arvind Yadav X-Patchwork-Id: 9855407 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 0B25A600F5 for ; Thu, 20 Jul 2017 17:40:19 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id EA1642883D for ; Thu, 20 Jul 2017 17:40:18 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id DC80928842; Thu, 20 Jul 2017 17:40:18 +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 7BB2D2883D for ; Thu, 20 Jul 2017 17:40:18 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S934794AbdGTRkQ (ORCPT ); Thu, 20 Jul 2017 13:40:16 -0400 Received: from mail-pg0-f66.google.com ([74.125.83.66]:35041 "EHLO mail-pg0-f66.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S965901AbdGTRkN (ORCPT ); Thu, 20 Jul 2017 13:40:13 -0400 Received: by mail-pg0-f66.google.com with SMTP id d193so3307339pgc.2; Thu, 20 Jul 2017 10:40:13 -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=hHgNc1SLGGIojqsSmDrk0d4kRRcP+t9gmajJJ9vcqpg=; b=s8jnoaiLn7i7Miq4mxPpDpe4PgRI8TcZZg/2aQ/cSKPbCEwadxA50e1Nwze2K3WvMp PmTwwENf6WRj14iBoEXbkCHW+FKppw54mwbTk4p6nUMzYvCU3hP9o1br99VIXKz2vmeB TlxUZDoMG9bZU73jzsv0SYHzS3mgfniK+yPqzjMwn1zvHj9Gc0TBC9GATTXKYBx5KVns mjEj6VLUC3HTpnCZx3LDdl+A+ygpN5Ttc03XGsrEsZ2euGeW9LsYtXdK9mWbCanUldMS mGlXrIhN8q30oMK1TEgB8vshjtFlGnUi1U+iTERIvskXj/mMNt/d/iur7hYmaJQraSgF EeZw== 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=hHgNc1SLGGIojqsSmDrk0d4kRRcP+t9gmajJJ9vcqpg=; b=iJqBkOLJQxjMEA6MhCKtDdmBeMotRA74l5wPzVo1Rs8ShNFb45E/mLSCXFV+wnsMeC ANEhFhQr9o/AEWDh8xkvWNz0gajo/lVf81iNlr2TrKRILz6AB95a2zWvD/h9qSS4o6D8 bWeNrc9eLcThUFT0ITPK0uiS0nL1ersozSssHDBjqTFXCKrvGbu1MJ0U3O//N4pyN2UM s/tBh52AAJLwBWtGuePXLNSHP6py9px4l1CnUAAuNMB3Waf04ydHWbpdZ9CmYSjQXvtn GlTnvmUw3fONMRTqe+Bav0UWiEpXZhvV5yPXVoBcoMus+UhLD8jUV21uzx+Iat1Nzt4o iBrA== X-Gm-Message-State: AIVw112TysJ+YqVgbw5YYiSIwzfTEbTdaM859b+xUzb3kIsGftYPTsKi 7uh+CUku7drBSg== X-Received: by 10.84.131.165 with SMTP id d34mr5019646pld.317.1500572412771; Thu, 20 Jul 2017 10:40:12 -0700 (PDT) Received: from localhost.localdomain ([103.16.70.17]) by smtp.gmail.com with ESMTPSA id n90sm6315528pfk.105.2017.07.20.10.40.09 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Thu, 20 Jul 2017 10:40:11 -0700 (PDT) From: Arvind Yadav To: b.zolnierkie@samsung.com, paulus@samba.org, benh@kernel.crashing.org, adaplas@gmail.com, mbroemme@libmpq.org, FlorianSchandinat@gmx.de Cc: linux-fbdev@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH 02/28] video: fbdev: atyfb: constify pci_device_id. Date: Thu, 20 Jul 2017 23:09:27 +0530 Message-Id: <1500572393-18844-3-git-send-email-arvind.yadav.cs@gmail.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1500572393-18844-1-git-send-email-arvind.yadav.cs@gmail.com> References: <1500572393-18844-1-git-send-email-arvind.yadav.cs@gmail.com> 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 pci_device_id are not supposed to change at runtime. All functions working with pci_device_id provided by work with const pci_device_id. So mark the non-const structs as const. File size before: text data bss dec hex filename 17534 1824 48 19406 4bce video/fbdev/aty/atyfb_base.o File size After adding 'const': text data bss dec hex filename 18686 672 48 19406 4bce video/fbdev/aty/atyfb_base.o Signed-off-by: Arvind Yadav --- drivers/video/fbdev/aty/atyfb_base.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/video/fbdev/aty/atyfb_base.c b/drivers/video/fbdev/aty/atyfb_base.c index 11026e7..d38cfc6 100644 --- a/drivers/video/fbdev/aty/atyfb_base.c +++ b/drivers/video/fbdev/aty/atyfb_base.c @@ -3762,7 +3762,7 @@ static void atyfb_pci_remove(struct pci_dev *pdev) atyfb_remove(info); } -static struct pci_device_id atyfb_pci_tbl[] = { +static const struct pci_device_id atyfb_pci_tbl[] = { #ifdef CONFIG_FB_ATY_GX { PCI_DEVICE(PCI_VENDOR_ID_ATI, PCI_CHIP_MACH64GX) }, { PCI_DEVICE(PCI_VENDOR_ID_ATI, PCI_CHIP_MACH64CX) },