lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <MN2PR12MB33099BF7946484E6AE1F75F5EC090@MN2PR12MB3309.namprd12.prod.outlook.com>
Date:   Wed, 15 May 2019 09:53:33 +0000
From:   "Huang, Ray" <Ray.Huang@....com>
To:     Dan Carpenter <dan.carpenter@...cle.com>,
        "Deucher, Alexander" <Alexander.Deucher@....com>,
        "Wang, Kevin(Yang)" <Kevin1.Wang@....com>
CC:     "Koenig, Christian" <Christian.Koenig@....com>,
        "Zhou, David(ChunMing)" <David1.Zhou@....com>,
        David Airlie <airlied@...ux.ie>,
        Daniel Vetter <daniel@...ll.ch>,
        "Gao, Likun" <Likun.Gao@....com>, "Gui, Jack" <Jack.Gui@....com>,
        "amd-gfx@...ts.freedesktop.org" <amd-gfx@...ts.freedesktop.org>,
        "dri-devel@...ts.freedesktop.org" <dri-devel@...ts.freedesktop.org>,
        "linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
        "kernel-janitors@...r.kernel.org" <kernel-janitors@...r.kernel.org>
Subject: RE: [PATCH] drm/amd/powerplay: fix locking in
 smu_feature_set_supported()

> -----Original Message-----
> From: Dan Carpenter <dan.carpenter@...cle.com>
> Sent: Wednesday, May 15, 2019 5:52 PM
> To: Deucher, Alexander <Alexander.Deucher@....com>; Wang, Kevin(Yang)
> <Kevin1.Wang@....com>
> Cc: Koenig, Christian <Christian.Koenig@....com>; Zhou, David(ChunMing)
> <David1.Zhou@....com>; David Airlie <airlied@...ux.ie>; Daniel Vetter
> <daniel@...ll.ch>; Huang, Ray <Ray.Huang@....com>; Gao, Likun
> <Likun.Gao@....com>; Gui, Jack <Jack.Gui@....com>; amd-
> gfx@...ts.freedesktop.org; dri-devel@...ts.freedesktop.org; linux-
> kernel@...r.kernel.org; kernel-janitors@...r.kernel.org
> Subject: [PATCH] drm/amd/powerplay: fix locking in
> smu_feature_set_supported()
> 
> There is a typo so the code unlocks twice instead of taking the lock and then
> releasing it.
> 
> Fixes: f14a323db5b0 ("drm/amd/powerplay: implement update enabled
> feature state to smc for smu11")
> Signed-off-by: Dan Carpenter <dan.carpenter@...cle.com>
> 

Thanks!
Reviewed-by: Huang Rui <ray.huang@....com>

Will apply it.

---
>  drivers/gpu/drm/amd/powerplay/amdgpu_smu.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/drivers/gpu/drm/amd/powerplay/amdgpu_smu.c
> b/drivers/gpu/drm/amd/powerplay/amdgpu_smu.c
> index 52d919a8b70a..85ac29af5363 100644
> --- a/drivers/gpu/drm/amd/powerplay/amdgpu_smu.c
> +++ b/drivers/gpu/drm/amd/powerplay/amdgpu_smu.c
> @@ -310,7 +310,7 @@ int smu_feature_set_supported(struct smu_context
> *smu, int feature_id,
> 
>         WARN_ON(feature_id > feature->feature_num);
> 
> -       mutex_unlock(&feature->mutex);
> +       mutex_lock(&feature->mutex);
>         if (enable)
>                 test_and_set_bit(feature_id, feature->supported);
>         else
> --
> 2.20.1

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