tests/vfs_fat_ramdisk: Switch to ioctl-based blockdev API.

This commit is contained in:
Paul Sokolovsky 2016-02-14 20:45:08 +02:00
parent 9e0478a902
commit 9d0525182d

View File

@ -21,10 +21,9 @@ class RAMFS:
for i in range(len(buf)): for i in range(len(buf)):
self.data[n*512+i] = buf[i] self.data[n*512+i] = buf[i]
def sync(self): def ioctl(self, op, arg):
pass #print("ioctl(%d, %r)" % (op, arg))
if op == 4: # BP_IOCTL_SEC_COUNT
def count(self):
return len(self.data) // 512 return len(self.data) // 512