From patchwork Wed Jan 13 17:58:38 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Yoshihiro Kaneko X-Patchwork-Id: 8027681 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 C4A049F744 for ; Wed, 13 Jan 2016 17:59:13 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id DEC9420515 for ; Wed, 13 Jan 2016 17:59:12 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id E4D2B20513 for ; Wed, 13 Jan 2016 17:59:11 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1755488AbcAMR7L (ORCPT ); Wed, 13 Jan 2016 12:59:11 -0500 Received: from mail-pa0-f65.google.com ([209.85.220.65]:33946 "EHLO mail-pa0-f65.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1755005AbcAMR7J (ORCPT ); Wed, 13 Jan 2016 12:59:09 -0500 Received: by mail-pa0-f65.google.com with SMTP id yy13so27290268pab.1; Wed, 13 Jan 2016 09:59:09 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=from:to:cc:subject:date:message-id; bh=renaWaPnhureXPUluSUI0Z1fM2WJdjVGx/xBUaozT+I=; b=y7btzY5tPX7794idWU06yqJN35vNr3h+7fjfq6ejwW3OOChB0KuEYcgLDrarI+nYVu lII8FRCQAPKtSXFsX0Nrk/xWh1iwQxhkvPnxxZumUgdlTjqp6nFhzyJZXjizsYuVPRgN bgp1qBbyGdG89r0kKJZuwwNRzKStqA+shRVT+Fe3zxaeEqJZnyi0Dwdj0Vfh1TKyEKtQ a7nVcYwdiVyqSP1tAFJvQbuMQpgQSSD6Pgzf1om8pom8UvX546e4OKeJbKom5F+gf8lI lE5bttRne82nhGJiQWDB9eNvJ4i/6WeTqM5Mv3J2HsT/TJDEZESqQJRpIxys5IHCMTtW ytBw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:from:to:cc:subject:date:message-id; bh=renaWaPnhureXPUluSUI0Z1fM2WJdjVGx/xBUaozT+I=; b=ApJ5mx7y+ia/f4v9H0ME4i2hy6cGvlSBC2Lf/4RMZClssYJpa1GW8dMRrKi5Ncgtg5 cWvaQ/fY/7cw58ZelET48AmlqhwGUO8n8qHoHGtyT/a9iAW/UyHEDMaitHl/V9n5D388 vg1tnu5n9a1LDOfG20MWS9NSBuNrBWV2rNXRbFWiqefc/ELj7OmnUY9oZsIlHBRyIig8 ejlHn5CUpTgSSfCU3w1JRqOBMWHgfHDMerYcTiEHK9nocA2NWwggqhtPzTGp/8C3KCBD WMCjRZMrGkjrDxubYRr1mfB/6PsWrEaoebzTEOqWMnCufvU37LEqKWT9JL1rRQDU3liV RUOQ== X-Gm-Message-State: ALoCoQm575vcq3GskME29LYeis9VfoyPPWWCZiv7GRRDY2O5BAs02mJ19ubtohwDbpeHu1UDGKrVen/BWd2yECw7nbIlGpFNKQ== X-Received: by 10.66.139.234 with SMTP id rb10mr196680731pab.82.1452707949095; Wed, 13 Jan 2016 09:59:09 -0800 (PST) Received: from localhost.localdomain (KD118152108246.ppp-bb.dion.ne.jp. [118.152.108.246]) by smtp.gmail.com with ESMTPSA id 89sm2882323pfs.63.2016.01.13.09.59.07 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Wed, 13 Jan 2016 09:59:08 -0800 (PST) From: Yoshihiro Kaneko To: linux-media@vger.kernel.org Cc: Guennadi Liakhovetski , Simon Horman , Magnus Damm , linux-sh@vger.kernel.org Subject: [PATCH v3] media: soc_camera: rcar_vin: Add rcar fallback compatibility string Date: Thu, 14 Jan 2016 02:58:38 +0900 Message-Id: <1452707918-4321-1-git-send-email-ykaneko0929@gmail.com> X-Mailer: git-send-email 1.9.1 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.8 required=5.0 tests=BAYES_00, DKIM_ADSP_CUSTOM_MED, DKIM_SIGNED, FREEMAIL_FROM, RCVD_IN_DNSWL_HI, RP_MATCHES_RCVD, T_DKIM_INVALID, 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 Add fallback compatibility string for R-Car Gen2 and Gen3, This is in keeping with the fallback scheme being adopted wherever appropriate for drivers for Renesas SoCs. Signed-off-by: Yoshihiro Kaneko --- This patch is based on the for-4.6-1 branch of Guennadi's v4l-dvb tree. v3 [Yoshihiro Kaneko] * rebased to for-4.6-1 branch of Guennadi's tree. v2 [Yoshihiro Kaneko] * As suggested by Geert Uytterhoeven drivers/media/platform/soc_camera/rcar_vin.c: - The generic compatibility values are listed at the end of the rcar_vin_of_table[]. Documentation/devicetree/bindings/media/rcar_vin.txt | 8 +++++++- drivers/media/platform/soc_camera/rcar_vin.c | 2 ++ 2 files changed, 9 insertions(+), 1 deletion(-) diff --git a/Documentation/devicetree/bindings/media/rcar_vin.txt b/Documentation/devicetree/bindings/media/rcar_vin.txt index 619193c..e1a92c9 100644 --- a/Documentation/devicetree/bindings/media/rcar_vin.txt +++ b/Documentation/devicetree/bindings/media/rcar_vin.txt @@ -6,6 +6,8 @@ family of devices. The current blocks are always slaves and suppot one input channel which can be either RGB, YUYV or BT656. - compatible: Must be one of the following + - "renesas,rcar-gen2-vin" for R-Car Gen2 Series + - "renesas,rcar-gen3-vin" for R-Car Gen3 Series - "renesas,vin-r8a7795" for the R8A7795 device - "renesas,vin-r8a7794" for the R8A7794 device - "renesas,vin-r8a7793" for the R8A7793 device @@ -13,6 +15,10 @@ channel which can be either RGB, YUYV or BT656. - "renesas,vin-r8a7790" for the R8A7790 device - "renesas,vin-r8a7779" for the R8A7779 device - "renesas,vin-r8a7778" for the R8A7778 device + + When compatible with the generic version, nodes must list the SoC-specific + version corresponding to the platform first followed by the generic version. + - reg: the register base and size for the device registers - interrupts: the interrupt for the device - clocks: Reference to the parent clock @@ -37,7 +43,7 @@ Device node example }; vin0: vin@0xe6ef0000 { - compatible = "renesas,vin-r8a7790"; + compatible = "renesas,vin-r8a7790","renesas,rcar-gen2-vin"; clocks = <&mstp8_clks R8A7790_CLK_VIN0>; reg = <0 0xe6ef0000 0 0x1000>; interrupts = <0 188 IRQ_TYPE_LEVEL_HIGH>; diff --git a/drivers/media/platform/soc_camera/rcar_vin.c b/drivers/media/platform/soc_camera/rcar_vin.c index dc75a80..b72a048 100644 --- a/drivers/media/platform/soc_camera/rcar_vin.c +++ b/drivers/media/platform/soc_camera/rcar_vin.c @@ -1826,6 +1826,8 @@ static const struct of_device_id rcar_vin_of_table[] = { { .compatible = "renesas,vin-r8a7790", .data = (void *)RCAR_GEN2 }, { .compatible = "renesas,vin-r8a7779", .data = (void *)RCAR_H1 }, { .compatible = "renesas,vin-r8a7778", .data = (void *)RCAR_M1 }, + { .compatible = "renesas,rcar-gen2-vin", .data = (void *)RCAR_GEN2 }, + { .compatible = "renesas,rcar-gen3-vin", .data = (void *)RCAR_GEN3 }, { }, }; MODULE_DEVICE_TABLE(of, rcar_vin_of_table);