diff options
author | Prarit Bhargava <prarit@redhat.com> | 2010-05-23 20:24:07 -0400 |
---|---|---|
committer | Dave Airlie <airlied@redhat.com> | 2010-05-23 20:24:07 -0400 |
commit | f49d273df9087d92e20c485fe9f8355d4f55b933 (patch) | |
tree | e99874b3b7bed5cea1d8a9d0fa901ebc5153c859 /drivers/gpu/drm/nouveau/nv40_graph.c | |
parent | 579766020d2eee2f1c51af1641ef9a7dbc6a5798 (diff) |
drm: Fixes linux-next & linux-2.6 checkstack warnings:
drivers/gpu/drm/nouveau/nv40_graph.c: In function `nv40_graph_init':
drivers/gpu/drm/nouveau/nv40_graph.c:400: warning: the frame size of 1184 bytes is larger than 1024 bytes
drivers/gpu/drm/radeon/radeon_atombios.c: In function `radeon_get_atom_connector_info_from_supported_devices_table':
drivers/gpu/drm/radeon/radeon_atombios.c:857: warning: the frame size of 1872 bytes is larger than 1024 bytes
Signed-off-by: Prarit Bhargava <prarit@redhat.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
Diffstat (limited to 'drivers/gpu/drm/nouveau/nv40_graph.c')
-rw-r--r-- | drivers/gpu/drm/nouveau/nv40_graph.c | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/drivers/gpu/drm/nouveau/nv40_graph.c b/drivers/gpu/drm/nouveau/nv40_graph.c index 0616c96e4b6..704a25d04ac 100644 --- a/drivers/gpu/drm/nouveau/nv40_graph.c +++ b/drivers/gpu/drm/nouveau/nv40_graph.c | |||
@@ -253,7 +253,11 @@ nv40_graph_init(struct drm_device *dev) | |||
253 | 253 | ||
254 | if (!dev_priv->engine.graph.ctxprog) { | 254 | if (!dev_priv->engine.graph.ctxprog) { |
255 | struct nouveau_grctx ctx = {}; | 255 | struct nouveau_grctx ctx = {}; |
256 | uint32_t cp[256]; | 256 | uint32_t *cp; |
257 | |||
258 | cp = kmalloc(sizeof(*cp) * 256, GFP_KERNEL); | ||
259 | if (!cp) | ||
260 | return -ENOMEM; | ||
257 | 261 | ||
258 | ctx.dev = dev; | 262 | ctx.dev = dev; |
259 | ctx.mode = NOUVEAU_GRCTX_PROG; | 263 | ctx.mode = NOUVEAU_GRCTX_PROG; |
@@ -265,6 +269,8 @@ nv40_graph_init(struct drm_device *dev) | |||
265 | nv_wr32(dev, NV40_PGRAPH_CTXCTL_UCODE_INDEX, 0); | 269 | nv_wr32(dev, NV40_PGRAPH_CTXCTL_UCODE_INDEX, 0); |
266 | for (i = 0; i < ctx.ctxprog_len; i++) | 270 | for (i = 0; i < ctx.ctxprog_len; i++) |
267 | nv_wr32(dev, NV40_PGRAPH_CTXCTL_UCODE_DATA, cp[i]); | 271 | nv_wr32(dev, NV40_PGRAPH_CTXCTL_UCODE_DATA, cp[i]); |
272 | |||
273 | kfree(cp); | ||
268 | } | 274 | } |
269 | 275 | ||
270 | /* No context present currently */ | 276 | /* No context present currently */ |