LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Hardware
User Name
Password
Linux - Hardware This forum is for Hardware issues.
Having trouble installing a piece of hardware? Want to know if that peripheral is compatible with Linux?

Notices


Reply
  Search this Thread
Old 04-24-2019, 09:22 AM   #1
Dênio
LQ Newbie
 
Registered: Apr 2019
Posts: 10

Rep: Reputation: Disabled
Kernel ejects the USB device


Dear

I have a question on the Slackware distribution since version 14.2, because every time I plug in a Gertec PPC920 USB device the Kernel ejects the device as if it is no longer plugged in.
I did tests on Linux Slackware 14.1 and also other distributions like Linux Mint 19 and work without problems, already with Slackware 14.2 and also with the current version of Slackware the problem occurs.

Monitoring the UDEV we can see:

udevadm monitor
monitor will print the received events for:
Code:
UDEV - the event which udev sends out after rule processing
KERNEL - the kernel uevent

KERNEL[3626.013100] add /devices/pci0000:00/0000:00:1d.1/usb3/3-1 (usb)
KERNEL[3626.015922] add /devices/pci0000:00/0000:00:1d.1/usb3/3-1/3-1:1.0 (usb)
KERNEL[3626.017935] add /devices/pci0000:00/0000:00:1d.1/usb3/3-1/3-1:1.0/tty/ttyACM0 (tty)
KERNEL[3626.017993] bind /devices/pci0000:00/0000:00:1d.1/usb3/3-1/3-1:1.0 (usb)
KERNEL[3626.018037] add /devices/pci0000:00/0000:00:1d.1/usb3/3-1/3-1:1.1 (usb)
KERNEL[3626.018078] bind /devices/pci0000:00/0000:00:1d.1/usb3/3-1/3-1:1.1 (usb)
KERNEL[3626.018127] bind /devices/pci0000:00/0000:00:1d.1/usb3/3-1 (usb)
KERNEL[3626.086078] remove /devices/pci0000:00/0000:00:1d.1/usb3/3-1/3-1:1.0/tty/ttyACM0 (tty)
KERNEL[3626.086128] unbind /devices/pci0000:00/0000:00:1d.1/usb3/3-1/3-1:1.1 (usb)
KERNEL[3626.086160] unbind /devices/pci0000:00/0000:00:1d.1/usb3/3-1/3-1:1.0 (usb)
KERNEL[3626.086192] remove /devices/pci0000:00/0000:00:1d.1/usb3/3-1/3-1:1.0 (usb)
KERNEL[3626.086225] remove /devices/pci0000:00/0000:00:1d.1/usb3/3-1/3-1:1.1 (usb)
KERNEL[3626.086639] unbind /devices/pci0000:00/0000:00:1d.1/usb3/3-1 (usb)
KERNEL[3626.086690] remove /devices/pci0000:00/0000:00:1d.1/usb3/3-1 (usb)
UDEV [3626.538480] add /devices/pci0000:00/0000:00:1d.1/usb3/3-1 (usb)
UDEV [3626.545897] add /devices/pci0000:00/0000:00:1d.1/usb3/3-1/3-1:1.1 (usb)
UDEV [3626.545943] add /devices/pci0000:00/0000:00:1d.1/usb3/3-1/3-1:1.0 (usb)
UDEV [3626.546245] bind /devices/pci0000:00/0000:00:1d.1/usb3/3-1/3-1:1.1 (usb)
UDEV [3626.547268] add /devices/pci0000:00/0000:00:1d.1/usb3/3-1/3-1:1.0/tty/ttyACM0 (tty)
UDEV [3626.547527] bind /devices/pci0000:00/0000:00:1d.1/usb3/3-1/3-1:1.0 (usb)
UDEV [3626.547720] bind /devices/pci0000:00/0000:00:1d.1/usb3/3-1 (usb)
UDEV [3626.548004] unbind /devices/pci0000:00/0000:00:1d.1/usb3/3-1/3-1:1.1 (usb)
UDEV [3626.548567] remove /devices/pci0000:00/0000:00:1d.1/usb3/3-1/3-1:1.0/tty/ttyACM0 (tty)
UDEV [3626.548612] remove /devices/pci0000:00/0000:00:1d.1/usb3/3-1/3-1:1.1 (usb)
UDEV [3626.548931] unbind /devices/pci0000:00/0000:00:1d.1/usb3/3-1/3-1:1.0 (usb)
UDEV [3626.549360] remove /devices/pci0000:00/0000:00:1d.1/usb3/3-1/3-1:1.0 (usb)
UDEV [3626.549570] unbind /devices/pci0000:00/0000:00:1d.1/usb3/3-1 (usb)
UDEV [3626.550063] remove /devices/pci0000:00/0000:00:1d.1/usb3/3-1 (usb)
Anyone with any suggestions !?
Thank you!
 
