[Intel-gfx] drm-tip compile break
Christian König
christian.koenig at amd.com
Thu Mar 31 08:20:58 UTC 2022
Am 31.03.22 um 10:15 schrieb Lucas De Marchi:
> On Thu, Mar 31, 2022 at 09:35:50AM +0200, Christian König wrote:
>> Well the fix is trivial, but somehow rebuilding drm-tip always fails
>> for me while merging drm-intel-next.
>>
>> I probably have somehow messed up reverting the conflict resolution.
>> Ideas?
>
> It looks like the error is in the wrong conflict resolution in
> 629041de3a0c M─┐ Merge remote-tracking branch 'drm-misc/drm-misc-next'
> into drm-tip
> you'd need to redo the merge (-i) after telling git
> rerere to forget the previous conflict resolution.
>
> https://nam11.safelinks.protection.outlook.com/?url=https%3A%2F%2Fdrm.pages.freedesktop.org%2Fmaintainer-tools%2Fdrm-tip.html%23removing-a-wrong-conflict-resolution&data=04%7C01%7Cchristian.koenig%40amd.com%7C7b9d9727a7314f7a9a8d08da12ee9ee2%7C3dd8961fe4884e608e11a82d994e183d%7C0%7C0%7C637843113330258383%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C3000&sdata=y5KjOfpLsu%2B42zDUZmKlkOFNHiAsjHfNPNMEVeZ9wLI%3D&reserved=0
>
>
> it's also useful to use dim -i, to make sure we can build on each merge
> afterwards.
>
> AFAICS the revert would be on 141577c6d0bd ("2022y-03m-29d-09h-01m-04s
> UTC: drm-tip rerere cache update")
>
> taking a stab on it, should be like below. It even builds,
> but I have no confidence to commit it.
Please go ahead with that, it looks correct to me.
I somehow messed up my installation so badly that even a "drm
rebuild-tip" doesn't work any more and fails to merge drm-intel-next
with a conflict which seems to already be resolved.
And when I try to resolve it once more drm-tip says only "Preimage für
'drivers/gpu/drm/i915/intel_pm.c' aufgezeichnet." and doesn't seem to
remember the conflict resolution.
Any advise how I can fix this?
Thanks,
Christian.
>
> Lucas De Marchi
>
> -------
> diff --cc drivers/gpu/drm/amd/amdgpu/amdgpu_gtt_mgr.c
> index dd78402e3cb0,68494b959116..000000000000
> --- a/drivers/gpu/drm/amd/amdgpu/amdgpu_gtt_mgr.c
> +++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_gtt_mgr.c
> @@@ -200,17 -187,20 +187,17 @@@ static void amdgpu_gtt_mgr_del(struct t
> *
> * Re-init the gart for each known BO in the GTT.
> */
> -int amdgpu_gtt_mgr_recover(struct amdgpu_gtt_mgr *mgr)
> +void amdgpu_gtt_mgr_recover(struct amdgpu_gtt_mgr *mgr)
> {
> - struct amdgpu_gtt_node *node;
> + struct ttm_range_mgr_node *node;
> struct drm_mm_node *mm_node;
> struct amdgpu_device *adev;
> - int r = 0;
> adev = container_of(mgr, typeof(*adev), mman.gtt_mgr);
> spin_lock(&mgr->lock);
> drm_mm_for_each_node(mm_node, &mgr->mm) {
> - node = container_of(mm_node, typeof(*node), base.mm_nodes[0]);
> - amdgpu_ttm_recover_gart(node->tbo);
> + node = container_of(mm_node, typeof(*node), mm_nodes[0]);
> - r = amdgpu_ttm_recover_gart(node->base.bo);
> - if (r)
> - break;
> ++ amdgpu_ttm_recover_gart(node->base.bo);
> }
> spin_unlock(&mgr->lock);
> diff --cc drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c
> index fc4563cf2828,28f5e8b21a99..000000000000
> --- a/drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c
> +++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c
> @@@ -375,9 -375,7 +375,9 @@@ static void amdgpu_vm_bo_base_init(stru
> if (bo->tbo.base.resv != vm->root.bo->tbo.base.resv)
> return;
> + dma_resv_assert_held(vm->root.bo->tbo.base.resv);
> +
> - vm->bulk_moveable = false;
> + ttm_bo_set_bulk_move(&bo->tbo, &vm->lru_bulk_move);
> if (bo->tbo.type == ttm_bo_type_kernel && bo->parent)
> amdgpu_vm_bo_relocated(base);
> else
> @@@ -2660,12 -2597,9 +2606,12 @@@ void amdgpu_vm_bo_del(struct amdgpu_dev
> struct amdgpu_vm *vm = bo_va->base.vm;
> struct amdgpu_vm_bo_base **base;
> + dma_resv_assert_held(vm->root.bo->tbo.base.resv);
> +
> if (bo) {
> + dma_resv_assert_held(bo->tbo.base.resv);
> if (bo->tbo.base.resv == vm->root.bo->tbo.base.resv)
> - vm->bulk_moveable = false;
> + ttm_bo_set_bulk_move(&bo->tbo, NULL);
> for (base = &bo_va->base.bo->vm_bo; *base;
> base = &(*base)->next) {
>
>
>>
>> Christian.
>>
>> Am 31.03.22 um 08:28 schrieb Christian König:
>>> I'm going to take a look, but need to figure out how to find the
>>> broken merge
>>>
>>> Christian.
>>>
>>> Am 31.03.22 um 00:33 schrieb Dixit, Ashutosh:
>>>> Is anyone looking into fixing this:
>>>>
>>>> drivers/gpu/drm/amd/amdgpu/amdgpu_gtt_mgr.c: In function
>>>> ‘amdgpu_gtt_mgr_recover’:
>>>> drivers/gpu/drm/amd/amdgpu/amdgpu_gtt_mgr.c:200:31: error: ‘struct
>>>> ttm_range_mgr_node’ has no member named ‘tbo’
>>>> amdgpu_ttm_recover_gart(node->tbo);
>>>> ^~
>>>> make[4]: *** [scripts/Makefile.build:288:
>>>> drivers/gpu/drm/amd/amdgpu/amdgpu_gtt_mgr.o] Error 1
>>>>
>>>> Thanks.
>>>
>>
More information about the Intel-gfx
mailing list