Changes between Version 16 and Version 17 of cma_driver


Ignore:
Timestamp:
Jul 15, 2015, 6:51:43 PM (9 years ago)
Author:
bellefin
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • cma_driver

    v16 v17  
    1212 * '''OUT OF ORDER''' : The controller scan all the source buffers, and the first full buffer found is read. Similarly, the controller scan all the destination buffers, and the first empty buffer found is written, with a round robin priority for the search. This mode is activated when the CHBUF_PERIOD value is zero (default value).
    1313
    14 A ''chbuf'' descriptor is a variable size circular array of 64 bits entries. Each entry is a single buffer descriptor, and
    15 contains a 48 bits physical address (PADDR) and a valid bit V that is 0 when the buffer is empty.
    16 ||1||    15   ||       48                                       ||
    17 ||V||   unused || ------- PADDR ---------   ||
     14The state of each buffer must be defined in a variable called ''status''. Each “status” occupies 64 bytes, but only the last bit is useful (1 if the buffer is full, 0 if it is empty). A buffer and its status physical addresses must be 64 bytes aligned and must have the same extension (identical bits[43:32]).
     15
     16A ''chbuf descriptor'' is a variable size circular array of 64 bits entries. Each entry is a single buffer descriptor and contains the physical addresses (PADDR) of the buffer and the status variable :
     17 * The 12 MSB bits contain the common extension of the buffer address and the buffer status address
     18 * The 26 following bits contain the bits [31:6] of the buffer address
     19 * The 26 LSB bits contain the bits [31:6] of the buffer status address
     20
     21|| 12 || 26 || 26 ||
     22|| buffer_paddr[43:32] = status_paddr[43:32] || buffer_paddr[31:6] || status_paddr[31:6] ||
    1823
    1924The SEG_CMA_BASE address must be defined in the hard_config.h file.
     
    3439A CMA IRQ is activated in case of memory access error for a specific CMA channel. There is 4 types of errors:
    3540 * SRC_DESC_ERROR : error accessing source chbuf descriptor
    36  * SRC_DATA_ERROR : error accessing source data buffer
     41 * SRC_STATUS_ERROR : error accessing source buffer status
    3742 * DST_DESC_ERROR : error accessing destination chbuf descriptor
    38  * DST_DATA_ERROR : error accessing destination data buffer
     43 * DST_STATUS_ERROR : error accessing destination buffer status
     44 * DATA_ERROR : error accessing source or destination data buffer
    3945The Interrupt Service Routine displays a message on TTY0 and desactivates the CMA channel to acknowledge IRQ.
    4046