mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Michal Simek <michal.simek@xilinx.com>
To: Rajan Vaja <rajan.vaja@xilinx.com>, <michal.simek@xilinx.com>,
	<gregkh@linuxfoundation.org>, <arnd@arndb.de>,
	<manish.narani@xilinx.com>, <nava.manne@xilinx.com>,
	<lakshmi.sai.krishna.potthuri@xilinx.com>
Cc: <linux-arm-kernel@lists.infradead.org>, <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH] firmware: xilinx: check return value of zynqmp_pm_get_api_version()
Date: Mon, 18 Oct 2021 15:14:45 +0200	[thread overview]
Message-ID: <4af277e4-4cab-1e61-8a68-f45df1b19016@xilinx.com> (raw)
In-Reply-To: <1633509835-31949-1-git-send-email-rajan.vaja@xilinx.com>



On 10/6/21 10:43, Rajan Vaja wrote:
> Currently return value of zynqmp_pm_get_api_version() is ignored.
> Because of that, API version is checked in case of error also.
> So add check for return value of zynqmp_pm_get_api_version().
> 
> Signed-off-by: Rajan Vaja <rajan.vaja@xilinx.com>
> ---
>   drivers/firmware/xilinx/zynqmp.c | 5 ++++-
>   1 file changed, 4 insertions(+), 1 deletion(-)
> 
> diff --git a/drivers/firmware/xilinx/zynqmp.c b/drivers/firmware/xilinx/zynqmp.c
> index a3cadba..070197e 100644
> --- a/drivers/firmware/xilinx/zynqmp.c
> +++ b/drivers/firmware/xilinx/zynqmp.c
> @@ -1371,7 +1371,10 @@ static int zynqmp_firmware_probe(struct platform_device *pdev)
>   		return ret;
>   
>   	/* Check PM API version number */
> -	zynqmp_pm_get_api_version(&pm_api_version);
> +	ret = zynqmp_pm_get_api_version(&pm_api_version);
> +	if (ret)
> +		return ret;
> +
>   	if (pm_api_version < ZYNQMP_PM_VERSION) {
>   		panic("%s Platform Management API version error. Expected: v%d.%d - Found: v%d.%d\n",
>   		      __func__,
> 

Applied.
M

      parent reply	other threads:[~2021-10-18 13:14 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-10-06  8:43 Rajan Vaja
2021-10-06  8:53 ` Michal Simek
2021-10-18 13:14 ` Michal Simek [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=4af277e4-4cab-1e61-8a68-f45df1b19016@xilinx.com \
    --to=michal.simek@xilinx.com \
    --cc=arnd@arndb.de \
    --cc=gregkh@linuxfoundation.org \
    --cc=lakshmi.sai.krishna.potthuri@xilinx.com \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=manish.narani@xilinx.com \
    --cc=nava.manne@xilinx.com \
    --cc=rajan.vaja@xilinx.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

all inboxes | Powered by JetHome®