Mistake on this page?
Report an issue in GitHub or email us
EMACMemoryManager.h
1 /* Copyright (c) 2017 ARM Limited
2  *
3  * Licensed under the Apache License, Version 2.0 (the "License");
4  * you may not use this file except in compliance with the License.
5  * You may obtain a copy of the License at
6  *
7  * http://www.apache.org/licenses/LICENSE-2.0
8  *
9  * Unless required by applicable law or agreed to in writing, software
10  * distributed under the License is distributed on an "AS IS" BASIS,
11  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12  * See the License for the specific language governing permissions and
13  * limitations under the License.
14  */
15 
16 #ifndef EMAC_MEMORY_MANAGER_H
17 #define EMAC_MEMORY_MANAGER_H
18 
19 /**
20  * Emac interface memory manager
21  *
22  * This interface provides abstraction for memory modules used in different IP stacks (often to accommodate zero
23  * copy). Emac interface is required to accept output packets and provide received data using this stack-
24  * independent API. This header should be implemented for each IP stack, so that we keep emacs module independent.
25  *
26  * Emac memory interface uses memory buffer chains to store data. Data passed in either direction
27  * may be either contiguous (a single-buffer chain), or may consist of multiple buffers.
28  * Chaining of the buffers is made using singly-linked list. The Emac data-passing APIs do not specify
29  * alignment or structure of the chain in either direction.
30  *
31  * Memory buffers can be allocated either from heap or from memory pools. Heap buffers are always contiguous.
32  * Memory pool buffers may be either contiguous or chained depending on allocation size.
33  *
34  * On Emac interface buffer chain ownership is transferred. Emac must free buffer chain that it is given for
35  * link output and the stack must free the buffer chain that it is given for link input.
36  *
37  */
38 
39 #include "nsapi.h"
40 #include "NetStackMemoryManager.h"
41 
42 typedef void emac_mem_buf_t; // Memory buffer
43 
45 
46 };
47 
48 #endif /* EMAC_MEMORY_MANAGER_H */
Important Information for this Arm website

This site uses cookies to store information on your computer. By continuing to use our site, you consent to our cookies. If you are not happy with the use of these cookies, please review our Cookie Policy to learn how they can be disabled. By disabling cookies, some features of the site will not work.