[Mesa-dev] [PATCH 14/19] gallium/r300/r600/radeonsi: handle query_renderer caps
Emil Velikov
emil.l.velikov at gmail.com
Fri Aug 15 02:24:00 PDT 2014
On 15/08/14 04:41, Alex Deucher wrote:
> On Thu, Aug 14, 2014 at 6:18 PM, Emil Velikov <emil.l.velikov at gmail.com> wrote:
>> Signed-off-by: Emil Velikov <emil.l.velikov at gmail.com>
>
> Might make sense to set PIPE_CAP_UMA for the the IGP chips and APUs.
> I guess it depends how applications use that info.
>
At first we need to get this out, in order for people to implement/use it :)
Whereas what is an isn't a UMA (mostly thinking about APUs here) - I feel
someone with better knowledge of the hardware needs to confirm with Ian, and
update the spec to make things a bit clearer :]
Emil
> Alex
>
>> ---
>> src/gallium/drivers/r300/r300_screen.c | 11 +++++++++++
>> src/gallium/drivers/r600/r600_pipe.c | 11 +++++++++++
>> src/gallium/drivers/radeonsi/si_pipe.c | 11 +++++++++++
>> 3 files changed, 33 insertions(+)
>>
>> diff --git a/src/gallium/drivers/r300/r300_screen.c b/src/gallium/drivers/r300/r300_screen.c
>> index 4e46f77..465547b 100644
>> --- a/src/gallium/drivers/r300/r300_screen.c
>> +++ b/src/gallium/drivers/r300/r300_screen.c
>> @@ -208,6 +208,17 @@ static int r300_get_param(struct pipe_screen* pscreen, enum pipe_cap param)
>>
>> case PIPE_CAP_MAX_VIEWPORTS:
>> return 1;
>> +
>> + case PIPE_CAP_VENDOR_ID:
>> + return 0x1002;
>> + case PIPE_CAP_DEVICE_ID:
>> + return r300screen->info.pci_id;
>> + case PIPE_CAP_ACCELERATED:
>> + return 1;
>> + case PIPE_CAP_VIDEO_MEMORY:
>> + return r300screen->info.vram_size >> 20;
>> + case PIPE_CAP_UMA:
>> + return 0;
>> }
>> return 0;
>> }
>> diff --git a/src/gallium/drivers/r600/r600_pipe.c b/src/gallium/drivers/r600/r600_pipe.c
>> index 20d9f95..4a1d4a7 100644
>> --- a/src/gallium/drivers/r600/r600_pipe.c
>> +++ b/src/gallium/drivers/r600/r600_pipe.c
>> @@ -379,6 +379,17 @@ static int r600_get_param(struct pipe_screen* pscreen, enum pipe_cap param)
>> return PIPE_QUIRK_TEXTURE_BORDER_COLOR_SWIZZLE_R600;
>> case PIPE_CAP_ENDIANNESS:
>> return PIPE_ENDIAN_LITTLE;
>> +
>> + case PIPE_CAP_VENDOR_ID:
>> + return 0x1002;
>> + case PIPE_CAP_DEVICE_ID:
>> + return rscreen->b.info.pci_id;
>> + case PIPE_CAP_ACCELERATED:
>> + return 1;
>> + case PIPE_CAP_VIDEO_MEMORY:
>> + return rscreen->b.info.vram_size >> 20;
>> + case PIPE_CAP_UMA:
>> + return 0;
>> }
>> return 0;
>> }
>> diff --git a/src/gallium/drivers/radeonsi/si_pipe.c b/src/gallium/drivers/radeonsi/si_pipe.c
>> index 879387f..4beccd7 100644
>> --- a/src/gallium/drivers/radeonsi/si_pipe.c
>> +++ b/src/gallium/drivers/radeonsi/si_pipe.c
>> @@ -309,6 +309,17 @@ static int si_get_param(struct pipe_screen* pscreen, enum pipe_cap param)
>>
>> case PIPE_CAP_ENDIANNESS:
>> return PIPE_ENDIAN_LITTLE;
>> +
>> + case PIPE_CAP_VENDOR_ID:
>> + return 0x1002;
>> + case PIPE_CAP_DEVICE_ID:
>> + return sscreen->b.info.pci_id;
>> + case PIPE_CAP_ACCELERATED:
>> + return 1;
>> + case PIPE_CAP_VIDEO_MEMORY:
>> + return sscreen->b.info.vram_size >> 20;
>> + case PIPE_CAP_UMA:
>> + return 0;
>> }
>> return 0;
>> }
>> --
>> 2.0.2
>>
>> _______________________________________________
>> mesa-dev mailing list
>> mesa-dev at lists.freedesktop.org
>> http://lists.freedesktop.org/mailman/listinfo/mesa-dev
More information about the mesa-dev
mailing list