Received: by 2002:a25:ab43:0:0:0:0:0 with SMTP id u61csp8188097ybi; Thu, 6 Jun 2019 08:06:32 -0700 (PDT) X-Google-Smtp-Source: APXvYqzKtxmOSexl7HBplmWGwi9WAR/Sa7SDBmckcWYci7Jul42aG1fqCAMYwRReW856xNiDkJvb X-Received: by 2002:a17:90a:cb09:: with SMTP id z9mr320814pjt.87.1559833592366; Thu, 06 Jun 2019 08:06:32 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1559833592; cv=none; d=google.com; s=arc-20160816; b=Py6F6+dRFfLHZwl1NxKQ8+c5cffttxmP+/OlRABRs3kwWDN6c+tlQavVbLIdA7Sf1I 63zrVopreuehEGJ2pozxci1acUSfsZQ1yxrsF7J0TGYPWuSjEeHjrtQOTSO4Y9J8DahI QIUX0BKmh5H+V7n31uQrgowOQpw0OkQUiAKn4t9jJbpHhnoy+5VbMpDqFowYz5QnX9C3 Yi0qeJK/jNDBwPYekXtVc0RAlrXaMvGnA9yys4U8H6LUd84xzbpkRc3kCcn16qZTOEhY OAiVJ3az/DQ495US6bUYhbYDCXBx85JGvISvNt4Q/nI5nXtajkyOL9hhpC9iR7rl+1Ab EmAQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:message-id:date:subject:cc:to:from; bh=Q5rTojta1Ey0Wvq6GWwGphcaQJFVMEsHUSzLakI6x7E=; b=Ht7d+0qU0a0j9UAIGaVybufVawhMwPbfS7dYq+hAxFwVsyAmKtgFA8rIN56Cer5Qom v3nquY/XmeQdqcAqZPlJovdrIALSB4eHfltUlEAdW0TPV9/sYROJAvaaYKCcpiuElr8+ kmxAatBOt2SM4cFw1ritUEXrqb0DUGiAeVGp3wgKMz8rQW/xOluRRQBANw97uJtvkZoc GEHbR96KhbWqTaCdxrmh4q5/ysi2wt5Uhw6amzaSX2/8ijA9IHsTImJB+BaZoybekbGH thzCYwtXnmjtST98vpK6EYWld8S9w5L95RxL/qHXwrsv/nj51CE2SZG3R4/5kVBGRnP2 UhSg== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id i4si2134618pfc.26.2019.06.06.08.06.14; Thu, 06 Jun 2019 08:06:32 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729071AbfFFPEu (ORCPT + 99 others); Thu, 6 Jun 2019 11:04:50 -0400 Received: from mout.kundenserver.de ([217.72.192.74]:35789 "EHLO mout.kundenserver.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727309AbfFFPEt (ORCPT ); Thu, 6 Jun 2019 11:04:49 -0400 Received: from orion.localdomain ([77.9.2.22]) by mrelayeu.kundenserver.de (mreue106 [212.227.15.183]) with ESMTPSA (Nemesis) id 1M6EKU-1hSJJ61Tya-006hc6; Thu, 06 Jun 2019 17:04:36 +0200 From: "Enrico Weigelt, metux IT consult" To: linux-kernel@vger.kernel.org Cc: khalid@gonehiking.org, jejb@linux.ibm.com, martin.petersen@oracle.com, aacraid@microsemi.com, linux-scsi@vger.kernel.org Subject: [PATCH v2] drivers: scsi: remove unnecessary #ifdef MODULE Date: Thu, 6 Jun 2019 17:04:31 +0200 Message-Id: <1559833471-30534-1-git-send-email-info@metux.net> X-Mailer: git-send-email 1.9.1 X-Provags-ID: V03:K1:S05UD3svuTQRSQq5A0hsQ3kyRKPt3nPXhYfj+2dEeHyTV1PbUr5 Nbq41ct24TRxMO8CYAr1oBuZg3I7xf6gwBoWthbAu+Y1oMnCLxpjuS6I75VXG9utqw9NGmd suEB8slTZtPvt12iW75IFe5hglpOHH2AmI+DjRV9LaKfTBIQxIqGdQu3/tPvrilEgsaSO9o mnqExZjL1l59RwRdKPsTg== X-Spam-Flag: NO X-UI-Out-Filterresults: notjunk:1;V03:K0:eIv+RsL1Bog=:vH344YMgr+N0/OansCbK4u 9zGAL55HxDTthVLbjdZWfpKyYsga4pkHOMrYtj2q11Mqwu4UsqGR1K71oXeKhE69e/v8bIprG f4jUYkWbqD8jfiqgNubRXpn8YF/xBCijJxIZJ7+ldugK3j9TnWSagHsAoNOXRagRUiVOO5WyU fSGvWIGmNa/pZqSZ225yy/6G0SXb85ZKq6+cUNhKo13qPZJschCJ3NEumXMJU9jfBWXtZZ+Ty 1UqV2dDdaA0NiaSr1bGIABpcj3rG/FVA/gFAQ+toyhvbUGPnuHOVT+eg7VlDZXYqW1GXuwRhb NUg6eJIxgqnsv8I3+p7/T+UAH9uxjhDf0RDtK9OmWGOnT7Kj5NE4GGesKPlFnCGmY3ZXGUow6 pNT/2DMI1htcZsF/bW5qd5GPRl/RV/13iIDCIAg6PeKk3hXHJdkpGNwK7vIJaPFcGSycmMWz9 4FwLzj/TiOR/3qhbbPNhWNzXVQzhq8wpVaxNqPQRefbJv2mm04IW7DxZzm22AZ9QYzvC5aZy9 3gGTgdQazHcfaBJ2mHctTRIQ4MMiM58LJs9JGtimuKKQhVG7ikjKF4cCYAwGOu7HE0Y0hkvcH gQGgvdVT4koUihW7Moo/oTNqHJaAi8Gqy1CZ6rdvYlUnEtNsz85Jo2HgWLUX3ke3uba0uCzs1 V3pZCadxMv2clZkJg1oNyaTUkL2kQihc4lF5RbA+7OHN3kWowqJCwMlJnWIR4qPvKaVdax179 poRu/ygzn0HKhghMeLIbUgV5qb2c9TZlZl0gVzHA3XFoiGCe5TJ44aCkaDs= Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Enrico Weigelt The MODULE_DEVICE_TABLE() macro already checks for MODULE defined, so the extra check here is not necessary. Changes v2: * make dptids const to fix warning on unused variable Signed-off-by: Enrico Weigelt --- drivers/scsi/BusLogic.c | 2 -- drivers/scsi/dpt_i2o.c | 5 +---- 2 files changed, 1 insertion(+), 6 deletions(-) diff --git a/drivers/scsi/BusLogic.c b/drivers/scsi/BusLogic.c index e41e51f..68cc68b 100644 --- a/drivers/scsi/BusLogic.c +++ b/drivers/scsi/BusLogic.c @@ -3893,7 +3893,6 @@ static void __exit blogic_exit(void) __setup("BusLogic=", blogic_setup); -#ifdef MODULE /*static struct pci_device_id blogic_pci_tbl[] = { { PCI_VENDOR_ID_BUSLOGIC, PCI_DEVICE_ID_BUSLOGIC_MULTIMASTER, PCI_ANY_ID, PCI_ANY_ID, 0, 0, 0}, @@ -3909,7 +3908,6 @@ static void __exit blogic_exit(void) {PCI_DEVICE(PCI_VENDOR_ID_BUSLOGIC, PCI_DEVICE_ID_BUSLOGIC_FLASHPOINT)}, {0, }, }; -#endif MODULE_DEVICE_TABLE(pci, blogic_pci_tbl); module_init(blogic_init); diff --git a/drivers/scsi/dpt_i2o.c b/drivers/scsi/dpt_i2o.c index abc74fd..162d56a 100644 --- a/drivers/scsi/dpt_i2o.c +++ b/drivers/scsi/dpt_i2o.c @@ -177,14 +177,11 @@ static u8 adpt_read_blink_led(adpt_hba* host) *============================================================================ */ -#ifdef MODULE -static struct pci_device_id dptids[] = { +static const struct pci_device_id dptids[] = { { PCI_DPT_VENDOR_ID, PCI_DPT_DEVICE_ID, PCI_ANY_ID, PCI_ANY_ID,}, { PCI_DPT_VENDOR_ID, PCI_DPT_RAPTOR_DEVICE_ID, PCI_ANY_ID, PCI_ANY_ID,}, { 0, } }; -#endif - MODULE_DEVICE_TABLE(pci,dptids); static int adpt_detect(struct scsi_host_template* sht) -- 1.9.1