From 680a3cf81fe52bf300a21cb87f4fbf70a31143d7 Mon Sep 17 00:00:00 2001 From: Lennart Poettering Date: Sat, 6 Jun 2009 23:29:49 +0200 Subject: sound: check ID_VENDOR_FROM_DATABASE before running pci-db/usb-db It is more likely that the vendor id is in the databases than the product id. Hence, check for the vendor id to figure out whether pci-db/usb-db still needs to be run. --- rules.d/78-sound-card.rules | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/rules.d/78-sound-card.rules b/rules.d/78-sound-card.rules index 679e7a3..52b6174 100644 --- a/rules.d/78-sound-card.rules +++ b/rules.d/78-sound-card.rules @@ -38,11 +38,11 @@ KERNEL!="card*", GOTO="sound_end" ENV{SOUND_INITIALIZED}="1" SUBSYSTEMS=="usb", ENV{ID_MODEL}=="", IMPORT{program}="usb_id --export %p" -SUBSYSTEMS=="usb", ENV{ID_MODEL_FROM_DATABASE}=="", IMPORT{program}="usb-db %p" +SUBSYSTEMS=="usb", ENV{ID_VENDOR_FROM_DATABASE}=="", IMPORT{program}="usb-db %p" SUBSYSTEMS=="usb", ATTRS{idVendor}!="", ATTRS{idProduct}!="", ENV{ID_VENDOR_ID}="$attr{idVendor}", ENV{ID_MODEL_ID}="$attr{idProduct}" SUBSYSTEMS=="usb", GOTO="skip_pci" -SUBSYSTEMS=="pci", ENV{ID_MODEL_FROM_DATABASE}=="", IMPORT{program}="pci-db %p" +SUBSYSTEMS=="pci", ENV{ID_VENDOR_FROM_DATABASE}=="", IMPORT{program}="pci-db %p" SUBSYSTEMS=="pci", ENV{ID_BUS}="pci", ENV{ID_VENDOR_ID}="$attr{vendor}", ENV{ID_MODEL_ID}="$attr{device}" # The values used here for $SOUND_FORM_FACTOR should be kept in sync -- cgit