LinuxQuestions.org
Help answer threads with 0 replies.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Linux From Scratch
User Name
Password
Linux From Scratch This Forum is for the discussion of LFS.
LFS is a project that provides you with the steps necessary to build your own custom Linux system.

Notices


Reply
  Search this Thread
Old 11-03-2016, 01:03 PM   #1
cellsheet
LQ Newbie
 
Registered: Aug 2014
Posts: 16

Rep: Reputation: Disabled
Kernel panic - LFS Not recognizing UAS device


I'm trying to make the linux kernel recognize my thermaltake BlaX duet USB 3.0 dock in which I have the drive LFS is installed on. Whenever I boot the kernel, my drive isn't recognized as it is in arch linux as shown in dmesg (full dmesg is http://sprunge.us/JEES).

Code:
[    1.125149] usb 4-2: new SuperSpeed USB device number 2 using xhci_hcd
[    1.152040] usbcore: registered new interface driver usb-storage
[    1.156420] scsi host6: uas
[    1.156583] usbcore: registered new interface driver uas
[    1.157544] scsi 6:0:0:0: Direct-Access     JMicron                   9122 PQ: 0 ANSI: 6
[    1.241110] sd 6:0:0:0: [sdb] 1953525168 512-byte logical blocks: (1.00 TB/932 GiB)
[    1.242094] sd 6:0:0:0: [sdb] Write Protect is off
[    1.242094] sd 6:0:0:0: [sdb] Mode Sense: 67 00 10 08
[    1.242452] sd 6:0:0:0: [sdb] Write cache: enabled, read cache: enabled, supports DPO and FUA
[    1.246992]  sdb: sdb1 sdb2
[    1.250650] sd 6:0:0:0: [sdb] Attached SCSI disk

This results in a kernel panic as shown here: http://imgur.com/vBXZkda

Code:
$ lsusb -v
Bus 004 Device 002: ID 152d:2561 JMicron Technology Corp. / JMicron USA Technology Corp. 
Couldn't open device, some information will be missing
Device Descriptor:
  bLength                18
  bDescriptorType         1
  bcdUSB               3.00
  bDeviceClass            0 
  bDeviceSubClass         0 
  bDeviceProtocol         0 
  bMaxPacketSize0         9
  idVendor           0x152d JMicron Technology Corp. / JMicron USA Technology Corp.
  idProduct          0x2561 
  bcdDevice           91.22
  iManufacturer           1 
  iProduct                2 
  iSerial                 5 
  bNumConfigurations      1
  Configuration Descriptor:
    bLength                 9
    bDescriptorType         2
    wTotalLength          121
    bNumInterfaces          1
    bConfigurationValue     1
    iConfiguration          4 
    bmAttributes         0xc0
      Self Powered
    MaxPower                2mA
    Interface Descriptor:
      bLength                 9
      bDescriptorType         4
      bInterfaceNumber        0
      bAlternateSetting       0
      bNumEndpoints           2
      bInterfaceClass         8 Mass Storage
      bInterfaceSubClass      6 SCSI
      bInterfaceProtocol     80 Bulk-Only
      iInterface              6 
      Endpoint Descriptor:
        bLength                 7
        bDescriptorType         5
        bEndpointAddress     0x81  EP 1 IN
        bmAttributes            2
          Transfer Type            Bulk
          Synch Type               None
          Usage Type               Data
        wMaxPacketSize     0x0400  1x 1024 bytes
        bInterval               0
        bMaxBurst              15
      Endpoint Descriptor:
        bLength                 7
        bDescriptorType         5
        bEndpointAddress     0x02  EP 2 OUT
        bmAttributes            2
          Transfer Type            Bulk
          Synch Type               None
          Usage Type               Data
        wMaxPacketSize     0x0400  1x 1024 bytes
        bInterval               0
        bMaxBurst              15
    Interface Descriptor:
      bLength                 9
      bDescriptorType         4
      bInterfaceNumber        0
      bAlternateSetting       1
      bNumEndpoints           4
      bInterfaceClass         8 Mass Storage
      bInterfaceSubClass      6 SCSI
      bInterfaceProtocol     98 
      iInterface             10 
      Endpoint Descriptor:
        bLength                 7
        bDescriptorType         5
        bEndpointAddress     0x01  EP 1 OUT
        bmAttributes            2
          Transfer Type            Bulk
          Synch Type               None
          Usage Type               Data
        wMaxPacketSize     0x0400  1x 1024 bytes
        bInterval               0
        bMaxBurst               0
        Command pipe (0x01)
      Endpoint Descriptor:
        bLength                 7
        bDescriptorType         5
        bEndpointAddress     0x82  EP 2 IN
        bmAttributes            2
          Transfer Type            Bulk
          Synch Type               None
          Usage Type               Data
        wMaxPacketSize     0x0400  1x 1024 bytes
        bInterval               0
        bMaxBurst               0
        MaxStreams             16
        Status pipe (0x02)
      Endpoint Descriptor:
        bLength                 7
        bDescriptorType         5
        bEndpointAddress     0x83  EP 3 IN
        bmAttributes            2
          Transfer Type            Bulk
          Synch Type               None
          Usage Type               Data
        wMaxPacketSize     0x0400  1x 1024 bytes
        bInterval               0
        bMaxBurst              15
        MaxStreams             16
        Data-in pipe (0x03)
      Endpoint Descriptor:
        bLength                 7
        bDescriptorType         5
        bEndpointAddress     0x04  EP 4 OUT
        bmAttributes            2
          Transfer Type            Bulk
          Synch Type               None
          Usage Type               Data
        wMaxPacketSize     0x0400  1x 1024 bytes
        bInterval               0
        bMaxBurst              15
        MaxStreams             16
        Data-out pipe (0x04)
Code:
$ sudo fdisk -l
Disk /dev/sda: 119.2 GiB, 128035676160 bytes, 250069680 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disklabel type: gpt
Disk identifier: 76135E96-CAAD-468A-B5CC-5AB3D4AE61B9

Device      Start       End   Sectors  Size Type
/dev/sda1    2048    534527    532480  260M EFI System
/dev/sda2  534528 250069646 249535119  119G Linux filesystem


Disk /dev/sdc: 477 GiB, 512110190592 bytes, 1000215216 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes
Disklabel type: gpt
Disk identifier: CB6C419E-726A-40D3-B54D-E4DDBDF079A6

Device       Start        End   Sectors   Size Type
/dev/sdc1     2048     923647    921600   450M Windows recovery environment
/dev/sdc2   923648    1128447    204800   100M EFI System
/dev/sdc3  1128448    1161215     32768    16M Microsoft reserved
/dev/sdc4  1161216 1000214527 999053312 476.4G Microsoft basic data


Disk /dev/sdb: 931.5 GiB, 1000204886016 bytes, 1953525168 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 4096 bytes / 33553920 bytes
Disklabel type: gpt
Disk identifier: 81E1C06A-50E1-4121-8D61-4D19C5F41EC4

Device      Start        End    Sectors   Size Type
/dev/sdb1    2048     534527     532480   260M EFI System
/dev/sdb2  534528 1953525134 1952990607 931.3G Linux filesystem

Last edited by cellsheet; 11-03-2016 at 01:12 PM.
 
Old 11-03-2016, 01:43 PM   #2
Luridis
Member
 
Registered: Mar 2014
Location: Texas
Distribution: LFS 9.0 Custom, Merged Usr, Linux 4.19.x
Posts: 616

Rep: Reputation: 167Reputation: 167
Grab the config file (not the whole kernel source) from your Arch kernel, open it and trim out the Arch-specific fields at the top. Save that in a fresh decompress of the kernel for your LFS after you make-proper. Finally, run "make silentoldconfig && make menuconfig", that should leave you with the same driver setup as the Arch. I would change little in this first configuration, just adding what you specifically need. If the new kernel works, you've got yourself a baseline build.
 
Old 11-03-2016, 03:47 PM   #3
cellsheet
LQ Newbie
 
Registered: Aug 2014
Posts: 16

Original Poster
Rep: Reputation: Disabled
Unfortunately the kernel still panics . Also, the resolution of the output is now smaller, so I'm seeing less lines. I'm not sure what switch arch put in to produce that, but now I'm attempting to turn that off to see more output.

Edit: I'm currently using integrated graphics from my i5-6500k through display port in order to see video. My config didn't initially have the configurations necessary to support video from my nvidia GTX 1080 even early on boot at this stage.

Last edited by cellsheet; 11-03-2016 at 05:11 PM.
 
Old 11-03-2016, 06:32 PM   #4
Luridis
Member
 
Registered: Mar 2014
Location: Texas
Distribution: LFS 9.0 Custom, Merged Usr, Linux 4.19.x
Posts: 616

Rep: Reputation: 167Reputation: 167
Are you using an initramfs? I noticed your kernel points to the rootfs in the form of a UUID and you're using UEFI. See below...

http://www.linuxfromscratch.org/blfs...initramfs.html
 
1 members found this post helpful.
Old 11-03-2016, 07:42 PM   #5
cellsheet
LQ Newbie
 
Registered: Aug 2014
Posts: 16

Original Poster
Rep: Reputation: Disabled
Quote:
Originally Posted by Luridis View Post
Are you using an initramfs? I noticed your kernel points to the rootfs in the form of a UUID and you're using UEFI. See below...

http://www.linuxfromscratch.org/blfs...initramfs.html
I installed initramfs, and now I'm getting something very interesting. Apparently the kernel is registering /dev/sdc2 after attempting to look for rootfs. Also, unable to make input into the shell.

http://imgur.com/xSr366S

EDIT: Attempt number 2 gave me keyboard input, and when I typed exit, the boot process continued as normal

Last edited by cellsheet; 11-03-2016 at 08:13 PM.
 
Old 11-03-2016, 09:34 PM   #6
stoat
Member
 
Registered: May 2007
Distribution: LFS
Posts: 628

Rep: Reputation: 185Reputation: 185
Quote:
Originally Posted by cellsheet

Attempt number 2 gave me keyboard input, and when I typed exit, the boot process continued as normal
Systems on USB-connected drives sometimes require a delay before the root filesystem is sought. You can try adding rootdelay=5 to your linux command line in grub.cfg. Experiment with a longer or shorter delay.

Another thing systems on USB-connected drives may need is to identify the root filesystem by UUID or LABEL if you have an initial ram filesystem or maybe by PARTUUID with EFI. The standard device name syntax in grub.cfg may fail from the USB device being discovered in a different order than expected if multiple USB devices are present.
 
Old 11-08-2016, 11:23 AM   #7
cellsheet
LQ Newbie
 
Registered: Aug 2014
Posts: 16

Original Poster
Rep: Reputation: Disabled
Quote:
Originally Posted by stoat View Post
Systems on USB-connected drives sometimes require a delay before the root filesystem is sought. You can try adding rootdelay=5 to your linux command line in grub.cfg. Experiment with a longer or shorter delay.

Another thing systems on USB-connected drives may need is to identify the root filesystem by UUID or LABEL if you have an initial ram filesystem or maybe by PARTUUID with EFI. The standard device name syntax in grub.cfg may fail from the USB device being discovered in a different order than expected if multiple USB devices are present.
I will definitely give PARTUUID a try as well as rootdelay/rootwait. I think though that systemd-boot would also be a better choice of a boot loader to avoid GRUB all together. I will try this and update as soon as I can get my frame buffer working with my GPU.

EDIT: got framebuffer working, and rootdelay=10 worked. Thank you!

Last edited by cellsheet; 11-08-2016 at 11:36 AM.
 
Old 11-08-2016, 11:52 AM   #8
Luridis
Member
 
Registered: Mar 2014
Location: Texas
Distribution: LFS 9.0 Custom, Merged Usr, Linux 4.19.x
Posts: 616

Rep: Reputation: 167Reputation: 167
Quote:
Originally Posted by cellsheet View Post
I will definitely give PARTUUID a try as well as rootdelay/rootwait. I think though that systemd-boot would also be a better choice of a boot loader to avoid GRUB all together. I will try this and update as soon as I can get my frame buffer working with my GPU.
That one is a pain (framebuffer), as there are competing graphics driver models in the kernel. The huge kernel configs from distributions can paint a confusing picture as one driver is loaded, then unloaded by another. My recommendation is to stay with either the classic FB and avoid DRI, or use DRI and not select any classic FB drivers, like vesafb, that are not DRI-aware. If you're trying to stay on the DRI side of things, avoid selecting or building a module for anything in:

Device Drivers ---> Graphics support ---> Frame buffer Devices
under the heading: *** Framebuffer Hardware Drivers ***

But you may still need a couple above that heading like like "support for framebuffer devices" in order to use DRI-aware fbs. My vmwgfxfb fb driver won't show up under DRM driver for VMware Virtual GPU in the root graphics driver menu until fb support is added in FB Devices menu.

All-in-all, its very confusing how they have it setup.
 
1 members found this post helpful.
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
[SOLVED] Kernel Panic from loading non-existent device Jimdsi Linux - Software 15 03-06-2012 08:49 AM
[SOLVED] No device nodes with fresh kernel (was Kernel panic after fsck) roberto967 Slackware 4 12-04-2011 03:05 PM
Kernel + Chipset not recognizing my PCI device dmangal Linux - Hardware 6 08-06-2008 01:00 PM
Kernel panic: can't find root device jagot Linux - Software 14 08-07-2005 11:54 PM
kernel panic - cant mount root device. -Nw- neX Linux - Software 18 09-19-2004 02:56 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Linux From Scratch

All times are GMT -5. The time now is 10:17 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration