From patchwork Fri Sep 18 01:56:29 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Kuninori Morimoto X-Patchwork-Id: 7212381 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 6B31D9F336 for ; Fri, 18 Sep 2015 01:56:36 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 7D270206B5 for ; Fri, 18 Sep 2015 01:56:35 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 8C9D22062E for ; Fri, 18 Sep 2015 01:56:34 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752415AbbIRB4e (ORCPT ); Thu, 17 Sep 2015 21:56:34 -0400 Received: from relmlor2.renesas.com ([210.160.252.172]:38349 "EHLO relmlie1.idc.renesas.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1752043AbbIRB4d (ORCPT ); Thu, 17 Sep 2015 21:56:33 -0400 Received: from unknown (HELO relmlir3.idc.renesas.com) ([10.200.68.153]) by relmlie1.idc.renesas.com with ESMTP; 18 Sep 2015 10:56:32 +0900 Received: from relmlac3.idc.renesas.com (relmlac3.idc.renesas.com [10.200.69.23]) by relmlir3.idc.renesas.com (Postfix) with ESMTP id 5FFB5404CE; Fri, 18 Sep 2015 10:56:32 +0900 (JST) Received: by relmlac3.idc.renesas.com (Postfix, from userid 0) id 3F9461806F; Fri, 18 Sep 2015 10:56:32 +0900 (JST) Received: from relmlac3.idc.renesas.com (localhost [127.0.0.1]) by relmlac3.idc.renesas.com (Postfix) with ESMTP id 3845A1800A; Fri, 18 Sep 2015 10:56:32 +0900 (JST) Received: from relmlii2.idc.renesas.com [10.200.68.66] by relmlac3.idc.renesas.com with ESMTP id LAC19549; Fri, 18 Sep 2015 10:56:32 +0900 X-IronPort-AV: E=Sophos;i="5.17,550,1437404400"; d="scan'";a="195904304" Received: from mail-sg2apc01lp0245.outbound.protection.outlook.com (HELO APC01-SG2-obe.outbound.protection.outlook.com) ([65.55.88.245]) by relmlii2.idc.renesas.com with ESMTP/TLS/AES256-SHA; 18 Sep 2015 10:56:31 +0900 Authentication-Results: spf=none (sender IP is ) smtp.mailfrom=kuninori.morimoto.gx@renesas.com; Received: from morimoto-PC.renesas.com (211.11.155.144) by HK2PR06MB0595.apcprd06.prod.outlook.com (10.161.187.146) with Microsoft SMTP Server (TLS) id 15.1.268.17; Fri, 18 Sep 2015 01:56:29 +0000 Message-ID: <87lhc41okx.wl%kuninori.morimoto.gx@renesas.com> From: Kuninori Morimoto Subject: [PATCH 1/2 v3] i2c: rcar: add support for r8a7795 (R-Car H3) User-Agent: Wanderlust/2.15.9 Emacs/24.3 Mule/6.0 MIME-Version: 1.0 (generated by SEMI-EPG 1.14.7 - "Harue") To: Simon CC: Magnus , Linux-SH In-Reply-To: <87mvwk1om3.wl%kuninori.morimoto.gx@renesas.com> References: <87twqs1osz.wl%kuninori.morimoto.gx@renesas.com> <87mvwk1om3.wl%kuninori.morimoto.gx@renesas.com> Date: Fri, 18 Sep 2015 01:56:29 +0000 X-Originating-IP: [211.11.155.144] X-ClientProxiedBy: TY1PR01CA0006.jpnprd01.prod.outlook.com (25.161.131.144) To HK2PR06MB0595.apcprd06.prod.outlook.com (25.161.187.146) X-Microsoft-Exchange-Diagnostics: 1; HK2PR06MB0595; 2:Dx+bSSnGCOn0yyChuO4C4ocmVSZNFpj2zs7ruQFv4kuniJolw+tyFUpuk/WwiKLcPxWiKuR/gwlM9Hm8hn5P52F1vkf8MUjNcjRMV9DD7vnj5z8WSaCEF4D1nn/UB8JvMhUJ4RECdqdt5pVX21kow4GFpADi6LL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+sl/59GVq0NgI1m4BtG6ZxYxr52iLd2PU40oYn1uVlc9bVSRMUydEJPF6NYcQD/fCaZbTvAkmwO2ey0dZu1uQeBhwfF9cIYJRE0CKgIFwuhIU7JDQ7BbZsGwg9eF73/TpXFiBoxnVpYKnGXT/IJIfV54zpiXivPkya38l5hJVw1mIE2wBO5eQW3MLebw10LmD5p4USt6m7NmnO66qorAbNJ6xPr7BKqyyTWw3eFgVm3sLY6NBcBn3rxHFpZwKwOfkKama55P3hqbZAvQBXYWbes79oARlSTo1dLAEginwq2SNhrVeWBM9lpxqGmwEb1sxw== X-Microsoft-Antispam-PRVS: X-Exchange-Antispam-Report-Test: UriScan:; X-Exchange-Antispam-Report-CFA-Test: BCL:0; PCL:0; RULEID:(601004)(5005006)(8121501046)(520078)(3002001); SRVR:HK2PR06MB0595; BCL:0; PCL:0; RULEID:; SRVR:HK2PR06MB0595; X-Forefront-PRVS: 0703B549E4 X-Forefront-Antispam-Report: SFV:NSPM; SFS:(10019020)(6009001)(189002)(199003)(77156002)(5001860100001)(4001350100001)(5004730100002)(77096005)(5001830100001)(46102003)(53416004)(5001960100002)(229853001)(36756003)(110136002)(62966003)(68736005)(189998001)(23726002)(106356001)(105586002)(2950100001)(50986999)(5007970100001)(97736004)(81156007)(19580395003)(50466002)(92566002)(46406003)(76176999)(66066001)(83506001)(33646002)(4001540100001)(42186005)(69596002)(122386002)(40100003)(19580405001)(64706001)(86362001)(87976001)(47776003)(54356999)(101416001); DIR:OUT; SFP:1102; SCL:1; SRVR:HK2PR06MB0595; H:morimoto-PC.renesas.com; FPR:; SPF:None; PTR:InfoNoRecords; MX:1; A:1; LANG:en; X-Microsoft-Exchange-Diagnostics: =?us-ascii?Q?1; HK2PR06MB0595; 23:9TfgC+OVSTnk225Om2KIzdZNxRkTrTJK7vWXxFuN4?= =?us-ascii?Q?kUEq8D2ilAxLh+Lg6Gvc5+h7s04wi68653+nKOg8GmAyecMKZX8o2rVXdRQN?= =?us-ascii?Q?5jUEAy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QN8NgXW?= =?us-ascii?Q?VlmkvFeGNOJIQ4T9cj5M4q6oilbkBjCOr4bJGPyYBwAZbEha/LXakYR1aWd8?= =?us-ascii?Q?Qa7qG81gFW8AGW1qEcR0lYnabrsmESuPk1YQOpb2eMowzbfJ2geoOsYiFHhL?= =?us-ascii?Q?lIrcWbTbvWlFALlkwGC+vcDndPkh468ZtA62p9TxCsiVDIivMdpdztLzfiLI?= =?us-ascii?Q?/242J3UBYJ5s1JWgxewqIPGf+aK+BwH+JbpVKtr3TbhZCv6SnCQXDli9CIFd?= =?us-ascii?Q?oDacNp7X+KK3KRgSO4=3D?= X-Microsoft-Exchange-Diagnostics: 1; HK2PR06MB0595; 5:k7xng95Gx7V2rtvSRSNsJUHj3jSWxS2Qe1GjshWMwR0RhPbHyFzuTNX+g8PvlJroH9VZiyeEeEyNIbOv8mT3E0KRVUBxffvTkd+BJ+MVNUFowqGlKklcyzPIh62j1jDRbzsQml3HxPZnC2mnw8niYw==; 24:jL140LGlc6Gzkuk5H/QnVYXeoeQircxa4iFoxo547ANCvBmsfpIvxgvJLP4L8/Z9BN1i+lEvi5prRtv0mc/jRsASAEEcxQnc37+N+CoIABA=; 20:CulejCbUvxbkIfaHygTGVdhj2DUYfY1S2uGRZKCCt2iw+pM5qmGGMnrx5rl935YGJEUqa4CHKzutw7TLfAme0dVTDnm93KaxtGR2xOsCrUxNfEWsvbq4OGHSd66Z6PBtuZMOmox0P3mdineBREH2xfftB0SSDf660LaHDSLk6S8= SpamDiagnosticOutput: 1:23 SpamDiagnosticMetadata: NSPM X-OriginatorOrg: renesas.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 18 Sep 2015 01:56:29.9187 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-Transport-CrossTenantHeadersStamped: HK2PR06MB0595 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: Wolfram Sang Enable the I2C core for this SoC. I add a new type because this version has new features (e.g. DMA) which will be added somewhen later. Signed-off-by: Wolfram Sang Signed-off-by: Kuninori Morimoto Acked-by: Geert Uytterhoeven --- v2 -> v3 - add Geert's Acked-by Documentation/devicetree/bindings/i2c/i2c-rcar.txt | 1 + drivers/i2c/busses/i2c-rcar.c | 3 +++ 2 files changed, 4 insertions(+) diff --git a/Documentation/devicetree/bindings/i2c/i2c-rcar.txt b/Documentation/devicetree/bindings/i2c/i2c-rcar.txt index 16b3e07..ea406eb2 100644 --- a/Documentation/devicetree/bindings/i2c/i2c-rcar.txt +++ b/Documentation/devicetree/bindings/i2c/i2c-rcar.txt @@ -10,6 +10,7 @@ Required properties: "renesas,i2c-r8a7792" "renesas,i2c-r8a7793" "renesas,i2c-r8a7794" + "renesas,i2c-r8a7795" - reg: physical base address of the controller and length of memory mapped region. - interrupts: interrupt specifier. diff --git a/drivers/i2c/busses/i2c-rcar.c b/drivers/i2c/busses/i2c-rcar.c index d8361da..3e12565 100644 --- a/drivers/i2c/busses/i2c-rcar.c +++ b/drivers/i2c/busses/i2c-rcar.c @@ -103,6 +103,7 @@ enum rcar_i2c_type { I2C_RCAR_GEN1, I2C_RCAR_GEN2, + I2C_RCAR_GEN3, }; struct rcar_i2c_priv { @@ -178,6 +179,7 @@ static int rcar_i2c_clock_calculate(struct rcar_i2c_priv *priv, cdf_width = 2; break; case I2C_RCAR_GEN2: + case I2C_RCAR_GEN3: cdf_width = 3; break; default: @@ -625,6 +627,7 @@ static const struct of_device_id rcar_i2c_dt_ids[] = { { .compatible = "renesas,i2c-r8a7792", .data = (void *)I2C_RCAR_GEN2 }, { .compatible = "renesas,i2c-r8a7793", .data = (void *)I2C_RCAR_GEN2 }, { .compatible = "renesas,i2c-r8a7794", .data = (void *)I2C_RCAR_GEN2 }, + { .compatible = "renesas,i2c-r8a7795", .data = (void *)I2C_RCAR_GEN3 }, {}, }; MODULE_DEVICE_TABLE(of, rcar_i2c_dt_ids);