Fix 2.4 for pcmcia-ti-routing-9_v24.patch

Pavel Roskin proski at gnu.org
Fri May 14 21:03:11 EDT 2004


Hi, Daniel and everybody!

pcmcia-ti-routing-9_v24.patch is totally broken.  socket->probe_status is
never set to anything but 0.  yenta_probe_handler() fails always.  The
code that sets socket->probe_status to 1 in yenta_probe_handler() was lost
during backporting.

Please apply the attached patch on top of pcmcia-ti-routing-9_v24.patch.
It has been tested.  The patch can be combined with
pcmcia-ti-routing-9_v24.patch using "combinediff" from patchutils.

I believe pcmcia-ti-routing-9_v24.patch should be removed from the
website.  It cannot work for anybody.  There are direct links to that file,
and people will waste their time is they try it.

Many thanks to Warren Melnick and Jonathan Sambrook for reporting this
problem!

-- 
Regards,
Pavel Roskin
-------------- next part --------------
--- linux.orig/drivers/pcmcia/yenta.c
+++ linux/drivers/pcmcia/yenta.c
@@ -571,11 +571,16 @@ static unsigned int yenta_probe_irq(pci_
 static void yenta_probe_handler(int irq, void *dev_id, struct pt_regs *regs)
 {
 	pci_socket_t *socket = dev_id;
+	u8 csc;
+	u32 cb_event;
 
 	/* Clear interrupt status for the event */
-	cb_readl(socket, CB_SOCKET_EVENT);
+	cb_event = cb_readl(socket, CB_SOCKET_EVENT);
 	cb_writel(socket, CB_SOCKET_EVENT, -1);
-	exca_readb(socket, I365_CSC);
+	csc = exca_readb(socket, I365_CSC);
+
+	if (cb_event || csc)
+		socket->probe_status = 1;
 }
 
 /* probes the PCI interrupt, use only on override functions */


More information about the linux-pcmcia mailing list