linux-pci.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Yinghai Lu <yinghai@kernel.org>
To: Bjorn Helgaas <bhelgaas@google.com>,
	"Rafael J. Wysocki" <rjw@sisk.pl>,
	Huang Ying <ying.huang@intel.com>
Cc: David Bulkow <David.Bulkow@stratus.com>,
	Kenji Kaneshige <kaneshige.kenji@jp.fujitsu.com>,
	linux-pci@vger.kernel.org, linux-kernel@vger.kernel.org,
	Yinghai Lu <yinghai@kernel.org>
Subject: [PATCH] PCI: Remove duplicate pci_disable_device for pcie port
Date: Thu, 25 Apr 2013 18:47:00 -0700	[thread overview]
Message-ID: <1366940820-15302-1-git-send-email-yinghai@kernel.org> (raw)
In-Reply-To: <5AA430FFE4486C448003201AC83BC85E03DEA483@EXHQ.corp.stratus.com>

During chasing one PCI xHCI hotplug problem, David Bulkow found

	static void pcie_portdrv_remove(struct pci_dev *dev)
	{
        	pcie_port_device_remove(dev);
	        pci_disable_device(dev);
	}
and
	void pcie_port_device_remove(struct pci_dev *dev)
	{
        	device_for_each_child(&dev->dev, NULL, remove_iter);
	        cleanup_service_irqs(dev);
	        pci_disable_device(dev);
	}

that extra pci_disable_device in pcie_port_device_remove() was added by
| commit dc5351784eb36f1fec4efa88e01581be72c0b711
| Author: Kenji Kaneshige <kaneshige.kenji@jp.fujitsu.com>
| Date:   Wed Nov 25 21:04:00 2009 +0900
|
|    PCI: portdrv: cleanup service irqs initialization

so pci_dsiable_device is called two times.

We should remove extra one in pcie_portdrv_remove.

Reported-by: David Bulkow <David.Bulkow@stratus.com>
Signed-off-by: Yinghai Lu <yinghai@kernel.org>

---
 drivers/pci/pcie/portdrv_pci.c |    1 -
 1 file changed, 1 deletion(-)

Index: linux-2.6/drivers/pci/pcie/portdrv_pci.c
===================================================================
--- linux-2.6.orig/drivers/pci/pcie/portdrv_pci.c
+++ linux-2.6/drivers/pci/pcie/portdrv_pci.c
@@ -223,7 +223,6 @@ static int pcie_portdrv_probe(struct pci
 static void pcie_portdrv_remove(struct pci_dev *dev)
 {
 	pcie_port_device_remove(dev);
-	pci_disable_device(dev);
 }
 
 static int error_detected_iter(struct device *device, void *data)

  reply	other threads:[~2013-04-26  1:47 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <5AA430FFE4486C448003201AC83BC85E01F83F0D@EXHQ.corp.stratus.com>
2013-04-15 18:26 ` USB PCI quirk issue Sarah Sharp
2013-04-15 20:41   ` Yinghai Lu
2013-04-16 20:17     ` Bulkow, David
     [not found]       ` <5AA430FFE4486C448003201AC83BC85E01F83F13@EXHQ.corp.stratus.com>
2013-04-24 17:08         ` Yinghai Lu
2013-04-24 18:32           ` Bulkow, David
2013-04-26  1:47             ` Yinghai Lu [this message]
2013-04-26  4:02               ` [PATCH] PCI: Remove duplicate pci_disable_device for pcie port Yijing Wang
2013-04-26  6:20                 ` Yinghai Lu
2013-04-26  9:41                   ` Yijing Wang
2013-04-26  1:47       ` [PATCH] PCI: move down pci_fixup_final for hotplug path Yinghai Lu
2013-05-07 21:32         ` Bjorn Helgaas
2013-05-07 21:38           ` Bjorn Helgaas
2013-05-07 22:36             ` Yinghai Lu

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=1366940820-15302-1-git-send-email-yinghai@kernel.org \
    --to=yinghai@kernel.org \
    --cc=David.Bulkow@stratus.com \
    --cc=bhelgaas@google.com \
    --cc=kaneshige.kenji@jp.fujitsu.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-pci@vger.kernel.org \
    --cc=rjw@sisk.pl \
    --cc=ying.huang@intel.com \
    /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).