<feed xmlns='http://www.w3.org/2005/Atom'>
<title>linux-stable.git/drivers/gpu/drm/mgag200, branch linux-3.13.y</title>
<subtitle>Linux kernel stable tree</subtitle>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux-stable.git/'/>
<entry>
<title>drm/mgag200,ast,cirrus: fix regression with drm_can_sleep conversion</title>
<updated>2014-02-13T21:55:44+00:00</updated>
<author>
<name>Dave Airlie</name>
<email>airlied@redhat.com</email>
</author>
<published>2014-02-05T04:47:45+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux-stable.git/commit/?id=03d0de9df95813da0d42b4dd695ab2de17f3da4a'/>
<id>03d0de9df95813da0d42b4dd695ab2de17f3da4a</id>
<content type='text'>
commit 8b7ad1bb3d440da888f2a939dc870eba429b9192 upstream.

I totally sign inverted my way out of this one.

Reported-by: "Sabrina Dubroca" &lt;sd@queasysnail.net&gt;
Signed-off-by: Dave Airlie &lt;airlied@redhat.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;

</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
commit 8b7ad1bb3d440da888f2a939dc870eba429b9192 upstream.

I totally sign inverted my way out of this one.

Reported-by: "Sabrina Dubroca" &lt;sd@queasysnail.net&gt;
Signed-off-by: Dave Airlie &lt;airlied@redhat.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;

</pre>
</div>
</content>
</entry>
<entry>
<title>drm/mgag200: fix typo causing bw limits to be ignored on some chips</title>
<updated>2014-02-13T21:55:44+00:00</updated>
<author>
<name>Dave Airlie</name>
<email>airlied@redhat.com</email>
</author>
<published>2014-02-05T04:13:56+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux-stable.git/commit/?id=b6d556d94fae1657509227efe9e9c1ded8e68023'/>
<id>b6d556d94fae1657509227efe9e9c1ded8e68023</id>
<content type='text'>
commit ec22b4aa993abbd18f5bbbcb20a1c56be3b1d38b upstream.

mode-&gt;mdev otherwise the bw limits never kick in.

Reported in RHEL testing.

Signed-off-by: Dave Airlie &lt;airlied@redhat.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;

</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
commit ec22b4aa993abbd18f5bbbcb20a1c56be3b1d38b upstream.

mode-&gt;mdev otherwise the bw limits never kick in.

Reported in RHEL testing.

Signed-off-by: Dave Airlie &lt;airlied@redhat.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;

</pre>
</div>
</content>
</entry>
<entry>
<title>drm/mgag200: fix oops in cursor code.</title>
<updated>2014-02-13T21:55:43+00:00</updated>
<author>
<name>Dave Airlie</name>
<email>airlied@redhat.com</email>
</author>
<published>2014-01-16T04:28:22+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux-stable.git/commit/?id=a4457eb14534f21aa18d10bb09aad5bb3ed4960d'/>
<id>a4457eb14534f21aa18d10bb09aad5bb3ed4960d</id>
<content type='text'>
commit 53dac830537b51df555ba5e7ebb236705b7eaa7c upstream.

In some cases we enter the cursor code with file_priv = NULL causing an oops,
we also can try to unpin something that isn't pinned, and this is a good fix for it.

Signed-off-by: Dave Airlie &lt;airlied@redhat.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;

</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
commit 53dac830537b51df555ba5e7ebb236705b7eaa7c upstream.

In some cases we enter the cursor code with file_priv = NULL causing an oops,
we also can try to unpin something that isn't pinned, and this is a good fix for it.

Signed-off-by: Dave Airlie &lt;airlied@redhat.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;

</pre>
</div>
</content>
</entry>
<entry>
<title>drm: ast,cirrus,mgag200: use drm_can_sleep</title>
<updated>2014-02-13T21:55:43+00:00</updated>
<author>
<name>Dave Airlie</name>
<email>airlied@redhat.com</email>
</author>
<published>2014-01-23T23:50:18+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux-stable.git/commit/?id=f105771f195c34e690a37218e8f9c582d29a08b6'/>
<id>f105771f195c34e690a37218e8f9c582d29a08b6</id>
<content type='text'>
commit f4b4718b61d1d5a7442a4fd6863ea80c3a10e508 upstream.

