On a new ARM9 board with memory mapped interface to a compact flash
socket, I need to implement an IDE or ATA driver that will support TRUE
IDE mode.
Am using kernel version 2.6.26
What is the best starting point, i.e. example driver in the tree?
Please respond to my personal email address also as I do not subscribe.
TIA
On Thursday 08 January 2009, Dick Hollenbeck wrote:
> On a new ARM9 board with memory mapped interface to a compact flash
> socket, I need to implement an IDE or ATA driver that will support TRUE
> IDE mode.
>
> Am using kernel version 2.6.26
>
> What is the best starting point, i.e. example driver in the tree?
You should not need to write a new driver, but rather use the existing
drivers/ata/pata_platform.c driver by registering the MMIO registers
and IRQ number as a platform device.
Arnd <><
Arnd Bergmann wrote:
> On Thursday 08 January 2009, Dick Hollenbeck wrote:
>
>> On a new ARM9 board with memory mapped interface to a compact flash
>> socket, I need to implement an IDE or ATA driver that will support TRUE
>> IDE mode.
>>
>> Am using kernel version 2.6.26
>>
>> What is the best starting point, i.e. example driver in the tree?
>>
>
> You should not need to write a new driver, but rather use the existing
> drivers/ata/pata_platform.c driver by registering the MMIO registers
> and IRQ number as a platform device.
>
> Arnd <><
>
Thank you Arnd!
Is there some example code in the tree to do this?
I've done something similar to this for 8250 serial ports, but I am
having a difficult time finding out how to do this with pata_platform.c
Thanks,
Dick Hollenbeck
On Thursday 08 January 2009, Dick Hollenbeck wrote:
> I've done something similar to this for 8250 serial ports, but I am
> having a difficult time finding out how to do this with pata_platform.c
>
Just grep for pata_platform_info to find example code.
Arnd <><
Arnd Bergmann wrote:
> On Thursday 08 January 2009, Dick Hollenbeck wrote:
>
>> I've done something similar to this for 8250 serial ports, but I am
>> having a difficult time finding out how to do this with pata_platform.c
>>
>>
>
> Just grep for pata_platform_info to find example code.
>
> Arnd <><
>
Thanks again Arnd. I did that yesterday and got it working last night!
The only thing I have questions about are:
1) Since this is for a quasi realtime application, is there any
advantage to using the interrupt line regarding how the CPU spends its
idle time waiting for the flash? (I have an interrupt line I can use.)
Currently I am not sending in the IRQ resource, resource array length of
2, not 3.
2) I am getting this message during boot up: "Driver 'sd' needs
updating - please use bus_type methods". Again this is kernel 2.6.26.
It seems like this can be safely ignored, but if its easy to get rid of
that I would be happy to back port a patch.
I really appreciate your help.
Dick Hollenbeck
> 1) Since this is for a quasi realtime application, is there any
> advantage to using the interrupt line regarding how the CPU spends its
> idle time waiting for the flash? (I have an interrupt line I can use.)
> Currently I am not sending in the IRQ resource, resource array length of
> 2, not 3.
For real time you may actually be better with the IRQless polling
behaviour as the driver and ATA library currently stands.
Dick Hollenbeck wrote:
> On a new ARM9 board with memory mapped interface to a compact flash
> socket, I need to implement an IDE or ATA driver that will support TRUE
> IDE mode.
>
> Am using kernel version 2.6.26
>
> What is the best starting point, i.e. example driver in the tree?
>
>
> Please respond to my personal email address also as I do not subscribe.
>
Not that it is a piece of art, but this is my implementation of a
similar driver that I am trying to get merged.
http://marc.info/?l=linux-ide&m=122895233817240&w=4
David Daney