From patchwork Sat Jun 18 17:45:30 2011 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Sebastian Rasmussen X-Patchwork-Id: 893562 Received: from merlin.infradead.org (merlin.infradead.org [205.233.59.134]) by demeter2.kernel.org (8.14.4/8.14.4) with ESMTP id p5IHkAVW013998 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO) for ; Sat, 18 Jun 2011 17:46:31 GMT Received: from canuck.infradead.org ([2001:4978:20e::1]) by merlin.infradead.org with esmtps (Exim 4.76 #1 (Red Hat Linux)) id 1QXzai-0001rn-JL; Sat, 18 Jun 2011 17:45:52 +0000 Received: from localhost ([127.0.0.1] helo=canuck.infradead.org) by canuck.infradead.org with esmtp (Exim 4.76 #1 (Red Hat Linux)) id 1QXzai-0007SP-7i; Sat, 18 Jun 2011 17:45:52 +0000 Received: from casper.infradead.org ([2001:770:15f::2]) by canuck.infradead.org with esmtps (Exim 4.76 #1 (Red Hat Linux)) id 1QXzaf-0007SK-80 for linux-arm-kernel@canuck.infradead.org; Sat, 18 Jun 2011 17:45:49 +0000 Received: from mail.df.lth.se ([194.47.250.12]) by casper.infradead.org with esmtps (Exim 4.76 #1 (Red Hat Linux)) id 1QXzac-0005HE-Vd for linux-arm-kernel@lists.infradead.org; Sat, 18 Jun 2011 17:45:47 +0000 Received: from mer.df.lth.se (mer.df.lth.se [194.47.250.37]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by mail.df.lth.se (Postfix) with ESMTPS id 4AA7665DEA; Sat, 18 Jun 2011 19:45:36 +0200 (CEST) Received: from mer.df.lth.se (triad@localhost.localdomain [127.0.0.1]) by mer.df.lth.se (8.14.3/8.14.3/Debian-9.4) with ESMTP id p5IHjZGY018173; Sat, 18 Jun 2011 19:45:35 +0200 Received: (from triad@localhost) by mer.df.lth.se (8.14.3/8.14.3/Submit) id p5IHjZi8018171; Sat, 18 Jun 2011 19:45:35 +0200 From: Sebastian Rasmussen To: linux-mmc@vger.kernel.org, linux-arm-kernel@lists.infradead.org Subject: [PATCH] mmci: Fix checkpatch warnings Date: Sat, 18 Jun 2011 19:45:30 +0200 Message-Id: <1308419130-18143-1-git-send-email-sebras@gmail.com> X-Mailer: git-send-email 1.7.2.5 X-CRM114-Version: 20090807-BlameThorstenAndJenny ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20110618_184547_218353_15D3F580 X-CRM114-Status: GOOD ( 19.34 ) X-Spam-Score: -1.0 (-) X-Spam-Report: SpamAssassin version 3.3.2-r929478 on casper.infradead.org summary: Content analysis details: (-1.0 points, 5.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- 0.0 FREEMAIL_FROM Sender email is freemail (sebras[at]gmail.com) 0.0 DKIM_ADSP_CUSTOM_MED No valid author signature, adsp_override is CUSTOM_MED -0.0 T_RP_MATCHES_RCVD Envelope sender domain matches handover relay domain -0.0 SPF_PASS SPF: sender matches SPF record -1.9 BAYES_00 BODY: Bayes spam probability is 0 to 1% [score: 0.0000] 0.9 NML_ADSP_CUSTOM_MED ADSP custom_med hit, and not from a mailing list 0.0 T_TO_NO_BRKTS_FREEMAIL T_TO_NO_BRKTS_FREEMAIL Cc: Sebastian Rasmussen X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.12 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Sender: linux-arm-kernel-bounces@lists.infradead.org Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org X-Greylist: IP, sender and recipient auto-whitelisted, not delayed by milter-greylist-4.2.6 (demeter2.kernel.org [140.211.167.43]); Sat, 18 Jun 2011 17:46:31 +0000 (UTC) From: Sebastian Rasmussen Pretty self-descriptive. Signed-off-by: Sebastian Rasmussen --- drivers/mmc/host/mmci.c | 38 ++++++++++++++++++++++---------------- 1 files changed, 22 insertions(+), 16 deletions(-) diff --git a/drivers/mmc/host/mmci.c b/drivers/mmc/host/mmci.c index 5da5bea..a94f965 100644 --- a/drivers/mmc/host/mmci.c +++ b/drivers/mmc/host/mmci.c @@ -29,9 +29,9 @@ #include #include #include +#include #include -#include #include #include "mmci.h" @@ -329,11 +329,10 @@ static void mmci_dma_unmap(struct mmci_host *host, struct mmc_data *data) data->error = -EIO; } - if (data->flags & MMC_DATA_WRITE) { + if (data->flags & MMC_DATA_WRITE) dir = DMA_TO_DEVICE; - } else { + else dir = DMA_FROM_DEVICE; - } dma_unmap_sg(chan->device->dev, data->sg, data->sg_len, dir); @@ -445,7 +444,8 @@ static inline void mmci_dma_data_error(struct mmci_host *host) { } -static inline int mmci_dma_start_data(struct mmci_host *host, unsigned int datactrl) +static inline int mmci_dma_start_data(struct mmci_host *host, + unsigned int datactrl) { return -ENOSYS; } @@ -557,7 +557,8 @@ mmci_data_irq(struct mmci_host *host, struct mmc_data *data, unsigned int status) { /* First check for errors */ - if (status & (MCI_DATACRCFAIL|MCI_DATATIMEOUT|MCI_TXUNDERRUN|MCI_RXOVERRUN)) { + if (status & (MCI_DATACRCFAIL|MCI_DATATIMEOUT|MCI_TXUNDERRUN| + MCI_RXOVERRUN)) { u32 remain, success; /* Terminate the DMA transfer */ @@ -606,11 +607,10 @@ mmci_data_irq(struct mmci_host *host, struct mmc_data *data, /* The error clause is handled above, success! */ data->bytes_xfered = data->blksz * data->blocks; - if (!data->stop) { + if (!data->stop) mmci_request_end(host, data->mrq); - } else { + else mmci_start_command(host, data->stop, 0); - } } } @@ -642,7 +642,8 @@ mmci_cmd_irq(struct mmci_host *host, struct mmc_command *cmd, } } -static int mmci_pio_read(struct mmci_host *host, char *buffer, unsigned int remain) +static int mmci_pio_read(struct mmci_host *host, char *buffer, + unsigned int remain) { void __iomem *base = host->base; char *ptr = buffer; @@ -673,7 +674,8 @@ static int mmci_pio_read(struct mmci_host *host, char *buffer, unsigned int rema return ptr - buffer; } -static int mmci_pio_write(struct mmci_host *host, char *buffer, unsigned int remain, u32 status) +static int mmci_pio_write(struct mmci_host *host, char *buffer, + unsigned int remain, u32 status) { struct variant_data *variant = host->variant; void __iomem *base = host->base; @@ -799,7 +801,8 @@ static irqreturn_t mmci_pio_irq(int irq, void *dev_id) */ if (host->size == 0) { mmci_set_mask1(host, 0); - writel(readl(base + MMCIMASK0) | MCI_DATAENDMASK, base + MMCIMASK0); + writel(readl(base + MMCIMASK0) | MCI_DATAENDMASK, + base + MMCIMASK0); } return IRQ_HANDLED; @@ -836,11 +839,13 @@ static irqreturn_t mmci_irq(int irq, void *dev_id) data = host->data; if (status & (MCI_DATACRCFAIL|MCI_DATATIMEOUT|MCI_TXUNDERRUN| - MCI_RXOVERRUN|MCI_DATAEND|MCI_DATABLOCKEND) && data) + MCI_RXOVERRUN|MCI_DATAEND|MCI_DATABLOCKEND) + && data) mmci_data_irq(host, data, status); cmd = host->cmd; - if (status & (MCI_CMDCRCFAIL|MCI_CMDTIMEOUT|MCI_CMDSENT|MCI_CMDRESPEND) && cmd) + if (status & (MCI_CMDCRCFAIL|MCI_CMDTIMEOUT|MCI_CMDSENT| + MCI_CMDRESPEND) && cmd) mmci_cmd_irq(host, cmd, status); ret = 1; @@ -907,7 +912,7 @@ static void mmci_set_ios(struct mmc_host *mmc, struct mmc_ios *ios) if (host->plat->vdd_handler) pwr |= host->plat->vdd_handler(mmc_dev(mmc), ios->vdd, ios->power_mode); - /* The ST version does not have this, fall through to POWER_ON */ + /* ST version does not have this, fall through to POWER_ON */ if (host->hw_designer != AMBA_VENDOR_ST) { pwr |= MCI_PWR_UP; break; @@ -1164,7 +1169,8 @@ static int __devinit mmci_probe(struct amba_device *dev, && host->gpio_cd_irq < 0) mmc->caps |= MMC_CAP_NEEDS_POLL; - ret = request_irq(dev->irq[0], mmci_irq, IRQF_SHARED, DRIVER_NAME " (cmd)", host); + ret = request_irq(dev->irq[0], mmci_irq, IRQF_SHARED, + DRIVER_NAME " (cmd)", host); if (ret) goto unmap;