From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-pb0-f46.google.com ([209.85.160.46]:65282 "EHLO mail-pb0-f46.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1756458Ab2IQOWx (ORCPT ); Mon, 17 Sep 2012 10:22:53 -0400 Message-ID: <50573232.9080508@gmail.com> Date: Mon, 17 Sep 2012 22:22:42 +0800 From: Jiang Liu MIME-Version: 1.0 To: Yinghai Lu CC: Bjorn Helgaas , Len Brown , Tony Luck , Jiang Liu , Kenji Kaneshige , Yijing Wang , linux-kernel@vger.kernel.org, linux-pci@vger.kernel.org, linux-acpi@vger.kernel.org Subject: Re: [PATCH v2 5/9] ACPI/pci-bind: remove bind/unbind callbacks from acpi_device_ops References: <1347678312-11124-1-git-send-email-jiang.liu@huawei.com> <1347678312-11124-6-git-send-email-jiang.liu@huawei.com> In-Reply-To: Content-Type: text/plain; charset=ISO-8859-1 Sender: linux-pci-owner@vger.kernel.org List-ID: On 09/17/2012 11:03 AM, Yinghai Lu wrote: > On Sat, Sep 15, 2012 at 4:27 PM, Yinghai Lu wrote: >> On Fri, Sep 14, 2012 at 8:05 PM, Jiang Liu wrote: >>> From: Jiang Liu >>> >>> Now ACPI devices are created before/destroyed after corresponding PCI >>> devices, and acpi_platform_notify/acpi_platform_notify_remove will >>> update PCI<->ACPI binding relationship when creating/destroying PCI >>> devices, there's no need to invoke bind/unbind callbacks from ACPI >>> device probe/destroy routines anymore. So remove bind/unbind callbacks >>> from acpi_device_ops. >> for pci root bus, acpi_bus_trim() is used to remove acpi_device. >> >> and later in acpi_pci_root_remove to stop pci drivers/ioapic driver, >> iommu driver then remove pci devices. >> >> if call back is removed there, then could some functions in >> acpi_pci_unbind() will be skipped. >> >> I really do not want to add pci_stop_bus_devices() in >> pci_root_hp.c::handle_root_bridge_removal before >> calling acpi_bus_trim... > > FYI, I solved the problem. will call apci_bus_remove() two times. it > will make sure pci devices > get removed at first before acpi devices... Hi Yinghai, Great! So we could remove the acpi<->PCI logic now. Thanks! Gerry