Inconsistent storage.bus and storage.originating_device info

Dan Williams dcbw at redhat.com
Sun Sep 20 20:43:47 PDT 2009


On Sun, 2009-09-20 at 08:05 -0700, Dan Williams wrote:
> On Sun, 2009-09-20 at 15:51 +0100, Baz Walter wrote:
> > hello
> > 
> > i'm writing a small application for portable audio players which needs 
> > to get the vendor_id and some properties from the portable_audio_player 
> > namespace. at the moment, i use dbus to search for all devices with 
> > storage.bus == usb, and then use the storage.originating_device to check 
> > the vendor_id.
> 
> You want '.subsystem', not .bus.  .bus has been deprecated for quite a
> long time.

Sorry, I lied... I was thinking "info.subsystem" which should be used
instead of "info.bus"...  storage appears to still use ".bus".

Dan

> What HAL version are you using?
> 
> Dan
> 
> > unfortunately, sometimes this works and sometimes it doesn't. what i'm 
> > finding is that (apparently ramdomly) the bus will be shown as "pci", 
> > the originating_device as "/org/freedesktop/Hal/devices/computer", and 
> > all the portable_audio_player properties will be missing. other than 
> > showing the wrong information, though, the device works totally 
> > correctly (it's a Samsung YP-P3).
> > 
> > looking in gnome-device-manager i see that the SCSI Host Adapter for the 
> >   relevant Mass Storage Drive appears as a child of the USB Device 
> > rather than the USB Mass Storage Interface. The correct UMS interface is 
> > there - it just isn't linked to the correct SCSI Host Adapter.
> > 
> > so is this a problem with hal, or with hal-info?
> > 
> > is there a reliable way to get the relevant UMS Interface that doesn't 
> > depend on querying storage.originating_device?
> > 
> > some info about my setup:
> > 
> > distro: mandriva 2009.1
> > hal : 0.5.12-0.rc1.20090403.1mdv2009.1
> > hal-info : 0.0-5.20090414.1mdv2009.1
> > udev : 140-3.2mnb2
> > hotplug : 2.4.4-2mdv2009.1
> > kernel : 2.6.29.6-2mnb2
> > policykit : 0.9-5mdv2009.1
> > consolekit : 0.3.0-5mdv2009.1
> > 
> > TIA
> > baz walter
> > _______________________________________________
> > hal mailing list
> > hal at lists.freedesktop.org
> > http://lists.freedesktop.org/mailman/listinfo/hal
> 
> _______________________________________________
> hal mailing list
> hal at lists.freedesktop.org
> http://lists.freedesktop.org/mailman/listinfo/hal



More information about the hal mailing list