From patchwork Sun Mar 29 15:04:34 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Michael S. Tsirkin" X-Patchwork-Id: 6117391 X-Patchwork-Delegate: bhelgaas@google.com Return-Path: X-Original-To: patchwork-linux-pci@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork1.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.136]) by patchwork1.web.kernel.org (Postfix) with ESMTP id A7B919F32E for ; Sun, 29 Mar 2015 15:09:50 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id DD7AD20295 for ; Sun, 29 Mar 2015 15:09:49 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 41BFC202BE for ; Sun, 29 Mar 2015 15:09:48 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752774AbbC2PJr (ORCPT ); Sun, 29 Mar 2015 11:09:47 -0400 Received: from mx1.redhat.com ([209.132.183.28]:60921 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752743AbbC2PJq (ORCPT ); Sun, 29 Mar 2015 11:09:46 -0400 Received: from int-mx13.intmail.prod.int.phx2.redhat.com (int-mx13.intmail.prod.int.phx2.redhat.com [10.5.11.26]) by mx1.redhat.com (8.14.4/8.14.4) with ESMTP id t2TF4c8O018972 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=FAIL); Sun, 29 Mar 2015 11:04:38 -0400 Received: from redhat.com (ovpn-116-29.ams2.redhat.com [10.36.116.29]) by int-mx13.intmail.prod.int.phx2.redhat.com (8.14.4/8.14.4) with SMTP id t2TF4ZBG030188; Sun, 29 Mar 2015 11:04:36 -0400 Date: Sun, 29 Mar 2015 17:04:34 +0200 From: "Michael S. Tsirkin" To: linux-kernel@vger.kernel.org Cc: Bjorn Helgaas , linux-pci@vger.kernel.org, Fam Zheng , Yinghai Lu , Yijing Wang Subject: [PATCH v5 10/10] pci: unexport pci_msi_off Message-ID: <1427641227-7574-11-git-send-email-mst@redhat.com> References: <1427641227-7574-1-git-send-email-mst@redhat.com> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: <1427641227-7574-1-git-send-email-mst@redhat.com> X-Mutt-Fcc: =sent X-Scanned-By: MIMEDefang 2.68 on 10.5.11.26 Sender: linux-pci-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-pci@vger.kernel.org X-Spam-Status: No, score=-6.9 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_HI, T_RP_MATCHES_RCVD, UNPARSEABLE_RELAY autolearn=unavailable version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP Now one should be using pci_msi_off now, unexport it and move the declaration to internal header to prevent misuse. Signed-off-by: Michael S. Tsirkin --- drivers/pci/pci.h | 2 ++ include/linux/pci.h | 1 - drivers/pci/pci.c | 2 +- 3 files changed, 3 insertions(+), 2 deletions(-) diff --git a/drivers/pci/pci.h b/drivers/pci/pci.h index 17f213d..620fcad 100644 --- a/drivers/pci/pci.h +++ b/drivers/pci/pci.h @@ -146,6 +146,8 @@ static inline void pci_no_msi(void) { } static inline void pci_msi_init_pci_dev(struct pci_dev *dev) { } #endif +void pci_msi_off(struct pci_dev *dev); + static inline void pci_msi_set_enable(struct pci_dev *dev, int enable) { u16 control; diff --git a/include/linux/pci.h b/include/linux/pci.h index a34df45..ef15f91 100644 --- a/include/linux/pci.h +++ b/include/linux/pci.h @@ -970,7 +970,6 @@ void pci_intx(struct pci_dev *dev, int enable); bool pci_intx_mask_supported(struct pci_dev *dev); bool pci_check_and_mask_intx(struct pci_dev *dev); bool pci_check_and_unmask_intx(struct pci_dev *dev); -void pci_msi_off(struct pci_dev *dev); int pci_set_dma_max_seg_size(struct pci_dev *dev, unsigned int size); int pci_set_dma_seg_boundary(struct pci_dev *dev, unsigned long mask); int pci_wait_for_pending(struct pci_dev *dev, int pos, u16 mask); diff --git a/drivers/pci/pci.c b/drivers/pci/pci.c index fcee8ea..54cefb4 100644 --- a/drivers/pci/pci.c +++ b/drivers/pci/pci.c @@ -3103,6 +3103,7 @@ EXPORT_SYMBOL_GPL(pci_check_and_unmask_intx); * If you want to use MSI, see pci_enable_msi() and friends. * This is a lower-level primitive that allows us to disable * MSI operation at the device level. + * Not for use by drivers. */ void pci_msi_off(struct pci_dev *dev) { @@ -3112,7 +3113,6 @@ void pci_msi_off(struct pci_dev *dev) if (dev->msix_cap) pci_msix_clear_and_set_ctrl(dev, PCI_MSIX_FLAGS_ENABLE, 0); } -EXPORT_SYMBOL_GPL(pci_msi_off); int pci_set_dma_max_seg_size(struct pci_dev *dev, unsigned int size) {