From patchwork Wed Jan 17 16:28:04 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Masahiro Yamada X-Patchwork-Id: 124833 Delivered-To: patch@linaro.org Received: by 10.46.62.1 with SMTP id l1csp103409lja; Wed, 17 Jan 2018 08:29:40 -0800 (PST) X-Google-Smtp-Source: ACJfBosw5aKdrVL0l0+pfh+iL6fzWlrSSxBgQOdptAeCzc5DrEw20pSaw/sYOWFJUiX9ucBWzUOt X-Received: by 10.84.242.69 with SMTP id c5mr34973995pll.358.1516206580508; Wed, 17 Jan 2018 08:29:40 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1516206580; cv=none; d=google.com; s=arc-20160816; b=dPQb/CXcJ+FCgRS7fFJ5+YozW0ueCr0KY5lGQQ1rrbqAAQKAQCwmO9/j2qtOlLAhLC rvboJsEZDM79dos/pN3vmmtidb1GL8hWnfH2d5piBlZIgBKR1CXFY4iqP2xMPBW8/N7c hrkVRQn3GxbZC6CsNij1plBIQElzebguCTeEg66HE5BJOAu37XcJkTSzHA6eJoTy7njY NAPltMKk18h3We2tUJd5g63OtlC0U1Qh85Pj18fRgo+Cp3LZNO9h9dqOFnk6K9VefSvi nhgvGtZp/J6w6XkcvsTjVxYBk3gtuCRgfNkz+Llkc3L1U2KLX3adLS21+HxcI46c8MkT ue3A== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:references:in-reply-to:message-id:date :subject:cc:to:from:dkim-signature:dkim-filter :arc-authentication-results; bh=xqFU6F7Jecy8/7Pro/S+HEUnnMh7H5gX2lu10hVBtHo=; b=Q94ajZHCp1H+09uP9OZxXNd46Bgje1vywANCm6QJNQ/0iAZtdBmcnn57wOH31zYd3P 6HPLR8jNLoaM6lWIc9hCugvc+abxcZ69Y8vOTpvgeuzsOU0osIBCuWi25afaEylDfowe +Sjoi8k1b33kLLghTwrv2sJbS9cET3oqdjntooeTpWW3jf6s2AqlSyOK8+deeEout7ys mxCPFMy3m79PZ9mXkLcd6V9XeKLTG+WOP7mUyzNnmj4nuTHz3iVoaBxvFS3G/PYCt2bX 1uOInrKXxObOWOUMnVEq/Wv+iOuaIIFj3bfTfrLifm18FpXz5BIfIYn2z+0Ma5+5x6/x BKFQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@nifty.com header.s=dec2015msa header.b=kBBcEvDN; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id b3si4562356plb.293.2018.01.17.08.29.40; Wed, 17 Jan 2018 08:29:40 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@nifty.com header.s=dec2015msa header.b=kBBcEvDN; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754070AbeAQQ3i (ORCPT + 28 others); Wed, 17 Jan 2018 11:29:38 -0500 Received: from conuserg-08.nifty.com ([210.131.2.75]:36663 "EHLO conuserg-08.nifty.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753787AbeAQQ3b (ORCPT ); Wed, 17 Jan 2018 11:29:31 -0500 Received: from grover.sesame (FL1-125-199-20-195.osk.mesh.ad.jp [125.199.20.195]) (authenticated) by conuserg-08.nifty.com with ESMTP id w0HGSIKo014790; Thu, 18 Jan 2018 01:28:22 +0900 DKIM-Filter: OpenDKIM Filter v2.10.3 conuserg-08.nifty.com w0HGSIKo014790 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=nifty.com; s=dec2015msa; t=1516206503; bh=xqFU6F7Jecy8/7Pro/S+HEUnnMh7H5gX2lu10hVBtHo=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=kBBcEvDN07OKdN1NgPxWThPuwqPUE3c+Oz9XuURtSWHxLi9lscZqe9VG5b6Spm3aT k5qSiv4AVTeyHGSHdea0lN6YDc/2CsMUolRdU4X/Q+j4yQk47FFgMej62/atbZkvEN Rv4lb0n22VZVDaVxC27HdIkp4gvHqGG3JYHVitxPUjAnKFakUAUsplqXitJIGIawIh j3c57A1HhyDhdB1ASwHI8POyppMj85ZjxIc6TWQUvkMKLPkakyXyE2Uh4FnhRNhOiF GmNU83hcdV2KP8BS1K5S3WMX/3nPQ012/h4RkGNK9ZfTuO9gXss9RwIm9JkBvxl2Xl 5M3ou6J/hmGlg== X-Nifty-SrcIP: [125.199.20.195] From: Masahiro Yamada To: linux-mmc@vger.kernel.org, Wolfram Sang Cc: Ulf Magnusson , Geert Uytterhoeven , Simon Horman , Yoshihiro Shimoda , linux-renesas-soc@vger.kernel.org, Masahiro Yamada , linux-kernel@vger.kernel.org, Ulf Hansson Subject: [PATCH v3 04/16] mmc: tmio: remove dma_ops from tmio_mmc_host_probe() argument Date: Thu, 18 Jan 2018 01:28:04 +0900 Message-Id: <1516206496-16612-5-git-send-email-yamada.masahiro@socionext.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1516206496-16612-1-git-send-email-yamada.masahiro@socionext.com> References: <1516206496-16612-1-git-send-email-yamada.masahiro@socionext.com> Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Drivers need to set up various struct members for tmio_mmc_host before calling tmio_mmc_host_probe(). Do likewise for host->dma_ops instead of passing it as a function argument. Signed-off-by: Masahiro Yamada Reviewed-by: Wolfram Sang --- Changes in v3: None Changes in v2: None drivers/mmc/host/renesas_sdhi_core.c | 3 ++- drivers/mmc/host/tmio_mmc.c | 2 +- drivers/mmc/host/tmio_mmc.h | 3 +-- drivers/mmc/host/tmio_mmc_core.c | 4 +--- 4 files changed, 5 insertions(+), 7 deletions(-) -- 2.7.4 diff --git a/drivers/mmc/host/renesas_sdhi_core.c b/drivers/mmc/host/renesas_sdhi_core.c index e18a1c5..80943fa 100644 --- a/drivers/mmc/host/renesas_sdhi_core.c +++ b/drivers/mmc/host/renesas_sdhi_core.c @@ -532,6 +532,7 @@ int renesas_sdhi_probe(struct platform_device *pdev, host->clk_update = renesas_sdhi_clk_update; host->clk_disable = renesas_sdhi_clk_disable; host->multi_io_quirk = renesas_sdhi_multi_io_quirk; + host->dma_ops = dma_ops; /* SDR speeds are only available on Gen2+ */ if (mmc_data->flags & TMIO_MMC_MIN_RCAR2) { @@ -575,7 +576,7 @@ int renesas_sdhi_probe(struct platform_device *pdev, if (ret) goto efree; - ret = tmio_mmc_host_probe(host, dma_ops); + ret = tmio_mmc_host_probe(host); if (ret < 0) goto edisclk; diff --git a/drivers/mmc/host/tmio_mmc.c b/drivers/mmc/host/tmio_mmc.c index 11b87ce..43a2ea5 100644 --- a/drivers/mmc/host/tmio_mmc.c +++ b/drivers/mmc/host/tmio_mmc.c @@ -104,7 +104,7 @@ static int tmio_mmc_probe(struct platform_device *pdev) host->mmc->f_max = pdata->hclk; host->mmc->f_min = pdata->hclk / 512; - ret = tmio_mmc_host_probe(host, NULL); + ret = tmio_mmc_host_probe(host); if (ret) goto host_free; diff --git a/drivers/mmc/host/tmio_mmc.h b/drivers/mmc/host/tmio_mmc.h index f46d282..7609434 100644 --- a/drivers/mmc/host/tmio_mmc.h +++ b/drivers/mmc/host/tmio_mmc.h @@ -198,8 +198,7 @@ struct tmio_mmc_host { struct tmio_mmc_host *tmio_mmc_host_alloc(struct platform_device *pdev, struct tmio_mmc_data *pdata); void tmio_mmc_host_free(struct tmio_mmc_host *host); -int tmio_mmc_host_probe(struct tmio_mmc_host *host, - const struct tmio_mmc_dma_ops *dma_ops); +int tmio_mmc_host_probe(struct tmio_mmc_host *host); void tmio_mmc_host_remove(struct tmio_mmc_host *host); void tmio_mmc_do_data_irq(struct tmio_mmc_host *host); diff --git a/drivers/mmc/host/tmio_mmc_core.c b/drivers/mmc/host/tmio_mmc_core.c index fc9b28d..d092b0f 100644 --- a/drivers/mmc/host/tmio_mmc_core.c +++ b/drivers/mmc/host/tmio_mmc_core.c @@ -1195,8 +1195,7 @@ void tmio_mmc_host_free(struct tmio_mmc_host *host) } EXPORT_SYMBOL_GPL(tmio_mmc_host_free); -int tmio_mmc_host_probe(struct tmio_mmc_host *_host, - const struct tmio_mmc_dma_ops *dma_ops) +int tmio_mmc_host_probe(struct tmio_mmc_host *_host) { struct platform_device *pdev = _host->pdev; struct tmio_mmc_data *pdata = _host->pdata; @@ -1296,7 +1295,6 @@ int tmio_mmc_host_probe(struct tmio_mmc_host *_host, INIT_WORK(&_host->done, tmio_mmc_done_work); /* See if we also get DMA */ - _host->dma_ops = dma_ops; tmio_mmc_request_dma(_host, pdata); pm_runtime_set_active(&pdev->dev);