these 3 were checking in_interrupt but we have situations where
calling vunmap under this could cause a BUG to be hit in
smp_call_function_many. Use the drm_can_sleep macro instead,
which should stop this path from been taken in this case.

Signed-off-by: Dave Airlie &lt;airlied@redhat.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;

</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
commit f4b4718b61d1d5a7442a4fd6863ea80c3a10e508 upstream.

these 3 were checking in_interrupt but we have situations where
calling vunmap under this could cause a BUG to be hit in
smp_call_function_many. Use the drm_can_sleep macro instead,
which should stop this path from been taken in this case.

Signed-off-by: Dave Airlie &lt;airlied@redhat.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;

</pre>
</div>
</content>
</entry>
<entry>
<title>drm/mgag200: drop pointless info print.</title>
<updated>2013-11-08T05:49:43+00:00</updated>
<author>
<name>Dave Airlie</name>
<email>airlied@redhat.com</email>
</author>
<published>2013-11-05T03:21:17+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux-stable.git/commit/?id=ec61f5eb5895926a7ad8bb4472bdc95dc1e44764'/>
<id>ec61f5eb5895926a7ad8bb4472bdc95dc1e44764</id>
<content type='text'>
This isn't useful anymore.

Signed-off-by: Dave Airlie &lt;airlied@redhat.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This isn't useful anymore.

Signed-off-by: Dave Airlie &lt;airlied@redhat.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>drm: Add separate Kconfig option for fbdev helpers</title>
<updated>2013-10-11T21:36:58+00:00</updated>
<author>
<name>Daniel Vetter</name>
<email>daniel.vetter@ffwll.ch</email>
</author>
<published>2013-10-08T15:44:47+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux-stable.git/commit/?id=92b6f89f6b85f433ddac1f4a9eb0962dc96380fe'/>
<id>92b6f89f6b85f433ddac1f4a9eb0962dc96380fe</id>
<content type='text'>
For drivers which might want to disable fbdev legacy support.

Select the new option in all drivers for now, so this shouldn't result
in any change. Drivers need some work anyway to make fbdev support
optional (if they have it implemented, that is), so the recommended
way to expose this is by adding per-driver options. At least as long
as most drivers don't support disabling the fbdev support.

v2: Update for new drm drivers msm and rcar-du. Note that Rob's msm
driver can already take advantage of this, which allows us to build
msm without any fbdev depencies in the kernel!

v3: Move the MODULE_* stuff from the fbdev helper file to
drm_crtc_helper.c.

Cc: David Herrmann &lt;dh.herrmann@gmail.com&gt;
Cc: Rob Clark &lt;robdclark@gmail.com&gt;
Reviewed-by: Rob Clark &lt;robdclark@gmail.com&gt;
Acked-by: Dave Airlie &lt;airlied@linux.ie&gt;
Reviewed-by: Chon Ming Lee &lt;chon.ming.lee@intel.com&gt;
Signed-off-by: Daniel Vetter &lt;daniel.vetter@ffwll.ch&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
For drivers which might want to disable fbdev legacy support.

Select the new option in all drivers for now, so this shouldn't result
in any change. Drivers need some work anyway to make fbdev support
optional (if they have it implemented, that is), so the recommended
way to expose this is by adding per-driver options. At least as long
as most drivers don't support disabling the fbdev support.

v2: Update for new drm drivers msm and rcar-du. Note that Rob's msm
driver can already take advantage of this, which allows us to build
msm without any fbdev depencies in the kernel!

v3: Move the MODULE_* stuff from the fbdev helper file to
drm_crtc_helper.c.

