diff options
author | Ben Skeggs <bskeggs@redhat.com> | 2015-01-14 00:32:28 -0500 |
---|---|---|
committer | Ben Skeggs <bskeggs@redhat.com> | 2015-01-21 21:18:06 -0500 |
commit | a56866a9809d276e3bf9aee27466cee385d2b5e6 (patch) | |
tree | 16b505f835d4843297b8eafb99ae982dd4e7cab1 | |
parent | f84aff4ed4942add5c3bafd8464746209bc1f51c (diff) |
drm/nouveau/vp: namespace + nvidia gpu names (no binary change)
The namespace of NVKM is being changed to nvkm_ instead of nouveau_,
which will be used for the DRM part of the driver. This is being
done in order to make it very clear as to what part of the driver a
given symbol belongs to, and as a minor step towards splitting the
DRM driver out to be able to stand on its own (for virt).
Because there's already a large amount of churn here anyway, this is
as good a time as any to also switch to NVIDIA's device and chipset
naming to ease collaboration with them.
A comparison of objdump disassemblies proves no code changes.
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
-rw-r--r-- | drivers/gpu/drm/nouveau/include/nvkm/engine/vp.h | 7 | ||||
-rw-r--r-- | drivers/gpu/drm/nouveau/nvkm/engine/device/nv50.c | 12 | ||||
-rw-r--r-- | drivers/gpu/drm/nouveau/nvkm/engine/vp/Kbuild | 2 | ||||
-rw-r--r-- | drivers/gpu/drm/nouveau/nvkm/engine/vp/g84.c (renamed from drivers/gpu/drm/nouveau/nvkm/engine/vp/nv84.c) | 61 |
4 files changed, 41 insertions, 41 deletions
diff --git a/drivers/gpu/drm/nouveau/include/nvkm/engine/vp.h b/drivers/gpu/drm/nouveau/include/nvkm/engine/vp.h index 7175e6e032cc..7851f18c5add 100644 --- a/drivers/gpu/drm/nouveau/include/nvkm/engine/vp.h +++ b/drivers/gpu/drm/nouveau/include/nvkm/engine/vp.h | |||
@@ -1,4 +1,5 @@ | |||
1 | #ifndef __NOUVEAU_VP_H__ | 1 | #ifndef __NVKM_VP_H__ |
2 | #define __NOUVEAU_VP_H__ | 2 | #define __NVKM_VP_H__ |
3 | extern struct nouveau_oclass nv84_vp_oclass; | 3 | #include <core/engine.h> |
4 | extern struct nvkm_oclass g84_vp_oclass; | ||
4 | #endif | 5 | #endif |
diff --git a/drivers/gpu/drm/nouveau/nvkm/engine/device/nv50.c b/drivers/gpu/drm/nouveau/nvkm/engine/device/nv50.c index bf3998b96bc4..36944babbb53 100644 --- a/drivers/gpu/drm/nouveau/nvkm/engine/device/nv50.c +++ b/drivers/gpu/drm/nouveau/nvkm/engine/device/nv50.c | |||
@@ -110,7 +110,7 @@ nv50_identify(struct nouveau_device *device) | |||
110 | device->oclass[NVDEV_ENGINE_SW ] = nv50_sw_oclass; | 110 | device->oclass[NVDEV_ENGINE_SW ] = nv50_sw_oclass; |
111 | device->oclass[NVDEV_ENGINE_GR ] = &nv50_gr_oclass; | 111 | device->oclass[NVDEV_ENGINE_GR ] = &nv50_gr_oclass; |
112 | device->oclass[NVDEV_ENGINE_MPEG ] = &g84_mpeg_oclass; | 112 | device->oclass[NVDEV_ENGINE_MPEG ] = &g84_mpeg_oclass; |
113 | device->oclass[NVDEV_ENGINE_VP ] = &nv84_vp_oclass; | 113 | device->oclass[NVDEV_ENGINE_VP ] = &g84_vp_oclass; |
114 | device->oclass[NVDEV_ENGINE_CIPHER ] = &g84_cipher_oclass; | 114 | device->oclass[NVDEV_ENGINE_CIPHER ] = &g84_cipher_oclass; |
115 | device->oclass[NVDEV_ENGINE_BSP ] = &g84_bsp_oclass; | 115 | device->oclass[NVDEV_ENGINE_BSP ] = &g84_bsp_oclass; |
116 | device->oclass[NVDEV_ENGINE_DISP ] = g84_disp_oclass; | 116 | device->oclass[NVDEV_ENGINE_DISP ] = g84_disp_oclass; |
@@ -139,7 +139,7 @@ nv50_identify(struct nouveau_device *device) | |||
139 | device->oclass[NVDEV_ENGINE_SW ] = nv50_sw_oclass; | 139 | device->oclass[NVDEV_ENGINE_SW ] = nv50_sw_oclass; |
140 | device->oclass[NVDEV_ENGINE_GR ] = &nv50_gr_oclass; | 140 | device->oclass[NVDEV_ENGINE_GR ] = &nv50_gr_oclass; |
141 | device->oclass[NVDEV_ENGINE_MPEG ] = &g84_mpeg_oclass; | 141 | device->oclass[NVDEV_ENGINE_MPEG ] = &g84_mpeg_oclass; |
142 | device->oclass[NVDEV_ENGINE_VP ] = &nv84_vp_oclass; | 142 | device->oclass[NVDEV_ENGINE_VP ] = &g84_vp_oclass; |
143 | device->oclass[NVDEV_ENGINE_CIPHER ] = &g84_cipher_oclass; | 143 | device->oclass[NVDEV_ENGINE_CIPHER ] = &g84_cipher_oclass; |
144 | device->oclass[NVDEV_ENGINE_BSP ] = &g84_bsp_oclass; | 144 | device->oclass[NVDEV_ENGINE_BSP ] = &g84_bsp_oclass; |
145 | device->oclass[NVDEV_ENGINE_DISP ] = g84_disp_oclass; | 145 | device->oclass[NVDEV_ENGINE_DISP ] = g84_disp_oclass; |
@@ -168,7 +168,7 @@ nv50_identify(struct nouveau_device *device) | |||
168 | device->oclass[NVDEV_ENGINE_SW ] = nv50_sw_oclass; | 168 | device->oclass[NVDEV_ENGINE_SW ] = nv50_sw_oclass; |
169 | device->oclass[NVDEV_ENGINE_GR ] = &nv50_gr_oclass; | 169 | device->oclass[NVDEV_ENGINE_GR ] = &nv50_gr_oclass; |
170 | device->oclass[NVDEV_ENGINE_MPEG ] = &g84_mpeg_oclass; | 170 | device->oclass[NVDEV_ENGINE_MPEG ] = &g84_mpeg_oclass; |
171 | device->oclass[NVDEV_ENGINE_VP ] = &nv84_vp_oclass; | 171 | device->oclass[NVDEV_ENGINE_VP ] = &g84_vp_oclass; |
172 | device->oclass[NVDEV_ENGINE_CIPHER ] = &g84_cipher_oclass; | 172 | device->oclass[NVDEV_ENGINE_CIPHER ] = &g84_cipher_oclass; |
173 | device->oclass[NVDEV_ENGINE_BSP ] = &g84_bsp_oclass; | 173 | device->oclass[NVDEV_ENGINE_BSP ] = &g84_bsp_oclass; |
174 | device->oclass[NVDEV_ENGINE_DISP ] = g84_disp_oclass; | 174 | device->oclass[NVDEV_ENGINE_DISP ] = g84_disp_oclass; |
@@ -197,7 +197,7 @@ nv50_identify(struct nouveau_device *device) | |||
197 | device->oclass[NVDEV_ENGINE_SW ] = nv50_sw_oclass; | 197 | device->oclass[NVDEV_ENGINE_SW ] = nv50_sw_oclass; |
198 | device->oclass[NVDEV_ENGINE_GR ] = &nv50_gr_oclass; | 198 | device->oclass[NVDEV_ENGINE_GR ] = &nv50_gr_oclass; |
199 | device->oclass[NVDEV_ENGINE_MPEG ] = &g84_mpeg_oclass; | 199 | device->oclass[NVDEV_ENGINE_MPEG ] = &g84_mpeg_oclass; |
200 | device->oclass[NVDEV_ENGINE_VP ] = &nv84_vp_oclass; | 200 | device->oclass[NVDEV_ENGINE_VP ] = &g84_vp_oclass; |
201 | device->oclass[NVDEV_ENGINE_CIPHER ] = &g84_cipher_oclass; | 201 | device->oclass[NVDEV_ENGINE_CIPHER ] = &g84_cipher_oclass; |
202 | device->oclass[NVDEV_ENGINE_BSP ] = &g84_bsp_oclass; | 202 | device->oclass[NVDEV_ENGINE_BSP ] = &g84_bsp_oclass; |
203 | device->oclass[NVDEV_ENGINE_DISP ] = g94_disp_oclass; | 203 | device->oclass[NVDEV_ENGINE_DISP ] = g94_disp_oclass; |
@@ -226,7 +226,7 @@ nv50_identify(struct nouveau_device *device) | |||
226 | device->oclass[NVDEV_ENGINE_SW ] = nv50_sw_oclass; | 226 | device->oclass[NVDEV_ENGINE_SW ] = nv50_sw_oclass; |
227 | device->oclass[NVDEV_ENGINE_GR ] = &nv50_gr_oclass; | 227 | device->oclass[NVDEV_ENGINE_GR ] = &nv50_gr_oclass; |
228 | device->oclass[NVDEV_ENGINE_MPEG ] = &g84_mpeg_oclass; | 228 | device->oclass[NVDEV_ENGINE_MPEG ] = &g84_mpeg_oclass; |
229 | device->oclass[NVDEV_ENGINE_VP ] = &nv84_vp_oclass; | 229 | device->oclass[NVDEV_ENGINE_VP ] = &g84_vp_oclass; |
230 | device->oclass[NVDEV_ENGINE_CIPHER ] = &g84_cipher_oclass; | 230 | device->oclass[NVDEV_ENGINE_CIPHER ] = &g84_cipher_oclass; |
231 | device->oclass[NVDEV_ENGINE_BSP ] = &g84_bsp_oclass; | 231 | device->oclass[NVDEV_ENGINE_BSP ] = &g84_bsp_oclass; |
232 | device->oclass[NVDEV_ENGINE_DISP ] = g94_disp_oclass; | 232 | device->oclass[NVDEV_ENGINE_DISP ] = g94_disp_oclass; |
@@ -284,7 +284,7 @@ nv50_identify(struct nouveau_device *device) | |||
284 | device->oclass[NVDEV_ENGINE_SW ] = nv50_sw_oclass; | 284 | device->oclass[NVDEV_ENGINE_SW ] = nv50_sw_oclass; |
285 | device->oclass[NVDEV_ENGINE_GR ] = &nv50_gr_oclass; | 285 | device->oclass[NVDEV_ENGINE_GR ] = &nv50_gr_oclass; |
286 | device->oclass[NVDEV_ENGINE_MPEG ] = &g84_mpeg_oclass; | 286 | device->oclass[NVDEV_ENGINE_MPEG ] = &g84_mpeg_oclass; |
287 | device->oclass[NVDEV_ENGINE_VP ] = &nv84_vp_oclass; | 287 | device->oclass[NVDEV_ENGINE_VP ] = &g84_vp_oclass; |
288 | device->oclass[NVDEV_ENGINE_CIPHER ] = &g84_cipher_oclass; | 288 | device->oclass[NVDEV_ENGINE_CIPHER ] = &g84_cipher_oclass; |
289 | device->oclass[NVDEV_ENGINE_BSP ] = &g84_bsp_oclass; | 289 | device->oclass[NVDEV_ENGINE_BSP ] = &g84_bsp_oclass; |
290 | device->oclass[NVDEV_ENGINE_DISP ] = gt200_disp_oclass; | 290 | device->oclass[NVDEV_ENGINE_DISP ] = gt200_disp_oclass; |
diff --git a/drivers/gpu/drm/nouveau/nvkm/engine/vp/Kbuild b/drivers/gpu/drm/nouveau/nvkm/engine/vp/Kbuild index e4bfb6eb3d21..6b390eb92b0e 100644 --- a/drivers/gpu/drm/nouveau/nvkm/engine/vp/Kbuild +++ b/drivers/gpu/drm/nouveau/nvkm/engine/vp/Kbuild | |||
@@ -1 +1 @@ | |||
nvkm-y += nvkm/engine/vp/nv84.o | nvkm-y += nvkm/engine/vp/g84.o | ||
diff --git a/drivers/gpu/drm/nouveau/nvkm/engine/vp/nv84.c b/drivers/gpu/drm/nouveau/nvkm/engine/vp/g84.c index 9caa037b7a6b..45f4e186befc 100644 --- a/drivers/gpu/drm/nouveau/nvkm/engine/vp/nv84.c +++ b/drivers/gpu/drm/nouveau/nvkm/engine/vp/g84.c | |||
@@ -21,9 +21,8 @@ | |||
21 | * | 21 | * |
22 | * Authors: Ben Skeggs, Ilia Mirkin | 22 | * Authors: Ben Skeggs, Ilia Mirkin |
23 | */ | 23 | */ |
24 | |||
25 | #include <engine/xtensa.h> | ||
26 | #include <engine/vp.h> | 24 | #include <engine/vp.h> |
25 | #include <engine/xtensa.h> | ||
27 | 26 | ||
28 | #include <core/engctx.h> | 27 | #include <core/engctx.h> |
29 | 28 | ||
@@ -31,9 +30,9 @@ | |||
31 | * VP object classes | 30 | * VP object classes |
32 | ******************************************************************************/ | 31 | ******************************************************************************/ |
33 | 32 | ||
34 | static struct nouveau_oclass | 33 | static struct nvkm_oclass |
35 | nv84_vp_sclass[] = { | 34 | g84_vp_sclass[] = { |
36 | { 0x7476, &nouveau_object_ofuncs }, | 35 | { 0x7476, &nvkm_object_ofuncs }, |
37 | {}, | 36 | {}, |
38 | }; | 37 | }; |
39 | 38 | ||
@@ -41,16 +40,16 @@ nv84_vp_sclass[] = { | |||
41 | * PVP context | 40 | * PVP context |
42 | ******************************************************************************/ | 41 | ******************************************************************************/ |
43 | 42 | ||
44 | static struct nouveau_oclass | 43 | static struct nvkm_oclass |
45 | nv84_vp_cclass = { | 44 | g84_vp_cclass = { |
46 | .handle = NV_ENGCTX(VP, 0x84), | 45 | .handle = NV_ENGCTX(VP, 0x84), |
47 | .ofuncs = &(struct nouveau_ofuncs) { | 46 | .ofuncs = &(struct nvkm_ofuncs) { |
48 | .ctor = _nouveau_xtensa_engctx_ctor, | 47 | .ctor = _nvkm_xtensa_engctx_ctor, |
49 | .dtor = _nouveau_engctx_dtor, | 48 | .dtor = _nvkm_engctx_dtor, |
50 | .init = _nouveau_engctx_init, | 49 | .init = _nvkm_engctx_init, |
51 | .fini = _nouveau_engctx_fini, | 50 | .fini = _nvkm_engctx_fini, |
52 | .rd32 = _nouveau_engctx_rd32, | 51 | .rd32 = _nvkm_engctx_rd32, |
53 | .wr32 = _nouveau_engctx_wr32, | 52 | .wr32 = _nvkm_engctx_wr32, |
54 | }, | 53 | }, |
55 | }; | 54 | }; |
56 | 55 | ||
@@ -59,36 +58,36 @@ nv84_vp_cclass = { | |||
59 | ******************************************************************************/ | 58 | ******************************************************************************/ |
60 | 59 | ||
61 | static int | 60 | static int |
62 | nv84_vp_ctor(struct nouveau_object *parent, struct nouveau_object *engine, | 61 | g84_vp_ctor(struct nvkm_object *parent, struct nvkm_object *engine, |
63 | struct nouveau_oclass *oclass, void *data, u32 size, | 62 | struct nvkm_oclass *oclass, void *data, u32 size, |
64 | struct nouveau_object **pobject) | 63 | struct nvkm_object **pobject) |
65 | { | 64 | { |
66 | struct nouveau_xtensa *priv; | 65 | struct nvkm_xtensa *priv; |
67 | int ret; | 66 | int ret; |
68 | 67 | ||
69 | ret = nouveau_xtensa_create(parent, engine, oclass, 0xf000, true, | 68 | ret = nvkm_xtensa_create(parent, engine, oclass, 0xf000, true, |
70 | "PVP", "vp", &priv); | 69 | "PVP", "vp", &priv); |
71 | *pobject = nv_object(priv); | 70 | *pobject = nv_object(priv); |
72 | if (ret) | 71 | if (ret) |
73 | return ret; | 72 | return ret; |
74 | 73 | ||
75 | nv_subdev(priv)->unit = 0x01020000; | 74 | nv_subdev(priv)->unit = 0x01020000; |
76 | nv_engine(priv)->cclass = &nv84_vp_cclass; | 75 | nv_engine(priv)->cclass = &g84_vp_cclass; |
77 | nv_engine(priv)->sclass = nv84_vp_sclass; | 76 | nv_engine(priv)->sclass = g84_vp_sclass; |
78 | priv->fifo_val = 0x111; | 77 | priv->fifo_val = 0x111; |
79 | priv->unkd28 = 0x9c544; | 78 | priv->unkd28 = 0x9c544; |
80 | return 0; | 79 | return 0; |
81 | } | 80 | } |
82 | 81 | ||
83 | struct nouveau_oclass | 82 | struct nvkm_oclass |
84 | nv84_vp_oclass = { | 83 | g84_vp_oclass = { |
85 | .handle = NV_ENGINE(VP, 0x84), | 84 | .handle = NV_ENGINE(VP, 0x84), |
86 | .ofuncs = &(struct nouveau_ofuncs) { | 85 | .ofuncs = &(struct nvkm_ofuncs) { |
87 | .ctor = nv84_vp_ctor, | 86 | .ctor = g84_vp_ctor, |
88 | .dtor = _nouveau_xtensa_dtor, | 87 | .dtor = _nvkm_xtensa_dtor, |
89 | .init = _nouveau_xtensa_init, | 88 | .init = _nvkm_xtensa_init, |
90 | .fini = _nouveau_xtensa_fini, | 89 | .fini = _nvkm_xtensa_fini, |
91 | .rd32 = _nouveau_xtensa_rd32, | 90 | .rd32 = _nvkm_xtensa_rd32, |
92 | .wr32 = _nouveau_xtensa_wr32, | 91 | .wr32 = _nvkm_xtensa_wr32, |
93 | }, | 92 | }, |
94 | }; | 93 | }; |