Review Request: Fix audioCD properties with solid udisks backend

Luc Menut lmenut at free.fr
Sun Oct 16 11:39:09 BST 2011


-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
http://git.reviewboard.kde.org/r/102892/
-----------------------------------------------------------

Review request for kdelibs, Kevin Ottens and Lukáš Tinkl.


Description
-------

Currently, the udisks backend provides some inaccurate informations for AudioCD.
In audioCD.log in attachment, you can find the output of 'udev/cdrom_id', 'udisks --show-info' and 'solid-hardware details' for an audioCD.
- StorageVolume.ignored is incorrectly reported as true, because "IdUsage" is empty for audioCD ( (1) in the logs), so that UDisksDevice::isDeviceBlacklisted return true. To fix this, I add an exception for audioCD (when OpticalDiscNumAudioTracks >0) like for empty opticaldisc.
- OpticalDisc.availableContent = 'Audio|Data' for CDDA (which don't contain any data tracks), because the udev's prop ID_CDROM_MEDIA_TRACK_COUNT counts all the tracks ( http://hal.freedesktop.org/docs/udisks/Device.html#Device:OpticalDiscNumTracks ) and not only the number of data tracks (the number of data tracks is available in udev's ID_CDROM_MEDIA_TRACK_COUNT_DATA, but currently this property isn't used by udisks). Consequently, in OpticalDisc::availableContent(), hasData should be true only if OpticalDiscNumTracks > OpticalDiscNumAudioTracks  ( (2) in log).

regards,
Luc Menut
Mageia Contributor

PS: I don't have write access to kde git, so could you commit the change for me if the patch looks fine. Thanks.


This addresses bugs 265870 and 280229.
    http://bugs.kde.org/show_bug.cgi?id=265870
    http://bugs.kde.org/show_bug.cgi?id=280229


Diffs
-----

  solid/solid/backends/udisks/udisksdevice.cpp c76eebc 
  solid/solid/backends/udisks/udisksopticaldisc.cpp 378195c 

Diff: http://git.reviewboard.kde.org/r/102892/diff/diff


Testing
-------

tested with KDE 4.7.2 (Mageia Cauldron)


Thanks,

Luc Menut

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/kde-core-devel/attachments/20111016/e87454d4/attachment.htm>


More information about the kde-core-devel mailing list