aboutsummaryrefslogtreecommitdiff
path: root/lib/python
diff options
context:
space:
mode:
authorFelix Domke <tmbinc@elitedvb.net>2009-06-08 14:18:48 +0200
committerFelix Domke <tmbinc@elitedvb.net>2009-06-08 14:18:48 +0200
commit1736046db88e13842e67396da8ee7b02ece75443 (patch)
treea95a0bd6db6188e9968205c4d9d17eb061606e09 /lib/python
parente26b2adba2dad6e9c25196d841657d31e4f21046 (diff)
downloadenigma2-1736046db88e13842e67396da8ee7b02ece75443.tar.gz
enigma2-1736046db88e13842e67396da8ee7b02ece75443.zip
make DEVICEDB depending on model type
Diffstat (limited to 'lib/python')
-rwxr-xr-xlib/python/Components/Harddisk.py21
1 files changed, 15 insertions, 6 deletions
diff --git a/lib/python/Components/Harddisk.py b/lib/python/Components/Harddisk.py
index 0d141248..18616bf2 100755
--- a/lib/python/Components/Harddisk.py
+++ b/lib/python/Components/Harddisk.py
@@ -329,19 +329,27 @@ class Partition:
return False
DEVICEDB = \
+ {"dm8000":
+ {
+ # dm8000:
+ "/devices/platform/brcm-ehci.0/usb1/1-1/1-1.1/1-1.1:1.0": "Front USB Slot",
+ "/devices/platform/brcm-ehci.0/usb1/1-1/1-1.2/1-1.2:1.0": "Back, upper USB Slot",
+ "/devices/platform/brcm-ehci.0/usb1/1-1/1-1.3/1-1.3:1.0": "Back, lower USB Slot",
+ "/devices/platform/brcm-ehci-1.1/usb2/2-1/2-1:1.0/host1/target1:0:0/1:0:0:0": "DVD Drive",
+ },
+ "dm800":
{
- # dm8000:
- "/devices/platform/brcm-ehci.0/usb1/1-1/1-1.1/1-1.1:1.0": "Front USB Slot",
- "/devices/platform/brcm-ehci.0/usb1/1-1/1-1.2/1-1.2:1.0": "Back, upper USB Slot",
- "/devices/platform/brcm-ehci.0/usb1/1-1/1-1.3/1-1.3:1.0": "Back, lower USB Slot",
- "/devices/platform/brcm-ehci-1.1/usb2/2-1/2-1:1.0/host1/target1:0:0/1:0:0:0": "DVD Drive",
# dm800:
"/devices/platform/brcm-ehci.0/usb1/1-2/1-2:1.0": "Upper USB Slot",
"/devices/platform/brcm-ehci.0/usb1/1-1/1-1:1.0": "Lower USB Slot",
+ },
+ "dm7025":
+ {
# dm7025:
"/devices/pci0000:00/0000:00:14.1/ide1/1.0": "CF Card Slot", #hdc
"/devices/pci0000:00/0000:00:14.1/ide0/0.0": "Internal Harddisk"
}
+ }
class HarddiskManager:
def __init__(self):
@@ -519,7 +527,8 @@ class HarddiskManager:
description = open("/sys" + phys + "/model").read().strip()
except IOError, s:
print "couldn't read model: ", s
- for physdevprefix, pdescription in DEVICEDB.items():
+ from Tools.HardwareInfo import HardwareInfo
+ for physdevprefix, pdescription in DEVICEDB.get(HardwareInfo().device_name,{}).items():
if phys.startswith(physdevprefix):
description = pdescription