From patchwork Tue Apr 29 08:21:02 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Srinivas Kandagatla X-Patchwork-Id: 29312 Return-Path: X-Original-To: linaro@patches.linaro.org Delivered-To: linaro@patches.linaro.org Received: from mail-pd0-f200.google.com (mail-pd0-f200.google.com [209.85.192.200]) by ip-10-151-82-157.ec2.internal (Postfix) with ESMTPS id 8DB32202FE for ; Tue, 29 Apr 2014 08:21:28 +0000 (UTC) Received: by mail-pd0-f200.google.com with SMTP id x10sf14705567pdj.3 for ; Tue, 29 Apr 2014 01:21:27 -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=kqCb32p1lAqdLYBKgchaactwRmHpeCglF6wSYHbWvsw=; b=UkzQT8eoNZrkEHJdG/v/MQdLGP/UMJ9A/U22RCc303Wcu4GCiG/Dn9WkiC5QegswDh 1lsNMNWPZQFZu+27OdLiwww0WW0pucLPjhnU2wc/4wkWuXPtqI2TtY4NZqWAnfowa8up TBD2IXH9uMZlBpoAg+jcuxRbRr/pe3EmOdcvxK/yiTK22xp8P/3Lwf17dH80R3Ph9LjS 8fqAsvXlDt37oaGQnRwXVQmpYUuXVaVi/R+8s2qnxjPTWe0tayMzczrFBvsQQLL0pC/J /ejWexWxr0wtKNq0nkEZVUEq8qsF7nBY21oEY4cLLN/WabXoF2YKjzme7SL30qpbzDhH P7ew== X-Gm-Message-State: ALoCoQlmQFa/oDtZE2RsJKVrShmYGY/rqqOxrJRNQXHcU6GMS8Fwxz+EMUyn2reuUjJ5CBO3eJQW X-Received: by 10.66.102.36 with SMTP id fl4mr13897150pab.20.1398759687768; Tue, 29 Apr 2014 01:21:27 -0700 (PDT) MIME-Version: 1.0 X-BeenThere: patchwork-forward@linaro.org Received: by 10.140.47.10 with SMTP id l10ls2772583qga.4.gmail; Tue, 29 Apr 2014 01:21:27 -0700 (PDT) X-Received: by 10.221.37.1 with SMTP id tc1mr72143vcb.32.1398759687638; Tue, 29 Apr 2014 01:21:27 -0700 (PDT) Received: from mail-vc0-f176.google.com (mail-vc0-f176.google.com [209.85.220.176]) by mx.google.com with ESMTPS id vd8si4326801vdc.160.2014.04.29.01.21.27 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Tue, 29 Apr 2014 01:21:27 -0700 (PDT) Received-SPF: none (google.com: patch+caf_=patchwork-forward=linaro.org@linaro.org does not designate permitted sender hosts) client-ip=209.85.220.176; Received: by mail-vc0-f176.google.com with SMTP id lc6so9304783vcb.7 for ; Tue, 29 Apr 2014 01:21:27 -0700 (PDT) X-Received: by 10.52.65.132 with SMTP id x4mr381082vds.36.1398759687559; Tue, 29 Apr 2014 01:21:27 -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.220.221.72 with SMTP id ib8csp178201vcb; Tue, 29 Apr 2014 01:21:27 -0700 (PDT) X-Received: by 10.66.227.193 with SMTP id sc1mr31047954pac.102.1398759686729; Tue, 29 Apr 2014 01:21:26 -0700 (PDT) Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id rw8si6379883pbc.190.2014.04.29.01.21.26 for ; Tue, 29 Apr 2014 01:21:26 -0700 (PDT) Received-SPF: none (google.com: linux-kernel-owner@vger.kernel.org does not designate permitted sender hosts) client-ip=209.132.180.67; Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1755730AbaD2IVO (ORCPT + 28 others); Tue, 29 Apr 2014 04:21:14 -0400 Received: from mail-we0-f173.google.com ([74.125.82.173]:49582 "EHLO mail-we0-f173.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932884AbaD2IVL (ORCPT ); Tue, 29 Apr 2014 04:21:11 -0400 Received: by mail-we0-f173.google.com with SMTP id w61so7507691wes.32 for ; Tue, 29 Apr 2014 01:21:10 -0700 (PDT) X-Received: by 10.180.90.132 with SMTP id bw4mr9378675wib.26.1398759670637; Tue, 29 Apr 2014 01:21:10 -0700 (PDT) Received: from srinivas-Inspiron-N5050.dlink.com (host-78-147-6-229.as13285.net. [78.147.6.229]) by mx.google.com with ESMTPSA id lh6sm29955866wjb.27.2014.04.29.01.21.08 for (version=TLSv1.1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Tue, 29 Apr 2014 01:21:10 -0700 (PDT) From: srinivas.kandagatla@linaro.org To: Russell King , linux-mmc@vger.kernel.org Cc: Chris Ball , Ulf Hansson , linux-kernel@vger.kernel.org, agross@quicinc.com, linux-arm-msm@vger.kernel.org, Srinivas Kandagatla Subject: [PATCH v1 10/11] mmc: mmci: Add Qcom variations to MCICommand register. Date: Tue, 29 Apr 2014 09:21:02 +0100 Message-Id: <1398759662-13381-1-git-send-email-srinivas.kandagatla@linaro.org> X-Mailer: git-send-email 1.7.9.5 In-Reply-To: <1398759492-12970-1-git-send-email-srinivas.kandagatla@linaro.org> References: <1398759492-12970-1-git-send-email-srinivas.kandagatla@linaro.org> Sender: linux-kernel-owner@vger.kernel.org Precedence: list List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-Removed-Original-Auth: Dkim didn't pass. X-Original-Sender: srinivas.kandagatla@linaro.org X-Original-Authentication-Results: mx.google.com; spf=neutral (google.com: patch+caf_=patchwork-forward=linaro.org@linaro.org does not designate permitted sender hosts) smtp.mail=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: , From: Srinivas Kandagatla Some bits which control Command Path State Machine (CPSM) are new in Qcom integration, so this patch adds support to those bits. Signed-off-by: Srinivas Kandagatla --- drivers/mmc/host/mmci.c | 4 ++++ drivers/mmc/host/mmci.h | 7 +++++++ 2 files changed, 11 insertions(+) diff --git a/drivers/mmc/host/mmci.c b/drivers/mmc/host/mmci.c index da135c0..def1b19 100644 --- a/drivers/mmc/host/mmci.c +++ b/drivers/mmc/host/mmci.c @@ -901,6 +901,10 @@ mmci_start_command(struct mmci_host *host, struct mmc_command *cmd, u32 c) if (/*interrupt*/0) c |= MCI_CPSM_INTERRUPT; + if (host->hw_designer == AMBA_VENDOR_QCOM && + mmc_cmd_type(cmd) == MMC_CMD_ADTC) + c |= MCI_CSPM_QCOM_DATCMD; + host->cmd = cmd; mmci_writel(host, cmd->arg, MMCIARGUMENT); diff --git a/drivers/mmc/host/mmci.h b/drivers/mmc/host/mmci.h index 0a6de1c..2ba0834 100644 --- a/drivers/mmc/host/mmci.h +++ b/drivers/mmc/host/mmci.h @@ -64,6 +64,13 @@ #define MCI_ST_ENCMD_COMPL (1 << 12) #define MCI_ST_NIEN (1 << 13) #define MCI_ST_CE_ATACMD (1 << 14) +/* Modified on Qualcomm Integrations */ +#define MCI_CSPM_QCOM_DATCMD (1 << 12) +#define MCI_CSPM_QCOM_MCIABORT (1 << 13) +#define MCI_CSPM_QCOM_CCSENABLE (1 << 14) +#define MCI_CSPM_QCOM_CCSDISABLE (1 << 15) +#define MCI_CSPM_QCOM_AUTO_CMD19 (1 << 16) +#define MCI_CSPM_QCOM_AUTO_CMD21 (1 << 21) #define MMCIRESPCMD 0x010 #define MMCIRESPONSE0 0x014