From: Tang Bin <tangbin@cmss.chinamobile.com>
To: cernekee@gmail.com, balbi@kernel.org, gregkh@linuxfoundation.org,
sergei.shtylyov@cogentembedded.com
Cc: f.fainelli@gmail.com, bcm-kernel-feedback-list@broadcom.com,
linux-usb@vger.kernel.org, linux-arm-kernel@lists.infradead.org,
linux-kernel@vger.kernel.org,
Tang Bin <tangbin@cmss.chinamobile.com>
Subject: [PATCH v2]usb: gadget: bcm63xx_udc:remove redundant variable assignment
Date: Tue, 24 Mar 2020 21:20:29 +0800 [thread overview]
Message-ID: <20200324132029.16296-1-tangbin@cmss.chinamobile.com> (raw)
--v1------------------------------------
In this function, the variable 'rc' is assigned after this place,
so the definition is invalid.
--v2------------------------------------
In this function, the variable 'rc' will be assigned by the function
'usb_add_gadget_udc()',so the assignment here is redundant,we should
remove it.
Signed-off-by: Tang Bin <tangbin@cmss.chinamobile.com>
---
drivers/usb/gadget/udc/bcm63xx_udc.c | 2 --
1 file changed, 2 deletions(-)
diff --git a/drivers/usb/gadget/udc/bcm63xx_udc.c b/drivers/usb/gadget/udc/bcm63xx_udc.c
index 54501814d..a7afa8c35 100644
--- a/drivers/usb/gadget/udc/bcm63xx_udc.c
+++ b/drivers/usb/gadget/udc/bcm63xx_udc.c
@@ -2321,8 +2321,6 @@ static int bcm63xx_udc_probe(struct platform_device *pdev)
if (rc)
return rc;
- rc = -ENXIO;
-
/* IRQ resource #0: control interrupt (VBUS, speed, etc.) */
irq = platform_get_irq(pdev, 0);
if (irq < 0)
--
2.20.1.windows.1
next reply other threads:[~2020-03-24 13:20 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-03-24 13:20 Tang Bin [this message]
2020-03-24 14:50 ` [PATCH v2]usb: gadget: bcm63xx_udc:remove redundant variable assignment Sergei Shtylyov
2020-03-24 14:55 ` Sergei Shtylyov
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=20200324132029.16296-1-tangbin@cmss.chinamobile.com \
--to=tangbin@cmss.chinamobile.com \
--cc=balbi@kernel.org \
--cc=bcm-kernel-feedback-list@broadcom.com \
--cc=cernekee@gmail.com \
--cc=f.fainelli@gmail.com \
--cc=gregkh@linuxfoundation.org \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-usb@vger.kernel.org \
--cc=sergei.shtylyov@cogentembedded.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).