Old 04-25-2019, 02:19 AM   #2
pan64
LQ Addict
 
Registered: Mar 2012
Location: Hungary
Distribution: debian/ubuntu/suse ...
Posts: 24,669

Rep: Reputation: 8104Reputation: 8104Reputation: 8104Reputation: 8104Reputation: 8104Reputation: 8104Reputation: 8104Reputation: 8104Reputation: 8104Reputation: 8104Reputation: 8104
I would rather say: GUI or some other tool/app initiates that eject, these are only just the low level events.
 
Old 04-25-2019, 05:49 AM   #3
Dênio
LQ Newbie
 
Registered: Apr 2019
Posts: 10

Original Poster
Rep: Reputation: Disabled
I'm not running any applications!
Simply plug the device and it is already ejected automatically in the versions mentioned.

# dmesg

[ 900.329260] usb 3-2: new full-speed USB device number 7 using uhci_hcd
[ 900.499278] usb 3-2: Dual-Role OTG device on non-HNP port
[ 900.502284] usb 3-2: New USB device found, idVendor=1753, idProduct=c902, bcdDevice= 0.01
[ 900.502288] usb 3-2: New USB device strings: Mfr=1, Product=2, SerialNumber=0
[ 900.502292] usb 3-2: Product: PPC920 Pinpad Terminal
[ 900.502295] usb 3-2: Manufacturer: GERTEC
[ 900.505428] cdc_acm 3-2:1.0: ttyACM0: USB ACM device
[ 900.507994] usb 3-2: USB disconnect, device number 7
 
Old 04-25-2019, 06:03 AM   #4
dc.901
Senior Member
 
Registered: Aug 2018
Location: Atlanta, GA - USA
Distribution: CentOS/RHEL, openSuSE/SLES, Ubuntu
Posts: 1,005

Rep: Reputation: 370Reputation: 370Reputation: 370Reputation: 370
Maybe you already tried these:
- Try the USB device in different computer, does it work?
- On your Slackware machine, plugin a different USB device; does it also get ejected?
- Try different USB port on Slackware machine?
 
1 members found this post helpful.
Old 04-25-2019, 06:15 AM   #5
Dênio
LQ Newbie
 
Registered: Apr 2019
Posts: 10

Original Poster
Rep: Reputation: Disabled
dc.901 thanks!

- Try the USB device in different computer, does it work? YES (3 computers)
- On your Slackware machine, plugin a different USB device; does it also get ejected? Others devices no problem
- Try different USB port on Slackware machine? Test in all ports

Complementing:

I'm doing the tests with 3 different machines
And using 2 different devices: Pinpad - Geretec PPC920 and also PPC910

Only in the cases of Slackware 14.2 and in the current version the problem is presented.

https://www.gertec.com.br/produtos/ppc920/
https://www.gertec.com.br/produtos/ppc910/

The devices are listed in /usr/share/usb.ids and /lib/udev/hwbd.d/20-usb-vendor-model.hwdb

dmesg after connecting device


