<feed xmlns='http://www.w3.org/2005/Atom'>
<title>kernel.git/drivers/gpu/drm/i915/intel_ringbuffer.c, branch linux-2.6.38.y</title>
<subtitle>Hosts the 0x221E linux distro kernel.
</subtitle>
<id>https://git.0xinfinity.dev/distro/kernel.git/atom?h=linux-2.6.38.y</id>
<link rel='self' href='https://git.0xinfinity.dev/distro/kernel.git/atom?h=linux-2.6.38.y'/>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/'/>
<updated>2011-06-03T01:34:45Z</updated>
<entry>
<title>drm/i915: fix user irq miss in BSD ring on g4x</title>
<updated>2011-06-03T01:34:45Z</updated>
<author>
<name>Boqun Feng</name>
</author>
<published>2011-05-16T08:02:39Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=cd9c43f0be334f028e2c8e969e6bd90b51fcdebb'/>
<id>urn:sha1:cd9c43f0be334f028e2c8e969e6bd90b51fcdebb</id>
<content type='text'>
commit 5bfa1063a775836a84f97e4df863fc36e1f856ad upstream.

On g4x, user interrupt in BSD ring is missed.
This is because though g4x and ironlake share the same bsd_ring,
their interrupt control interfaces have _two_ differences.

1.different irq enable/disable functions:
On g4x are i915_enable_irq and i915_disable_irq.
On ironlake are ironlake_enable_irq and ironlake_disable_irq.
2.different irq flag:
On g4x user interrupt flag in BSD ring on is I915_BSD_USER_INTERRUPT.
On ironlake is GT_BSD_USER_INTERRUPT

Old bsd_ring_get/put_irq call ring_get_irq and ring_get_irq.
ring_get_irq and ring_put_irq only call ironlake_enable/disable_irq.
So comes the irq miss on g4x.

To fix this, as other rings' code do, conditionally call different
functions(i915_enable/disable_irq and ironlake_enable/disable_irq)
and use different interrupt flags in bsd_ring_get/put_irq.

Signed-off-by: Boqun Feng &lt;boqun.feng@intel.com&gt;
Reviewed-by: Xiang, Haihao &lt;haihao.xiang@intel.com&gt;
Signed-off-by: Keith Packard &lt;keithp@keithp.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@suse.de&gt;

</content>
</entry>
<entry>
<title>drm/i915: Invalidate TLB caches on SNB BLT/BSD rings</title>
<updated>2011-02-02T15:52:38Z</updated>
<author>
<name>Chris Wilson</name>
</author>
<published>2011-02-02T12:13:49Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=71a77e07d0e33b57d4a50c173e5ce4fabceddbec'/>
<id>urn:sha1:71a77e07d0e33b57d4a50c173e5ce4fabceddbec</id>
<content type='text'>
Signed-off-by: Chris Wilson &lt;chris@chris-wilson.co.uk&gt;
Cc: stable@kernel.org
</content>
</entry>
<entry>
<title>drm/i915/ringbuffer: Fix use of stale HEAD position whilst polling for space</title>
<updated>2011-01-20T17:26:57Z</updated>
<author>
<name>Chris Wilson</name>
</author>
<published>2011-01-20T17:00:10Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=c7dca47bd6fbb7c215cb1ce6bc40398b4b017752'/>
<id>urn:sha1:c7dca47bd6fbb7c215cb1ce6bc40398b4b017752</id>
<content type='text'>
During suspend, Linus found that his machine would hang for 3 seconds,
and identified that intel_ring_buffer_wait() was the culprit:

"Because from looking at the code, I get the notion that
"intel_read_status_page()" may not be exact. But what happens if that
inexact value matches our cached ring-&gt;actual_head, so we never even
try to read the exact case? Does it _stay_ inexact for arbitrarily
long times? If so, we might wait for the ring to empty forever (well,
until the timeout - the behavior I see), even though the ring really
_is_ empty."

As the reported HEAD position is only updated every time it crosses a
64k boundary, whilst draining the ring it is indeed likely to remain one
value. If that value matches the last known HEAD position, we never read
the true value from the register and so trigger a timeout.

Reported-by: Linus Torvalds &lt;torvalds@linux-foundation.org&gt;
Signed-off-by: Chris Wilson &lt;chris@chris-wilson.co.uk&gt;
</content>
</entry>
<entry>
<title>drm/i915: Initialise ring vfuncs for old DRI paths</title>
<updated>2011-01-20T11:20:53Z</updated>
<author>
<name>Chris Wilson</name>
</author>
<published>2011-01-20T09:57:11Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=e8616b6ced6137085e6657cc63bc2fe3900b8616'/>
<id>urn:sha1:e8616b6ced6137085e6657cc63bc2fe3900b8616</id>
<content type='text'>
We weren't setting up the vfunc table when initialising the old DRI
ringbuffer, leading to such OOPSes as:

