diff options
author | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2021-10-15 16:06:13 +0200 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2021-10-15 16:06:13 +0200 |
commit | 9b5f18e2df341f0e90cfc4e03d27ef11080adaaf (patch) | |
tree | ba12adda31d407dfe00d2b1e14512b13e4e0ece2 | |
parent | 57fb18e59cce31a50a1ca62d1e192512c905ba00 (diff) | |
download | usbutils-9b5f18e2df341f0e90cfc4e03d27ef11080adaaf.tar.gz |
usb-devices: list the root devices in numerical order
Previously "usb10" would come before "usb2"
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
-rwxr-xr-x | usb-devices | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/usb-devices b/usb-devices index 1ecca48..4e14608 100755 --- a/usb-devices +++ b/usb-devices @@ -178,7 +178,7 @@ if [ ! -d /sys/bus ]; then exit 1 fi -for device in /sys/bus/usb/devices/usb* +for device in $(ls /sys/bus/usb/devices/ | grep ^usb | sort -V) do - print_device $device 0 0 0 + print_device /sys/bus/usb/devices/$device 0 0 0 done |