[ 117.487030] usb 3-1: new full-speed USB device number 2 using uhci_hcd
[ 117.657054] usb 3-1: Dual-Role OTG device on non-HNP port
[ 117.660055] usb 3-1: New USB device found, idVendor=1753, idProduct=c902, bcdDevice= 0.01
[ 117.660059] usb 3-1: New USB device strings: Mfr=1, Product=2, SerialNumber=0
[ 117.660063] usb 3-1: Product: PPC920 Pinpad Terminal
[ 117.660066] usb 3-1: Manufacturer: GERTEC
[ 117.797099] usb 3-1: USB disconnect, device number 2
[ 118.205187] usbcore: registered new interface driver cdc_acm
[ 118.205189] cdc_acm: USB Abstract Control Model driver for USB modems and ISDN adapters

[ 962.289117] usb 3-2: new full-speed USB device number 3 using uhci_hcd
[ 962.459140] usb 3-2: Dual-Role OTG device on non-HNP port
[ 962.462142] usb 3-2: New USB device found, idVendor=1753, idProduct=c901, bcdDevice= 0.01
[ 962.462146] usb 3-2: New USB device strings: Mfr=1, Product=2, SerialNumber=0
[ 962.462150] usb 3-2: Product: PPC900 Pinpad Terminal
[ 962.462153] usb 3-2: Manufacturer: GERTEC
[ 962.465307] cdc_acm 3-2:1.0: ttyACM0: USB ACM device
[ 962.467523] usb 3-2: USB disconnect, device number 3

Last edited by Dênio; 04-25-2019 at 06:20 AM.
 
Old 04-26-2019, 06:32 AM   #6
Dênio
LQ Newbie
 
Registered: Apr 2019
Posts: 10

Original Poster
Rep: Reputation: Disabled
By doing several tests, I realize that I have a problem with Slackware packaging.
Using 2 computers for the tests, follow the results:

1. Computer with USB only 1.10 - No USB device works with this device.
2. Computer with USB 2.0 and 3.0 - Some USB ports work only with this device.

Now using Linux Mint 19 - Live on the same computers
1. Computer with USB only 1.10 - All USB ports working with the device.
2. Computer with USB 2.0 and 3.0 - Also all USB ports working with the device.

Slackware simply ejects the device and ignores any rule it places for the usb device.

--------------------- LINUX MINT 19 LIVE ---------------------

root@mint:~# udevadm monitor
monitor will print the received events for:
UDEV - the event which udev sends out after rule processing
KERNEL - the kernel uevent

KERNEL[1163.504310] add /devices/pci0000:00/0000:00:1d.0/usb2/2-1 (usb)
KERNEL[1163.507162] add /devices/pci0000:00/0000:00:1d.0/usb2/2-1/2-1:1.0 (usb)
KERNEL[1163.509131] add /devices/pci0000:00/0000:00:1d.0/usb2/2-1/2-1:1.0/tty/ttyACM0 (tty)
KERNEL[1163.509220] bind /devices/pci0000:00/0000:00:1d.0/usb2/2-1/2-1:1.0 (usb)
KERNEL[1163.509283] add /devices/pci0000:00/0000:00:1d.0/usb2/2-1/2-1:1.1 (usb)
KERNEL[1163.509356] bind /devices/pci0000:00/0000:00:1d.0/usb2/2-1/2-1:1.1 (usb)
KERNEL[1163.509447] bind /devices/pci0000:00/0000:00:1d.0/usb2/2-1 (usb)
UDEV [1163.821591] add /devices/pci0000:00/0000:00:1d.0/usb2/2-1 (usb)
UDEV [1163.827317] add /devices/pci0000:00/0000:00:1d.0/usb2/2-1/2-1:1.1 (usb)
UDEV [1163.830945] add /devices/pci0000:00/0000:00:1d.0/usb2/2-1/2-1:1.0 (usb)
UDEV [1163.833829] bind /devices/pci0000:00/0000:00:1d.0/usb2/2-1/2-1:1.1 (usb)
UDEV [1163.837665] add /devices/pci0000:00/0000:00:1d.0/usb2/2-1/2-1:1.0/tty/ttyACM0 (tty)
UDEV [1163.849951] bind /devices/pci0000:00/0000:00:1d.0/usb2/2-1/2-1:1.0 (usb)
UDEV [1163.854187] bind /devices/pci0000:00/0000:00:1d.0/usb2/2-1 (usb)
KERNEL[1164.516377] add /devices/parport0/ppdev0.0 (parport)
KERNEL[1164.517050] bind /devices/parport0/ppdev0.0 (parport)
KERNEL[1164.517500] unbind /devices/parport0/ppdev0.0 (parport)
KERNEL[1164.517801] remove /devices/parport0/ppdev0.0 (parport)
UDEV [1164.518488] add /devices/parport0/ppdev0.0 (parport)
UDEV [1164.519576] bind /devices/parport0/ppdev0.0 (parport)
UDEV [1164.520484] unbind /devices/parport0/ppdev0.0 (parport)
UDEV [1164.521255] remove /devices/parport0/ppdev0.0 (parport)
KERNEL[1168.910406] add /devices/parport0/ppdev0.0 (parport)
KERNEL[1168.910458] bind /devices/parport0/ppdev0.0 (parport)
UDEV [1168.913998] add /devices/parport0/ppdev0.0 (parport)
UDEV [1168.915360] bind /devices/parport0/ppdev0.0 (parport)
KERNEL[1168.956354] unbind /devices/parport0/ppdev0.0 (parport)
KERNEL[1168.957455] remove /devices/parport0/ppdev0.0 (parport)
UDEV [1168.961207] unbind /devices/parport0/ppdev0.0 (parport)
UDEV [1168.962744] remove /devices/parport0/ppdev0.0 (parport)

