Hello,
Benjamin Herrenschmidt sent me the following to patches to 2.3.99pre3
to try on my G4 today. I manually applied them to the 2.3.99pre3
linux-pmac-devel kernel sources (which are 2.3.99pre3 with some of
the more recent usb patches). The first of these two patches seems
to eliminate the kernel faults on the G4. The second seems okay as
well in concert with the first. Unfortunately the linux-pmac-devel
kernel seems to have some ext2 filesystem issues since my boot stopped
with a problem reading the superblock on the ext2 volume. However I
was able to use my usb keyboard to login as root at the emergency
prompt so I think usb is usable now on the G4. Below are the two
patches that Ben sent me that did the trick.
diff -Naur -X dontdiff linux-2.3.99-pre3-8/drivers/usb/usb-ohci.c
linux-2.3.99-pre3-8-greg/drivers/usb/usb-ohci.c
--- linux-2.3.99-pre3-8/drivers/usb/usb-ohci.c Thu Mar 23 14:22:09 2000
+++ linux-2.3.99-pre3-8-greg/drivers/usb/usb-ohci.c Thu Mar 23 14:50:31 2000@@
+-339,10 +339,11 @@
(le16_to_cpu
(ohci->hcca.frame_no) + 10)) & 0xffff;
}
- td_submit_urb (urb); /* fill the TDs and link it to the ed */
-
if (ed->state != ED_OPER) /* link the ed into a chain if is not already */
ep_link (ohci, ed);
+
+ td_submit_urb (urb); /* fill the TDs and link it to the ed */
+
spin_unlock_irqrestore (&usb_ed_lock, flags);
urb->status = USB_ST_URB_PENDING;
--- linux/drivers/usb/usb-ohci.c.bak Thu Mar 23 21:52:14 2000
+++ linux/drivers/usb/usb-ohci.c Thu Mar 23 21:54:58 2000
@@ -871,6 +872,7 @@
TD_CC | TD_DP_OUT : TD_CC | TD_R | TD_DP_IN ;
td_fill (info | (cnt? TD_T_TOGGLE:toggle), data,
data_len, urb, (cnt? 0: ST_ADDR) | ADD_LEN, cnt);
cnt++;
+ wmb();
writel (OHCI_BLF, &ohci->regs->cmdstatus); /*
start bulk list */
break;
@@ -891,6 +893,7 @@
info = usb_pipeout (urb->pipe)?
TD_CC | TD_DP_IN | TD_T_DATA1: TD_CC |
TD_DP_OUT | TD_T_DATA1;
td_fill (info, NULL, 0, urb, 0, cnt++);
+ wmb();
writel (OHCI_CLF, &ohci->regs->cmdstatus); /*
TD_CC | TD_DP_OUT : TD_CC | TD_R | TD_DP_IN ;
td_fill (info | (cnt? TD_T_TOGGLE:toggle), data,
data_len, urb, (cnt? 0: ST_ADDR) | ADD_LEN, cnt);
cnt++;
+ wmb();
writel (OHCI_BLF, &ohci->regs->cmdstatus); /*
start bulk list */
break;
@@ -891,6 +893,7 @@
info = usb_pipeout (urb->pipe)?
TD_CC | TD_DP_IN | TD_T_DATA1: TD_CC |
TD_DP_OUT | TD_T_DATA1;
td_fill (info, NULL, 0, urb, 0, cnt++);
+ wmb();
writel (OHCI_CLF, &ohci->regs->cmdstatus); /*
start Control list */
break;
Thanks for everyone's efforts here getting the usb fixed on the G4.
Jack Howarth
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]