diff options
author | Nitin A Kamble <nitin.a.kamble@intel.com> | 2012-09-18 12:16:07 -0700 |
---|---|---|
committer | Tom Zanussi <tom.zanussi@intel.com> | 2012-12-03 14:20:44 -0600 |
commit | 6eed0090597bfe82603be5ffa9c9f1fd141306f0 (patch) | |
tree | e4e16247f8ae3b3ad3a1426f59af2dcf5668e533 /meta-emenlow/recipes-graphics/libva/libva-0.31.0/390_compat.base.patch | |
parent | b4141a6404fa7d3445d660860b6bf68acec9f114 (diff) | |
download | meta-intel-6eed0090597bfe82603be5ffa9c9f1fd141306f0.tar.gz |
emenlow: use emgd instead of psb for graphics driver
Remove all the Poulsbo graphics driver specific meta data files.
And configure the BSP to use EMGD instead of psb for graphics stack.
Signed-off-by: Nitin A Kamble <nitin.a.kamble@intel.com>
Signed-off-by: Tom Zanussi <tom.zanussi@intel.com>
Diffstat (limited to 'meta-emenlow/recipes-graphics/libva/libva-0.31.0/390_compat.base.patch')
-rw-r--r-- | meta-emenlow/recipes-graphics/libva/libva-0.31.0/390_compat.base.patch | 135 |
1 files changed, 0 insertions, 135 deletions
diff --git a/meta-emenlow/recipes-graphics/libva/libva-0.31.0/390_compat.base.patch b/meta-emenlow/recipes-graphics/libva/libva-0.31.0/390_compat.base.patch deleted file mode 100644 index f2e0d61b..00000000 --- a/meta-emenlow/recipes-graphics/libva/libva-0.31.0/390_compat.base.patch +++ /dev/null | |||
@@ -1,135 +0,0 @@ | |||
1 | commit 483bc9e67afa9bcd8f99f08a74a78e7dfad4651f | ||
2 | Author: Gwenole Beauchesne <gbeauchesne@splitted-desktop.com> | ||
3 | Date: Thu Jul 2 09:24:04 2009 +0000 | ||
4 | |||
5 | Fix make dist (va_compat_template.h). | ||
6 | |||
7 | commit 0e0da9ea861f14e8129767dbf6f11be5c051d85f | ||
8 | Author: Gwenole Beauchesne <gbeauchesne@splitted-desktop.com> | ||
9 | Date: Wed Jun 24 11:40:56 2009 +0000 | ||
10 | |||
11 | Add compatibility layer with original libva 0.29. | ||
12 | |||
13 | --- a/src/Makefile.am | ||
14 | +++ b/src/Makefile.am | ||
15 | @@ -44,7 +44,7 @@ libva_x11_la_DEPENDENCIES = $(libvacorelib) | ||
16 | libva_x11_la_DEPENDENCIES = $(libvacorelib) | ||
17 | |||
18 | |||
19 | -libva_la_SOURCES = va.c | ||
20 | +libva_la_SOURCES = va.c va_compat.c | ||
21 | |||
22 | libvaincludedir = ${includedir}/va | ||
23 | libvainclude_HEADERS = va.h va_backend.h va_version.h | ||
24 | @@ -53,4 +53,8 @@ DISTCLEANFILES = \ | ||
25 | va_version.h | ||
26 | |||
27 | EXTRA_DIST = \ | ||
28 | - va_version.h.in | ||
29 | + va_version.h.in \ | ||
30 | + va_compat.h \ | ||
31 | + va_compat_template.h | ||
32 | + | ||
33 | +va_compat.c: va_compat_template.h | ||
34 | --- a/src/va.c | ||
35 | +++ b/src/va.c | ||
36 | @@ -25,6 +25,7 @@ | ||
37 | #define _GNU_SOURCE 1 | ||
38 | #include "va.h" | ||
39 | #include "va_backend.h" | ||
40 | +#include "va_compat.h" | ||
41 | |||
42 | #include <assert.h> | ||
43 | #include <stdarg.h> | ||
44 | @@ -41,6 +42,8 @@ | ||
45 | |||
46 | #define DRIVER_INIT_FUNC "__vaDriverInit_0_31" | ||
47 | #define DRIVER_INIT_FUNC_SDS "__vaDriverInit_0_31_sds" | ||
48 | +#define DRIVER_INIT_FUNC_0_29 "__vaDriverInit_0_29" | ||
49 | +#define DRIVER_INIT_FUNC_0_30 "__vaDriverInit_0_30" | ||
50 | |||
51 | #define DRIVER_EXTENSION "_drv_video.so" | ||
52 | |||
53 | @@ -168,11 +171,22 @@ static VAStatus va_openDriver(VADisplay dpy, char *driver_name) | ||
54 | else | ||
55 | { | ||
56 | VADriverInit init_func; | ||
57 | - init_func = (VADriverInit) dlsym(handle, DRIVER_INIT_FUNC); | ||
58 | + int compat_version = 0; | ||
59 | + /* First, try SDS extensions (VDPAU and XvBA backends) */ | ||
60 | + init_func = (VADriverInit) dlsym(handle, DRIVER_INIT_FUNC_SDS); | ||
61 | if (!init_func) | ||
62 | { | ||
63 | - /* Then try SDS extensions (VDPAU and XvBA backends) */ | ||
64 | - init_func = (VADriverInit) dlsym(handle, DRIVER_INIT_FUNC_SDS); | ||
65 | + /* Otherwise, we need the compatibility layer for some buffers */ | ||
66 | + init_func = (VADriverInit) dlsym(handle, DRIVER_INIT_FUNC); | ||
67 | + compat_version = VA_MINOR_VERSION; | ||
68 | + if (!init_func) { | ||
69 | + init_func = (VADriverInit) dlsym(handle, DRIVER_INIT_FUNC_0_29); | ||
70 | + compat_version = 29; | ||
71 | + } | ||
72 | + if (!init_func) { | ||
73 | + init_func = (VADriverInit) dlsym(handle, DRIVER_INIT_FUNC_0_30); | ||
74 | + compat_version = 30; | ||
75 | + } | ||
76 | } | ||
77 | if (!init_func) | ||
78 | { | ||
79 | @@ -181,7 +195,36 @@ static VAStatus va_openDriver(VADisplay dpy, char *driver_name) | ||
80 | } | ||
81 | else | ||
82 | { | ||
83 | - vaStatus = (*init_func)(ctx); | ||
84 | + struct VADriverContext_0_29 ctx_0_29; | ||
85 | + struct VADriverContext_0_30 ctx_0_30; | ||
86 | + void *compat_ctx = NULL; | ||
87 | + | ||
88 | + switch (compat_version) { | ||
89 | + case 29: | ||
90 | + compat_ctx = &ctx_0_29; | ||
91 | + ctx_0_29.pDriverData = NULL; | ||
92 | + ctx_0_29.x11_dpy = ctx->x11_dpy; | ||
93 | + ctx_0_29.x11_screen = ctx->x11_screen; | ||
94 | + break; | ||
95 | + case 30: | ||
96 | + compat_ctx = &ctx_0_30; | ||
97 | + ctx_0_30.pDriverData = NULL; | ||
98 | + ctx_0_30.x11_dpy = ctx->x11_dpy; | ||
99 | + ctx_0_30.x11_screen = ctx->x11_screen; | ||
100 | + break; | ||
101 | + case VA_MINOR_VERSION: | ||
102 | + compat_ctx = ctx; | ||
103 | + break; | ||
104 | + default: | ||
105 | + ASSERT(compat_version == 0); | ||
106 | + vaStatus = VA_STATUS_ERROR_UNKNOWN; | ||
107 | + break; | ||
108 | + } | ||
109 | + | ||
110 | + vaStatus = (*init_func)(compat_ctx ? compat_ctx : ctx); | ||
111 | + | ||
112 | + if (VA_STATUS_SUCCESS == vaStatus) | ||
113 | + vaStatus = va_compat_init(dpy, compat_version, compat_ctx); | ||
114 | |||
115 | if (VA_STATUS_SUCCESS == vaStatus) | ||
116 | { | ||
117 | @@ -377,6 +422,8 @@ VAStatus vaTerminate ( | ||
118 | old_ctx->handle = NULL; | ||
119 | } | ||
120 | |||
121 | + va_compat_fini(dpy); | ||
122 | + | ||
123 | if (VA_STATUS_SUCCESS == vaStatus) | ||
124 | pDisplayContext->vaDestroy(pDisplayContext); | ||
125 | return vaStatus; | ||
126 | --- a/src/va_backend.h | ||
127 | +++ b/src/va_backend.h | ||
128 | @@ -426,6 +426,7 @@ struct VADriverContext | ||
129 | |||
130 | void *dri_state; | ||
131 | void *glx; /* opaque for GLX code */ | ||
132 | + void *compat; /* opaque for compat code */ | ||
133 | }; | ||
134 | |||
135 | struct VADisplayContext | ||