linux-omap.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* Simple GPMC device driver with basic User application
       [not found] <CAOy7-nNxRgB21JSFcWvD4T3AwDDuh9MjBeB+8nFiwX-Cv+13Mw@mail.gmail.com>
@ 2011-10-24  1:47 ` James
  2011-11-03 19:25   ` Tony Lindgren
  0 siblings, 1 reply; 4+ messages in thread
From: James @ 2011-10-24  1:47 UTC (permalink / raw)
  To: linux-omap

Dear all,

I'm learning embedded linux development and need help on my task.

I'm trying to communicate with a FPGA via the GPMC bus on my Overo FE
board and need assistance with writing a simple device driver & test
application that uses the GPMC bus to read & write a WORD size data
and also a BLOCK of WORD data to the FPGA.

The FPGA-OMAP3530 will be use synchronous read/write over the 16-bit
datapath and CS 6.
The GPMC bus is shared with an Ethernet chip and NAND chip as per
Gumstix COM + TOBI/Chestnut design and these standard devices must
still work as per norm.

I've been searching via GMANE for similar questions but some are
pointing to non-existence archives.

I believe I have to develop a kernel device driver to register the
FPGA and from which will expose a device node for the test
application.
or is there a generic GPMC driver that does it?

Can someone share with me similar layout and code so that I can base
my learning from a starting point?

Many thanks in adv.

--
Regards,
James

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: Simple GPMC device driver with basic User application
  2011-10-24  1:47 ` Simple GPMC device driver with basic User application James
@ 2011-11-03 19:25   ` Tony Lindgren
  2011-11-04 11:48     ` Philip Balister
  0 siblings, 1 reply; 4+ messages in thread
From: Tony Lindgren @ 2011-11-03 19:25 UTC (permalink / raw)
  To: James; +Cc: linux-omap

* James <angweiyang@gmail.com> [111023 18:13]:
> Dear all,
> 
> I'm learning embedded linux development and need help on my task.
> 
> I'm trying to communicate with a FPGA via the GPMC bus on my Overo FE
> board and need assistance with writing a simple device driver & test
> application that uses the GPMC bus to read & write a WORD size data
> and also a BLOCK of WORD data to the FPGA.
> 
> The FPGA-OMAP3530 will be use synchronous read/write over the 16-bit
> datapath and CS 6.
> The GPMC bus is shared with an Ethernet chip and NAND chip as per
> Gumstix COM + TOBI/Chestnut design and these standard devices must
> still work as per norm.
> 
> I've been searching via GMANE for similar questions but some are
> pointing to non-existence archives.
> 
> I believe I have to develop a kernel device driver to register the
> FPGA and from which will expose a device node for the test
> application.
> or is there a generic GPMC driver that does it?
> 
> Can someone share with me similar layout and code so that I can base
> my learning from a starting point?
> 
> Many thanks in adv.

Please take a look at the various arch/arm/mach-omap2/gpmc-*.c files.
The biggest pain is to get the timings right.

Tony

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: Simple GPMC device driver with basic User application
  2011-11-03 19:25   ` Tony Lindgren
@ 2011-11-04 11:48     ` Philip Balister
  2011-11-08  2:07       ` James
  0 siblings, 1 reply; 4+ messages in thread
From: Philip Balister @ 2011-11-04 11:48 UTC (permalink / raw)
  To: Tony Lindgren; +Cc: James, linux-omap

