[PATCH 3/4] drm/amdgpu: add IOCTL interface for per VM BOs v2

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 30/08/17 04:34 PM, Christian König wrote:
> Am 30.08.2017 um 08:46 schrieb Michel Dänzer:
>> On 30/08/17 03:42 PM, Michel Dänzer wrote:
>>> On 30/08/17 03:09 PM, Christian König wrote:
>>>> Am 29.08.2017 um 19:20 schrieb Deucher, Alexander:
>>>>>> From: amd-gfx [mailto:amd-gfx-bounces at lists.freedesktop.org] On
>>>>>> Behalf
>>>>>> Of Christian König
>>>>>>
>>>>>> @@ -89,6 +89,8 @@ extern "C" {
>>>>>>    #define AMDGPU_GEM_CREATE_SHADOW        (1 << 4)
>>>>>>    /* Flag that allocating the BO should use linear VRAM */
>>>>>>    #define AMDGPU_GEM_CREATE_VRAM_CONTIGUOUS    (1 << 5)
>>>>>> +/* Flag that BO is local in the VM */
>>>>>> +#define AMDGPU_GEM_CREATE_LOCAL            (1 << 6)
>>>>> I'm not crazy about the name LOCAL.  Maybe something like
>>>>> ALWAYS_VALID?
>>>> Works for me as well. Dave any other opinion?
>>>>
>>>> If everybody is ok with ALWAYS_VALID I'm going to use that one.
>>> FWIW, I like LOCAL better than ALWAYS_VALID. The latter suggests that
>>> the BO is valid under any circumstances, whereas LOCAL indicates that it
>>> cannot be used outside of the GPUVM it was created in.
>>>
>>> I don't feel strongly about it though, feel free to go with either.
>> Another idea:
>>
>> /* The BO can only be used in the VM it was created in */
>> #define AMDGPU_GEM_CREATE_UNSHAREABLE            (1 << 6)
> 
> That in turn doesn't note that it is always available.
> 
> Additional to that I only limited sharing the BO because of the bad
> performance and memory usage. In theory we could share them pretty well.
> 
> How about VM_LOCAL ?

Hmm, well if such BOs might become shareable in the future, ALWAYS_VALID
might be best after all.


-- 
Earthling Michel Dänzer               |               http://www.amd.com
Libre software enthusiast             |             Mesa and X developer


[Index of Archives]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux