<feed xmlns='http://www.w3.org/2005/Atom'>
<title>kernel.git/drivers/gpu/drm/ttm, branch linux-5.13.y</title>
<subtitle>Hosts the 0x221E linux distro kernel.
</subtitle>
<id>https://git.0xinfinity.dev/distro/kernel.git/atom?h=linux-5.13.y</id>
<link rel='self' href='https://git.0xinfinity.dev/distro/kernel.git/atom?h=linux-5.13.y'/>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/'/>
<updated>2021-07-31T06:13:46Z</updated>
<entry>
<title>drm/ttm: add a check against null pointer dereference</title>
<updated>2021-07-31T06:13:46Z</updated>
<author>
<name>Zheyu Ma</name>
</author>
<published>2021-07-14T14:54:19Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=37ac00a0d35881cbf77302ac3fe011e07e5f6e02'/>
<id>urn:sha1:37ac00a0d35881cbf77302ac3fe011e07e5f6e02</id>
<content type='text'>
[ Upstream commit 9e5c772954406829e928dbe59891d08938ead04b ]

When calling ttm_range_man_fini(), 'man' may be uninitialized, which may
cause a null pointer dereference bug.

Fix this by checking if it is a null pointer.

This log reveals it:

[    7.902580 ] BUG: kernel NULL pointer dereference, address: 0000000000000058
[    7.905721 ] RIP: 0010:ttm_range_man_fini+0x40/0x160
[    7.911826 ] Call Trace:
[    7.911826 ]  radeon_ttm_fini+0x167/0x210
[    7.911826 ]  radeon_bo_fini+0x15/0x40
[    7.913767 ]  rs400_fini+0x55/0x80
[    7.914358 ]  radeon_device_fini+0x3c/0x140
[    7.914358 ]  radeon_driver_unload_kms+0x5c/0xe0
[    7.914358 ]  radeon_driver_load_kms+0x13a/0x200
[    7.914358 ]  ? radeon_driver_unload_kms+0xe0/0xe0
[    7.914358 ]  drm_dev_register+0x1db/0x290
[    7.914358 ]  radeon_pci_probe+0x16a/0x230
[    7.914358 ]  local_pci_probe+0x4a/0xb0

Signed-off-by: Zheyu Ma &lt;zheyuma97@gmail.com&gt;
Reviewed-by: Christian König &lt;christian.koenig@amd.com&gt;
Link: https://patchwork.freedesktop.org/patch/msgid/1626274459-8148-1-git-send-email-zheyuma97@gmail.com
Signed-off-by: Christian König &lt;christian.koenig@amd.com&gt;
Signed-off-by: Sasha Levin &lt;sashal@kernel.org&gt;
</content>
</entry>
<entry>
<title>drm/ttm: Force re-init if ttm_global_init() fails</title>
<updated>2021-07-28T12:37:32Z</updated>
<author>
<name>Jason Ekstrand</name>
</author>
<published>2021-07-20T18:13:55Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=a521c15683c1d604a85c3829d1a8428040807f35'/>
<id>urn:sha1:a521c15683c1d604a85c3829d1a8428040807f35</id>
<content type='text'>
[ Upstream commit 235c3610d5f02ee91244239b43cd9ae8b4859dff ]

If we have a failure, decrement the reference count so that the next
call to ttm_global_init() will actually do something instead of assume
everything is all set up.

Signed-off-by: Jason Ekstrand &lt;jason@jlekstrand.net&gt;
Fixes: 62b53b37e4b1 ("drm/ttm: use a static ttm_bo_global instance")
Reviewed-by: Christian König &lt;christian.koenig@amd.com&gt;
Link: https://patchwork.freedesktop.org/patch/msgid/20210720181357.2760720-5-jason@jlekstrand.net
Signed-off-by: Christian König &lt;christian.koenig@amd.com&gt;
Signed-off-by: Sasha Levin &lt;sashal@kernel.org&gt;
</content>
</entry>
<entry>
<title>drm/ttm: fix deref of bo-&gt;ttm without holding the lock v2</title>
<updated>2021-06-08T11:24:15Z</updated>
<author>
<name>Christian König</name>
</author>
<published>2021-05-28T12:34:38Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=2d2ddb589d5925ec7f2d1b17d88a2b36bf536105'/>
<id>urn:sha1:2d2ddb589d5925ec7f2d1b17d88a2b36bf536105</id>
<content type='text'>
We need to grab the resv lock first before doing that check.

