Philip Yang
bdffb36bcd
drm/amdgpu: prevent double kfree ttm->sg
...
[ Upstream commit 1d0e16ac1a9e800598dcfa5b6bc53b704a103390 ]
Set ttm->sg to NULL after kfree, to avoid memory corruption backtrace:
[ 420.932812] kernel BUG at
/build/linux-do9eLF/linux-4.15.0/mm/slub.c:295!
[ 420.934182] invalid opcode: 0000 [#1 ] SMP NOPTI
[ 420.935445] Modules linked in: xt_conntrack ipt_MASQUERADE
[ 420.951332] Hardware name: Dell Inc. PowerEdge R7525/0PYVT1, BIOS
1.5.4 07/09/2020
[ 420.952887] RIP: 0010:__slab_free+0x180/0x2d0
[ 420.954419] RSP: 0018:ffffbe426291fa60 EFLAGS: 00010246
[ 420.955963] RAX: ffff9e29263e9c30 RBX: ffff9e29263e9c30 RCX:
000000018100004b
[ 420.957512] RDX: ffff9e29263e9c30 RSI: fffff3d33e98fa40 RDI:
ffff9e297e407a80
[ 420.959055] RBP: ffffbe426291fb00 R08: 0000000000000001 R09:
ffffffffc0d39ade
[ 420.960587] R10: ffffbe426291fb20 R11: ffff9e49ffdd4000 R12:
ffff9e297e407a80
[ 420.962105] R13: fffff3d33e98fa40 R14: ffff9e29263e9c30 R15:
ffff9e2954464fd8
[ 420.963611] FS: 00007fa2ea097780(0000) GS:ffff9e297e840000(0000)
knlGS:0000000000000000
[ 420.965144] CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033
[ 420.966663] CR2: 00007f16bfffefb8 CR3: 0000001ff0c62000 CR4:
0000000000340ee0
[ 420.968193] Call Trace:
[ 420.969703] ? __page_cache_release+0x3c/0x220
[ 420.971294] ? amdgpu_ttm_tt_unpopulate+0x5e/0x80 [amdgpu]
[ 420.972789] kfree+0x168/0x180
[ 420.974353] ? amdgpu_ttm_tt_set_user_pages+0x64/0xc0 [amdgpu]
[ 420.975850] ? kfree+0x168/0x180
[ 420.977403] amdgpu_ttm_tt_unpopulate+0x5e/0x80 [amdgpu]
[ 420.978888] ttm_tt_unpopulate.part.10+0x53/0x60 [amdttm]
[ 420.980357] ttm_tt_destroy.part.11+0x4f/0x60 [amdttm]
[ 420.981814] ttm_tt_destroy+0x13/0x20 [amdttm]
[ 420.983273] ttm_bo_cleanup_memtype_use+0x36/0x80 [amdttm]
[ 420.984725] ttm_bo_release+0x1c9/0x360 [amdttm]
[ 420.986167] amdttm_bo_put+0x24/0x30 [amdttm]
[ 420.987663] amdgpu_bo_unref+0x1e/0x30 [amdgpu]
[ 420.989165] amdgpu_amdkfd_gpuvm_alloc_memory_of_gpu+0x9ca/0xb10
[amdgpu]
[ 420.990666] kfd_ioctl_alloc_memory_of_gpu+0xef/0x2c0 [amdgpu]
Signed-off-by: Philip Yang <Philip.Yang@amd.com>
Reviewed-by: Felix Kuehling <Felix.Kuehling@amd.com>
Reviewed-by: Christian König <christian.koenig@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2020-10-14 10:33:02 +02:00
..
2020-10-14 10:33:02 +02:00
2019-06-21 20:02:10 +02:00
2020-08-19 08:16:07 +02:00
2019-08-14 18:31:10 +02:00
2019-08-14 19:27:26 +02:00
2019-09-19 16:24:24 -07:00
2020-02-11 04:35:36 -08:00
2020-08-11 15:33:37 +02:00
2020-08-19 08:16:11 +02:00
2019-06-21 17:30:32 +02:00
2020-09-05 11:22:50 +02:00
2020-10-01 13:18:01 +02:00
2019-08-10 15:41:48 +02:00
2020-10-01 13:17:13 +02:00
2020-03-12 13:00:26 +01:00
2019-08-14 18:30:52 +02:00
2019-12-13 08:42:56 +01:00
2020-09-23 12:40:43 +02:00
2020-08-21 13:05:29 +02:00
2020-09-03 11:26:52 +02:00
2019-09-19 16:24:24 -07:00
2020-10-01 13:17:25 +02:00
2020-09-23 12:40:42 +02:00
2019-12-31 16:43:09 +01:00
2019-06-30 09:48:05 +02:00
2019-12-21 11:04:54 +01:00
2020-10-01 13:17:44 +02:00
2019-08-13 09:09:30 +02:00
2020-10-14 10:32:57 +02:00
2020-10-01 13:17:37 +02:00
2020-08-19 08:16:11 +02:00
2020-08-21 13:05:39 +02:00
2019-08-09 09:15:05 +02:00
2020-06-24 17:50:48 +02:00
2019-07-17 12:52:55 +02:00
2020-10-01 13:17:51 +02:00
2020-06-30 15:37:11 -04:00
2020-05-10 10:31:22 +02:00
2019-06-05 20:31:04 +02:00
2020-10-01 13:17:25 +02:00
2020-03-12 13:00:11 +01:00
2019-07-15 18:11:31 +02:00
2019-06-05 20:29:57 +02:00
2019-08-07 13:54:17 +02:00
2020-08-19 08:16:11 +02:00
2020-10-07 08:01:26 +02:00
2019-07-17 12:52:55 +02:00
2020-07-16 08:16:33 +02:00
2020-08-19 08:15:59 +02:00
2019-10-10 15:15:51 +02:00
2020-08-26 10:40:56 +02:00
2020-09-17 13:47:53 +02:00
2019-07-17 12:52:55 +02:00
2019-10-23 20:57:05 +02:00
2019-08-18 12:52:52 +02:00
2020-10-01 13:18:17 +02:00
2020-08-26 10:40:47 +02:00
2019-09-24 15:54:08 -07:00
2020-03-12 13:00:32 +01:00
2020-06-17 16:40:36 +02:00
2020-08-21 13:05:36 +02:00
2020-09-03 11:26:50 +02:00
2019-07-22 21:24:10 +02:00
2019-07-19 23:24:16 +02:00
2019-07-16 11:25:02 +02:00
2019-11-06 13:00:21 -05:00
2019-09-18 18:43:36 +02:00
2019-09-18 18:42:57 +02:00
2019-09-23 15:31:53 +08:00
2019-05-27 18:07:03 +02:00
2019-05-27 18:07:03 +02:00
2019-06-13 13:00:29 -04:00
2019-07-15 19:04:27 -07:00
2020-03-25 08:25:50 +01:00
2019-08-01 15:01:29 +02:00
2019-05-27 18:07:03 +02:00
2020-06-24 17:50:50 +02:00
2019-05-27 18:07:03 +02:00
2019-08-16 15:50:27 +03:00
2019-06-08 16:46:37 +02:00
2019-06-13 16:39:16 +02:00
2019-12-13 08:42:55 +01:00
2020-02-24 08:36:44 +01:00
2020-08-19 08:16:02 +02:00
2019-07-16 11:25:02 +02:00
2019-07-25 16:39:35 -04:00
2019-07-17 12:45:30 -04:00
2020-08-21 13:05:39 +02:00
2019-09-18 11:27:18 +02:00
2019-08-07 11:56:48 -04:00
2019-05-28 09:39:08 +02:00
2020-06-07 13:18:51 +02:00
2020-06-24 17:50:47 +02:00
2019-05-27 18:07:03 +02:00
2019-05-30 11:26:37 -07:00
2020-08-11 15:33:37 +02:00
2019-06-21 11:48:09 +02:00
2019-05-27 18:07:03 +02:00
2019-05-27 18:07:03 +02:00
2019-07-22 16:04:53 -04:00
2019-06-19 12:07:29 +02:00
2019-08-13 09:09:30 +02:00
2019-08-28 10:02:39 -05:00
2019-08-06 08:21:54 +02:00
2020-08-19 08:16:05 +02:00
2019-05-27 18:07:03 +02:00
2019-08-06 13:18:42 +05:30
2019-06-17 17:37:01 +02:00
2019-07-22 21:24:10 +02:00
2019-09-18 18:42:21 +02:00
2019-05-27 18:07:03 +02:00
2019-08-22 10:41:06 +03:00
2020-03-25 08:25:56 +01:00
2019-07-16 11:25:02 +02:00
2019-05-27 18:06:47 +02:00
2019-07-16 11:25:02 +02:00
2019-07-16 11:25:02 +02:00
2020-08-05 09:59:44 +02:00
2020-08-19 08:16:08 +02:00
2019-06-26 21:13:12 +01:00
2019-05-27 18:07:03 +02:00
2019-09-18 11:27:18 +02:00
2020-03-12 13:00:11 +01:00
2019-07-16 12:21:41 -07:00
2019-05-28 09:39:08 +02:00
2020-08-21 13:05:39 +02:00
2019-08-10 15:41:48 +02:00
2020-04-17 10:50:20 +02:00
2019-05-27 18:07:03 +02:00
2019-07-31 10:19:23 +02:00
2019-05-27 18:07:03 +02:00
2019-06-19 12:07:29 +02:00
2020-01-04 19:18:43 +01:00
2020-02-11 04:35:36 -08:00
2019-07-16 11:25:02 +02:00
2019-05-27 18:07:03 +02:00
2019-11-06 13:00:21 -05:00
2019-06-19 12:07:29 +02:00
2019-08-12 16:58:52 +02:00
2020-06-24 17:50:50 +02:00
2019-05-27 18:07:03 +02:00
2019-05-27 18:06:54 +02:00
2019-12-31 16:43:50 +01:00
2019-07-16 11:25:02 +02:00
2019-05-27 18:07:03 +02:00
2019-05-27 18:07:03 +02:00
2019-09-23 15:32:53 +08:00
2019-08-09 16:04:31 +10:00
2019-08-27 10:09:12 -05:00