All of lore.kernel.org
 help / color / mirror / Atom feed
From: "Christian König" <deathsimple@vodafone.de>
To: Alex Deucher <alexdeucher@gmail.com>
Cc: Maling list - DRI developers <dri-devel@lists.freedesktop.org>
Subject: Re: [PATCH 3/3] drm/radeon: optimize CIK VM handling
Date: Tue, 27 May 2014 19:36:06 +0200	[thread overview]
Message-ID: <5384CD06.8010005@vodafone.de> (raw)
In-Reply-To: <CADnq5_Nd2QdJjCNTY5psp0J0Qjg+himKmA5W09SaKJE65Wcg4Q@mail.gmail.com>

Am 27.05.2014 17:44, schrieb Alex Deucher:
> On Tue, May 27, 2014 at 10:47 AM, Christian König
> <deathsimple@vodafone.de> wrote:
>> From: Christian König <christian.koenig@amd.com>
>>
>> Fill VM page tables from the GART page table if applicable.
>>
>> Signed-off-by: Christian König <christian.koenig@amd.com>
>> ---
>>   drivers/gpu/drm/radeon/cik_sdma.c | 21 ++++++++++++++++++++-
>>   1 file changed, 20 insertions(+), 1 deletion(-)
>>
>> diff --git a/drivers/gpu/drm/radeon/cik_sdma.c b/drivers/gpu/drm/radeon/cik_sdma.c
>> index f7e46cf..5bd3fe8 100644
>> --- a/drivers/gpu/drm/radeon/cik_sdma.c
>> +++ b/drivers/gpu/drm/radeon/cik_sdma.c
>> @@ -741,7 +741,26 @@ void cik_sdma_vm_set_page(struct radeon_device *rdev,
>>
>>          trace_radeon_vm_set_page(pe, addr, count, incr, flags);
>>
>> -       if (flags & R600_PTE_SYSTEM) {
>> +       if (flags == R600_PTE_GART) {
>> +               uint64_t src = rdev->gart.table_addr + (addr >> 12) * 8;
>> +               while (count) {
>> +                       unsigned bytes = count * 8;
>> +                       if (bytes > 0x1FFFF8)
>> +                               bytes = 0x1FFFF8;
>> +
>> +                       ib->ptr[ib->length_dw++] = SDMA_PACKET(SDMA_OPCODE_WRITE, SDMA_WRITE_SUB_OPCODE_LINEAR, 0);
>
> Copy paste typo?  This should be SDMA_OPCODE_COPY, SDMA_COPY_SUB_OPCODE_LINEAR.

Oh, yes indeed. Thanks for the info.

Going to resend this patch in a minute. Can you add them to your 
3.16-wip branch?

Thanks,
Christian.

>
> With that fixed, this patch is:
>
> Reviewed-by: Alex Deucher <alexander.deucher@amd.com>
>
>> +                       ib->ptr[ib->length_dw++] = bytes;
>> +                       ib->ptr[ib->length_dw++] = 0; /* src/dst endian swap */
>> +                       ib->ptr[ib->length_dw++] = src & 0xffffffff;
>> +                       ib->ptr[ib->length_dw++] = upper_32_bits(src);
>> +                       ib->ptr[ib->length_dw++] = pe & 0xffffffff;
>> +                       ib->ptr[ib->length_dw++] = upper_32_bits(pe);
>> +
>> +                       pe += bytes;
>> +                       src += bytes;
>> +                       count -= bytes / 8;
>> +               }
>> +       } else if (flags & R600_PTE_SYSTEM) {
>>                  while (count) {
>>                          ndw = count * 2;
>>                          if (ndw > 0xFFFFE)
>> --
>> 1.9.1
>>
>> _______________________________________________
>> dri-devel mailing list
>> dri-devel@lists.freedesktop.org
>> http://lists.freedesktop.org/mailman/listinfo/dri-devel

_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/dri-devel

  reply	other threads:[~2014-05-27 17:36 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-05-27 14:47 [PATCH 1/3] drm/radeon: add define for flags used in R600+ GTT Christian König
2014-05-27 14:47 ` [PATCH 2/3] drm/radeon: optimize SI VM handling Christian König
2014-05-27 15:45   ` Alex Deucher
2014-05-27 14:47 ` [PATCH 3/3] drm/radeon: optimize CIK " Christian König
2014-05-27 15:44   ` Alex Deucher
2014-05-27 17:36     ` Christian König [this message]
2014-05-27 18:07       ` Alex Deucher
2014-05-27 15:44 ` [PATCH 1/3] drm/radeon: add define for flags used in R600+ GTT Alex Deucher

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=5384CD06.8010005@vodafone.de \
    --to=deathsimple@vodafone.de \
    --cc=alexdeucher@gmail.com \
    --cc=dri-devel@lists.freedesktop.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.