public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Mark Lord <lkml@rtr.ca>
To: kristen.c.accardi@intel.com, linux-kernel@vger.kernel.org,
	Andrew Morton <akpm@linux-foundation.org>
Cc: Alex Chiang <achiang@hp.com>, Linus Torvalds <torvalds@osdl.org>,
	Greg KH <gregkh@suse.de>
Subject: [PATCH] pciehp dont enable slot unless forced
Date: Mon, 17 Mar 2008 16:04:23 -0400	[thread overview]
Message-ID: <47DECEC7.6070005@rtr.ca> (raw)
In-Reply-To: <20080317195317.GE6808@ldl.fc.hp.com>

This fixes a 2.6.25 regression reported by Alex Chiang.

Invoke pciehp_enable_slot() at startup only when pciehp_force=1.
Some HP equipment apparently cannot cope with it otherwise.

This restores the (previously working) 2.6.24 behaviour here,
while allowing machines that need a kick to use pciehp_force=1.

This was the original design back in October 2007,
but Kristen suggested we try without it first:

   Kristen Carlson Accardi wrote:
   >I think it would be ok to try allowing the slot to be enabled when not
   >using pciehp_force mode.  We can wrap it later if it proves to break things

This ended up breaking one of Alex's setups,
so it's time to put the wrapper back in now.

Signed-off-by: Mark Lord <mlord@pobox.com>
Acked-by: Alex Chiang <achiang@hp.com>
---

--- old/drivers/pci/hotplug/pciehp_core.c	2008-03-12 13:21:46.000000000 -0400
+++ linux/drivers/pci/hotplug/pciehp_core.c	2008-03-12 13:23:54.000000000 -0400
@@ -467,7 +467,7 @@
 	t_slot = pciehp_find_slot(ctrl, ctrl->slot_device_offset);
 
 	t_slot->hpc_ops->get_adapter_status(t_slot, &value); /* Check if slot is occupied */
-	if (value) {
+	if (value && pciehp_force) {
 		rc = pciehp_enable_slot(t_slot);
 		if (rc)	/* -ENODEV: shouldn't happen, but deal with it */
 			value = 0;

  reply	other threads:[~2008-03-17 20:06 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-03-12  6:47 [regression] pciehp hang on hp ia64 rx6600 Alex Chiang
2008-03-12 17:12 ` Mark Lord
2008-03-12 17:34 ` Mark Lord
2008-03-17 19:53   ` Alex Chiang
2008-03-17 20:04     ` Mark Lord [this message]
2008-03-17 21:13       ` [PATCH] pciehp dont enable slot unless forced Kristen Carlson Accardi

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=47DECEC7.6070005@rtr.ca \
    --to=lkml@rtr.ca \
    --cc=achiang@hp.com \
    --cc=akpm@linux-foundation.org \
    --cc=gregkh@suse.de \
    --cc=kristen.c.accardi@intel.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=torvalds@osdl.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