From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from pigeon.gentoo.org ([208.92.234.80] helo=lists.gentoo.org) by finch.gentoo.org with esmtp (Exim 4.60) (envelope-from ) id 1QVuXy-00015e-6z for garchives@archives.gentoo.org; Sun, 12 Jun 2011 23:58:26 +0000 Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id A69881C105; Sun, 12 Jun 2011 23:56:55 +0000 (UTC) Received: from mailout-de.gmx.net (mailout-de.gmx.net [213.165.64.23]) by pigeon.gentoo.org (Postfix) with SMTP id 350BB1C105 for ; Sun, 12 Jun 2011 23:56:55 +0000 (UTC) Received: (qmail invoked by alias); 12 Jun 2011 23:56:53 -0000 Received: from p5485010F.dip0.t-ipconnect.de (EHLO gmx.net) [84.133.1.15] by mail.gmx.net (mp063) with SMTP; 13 Jun 2011 01:56:53 +0200 X-Authenticated: #20088476 X-Provags-ID: V01U2FsdGVkX1+SiTpuqP6Sme7ixDJZKyen4dq/UU+WeI7SVzVEGG 9JaSZP1q03r79F Received: by gmx.net (nbSMTP-1.00) for uid 1001 Meino.Cramer@gmx.de; Mon, 13 Jun 2011 01:56:54 +0200 (CEST) Date: Mon, 13 Jun 2011 01:56:53 +0200 From: meino.cramer@gmx.de To: gentoo-user@lists.gentoo.org Subject: Re: [gentoo-user] USB Problems Message-ID: <20110612235653.GE3061@solfire> References: <20110612153012.7b8bf4fa@arcticwolf.myzen.co.uk> <20110612144538.GA3061@solfire> <20110612194520.0f649340@arcticwolf.myzen.co.uk> <20110612192048.GD3061@solfire> <20110612223030.2541a526@arcticwolf.myzen.co.uk> Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-user@lists.gentoo.org Reply-to: gentoo-user@lists.gentoo.org MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20110612223030.2541a526@arcticwolf.myzen.co.uk> User-Agent: mutt-ng/devel-r804 (Linux) X-Y-GMX-Trusted: 0 X-Archives-Salt: X-Archives-Hash: 14735942bc32cd7c159baea6cab1a48c john [11-06-13 01:13]: > On Sun, 12 Jun 2011 21:20:48 +0200 > meino.cramer@gmx.de wrote: > > > john [11-06-12 20:52]: > > > On Sun, 12 Jun 2011 16:45:38 +0200 > > > meino.cramer@gmx.de wrote: > > > > > > > john [11-06-12 16:36]: > > > > > Gents > > > > > > > > > > Whenever I insert external USB device my machine locks and I > > > > > have to do a hard reset (sys req does not even work). I have > > > > > tried this in a graphical environment and without. Machine > > > > > boots up fine with USB keyboard and mouse but will not boot up > > > > > with usb storage (memory stick > > > > > - tried several) > > > > > > > > > > I have recently upgrade kernel to 2.6.38-r6 when this error > > > > > started (approx). Hav also tried 2.6.38-r7 (which according to > > > > > bugzilla should fix an issue similar to this) the error still > > > > > happens. > > > > > > > > > > Any suggestions on kernel config options, debugging would be > > > > > appreciated. And how to trap full error message. > > > > > > > > > > Error message alongs these lines > > > > > > > > > > Kernel panic not syncing - fatal exception in iterrupt > > > > > ksoftirqd/1 Not tainted > > > > > > > > > > > > > > > > > > > > > > > > > -- > > > > > -------------- > > > > > -------------- > > > > > John D Maunder > > > > > jdm@arcticwolf.myzen.co.uk > > > > > > > > > > > > > Hi John, > > > > > > > > may be this could help to track th eerror more closely: > > > > Recompile the kernel with CONFIG_USB_DEBUG set. > > > > If not already done, enable CONFIG_MAGIC_SYSRQ and > > > > read about the available commands in the according > > > > docs under /usr/src/linux/Documentation/. > > > > This is a overall life saver in many other cases too. > > > > But it may be a security hole also -- you can disable > > > > it in /proc/ later. > > > > If possible change /etc/fstab to mount the partition > > > > to which logging will go with the "sync" option so > > > > every log entry will go directly onto the bare metal > > > > instead of a RAM buffer. > > > > > > > > Reboot into console mode (no X). > > > > cd to the logging directory and > > > > do a tail -f onto the logfile in question > > > > > > > > Insert the "USB stick of death" ;) and > > > > see, whether you can see anything in the > > > > tailed log. > > > > > > > > If not do the magic sysrq dance to sync hds, > > > > remount readonly and finally reboot. > > > > > > > > Take a closer look into the resulting logs. > > > > > > > > Good luck! > > > > > > > > Nevertheless have a nice weekend! > > > > Best regards, > > > > mcc > > > > > > > > > > > > > > > > > > Thanks mmc, > > > CONFIG_MAGIC_SYSRQ and CONFIG_USB_DEBUG set to y > > > > > > When I plug in USB device SYSREQ does not work. I have tested when > > > system is normal and all ok with SYSREQ so USB device is locking up > > > system completely. > > > > > > I have put sync in mount table but when device is inserted error log > > > is not being produced (in /var/log/messages, etc). I may end up > > > having to take a photo of error log(lol). Or there maybe some other > > > way of catching error which Gentoo gurus may advise. > > > > > > I have tried 3 memory sticks and they all lock system up. These work > > > on another PC using Arch and work on this PC dual booting with > > > Windows. I have a usb hard drive which works ok so it is a memory > > > stick only issue!!!!???? > > > > > > Hmmm. > > > > > > -- > > > -------------- > > > -------------- > > > John D Maunder > > > jdm@arcticwolf.myzen.co.uk > > > > > > > Hi John, > > > > if sysreq does not work after inserting the usbstick then the kernel > > stops working completly (the sysreq-code of the kernel is not > > entered), which seems to be that something happening on very low > > level (the problem not the sysreq-code of course... ;) > > > > Just another shot into the dark: > > Do you have modularized all usb-related stuff? This also may help to > > let the usb-sticks work correctly. > > > > Ah! Another thing: Insert the related modules into > > /etc/conf.d/modules so that they get loaded in a very early > > phase of the bootprocess. > > > > With modules loaded and with no usb-sticks as root inspect the > > according modules with modinfo -p to see, whether > > there a additional parameters you may pass to the modules to get > > an extra of informations or - better - to fix the issue. > > > > Modify under "Kernel hacking" in the kernel config the > > "Default message log level" to see more. > > > > Furthermore there is a switch "Kernel debugging" with sub-options. > > May be turning on these may also help to get closer to all evil ;) > > > > Last thing: > > If there is nothing valueable stored on the usbsticks: > > Try to reformat the usbsticks. Instead of putting a FAT32-fs on the > > bare device, create a regular partition and create a Linux-fs > > (reiserfs, ext2/3/4 or like that) on that partition. > > > > This may not be good idea in general, but - if it works - this would > > give a hint, where to search next. > > > > Good luck! > > > > Best regards, > > mcc > > > > > > > > > > > > > > > > > > > > Thanks Meino, > Have recompliled USB as modules (ehci-hcd, ohci-hcd and usb-storage and > load with /etc/conf.d/modules but still locks ups. Hope these are the > right ones. I'll try scsi next. > > Also tried fdisk Linux file system and format ext3. But all to no avail. > Still locking up. > > Have configure kernel hacking options as suggested. > > Error message as follows:- > > -------------------------------------------------------- > Bug: unable to handle kernel null pointer dereference at > 0000000000000048 > > IP []elv_queue_empty+0x12/0x27 > > Oops 000 [#1] SMP > > last sys file: /sys/devices/virtual/bdi/8:32/uevent > > Pid: 1-, comm: ksoftirqd/1 Tainted: P 2.6.38-gentoo-r7 #4 MICRO-STAR > MS-7388 > > RIP 0010[] elv-queue_empty+0x12/0x27 > -------------------------------------------------------- > > > From my very limited knowledge, I would suspect kernel problem (ksoft) > and irq (software interrupt perhaps). Please put me right if I'm out of > order here. I'm Linux noobie > > > Think I'll drop back to an older kernel to see if I'm still getting the > issue as this may elliminate hardware issue. > > Unsure how to pass options to modules when loading. is this just done > through /etc/conf.d/modules > > I like the error messages though Oops, RIP (someone has a sense of > humour) > > > Thanks for you help > > At least you learn while debgging > > > -- > -------------- > -------------- > John D Maunder > jdm@arcticwolf.myzen.co.uk > Hi John, yes, the kernel panics due to a NULL pointer dereference. It happens at the memory adress 0000000000000048, which looks to me as a suspicously low address...hmmm. But who knows...:) As the usb stick runs fine when the mobo runs windows I think there is no your-mobo-alone-hardware bug, but it may be still a hardware issue, which is known to the driver programmers and which was "fixed" (circumvented) with a windows-only driver. The linux driver may not know of this and runs into an undefined state here. But this is all is more like guessing than anything else. You can pass options to modules like this (this is from my /etc/conf.d/modules): modules_2_6="${modules_2_6} microcode" module_microcode_args_2_6="" modules_2_6="${modules_2_6} gspca_main" module_gspca_main_args_2_6="" One module per line... Here I have left off the arguments by giving "" accordingly. Below I have inserted a section from that file which gives commented examples how to pass options/arguments: # Give the modules some arguments if needed, per version if necessary. #module_ieee1394_args="debug" #module_ieee1394_args_2_6_23_gentoo_r5="ieee1394 ohci1394" #module_ieee1394_args_2_6_23="tun ieee1394" #module_ieee1394_args_2_6="tun" Yes, the kernel messages are humorous...its just to sweeten the bitter pill of a kernel panic. If you like that kind of humor (Question to a couple (both hackers): "Do you have children?" Answers: "Yes" Question: "Girl or boy" Answer: "Yes"...which is 100% correct at least from the logical point of view...;) I would suggest you to take a look here: http://www.catb.org/jargon/ 8) It would be interesting (and would help the kernel hackers to get closer to the may-be kernel problem) if a previous kernel would run your usb-stick without a panic... Good luck! Best regards mcc