From: Krzysztof Kozlowski <krzysztof.kozlowski@canonical.com>
To: samirweng1979 <samirweng1979@163.com>,
davem@davemloft.net, kuba@kernel.org, unixbhaskar@gmail.com
Cc: netdev@vger.kernel.org, linux-kernel@vger.kernel.org,
wengjianfeng <wengjianfeng@yulong.com>
Subject: Re: [PATCH] nfc: fdp: remove unnecessary labels
Date: Thu, 10 Jun 2021 08:36:42 +0200 [thread overview]
Message-ID: <a4dd4569-2f81-7aac-e8f7-405866bb1b7d@canonical.com> (raw)
In-Reply-To: <20210610024616.1804-1-samirweng1979@163.com>
On 10/06/2021 04:46, samirweng1979 wrote:
> From: wengjianfeng <wengjianfeng@yulong.com>
>
> Some labels are meaningless, so we delete them and use the
> return statement instead of the goto statement.
>
> Signed-off-by: wengjianfeng <wengjianfeng@yulong.com>
> ---
> drivers/nfc/fdp/fdp.c | 7 ++-----
> 1 file changed, 2 insertions(+), 5 deletions(-)
>
Reviewed-by: Krzysztof Kozlowski <krzysztof.kozlowski@canonical.com>
Best regards,
Krzysztof
> diff --git a/drivers/nfc/fdp/fdp.c b/drivers/nfc/fdp/fdp.c
> index 7863b25..5287458 100644
> --- a/drivers/nfc/fdp/fdp.c
> +++ b/drivers/nfc/fdp/fdp.c
> @@ -266,7 +266,7 @@ static int fdp_nci_request_firmware(struct nci_dev *ndev)
> r = request_firmware(&info->ram_patch, FDP_RAM_PATCH_NAME, dev);
> if (r < 0) {
> nfc_err(dev, "RAM patch request error\n");
> - goto error;
> + return r;
> }
>
> data = (u8 *) info->ram_patch->data;
> @@ -283,7 +283,7 @@ static int fdp_nci_request_firmware(struct nci_dev *ndev)
> r = request_firmware(&info->otp_patch, FDP_OTP_PATCH_NAME, dev);
> if (r < 0) {
> nfc_err(dev, "OTP patch request error\n");
> - goto out;
> + return 0;
> }
>
> data = (u8 *) info->otp_patch->data;
> @@ -295,10 +295,7 @@ static int fdp_nci_request_firmware(struct nci_dev *ndev)
>
> dev_dbg(dev, "OTP patch version: %d, size: %d\n",
> info->otp_patch_version, (int) info->otp_patch->size);
> -out:
> return 0;
> -error:
> - return r;
> }
>
> static void fdp_nci_release_firmware(struct nci_dev *ndev)
>
next prev parent reply other threads:[~2021-06-10 6:36 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-06-10 2:46 [PATCH] nfc: fdp: remove unnecessary labels samirweng1979
2021-06-10 6:36 ` Krzysztof Kozlowski [this message]
2021-06-11 20:00 ` patchwork-bot+netdevbpf
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=a4dd4569-2f81-7aac-e8f7-405866bb1b7d@canonical.com \
--to=krzysztof.kozlowski@canonical.com \
--cc=davem@davemloft.net \
--cc=kuba@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=netdev@vger.kernel.org \
--cc=samirweng1979@163.com \
--cc=unixbhaskar@gmail.com \
--cc=wengjianfeng@yulong.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).