From patchwork Thu Jun 28 12:50:37 2012 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Andreas_Bie=C3=9Fmann?= X-Patchwork-Id: 167869 X-Patchwork-Delegate: andreas.biessmann@googlemail.com Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from theia.denx.de (theia.denx.de [85.214.87.163]) by ozlabs.org (Postfix) with ESMTP id 6750AB6FBE for ; Thu, 28 Jun 2012 22:50:59 +1000 (EST) Received: from localhost (localhost [127.0.0.1]) by theia.denx.de (Postfix) with ESMTP id 735002807F; Thu, 28 Jun 2012 14:50:55 +0200 (CEST) X-Virus-Scanned: Debian amavisd-new at theia.denx.de Received: from theia.denx.de ([127.0.0.1]) by localhost (theia.denx.de [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 7xdGfZky6MWP; Thu, 28 Jun 2012 14:50:55 +0200 (CEST) Received: from theia.denx.de (localhost [127.0.0.1]) by theia.denx.de (Postfix) with ESMTP id 634CA28082; Thu, 28 Jun 2012 14:50:52 +0200 (CEST) Received: from localhost (localhost [127.0.0.1]) by theia.denx.de (Postfix) with ESMTP id 6219028082 for ; Thu, 28 Jun 2012 14:50:50 +0200 (CEST) X-Virus-Scanned: Debian amavisd-new at theia.denx.de Received: from theia.denx.de ([127.0.0.1]) by localhost (theia.denx.de [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id a592Kih6ZzPx for ; Thu, 28 Jun 2012 14:50:49 +0200 (CEST) X-policyd-weight: NOT_IN_SBL_XBL_SPAMHAUS=-1.5 NOT_IN_SPAMCOP=-1.5 NOT_IN_BL_NJABL=-1.5 (only DNSBL check requested) Received: from mail-bk0-f44.google.com (mail-bk0-f44.google.com [209.85.214.44]) by theia.denx.de (Postfix) with ESMTPS id 9EA292807F for ; Thu, 28 Jun 2012 14:50:47 +0200 (CEST) Received: by bkty8 with SMTP id y8so1886179bkt.3 for ; Thu, 28 Jun 2012 05:50:46 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=googlemail.com; s=20120113; h=from:to:cc:subject:date:message-id:x-mailer:mime-version :content-type:content-transfer-encoding; bh=rNWrfPUDe8WYVLuQcGoEba5BdN3yYezcuFRLh3jiACE=; b=KGdLT611xS8fTBJ7fjrrjFS7/sqA/YcCdKIAOThK39gZ0gEMvz6Qg+qNonfivbiRRs BL2VytLanV8vLDccjQvp0FMzKDWzGrAMAZlxRHfjRC5nuqIsVLgsqBwt999SW5jZqlfH F1wg8O0AV/MOx1mwL99TEjMuc05A0GAq1gUUzIFmWm+D8gATBayLzmxhrx5YWI64eiCW nrcZ66Tf2sv1OT0UxkDa7eEO1M7RRlAfY+hvUzZMWVpiihSgxYv7HeUbPe+Q/JG0OeaW 73rbvX1SHzyv7mbCViT2AdfU02v0cVyCvPX20eZ5g4eCcFMy+sC14f9dOYXh2Yt0W6XX q4og== Received: by 10.204.149.216 with SMTP id u24mr1066662bkv.36.1340887846123; Thu, 28 Jun 2012 05:50:46 -0700 (PDT) Received: from azuregos.er.corscience.de (DSL01.212.114.252.242.ip-pool.NEFkom.net. [212.114.252.242]) by mx.google.com with ESMTPS id fu14sm58880711bkc.13.2012.06.28.05.50.44 (version=SSLv3 cipher=OTHER); Thu, 28 Jun 2012 05:50:45 -0700 (PDT) From: =?UTF-8?q?Andreas=20Bie=C3=9Fmann?= To: u-boot@lists.denx.de Date: Thu, 28 Jun 2012 14:50:37 +0200 Message-Id: <1340887837-3073-1-git-send-email-andreas.devel@googlemail.com> X-Mailer: git-send-email 1.7.10 MIME-Version: 1.0 Cc: Marek Vasut , Bo Shen Subject: [U-Boot] [PATCH] ehci-atmel: fix compiler warning X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.11 Precedence: list List-Id: U-Boot discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: u-boot-bounces@lists.denx.de Errors-To: u-boot-bounces@lists.denx.de Commit f61483c539439d32278faec62753811734737cce intoduced following warning: ---8<--- ehci-atmel.c: In function 'ehci_hcd_init': ehci-atmel.c:49:2: warning: suggest parentheses around comparison in operand of '&' [-Wparentheses] ehci-atmel.c: In function 'ehci_hcd_stop': ehci-atmel.c:79:2: warning: suggest parentheses around comparison in operand of '&' [-Wparentheses] --->8--- This patch fixes it. Signed-off-by: Andreas Bießmann cc: Bo Shen cc: Marek Vasut --- I'm really sorry, should have run the compile check before submission. This warning was introduced in v3, it was not there in v2. Maybe there was a misunderstanding between you Marek and you Bo. I will apply this patch immidiately. Best regards Andreas Bießmann drivers/usb/host/ehci-atmel.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/usb/host/ehci-atmel.c b/drivers/usb/host/ehci-atmel.c index 532db22..15b9b60 100644 --- a/drivers/usb/host/ehci-atmel.c +++ b/drivers/usb/host/ehci-atmel.c @@ -46,7 +46,7 @@ int ehci_hcd_init(void) start_time = get_timer(0); /* Enable UTMI PLL */ writel(AT91_PMC_UPLLEN | AT91_PMC_BIASEN, &pmc->uckr); - while (readl(&pmc->sr) & AT91_PMC_LOCKU != AT91_PMC_LOCKU) { + while ((readl(&pmc->sr) & AT91_PMC_LOCKU) != AT91_PMC_LOCKU) { WATCHDOG_RESET(); tmp_time = get_timer(0); if ((tmp_time - start_time) > EN_UPLL_TIMEOUT) { @@ -76,7 +76,7 @@ int ehci_hcd_stop(void) start_time = get_timer(0); /* Disable UTMI PLL */ writel(readl(&pmc->uckr) & ~AT91_PMC_UPLLEN, &pmc->uckr); - while (readl(&pmc->sr) & AT91_PMC_LOCKU == AT91_PMC_LOCKU) { + while ((readl(&pmc->sr) & AT91_PMC_LOCKU) == AT91_PMC_LOCKU) { WATCHDOG_RESET(); tmp_time = get_timer(0); if ((tmp_time - start_time) > EN_UPLL_TIMEOUT) {