Displaying 5 results from an estimated 5 matches for "mas_walk".
2023 Mar 06
2
[PATCH drm-next v2 05/16] drm: manager to keep track of GPUs VA mappings
...gt; Passing through the iterater clearly seems to be the way to go.
>>
>> I assume that if the entry to insert isn't at the location of the iterator
>> (as in the following example) we can just keep walking to this location my
>> changing the index of the mas and calling mas_walk()?
>
> no. You have to mas_set() to the value and walk from the top of the
> tree. mas_walk() walks down, not from side to side - well, it does go
> forward within a node (increasing offset), but if you hit the node limit
> then you have gotten yourself in trouble.
>
>>...
2023 Feb 27
2
[PATCH drm-next v2 05/16] drm: manager to keep track of GPUs VA mappings
...gt;>> + }
>>>> +
>>>
>>> -----
>>>
>>>> + if (unlikely(drm_gpuva_find_first(mgr, addr, range)))
>>>> + return -EEXIST;
>>>> +
>>>> + ret = mas_store_gfp(&mas, va, GFP_KERNEL);
>>>
>>> mas_walk() will set the internal maple state to the limits to what it
>>> finds. So, instead of an iterator, you can use the walk function and
>>> ensure there is a large enough area in the existing NULL:
>>>
>>> /*
>>> * Nothing at addr, mas now points to th...
2023 Mar 06
0
[PATCH drm-next v2 05/16] drm: manager to keep track of GPUs VA mappings
...gt;>> + }
>>>> +
>>>
>>> -----
>>>
>>>> + if (unlikely(drm_gpuva_find_first(mgr, addr, range)))
>>>> + return -EEXIST;
>>>> +
>>>> + ret = mas_store_gfp(&mas, va, GFP_KERNEL);
>>>
>>> mas_walk() will set the internal maple state to the limits to what it
>>> finds. So, instead of an iterator, you can use the walk function and
>>> ensure there is a large enough area in the existing NULL:
>>>
>>> /*
>>> * Nothing at addr, mas now points to the...
2023 Mar 13
1
[PATCH drm-next v2 05/16] drm: manager to keep track of GPUs VA mappings
...clearly seems to be the way to go.
>>>>
>>>> I assume that if the entry to insert isn't at the location of the iterator
>>>> (as in the following example) we can just keep walking to this location my
>>>> changing the index of the mas and calling mas_walk()?
>>>
>>> no. You have to mas_set() to the value and walk from the top of the
>>> tree. mas_walk() walks down, not from side to side - well, it does go
>>> forward within a node (increasing offset), but if you hit the node limit
>>> then you have gott...
2023 Aug 20
3
[PATCH drm-misc-next 0/3] [RFC] DRM GPUVA Manager GPU-VM features
So far the DRM GPUVA manager offers common infrastructure to track GPU VA
allocations and mappings, generically connect GPU VA mappings to their
backing buffers and perform more complex mapping operations on the GPU VA
space.
However, there are more design patterns commonly used by drivers, which
can potentially be generalized in order to make the DRM GPUVA manager
represent a basic GPU-VM