From patchwork Tue Oct 9 03:03:21 2012 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Yijing Wang X-Patchwork-Id: 1567711 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 841CBDF238 for ; Tue, 9 Oct 2012 03:06:13 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751455Ab2JIDGM (ORCPT ); Mon, 8 Oct 2012 23:06:12 -0400 Received: from szxga02-in.huawei.com ([119.145.14.65]:53026 "EHLO szxga02-in.huawei.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751260Ab2JIDGL (ORCPT ); Mon, 8 Oct 2012 23:06:11 -0400 Received: from 172.24.2.119 (EHLO szxeml209-edg.china.huawei.com) ([172.24.2.119]) by szxrg02-dlp.huawei.com (MOS 4.3.4-GA FastPath queued) with ESMTP id AQG37881; Tue, 09 Oct 2012 11:04:06 +0800 (CST) Received: from SZXEML418-HUB.china.huawei.com (10.82.67.157) by szxeml209-edg.china.huawei.com (172.24.2.184) with Microsoft SMTP Server (TLS) id 14.1.323.3; Tue, 9 Oct 2012 11:03:49 +0800 Received: from localhost (10.135.76.84) by szxeml418-hub.china.huawei.com (10.82.67.157) with Microsoft SMTP Server id 14.1.323.3; Tue, 9 Oct 2012 11:03:39 +0800 From: Yijing Wang To: Bjorn Helgaas CC: , Hanjun Guo , , Yinghai Lu , Yijing Wang Subject: [PATCH 4/7] PCI, cpqphp: disable ARI forwarding for cpqphp Date: Tue, 9 Oct 2012 11:03:21 +0800 Message-ID: <1349751804-7476-5-git-send-email-wangyijing@huawei.com> X-Mailer: git-send-email 1.7.11.msysgit.1 In-Reply-To: <1349751804-7476-1-git-send-email-wangyijing@huawei.com> References: <1349751804-7476-1-git-send-email-wangyijing@huawei.com> MIME-Version: 1.0 X-Originating-IP: [10.135.76.84] X-CFilter-Loop: Reflected Sender: linux-pci-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-pci@vger.kernel.org Disable the port ARI forwarding after an ARI device hot removed. Signed-off-by: Yijing Wang --- 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;