linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: "Liu, Shaoyun" <Shaoyun.Liu@amd.com>
To: "Gustavo A. R. Silva" <gustavo@embeddedor.com>,
	"Deucher, Alexander" <Alexander.Deucher@amd.com>,
	"Cox, Philip" <Philip.Cox@amd.com>,
	Oded Gabbay <oded.gabbay@gmail.com>,
	"Koenig, Christian" <Christian.Koenig@amd.com>,
	"Zhou, David(ChunMing)" <David1.Zhou@amd.com>,
	David Airlie <airlied@linux.ie>, Daniel Vetter <daniel@ffwll.ch>
Cc: "amd-gfx@lists.freedesktop.org" <amd-gfx@lists.freedesktop.org>,
	"dri-devel@lists.freedesktop.org"
	<dri-devel@lists.freedesktop.org>,
	"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH] drm/amdkfd/kfd_mqd_manager_v10: Fix missing break in switch statement
Date: Mon, 22 Jul 2019 17:43:56 +0000	[thread overview]
Message-ID: <fd20d447-dde0-a24d-8d63-d846accb5cc9@amd.com> (raw)
In-Reply-To: <b1feb7e5-bd52-ef1b-b72e-b98b2c954b89@embeddedor.com>

That sounds good to me .

Regards

shaoyun.liu

On 2019-07-22 12:13 p.m., Gustavo A. R. Silva wrote:
>
> On 7/22/19 10:58 AM, Deucher, Alexander wrote:
>> We need to add a /*fall through */ comment then.
>>
> It might be better to remove the call to pr_debug() in KFD_MQD_TYPE_CP:
>
> 	case KFD_MQD_TYPE_CP:
>         	case KFD_MQD_TYPE_COMPUTE:
> 		pr_debug("%s@%i\n", __func__, __LINE__);
> 		mqd->allocate_mqd = allocate_mqd;
>
> Thanks
> --
> Gustavo
>
>
>> Alex
>> ________________________________
>> From: Liu, Shaoyun <Shaoyun.Liu@amd.com>
>> Sent: Monday, July 22, 2019 11:14 AM
>> To: Gustavo A. R. Silva <gustavo@embeddedor.com>; Cox, Philip <Philip.Cox@amd.com>; Oded Gabbay <oded.gabbay@gmail.com>; Deucher, Alexander <Alexander.Deucher@amd.com>; Koenig, Christian <Christian.Koenig@amd.com>; Zhou, David(ChunMing) <David1.Zhou@amd.com>; David Airlie <airlied@linux.ie>; Daniel Vetter <daniel@ffwll.ch>
>> Cc: amd-gfx@lists.freedesktop.org <amd-gfx@lists.freedesktop.org>; dri-devel@lists.freedesktop.org <dri-devel@lists.freedesktop.org>; linux-kernel@vger.kernel.org <linux-kernel@vger.kernel.org>
>> Subject: Re: [PATCH] drm/amdkfd/kfd_mqd_manager_v10: Fix missing break in switch statement
>>
>> This one properly in purpose , The mqd init for CP and  COMPUTE will
>> have the same  routine .
>>
>> Regard
>>
>> sshaoyun.liu
>>
>> On 2019-07-21 6:59 p.m., Gustavo A. R. Silva wrote:
>>> Add missing break statement in order to prevent the code from falling
>>> through to case KFD_MQD_TYPE_COMPUTE.
>>>
>>> This bug was found thanks to the ongoing efforts to enable
>>> -Wimplicit-fallthrough.
>>>
>>> Fixes: 14328aa58ce5 ("drm/amdkfd: Add navi10 support to amdkfd. (v3)")
>>> Cc: stable@vger.kernel.org
>>> Signed-off-by: Gustavo A. R. Silva <gustavo@embeddedor.com>
>>> ---
>>>    drivers/gpu/drm/amd/amdkfd/kfd_mqd_manager_v10.c | 1 +
>>>    1 file changed, 1 insertion(+)
>>>
>>> diff --git a/drivers/gpu/drm/amd/amdkfd/kfd_mqd_manager_v10.c b/drivers/gpu/drm/amd/amdkfd/kfd_mqd_manager_v10.c
>>> index 4f8a6ffc5775..1d8b13ad46f9 100644
>>> --- a/drivers/gpu/drm/amd/amdkfd/kfd_mqd_manager_v10.c
>>> +++ b/drivers/gpu/drm/amd/amdkfd/kfd_mqd_manager_v10.c
>>> @@ -430,6 +430,7 @@ struct mqd_manager *mqd_manager_init_v10(enum KFD_MQD_TYPE type,
>>>         switch (type) {
>>>         case KFD_MQD_TYPE_CP:
>>>                 pr_debug("%s@%i\n", __func__, __LINE__);
>>> +             break;
>>>         case KFD_MQD_TYPE_COMPUTE:
>>>                 pr_debug("%s@%i\n", __func__, __LINE__);
>>>                 mqd->allocate_mqd = allocate_mqd;

      reply	other threads:[~2019-07-22 17:44 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-07-21 22:59 [PATCH] drm/amdkfd/kfd_mqd_manager_v10: Fix missing break in switch statement Gustavo A. R. Silva
2019-07-22 15:14 ` Liu, Shaoyun
     [not found]   ` <BN6PR12MB18098741A081711936563597F7C40@BN6PR12MB1809.namprd12.prod.outlook.com>
2019-07-22 16:13     ` Gustavo A. R. Silva
2019-07-22 17:43       ` Liu, Shaoyun [this message]

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=fd20d447-dde0-a24d-8d63-d846accb5cc9@amd.com \
    --to=shaoyun.liu@amd.com \
    --cc=Alexander.Deucher@amd.com \
    --cc=Christian.Koenig@amd.com \
    --cc=David1.Zhou@amd.com \
    --cc=Philip.Cox@amd.com \
    --cc=airlied@linux.ie \
    --cc=amd-gfx@lists.freedesktop.org \
    --cc=daniel@ffwll.ch \
    --cc=dri-devel@lists.freedesktop.org \
    --cc=gustavo@embeddedor.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=oded.gabbay@gmail.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;
as well as URLs for NNTP newsgroup(s).