Cc: David Herrmann &lt;dh.herrmann@gmail.com&gt;
Cc: Rob Clark &lt;robdclark@gmail.com&gt;
Reviewed-by: Rob Clark &lt;robdclark@gmail.com&gt;
Acked-by: Dave Airlie &lt;airlied@linux.ie&gt;
Reviewed-by: Chon Ming Lee &lt;chon.ming.lee@intel.com&gt;
Signed-off-by: Daniel Vetter &lt;daniel.vetter@ffwll.ch&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>drm: kill -&gt;gem_init_object() and friends</title>
<updated>2013-10-09T04:38:02+00:00</updated>
<author>
<name>David Herrmann</name>
<email>dh.herrmann@gmail.com</email>
</author>
<published>2013-10-02T08:15:18+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux-stable.git/commit/?id=16eb5f4379b2097438a224381be3b4d9e56ac979'/>
<id>16eb5f4379b2097438a224381be3b4d9e56ac979</id>
<content type='text'>
All drivers embed gem-objects into their own buffer objects. There is no
reason to keep drm_gem_object_alloc(), gem-&gt;driver_private and
-&gt;gem_init_object() anymore.

New drivers are highly encouraged to do the same. There is no benefit in
allocating gem-objects separately.

Cc: Dave Airlie &lt;airlied@gmail.com&gt;
Cc: Alex Deucher &lt;alexdeucher@gmail.com&gt;
Cc: Daniel Vetter &lt;daniel@ffwll.ch&gt;
Cc: Jerome Glisse &lt;jglisse@redhat.com&gt;
Cc: Rob Clark &lt;robdclark@gmail.com&gt;
Cc: Inki Dae &lt;inki.dae@samsung.com&gt;
Cc: Ben Skeggs &lt;skeggsb@gmail.com&gt;
Cc: Patrik Jakobsson &lt;patrik.r.jakobsson@gmail.com&gt;
Signed-off-by: David Herrmann &lt;dh.herrmann@gmail.com&gt;
Acked-by: Alex Deucher &lt;alexander.deucher@amd.com&gt;
Signed-off-by: Dave Airlie &lt;airlied@redhat.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
All drivers embed gem-objects into their own buffer objects. There is no
reason to keep drm_gem_object_alloc(), gem-&gt;driver_private and
-&gt;gem_init_object() anymore.

New drivers are highly encouraged to do the same. There is no benefit in
allocating gem-objects separately.

Cc: Dave Airlie &lt;airlied@gmail.com&gt;
Cc: Alex Deucher &lt;alexdeucher@gmail.com&gt;
Cc: Daniel Vetter &lt;daniel@ffwll.ch&gt;
Cc: Jerome Glisse &lt;jglisse@redhat.com&gt;
Cc: Rob Clark &lt;robdclark@gmail.com&gt;
Cc: Inki Dae &lt;inki.dae@samsung.com&gt;
Cc: Ben Skeggs &lt;skeggsb@gmail.com&gt;
Cc: Patrik Jakobsson &lt;patrik.r.jakobsson@gmail.com&gt;
Signed-off-by: David Herrmann &lt;dh.herrmann@gmail.com&gt;
Acked-by: Alex Deucher &lt;alexander.deucher@amd.com&gt;
Signed-off-by: Dave Airlie &lt;airlied@redhat.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>Merge branch 'drm-next-3.12' of git://people.freedesktop.org/~agd5f/linux into drm-next</title>
<updated>2013-09-01T23:31:40+00:00</updated>
<author>
<name>Dave Airlie</name>
<email>airlied@redhat.com</email>
</author>
<published>2013-09-01T23:31:40+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux-stable.git/commit/?id=9c725e5bcdae59d5383d4aec33a34c822582dda5'/>
<id>9c725e5bcdae59d5383d4aec33a34c822582dda5</id>
<content type='text'>
Alex writes:
This is the radeon drm-next request.  Big changes include:
- support for dpm on CIK parts
- support for ASPM on CIK parts
- support for berlin GPUs
- major ring handling cleanup
- remove the old 3D blit code for bo moves in favor of CP DMA or sDMA
- lots of bug fixes

[airlied: fix up a bunch of conflicts from drm_order removal]

