From patchwork Mon Jan 5 07:03:26 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Kuninori Morimoto X-Patchwork-Id: 5565231 X-Patchwork-Delegate: geert@linux-m68k.org Return-Path: X-Original-To: patchwork-linux-sh@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork1.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.136]) by patchwork1.web.kernel.org (Postfix) with ESMTP id C67F89F2ED for ; Mon, 5 Jan 2015 07:03:32 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id E2F3220145 for ; Mon, 5 Jan 2015 07:03:31 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id ED4E82015A for ; Mon, 5 Jan 2015 07:03:30 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753042AbbAEHDa (ORCPT ); Mon, 5 Jan 2015 02:03:30 -0500 Received: from relmlor2.renesas.com ([210.160.252.172]:45248 "EHLO relmlie1.idc.renesas.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1753016AbbAEHD3 (ORCPT ); Mon, 5 Jan 2015 02:03:29 -0500 Received: from unknown (HELO relmlir1.idc.renesas.com) ([10.200.68.151]) by relmlie1.idc.renesas.com with ESMTP; 05 Jan 2015 16:03:28 +0900 Received: from relmlac3.idc.renesas.com (relmlac3.idc.renesas.com [10.200.69.23]) by relmlir1.idc.renesas.com (Postfix) with ESMTP id 98536488C9; Mon, 5 Jan 2015 16:03:28 +0900 (JST) Received: by relmlac3.idc.renesas.com (Postfix, from userid 0) id 95EAF1800A; Mon, 5 Jan 2015 16:03:28 +0900 (JST) Received: from relmlac3.idc.renesas.com (localhost [127.0.0.1]) by relmlac3.idc.renesas.com (Postfix) with ESMTP id 8F15C18070; Mon, 5 Jan 2015 16:03:28 +0900 (JST) Received: from relmlii1.idc.renesas.com [10.200.68.65] by relmlac3.idc.renesas.com with ESMTP id SAB05303; Mon, 5 Jan 2015 16:03:28 +0900 X-IronPort-AV: E=Sophos;i="5.07,698,1413212400"; d="scan'208";a="176884943" Received: from mail-hk1lp0122.outbound.protection.outlook.com (HELO APAC01-HK1-obe.outbound.protection.outlook.com) ([207.46.51.122]) by relmlii1.idc.renesas.com with ESMTP/TLS/AES256-SHA; 05 Jan 2015 16:03:27 +0900 Received: from remon.renesas.com (211.11.155.132) by SINPR06MB171.apcprd06.prod.outlook.com (10.242.57.18) with Microsoft SMTP Server (TLS) id 15.1.49.12; Mon, 5 Jan 2015 07:03:26 +0000 Message-ID: <87r3v9ogin.wl%kuninori.morimoto.gx@renesas.com> From: Kuninori Morimoto Subject: [PATCH 6/9] mmc: tmio: tmio_mmc_host has .multi_io_quirk User-Agent: Wanderlust/2.14.0 Emacs/23.3 Mule/6.0 To: Ulf Hansson , Chris Ball , Simon CC: Linux-SH , linux-mmc , Kuninori Morimoto In-Reply-To: <87zj9xogln.wl%kuninori.morimoto.gx@renesas.com> References: <87zj9xogln.wl%kuninori.morimoto.gx@renesas.com> MIME-Version: 1.0 (generated by SEMI 1.14.6 - "Maruoka") Date: Mon, 5 Jan 2015 07:03:26 +0000 X-Originating-IP: [211.11.155.132] X-ClientProxiedBy: HKXPR02CA0037.apcprd02.prod.outlook.com (25.161.48.22) To SINPR06MB171.apcprd06.prod.outlook.com (10.242.57.18) Authentication-Results: spf=none (sender IP is ) smtp.mailfrom=kuninori.morimoto.gx@renesas.com; X-DmarcAction: None X-Microsoft-Antispam: UriScan:; X-Microsoft-Antispam: BCL:0;PCL:0;RULEID:(3005003);SRVR:SINPR06MB171; X-Forefront-PRVS: 0447DB1C71 X-Forefront-Antispam-Report: SFV:NSPM; SFS:(10019020)(6009001)(189002)(199003)(33646002)(83506001)(4396001)(31966008)(62966003)(87976001)(66066001)(77156002)(47776003)(64706001)(20776003)(86362001)(92566001)(19580405001)(19580395003)(46102003)(69596002)(106356001)(105586002)(81156004)(97736003)(229853001)(107046002)(122386002)(23726002)(120916001)(99396003)(101416001)(50466002)(53416004)(40100003)(42186005)(2950100001)(50986999)(46406003)(54356999)(76176999)(77096005)(68736005)(36756003)(21056001); DIR:OUT; SFP:1102; SCL:1; SRVR:SINPR06MB171; H:remon.renesas.com; FPR:; SPF:None; MLV:sfv; PTR:InfoNoRecords; MX:1; A:1; LANG:en; X-OriginatorOrg: renesas.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 05 Jan 2015 07:03:26.2514 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-Transport-CrossTenantHeadersStamped: SINPR06MB171 Sender: linux-sh-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-sh@vger.kernel.org X-Spam-Status: No, score=-6.9 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_HI, T_RP_MATCHES_RCVD, UNPARSEABLE_RELAY autolearn=ham version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP From: Kuninori Morimoto Current .multi_io_quirk is implemented under tmio_mmc_data. It goes to tmio_mmc_host by this patch. Signed-off-by: Kuninori Morimoto --- drivers/mmc/host/sh_mobile_sdhi.c | 2 +- drivers/mmc/host/tmio_mmc.h | 2 ++ drivers/mmc/host/tmio_mmc_pio.c | 5 ++--- include/linux/mfd/tmio.h | 3 --- 4 files changed, 5 insertions(+), 7 deletions(-) diff --git a/drivers/mmc/host/sh_mobile_sdhi.c b/drivers/mmc/host/sh_mobile_sdhi.c index 66951cc..79206a6 100644 --- a/drivers/mmc/host/sh_mobile_sdhi.c +++ b/drivers/mmc/host/sh_mobile_sdhi.c @@ -215,9 +215,9 @@ static int sh_mobile_sdhi_probe(struct platform_device *pdev) host->write16_hook = sh_mobile_sdhi_write16_hook; host->clk_enable = sh_mobile_sdhi_clk_enable; host->clk_disable = sh_mobile_sdhi_clk_disable; + host->multi_io_quirk = sh_mobile_sdhi_multi_io_quirk; mmc_data->capabilities = MMC_CAP_MMC_HIGHSPEED; - mmc_data->multi_io_quirk = sh_mobile_sdhi_multi_io_quirk; if (p) { mmc_data->flags = p->tmio_flags; mmc_data->ocr_mask = p->tmio_ocr_mask; diff --git a/drivers/mmc/host/tmio_mmc.h b/drivers/mmc/host/tmio_mmc.h index cdce015..c669801 100644 --- a/drivers/mmc/host/tmio_mmc.h +++ b/drivers/mmc/host/tmio_mmc.h @@ -98,6 +98,8 @@ struct tmio_mmc_host { int (*write16_hook)(struct tmio_mmc_host *host, int addr); int (*clk_enable)(struct platform_device *pdev, unsigned int *f); void (*clk_disable)(struct platform_device *pdev); + int (*multi_io_quirk)(struct mmc_card *card, + unsigned int direction, int blk_size); }; struct tmio_mmc_host* tmio_mmc_host_alloc(struct platform_device *pdev); diff --git a/drivers/mmc/host/tmio_mmc_pio.c b/drivers/mmc/host/tmio_mmc_pio.c index 84123d3..c683384 100644 --- a/drivers/mmc/host/tmio_mmc_pio.c +++ b/drivers/mmc/host/tmio_mmc_pio.c @@ -1004,10 +1004,9 @@ static int tmio_multi_io_quirk(struct mmc_card *card, unsigned int direction, int blk_size) { struct tmio_mmc_host *host = mmc_priv(card->host); - struct tmio_mmc_data *pdata = host->pdata; - if (pdata->multi_io_quirk) - return pdata->multi_io_quirk(card, direction, blk_size); + if (host->multi_io_quirk) + return host->multi_io_quirk(card, direction, blk_size); return blk_size; } diff --git a/include/linux/mfd/tmio.h b/include/linux/mfd/tmio.h index a3f78da..3edaa17 100644 --- a/include/linux/mfd/tmio.h +++ b/include/linux/mfd/tmio.h @@ -125,9 +125,6 @@ struct tmio_mmc_data { unsigned int cd_gpio; void (*set_pwr)(struct platform_device *host, int state); void (*set_clk_div)(struct platform_device *host, int state); - - int (*multi_io_quirk)(struct mmc_card *card, - unsigned int direction, int blk_size); }; /*