On 11/03/2011 03:25 PM, Tony Lindgren wrote:
> * James <angweiyang@gmail.com> [111023 18:13]:
>> Dear all,
>>
>> I'm learning embedded linux development and need help on my task.
>>
>> I'm trying to communicate with a FPGA via the GPMC bus on my Overo FE
>> board and need assistance with writing a simple device driver & test
>> application that uses the GPMC bus to read & write a WORD size data
>> and also a BLOCK of WORD data to the FPGA.
>>
>> The FPGA-OMAP3530 will be use synchronous read/write over the 16-bit
>> datapath and CS 6.
>> The GPMC bus is shared with an Ethernet chip and NAND chip as per
>> Gumstix COM + TOBI/Chestnut design and these standard devices must
>> still work as per norm.
>>
>> I've been searching via GMANE for similar questions but some are
>> pointing to non-existence archives.
>>
>> I believe I have to develop a kernel device driver to register the
>> FPGA and from which will expose a device node for the test
>> application.
>> or is there a generic GPMC driver that does it?
>>
>> Can someone share with me similar layout and code so that I can base
>> my learning from a starting point?
>>
>> Many thanks in adv.
> 
> Please take a look at the various arch/arm/mach-omap2/gpmc-*.c files.
> The biggest pain is to get the timings right.

Also take a look at:

https://github.com/balister/linux-omap-philip/commits/e100-2.6.38-2

Philip

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: Simple GPMC device driver with basic User application
  2011-11-04 11:48     ` Philip Balister
@ 2011-11-08  2:07       ` James
  0 siblings, 0 replies; 4+ messages in thread
From: James @ 2011-11-08  2:07 UTC (permalink / raw)
  To: Philip Balister; +Cc: Tony Lindgren, linux-omap

Hi Philip,

On Fri, Nov 4, 2011 at 7:48 PM, Philip Balister <philip@balister.org> wrote:
> On 11/03/2011 03:25 PM, Tony Lindgren wrote:
>> * James <angweiyang@gmail.com> [111023 18:13]:
>>> Dear all,
>>>
>>> I'm learning embedded linux development and need help on my task.
>>>
>>> I'm trying to communicate with a FPGA via the GPMC bus on my Overo FE
>>> board and need assistance with writing a simple device driver & test
>>> application that uses the GPMC bus to read & write a WORD size data
>>> and also a BLOCK of WORD data to the FPGA.
>>>
>>> The FPGA-OMAP3530 will be use synchronous read/write over the 16-bit
>>> datapath and CS 6.
>>> The GPMC bus is shared with an Ethernet chip and NAND chip as per
>>> Gumstix COM + TOBI/Chestnut design and these standard devices must
>>> still work as per norm.
>>>
>>> I've been searching via GMANE for similar questions but some are
>>> pointing to non-existence archives.
>>>
>>> I believe I have to develop a kernel device driver to register the
>>> FPGA and from which will expose a device node for the test
>>> application.
>>> or is there a generic GPMC driver that does it?
>>>
>>> Can someone share with me similar layout and code so that I can base
>>> my learning from a starting point?
>>>
>>> Many thanks in adv.
>>
>> Please take a look at the various arch/arm/mach-omap2/gpmc-*.c files.
>> The biggest pain is to get the timings right.
>
> Also take a look at:
>
> https://github.com/balister/linux-omap-philip/commits/e100-2.6.38-2
>
> Philip
>

I've been reading the codes from your e100-2.6.38-2 repo as suggested
by your earlier replies to me in Gumstix Mailing List. (^^,)

In usrp1_e_init() inside board-overo.c, GPMC_CS_CONFIG7 for both CS4
and CS6 are both written with 0x00.

I couldn't understand the background/why behind this line of code as
the Use-case in the TRM writes the base address of the device to it.

Do you have some timing diagram or documents that explains the data
flow / interactions / protocol between the FPGA and Overo as reference
to the codes?

Many many thanks in adv.

-- 
Regards,
James

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2011-11-08  2:07 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
     [not found] <CAOy7-nNxRgB21JSFcWvD4T3AwDDuh9MjBeB+8nFiwX-Cv+13Mw@mail.gmail.com>
2011-10-24  1:47 ` Simple GPMC device driver with basic User application James
2011-11-03 19:25   ` Tony Lindgren
2011-11-04 11:48     ` Philip Balister
2011-11-08  2:07       ` James

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).