diff mbox series

nfc: fdp: remove unnecessary labels

Message ID 20210610024616.1804-1-samirweng1979@163.com (mailing list archive)
State Accepted
Commit 43fa32d1cc1b967858ba5786b1b913527f1b10ed
Delegated to: Netdev Maintainers
Headers show
Series nfc: fdp: remove unnecessary labels | expand

Checks

Context Check Description
netdev/cover_letter success Link
netdev/fixes_present success Link
netdev/patch_count success Link
netdev/tree_selection success Guessed tree name to be net-next
netdev/subject_prefix warning Target tree name not specified in the subject
netdev/cc_maintainers warning 1 maintainers not CCed: zuoqilin@yulong.com
netdev/source_inline success Was 0 now: 0
netdev/verify_signedoff success Link
netdev/module_param success Was 0 now: 0
netdev/build_32bit success Errors and warnings before: 0 this patch: 0
netdev/kdoc success Errors and warnings before: 0 this patch: 0
netdev/verify_fixes success Link
netdev/checkpatch success total: 0 errors, 0 warnings, 0 checks, 26 lines checked
netdev/build_allmodconfig_warn success Errors and warnings before: 0 this patch: 0
netdev/header_inline success Link

Commit Message

samirweng1979 June 10, 2021, 2:46 a.m. UTC
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(-)

Comments

Krzysztof Kozlowski June 10, 2021, 6:36 a.m. UTC | #1
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)
>
patchwork-bot+netdevbpf@kernel.org June 11, 2021, 8 p.m. UTC | #2
Hello:

This patch was applied to netdev/net-next.git (refs/heads/master):

On Thu, 10 Jun 2021 10:46:16 +0800 you 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>
> 
> [...]

Here is the summary with links:
  - nfc: fdp: remove unnecessary labels
    https://git.kernel.org/netdev/net-next/c/43fa32d1cc1b

You are awesome, thank you!
--
Deet-doot-dot, I am a bot.
https://korg.docs.kernel.org/patchwork/pwbot.html
diff mbox series

Patch

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)