summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--memplugin.h10
-rw-r--r--memplugin_qnx.c28
2 files changed, 10 insertions, 28 deletions
diff --git a/memplugin.h b/memplugin.h
index f4dda8e..816829b 100644
--- a/memplugin.h
+++ b/memplugin.h
@@ -53,6 +53,16 @@
53#define P2H(p) (&(((MemHeader *)(p))[-1])) 53#define P2H(p) (&(((MemHeader *)(p))[-1]))
54#define H2P(h) ((void *)&(h)[1]) 54#define H2P(h) ((void *)&(h)[1])
55 55
56/* MemHeader is important because it is necessary to know the */
57/* size of the parameter buffers on IPU for Cache operations */
58/* The size can't be assumed as codec supports different inputs */
59/* For ex: static params can be VIDDEC3_Params, IVIDDEC3_Params */
60/* or IH264DEC_Params */
61typedef struct MemHeader {
62 int size;
63 void *ptr;
64} MemHeader;
65
56typedef enum mem_type { 66typedef enum mem_type {
57 TILER_1D_BUFFER, 67 TILER_1D_BUFFER,
58 TILER8_2D_BUFFER, 68 TILER8_2D_BUFFER,
diff --git a/memplugin_qnx.c b/memplugin_qnx.c
index 5555037..610a4f9 100644
--- a/memplugin_qnx.c
+++ b/memplugin_qnx.c
@@ -34,34 +34,6 @@
34#include "dce_priv.h" 34#include "dce_priv.h"
35 35
36 36
37/* Would it be good to have MemHeaders for Tiler 2D buffers?? */
38/* Since the decision is to not support allocation of IO buffers, no */
39/* need to worry about Tiler 2D Buffers. Hence below Memheader */
40/* can be used. */
41/*
42typedef struct {
43 dce_memory_type memory_type;
44 union {
45 struct {
46 Uint32 size;
47 Uint32 ducati_addr;
48 } tilerHeader;
49 shm_buf shm_bufHeader;
50 }
51} MemHeader;
52else for Tiler 1D buffers */
53
54/* MemHeader is important because it is necessary to know the */
55/* size of the parameter buffers on IPU for Cache operations */
56/* The size can't be assumed as codec supports different inputs */
57/* For ex: static params can be VIDDEC3_Params, IVIDDEC3_Params */
58/* or IH264DEC_Params */
59typedef struct MemHeader {
60 int size;
61 void *ptr;
62} MemHeader;
63
64
65/* For TILER 2D Buffers : sz = width */ 37/* For TILER 2D Buffers : sz = width */
66/* : height = nonzero */ 38/* : height = nonzero */
67/* For other memory_types : height = 0 */ 39/* For other memory_types : height = 0 */