Electronic Components Datasheet Search
  English  ▼

X  

UM0851 Datasheet(PDF) 165 Page - STMicroelectronics

Part # UM0851
Description  SPEAr is a family of highly customizable ARM-based embedded
PDF  245 Pages
Scroll/Zoom Zoom In 100%  Zoom Out
Manufacturer  STMICROELECTRONICS [STMicroelectronics]
Direct Link  http://www.st.com
Logo STMICROELECTRONICS - STMicroelectronics

UM0851 Datasheet(HTML) 165 Page - STMicroelectronics

Back Button UM0851 Datasheet HTML 161Page - STMicroelectronics UM0851 Datasheet HTML 162Page - STMicroelectronics UM0851 Datasheet HTML 163Page - STMicroelectronics UM0851 Datasheet HTML 164Page - STMicroelectronics UM0851 Datasheet HTML 165Page - STMicroelectronics UM0851 Datasheet HTML 166Page - STMicroelectronics UM0851 Datasheet HTML 167Page - STMicroelectronics UM0851 Datasheet HTML 168Page - STMicroelectronics UM0851 Datasheet HTML 169Page - STMicroelectronics Next Button
Zoom Inzoom in Zoom Outzoom out
 165 / 245 page
background image
UM0851
Accelerator engine device drivers
Doc ID 16604 Rev 2
165/245
Client registration
A client can register with the framework by using the following call:
dma_async_client_register(&dma_client1);
/* dma_client1 is an instance of struct dma_client present in
include/linux/dmaengine.h */
struct dma_client {
dma_event_callback
event_callback;
/* Function ptr for DMA framework purposes
(Mandatory). */
dma_cap_mask_t cap_mask;
/* Capability of the DMA Channel to be
requested, a value of zero corresponds to
any capability (Mandatory) */
struct dma_slave
*slave;
/* Data for preparing slave transfer. Must
be non-NULL if the DMA_SLAVE capability is
requested (Optional) */
struct list_head
global_node;
/* list_head for global dma_client_list
(Not for user driver) */
};
/* CAP can be one of DMA_MEMCPY (memory to memory), DMA_MEMSET(memory to memory),
DMA_SLAVE(peripheral to peripheral or memory to/from peripheral).
*/
/* Prototype of this event_callback. */
static enum dma_state_client dma_event(struct dma_client *client, struct dma_chan
*chan, enum dma_state state);
/* cap_mask can be set using following function */
dma_cap_set(CAP, dma_client1.cap_mask);
After registering the client, you must request the DMA channels for transferring data. This
can be done using following call:
dma_async_client_chan_request(&dma_client1);
The DMA framework calls the dma_event() function twice, once for channel allocation and
once for channel removal. The value of enum dma_state state is:
●
DMA_RESOURCE_AVAILABLE during channel allocation, and
●
DMA_RESOURCE_REMOVED during channel removal.
You have to check the value of the state variable in dma_event() to determine the cause of
the function call.
During channel allocation, dma_event() is called for every free DMA channel available that
satisfies the capability requested by the client. This callback is called until you return
DMA_NAK from the dma_event() function. Suppose there are 8 DMA channels available
and you need only three of them, then you must return DMA_ACK on the first three calls to
event_callback() and return DMA_NAK on the fourth call. In addition, you must save all the
struct dma_chan *chan parameters passed to event_callback(), chan is a pointer to the
DMA channel which is currently allocated to the client.
During channel removal, dma_event() is called for every DMA channel allocated to the
client. You must return DMA_ACK for the channels you want to free.



Html Pages

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100  ...More


Datasheet Download

Go To PDF Page


Link URL



Does ALLDATASHEET help your business so far?  [ DONATE ] 

About Alldatasheet   |   Advertisement   |   Contact us   |   Privacy Policy   |   Link to Datasheet    |   Link Exchange   |   Manufacturer List
All Rights Reserved©Alldatasheet.com


Mirror Sites
English : Alldatasheet.com  |   English : Alldatasheet.net  |   Chinese : Alldatasheetcn.com  |   German : Alldatasheetde.com  |   Japanese : Alldatasheet.jp
Russian : Alldatasheetru.com  |   Korean : Alldatasheet.co.kr  |   Spanish : Alldatasheet.es  |   French : Alldatasheet.fr  |   Italian : Alldatasheetit.com
Portuguese : Alldatasheetpt.com  |   Polish : Alldatasheet.pl  |   Vietnamese : Alldatasheet.vn
Indian : Alldatasheet.in  |   Mexican : Alldatasheet.com.mx  |   British : Alldatasheet.co.uk  |   New Zealand : Alldatasheet.co.nz
Family Site : ic2ic.com  |   icmetro.com