From patchwork Fri Aug 9 14:16:10 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Bogdan Togorean X-Patchwork-Id: 11088553 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id C9BA4746 for ; Sat, 10 Aug 2019 13:55:34 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id B8D5022638 for ; Sat, 10 Aug 2019 13:55:34 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id ACF9E26E3C; Sat, 10 Aug 2019 13:55:34 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-5.2 required=2.0 tests=BAYES_00,MAILING_LIST_MULTI, RCVD_IN_DNSWL_MED autolearn=ham version=3.3.1 Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) (using TLSv1.2 with cipher DHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id 4136222638 for ; Sat, 10 Aug 2019 13:55:34 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id ABB586E42A; Sat, 10 Aug 2019 13:55:15 +0000 (UTC) X-Original-To: dri-devel@lists.freedesktop.org Delivered-To: dri-devel@lists.freedesktop.org Received: from mx0b-00128a01.pphosted.com (mx0b-00128a01.pphosted.com [148.163.139.77]) by gabe.freedesktop.org (Postfix) with ESMTPS id EA9576EE0F for ; Fri, 9 Aug 2019 14:17:22 +0000 (UTC) Received: from pps.filterd (m0167090.ppops.net [127.0.0.1]) by mx0b-00128a01.pphosted.com (8.16.0.27/8.16.0.27) with SMTP id x79ED7aR015334; Fri, 9 Aug 2019 10:17:08 -0400 Received: from nam05-dm3-obe.outbound.protection.outlook.com (mail-dm3nam05lp2055.outbound.protection.outlook.com [104.47.49.55]) by mx0b-00128a01.pphosted.com with ESMTP id 2u9a8wg13g-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-SHA384 bits=256 verify=NOT); Fri, 09 Aug 2019 10:17:08 -0400 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=muGhaN/UEGwYn9Euae0HT4G+wbbG7sw1zz/G6PDu4W/XtyDZa2w1hzvF7zw7CToRJj3Rkc01kDv2AMFn3+ePt/ZY5eRgf3Rq63xEqXoZtf/AxE8nvVS6YEknmfEdvSJGgs7ClCefdDrroJwR25wytifGALVJiLKqNWFGQWTy+soeZ/G6Y1VAVa/E13pVFAq2Ab/0WaH8L/cp6r5WyeCmZModuURquJ8WOXr6YT1zXyHwkPfOOl6WqKQczddqabPho3TKxVZf+5NjtJszwGi0p/OIcf42ZSaKIvgFd/LnIUTaCwQLfYWt52nCzOQEXRqzqjjIwgCeP9XeMULnYem4jQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=Hk5MOBPzXtAPzDjxEajfGt+rT/TxLRzdbikgJ1pAAr0=; b=WNfUiCiCZKxRPKVOGNXAG9JeDqGBgzXBnaNQ/hJxonTPMutjk6zARLyHHdhGqY1f/VTcRRU9QKuYmC17P6QKKSWRQRAe15/TWsg9ySmT8j22cw0Uru7IVx1AR8ZfYqfnPGGhnSbBKFY4eek8heat6czTRAW2aQJDzxB0UmnQEkz0C53cdXv67mPLgu4Gx6rqmb1YUacBdP76GjmhofHSbdaGJBFNCjexQqDlHIpftwY6c8uZNxwbXSP7b6nxnsqqppAgCYJkLa8zGV7sgG79S9WLv/v/4dSSVNvBN7h2z2aVZ30dkt2XVjbHb/CRIK2bTNXrm0aweT3ts2m14fXzRw== ARC-Authentication-Results: i=1; mx.microsoft.com 1;spf=pass (sender ip is 137.71.25.57) smtp.rcpttodomain=kernel.org smtp.mailfrom=analog.com;dmarc=bestguesspass action=none header.from=analog.com;dkim=none (message not signed);arc=none Received: from BN6PR03CA0089.namprd03.prod.outlook.com (2603:10b6:405:6f::27) by BYAPR03MB4551.namprd03.prod.outlook.com (2603:10b6:a03:cc::20) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.2115.14; Fri, 9 Aug 2019 14:17:06 +0000 Received: from SN1NAM02FT034.eop-nam02.prod.protection.outlook.com (2a01:111:f400:7e44::206) by BN6PR03CA0089.outlook.office365.com (2603:10b6:405:6f::27) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.2157.18 via Frontend Transport; Fri, 9 Aug 2019 14:17:06 +0000 Received-SPF: Pass (protection.outlook.com: domain of analog.com designates 137.71.25.57 as permitted sender) receiver=protection.outlook.com; client-ip=137.71.25.57; helo=nwd2mta2.analog.com; Received: from nwd2mta2.analog.com (137.71.25.57) by SN1NAM02FT034.mail.protection.outlook.com (10.152.72.141) with Microsoft SMTP Server (version=TLS1_0, cipher=TLS_RSA_WITH_AES_256_CBC_SHA) id 15.20.2157.15 via Frontend Transport; Fri, 9 Aug 2019 14:17:05 +0000 Received: from NWD2HUBCAS7.ad.analog.com (nwd2hubcas7.ad.analog.com [10.64.69.107]) by nwd2mta2.analog.com (8.13.8/8.13.8) with ESMTP id x79EH45S005153 (version=TLSv1/SSLv3 cipher=AES256-SHA bits=256 verify=OK); Fri, 9 Aug 2019 07:17:04 -0700 Received: from btogorean-pc.ad.analog.com (10.48.65.146) by NWD2HUBCAS7.ad.analog.com (10.64.69.107) with Microsoft SMTP Server id 14.3.408.0; Fri, 9 Aug 2019 10:17:04 -0400 From: Bogdan Togorean To: Subject: [PATCH v2 1/2] dt-bindings: drm: bridge: adv7511: Add ADV7535 support Date: Fri, 9 Aug 2019 17:16:10 +0300 Message-ID: <20190809141611.9927-2-bogdan.togorean@analog.com> X-Mailer: git-send-email 2.22.0 In-Reply-To: <20190809141611.9927-1-bogdan.togorean@analog.com> References: <20190809141611.9927-1-bogdan.togorean@analog.com> MIME-Version: 1.0 X-ADIRoutedOnPrem: True X-EOPAttributedMessage: 0 X-MS-Office365-Filtering-HT: Tenant X-Forefront-Antispam-Report: CIP:137.71.25.57; IPV:NLI; CTRY:US; EFV:NLI; SFV:NSPM; SFS:(10009020)(39860400002)(136003)(376002)(396003)(346002)(2980300002)(199004)(189003)(5660300002)(47776003)(48376002)(1076003)(316002)(107886003)(478600001)(2906002)(246002)(356004)(6666004)(36756003)(2870700001)(70206006)(70586007)(50466002)(26005)(4326008)(2351001)(6916009)(86362001)(336012)(54906003)(446003)(44832011)(476003)(106002)(76176011)(126002)(50226002)(7636002)(486006)(305945005)(7416002)(186003)(7696005)(51416003)(426003)(8936002)(8676002)(11346002)(2616005)(16060500001); DIR:OUT; SFP:1101; SCL:1; SRVR:BYAPR03MB4551; H:nwd2mta2.analog.com; FPR:; SPF:Pass; LANG:en; PTR:nwd2mail11.analog.com; A:1; MX:1; X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 2025538f-51b2-46e0-2871-08d71cd441c1 X-Microsoft-Antispam: BCL:0; PCL:0; RULEID:(2390118)(7020095)(4652040)(8989299)(4534185)(4627221)(201703031133081)(201702281549075)(8990200)(5600148)(711020)(4605104)(4709080)(1401327)(2017052603328); SRVR:BYAPR03MB4551; X-MS-TrafficTypeDiagnostic: BYAPR03MB4551: X-Microsoft-Antispam-PRVS: X-MS-Oob-TLC-OOBClassifiers: OLM:6430; X-Forefront-PRVS: 01244308DF X-MS-Exchange-SenderADCheck: 1 X-Microsoft-Antispam-Message-Info: DKBfg1E7nOP3I7FoU3FCIJksqm6G3hTNnrlfcb4KCt6oZzJ1/42LWRqBFhVJ1uRHFPKLrWyck76d8WWYcoMq8sjCA19u/xcCQYu/9x5PWVgPZciaQx6pgzOSCVm8B+kpTMrXYcAB7OAGTVntZOPf5rdEN5hDRswXY2ZBgK3M1yWrgzJt92oiPhraR3g6iiMh9no2rvLfJpZJxyWSLtQIbeDEwAOMx5u/53dv/k0jHzM4kpyVs+/QrQlEEpJShaUhhmYO/kITN50vx/Rjxg6r0b4rDhc/z5q3naQkMq+9zfo21k6ty2D8jKuQsRg2IhAyt8YPaaZzmAecl1FfskJEbZQN1r7kFp6quOJWzb08DcHzpO0SAMDD2G8PGf5YxE2SVsxCXmhk9DCzFq4uYvsslzA7nCWs88rGIHTaJ3r9EfU= X-OriginatorOrg: analog.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 09 Aug 2019 14:17:05.2772 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 2025538f-51b2-46e0-2871-08d71cd441c1 X-MS-Exchange-CrossTenant-Id: eaa689b4-8f87-40e0-9c6f-7228de4d754a X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=eaa689b4-8f87-40e0-9c6f-7228de4d754a; Ip=[137.71.25.57]; Helo=[nwd2mta2.analog.com] X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: BYAPR03MB4551 X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10434:, , definitions=2019-08-09_04:, , signatures=0 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 priorityscore=1501 malwarescore=0 suspectscore=1 phishscore=0 bulkscore=0 spamscore=0 clxscore=1015 lowpriorityscore=0 mlxscore=0 impostorscore=0 mlxlogscore=999 adultscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.0.1-1906280000 definitions=main-1908090145 X-Mailman-Approved-At: Sat, 10 Aug 2019 13:55:12 +0000 X-Mailman-Original-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=analog.onmicrosoft.com; s=selector2-analog-onmicrosoft-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=Hk5MOBPzXtAPzDjxEajfGt+rT/TxLRzdbikgJ1pAAr0=; b=QgIuNipeFmeJh/dlEkGsdiG93lcy4pn2E2SSMSLU1VaB1mFn5A3LVhp6k/drSgbhH30JstuDp+a2wglQI5+3hHXN3Qz4ku6UAz+pGryYgFjsZnG9WjC6nhPJ6ocFZGVWjApNmIChM0UrybAn4HZ9Vb2vSfYaLm5pELTji9TwNd0= X-BeenThere: dri-devel@lists.freedesktop.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: Direct Rendering Infrastructure - Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: airlied@linux.ie, gregkh@linuxfoundation.org, linux-kernel@vger.kernel.org, robh+dt@kernel.org, Laurent.pinchart@ideasonboard.com, tglx@linutronix.de, sam@ravnborg.org, matt.redfearn@thinci.com, allison@lohutok.net, Bogdan Togorean Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" X-Virus-Scanned: ClamAV using ClamSMTP ADV7535 is a part compatible with ADV7533 but it supports 1080p@60hz and v1p2 supply is fixed to 1.8V Signed-off-by: Bogdan Togorean --- .../bindings/display/bridge/adi,adv7511.txt | 23 ++++++++++--------- 1 file changed, 12 insertions(+), 11 deletions(-) diff --git a/Documentation/devicetree/bindings/display/bridge/adi,adv7511.txt b/Documentation/devicetree/bindings/display/bridge/adi,adv7511.txt index 2c887536258c..e8ddec5d9d91 100644 --- a/Documentation/devicetree/bindings/display/bridge/adi,adv7511.txt +++ b/Documentation/devicetree/bindings/display/bridge/adi,adv7511.txt @@ -1,10 +1,10 @@ -Analog Device ADV7511(W)/13/33 HDMI Encoders +Analog Device ADV7511(W)/13/33/35 HDMI Encoders ----------------------------------------- -The ADV7511, ADV7511W, ADV7513 and ADV7533 are HDMI audio and video transmitters -compatible with HDMI 1.4 and DVI 1.0. They support color space conversion, -S/PDIF, CEC and HDCP. ADV7533 supports the DSI interface for input pixels, while -the others support RGB interface. +The ADV7511, ADV7511W, ADV7513, ADV7533 and ADV7535 are HDMI audio and video +transmitters compatible with HDMI 1.4 and DVI 1.0. They support color space +conversion, S/PDIF, CEC and HDCP. ADV7533/5 supports the DSI interface for input +pixels, while the others support RGB interface. Required properties: @@ -13,6 +13,7 @@ Required properties: "adi,adv7511w" "adi,adv7513" "adi,adv7533" + "adi,adv7535" - reg: I2C slave addresses The ADV7511 internal registers are split into four pages exposed through @@ -52,14 +53,14 @@ The following input format properties are required except in "rgb 1x" and - bgvdd-supply: A 1.8V supply that powers up the BGVDD pin. This is needed only for ADV7511. -The following properties are required for ADV7533: +The following properties are required for ADV7533 and ADV7535: - adi,dsi-lanes: Number of DSI data lanes connected to the DSI host. It should be one of 1, 2, 3 or 4. - a2vdd-supply: 1.8V supply that powers up the A2VDD pin on the chip. - v3p3-supply: A 3.3V supply that powers up the V3P3 pin on the chip. - v1p2-supply: A supply that powers up the V1P2 pin on the chip. It can be - either 1.2V or 1.8V. + either 1.2V or 1.8V for ADV7533 but only 1.8V for ADV7535. Optional properties: @@ -71,9 +72,9 @@ Optional properties: - adi,embedded-sync: The input uses synchronization signals embedded in the data stream (similar to BT.656). Defaults to separate H/V synchronization signals. -- adi,disable-timing-generator: Only for ADV7533. Disables the internal timing - generator. The chip will rely on the sync signals in the DSI data lanes, - rather than generate its own timings for HDMI output. +- adi,disable-timing-generator: Only for ADV7533 and ADV7535. Disables the + internal timing generator. The chip will rely on the sync signals in the + DSI data lanes, rather than generate its own timings for HDMI output. - clocks: from common clock binding: reference to the CEC clock. - clock-names: from common clock binding: must be "cec". - reg-names : Names of maps with programmable addresses. @@ -85,7 +86,7 @@ Required nodes: The ADV7511 has two video ports. Their connections are modelled using the OF graph bindings specified in Documentation/devicetree/bindings/graph.txt. -- Video port 0 for the RGB, YUV or DSI input. In the case of ADV7533, the +- Video port 0 for the RGB, YUV or DSI input. In the case of ADV7533/5, the remote endpoint phandle should be a reference to a valid mipi_dsi_host device node. - Video port 1 for the HDMI output From patchwork Fri Aug 9 14:16:11 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Bogdan Togorean X-Patchwork-Id: 11088549 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id B2321746 for ; Sat, 10 Aug 2019 13:55:28 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id A1A3022638 for ; Sat, 10 Aug 2019 13:55:28 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 95BD326E3C; Sat, 10 Aug 2019 13:55:28 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-5.2 required=2.0 tests=BAYES_00,MAILING_LIST_MULTI, RCVD_IN_DNSWL_MED autolearn=ham version=3.3.1 Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) (using TLSv1.2 with cipher DHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id 09AB422638 for ; Sat, 10 Aug 2019 13:55:28 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id BDEE16E415; Sat, 10 Aug 2019 13:55:13 +0000 (UTC) X-Original-To: dri-devel@lists.freedesktop.org Delivered-To: dri-devel@lists.freedesktop.org Received: from mx0b-00128a01.pphosted.com (mx0b-00128a01.pphosted.com [148.163.139.77]) by gabe.freedesktop.org (Postfix) with ESMTPS id CEFFD6EE0F for ; Fri, 9 Aug 2019 14:17:21 +0000 (UTC) Received: from pps.filterd (m0167090.ppops.net [127.0.0.1]) by mx0b-00128a01.pphosted.com (8.16.0.27/8.16.0.27) with SMTP id x79ED7aT015334; Fri, 9 Aug 2019 10:17:10 -0400 Received: from nam02-sn1-obe.outbound.protection.outlook.com (mail-sn1nam02lp2052.outbound.protection.outlook.com [104.47.36.52]) by mx0b-00128a01.pphosted.com with ESMTP id 2u9a8wg13m-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-SHA384 bits=256 verify=NOT); Fri, 09 Aug 2019 10:17:10 -0400 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=e2VG7UfCYex9W0eqmIl2Zh8WJo8iPW2mnWAziziEmVYulVbNn+XVcJMkM2kq5yXhT1ejbKL0GERPCWy4X9oPonEXpJGzoRmGYtwDh8jdUUilGc/PGJv+aTylbvbxnq+AU62OZO6bbnAHzkput2iEGJinkjaYFc2koQfk97vjKfsff537Hi/91haeqvIUg3NtcEaoTvCgSMSBhzhR1/N0C9v/pu/CSE5WGRPmzOhqW7ZrwE/uKzHbldqcvnjqnFZqfAdiEQ1KuJKyFO0lRUF9FQxE9oGW/0lGM3M3ddFY/KX+cVk+3Z+oZH6SSuQoPQAUb8rJIaYgWTZN1P0bPlcrrg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=jLZNujszGpwFXLMRJwnU+KjjddsZRuRfuPLmmIk0YBs=; b=LTj4F+2/deol9UH+Lx+hL/5TXlJemhBQCWF64C/vS4XKOsSl9BRXK8nSzt0F3wsg8ciulStPJgX+1PpGyaeydhCjCbYzmT74k4q0apPOM0yKZcCLqssQrPaYI+wBRoGDsdTNBu7NdELqoWKWTNP57CSGdq8Iagyka7u5H3XRafdPFNrbR3YPaab0zfDQD+nzTFvC9yRixzBIDmhI6+HFflrset7S5PS236BtVKTcWPQBPGRfW7NzyZDhCm+f6xtb70trGL3iWLAm+OrblVHnETJ16gvWDfKdD4SQQ46xclTMmic8+Uz1IY2JYzmWvIXvwHbqc+HNf3qKov1i2+JW6w== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass (sender ip is 137.71.25.57) smtp.rcpttodomain=kernel.org smtp.mailfrom=analog.com; dmarc=bestguesspass action=none header.from=analog.com; dkim=none (message not signed); arc=none Received: from DM3PR03CA0011.namprd03.prod.outlook.com (2603:10b6:0:50::21) by BN7PR03MB4354.namprd03.prod.outlook.com (2603:10b6:408:3c::25) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.2157.14; Fri, 9 Aug 2019 14:17:08 +0000 Received: from BL2NAM02FT006.eop-nam02.prod.protection.outlook.com (2a01:111:f400:7e46::207) by DM3PR03CA0011.outlook.office365.com (2603:10b6:0:50::21) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.2157.18 via Frontend Transport; Fri, 9 Aug 2019 14:17:08 +0000 Received-SPF: Pass (protection.outlook.com: domain of analog.com designates 137.71.25.57 as permitted sender) receiver=protection.outlook.com; client-ip=137.71.25.57; helo=nwd2mta2.analog.com; Received: from nwd2mta2.analog.com (137.71.25.57) by BL2NAM02FT006.mail.protection.outlook.com (10.152.76.239) with Microsoft SMTP Server (version=TLS1_0, cipher=TLS_RSA_WITH_AES_256_CBC_SHA) id 15.20.2157.15 via Frontend Transport; Fri, 9 Aug 2019 14:17:08 +0000 Received: from NWD2HUBCAS7.ad.analog.com (nwd2hubcas7.ad.analog.com [10.64.69.107]) by nwd2mta2.analog.com (8.13.8/8.13.8) with ESMTP id x79EH7hS005163 (version=TLSv1/SSLv3 cipher=AES256-SHA bits=256 verify=OK); Fri, 9 Aug 2019 07:17:07 -0700 Received: from btogorean-pc.ad.analog.com (10.48.65.146) by NWD2HUBCAS7.ad.analog.com (10.64.69.107) with Microsoft SMTP Server id 14.3.408.0; Fri, 9 Aug 2019 10:17:07 -0400 From: Bogdan Togorean To: Subject: [PATCH v2 2/2] drm: bridge: adv7511: Add support for ADV7535 Date: Fri, 9 Aug 2019 17:16:11 +0300 Message-ID: <20190809141611.9927-3-bogdan.togorean@analog.com> X-Mailer: git-send-email 2.22.0 In-Reply-To: <20190809141611.9927-1-bogdan.togorean@analog.com> References: <20190809141611.9927-1-bogdan.togorean@analog.com> MIME-Version: 1.0 X-ADIRoutedOnPrem: True X-EOPAttributedMessage: 0 X-MS-Office365-Filtering-HT: Tenant X-Forefront-Antispam-Report: CIP:137.71.25.57; IPV:NLI; CTRY:US; EFV:NLI; SFV:NSPM; SFS:(10009020)(136003)(376002)(346002)(396003)(39860400002)(2980300002)(189003)(199004)(316002)(51416003)(4326008)(2351001)(7696005)(50226002)(7636002)(7416002)(8936002)(106002)(50466002)(478600001)(86362001)(48376002)(5660300002)(70586007)(70206006)(305945005)(2616005)(54906003)(126002)(246002)(476003)(47776003)(1076003)(8676002)(336012)(44832011)(2870700001)(6916009)(14444005)(36756003)(5024004)(2906002)(186003)(446003)(26005)(11346002)(486006)(426003)(356004)(107886003)(6666004)(76176011)(16060500001); DIR:OUT; SFP:1101; SCL:1; SRVR:BN7PR03MB4354; H:nwd2mta2.analog.com; FPR:; SPF:Pass; LANG:en; PTR:nwd2mail11.analog.com; MX:1; A:1; X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 074315b7-17f7-430a-68d3-08d71cd44352 X-Microsoft-Antispam: BCL:0; PCL:0; RULEID:(2390118)(7020095)(4652040)(8989299)(4534185)(4627221)(201703031133081)(201702281549075)(8990200)(5600148)(711020)(4605104)(4709080)(1401327)(2017052603328); SRVR:BN7PR03MB4354; X-MS-TrafficTypeDiagnostic: BN7PR03MB4354: X-Microsoft-Antispam-PRVS: X-MS-Oob-TLC-OOBClassifiers: OLM:8882; X-Forefront-PRVS: 01244308DF X-MS-Exchange-SenderADCheck: 1 X-Microsoft-Antispam-Message-Info: Lwzgkgc+4HXKDlCWzln0M+fMwF8IkKFurCfwggUuzu89LCusk/B5QdwdadirOaSUri8Q2G77s86u+RIzknXtIofMwuzA8mxxpD6LqHDh5x+hOGCFRctTWVDhgYK3B8+I/2fXX1y13v0h+bmoVC7EsfbU7GVgQKCFb61IAwKLboMwF2FXqYyZGhHhhMdLB2oqD3suICHx+1R2MwawoxZez0XkIUKaD9cpdFHTs6tjdOFdhom3BFcmFx/NBrEPVADEvLFY2U1TT9m8ZfDDdTCLFzdnU6Kg8ThCw7KN/UnGPIxKzA3FBV0rTi06eBxAWAHXpHA7LchBMD9VcFntFGbFaFwKDbgbRIK/0W8jo8Mr0KYXXokHLevVhd8zWzWIB4kpcwzSL1PoQqw+BZrYXvW9K/2uXugKNEQnX1Ci0Pyp5cw= X-OriginatorOrg: analog.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 09 Aug 2019 14:17:08.3362 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 074315b7-17f7-430a-68d3-08d71cd44352 X-MS-Exchange-CrossTenant-Id: eaa689b4-8f87-40e0-9c6f-7228de4d754a X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=eaa689b4-8f87-40e0-9c6f-7228de4d754a; Ip=[137.71.25.57]; Helo=[nwd2mta2.analog.com] X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: BN7PR03MB4354 X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10434:, , definitions=2019-08-09_04:, , signatures=0 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 priorityscore=1501 malwarescore=0 suspectscore=1 phishscore=0 bulkscore=0 spamscore=0 clxscore=1015 lowpriorityscore=0 mlxscore=0 impostorscore=0 mlxlogscore=999 adultscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.0.1-1906280000 definitions=main-1908090145 X-Mailman-Approved-At: Sat, 10 Aug 2019 13:55:12 +0000 X-Mailman-Original-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=analog.onmicrosoft.com; s=selector2-analog-onmicrosoft-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=jLZNujszGpwFXLMRJwnU+KjjddsZRuRfuPLmmIk0YBs=; b=VJVdzO7QwBFa+e3lN08yuAcYciJTIaYtEY4ol9KoqoQdcfe1RnN4tUTdEZmy2jitLbFEBMWh8tDp2+rH57uCtKCPJ49NWt53q9RS1U1qtzr9+gPEBQJ51cYEC0lqvCHkpSQT4hC0UScCjz3htfvdsOEsZW1O7spwA9LRUwOU1SY= X-BeenThere: dri-devel@lists.freedesktop.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: Direct Rendering Infrastructure - Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: airlied@linux.ie, gregkh@linuxfoundation.org, linux-kernel@vger.kernel.org, robh+dt@kernel.org, Laurent.pinchart@ideasonboard.com, tglx@linutronix.de, sam@ravnborg.org, matt.redfearn@thinci.com, allison@lohutok.net, Bogdan Togorean Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" X-Virus-Scanned: ClamAV using ClamSMTP ADV7535 is a DSI to HDMI bridge chip like ADV7533 but it allows 1080p@60Hz. v1p2 is fixed to 1.8V on ADV7535 but on ADV7533 can be 1.2V or 1.8V and is configurable in a register. Signed-off-by: Bogdan Togorean --- drivers/gpu/drm/bridge/adv7511/Kconfig | 8 ++--- drivers/gpu/drm/bridge/adv7511/Makefile | 2 +- drivers/gpu/drm/bridge/adv7511/adv7511.h | 4 ++- drivers/gpu/drm/bridge/adv7511/adv7511_drv.c | 34 ++++++++++++++------ 4 files changed, 32 insertions(+), 16 deletions(-) diff --git a/drivers/gpu/drm/bridge/adv7511/Kconfig b/drivers/gpu/drm/bridge/adv7511/Kconfig index 8a56ff81f4fb..fa43acd46ab7 100644 --- a/drivers/gpu/drm/bridge/adv7511/Kconfig +++ b/drivers/gpu/drm/bridge/adv7511/Kconfig @@ -15,16 +15,16 @@ config DRM_I2C_ADV7511_AUDIO Support the ADV7511 HDMI Audio interface. This is used in conjunction with the AV7511 HDMI driver. -config DRM_I2C_ADV7533 - bool "ADV7533 encoder" +config DRM_I2C_ADV753x + bool "ADV753x encoder" depends on DRM_I2C_ADV7511 select DRM_MIPI_DSI default y help - Support for the Analog Devices ADV7533 DSI to HDMI encoder. + Support for the Analog Devices ADV7533/5 DSI to HDMI encoder. config DRM_I2C_ADV7511_CEC - bool "ADV7511/33 HDMI CEC driver" + bool "ADV7511/33/35 HDMI CEC driver" depends on DRM_I2C_ADV7511 select CEC_CORE default y diff --git a/drivers/gpu/drm/bridge/adv7511/Makefile b/drivers/gpu/drm/bridge/adv7511/Makefile index b46ebeb35fd4..319efddb268e 100644 --- a/drivers/gpu/drm/bridge/adv7511/Makefile +++ b/drivers/gpu/drm/bridge/adv7511/Makefile @@ -2,5 +2,5 @@ adv7511-y := adv7511_drv.o adv7511-$(CONFIG_DRM_I2C_ADV7511_AUDIO) += adv7511_audio.o adv7511-$(CONFIG_DRM_I2C_ADV7511_CEC) += adv7511_cec.o -adv7511-$(CONFIG_DRM_I2C_ADV7533) += adv7533.o +adv7511-$(CONFIG_DRM_I2C_ADV753x) += adv7533.o obj-$(CONFIG_DRM_I2C_ADV7511) += adv7511.o diff --git a/drivers/gpu/drm/bridge/adv7511/adv7511.h b/drivers/gpu/drm/bridge/adv7511/adv7511.h index 52b2adfdc877..38288c3c3c53 100644 --- a/drivers/gpu/drm/bridge/adv7511/adv7511.h +++ b/drivers/gpu/drm/bridge/adv7511/adv7511.h @@ -91,6 +91,7 @@ #define ADV7511_REG_ARC_CTRL 0xdf #define ADV7511_REG_CEC_I2C_ADDR 0xe1 #define ADV7511_REG_CEC_CTRL 0xe2 +#define ADV7511_REG_SUPPLY_SELECT 0xe4 #define ADV7511_REG_CHIP_ID_HIGH 0xf5 #define ADV7511_REG_CHIP_ID_LOW 0xf6 @@ -320,6 +321,7 @@ struct adv7511_video_config { enum adv7511_type { ADV7511, ADV7533, + ADV7535, }; #define ADV7511_MAX_ADDRS 3 @@ -393,7 +395,7 @@ static inline int adv7511_cec_init(struct device *dev, struct adv7511 *adv7511) } #endif -#ifdef CONFIG_DRM_I2C_ADV7533 +#ifdef CONFIG_DRM_I2C_ADV753x void adv7533_dsi_power_on(struct adv7511 *adv); void adv7533_dsi_power_off(struct adv7511 *adv); void adv7533_mode_set(struct adv7511 *adv, const struct drm_display_mode *mode); diff --git a/drivers/gpu/drm/bridge/adv7511/adv7511_drv.c b/drivers/gpu/drm/bridge/adv7511/adv7511_drv.c index f6d2681f6927..b1501344df3e 100644 --- a/drivers/gpu/drm/bridge/adv7511/adv7511_drv.c +++ b/drivers/gpu/drm/bridge/adv7511/adv7511_drv.c @@ -367,7 +367,7 @@ static void adv7511_power_on(struct adv7511 *adv7511) */ regcache_sync(adv7511->regmap); - if (adv7511->type == ADV7533) + if (adv7511->type == ADV7533 || adv7511->type == ADV7535) adv7533_dsi_power_on(adv7511); adv7511->powered = true; } @@ -387,7 +387,7 @@ static void __adv7511_power_off(struct adv7511 *adv7511) static void adv7511_power_off(struct adv7511 *adv7511) { __adv7511_power_off(adv7511); - if (adv7511->type == ADV7533) + if (adv7511->type == ADV7533 || adv7511->type == ADV7535) adv7533_dsi_power_off(adv7511); adv7511->powered = false; } @@ -761,7 +761,7 @@ static void adv7511_mode_set(struct adv7511 *adv7511, regmap_update_bits(adv7511->regmap, 0x17, 0x60, (vsync_polarity << 6) | (hsync_polarity << 5)); - if (adv7511->type == ADV7533) + if (adv7511->type == ADV7533 || adv7511->type == ADV7535) adv7533_mode_set(adv7511, adj_mode); drm_mode_copy(&adv7511->curr_mode, adj_mode); @@ -874,7 +874,7 @@ static int adv7511_bridge_attach(struct drm_bridge *bridge) &adv7511_connector_helper_funcs); drm_connector_attach_encoder(&adv->connector, bridge->encoder); - if (adv->type == ADV7533) + if (adv->type == ADV7533 || adv->type == ADV7535) ret = adv7533_attach_dsi(adv); if (adv->i2c_main->irq) @@ -903,6 +903,7 @@ static const char * const adv7511_supply_names[] = { "dvdd-3v", }; +/* The order of entries is important. If changed update hardcoded indices */ static const char * const adv7533_supply_names[] = { "avdd", "dvdd", @@ -952,7 +953,7 @@ static bool adv7511_cec_register_volatile(struct device *dev, unsigned int reg) struct i2c_client *i2c = to_i2c_client(dev); struct adv7511 *adv7511 = i2c_get_clientdata(i2c); - if (adv7511->type == ADV7533) + if (adv7511->type == ADV7533 || adv7511->type == ADV7535) reg -= ADV7533_REG_CEC_OFFSET; switch (reg) { @@ -994,7 +995,7 @@ static int adv7511_init_cec_regmap(struct adv7511 *adv) goto err; } - if (adv->type == ADV7533) { + if (adv->type == ADV7533 || adv->type == ADV7535) { ret = adv7533_patch_cec_registers(adv); if (ret) goto err; @@ -1094,8 +1095,9 @@ static int adv7511_probe(struct i2c_client *i2c, const struct i2c_device_id *id) struct adv7511_link_config link_config; struct adv7511 *adv7511; struct device *dev = &i2c->dev; + struct regulator *reg_v1p2; unsigned int val; - int ret; + int ret, reg_v1p2_uV; if (!dev->of_node) return -EINVAL; @@ -1163,6 +1165,16 @@ static int adv7511_probe(struct i2c_client *i2c, const struct i2c_device_id *id) if (ret) goto uninit_regulators; + if (adv7511->type == ADV7533) { + reg_v1p2 = adv7511->supplies[5].consumer; + reg_v1p2_uV = regulator_get_voltage(reg_v1p2); + + if (reg_v1p2_uV == 1200000) { + regmap_update_bits(adv7511->regmap, + ADV7511_REG_SUPPLY_SELECT, 0x80, 0x80); + } + } + adv7511_packet_disable(adv7511, 0xffff); adv7511->i2c_edid = i2c_new_secondary_device(i2c, "edid", @@ -1242,7 +1254,7 @@ static int adv7511_remove(struct i2c_client *i2c) { struct adv7511 *adv7511 = i2c_get_clientdata(i2c); - if (adv7511->type == ADV7533) + if (adv7511->type == ADV7533 || adv7511->type == ADV7535) adv7533_detach_dsi(adv7511); i2c_unregister_device(adv7511->i2c_cec); if (adv7511->cec_clk) @@ -1266,8 +1278,9 @@ static const struct i2c_device_id adv7511_i2c_ids[] = { { "adv7511", ADV7511 }, { "adv7511w", ADV7511 }, { "adv7513", ADV7511 }, -#ifdef CONFIG_DRM_I2C_ADV7533 +#ifdef CONFIG_DRM_I2C_ADV753x { "adv7533", ADV7533 }, + { "adv7535", ADV7535 }, #endif { } }; @@ -1277,8 +1290,9 @@ static const struct of_device_id adv7511_of_ids[] = { { .compatible = "adi,adv7511", .data = (void *)ADV7511 }, { .compatible = "adi,adv7511w", .data = (void *)ADV7511 }, { .compatible = "adi,adv7513", .data = (void *)ADV7511 }, -#ifdef CONFIG_DRM_I2C_ADV7533 +#ifdef CONFIG_DRM_I2C_ADV753x { .compatible = "adi,adv7533", .data = (void *)ADV7533 }, + { .compatible = "adi,adv7535", .data = (void *)ADV7535 }, #endif { } };