linux-arm-kernel.lists.infradead.org archive mirror
 help / color / mirror / Atom feed
From: Wei Xu <xuwei5@hisilicon.com>
To: Huisong Li <lihuisong@huawei.com>
Cc: <linux-kernel@vger.kernel.org>, <soc@kernel.org>,
	<linux-arm-kernel@lists.infradead.org>,
	<Jonathan.Cameron@Huawei.com>, <liuyonglong@huawei.com>,
	<xuwei5@hisilicon.com>
Subject: Re: [PATCH 1/2] soc: hisilicon: kunpeng_hccs: Add the check for obtaining complete port attribute
Date: Mon, 15 Apr 2024 09:17:11 +0800	[thread overview]
Message-ID: <661C8017.1070203@hisilicon.com> (raw)
In-Reply-To: <20240403081935.24308-2-lihuisong@huawei.com>

Hi Huisong,

On 2024/4/3 16:19, Huisong Li wrote:
> The hccs_get_all_port_attr() is used to obtained the attribute of all
> ports on a specified DIE from firmware. However, this interface doesn't
> ensure whether firmware reports the complete attribute of all ports or not.
> So this patch adds the check for this.
> 
> Signed-off-by: Huisong Li <lihuisong@huawei.com>
> ---
>  drivers/soc/hisilicon/kunpeng_hccs.c | 6 ++++++
>  1 file changed, 6 insertions(+)
> 
> diff --git a/drivers/soc/hisilicon/kunpeng_hccs.c b/drivers/soc/hisilicon/kunpeng_hccs.c
> index 9ff70b38e5e9..bb69a95b5f2d 100644
> --- a/drivers/soc/hisilicon/kunpeng_hccs.c
> +++ b/drivers/soc/hisilicon/kunpeng_hccs.c
> @@ -556,6 +556,12 @@ static int hccs_get_all_port_attr(struct hccs_dev *hdev,
>  		start_id = rsp_head.next_id;
>  	}
>  
> +	if (left_buf_len != 0) {
> +		dev_err(hdev->dev, "do not get the expected port number(%u) attribute.\n",

How about changing to "failed to get the expected port number(%u) attribute.\n"?

Best Regards,
Wei

> +			size);
> +		return -EINVAL;
> +	}
> +
>  	return 0;
>  }
>  
> 

_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

  reply	other threads:[~2024-04-15  1:17 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-04-03  8:19 [PATCH 0/2] soc: hisilicon: kunpeng_hccs: add dependency and enhance verification Huisong Li
2024-04-03  8:19 ` [PATCH 1/2] soc: hisilicon: kunpeng_hccs: Add the check for obtaining complete port attribute Huisong Li
2024-04-15  1:17   ` Wei Xu [this message]
2024-04-16  1:17     ` lihuisong (C)
2024-04-03  8:19 ` [PATCH 2/2] soc: hisilicon: kunpeng_hccs: replace MAILBOX dependency with PCC Huisong Li
2024-04-17  9:47 ` [PATCH v2 0/2] soc: hisilicon: kunpeng_hccs: add dependency and enhance verification Huisong Li
2024-04-17  9:48   ` [PATCH v2 1/2] soc: hisilicon: kunpeng_hccs: Add the check for obtaining complete port attribute Huisong Li
2024-04-17  9:48   ` [PATCH v2 2/2] soc: hisilicon: kunpeng_hccs: replace MAILBOX dependency with PCC Huisong Li
2024-04-25 11:16   ` [PATCH v2 0/2] soc: hisilicon: kunpeng_hccs: add dependency and enhance verification Wei Xu

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=661C8017.1070203@hisilicon.com \
    --to=xuwei5@hisilicon.com \
    --cc=Jonathan.Cameron@Huawei.com \
    --cc=lihuisong@huawei.com \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=liuyonglong@huawei.com \
    --cc=soc@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;
as well as URLs for NNTP newsgroup(s).