EMBEDDED FILESYSTEM CONTROLLER / DRIVER
Posted: Fri Dec 30, 2005 6:27 am
Hey guys
I don't know if this has been thought of or done before but it just came to my mind.
-We implement filesystem drivers in software, usu. OS modules or drivers. AFAIK, calls to these drivers are costly even if due care is taken. The cost is in terms of overhead. Moreover, they consume the central processor time, which is the most important aspect of software filesystem driver.
-Instead, if we implement the FS driver/Handler in a hardware interface [EMBEDDED FILESYSTEM CONTROLLER / DRIVER] between the actual physical storage device like HDD and the storage controller like IDE, (S/P)ATA or say PCI [Maybe PCI Extreme], then we can issue the FS specific commands to our intermediate controller hardware. While our hardware processes the command, the central processor is free to do other tasks.
-This will effectively reduce the central processor time spent in just handling the FS and the physical storage medium like HDD.
-Also, reverse engineering of proprietary filesystem designs like NTFS will be tougher.
-Any disk with the attached controller will be accessible in any OS, provided some basic software driver support is coded for that target OS. eg. you will be able to use ext3 FS in windows or NTFS in DOS or WIN98 or even Linux with read-write support. (This will require direct support and involvement from Microsoft). [this may create an entirely new class of problems]
!~~~~The actual hardware interface~~~~
-Let us assume our device as an interface between an existing peripheral controller present on the motherboard like PCI, and the storage device such as HDD/RAID.
-We take commands from the MthrBrd device [let's consider PCI from hereafter], interpret them, then command and control and manage the underlaying physical storage device [consider HDD from now on]. That means our device must interface with both the motherboard controller and the HDD device. The device will also handle request queues [one of the costly things to manage in kernel mode].
-The device will handle all opened files etc.
-Two devices will communicate with each other and file copying among them will not involve central processor.*
-The device will schedule physical disk access according to the requesting task's effective priority, and a suitable head/seek scheduling algorithm such as C-SCAN or Elevator etc.*
!~~~~Probable problems~~~~
-The major problem can be that of inflexibility, in the sense that you won't be able to switch filesystems eg. in normal, standard scenario, the same hard disk can be used to store files in FAT as well as ext3 filesystem at different times; but this won't be possible as easily and on the fly since the logic implementation is in hardware.
-If implemented using a standard microcontroller, operation & data transfer speeds can be far less than normal.
-Even though we are implementing some FS handling code in hardware, we will need our own software driver to give specific commands to our device. Thus, inevitably, we gotta implement a software driver; the only advantage is that much more processing is done in hardware controller parallel to the central processor, but still the overhead 'system call' to kernel code prevails.
-Whether it is the storage device or our device, we need to handle a device.
-Due to limited memory in or interfaceable with the microcontroller, the number of files that can be opened and handled is limited. The file bufers are also limited.If this memory is increased, cost shoots up.
-Designing it so as to support ALL existing and future Operating Systems is a difficult job.
-It may not be accessible under Cave-man-os like MSDOS. Even if you write software driver for it, you may need some other native bootable disk.
-Handling some OS and FS specific details and constraints such as users, security info, their quotas, their encryption keys etc. will need to be incorporated in software driver. It is a mammoth task for embedded processor. Excellent examples are NTFS and ext filesystems. No idea about RAID.
I don't know if this has been thought of or done before but it just came to my mind.
-We implement filesystem drivers in software, usu. OS modules or drivers. AFAIK, calls to these drivers are costly even if due care is taken. The cost is in terms of overhead. Moreover, they consume the central processor time, which is the most important aspect of software filesystem driver.
-Instead, if we implement the FS driver/Handler in a hardware interface [EMBEDDED FILESYSTEM CONTROLLER / DRIVER] between the actual physical storage device like HDD and the storage controller like IDE, (S/P)ATA or say PCI [Maybe PCI Extreme], then we can issue the FS specific commands to our intermediate controller hardware. While our hardware processes the command, the central processor is free to do other tasks.
-This will effectively reduce the central processor time spent in just handling the FS and the physical storage medium like HDD.
-Also, reverse engineering of proprietary filesystem designs like NTFS will be tougher.
-Any disk with the attached controller will be accessible in any OS, provided some basic software driver support is coded for that target OS. eg. you will be able to use ext3 FS in windows or NTFS in DOS or WIN98 or even Linux with read-write support. (This will require direct support and involvement from Microsoft). [this may create an entirely new class of problems]
!~~~~The actual hardware interface~~~~
-Let us assume our device as an interface between an existing peripheral controller present on the motherboard like PCI, and the storage device such as HDD/RAID.
-We take commands from the MthrBrd device [let's consider PCI from hereafter], interpret them, then command and control and manage the underlaying physical storage device [consider HDD from now on]. That means our device must interface with both the motherboard controller and the HDD device. The device will also handle request queues [one of the costly things to manage in kernel mode].
-The device will handle all opened files etc.
-Two devices will communicate with each other and file copying among them will not involve central processor.*
-The device will schedule physical disk access according to the requesting task's effective priority, and a suitable head/seek scheduling algorithm such as C-SCAN or Elevator etc.*
!~~~~Probable problems~~~~
-The major problem can be that of inflexibility, in the sense that you won't be able to switch filesystems eg. in normal, standard scenario, the same hard disk can be used to store files in FAT as well as ext3 filesystem at different times; but this won't be possible as easily and on the fly since the logic implementation is in hardware.
-If implemented using a standard microcontroller, operation & data transfer speeds can be far less than normal.
-Even though we are implementing some FS handling code in hardware, we will need our own software driver to give specific commands to our device. Thus, inevitably, we gotta implement a software driver; the only advantage is that much more processing is done in hardware controller parallel to the central processor, but still the overhead 'system call' to kernel code prevails.
-Whether it is the storage device or our device, we need to handle a device.
-Due to limited memory in or interfaceable with the microcontroller, the number of files that can be opened and handled is limited. The file bufers are also limited.If this memory is increased, cost shoots up.
-Designing it so as to support ALL existing and future Operating Systems is a difficult job.
-It may not be accessible under Cave-man-os like MSDOS. Even if you write software driver for it, you may need some other native bootable disk.
-Handling some OS and FS specific details and constraints such as users, security info, their quotas, their encryption keys etc. will need to be incorporated in software driver. It is a mammoth task for embedded processor. Excellent examples are NTFS and ext filesystems. No idea about RAID.