-------------------- dmesg --------------------------------

[ 1163.335657] usb 2-1: new full-speed USB device number 4 using uhci_hcd
[ 1163.523543] usb 2-1: New USB device found, idVendor=1753, idProduct=c902
[ 1163.523548] usb 2-1: New USB device strings: Mfr=1, Product=2, SerialNumber=0
[ 1163.523552] usb 2-1: Product: PPC920 Pinpad Terminal
[ 1163.523556] usb 2-1: Manufacturer: GERTEC
[ 1163.526705] cdc_acm 2-1:1.0: ttyACM0: USB ACM device


Anyone with any suggestions?
Thank you!
 
Old 04-29-2019, 03:03 AM   #7
pan64
LQ Addict
 
Registered: Mar 2012
Location: Hungary
Distribution: debian/ubuntu/suse ...
Posts: 24,669

Rep: Reputation: 8104Reputation: 8104Reputation: 8104Reputation: 8104Reputation: 8104Reputation: 8104Reputation: 8104Reputation: 8104Reputation: 8104Reputation: 8104Reputation: 8104
probably the filesystem/device could not be recognized properly, that's why was it ejected immediately. It looks like a [missing] device driver issue or something similar.
Again, these are just the low level events, you need to find (in /var/log or ??) more related info.
 
1 members found this post helpful.
Old 04-30-2019, 01:48 PM   #8
Dênio
LQ Newbie
 
Registered: Apr 2019
Posts: 10

Original Poster
Rep: Reputation: Disabled
Dear

Solution to the problem is to just recompile the kernel by unchecking the CONFIG_USB_OTG option.

The .config file in the default Slackware build looks like this:
CONFIG_USB_OTG = y

The .config file in the build looks like this:
# CONFIG_USB_OTG is not set

Questions to recompile the kernel use the link:
https://edersoncorbari.github.io/tut...-build-kernel/

No need to recompile modules!

After compiling the kernel update the files:
vmlinuz-huge-smp-4.4.14-smp
System.map-huge-smp-4.4.14-smp
config-huge-smp-4.4.14-smp

And rewrite lilo again.

Last edited by Dênio; 05-02-2019 at 08:53 AM.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

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
CDROM Ejects Continuously bmikowski Linux - General 2 10-17-2004 07:16 PM
cd doesn't eject in cd-rw & ejects in dvd rom psa Linux - Newbie 16 08-29-2004 03:56 AM
cdrom ejects after burning drigz Linux - Hardware 7 05-29-2004 07:04 AM
Grip ejects CD's Jiawen Linux - Software 5 05-04-2004 05:08 PM
MandrakeMove problem cd ejects for no reason blackphiber Mandriva 2 03-19-2004 03:00 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Hardware

All times are GMT -5. The time now is 03:33 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