From: Stanislaw Gruszka <stanislaw.gruszka@linux.intel.com>
To: Jeffrey Hugo <quic_jhugo@quicinc.com>
Cc: quic_carlv@quicinc.com, quic_pkanojiy@quicinc.com,
ogabbay@kernel.org, linux-arm-msm@vger.kernel.org,
dri-devel@lists.freedesktop.org
Subject: Re: [PATCH 6/7] accel/qaic: Create a function to initialize BO
Date: Sun, 17 Sep 2023 10:48:29 +0200 [thread overview]
Message-ID: <20230917084829.GA441281@linux.intel.com> (raw)
In-Reply-To: <20230901172247.11410-7-quic_jhugo@quicinc.com>
On Fri, Sep 01, 2023 at 11:22:46AM -0600, Jeffrey Hugo wrote:
> From: Pranjal Ramajor Asha Kanojiya <quic_pkanojiy@quicinc.com>
>
> This makes sure that we have a single place to initialize and
> re-initialize BO.
>
> Use this new API to cleanup release_dbc()
>
> We will need this for next patch to detach slicing to a BO.
>
> Signed-off-by: Pranjal Ramajor Asha Kanojiya <quic_pkanojiy@quicinc.com>
> Reviewed-by: Jeffrey Hugo <quic_jhugo@quicinc.com>
> Signed-off-by: Jeffrey Hugo <quic_jhugo@quicinc.com>
> ---
> drivers/accel/qaic/qaic_data.c | 20 ++++++++++++++------
> 1 file changed, 14 insertions(+), 6 deletions(-)
>
> diff --git a/drivers/accel/qaic/qaic_data.c b/drivers/accel/qaic/qaic_data.c
> index 6e44e00937af..2acb9dbac88b 100644
> --- a/drivers/accel/qaic/qaic_data.c
> +++ b/drivers/accel/qaic/qaic_data.c
> @@ -635,6 +635,18 @@ static const struct drm_gem_object_funcs qaic_gem_funcs = {
> .vm_ops = &drm_vm_ops,
> };
>
> +static void qaic_init_bo(struct qaic_bo *bo, bool reinit)
> +{
> + if (reinit) {
> + bo->sliced = false;
> + reinit_completion(&bo->xfer_done);
> + } else {
> + init_completion(&bo->xfer_done);
> + }
> + complete_all(&bo->xfer_done);
Why do you need complete_all() here ?
Regards
Stanislaw
WARNING: multiple messages have this Message-ID (diff)
From: Stanislaw Gruszka <stanislaw.gruszka@linux.intel.com>
To: Jeffrey Hugo <quic_jhugo@quicinc.com>
Cc: quic_pkanojiy@quicinc.com, linux-arm-msm@vger.kernel.org,
quic_carlv@quicinc.com, ogabbay@kernel.org,
dri-devel@lists.freedesktop.org
Subject: Re: [PATCH 6/7] accel/qaic: Create a function to initialize BO
Date: Sun, 17 Sep 2023 10:48:29 +0200 [thread overview]
Message-ID: <20230917084829.GA441281@linux.intel.com> (raw)
In-Reply-To: <20230901172247.11410-7-quic_jhugo@quicinc.com>
On Fri, Sep 01, 2023 at 11:22:46AM -0600, Jeffrey Hugo wrote:
> From: Pranjal Ramajor Asha Kanojiya <quic_pkanojiy@quicinc.com>
>
> This makes sure that we have a single place to initialize and
> re-initialize BO.
>
> Use this new API to cleanup release_dbc()
>
> We will need this for next patch to detach slicing to a BO.
>
> Signed-off-by: Pranjal Ramajor Asha Kanojiya <quic_pkanojiy@quicinc.com>
> Reviewed-by: Jeffrey Hugo <quic_jhugo@quicinc.com>
> Signed-off-by: Jeffrey Hugo <quic_jhugo@quicinc.com>
> ---
> drivers/accel/qaic/qaic_data.c | 20 ++++++++++++++------
> 1 file changed, 14 insertions(+), 6 deletions(-)
>
> diff --git a/drivers/accel/qaic/qaic_data.c b/drivers/accel/qaic/qaic_data.c
> index 6e44e00937af..2acb9dbac88b 100644
> --- a/drivers/accel/qaic/qaic_data.c
> +++ b/drivers/accel/qaic/qaic_data.c
> @@ -635,6 +635,18 @@ static const struct drm_gem_object_funcs qaic_gem_funcs = {
> .vm_ops = &drm_vm_ops,
> };
>
> +static void qaic_init_bo(struct qaic_bo *bo, bool reinit)
> +{
> + if (reinit) {
> + bo->sliced = false;
> + reinit_completion(&bo->xfer_done);
> + } else {
> + init_completion(&bo->xfer_done);
> + }
> + complete_all(&bo->xfer_done);
Why do you need complete_all() here ?
Regards
Stanislaw
next prev parent reply other threads:[~2023-09-17 8:49 UTC|newest]
Thread overview: 30+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-09-01 17:22 [PATCH 0/7] accel/qaic: Extend uAPI to support undoing ATTACH_SLICE_BO Jeffrey Hugo
2023-09-01 17:22 ` Jeffrey Hugo
2023-09-01 17:22 ` [PATCH 1/7] accel/qaic: Remove ->size field from struct qaic_bo Jeffrey Hugo
2023-09-01 17:22 ` Jeffrey Hugo
2023-09-01 17:22 ` [PATCH 2/7] accel/qaic: Update BO metadata in a central location Jeffrey Hugo
2023-09-01 17:22 ` Jeffrey Hugo
2023-09-01 17:22 ` [PATCH 3/7] accel/qaic: Declare BO 'sliced' after all the operations are complete Jeffrey Hugo
2023-09-01 17:22 ` Jeffrey Hugo
2023-09-01 17:22 ` [PATCH 4/7] accel/qaic: Undo slicing setup done in qaic_attach_slicing_bo() Jeffrey Hugo
2023-09-01 17:22 ` Jeffrey Hugo
2023-09-01 17:22 ` [PATCH 5/7] accel/qaic: Clean up BO during flushing of transfer list Jeffrey Hugo
2023-09-01 17:22 ` Jeffrey Hugo
2023-09-01 17:22 ` [PATCH 6/7] accel/qaic: Create a function to initialize BO Jeffrey Hugo
2023-09-01 17:22 ` Jeffrey Hugo
2023-09-17 8:48 ` Stanislaw Gruszka [this message]
2023-09-17 8:48 ` Stanislaw Gruszka
2023-09-22 14:59 ` Jeffrey Hugo
2023-09-22 14:59 ` Jeffrey Hugo
2023-09-01 17:22 ` [PATCH 7/7] accel/qaic: Add QAIC_DETACH_SLICE_BO IOCTL Jeffrey Hugo
2023-09-01 17:22 ` Jeffrey Hugo
2023-09-17 8:56 ` Stanislaw Gruszka
2023-09-17 8:56 ` Stanislaw Gruszka
2023-09-22 15:16 ` Jeffrey Hugo
2023-09-22 15:16 ` Jeffrey Hugo
2023-09-17 8:58 ` [PATCH 0/7] accel/qaic: Extend uAPI to support undoing ATTACH_SLICE_BO Stanislaw Gruszka
2023-09-17 8:58 ` Stanislaw Gruszka
2023-09-22 15:17 ` Jeffrey Hugo
2023-09-22 15:17 ` Jeffrey Hugo
2023-09-22 16:04 ` Jeffrey Hugo
2023-09-22 16:04 ` Jeffrey Hugo
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=20230917084829.GA441281@linux.intel.com \
--to=stanislaw.gruszka@linux.intel.com \
--cc=dri-devel@lists.freedesktop.org \
--cc=linux-arm-msm@vger.kernel.org \
--cc=ogabbay@kernel.org \
--cc=quic_carlv@quicinc.com \
--cc=quic_jhugo@quicinc.com \
--cc=quic_pkanojiy@quicinc.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 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.