Intel-XE Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: "Summers, Stuart" <stuart.summers@intel.com>
To: "Brost, Matthew" <matthew.brost@intel.com>
Cc: "intel-xe@lists.freedesktop.org" <intel-xe@lists.freedesktop.org>,
	"Harrison, John C" <john.c.harrison@intel.com>,
	"Vivi, Rodrigo" <rodrigo.vivi@intel.com>,
	"Welty, Brian" <brian.welty@intel.com>
Subject: Re: [PATCH 3/3] drm/xe/guc: Bump the G2H queue size to account for page faults
Date: Tue, 23 Jul 2024 14:13:45 +0000	[thread overview]
Message-ID: <06a1ad55a644fb1f0f77b3ec3a4bc7683234521f.camel@intel.com> (raw)
In-Reply-To: <Zpr903XK3nsmzlrM@DUT025-TGLU.fm.intel.com>

On Fri, 2024-07-19 at 23:59 +0000, Matthew Brost wrote:
> On Fri, Jul 19, 2024 at 07:06:14PM +0000, Stuart Summers wrote:
> > With the increase in the size of the recoverable page fault
> > queue, we want to ensure the initial messages from GuC in
> > the G2H buffer have space while we transfer those out to the
> > actual pf_queue. Bump the G2H queue size to account for this
> > increase in the pf_queue size.
> > 
> 
> For future reference, include change log to help reviewers.

Sure makes sense. I had included the change log in the cover letter but
decided not to include here. I'll do that in the future.

> 
> Reviewed-by: Matthew Brost <matthew.brost@intel.com>

Thanks for the reviews Matt!

> 
> > Signed-off-by: Stuart Summers <stuart.summers@intel.com>
> > ---
> >  drivers/gpu/drm/xe/xe_guc_ct.c | 12 ++++++++++--
> >  1 file changed, 10 insertions(+), 2 deletions(-)
> > 
> > diff --git a/drivers/gpu/drm/xe/xe_guc_ct.c
> > b/drivers/gpu/drm/xe/xe_guc_ct.c
> > index 7d2e937da1d8..a3e9dd71f957 100644
> > --- a/drivers/gpu/drm/xe/xe_guc_ct.c
> > +++ b/drivers/gpu/drm/xe/xe_guc_ct.c
> > @@ -105,12 +105,20 @@ ct_to_xe(struct xe_guc_ct *ct)
> >   * enough space to avoid backpressure on the driver. We increase
> > the size
> >   * of the receive buffer (relative to the send) to ensure a G2H
> > response
> >   * CTB has a landing spot.
> > + *
> > + * In addition to submissions, the G2H buffer needs to be able to
> > hold
> > + * enough space for recoverable page fault notifications. The
> > number of
> > + * page faults is interrupt driven and can be as much as the
> > number of
> > + * compute resources available. However, most of the actual work
> > for these
> > + * is in a separate page fault worker thread. Therefore we only
> > need to
> > + * make sure the queue has enough space to handle all of the
> > submissions
> > + * and responses and an extra buffer for incoming page faults.
> >   */
> >  
> >  #define CTB_DESC_SIZE          ALIGN(sizeof(struct
> > guc_ct_buffer_desc), SZ_2K)
> >  #define CTB_H2G_BUFFER_SIZE    (SZ_4K)
> > -#define CTB_G2H_BUFFER_SIZE    (4 * CTB_H2G_BUFFER_SIZE)
> > -#define G2H_ROOM_BUFFER_SIZE   (CTB_G2H_BUFFER_SIZE / 4)
> > +#define CTB_G2H_BUFFER_SIZE    (SZ_128K)
> > +#define G2H_ROOM_BUFFER_SIZE   (CTB_G2H_BUFFER_SIZE / 2)
> >  
> >  /**
> >   * xe_guc_ct_queue_proc_time_jiffies - Return maximum time to
> > process a full
> > -- 
> > 2.34.1
> > 


  reply	other threads:[~2024-07-23 14:13 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-07-19 19:06 [PATCH 0/3] Update page fault queue size calculation Stuart Summers
2024-07-19 19:06 ` [PATCH 1/3] drm/xe: Fix missing workqueue destroy in xe_gt_pagefault Stuart Summers
2024-07-19 19:06 ` [PATCH 2/3] drm/xe: Use topology to determine page fault queue size Stuart Summers
2024-07-19 19:06 ` [PATCH 3/3] drm/xe/guc: Bump the G2H queue size to account for page faults Stuart Summers
2024-07-19 23:59   ` Matthew Brost
2024-07-23 14:13     ` Summers, Stuart [this message]
2024-07-19 19:11 ` ✓ CI.Patch_applied: success for Update page fault queue size calculation (rev4) Patchwork
2024-07-19 19:12 ` ✓ CI.checkpatch: " Patchwork
2024-07-19 19:12 ` ✗ CI.KUnit: failure " Patchwork
  -- strict thread matches above, loose matches on Subject: below --
2024-07-19 17:58 [PATCH 0/3] Update page fault queue size calculation Stuart Summers
2024-07-19 17:58 ` [PATCH 3/3] drm/xe/guc: Bump the G2H queue size to account for page faults Stuart Summers
2024-07-19 18:10   ` Matthew Brost
2024-07-19 19:00     ` Summers, Stuart

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=06a1ad55a644fb1f0f77b3ec3a4bc7683234521f.camel@intel.com \
    --to=stuart.summers@intel.com \
    --cc=brian.welty@intel.com \
    --cc=intel-xe@lists.freedesktop.org \
    --cc=john.c.harrison@intel.com \
    --cc=matthew.brost@intel.com \
    --cc=rodrigo.vivi@intel.com \
    /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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox