Re: [PATCH] drm/ttm: fix error handling in ttm_bo_handle_move_mem()

2021-06-17 Thread Daniel Vetter
On Thu, Jun 17, 2021 at 09:41:35AM +0200, Christian König wrote: > > > Am 16.06.21 um 21:19 schrieb Dan Carpenter: > > On Wed, Jun 16, 2021 at 01:00:38PM +0200, Christian König wrote: > > > > > > Am 16.06.21 um 11:36 schrieb Dan Carpenter: > > > > On Wed, Jun 16, 2021 at 10:47:14AM +0200, Christ

Re: [PATCH] drm/ttm: fix error handling in ttm_bo_handle_move_mem()

2021-06-17 Thread Christian König
Am 16.06.21 um 21:19 schrieb Dan Carpenter: On Wed, Jun 16, 2021 at 01:00:38PM +0200, Christian König wrote: Am 16.06.21 um 11:36 schrieb Dan Carpenter: On Wed, Jun 16, 2021 at 10:47:14AM +0200, Christian König wrote: Am 16.06.21 um 10:37 schrieb Dan Carpenter: On Wed, Jun 16, 2021 at 08:

Re: [PATCH] drm/ttm: fix error handling in ttm_bo_handle_move_mem()

2021-06-16 Thread Dan Carpenter
On Wed, Jun 16, 2021 at 01:00:38PM +0200, Christian König wrote: > > > Am 16.06.21 um 11:36 schrieb Dan Carpenter: > > On Wed, Jun 16, 2021 at 10:47:14AM +0200, Christian König wrote: > > > > > > Am 16.06.21 um 10:37 schrieb Dan Carpenter: > > > > On Wed, Jun 16, 2021 at 08:46:33AM +0200, Christ

Re: [PATCH] drm/ttm: fix error handling in ttm_bo_handle_move_mem()

2021-06-16 Thread Christian König
Am 16.06.21 um 11:36 schrieb Dan Carpenter: On Wed, Jun 16, 2021 at 10:47:14AM +0200, Christian König wrote: Am 16.06.21 um 10:37 schrieb Dan Carpenter: On Wed, Jun 16, 2021 at 08:46:33AM +0200, Christian König wrote: Sending the first message didn't worked, so let's try again. Am 16.06.2

Re: [PATCH] drm/ttm: fix error handling in ttm_bo_handle_move_mem()

2021-06-16 Thread Dan Carpenter
On Wed, Jun 16, 2021 at 10:47:14AM +0200, Christian König wrote: > > > Am 16.06.21 um 10:37 schrieb Dan Carpenter: > > On Wed, Jun 16, 2021 at 08:46:33AM +0200, Christian König wrote: > > > Sending the first message didn't worked, so let's try again. > > > > > > Am 16.06.21 um 08:30 schrieb Dan

Re: [PATCH] drm/ttm: fix error handling in ttm_bo_handle_move_mem()

2021-06-16 Thread Christian König
Am 16.06.21 um 10:37 schrieb Dan Carpenter: On Wed, Jun 16, 2021 at 08:46:33AM +0200, Christian König wrote: Sending the first message didn't worked, so let's try again. Am 16.06.21 um 08:30 schrieb Dan Carpenter: There are three bugs here: 1) We need to call unpopulate() if ttm_tt_populate

Re: [PATCH] drm/ttm: fix error handling in ttm_bo_handle_move_mem()

2021-06-16 Thread Dan Carpenter
On Wed, Jun 16, 2021 at 08:46:33AM +0200, Christian König wrote: > Sending the first message didn't worked, so let's try again. > > Am 16.06.21 um 08:30 schrieb Dan Carpenter: > > There are three bugs here: > > 1) We need to call unpopulate() if ttm_tt_populate() succeeds. > > 2) The "new_man = tt

Re: [PATCH] drm/ttm: fix error handling in ttm_bo_handle_move_mem()

2021-06-15 Thread Christian König
Sending the first message didn't worked, so let's try again. Am 16.06.21 um 08:30 schrieb Dan Carpenter: There are three bugs here: 1) We need to call unpopulate() if ttm_tt_populate() succeeds. 2) The "new_man = ttm_manager_type(bdev, bo->mem.mem_type);" assignment was wrong and it was real

[PATCH] drm/ttm: fix error handling in ttm_bo_handle_move_mem()

2021-06-15 Thread Dan Carpenter
There are three bugs here: 1) We need to call unpopulate() if ttm_tt_populate() succeeds. 2) The "new_man = ttm_manager_type(bdev, bo->mem.mem_type);" assignment was wrong and it was really assigning "new_mem = old_mem;". There is no need for this assignment anyway as we already have the val