Description of Problem: mount segfaults, sometimes the kernel panics. Version-Release number of selected component (if applicable): mount-2.11g-5 kernel 2.4.7-2smp How Reproducible: always (kernel panics are erratic), further attempts to mount after the first one cause zombie mount processes that wont die. Steps to Reproduce: 1. modprobe sg; modprobe usb-storage 2. mount /dev/scd0 /mnt/cdrom Actual Results: [root@zorak mnt]# mount /dev/scd0 /mnt/cdrom /dev/scd0: Success mount: block device /dev/scd0 is write-protected, mounting read-only /dev/scd0: Read-only file system Segmentation fault Expected Results: cdrom mounts disc in /mnt/cdrom Additional Information: CDRW is labeled as an HP CDWriter 8200 Series, external USB. [root@zorak etc]# cat /proc/scsi/scsi Attached devices: Host: scsi0 Channel: 00 Id: 00 Lun: 00 Vendor: IBM-PSG Model: DNES-309170W !# Rev: SAB0 Type: Direct-Access ANSI SCSI revision: 03 Host: scsi2 Channel: 00 Id: 00 Lun: 00 Vendor: HP Model: CD-Writer+ 8290 Rev: 1.3C Type: CD-ROM ANSI SCSI revision: 02 [root@zorak etc]# cat /proc/bus/usb/devices T: Bus=01 Lev=00 Prnt=00 Port=00 Cnt=00 Dev#= 1 Spd=12 MxCh= 2 B: Alloc= 0/900 us ( 0%), #Int= 0, #Iso= 0 D: Ver= 1.00 Cls=09(hub ) Sub=00 Prot=00 MxPS= 8 #Cfgs= 1 P: Vendor=0000 ProdID=0000 Rev= 0.00 S: Product=USB UHCI Root Hub S: SerialNumber=ff00 C:* #Ifs= 1 Cfg#= 1 Atr=40 MxPwr= 0mA I: If#= 0 Alt= 0 #EPs= 1 Cls=09(hub ) Sub=00 Prot=00 Driver=hub E: Ad=81(I) Atr=03(Int.) MxPS= 8 Ivl=255ms T: Bus=01 Lev=01 Prnt=01 Port=00 Cnt=01 Dev#= 2 Spd=12 MxCh= 0 D: Ver= 1.00 Cls=00(>ifc ) Sub=00 Prot=00 MxPS=16 #Cfgs= 1 P: Vendor=03f0 ProdID=0207 Rev= 0.01 S: Product=HP USB CD-Writer Plus C:* #Ifs= 1 Cfg#= 1 Atr=40 MxPwr= 0mA I: If#= 0 Alt= 0 #EPs= 3 Cls=ff(vend.) Sub=01 Prot=ff Driver=usb-storage E: Ad=81(I) Atr=03(Int.) MxPS= 4 Ivl= 5ms E: Ad=82(I) Atr=02(Bulk) MxPS= 64 Ivl= 0ms E: Ad=03(O) Atr=02(Bulk) MxPS= 64 Ivl= 0ms [root@zorak etc]# cat /proc/scsi/sg/device_strs IBM-PSG DNES-309170W !# SAB0 HP CD-Writer+ 8290 1.3C [root@zorak spot]# cat /proc/scsi/usb-storage-0/2 Host scsi2: usb-storage Vendor: HP Product: HP USB CD-Writer Plus Serial Number: None Protocol: 8070i Transport: SCM/ATAPI GUID: 03f002070000000000000000 Attached: 1 [root@zorak spot]# cat /proc/bus/usb/drivers usbdevfs hub hid 96-111: hiddev usb-storage
I am 99% sure that EVERY so-called "mount segfault" is actually a kernel oops. Requestor, please do the following: 1. Reboot clean, without magicdev. 2. Attach the device. 3. mount, get the "segfault". DO IT ONLY ONCE. 4. dmesg > /tmp/dmesg.out 5. Reboot before it got worse. Attach the resulting dmesg.out. If dmesg has an oops, I'll take the bug (almost sure now). Certainly bero won't mind.
Created attachment 28914 [details] dmesg showing kernel oops
Indeed, it is oopsing. Now, last night I did some research on the problem and discovered a reference to some patches which resolve the problem. I applied those patches to the roswell2 kernel source, rebuilt it, booted the new kernel, and was able to successfully mount the cdrom drive. Havent tried burning yet, but it looks promising at this point.
Created attachment 28915 [details] patch for /usr/src/linux-2.4.7-2/drivers/usb/storage
Created attachment 28916 [details] patch for /usr/src/linux-2.4.7-2/drivers/usb/storage
Burning works as well.
Curious. The 8290-patch-2_4_2 seems to be unrelated, it only allows the Shuttle to work properly but does not prevent any oopses. Can you try with the second patch only and see if it still works?
Kernel with only wilford-sectorsize patch oopses, reproduceably. Oops is attached below.
Created attachment 28997 [details] New oops, with only the 2nd patch applied.
Thanks for the oops, can you run it through ksymoops for me?
We (Red Hat) should really try to fix this before next release.
Created attachment 29077 [details] ksymoops results
Thanks for the trace, I am looking... BTW, do you know that NV scribbles randomly over memory? This looks pretty scary: Trace; e09b9f33 <[NVdriver]KernInitAGP+313/40c> (I realize that it's garbage from old stack frames :). But still...)
I do not pretend to understand to understand how this works, but both of those fixes are in 2.4.8-ac8. Let me ask Arjan if they will filter down to our kernel before 7.2 release. Current HEAD and fairfax are 2.4.7-ac3, without the fixes.
The sector size guess was dropped from 2.4.8-ac10. Needs to be re-tested. I've committed the other one in HEAD and fairfax, let it get into a build.
Does the RC2 work?! Please let me know. (actually, 7.2 final is available, please try that if you can find it).
Works like a charm now, thanks Pete!