Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S932541AbVI3C0j (ORCPT ); Thu, 29 Sep 2005 22:26:39 -0400 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S932419AbVI3C0P (ORCPT ); Thu, 29 Sep 2005 22:26:15 -0400 Received: from smtp.osdl.org ([65.172.181.4]:45482 "EHLO smtp.osdl.org") by vger.kernel.org with ESMTP id S932541AbVI3C0C (ORCPT ); Thu, 29 Sep 2005 22:26:02 -0400 Message-Id: <20050930022140.536323000@localhost.localdomain> References: <20050930022016.640197000@localhost.localdomain> Date: Thu, 29 Sep 2005 19:20:17 -0700 From: Chris Wright To: linux-kernel@vger.kernel.org, stable@kernel.org, Olaf Hering Cc: Justin Forbes , Zwane Mwaikambo , "Theodore Ts'o" , Randy Dunlap , Chuck Wolber , torvalds@osdl.org, akpm@osdl.org, alan@lxorguk.ukuu.org.uk, Ivan Kokshaysky , Andreas Koch , Marcus Wegner , Chris Wright Subject: [PATCH 01/10] [PATCH] yenta oops fix Content-Disposition: inline; filename=yenta-oops-fix.patch Sender: linux-kernel-owner@vger.kernel.org X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1824 Lines: 51 -stable review patch. If anyone has any objections, please let us know. ------------------ In some cases, especially on modern laptops with a lot of PCI and cardbus bridges, we're unable to assign correct secondary/subordinate bus numbers to all cardbus bridges due to BIOS limitations unless we are using "pci=assign-busses" boot option. So some cardbus controllers may not have attached subordinate pci_bus structure, and yenta driver must cope with it - just ignore such cardbus bridges. For example, see https://bugzilla.novell.com/show_bug.cgi?id=113778 Signed-off-by: Ivan Kokshaysky Signed-off-by: Linus Torvalds Signed-off-by: Chris Wright --- drivers/pcmcia/yenta_socket.c | 13 ++++++++++++- 1 files changed, 12 insertions(+), 1 deletion(-) Index: linux-2.6.13.y/drivers/pcmcia/yenta_socket.c =================================================================== --- linux-2.6.13.y.orig/drivers/pcmcia/yenta_socket.c +++ linux-2.6.13.y/drivers/pcmcia/yenta_socket.c @@ -976,7 +976,18 @@ static int __devinit yenta_probe (struct { struct yenta_socket *socket; int ret; - + + /* + * If we failed to assign proper bus numbers for this cardbus + * controller during PCI probe, its subordinate pci_bus is NULL. + * Bail out if so. + */ + if (!dev->subordinate) { + printk(KERN_ERR "Yenta: no bus associated with %s! " + "(try 'pci=assign-busses')\n", pci_name(dev)); + return -ENODEV; + } + socket = kmalloc(sizeof(struct yenta_socket), GFP_KERNEL); if (!socket) return -ENOMEM; -- - To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/