From patchwork Mon Jul 17 18:09:50 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Arvind Yadav X-Patchwork-Id: 9845907 X-Patchwork-Delegate: kvalo@adurom.com 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 5476360386 for ; Mon, 17 Jul 2017 18:13:26 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 4B12328515 for ; Mon, 17 Jul 2017 18:13:26 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 400D02851E; Mon, 17 Jul 2017 18:13:26 +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.5 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, FREEMAIL_FROM, RCVD_IN_DNSWL_HI, RCVD_IN_SORBS_SPAM autolearn=unavailable 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 EF76828515 for ; Mon, 17 Jul 2017 18:13:25 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751516AbdGQSMj (ORCPT ); Mon, 17 Jul 2017 14:12:39 -0400 Received: from mail-pg0-f68.google.com ([74.125.83.68]:33941 "EHLO mail-pg0-f68.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751366AbdGQSKO (ORCPT ); Mon, 17 Jul 2017 14:10:14 -0400 Received: by mail-pg0-f68.google.com with SMTP id v190so6506134pgv.1; Mon, 17 Jul 2017 11:10: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=jh3puUuSql7pDUunDdCHV2MrtABlhwT7BtbNySuif+Y=; b=q8ZLGvOT2KGAzWv6gVujnSTgfNRhUaaZtOcpS1lm8rYcVtAm2XMgxkvUIGbmOXPIkT i7db8J84vID/vfdq24xcvbjczAS3r7P/eiqFZBziIs0UHErZg1u3pSeAIboyGwW7x2WN ORWdVYJXd2RolC2FYUKKT2lBb6TvXSsihCnBm905qYtXtHrRyAyFQ3GIUWTcGQPq4+6Z 2Zd206RzEZiCPZcsiCWuEdh9PPPAcAvtu6j+LQYxWFF7ep4uo/QP2XPOGz9Oa2+z1rI4 vEZFXyOs3EzqfPpbJrAKd5d3jOytZ6tb0aFpu0L1/uH+QutplD9xsarPw/tdVgBTcKsi PZEg== 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=jh3puUuSql7pDUunDdCHV2MrtABlhwT7BtbNySuif+Y=; b=CCu86+WLIRGDC5cwHCD4iNK+OaEVkjNoryu6LjS1jCnpeY3wTI+GUH2NAqM5wX1Jwj xHogzERonKzohAZBoy9PNaLOIWqssNOY4gKwWAGWcTuv0Z6S8XLg9vlH2YFNS0ci4PWU 5Nb4L400r9CKqaTLR5ZsdKWbvUbVxEoW68zNWASVK9f/SDnY1gRArS1liShOa/Se2MuX 6pahsE6KySAdbdDE4aEDUS3nJ/l9O2THHERPznltbG/vGP+IUw2EEWkYn5+GbfV9NUGZ j0J8F2MvYY36cRVXBhhMH5ApVir4k6FAUHbpeSvRzGJaOZCP1E9EATaw3DjqhvyyA+ou 9oCg== X-Gm-Message-State: AIVw113Vu5l5hlMIqfnVMLUZjKjMGlVg7nBJ7S52LaRCQUYRIEqmEUyO sCkML+6yOGwHxA== X-Received: by 10.84.217.208 with SMTP id d16mr3966209plj.208.1500315013398; Mon, 17 Jul 2017 11:10:13 -0700 (PDT) Received: from localhost.localdomain ([103.16.70.163]) by smtp.gmail.com with ESMTPSA id m8sm12316823pgs.24.2017.07.17.11.10.11 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Mon, 17 Jul 2017 11:10:12 -0700 (PDT) From: Arvind Yadav To: Larry.Finger@lwfinger.net, chaoming_li@realsil.com.cn, kvalo@codeaurora.org Cc: linux-wireless@vger.kernel.org, netdev@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH 02/11] rtlwifi: rtl8192se: constify pci_device_id. Date: Mon, 17 Jul 2017 23:39:50 +0530 Message-Id: <1500314995-3181-3-git-send-email-arvind.yadav.cs@gmail.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1500314995-3181-1-git-send-email-arvind.yadav.cs@gmail.com> References: <1500314995-3181-1-git-send-email-arvind.yadav.cs@gmail.com> Sender: linux-wireless-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-wireless@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 2817 1040 0 3857 f11 realtek/rtlwifi/rtl8192se/sw.o File size After adding 'const': text data bss dec hex filename 3009 848 0 3857 f11 realtek/rtlwifi/rtl8192se/sw.o Signed-off-by: Arvind Yadav --- drivers/net/wireless/realtek/rtlwifi/rtl8192se/sw.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/net/wireless/realtek/rtlwifi/rtl8192se/sw.c b/drivers/net/wireless/realtek/rtlwifi/rtl8192se/sw.c index 2006b09..201100e 100644 --- a/drivers/net/wireless/realtek/rtlwifi/rtl8192se/sw.c +++ b/drivers/net/wireless/realtek/rtlwifi/rtl8192se/sw.c @@ -396,7 +396,7 @@ static const struct rtl_hal_cfg rtl92se_hal_cfg = { .maps[RTL_RC_HT_RATEMCS15] = DESC_RATEMCS15, }; -static struct pci_device_id rtl92se_pci_ids[] = { +static const struct pci_device_id rtl92se_pci_ids[] = { {RTL_PCI_DEVICE(PCI_VENDOR_ID_REALTEK, 0x8192, rtl92se_hal_cfg)}, {RTL_PCI_DEVICE(PCI_VENDOR_ID_REALTEK, 0x8171, rtl92se_hal_cfg)}, {RTL_PCI_DEVICE(PCI_VENDOR_ID_REALTEK, 0x8172, rtl92se_hal_cfg)},