summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--perl-install/detect_devices.pm4
1 files changed, 3 insertions, 1 deletions
diff --git a/perl-install/detect_devices.pm b/perl-install/detect_devices.pm
index 74d09c887..099b9ca45 100644
--- a/perl-install/detect_devices.pm
+++ b/perl-install/detect_devices.pm
@@ -570,6 +570,7 @@ sub getNet() {
sub getUPS() {
# MGE serial PnP devices:
+ my @usb_devices = usb_probe();
(map {
$_->{port} = $_->{DEVICE};
$_->{bus} = "Serial";
@@ -580,12 +581,13 @@ sub getUPS() {
$_;
} grep { $_->{DESCRIPTION} =~ /MGE UPS/ } values %serialprobe),
# USB UPSs;
+ (grep { $->{description} =~ /American Power Conversion\|Back-UPS/ } @usb_devices),
(map {
($_->{name} = $_->{description}) =~ s/.*\|//;
$_->{port} = "/dev/"; # FIXME
$_->{media_type} = 'UPS';
$_;
- } grep { $_->{driver} =~ /ups$/ } usb_probe());
+ } grep { $_->{driver} =~ /ups$/ } @usb_devices);
}
$pcitable_addons = <<'EOF';