From: "Christian König" <christian.koenig@amd.com>
To: Dan Carpenter <dan.carpenter@oracle.com>,
Alex Deucher <alexander.deucher@amd.com>,
Dave Airlie <airlied@redhat.com>
Cc: "Pan, Xinhui" <Xinhui.Pan@amd.com>,
David Airlie <airlied@linux.ie>, Daniel Vetter <daniel@ffwll.ch>,
Felix Kuehling <Felix.Kuehling@amd.com>,
amd-gfx@lists.freedesktop.org, dri-devel@lists.freedesktop.org,
kernel-janitors@vger.kernel.org
Subject: Re: [PATCH] drm/amdgpu: fix amdgpu_preempt_mgr_new()
Date: Fri, 18 Jun 2021 10:39:26 +0200 [thread overview]
Message-ID: <fadcee22-d830-c1be-09f0-9788b98c45ec@amd.com> (raw)
In-Reply-To: <YMxbQXg/Wqm0ACxt@mwanda>
Am 18.06.21 um 10:37 schrieb Dan Carpenter:
> There is a reversed if statement in amdgpu_preempt_mgr_new() so it
> always returns -ENOMEM.
>
> Fixes: 09b020bb05a5 ("Merge tag 'drm-misc-next-2021-06-09' of git://anongit.freedesktop.org/drm/drm-misc into drm-next")
> Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Most be some fallout from merging it with the TTM changes.
Anyway, patch is Reviewed-by: Christian König <christian.koenig@amd.com>
Thanks,
Christian.
> ---
> drivers/gpu/drm/amd/amdgpu/amdgpu_preempt_mgr.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_preempt_mgr.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_preempt_mgr.c
> index f6aff7ce5160..d02c8637f909 100644
> --- a/drivers/gpu/drm/amd/amdgpu/amdgpu_preempt_mgr.c
> +++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_preempt_mgr.c
> @@ -71,7 +71,7 @@ static int amdgpu_preempt_mgr_new(struct ttm_resource_manager *man,
> struct amdgpu_preempt_mgr *mgr = to_preempt_mgr(man);
>
> *res = kzalloc(sizeof(**res), GFP_KERNEL);
> - if (*res)
> + if (!*res)
> return -ENOMEM;
>
> ttm_resource_init(tbo, place, *res);
next prev parent reply other threads:[~2021-06-18 8:39 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-06-18 8:37 [PATCH] drm/amdgpu: fix amdgpu_preempt_mgr_new() Dan Carpenter
2021-06-18 8:39 ` Christian König [this message]
2021-06-18 15:40 ` Felix Kuehling
2021-06-18 21:18 ` Alex Deucher
2021-06-21 10:27 ` Christian König
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=fadcee22-d830-c1be-09f0-9788b98c45ec@amd.com \
--to=christian.koenig@amd.com \
--cc=Felix.Kuehling@amd.com \
--cc=Xinhui.Pan@amd.com \
--cc=airlied@linux.ie \
--cc=airlied@redhat.com \
--cc=alexander.deucher@amd.com \
--cc=amd-gfx@lists.freedesktop.org \
--cc=dan.carpenter@oracle.com \
--cc=daniel@ffwll.ch \
--cc=dri-devel@lists.freedesktop.org \
--cc=kernel-janitors@vger.kernel.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox