summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTzafrir Cohen <tzafrir.cohen@xorcom.com>2010-04-12 20:18:29 +0000
committerTzafrir Cohen <tzafrir.cohen@xorcom.com>2010-04-12 20:18:29 +0000
commitae7ec47b870bb8683ad4539ea860bfc2a6c24635 (patch)
tree86bf69d0422b52aa4959fae094de3f5c11e556e1
parent4848d25b3da84eef91ab1056238fbf9de0105e12 (diff)
Also detect USB devices connected on a hub.
git-svn-id: http://svn.asterisk.org/svn/dahdi/tools/trunk@8508 a0bf4364-ded3-4de4-8d8a-66a801d63aff
-rw-r--r--xpp/perl_modules/Dahdi/Hardware/USB.pm4
1 files changed, 2 insertions, 2 deletions
diff --git a/xpp/perl_modules/Dahdi/Hardware/USB.pm b/xpp/perl_modules/Dahdi/Hardware/USB.pm
index 711f977..d73bdbe 100644
--- a/xpp/perl_modules/Dahdi/Hardware/USB.pm
+++ b/xpp/perl_modules/Dahdi/Hardware/USB.pm
@@ -95,7 +95,7 @@ sub set_transport($$) {
}
} elsif(-f "$transportdir/idVendor" ) {
my $transport_link = readlink($transportdir);
- $transport_link =~ m|/(\d+)-\d+$|;
+ $transport_link =~ m|/(\d+)-[\d.]+$|;
$busnum = $1;
$devnum = readval("$transportdir/devnum");
}
@@ -140,7 +140,7 @@ sub scan_devices_sysfs($) {
# Older kernels, e.g. 2.6.9, don't have the attribute
# busnum:
- m|/(\d+)-\d+$|;
+ m|/(\d+)-[\d.]+$|;
my $busnum = $1 || next;
my $vendor = _get_attr("$_/idVendor");
my $product = _get_attr("$_/idProduct");