All of lore.kernel.org
 help / color / mirror / Atom feed
From: Roel Kluin <roel.kluin@gmail.com>
To: Felipe Balbi <felipe.balbi@nokia.com>,
	linux-usb@vger.kernel.org,
	Andrew Morton <akpm@linux-foundation.org>,
	LKML <linux-kernel@vger.kernel.org>
Subject: [PATCH] musb: Test always evaluates to false
Date: Sat, 09 Jan 2010 13:09:01 +0100	[thread overview]
Message-ID: <4B4871DD.5070505@gmail.com> (raw)

The removed part always evaluates to false.

Signed-off-by: Roel Kluin <roel.kluin@gmail.com>
---
 drivers/usb/musb/musb_gadget.c |    3 +--
 1 files changed, 1 insertions(+), 2 deletions(-)

Was a different test intended?

diff --git a/drivers/usb/musb/musb_gadget.c b/drivers/usb/musb/musb_gadget.c
index cbcf14a..1a19203 100644
--- a/drivers/usb/musb/musb_gadget.c
+++ b/drivers/usb/musb/musb_gadget.c
@@ -1697,8 +1697,7 @@ int usb_gadget_register_driver(struct usb_gadget_driver *driver)
 		return -EINVAL;
 
 	/* driver must be initialized to support peripheral mode */
-	if (!musb || !(musb->board_mode == MUSB_OTG
-				|| musb->board_mode != MUSB_OTG)) {
+	if (!musb) {
 		DBG(1, "%s, no dev??\n", __func__);
 		return -ENODEV;
 	}

             reply	other threads:[~2010-01-09 12:05 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-01-09 12:09 Roel Kluin [this message]
2010-01-29 10:39 ` [PATCH] musb: Test always evaluates to false Felipe Balbi

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=4B4871DD.5070505@gmail.com \
    --to=roel.kluin@gmail.com \
    --cc=akpm@linux-foundation.org \
    --cc=felipe.balbi@nokia.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-usb@vger.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.