linux-pci.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Yijing Wang <wangyijing@huawei.com>
To: Bjorn Helgaas <bhelgaas@google.com>
Cc: <jiang.liu@huawei.com>, Hanjun Guo <guohanjun@huawei.com>,
	<linux-pci@vger.kernel.org>, Yinghai Lu <yinghai@kernel.org>,
	Yijing Wang <wangyijing@huawei.com>
Subject: [PATCH 4/7] PCI, cpqphp: disable ARI forwarding for cpqphp
Date: Tue, 9 Oct 2012 11:03:21 +0800	[thread overview]
Message-ID: <1349751804-7476-5-git-send-email-wangyijing@huawei.com> (raw)
In-Reply-To: <1349751804-7476-1-git-send-email-wangyijing@huawei.com>

Disable the port ARI forwarding after an ARI device hot removed.

Signed-off-by: Yijing Wang <wangyijing@huawei.com>
---
 drivers/pci/hotplug/cpci_hotplug_pci.c |    1 +
 drivers/pci/hotplug/cpqphp_pci.c       |    1 +
 2 files changed, 2 insertions(+), 0 deletions(-)

diff --git a/drivers/pci/hotplug/cpci_hotplug_pci.c b/drivers/pci/hotplug/cpci_hotplug_pci.c
index dcc75c7..d59d228 100644
--- a/drivers/pci/hotplug/cpci_hotplug_pci.c
+++ b/drivers/pci/hotplug/cpci_hotplug_pci.c
@@ -319,6 +319,7 @@ int cpci_unconfigure_slot(struct slot* slot)
 				    PCI_DEVFN(PCI_SLOT(slot->devfn), i));
 		if (dev) {
 			pci_stop_and_remove_bus_device(dev);
+			pci_configure_ari(dev, false);
 			pci_dev_put(dev);
 		}
 	}
diff --git a/drivers/pci/hotplug/cpqphp_pci.c b/drivers/pci/hotplug/cpqphp_pci.c
index 09801c6..a818c1a 100644
--- a/drivers/pci/hotplug/cpqphp_pci.c
+++ b/drivers/pci/hotplug/cpqphp_pci.c
@@ -128,6 +128,7 @@ int cpqhp_unconfigure_device(struct pci_func* func)
 		if (temp) {
 			pci_dev_put(temp);
 			pci_stop_and_remove_bus_device(temp);
+			pci_configure_ari(temp, false);
 		}
 	}
 	return 0;
-- 
1.7.1



  parent reply	other threads:[~2012-10-09  3:06 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-10-09  3:03 [PATCH 0/7] disable bridge ari forwarding after connected ari device hot removed Yijing Wang
2012-10-09  3:03 ` [PATCH 1/7] PCI: rework pci_enable_ari for support disable ari forwarding Yijing Wang
2012-10-09  3:03 ` [PATCH 2/7] PCI, acpiphp: disable ARI forwarding for acpiphp Yijing Wang
2012-10-09  3:03 ` [PATCH 3/7] PCI, pciehp: disable ARI forwarding for pciehp Yijing Wang
2012-10-09  3:03 ` Yijing Wang [this message]
2012-10-09  3:03 ` [PATCH 5/7] PCI, shpchp: disable ARI forwarding for shpchp Yijing Wang
2012-10-09  3:03 ` [PATCH 6/7] PCI, sgi: disable ARI forwarding for sgiphp Yijing Wang
2012-10-09  3:03 ` [PATCH 7/7] PCI, ibmphp: disable ARI forwarding for ibmphp Yijing Wang
2012-10-09  3:08 ` [PATCH 0/7] disable bridge ari forwarding after connected ari device hot removed Jiang Liu
2012-10-09  3:15   ` Yijing Wang
2012-10-09  3:42 ` Jiang Liu
2012-10-09  7:42   ` Yijing Wang
2012-10-09  7:51     ` Jiang Liu
2012-10-09  8:14       ` Yijing Wang
2012-10-09  8:16         ` Jiang Liu
2012-10-09  8:47         ` Jiang Liu

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1349751804-7476-5-git-send-email-wangyijing@huawei.com \
    --to=wangyijing@huawei.com \
    --cc=bhelgaas@google.com \
    --cc=guohanjun@huawei.com \
    --cc=jiang.liu@huawei.com \
    --cc=linux-pci@vger.kernel.org \
    --cc=yinghai@kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).