v2 (chk): simplify the change for -fixes

Signed-off-by: Christian König &lt;christian.koenig@amd.com&gt;
Signed-off-by: Thomas Hellström &lt;thomas.hellstrom@linux.intel.com&gt;
Reviewed-by: Huang Rui &lt;ray.huang@amd.com&gt;
Link: https://patchwork.freedesktop.org/patch/msgid/20210528130041.1683-1-christian.koenig@amd.com
</content>
</entry>
<entry>
<title>drm/ttm: Skip swapout if ttm object is not populated</title>
<updated>2021-05-26T13:02:47Z</updated>
<author>
<name>xinhui pan</name>
</author>
<published>2021-05-21T08:31:12Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=35f819d218035ddfbc71e7cf62a4849231701e58'/>
<id>urn:sha1:35f819d218035ddfbc71e7cf62a4849231701e58</id>
<content type='text'>
Swapping a ttm object which has no backend pages makes no sense.

Suggested-by: Christian König &lt;christian.koenig@amd.com&gt;
Signed-off-by: xinhui pan &lt;xinhui.pan@amd.com&gt;
Reviewed-by: Christian König &lt;christian.koenig@amd.com&gt;
Link: https://patchwork.freedesktop.org/patch/msgid/20210521083112.33176-1-xinhui.pan@amd.com
CC: stable@kernel.org
Signed-off-by: Christian König &lt;christian.koenig@amd.com&gt;
</content>
</entry>
<entry>
<title>Merge tag 'drm-misc-next-fixes-2021-04-29' of git://anongit.freedesktop.org/drm/drm-misc into drm-next</title>
<updated>2021-04-30T00:13:48Z</updated>
<author>
<name>Dave Airlie</name>
</author>
<published>2021-04-30T00:13:08Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=9b2788dbcef756a77659fa22e6a73bec4a57d126'/>
<id>urn:sha1:9b2788dbcef756a77659fa22e6a73bec4a57d126</id>
<content type='text'>
Two patches in drm-misc-next-fixes this week, one to fix the error
handling in TTM when a BO can't be swapped out and one to prevent a
wrong dereference in efifb.

Signed-off-by: Dave Airlie &lt;airlied@redhat.com&gt;

From: Maxime Ripard &lt;maxime@cerno.tech&gt;
Link: https://patchwork.freedesktop.org/patch/msgid/20210429090308.k3fuqvenf6vupfmg@gilmour
</content>
</entry>
<entry>
<title>drm/ttm: fix error handling if no BO can be swapped out v4</title>
<updated>2021-04-23T12:20:38Z</updated>
<author>
<name>Shiwu Zhang</name>
</author>
<published>2021-04-22T08:37:49Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=2a269ba888d3dcf950ef7ceb8421f7ff6aeaa9c0'/>
<id>urn:sha1:2a269ba888d3dcf950ef7ceb8421f7ff6aeaa9c0</id>
<content type='text'>
In case that all pre-allocated BOs are busy, just continue to populate
BOs since likely half of system memory in total is still free.

v4 (chk): fix code moved to VMWGFX as well

