From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mx01-fr.bfs.de ([193.174.231.67]:43792 "EHLO mx01-fr.bfs.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751676Ab3HUJFt (ORCPT ); Wed, 21 Aug 2013 05:05:49 -0400 Message-ID: <52148115.3050703@bfs.de> Date: Wed, 21 Aug 2013 10:57:57 +0200 From: walter harms Reply-To: wharms@bfs.de MIME-Version: 1.0 Subject: Re: [patch] mmc: sdhci-bcm-kona: '|' vs '&' typo References: <20130821082423.GA5240@elgon.mountain> In-Reply-To: <20130821082423.GA5240@elgon.mountain> Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Sender: devicetree-owner@vger.kernel.org To: Dan Carpenter Cc: Chris Ball , Grant Likely , Rob Herring , Christian Daudt , Arnd Bergmann , linux-mmc@vger.kernel.org, devicetree@vger.kernel.org, kernel-janitors@vger.kernel.org List-ID: Am 21.08.2013 10:24, schrieb Dan Carpenter: > The intent was to test if a flag was set. In the current code the > conditions are always true. I guess that it worked before ... That leaves the Question: are the tests needed at all ? re, wh > Signed-off-by: Dan Carpenter > --- > Static checker stuff. Untested. > > diff --git a/drivers/mmc/host/sdhci-bcm-kona.c b/drivers/mmc/host/sdhci-bcm-kona.c > index 87175f9..9ffac0b 100644 > --- a/drivers/mmc/host/sdhci-bcm-kona.c > +++ b/drivers/mmc/host/sdhci-bcm-kona.c > @@ -263,7 +263,7 @@ static int __init sdhci_bcm_kona_probe(struct platform_device *pdev) > (mmc_gpio_get_cd(host->mmc) != -ENOSYS) ? 'Y' : 'N', > (mmc_gpio_get_ro(host->mmc) != -ENOSYS) ? 'Y' : 'N'); > > - if (host->mmc->caps | MMC_CAP_NONREMOVABLE) > + if (host->mmc->caps & MMC_CAP_NONREMOVABLE) > host->quirks |= SDHCI_QUIRK_BROKEN_CARD_DETECTION; > > dev_dbg(dev, "is_8bit=%c\n", > @@ -282,7 +282,7 @@ static int __init sdhci_bcm_kona_probe(struct platform_device *pdev) > } > > /* if device is eMMC, emulate card insert right here */ > - if (host->mmc->caps | MMC_CAP_NONREMOVABLE) { > + if (host->mmc->caps & MMC_CAP_NONREMOVABLE) { > ret = sdhci_bcm_kona_sd_card_emulate(host, 1); > if (ret) { > dev_err(dev, > -- > To unsubscribe from this list: send the line "unsubscribe kernel-janitors" in > the body of a message to majordomo@vger.kernel.org > More majordomo info at http://vger.kernel.org/majordomo-info.html >