This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

GPMC WAIT pin monitoring timeout.

I plan to use the GPMC to communicate with a FPGA  in synchronous NOR-like mode of operation. The WAIT pin will be used to check readyness of the FPGA with timeout enabled in order not to block the GPMC bus for too long, to which also a NAND memory will be connected. My question is how will linux react to a timeout occurence on the WAIT pin?

I plan to use the am335x processor.

  • Hi,

    The GPMC error-handling mechanism is described in section 7.1.3.3.8.4 of the AM335X Technical Reference Manual Rev. L. I will ask the SW team to comment if/how this is handled in the Sitara Processor SDK.

  • Hi,

    In order to enable the wait pin you need to define:
    - gpmc,wait-pin Wait-pin used by client. Must be less than
    "gpmc,num-waitpins".
    - gpmc,wait-on-read Enables wait monitoring on reads.
    - gpmc,wait-on-write Enables wait monitoring on writes.

    in gpmc dts node.

    Later in arch/arm/mach-omap2/gpmc.c these settings are applied. Check:
    gpmc_read_settings_dt(), gpmc_cs_program_settings()

    Hope this helps.

    Best Regards,
    Yordan
  • Thanks for the reply.
    The TRM states: "The GPMC does not generate interrupts on these errors. True abort to the MPU or interrupt generation is
    handled at the interconnect level."
    If I understand it correctly: when a timeout occurs then some kind of exception will be signalled like segmentation fault in linux?
    Can this behaviour be changed?
    Best Regards
  • Hi,

    As far as I know, the device cannot handle timeout error, the way to recover from a timeout is software to reset the module that returned the error.
    See drivers/bus/omap_l3_* sources to get familiar with error handling within the interconnect.

    So it is highly recommended to implement some kind of delays, in order to avoid timeout errors.

    Best Regards,
    Yordan