* 'drm-next-3.12' of git://people.freedesktop.org/~agd5f/linux: (898 commits)
  drm/radeon/dpm: make sure dc performance level limits are valid (CI)
  drm/radeon/dpm: make sure dc performance level limits are valid (BTC-SI) (v2)
  drm/radeon: gcc fixes for extended dpm tables
  drm/radeon: gcc fixes for kb/kv dpm
  drm/radeon: gcc fixes for ci dpm
  drm/radeon: gcc fixes for si dpm
  drm/radeon: gcc fixes for ni dpm
  drm/radeon: gcc fixes for trinity dpm
  drm/radeon: gcc fixes for sumo dpm
  drm/radeonn: gcc fixes for rv7xx/eg/btc dpm
  drm/radeon: gcc fixes for rv6xx dpm
  drm/radeon: gcc fixes for radeon_atombios.c
  drm/radeon: enable UVD interrupts on CIK
  drm/radeon: fix init ordering for r600+
  drm/radeon/dpm: only need to reprogram uvd if uvd pg is enabled
  drm/radeon: check the return value of uvd_v1_0_start in uvd_v1_0_init
  drm/radeon: split out radeon_uvd_resume from uvd_v4_2_resume
  radeon kms: fix uninitialised hotplug work usage in r100_irq_process()
  drm/radeon/audio: set up the sads on DCE3.2 asics
  drm/radeon: fix handling of variable sized arrays for router objects
  ...

Conflicts:
	drivers/gpu/drm/i915/i915_dma.c
	drivers/gpu/drm/i915/i915_gem_dmabuf.c
	drivers/gpu/drm/i915/intel_pm.c
	drivers/gpu/drm/radeon/cik.c
	drivers/gpu/drm/radeon/ni.c
	drivers/gpu/drm/radeon/r600.c
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Alex writes:
This is the radeon drm-next request.  Big changes include:
- support for dpm on CIK parts
- support for ASPM on CIK parts
- support for berlin GPUs
- major ring handling cleanup
- remove the old 3D blit code for bo moves in favor of CP DMA or sDMA
- lots of bug fixes

[airlied: fix up a bunch of conflicts from drm_order removal]

* 'drm-next-3.12' of git://people.freedesktop.org/~agd5f/linux: (898 commits)
  drm/radeon/dpm: make sure dc performance level limits are valid (CI)
  drm/radeon/dpm: make sure dc performance level limits are valid (BTC-SI) (v2)
  drm/radeon: gcc fixes for extended dpm tables
  drm/radeon: gcc fixes for kb/kv dpm
  drm/radeon: gcc fixes for ci dpm
  drm/radeon: gcc fixes for si dpm
  drm/radeon: gcc fixes for ni dpm
  drm/radeon: gcc fixes for trinity dpm
  drm/radeon: gcc fixes for sumo dpm
  drm/radeonn: gcc fixes for rv7xx/eg/btc dpm
  drm/radeon: gcc fixes for rv6xx dpm
  drm/radeon: gcc fixes for radeon_atombios.c
  drm/radeon: enable UVD interrupts on CIK
  drm/radeon: fix init ordering for r600+
  drm/radeon/dpm: only need to reprogram uvd if uvd pg is enabled
  drm/radeon: check the return value of uvd_v1_0_start in uvd_v1_0_init
  drm/radeon: split out radeon_uvd_resume from uvd_v4_2_resume
  radeon kms: fix uninitialised hotplug work usage in r100_irq_process()
  drm/radeon/audio: set up the sads on DCE3.2 asics
  drm/radeon: fix handling of variable sized arrays for router objects
  ...

Conflicts:
	drivers/gpu/drm/i915/i915_dma.c
	drivers/gpu/drm/i915/i915_gem_dmabuf.c
	drivers/gpu/drm/i915/intel_pm.c
	drivers/gpu/drm/radeon/cik.c
	drivers/gpu/drm/radeon/ni.c
	drivers/gpu/drm/radeon/r600.c
</pre>
</div>
</content>
</entry>
<entry>
<title>drm: verify vma access in TTM+GEM drivers</title>
<updated>2013-08-27T01:54:58+00:00</updated>
<author>
<name>David Herrmann</name>
<email>dh.herrmann@gmail.com</email>
</author>
<published>2013-08-25T16:28:59+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux-stable.git/commit/?id=acb4652703f0a452405a3ab9319594eddc41391b'/>
<id>acb4652703f0a452405a3ab9319594eddc41391b</id>
<content type='text'>
GEM does already a good job in tracking access to gem buffers via handles
and drm_vma access management. However, TTM drivers currently do not
verify this during mmap().

