summaryrefslogtreecommitdiffstats
path: root/drivers/char/drm/i830_dma.c
diff options
context:
space:
mode:
authorDave Airlie <airlied@linux.ie>2007-05-25 21:01:51 +0200
committerDave Airlie <airlied@linux.ie>2007-07-11 03:58:02 +0200
commitbd1b331fae2813d9f03ceee649296f02edc0b893 (patch)
tree6139f72ebae88c332c754745f3d98cbe794ae4de /drivers/char/drm/i830_dma.c
parentlots-of-architectures: enable arbitary speed tty support (diff)
downloadlinux-bd1b331fae2813d9f03ceee649296f02edc0b893.tar.xz
linux-bd1b331fae2813d9f03ceee649296f02edc0b893.zip
drm: cleanup use of Linux list handling macros
This makes the drms use of the list handling macros a lot cleaner and more along the lines of how they should be used and uses them in some more places. Signed-off-by: Dave Airlie <airlied@linux.ie>
Diffstat (limited to 'drivers/char/drm/i830_dma.c')
-rw-r--r--drivers/char/drm/i830_dma.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/drivers/char/drm/i830_dma.c b/drivers/char/drm/i830_dma.c
index 3314a9fea9e5..3103258df61e 100644
--- a/drivers/char/drm/i830_dma.c
+++ b/drivers/char/drm/i830_dma.c
@@ -334,12 +334,11 @@ static int i830_dma_initialize(drm_device_t * dev,
drm_i830_private_t * dev_priv,
drm_i830_init_t * init)
{
- struct list_head *list;
+ drm_map_list_t *r_list;
memset(dev_priv, 0, sizeof(drm_i830_private_t));
- list_for_each(list, &dev->maplist->head) {
- drm_map_list_t *r_list = list_entry(list, drm_map_list_t, head);
+ list_for_each_entry(r_list, &dev->maplist, head) {
if (r_list->map &&
r_list->map->type == _DRM_SHM &&
r_list->map->flags & _DRM_CONTAINS_LOCK) {