summaryrefslogtreecommitdiffstats
path: root/drivers/char/drm/i915_irq.c
diff options
context:
space:
mode:
authorLi Zefan <lizf@cn.fujitsu.com>2007-12-17 00:47:19 +0100
committerDave Airlie <airlied@redhat.com>2008-02-07 06:09:39 +0100
commitd5b0d1b5bda979b077cf011e79fc19677663afc4 (patch)
treeaa8bd82793341bdbf18589eed8a91fbe511cddfe /drivers/char/drm/i915_irq.c
parentmga_dma: return 'err' not just zero from mga_do_cleanup_dma() (diff)
downloadlinux-d5b0d1b5bda979b077cf011e79fc19677663afc4.tar.xz
linux-d5b0d1b5bda979b077cf011e79fc19677663afc4.zip
drm: don't cast a pointer to pointer of list_head
The casting is safe only when the list_head member is the first member of the structure. Signed-off-by: Li Zefan <lizf@cn.fujitsu.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Dave Airlie <airlied@linux.ie>
Diffstat (limited to 'drivers/char/drm/i915_irq.c')
-rw-r--r--drivers/char/drm/i915_irq.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/char/drm/i915_irq.c b/drivers/char/drm/i915_irq.c
index 3f02ff593bbd..b273fe4e1345 100644
--- a/drivers/char/drm/i915_irq.c
+++ b/drivers/char/drm/i915_irq.c
@@ -555,7 +555,7 @@ int i915_vblank_swap(struct drm_device *dev, void *data,
spin_lock_irqsave(&dev_priv->swaps_lock, irqflags);
- list_add_tail((struct list_head *)vbl_swap, &dev_priv->vbl_swaps.head);
+ list_add_tail(&vbl_swap->head, &dev_priv->vbl_swaps.head);
dev_priv->swaps_pending++;
spin_unlock_irqrestore(&dev_priv->swaps_lock, irqflags);