TTM provides the verify_access() callback to test this. So fix all drivers
to actually call into gem+vma to verify access instead of always returning
0.

All drivers assume that user-space can only get access to TTM buffers via
GEM handles. So whenever the verify_access() callback is called from
ttm_bo_mmap(), the buffer must have a valid embedded gem object. This is
true for all TTM+GEM drivers. But that's why this patch doesn't touch pure
TTM drivers (ie, vmwgfx).

v2: Switch to drm_vma_node_verify_access() to correctly return -EACCES if
    access was denied.

Cc: Dave Airlie &lt;airlied@redhat.com&gt;
Cc: Alex Deucher &lt;alexander.deucher@amd.com&gt;
Cc: Ben Skeggs &lt;bskeggs@redhat.com&gt;
Cc: Maarten Lankhorst &lt;maarten.lankhorst@canonical.com&gt;
Cc: Jerome Glisse &lt;jglisse@redhat.com&gt;
Signed-off-by: David Herrmann &lt;dh.herrmann@gmail.com&gt;
Signed-off-by: Dave Airlie &lt;airlied@redhat.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
GEM does already a good job in tracking access to gem buffers via handles
and drm_vma access management. However, TTM drivers currently do not
verify this during mmap().

TTM provides the verify_access() callback to test this. So fix all drivers
to actually call into gem+vma to verify access instead of always returning
0.

All drivers assume that user-space can only get access to TTM buffers via
GEM handles. So whenever the verify_access() callback is called from
ttm_bo_mmap(), the buffer must have a valid embedded gem object. This is
true for all TTM+GEM drivers. But that's why this patch doesn't touch pure
TTM drivers (ie, vmwgfx).

v2: Switch to drm_vma_node_verify_access() to correctly return -EACCES if
    access was denied.

Cc: Dave Airlie &lt;airlied@redhat.com&gt;
Cc: Alex Deucher &lt;alexander.deucher@amd.com&gt;
Cc: Ben Skeggs &lt;bskeggs@redhat.com&gt;
Cc: Maarten Lankhorst &lt;maarten.lankhorst@canonical.com&gt;
Cc: Jerome Glisse &lt;jglisse@redhat.com&gt;
Signed-off-by: David Herrmann &lt;dh.herrmann@gmail.com&gt;
Signed-off-by: Dave Airlie &lt;airlied@redhat.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>drm: rip out drm_core_has_MTRR checks</title>
<updated>2013-08-19T04:11:44+00:00</updated>
<author>
<name>Daniel Vetter</name>
<email>daniel.vetter@ffwll.ch</email>
</author>
<published>2013-08-08T13:41:27+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux-stable.git/commit/?id=281856477cdaba70032af502ee7192fe7aa54f69'/>
<id>281856477cdaba70032af502ee7192fe7aa54f69</id>
<content type='text'>
The new arch_phys_wc_add/del functions do the right thing both with
and without MTRR support in the kernel. So we can drop these
additional checks.

David Herrmann suggest to also kill the DRIVER_USE_MTRR flag since
it's now unused, which spurred me to do a bit a better audit of the
affected drivers. David helped a lot in that. Quoting our mail
discussion:

