diff options
| author | ghost <andreas.monzner@multimedia-labs.de> | 2008-12-02 00:07:43 +0100 |
|---|---|---|
| committer | ghost <andreas.monzner@multimedia-labs.de> | 2008-12-02 00:07:43 +0100 |
| commit | 4030160e538a616edfd896c5cf6481bb458aaabe (patch) | |
| tree | 9d70c0112db1d0670864dec4723198b1d30cd7ef /lib/python/Components/Harddisk.py | |
| parent | 34c1ccf6eaef6f2e8535cb3c0cbe6390835086ef (diff) | |
| download | enigma2-4030160e538a616edfd896c5cf6481bb458aaabe.tar.gz enigma2-4030160e538a616edfd896c5cf6481bb458aaabe.zip | |
fix disc handling for /dev/discs/disc in fstab ...
Diffstat (limited to 'lib/python/Components/Harddisk.py')
| -rw-r--r-- | lib/python/Components/Harddisk.py | 12 |
1 files changed, 7 insertions, 5 deletions
diff --git a/lib/python/Components/Harddisk.py b/lib/python/Components/Harddisk.py index f7c3a7cb..febd16dd 100644 --- a/lib/python/Components/Harddisk.py +++ b/lib/python/Components/Harddisk.py @@ -19,20 +19,22 @@ class Harddisk: s_minor = int(tmp[1]) for disc in listdir("/dev/discs"): path = readlink('/dev/discs/'+disc) - devidex = '/dev'+path[2:]+'/' - disc = devidex+'disc' + devidex = '/dev/discs/'+disc+'/' + devidex2 = '/dev'+path[2:]+'/' + disc = devidex2+'disc' ret = stat(disc).st_rdev if s_major == major(ret) and s_minor == minor(ret): self.devidex = devidex - print "new Harddisk", device, self.devidex + self.devidex2 = devidex2 + print "new Harddisk", device, '->', self.devidex, '->', self.devidex2 break def __lt__(self, ob): return self.device < ob.device def bus(self): - ide_cf = self.device.find("hd") == 0 and self.devidex.find("host0") == -1 # 7025 specific - internal = self.device.find("hd") == 0 and self.devidex + ide_cf = self.device.find("hd") == 0 and self.devidex2.find("host0") == -1 # 7025 specific + internal = self.device.find("hd") == 0 if ide_cf: ret = "External (CF)" elif internal: |