BUG: unable to handle kernel NULL pointer dereference at (null)
IP: [&lt;(null)&gt;] (null)
PGD 10c441067 PUD 1185e5067 PMD 0
Oops: 0010 [#1] PREEMPT SMP
last sysfs file: /sys/class/dmi/id/chassis_asset_tag
CPU 3
Modules linked in: i915 drm_kms_helper drm fb fbdev i2c_algo_bit
cfbcopyarea video backlight output cfbimgblt cfbfillrect autofs4 ipv6
nfs lockd fscache nfs_acl auth_rpcgss sunrpc coretemp hwmon_vid mousedev
usbhid hid option usb_wwan snd_hda_codec_via asus_atk0110 atl1e
usbserial snd_hda_intel snd_hda_codec firmware_class snd_hwdep snd_pcm
snd_seq snd_timer snd_seq_device processor parport_pc thermal snd
thermal_sys parport 8250_pnp button rng_core rtc_cmos shpchp hwmon
rtc_core ehci_hcd pci_hotplug uhci_hcd soundcore tpm_tis i2c_i801
rtc_lib tpm serio_raw snd_page_alloc tpm_bios i2c_core usbcore psmouse
intel_agp sg pcspkr sr_mod evdev cdrom ext3 jbd mbcache dm_mod sd_mod
ata_piix libata scsi_mod unix
Jan 18 15:49:29 lithui kernel:
Pid: 3605, comm: Xorg Not tainted 2.6.36.2 #5 P5KPL-CM/System Product
Name
RIP: 0010:[&lt;0000000000000000&gt;]  [&lt;(null)&gt;] (null)
RSP: 0018:ffff8801150d1d40  EFLAGS: 00010202
RAX: 000000000001ffff RBX: ffff88011a011b00 RCX: 000000000001a704
RDX: ffff880118566028 RSI: ffff880118566028 RDI: ffff880117876800
RBP: ffff8801150d1d48 R08: ffff8801195fe300 R09: 00000000c0086444
R10: 0000000000000001 R11: 0000000000003206 R12: ffff880117876800
R13: ffff880118566000 R14: ffff880117876820 R15: ffff8801150d1df8
FS:  00007f1038d456e0(0000) GS:ffff880001780000(0000)
knlGS:0000000000000000
CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 0000000000000000 CR3: 00000001187e7000 CR4: 00000000000006e0
DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
DR3: 0000000000000000 DR6: 00000000ffff0ff0 DR7: 0000000000000400
Process Xorg (pid: 3605, threadinfo ffff8801150d0000, task
ffff88011b016e40)
Stack:
ffffffffa043b8e6 ffff8801150d1d98 ffffffffa041768b dead000000000000
&lt;0&gt; 0000000000000048 00007f1023f2a000 0000000000000044 0000000000000008
&lt;0&gt; ffff88010d26bd80 ffff880117876800 ffff8801150d1df8 ffff8801150d1ea8
Call Trace:
[&lt;ffffffffa043b8e6&gt;] ? intel_ring_advance+0x16/0x20 [i915]
[&lt;ffffffffa041768b&gt;] i915_irq_emit+0x15b/0x240 [i915]
[&lt;ffffffffa03ea7b1&gt;] drm_ioctl+0x1f1/0x460 [drm]
[&lt;ffffffffa0417530&gt;] ? i915_irq_emit+0x0/0x240 [i915]
[&lt;ffffffff810dd8f1&gt;] ? do_sync_read+0xd1/0x120
[&lt;ffffffff81025b1f&gt;] ? do_page_fault+0x1df/0x3d0
[&lt;ffffffff810ed5c7&gt;] do_vfs_ioctl+0x97/0x550
[&lt;ffffffff8115c2ea&gt;] ? security_file_permission+0x7a/0x90
[&lt;ffffffff810edb19&gt;] sys_ioctl+0x99/0xa0
[&lt;ffffffff810024ab&gt;] system_call_fastpath+0x16/0x1b
Code:  Bad RIP value.
RIP  [&lt;(null)&gt;] (null)
RSP &lt;ffff8801150d1d40&gt;
CR2: 0000000000000000

Reported-by: Herbert Xu &lt;herbert@gondor.apana.org.au&gt;
Tested-by: Herbert Xu &lt;herbert@gondor.apana.org.au&gt;
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=29153
Bugzilla: https://bugzilla.kernel.org/show_bug.cgi?id=23172
Signed-off-by: Chris Wilson &lt;chris@chris-wilson.co.uk&gt;
Cc: stable@kernel.org
</content>
</entry>
<entry>
<title>drm/i915: Make the ring IMR handling private</title>
<updated>2011-01-11T20:43:58Z</updated>
<author>
<name>Chris Wilson</name>
</author>
<published>2011-01-05T10:32:24Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=0dc79fb2a36efcadbb39bd8b28933d8aa40408b1'/>
<id>urn:sha1:0dc79fb2a36efcadbb39bd8b28933d8aa40408b1</id>
<content type='text'>
As the IMR for the USER interrupts are not modified elsewhere, we can
separate the spinlock used for these from that of hpd and pipestats.
Those two IMR are manipulated under an IRQ and so need heavier locking.

Reported-and-tested-by: Alexey Fisher &lt;bug-track@fisher-privat.net&gt;
Signed-off-by: Chris Wilson &lt;chris@chris-wilson.co.uk&gt;
</content>
</entry>
<entry>
<title>drm/i915/ringbuffer: Simplify the ring irq refcounting</title>
<updated>2011-01-11T20:43:57Z</updated>
<author>
<name>Chris Wilson</name>
</author>
<published>2011-01-04T22:22:56Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=01a03331e5fe91861937f8b8e72c259f5e9eae67'/>
<id>urn:sha1:01a03331e5fe91861937f8b8e72c259f5e9eae67</id>
<content type='text'>
... and move it under the spinlock to gain the appropriate memory
barriers.

Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=32752
Signed-off-by: Chris Wilson &lt;chris@chris-wilson.co.uk&gt;
</content>
</entry>
<entry>
<title>drm/i915: Mask USER interrupts on gen6 (until required)</title>
<updated>2011-01-11T20:43:56Z</updated>
<author>
<name>Chris Wilson</name>
</author>
<published>2011-01-04T17:35:21Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=0f46832fab779a9a3314ce5e833155fe4cf18f6c'/>
<id>urn:sha1:0f46832fab779a9a3314ce5e833155fe4cf18f6c</id>
<content type='text'>
Otherwise we may consume 20% of the CPU just handling IRQs whilst
rendering. Ouch.

Signed-off-by: Chris Wilson &lt;chris@chris-wilson.co.uk&gt;
</content>
</entry>
<entry>
<title>drm/i915: Handle ringbuffer stalls when flushing</title>
<updated>2011-01-11T20:43:55Z</updated>
<author>
<name>Chris Wilson</name>
</author>
<published>2011-01-04T17:34:02Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=b72f3acb71646de073abdc070fe1108866c96634'/>
<id>urn:sha1:b72f3acb71646de073abdc070fe1108866c96634</id>
<content type='text'>
Signed-off-by: Chris Wilson &lt;chris@chris-wilson.co.uk&gt;
</content>
</entry>
<entry>
<title>drm/i915: Workaround erratum on i830 for TAIL pointer within last 2 cachelines</title>
<updated>2011-01-11T20:35:41Z</updated>
<author>
<name>Chris Wilson</name>
</author>
<published>2010-12-22T14:04:47Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=55249baaa5cd188ebd9acdb047eeaed8092e4a93'/>
<id>urn:sha1:55249baaa5cd188ebd9acdb047eeaed8092e4a93</id>
<content type='text'>
On i830 if the tail pointer is set to within 2 cachelines of the end of
the buffer, the chip may hang. So instead if the tail were to land in
that location, we pad the end of the buffer with NOPs, and start again
at the beginning.

Signed-off-by: Chris Wilson &lt;chris@chris-wilson.co.uk&gt;
</content>
</entry>
<entry>
<title>Revert "drm/i915: Avoid using PIPE_CONTROL on Ironlake"</title>
<updated>2010-12-15T10:15:25Z</updated>
<author>
<name>Chris Wilson</name>
</author>
<published>2010-12-15T09:56:50Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=c6df541c00e53a4fdff7a130d4365f848075adcc'/>
<id>urn:sha1:c6df541c00e53a4fdff7a130d4365f848075adcc</id>
<content type='text'>
Restore PIPE_CONTROL once again just for Ironlake, as it appears that
MI_USER_INTERRUPT does not have the same coherency guarantees, that is
on Ironlake the interrupt following a GPU write is not guaranteed to
arrive after the write is coherent from the CPU, as it does on the
other generations.

Reported-by: Zhenyu Wang &lt;zhenyuw@linux.intel.com&gt;
Reported-by: Shuang He &lt;shuang.he@intel.com&gt;
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=32402
Signed-off-by: Chris Wilson &lt;chris@chris-wilson.co.uk&gt;
</content>
</entry>
</feed>