On Wed, Jul 10, 2013 at 5:41 PM, David Herrmann &lt;dh.herrmann@gmail.com&gt; wrote:
&gt; On Wed, Jul 10, 2013 at 5:22 PM, Daniel Vetter &lt;daniel.vetter@ffwll.ch&gt; wrote:
&gt;&gt; On Wed, Jul 10, 2013 at 3:51 PM, David Herrmann &lt;dh.herrmann@gmail.com&gt; wrote:
&gt;&gt;&gt;&gt; -#if __OS_HAS_MTRR
&gt;&gt;&gt;&gt; -static inline int drm_core_has_MTRR(struct drm_device *dev)
&gt;&gt;&gt;&gt; -{
&gt;&gt;&gt;&gt; -       return drm_core_check_feature(dev, DRIVER_USE_MTRR);
&gt;&gt;&gt;&gt; -}
&gt;&gt;&gt;&gt; -#else
&gt;&gt;&gt;&gt; -#define drm_core_has_MTRR(dev) (0)
&gt;&gt;&gt;&gt; -#endif
&gt;&gt;&gt;&gt; -
&gt;&gt;&gt;
&gt;&gt;&gt; That was the last user of DRIVER_USE_MTRR (apart from drivers setting
&gt;&gt;&gt; it in .driver_features). Any reason to keep it around?
&gt;&gt;
&gt;&gt; Yeah, I guess we could rip things out. Which will also force me to
&gt;&gt; properly audit drivers for the eventual behaviour change this could
&gt;&gt; entail (in case there's an x86 driver which did not ask for an mtrr,
&gt;&gt; but iirc there isn't).
&gt;
&gt; david@david-mb ~/dev/kernel/linux $ for i in drivers/gpu/drm/* ; do if
&gt; test -d "$i" ; then if ! grep -q USE_MTRR -r $i ; then echo $i ; fi ;
&gt; fi ; done
&gt; drivers/gpu/drm/exynos
&gt; drivers/gpu/drm/gma500
&gt; drivers/gpu/drm/i2c
&gt; drivers/gpu/drm/nouveau
&gt; drivers/gpu/drm/omapdrm
&gt; drivers/gpu/drm/qxl
&gt; drivers/gpu/drm/rcar-du
&gt; drivers/gpu/drm/shmobile
&gt; drivers/gpu/drm/tilcdc
&gt; drivers/gpu/drm/ttm
&gt; drivers/gpu/drm/udl
&gt; drivers/gpu/drm/vmwgfx
&gt; david@david-mb ~/dev/kernel/linux $
&gt;
&gt; So for x86 gma500,nouveau,qxl,udl,vmwgfx don't set DRIVER_USE_MTRR.
&gt; But I cannot tell whether they break if we call arch_phys_wc_add/del,
&gt; anyway. At least nouveau seemed to work here, but it doesn't use AGP
&gt; or drm_bufs, I guess.

Cool, thanks a lot for stitching together the list of drivers to look
at. So for real KMS drivers it's the drives responsibility to add an
mtrr if it needs one. nouvea, radeon, mgag200, i915 and vmwgfx do that
already. Somehow the savage driver also ends up doing that, I have no
idea why.

Note that gma500 as a pure KMS driver doesn't need MTRR setup since
the platforms that it supports all support PAT. So no MTRRs needed to
get wc iomappings.

The mtrr support in the drm core is all for legacy mappings of garts,
framebuffers and registers. All legacy drivers set the USE_MTRR flag,
so we're good there.

All in all I think we can really just ditch this

/endquote

v2: Also kill DRIVER_USE_MTRR as suggested by David Herrmann

v3: Rebase on top of David Herrmann's agp setup/cleanup changes.

Cc: David Herrmann &lt;dh.herrmann@gmail.com&gt;
Cc: Andy Lutomirski &lt;luto@amacapital.net&gt;
Signed-off-by: Daniel Vetter &lt;daniel.vetter@ffwll.ch&gt;
Acked-by: Andy Lutomirski &lt;luto@amacapital.net&gt;
Reviewed-by: David Herrmann &lt;dh.herrmann@gmail.com&gt;
Signed-off-by: Dave Airlie &lt;airlied@redhat.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
The new arch_phys_wc_add/del functions do the right thing both with
and without MTRR support in the kernel. So we can drop these
additional checks.

David Herrmann suggest to also kill the DRIVER_USE_MTRR flag since
it's now unused, which spurred me to do a bit a better audit of the
affected drivers. David helped a lot in that. Quoting our mail
discussion:

On Wed, Jul 10, 2013 at 5:41 PM, David Herrmann &lt;dh.herrmann@gmail.com&gt; wrote:
&gt; On Wed, Jul 10, 2013 at 5:22 PM, Daniel Vetter &lt;daniel.vetter@ffwll.ch&gt; wrote:
&gt;&gt; On Wed, Jul 10, 2013 at 3:51 PM, David Herrmann &lt;dh.herrmann@gmail.com&gt; wrote:
&gt;&gt;&gt;&gt; -#if __OS_HAS_MTRR
&gt;&gt;&gt;&gt; -static inline int drm_core_has_MTRR(struct drm_device *dev)
&gt;&gt;&gt;&gt; -{
&gt;&gt;&gt;&gt; -       return drm_core_check_feature(dev, DRIVER_USE_MTRR);
&gt;&gt;&gt;&gt; -}
&gt;&gt;&gt;&gt; -#else
&gt;&gt;&gt;&gt; -#define drm_core_has_MTRR(dev) (0)
&gt;&gt;&gt;&gt; -#endif
&gt;&gt;&gt;&gt; -
&gt;&gt;&gt;
&gt;&gt;&gt; That was the last user of DRIVER_USE_MTRR (apart from drivers setting
&gt;&gt;&gt; it in .driver_features). Any reason to keep it around?
&gt;&gt;
&gt;&gt; Yeah, I guess we could rip things out. Which will also force me to
&gt;&gt; properly audit drivers for the eventual behaviour change this could
&gt;&gt; entail (in case there's an x86 driver which did not ask for an mtrr,
&gt;&gt; but iirc there isn't).
&gt;
&gt; david@david-mb ~/dev/kernel/linux $ for i in drivers/gpu/drm/* ; do if
&gt; test -d "$i" ; then if ! grep -q USE_MTRR -r $i ; then echo $i ; fi ;
&gt; fi ; done
&gt; drivers/gpu/drm/exynos
&gt; drivers/gpu/drm/gma500
&gt; drivers/gpu/drm/i2c
&gt; drivers/gpu/drm/nouveau
&gt; drivers/gpu/drm/omapdrm
&gt; drivers/gpu/drm/qxl
&gt; drivers/gpu/drm/rcar-du
&gt; drivers/gpu/drm/shmobile
&gt; drivers/gpu/drm/tilcdc
&gt; drivers/gpu/drm/ttm
&gt; drivers/gpu/drm/udl
&gt; drivers/gpu/drm/vmwgfx
&gt; david@david-mb ~/dev/kernel/linux $
&gt;
&gt; So for x86 gma500,nouveau,qxl,udl,vmwgfx don't set DRIVER_USE_MTRR.
&gt; But I cannot tell whether they break if we call arch_phys_wc_add/del,
&gt; anyway. At least nouveau seemed to work here, but it doesn't use AGP
&gt; or drm_bufs, I guess.

Cool, thanks a lot for stitching together the list of drivers to look
at. So for real KMS drivers it's the drives responsibility to add an
mtrr if it needs one. nouvea, radeon, mgag200, i915 and vmwgfx do that
already. Somehow the savage driver also ends up doing that, I have no
idea why.

Note that gma500 as a pure KMS driver doesn't need MTRR setup since
the platforms that it supports all support PAT. So no MTRRs needed to
get wc iomappings.

The mtrr support in the drm core is all for legacy mappings of garts,
framebuffers and registers. All legacy drivers set the USE_MTRR flag,
so we're good there.

All in all I think we can really just ditch this

/endquote

v2: Also kill DRIVER_USE_MTRR as suggested by David Herrmann

v3: Rebase on top of David Herrmann's agp setup/cleanup changes.

Cc: David Herrmann &lt;dh.herrmann@gmail.com&gt;
Cc: Andy Lutomirski &lt;luto@amacapital.net&gt;
Signed-off-by: Daniel Vetter &lt;daniel.vetter@ffwll.ch&gt;
Acked-by: Andy Lutomirski &lt;luto@amacapital.net&gt;
Reviewed-by: David Herrmann &lt;dh.herrmann@gmail.com&gt;
Signed-off-by: Dave Airlie &lt;airlied@redhat.com&gt;
</pre>
</div>
</content>
</entry>
</feed>
