linux/drivers/gpu/drm/via
Márton Németh ce020ea532 drm via: initialize object_idr
The field obejct_idr of struct drm_via_private was introduced with the
commit http://git.kernel.org/?p=linux/kernel/git/torvalds/linux.git;a=commitdiff;h=77ee8f3825054f23b17e9c8f728f061defd86cdc .
In that patch idr_init(&dev->object_name_idr) was called instead of
idr_init(&dev_priv->object_idr) by mistake, leaving the dev_priv->object_idr
uninitialized. To be more exact, the object_idr buffer is filled with zeros
because of kzalloc(), but the dev_priv->object_idr.lock spinlock can cause
system freeze at lib/idr.c:move_to_free_list() when spin_lock_irqsave()
is called on this spinlock.

The patch was tested on Clevo D4J, model D410J laptop, on the following
hardware, without AGP kernel module loaded:

  # lspci -s 01:00.0 -n
  01:00.0 0300: 1106:3108 (rev 01)
  # lspci -s 01:00.0 -v
  01:00.0 VGA compatible controller: VIA Technologies, Inc. K8M800/K8N800/K8N800A [S3 UniChrome Pro] (rev 01) (prog-if 00 [VGA controller])
          Subsystem: CLEVO/KAPOK Computer Device 4702
          Flags: bus master, 66MHz, medium devsel, latency 64, IRQ 16
          Memory at f0000000 (32-bit, prefetchable) [size=64M]
          Memory at d1000000 (32-bit, non-prefetchable) [size=16M]
          Expansion ROM at <unassigned> [disabled]
          Capabilities: [60] Power Management version 2
          Capabilities: [70] AGP version 3.0

Signed-off-by: Márton Németh <nm127@freemail.hu>
Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Cc: stable@vger.kernel.org
Signed-off-by: Dave Airlie <airlied@redhat.com>
2012-06-16 11:18:38 +01:00
..
Makefile
via_3d_reg.h
via_dma.c drm: block userspace under allocating buffer and having drivers overwrite it (v2) 2010-08-17 14:52:25 +10:00
via_dmablit.c drivers/gpu: Use vzalloc 2010-11-09 13:41:35 +10:00
via_dmablit.h drm/via: fixed coding style issues, simplified return 2010-08-02 10:17:23 +10:00
via_drv.c drm/via: track obj->drm_fd relations in the driver 2011-12-22 00:33:19 +01:00
via_drv.h drm/via: use drm_mm instead of drm_sman 2011-12-22 00:33:22 +01:00
via_irq.c drm/via: fixed coding style issues, simplified return 2010-08-02 10:17:23 +10:00
via_map.c drm via: initialize object_idr 2012-06-16 11:18:38 +01:00
via_mm.c drm/sis|via: don't return stack garbage from free_mem ioctl 2012-01-09 12:11:39 +00:00
via_verifier.c drm/via: fixed coding style issues, simplified return 2010-08-02 10:17:23 +10:00
via_verifier.h drm/via: fixed coding style issues, simplified return 2010-08-02 10:17:23 +10:00
via_video.c drm/via: fixed coding style issues, simplified return 2010-08-02 10:17:23 +10:00