Signed-off-by: Shiwu Zhang &lt;shiwu.zhang@amd.com&gt;
Reviewed-by: Christian König &lt;christian.koenig@amd.com&gt;
Signed-off-by: Christian König &lt;christian.koenig@amd.com&gt;
Link: https://patchwork.freedesktop.org/patch/msgid/20210422115757.3946-1-christian.koenig@amd.com
</content>
</entry>
<entry>
<title>Merge tag 'drm-misc-next-fixes-2021-04-22' of git://anongit.freedesktop.org/drm/drm-misc into drm-next</title>
<updated>2021-04-23T03:53:07Z</updated>
<author>
<name>Dave Airlie</name>
</author>
<published>2021-04-23T02:56:21Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=a1a1ca70deb3ec600eeabb21de7f3f48aaae5695'/>
<id>urn:sha1:a1a1ca70deb3ec600eeabb21de7f3f48aaae5695</id>
<content type='text'>
A few fixes for the next merge window, with some build fixes for anx7625
and lt8912b bridges, incorrect error handling for lt8912b and TTM, and
one fix for TTM page limit accounting.

Signed-off-by: Dave Airlie &lt;airlied@redhat.com&gt;

From: Maxime Ripard &lt;maxime@cerno.tech&gt;
Link: https://patchwork.freedesktop.org/patch/msgid/20210422163329.dvbuwre3akwdmzjt@gilmour
</content>
</entry>
<entry>
<title>drm/ttm: Don't count pages in SG BOs against pages_limit</title>
<updated>2021-04-21T13:35:20Z</updated>
<author>
<name>Felix Kuehling</name>
</author>
<published>2021-04-14T06:48:03Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=a4394b6d0a273941a75ebe86a86d6416d536ed0f'/>
<id>urn:sha1:a4394b6d0a273941a75ebe86a86d6416d536ed0f</id>
<content type='text'>
Pages in SG BOs were not allocated by TTM. So don't count them against
TTM's pages limit.

Signed-off-by: Felix Kuehling &lt;Felix.Kuehling@amd.com&gt;
Reviewed-by: Christian König &lt;christian.koenig@amd.com&gt;
Signed-off-by: Christian König &lt;christian.koenig@amd.com&gt;
Link: https://patchwork.freedesktop.org/patch/msgid/20210414064804.29356-9-Felix.Kuehling@amd.com
</content>
</entry>
<entry>
<title>drm/ttm: fix return value check</title>
<updated>2021-04-21T13:35:11Z</updated>
<author>
<name>Christian König</name>
</author>
<published>2021-04-09T12:58:43Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=8a9d24f222ea1b1c20dffbc62bff736f3f94b768'/>
<id>urn:sha1:8a9d24f222ea1b1c20dffbc62bff736f3f94b768</id>
<content type='text'>
The function returns the number of swapped pages here. Only abort when we get
a negative error code.

Signed-off-by: Christian König &lt;christian.koenig@amd.com&gt;
Reviewed-by: Matthew Auld &lt;matthew.auld@intel.com&gt;
Link: https://patchwork.freedesktop.org/patch/msgid/20210409130113.1459-1-christian.koenig@amd.com
</content>
</entry>
<entry>
<title>drm/ttm: ioremap buffer according to TTM mem caching setting</title>
<updated>2021-04-08T10:21:22Z</updated>
<author>
<name>Oak Zeng</name>
</author>
<published>2021-02-27T01:09:42Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=b849bec29a991d25689507315db5641f7512def3'/>
<id>urn:sha1:b849bec29a991d25689507315db5641f7512def3</id>
<content type='text'>
If tbo.mem.bus.caching is cached, buffer is intended to be mapped
as cached from CPU. Map it with ioremap_cache.

This wasn't necessary before as device memory was never mapped
as cached from CPU side. It becomes necessary for aldebaran as
device memory is mapped cached from CPU.

Signed-off-by: Oak Zeng &lt;Oak.Zeng@amd.com&gt;
Reviewed-by: Christian Konig &lt;Christian.Koenig@amd.com&gt;
Signed-off-by: Alex Deucher &lt;alexander.deucher@amd.com&gt;
Link: https://patchwork.freedesktop.org/patch/msgid/1614638628-10508-1-git-send-email-Oak.Zeng@amd.com
Signed-off-by: Christian König &lt;christian.koenig@amd.com&gt;
</content>
</entry>
</feed>
