Solved How do I determine the physical location of my USB ports

Solved issue

cencar

New Member
Joined
Nov 15, 2022
Messages
17
Reaction score
2
Credits
156
How do I determine the physical location of my USB ports

Hi everyone,
I use the lsusb and my laptop has 4 usb ports from what I have established there are two ports on both sides
1.1 usb port
2.0 usb port
2.0 usb port
3.0 usb port.
Code:
lsusb
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 001 Device 003: ID 0bda:0138 Realtek Semiconductor Corp. RTS5138 Card Reader Controller
Bus 002 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
Bus 002 Device 002: ID 10c4:8108 Silicon Labs USB OPTICAL MOUSE
Bus 003 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 003 Device 002: ID 148f:5572 Ralink Technology, Corp. RT5572 Wireless Adapter
Bus 004 Device 001: ID 1d6b:0003 Linux Foundation 3.0 root hub
I have a usb mouse as shown and a wireless adapter again shown. How do I determine the information relating their physical locations?
All suggestions welcome.
 


It appears you have, in the usb sockets:
a card reader,
a mouse
a wifi dongle

You ask:
How do I determine the information relating their physical locations?

Maybe this is a little ambiguous insofar as the information you are after.

As I understand it, their physical locations can be determined by inspecting which usb port the items are connected to. For example, whichever port the usb mouse is connected to will be on the bus 002, have device number 002. The ID in hex of 10c4:8108, identifies the vendor and product, seen here:


The lsusb command output in your post already shows that.

For more information about any item, you can run the lsusb command to provide more information by referencing the bus and device numbers. For example, in relation to your mouse, you could run:
Code:
lsusb -v -s 002:002

On a machine here, where the numbers are different, the output looks like the following, though I have snipped lots off the end. Note that the output says "some information will be missing". To get that missing information, run the command as root. Below, it's run as user:
Code:
[tom@min ~]$ lsusb -v -s 001:005 
Bus 001 Device 005: ID 046d:c077 Logitech, Inc. Mouse
Couldn't open device, some information will be missing
Device Descriptor:
  bLength                18
  bDescriptorType         1
  bcdUSB               2.00
  bDeviceClass            0 
  bDeviceSubClass         0 
  bDeviceProtocol         0 
  bMaxPacketSize0         8
  idVendor           0x046d Logitech, Inc.
  idProduct          0xc077 Mouse
  bcdDevice           72.00
  iManufacturer           1 Logitech
  iProduct                2 USB Optical Mouse
<snip>
 

Hi osprey,​

Thanks for your response, probably not the correct method. However, I determined the USB 3.0 by the colour blue and by moving the network card from port to port and checking the relative speeds I was able to single out the 1.1 port and thus the other two 2.0.
Given that the 1.1 and 2.0 are the same colour, I now know what port not to use.
Thanks again.
 
Thanks for your response, probably not the correct method. However, I determined the USB 3.0 by the colour blue and by moving the network card from port to port and checking the relative speeds I was able to single out the 1.1 port and thus the other two 2.0.
Given that the 1.1 and 2.0 are the same colour, I now know what port not to use.
Thanks again.

I guess that works, but Osprey's method is probably easier.


lsusb -v -s 003:002

Bus 003 Device 002: ID 0bda:9210 Realtek Semiconductor Corp. RTL9210 M.2 NVME Adapter
Device Descriptor:
bLength 18
bDescriptorType 1
bcdUSB 2.10
bDeviceClass 0 [unknown]
bDeviceSubClass 0 [unknown]
bDeviceProtocol 0
bMaxPacketSize0 64
idVendor 0x0bda Realtek Semiconductor Corp.
idProduct 0x9210 RTL9210 M.2 NVME Adapter
bcdDevice 20.01
iManufacturer 1 Realtek
iProduct 2 DLWJ-RTL9210B-CG
iSerial 3 012345678928
bNumConfigurations 1
Configuration Descriptor:
bLength 9
bDescriptorType 2
wTotalLength 0x0020
bNumInterfaces 1
bConfigurationValue 1
iConfiguration 0
bmAttributes 0x80
(Bus Powered)
MaxPower 500mA
Interface Descriptor:
bLength 9
bDescriptorType 4
bInterfaceNumber 0
bAlternateSetting 0
bNumEndpoints 2
bInterfaceClass 8 Mass Storage
bInterfaceSubClass 6 SCSI
bInterfaceProtocol 80 Bulk-Only
iInterface 0
Endpoint Descriptor:
bLength 7
bDescriptorType 5
bEndpointAddress 0x81 EP 1 IN
bmAttributes 2
Transfer Type Bulk
Synch Type None
Usage Type Data
wMaxPacketSize 0x0200 1x 512 bytes
bInterval 0
Endpoint Descriptor:
bLength 7
bDescriptorType 5
bEndpointAddress 0x02 EP 2 OUT
bmAttributes 2
Transfer Type Bulk
Synch Type None
Usage Type Data
wMaxPacketSize 0x0200 1x 512 bytes
bInterval 0
Binary Object Store Descriptor:
bLength 5
bDescriptorType 15
wTotalLength 0x002a
bNumDeviceCaps 3
USB 2.0 Extension Device Capability:
bLength 7
bDescriptorType 16
bDevCapabilityType 2
bmAttributes 0x00000006
BESL Link Power Management (LPM) Supported
SuperSpeed USB Device Capability:
bLength 10
bDescriptorType 16
bDevCapabilityType 3
bmAttributes 0x00
wSpeedsSupported 0x000e
Device can operate at Full Speed (12Mbps)
Device can operate at High Speed (480Mbps)
Device can operate at SuperSpeed (5Gbps)
bFunctionalitySupport 1
Lowest fully-functional device speed is Full Speed (12Mbps)
bU1DevExitLat 10 micro seconds
bU2DevExitLat 2047 micro seconds
SuperSpeedPlus USB Device Capability:
bLength 20
bDescriptorType 16
bDevCapabilityType 10
bmAttributes 0x00000001
Sublink Speed Attribute count 2
Sublink Speed ID count 1
wFunctionalitySupport 0x1100
Min functional Speed Attribute ID: 0
Min functional RX lanes: 1
Min functional TX lanes: 1
bmSublinkSpeedAttr[0] 0x000a4030
Speed Attribute ID: 0 10Gb/s Symmetric RX SuperSpeedPlus
bmSublinkSpeedAttr[1] 0x000a40b0
Speed Attribute ID: 0 10Gb/s Symmetric TX SuperSpeedPlus

Device Status: 0x0000
(Bus Powered)

This will also tell you how fast a given device in a specific port can support.
In my case, the port support 10Gb/s. But the current plugged in device only supports 5 Gb/s.

Another interesting thing here, some ports have a "minimum" speed limit. Kind of like driving too
slow on the freeway I guess. I do a couple of old USB 1.0 thumb drives ( Gen 1 ). If I plug them into this
port they don't show up at all. fdisk doesn't see them, and they don't automount.

However if I plug them into a USB 2.0 port, then everything seems to work ( albeit more slowly ).
 
How do I determine the physical location of my USB ports

I normally use my eyes...I don't need a terminal for that..it's not hard to workout what's plugged in to them.
m1210.gif


As for USB 1.1...they haven't been around for over 25 years...modern Flash Drives simply don't work in them...anyway Flash Drives now are USB 3 or 3.1.
m1212.gif
 

Members online


Top