diff options
author | Pascal Rigaux <pixel@mandriva.com> | 2002-08-28 22:29:30 +0000 |
---|---|---|
committer | Pascal Rigaux <pixel@mandriva.com> | 2002-08-28 22:29:30 +0000 |
commit | 471e1eed85397a23424eee348b07734f1ce0a0f8 (patch) | |
tree | b5bcbf716b575e060e19758958e6eb35f0239088 /convert | |
parent | 9243ddda5a2931acb272f2d14cdaa7cbe0918da5 (diff) | |
download | ldetect-lst-471e1eed85397a23424eee348b07734f1ce0a0f8.tar ldetect-lst-471e1eed85397a23424eee348b07734f1ce0a0f8.tar.gz ldetect-lst-471e1eed85397a23424eee348b07734f1ce0a0f8.tar.bz2 ldetect-lst-471e1eed85397a23424eee348b07734f1ce0a0f8.tar.xz ldetect-lst-471e1eed85397a23424eee348b07734f1ce0a0f8.zip |
- add "Removable:floppy", "Removable:memory_card", "Removable:camera"
- usb-removables.pl is useful to update usbtable Removable:xxx based on device descriptions
Diffstat (limited to 'convert')
-rwxr-xr-x | convert/usb-removables.pl | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/convert/usb-removables.pl b/convert/usb-removables.pl new file mode 100755 index 00000000..822917ee --- /dev/null +++ b/convert/usb-removables.pl @@ -0,0 +1,18 @@ +#!/usr/bin/perl + +use lib qw(/usr/lib/libDrakX); +use detect_devices; + +require './merge2pcitable.pl'; +my $usbtable = read_pcitable($ARGV[0]); + +foreach (values %$usbtable) { + my $s = detect_devices::usb_description2removable($_->[1]) or next; + if ($_->[0] =~ /Removable:(.*)/) { + print STDERR "Conflicting $1 and $s for $_->[1]\n" if $1 ne $s; + } else { + print STDERR "Suggesting $s for $_->[1]\n"; + $_->[0] = "Removable:$s" if $_->[0] eq 'usb-storage'; + } +} +write_pcitable($usbtable); |