From 3de1d840e435bce4e2f5cd592593f91ab87cb901 Mon Sep 17 00:00:00 2001 From: Contarino Rosario Date: Wed, 11 May 2011 00:13:53 +0200 Subject: [PATCH] tools/pamusb-conf: Added SDCard support --- tools/pamusb-conf | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/tools/pamusb-conf b/tools/pamusb-conf index 22d0045..03678fc 100755 --- a/tools/pamusb-conf +++ b/tools/pamusb-conf @@ -28,7 +28,9 @@ class Device: udi) deviceProperties = dbus.Interface(deviceObj, dbus.PROPERTIES_IFACE) if deviceProperties.Get('org.freedesktop.UDisks.Device', 'DeviceIsRemovable') != 1: - raise Exception, 'Not a removable device' + # Workaround for removable devices with fixed media (such as SD cards) + if not "mmcblk" in udi: + raise Exception, 'Not a removable device' self.vendor = deviceProperties.Get('org.freedesktop.UDisks.Device', 'DriveVendor') self.product = deviceProperties.Get('org.freedesktop.UDisks.Device', 'DriveModel') self.serialNumber = deviceProperties.Get('org.freedesktop.UDisks.Device', 'DriveSerial')