From patchwork Tue Sep 1 19:24:13 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Vaibhav Hiremath X-Patchwork-Id: 52940 Return-Path: X-Original-To: linaro@patches.linaro.org Delivered-To: linaro@patches.linaro.org Received: from mail-lb0-f199.google.com (mail-lb0-f199.google.com [209.85.217.199]) by patches.linaro.org (Postfix) with ESMTPS id 295712157D for ; Tue, 1 Sep 2015 19:27:11 +0000 (UTC) Received: by lbbmp1 with SMTP id mp1sf3707284lbb.2 for ; Tue, 01 Sep 2015 12:27:10 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:delivered-to:from:to:cc:subject :date:message-id:in-reply-to:references:sender:precedence:list-id :x-original-sender:x-original-authentication-results:mailing-list :list-post:list-help:list-archive:list-unsubscribe; bh=+V8TKIJzpwWmQHREM5Z+kyEdCinU7NYNxcp2fn1+Aeg=; b=G9wpx8ULVPyMC1/opY9asZMFbb/0rnQE/V8VHW4PQSCVAPh1ba448kWJQrHlqumLfn Gn+0+MT9M7iK8zk7u41EsWcjLVg9aGUKzLm3CBkacMRxNTFWTQ5yZiGx3H1i8AGNMY+Y JaLQwCy+4IrDqRvUdn28z8J39yUJVRKRYJc+QsEPlmRngQvPsBdyls9P81fnSHsaQAZG jVDOS/p7NVQYcsNMV+blG7bkZWs3fl/CQ1FybbchkufFwXDPDlk0bXvbIRFxOQFEJNiC ZfIYxEsIGj4GhMXXoSv+VT/VVccL5HWyX5WrvaqOfOr6hzXeVY5vH/Rg1konGKlhJn9Z +ikw== X-Gm-Message-State: ALoCoQkgiosr+P7jYR87qvWUsYKXExMbl0D9GwnqGBspcHwpuwGiWjduZ6SrELu+ozzQSV0uO1S+ X-Received: by 10.112.135.104 with SMTP id pr8mr8178126lbb.4.1441135630121; Tue, 01 Sep 2015 12:27:10 -0700 (PDT) MIME-Version: 1.0 X-BeenThere: patchwork-forward@linaro.org Received: by 10.152.23.74 with SMTP id k10ls640897laf.30.gmail; Tue, 01 Sep 2015 12:27:10 -0700 (PDT) X-Received: by 10.112.125.34 with SMTP id mn2mr11285381lbb.76.1441135629988; Tue, 01 Sep 2015 12:27:09 -0700 (PDT) Received: from mail-la0-f43.google.com (mail-la0-f43.google.com. [209.85.215.43]) by mx.google.com with ESMTPS id ap9si17326657lbc.133.2015.09.01.12.27.09 for (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Tue, 01 Sep 2015 12:27:09 -0700 (PDT) Received-SPF: pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.215.43 as permitted sender) client-ip=209.85.215.43; Received: by lagj9 with SMTP id j9so4160347lag.2 for ; Tue, 01 Sep 2015 12:27:09 -0700 (PDT) X-Received: by 10.112.131.98 with SMTP id ol2mr13998492lbb.56.1441135629740; Tue, 01 Sep 2015 12:27:09 -0700 (PDT) X-Forwarded-To: patchwork-forward@linaro.org X-Forwarded-For: patch@linaro.org patchwork-forward@linaro.org Delivered-To: patch@linaro.org Received: by 10.112.164.42 with SMTP id yn10csp69245lbb; Tue, 1 Sep 2015 12:27:08 -0700 (PDT) X-Received: by 10.66.192.130 with SMTP id hg2mr48931611pac.114.1441135628611; Tue, 01 Sep 2015 12:27:08 -0700 (PDT) Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id i6si31282214pbq.228.2015.09.01.12.27.07; Tue, 01 Sep 2015 12:27:08 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-mmc-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754328AbbIAT1B (ORCPT + 2 others); Tue, 1 Sep 2015 15:27:01 -0400 Received: from mail-pa0-f50.google.com ([209.85.220.50]:34238 "EHLO mail-pa0-f50.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1754277AbbIAT06 (ORCPT ); Tue, 1 Sep 2015 15:26:58 -0400 Received: by padhy1 with SMTP id hy1so5222452pad.1 for ; Tue, 01 Sep 2015 12:26:57 -0700 (PDT) X-Received: by 10.68.169.69 with SMTP id ac5mr50231658pbc.14.1441135617441; Tue, 01 Sep 2015 12:26:57 -0700 (PDT) Received: from localhost.localdomain ([202.62.93.143]) by smtp.gmail.com with ESMTPSA id kh10sm7418927pad.7.2015.09.01.12.26.54 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Tue, 01 Sep 2015 12:26:56 -0700 (PDT) From: Vaibhav Hiremath To: linux-mmc@vger.kernel.org Cc: ulf.hansson@linaro.org, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, Vaibhav Hiremath Subject: [PATCH 1/2] mmc: sdhci-pxav3: Fix tabbing issue Date: Wed, 2 Sep 2015 00:54:13 +0530 Message-Id: <1441135454-6902-2-git-send-email-vaibhav.hiremath@linaro.org> X-Mailer: git-send-email 1.9.1 In-Reply-To: <1441135454-6902-1-git-send-email-vaibhav.hiremath@linaro.org> References: <1441135454-6902-1-git-send-email-vaibhav.hiremath@linaro.org> Sender: linux-mmc-owner@vger.kernel.org Precedence: list List-ID: X-Mailing-List: linux-mmc@vger.kernel.org X-Removed-Original-Auth: Dkim didn't pass. X-Original-Sender: vaibhav.hiremath@linaro.org X-Original-Authentication-Results: mx.google.com; spf=pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.215.43 as permitted sender) smtp.mailfrom=patch+caf_=patchwork-forward=linaro.org@linaro.org Mailing-list: list patchwork-forward@linaro.org; contact patchwork-forward+owners@linaro.org X-Google-Group-Id: 836684582541 List-Post: , List-Help: , List-Archive: List-Unsubscribe: , There were some coding style issues where spaces have been used instead of tabs, for example, in macro definitions, alignment of function declarations/definitions, etc... This patch fixes all such occurrences in the code. And also use BIT for bit definitions. Signed-off-by: Vaibhav Hiremath --- drivers/mmc/host/sdhci-pxav3.c | 63 ++++++++++++++++++++++-------------------- 1 file changed, 33 insertions(+), 30 deletions(-) diff --git a/drivers/mmc/host/sdhci-pxav3.c b/drivers/mmc/host/sdhci-pxav3.c index 946d37f..d02bc37 100644 --- a/drivers/mmc/host/sdhci-pxav3.c +++ b/drivers/mmc/host/sdhci-pxav3.c @@ -39,24 +39,29 @@ #include "sdhci.h" #include "sdhci-pltfm.h" -#define PXAV3_RPM_DELAY_MS 50 +#define PXAV3_RPM_DELAY_MS 50 -#define SD_CLOCK_BURST_SIZE_SETUP 0x10A -#define SDCLK_SEL 0x100 -#define SDCLK_DELAY_SHIFT 9 -#define SDCLK_DELAY_MASK 0x1f +#define SD_CLOCK_BURST_SIZE_SETUP 0x10A +#define SDCLK_SEL 0x100 +#define SDCLK_DELAY_SHIFT 9 +#define SDCLK_DELAY_MASK 0x1f -#define SD_CFG_FIFO_PARAM 0x100 -#define SDCFG_GEN_PAD_CLK_ON (1<<6) -#define SDCFG_GEN_PAD_CLK_CNT_MASK 0xFF -#define SDCFG_GEN_PAD_CLK_CNT_SHIFT 24 +#define SD_CFG_FIFO_PARAM 0x100 +#define SDCFG_GEN_PAD_CLK_ON BIT(6) +#define SDCFG_GEN_PAD_CLK_CNT_MASK 0xFF +#define SDCFG_GEN_PAD_CLK_CNT_SHIFT 24 -#define SD_SPI_MODE 0x108 -#define SD_CE_ATA_1 0x10C +#define SD_SPI_MODE 0x108 +#define SD_CE_ATA_1 0x10C -#define SD_CE_ATA_2 0x10E -#define SDCE_MISC_INT (1<<2) -#define SDCE_MISC_INT_EN (1<<1) +#define SD_CE_ATA_2 0x10E +#define SDCE_MISC_INT BIT(2) +#define SDCE_MISC_INT_EN BIT(1) + +/* IO Power control */ +#define IO_PWR_AKEY_ASFAR 0xbaba +#define IO_PWR_AKEY_ASSAR 0xeb10 +#define IO_PWR_MMC1_PAD_1V8 BIT(2) struct sdhci_pxa { struct clk *clk_core; @@ -128,7 +133,7 @@ static int mv_conf_mbus_windows(struct platform_device *pdev, } static int armada_38x_quirks(struct platform_device *pdev, - struct sdhci_host *host) + struct sdhci_host *host) { struct device_node *np = pdev->dev.of_node; struct sdhci_pltfm_host *pltfm_host = sdhci_priv(host); @@ -136,8 +141,7 @@ static int armada_38x_quirks(struct platform_device *pdev, struct resource *res; host->quirks |= SDHCI_QUIRK_MISSING_CAPS; - res = platform_get_resource_byname(pdev, IORESOURCE_MEM, - "conf-sdio3"); + res = platform_get_resource_byname(pdev, IORESOURCE_MEM, "conf-sdio3"); if (res) { pxa->sdio3_conf_reg = devm_ioremap_resource(&pdev->dev, res); if (IS_ERR(pxa->sdio3_conf_reg)) @@ -284,10 +288,10 @@ static void pxav3_set_uhs_signaling(struct sdhci_host *host, unsigned int uhs) * FE-2946959 */ if (pxa->sdio3_conf_reg) { - u8 reg_val = readb(pxa->sdio3_conf_reg); + u8 reg_val = readb(pxa->sdio3_conf_reg); if (uhs == MMC_TIMING_UHS_SDR50 || - uhs == MMC_TIMING_UHS_DDR50) { + uhs == MMC_TIMING_UHS_DDR50) { reg_val &= ~SDIO3_CONF_CLK_INV; reg_val |= SDIO3_CONF_SD_FB_CLK; } else { @@ -304,20 +308,20 @@ static void pxav3_set_uhs_signaling(struct sdhci_host *host, unsigned int uhs) } static const struct sdhci_ops pxav3_sdhci_ops = { - .set_clock = sdhci_set_clock, - .platform_send_init_74_clocks = pxav3_gen_init_74_clocks, - .get_max_clock = sdhci_pltfm_clk_get_max_clock, - .set_bus_width = sdhci_set_bus_width, - .reset = pxav3_reset, - .set_uhs_signaling = pxav3_set_uhs_signaling, + .set_clock = sdhci_set_clock, + .platform_send_init_74_clocks = pxav3_gen_init_74_clocks, + .get_max_clock = sdhci_pltfm_clk_get_max_clock, + .set_bus_width = sdhci_set_bus_width, + .reset = pxav3_reset, + .set_uhs_signaling = pxav3_set_uhs_signaling, }; static struct sdhci_pltfm_data sdhci_pxav3_pdata = { - .quirks = SDHCI_QUIRK_DATA_TIMEOUT_USES_SDCLK + .quirks = SDHCI_QUIRK_DATA_TIMEOUT_USES_SDCLK | SDHCI_QUIRK_NO_ENDATTR_IN_NOPDESC | SDHCI_QUIRK_32BIT_ADMA_SIZE | SDHCI_QUIRK_CAP_CLOCK_BASE_BROKEN, - .ops = &pxav3_sdhci_ops, + .ops = &pxav3_sdhci_ops, }; #ifdef CONFIG_OF @@ -343,7 +347,7 @@ static struct sdhci_pxa_platdata *pxav3_get_mmc_pdata(struct device *dev) return NULL; if (!of_property_read_u32(np, "mrvl,clk-delay-cycles", - &clk_delay_cycles)) + &clk_delay_cycles)) pdata->clk_delay_cycles = clk_delay_cycles; return pdata; @@ -433,8 +437,7 @@ static int sdhci_pxav3_probe(struct platform_device *pdev) host->mmc->pm_caps |= pdata->pm_caps; if (gpio_is_valid(pdata->ext_cd_gpio)) { - ret = mmc_gpio_request_cd(host->mmc, pdata->ext_cd_gpio, - 0); + ret = mmc_gpio_request_cd(host->mmc, pdata->ext_cd_gpio, 0); if (ret) { dev_err(mmc_dev(host->mmc), "failed to allocate card detect gpio\n");