From patchwork Mon Apr 22 23:11:54 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Bjorn Helgaas X-Patchwork-Id: 2474911 X-Patchwork-Delegate: bhelgaas@google.com Return-Path: X-Original-To: patchwork-linux-pci@patchwork.kernel.org Delivered-To: patchwork-process-083081@patchwork2.kernel.org Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by patchwork2.kernel.org (Postfix) with ESMTP id C6CAFDF23A for ; Mon, 22 Apr 2013 23:11:57 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753851Ab3DVXL5 (ORCPT ); Mon, 22 Apr 2013 19:11:57 -0400 Received: from mail-ia0-f175.google.com ([209.85.210.175]:52038 "EHLO mail-ia0-f175.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753063Ab3DVXL4 (ORCPT ); Mon, 22 Apr 2013 19:11:56 -0400 Received: by mail-ia0-f175.google.com with SMTP id i38so11563iae.6 for ; Mon, 22 Apr 2013 16:11:56 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=x-received:subject:to:from:cc:date:message-id:in-reply-to :references:user-agent:mime-version:content-type :content-transfer-encoding; bh=KnoLaymn4G0/pfU/Xx/uG5HgqOJ8ONbt4v50JTsiDJs=; b=cylv27rgTkorXALBFmkkDuSS9uIQrmy+HLEyVNZ4/iiMe6UsHRSbFw0GrR/Mh5kBjC 6DJizCfdFaulQhAY6PRNBTO7KCMY71fsCovCp/ihUxdtFOI5SkX7s53Pf9l3AUABDQRr 165sD1BFsVA0imAhcPy2kNyChBOCZewa348AV+TBLBx1ZaZ2lja19ehsz2QFZiHf+ke4 BuJLKdhSo6Ujjam8WRv2gVcYJhmPX7KztMbiMWz6+JmTq2z9Jw/G6gsh30FAC+uhUWC0 qH1lj2toU6ZJBJ1pUliKjDBCy3ULhqZ748Sh0dsjoH/hsPBdJIbESo6bdrz2Pf39k9yj t53Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=x-received:subject:to:from:cc:date:message-id:in-reply-to :references:user-agent:mime-version:content-type :content-transfer-encoding:x-gm-message-state; bh=KnoLaymn4G0/pfU/Xx/uG5HgqOJ8ONbt4v50JTsiDJs=; b=HjHWaklzj2ZMT2Fq/kyWjnJrVcTRFw1zYV1vsEI2vZ3+JmFBQPol89//RwkazjX9rX RPiNFM/L090h7Q1fYe8ZnsQqhDNY+ijGiKcDqNnhnfzD3p5p/TfdDG/Y4uB25hQ6HwEb 8l6KJkW0mbN/IEqVD0+PsTbDFam7fkTGi3ASsEuEmwdZEBOCcX5w/wetJcLd0k50LbQy pesI5DTNaa+Nrn3H+YOeXpMQrXU0jF3Z90Zh174hXQ7bVtZttrQ69tsErAGPUdDbTnI9 kliZADy+QviT7nGSdLJa9NTeewBhZToRoGVyEUChWB7SRg2CjpyNqXycyXDYqnA38cRb /qIA== X-Received: by 10.50.49.66 with SMTP id s2mr22182741ign.13.1366672316240; Mon, 22 Apr 2013 16:11:56 -0700 (PDT) Received: from localhost ([172.29.120.215]) by mx.google.com with ESMTPSA id xc3sm17852225igb.10.2013.04.22.16.11.55 for (version=TLSv1.2 cipher=RC4-SHA bits=128/128); Mon, 22 Apr 2013 16:11:55 -0700 (PDT) Subject: [PATCH v4 15/22] PCI: Drop msi_mask_reg() and remove drivers/pci/msi.h To: linux-pci@vger.kernel.org From: Bjorn Helgaas Cc: Gavin Shan Date: Mon, 22 Apr 2013 17:11:54 -0600 Message-ID: <20130422231154.32621.3444.stgit@bhelgaas-glaptop> In-Reply-To: <20130422230012.32621.15224.stgit@bhelgaas-glaptop> References: <20130422230012.32621.15224.stgit@bhelgaas-glaptop> User-Agent: StGit/0.15 MIME-Version: 1.0 X-Gm-Message-State: ALoCoQlJb6yUe/ds1is11lCrxr6NMCzhYTr0ikHo1ttrYAWKMR9E2S6OLl8qciXXnBkuedWV0AWWYbU9t8Yj8s5EvK05wspBxcmFDoGmYcIgPxq7Auhz6DjM1TJixiSvB6JUC61BV2oAYl43P17h4EHaIw3tm6dMRNHFKJIJn9Y/POaLIMfVFQLNV4mxTaSYgNJwaG7oWmTbGC5lIbPllGRvp6hxP0tzcy9GpvJRbzW3SbUc28VFaVo= Sender: linux-pci-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-pci@vger.kernel.org msi_mask_reg() doesn't provide any useful abstraction, do drop it. Remove the now-empty drivers/pci/msi.h. Signed-off-by: Bjorn Helgaas --- drivers/pci/msi.c | 4 ++-- drivers/pci/msi.h | 12 ------------ 2 files changed, 2 insertions(+), 14 deletions(-) delete mode 100644 drivers/pci/msi.h -- To unsubscribe from this list: send the line "unsubscribe linux-pci" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html diff --git a/drivers/pci/msi.c b/drivers/pci/msi.c index 06c5f6e..afdc388 100644 --- a/drivers/pci/msi.c +++ b/drivers/pci/msi.c @@ -22,7 +22,6 @@ #include #include "pci.h" -#include "msi.h" static int pci_msi_enable = 1; @@ -564,7 +563,8 @@ static int msi_capability_init(struct pci_dev *dev, int nvec) entry->msi_attrib.default_irq = dev->irq; /* Save IOAPIC IRQ */ entry->msi_attrib.pos = dev->msi_cap; - entry->mask_pos = msi_mask_reg(dev->msi_cap, entry->msi_attrib.is_64); + entry->mask_pos = dev->msi_cap + (control & PCI_MSI_FLAGS_64BIT) ? + PCI_MSI_MASK_64 : PCI_MSI_MASK_32; /* All MSIs are unmasked by default, Mask them all */ if (entry->msi_attrib.maskbit) pci_read_config_dword(dev, entry->mask_pos, &entry->masked); diff --git a/drivers/pci/msi.h b/drivers/pci/msi.h deleted file mode 100644 index df12830..0000000 --- a/drivers/pci/msi.h +++ /dev/null @@ -1,12 +0,0 @@ -/* - * Copyright (C) 2003-2004 Intel - * Copyright (C) Tom Long Nguyen (tom.l.nguyen@intel.com) - */ - -#ifndef MSI_H -#define MSI_H - -#define msi_mask_reg(base, is64bit) \ - (base + ((is64bit == 1) ? PCI_MSI_MASK_64 : PCI_MSI_MASK_32)) - -#endif /* MSI_H */