From patchwork Wed Jul 8 06:59:21 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Vinod Koul X-Patchwork-Id: 235035 Delivered-To: patch@linaro.org Received: by 2002:a92:d244:0:0:0:0:0 with SMTP id v4csp172635ilg; Tue, 7 Jul 2020 23:59:52 -0700 (PDT) X-Google-Smtp-Source: ABdhPJy1ArVktM+qfy1SfP0s5PxLUSbyVwuyx83ejjL4le+CkSAoZyfg4NxJUnfiS13EgQhunlGW X-Received: by 2002:aa7:d297:: with SMTP id w23mr62842625edq.49.1594191591973; Tue, 07 Jul 2020 23:59:51 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1594191591; cv=none; d=google.com; s=arc-20160816; b=CKQvWSDbxqjhsWqnzzs2lWzKK3rsJtp6tJhFFJfjKASiVNW3buyDWtma0zzzTchdRN gT168fwzTsgvhfZM8GsM4+QBl4GwBSrN249qPVfFLWQIK1mfFKQ2ctcXsE9m2tueWRs+ s2gD7ObNO2PmFAVn+d3mVtbK/Ed6e9zy+moj1xOHlbjSWBRCmn+StVia5GI2x9POQh3U M8t+DSYZHRpvLYmfD5sYBk6n7u8JtS5bvMqJrA6VzrTJ8LzQoQLHSR/KP4aYoTyiOkZb DQuF9PFdgVRJ4fstd+8v7UzV7yy8rHFLbKJS8NMFyan6lYHXr6xZe2UFyGFTtfMq2Zcl bb7g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=LcR4fsQv2xFO2CNaJrgucsoTJIO5W8Iml6EKBuxDPS4=; b=hUXUqbdKsgWChHAdBFFVIHg8Kf5a4jsIgP6wNGJ8wn5VWRNqYPyrwwPIwBzkTnbwvn SaUUEPAZ7GcNQvTWqiycQWuB5XMDhBSk5FSizwX0I4KHSTMzZQRGtZ0b2UzDU/wZtbWM cyAifYilb3qDcTFvl8OEUmpCvDpvQvBexXeaSme4S0orLjcLZ+Bgbq7nrNHKu8jJSZ4l d+koI1GN5FWuvSXKu+oB5erye/GuFCr2aRh5JeZFdshgM5saa/94HVwWMht/Rzi6tCsk 9t/klOqVgW7gRI52jNirJS2Y1XjdbR1lkfrLbXIMxVXHd3j5gv8j9G9IVEmr9TezxJ2k bVFg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=2c6rlAG0; spf=pass (google.com: domain of devicetree-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=devicetree-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id v11si9659807edr.331.2020.07.07.23.59.51; Tue, 07 Jul 2020 23:59:51 -0700 (PDT) Received-SPF: pass (google.com: domain of devicetree-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=2c6rlAG0; spf=pass (google.com: domain of devicetree-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=devicetree-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729905AbgGHG7v (ORCPT + 6 others); Wed, 8 Jul 2020 02:59:51 -0400 Received: from mail.kernel.org ([198.145.29.99]:35202 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726194AbgGHG7v (ORCPT ); Wed, 8 Jul 2020 02:59:51 -0400 Received: from localhost.localdomain (unknown [122.182.251.219]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 72C5720773; Wed, 8 Jul 2020 06:59:44 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1594191590; bh=j4EX+FYYMmUL3lz0Sf39rotA7d7j4vro6NAbsWtYLko=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=2c6rlAG0ooqBZhGzD1eIyXOhCS9GBsXPmPraJWzk10ez/D1yWE11CWBR5KbaMe/Kt LbB2MJQX0S+bug3IcR1Wx+xBKJ2U1Am17Zv/VpeIquhmweHaWPR6bEUA6z3EqwZeB2 mK8Lelu5muIKSrVJbX8tspdXbOSXLFMq5kQDbtiY= From: Vinod Koul To: Daniel Vetter , David Airlie , Rob Clark Cc: linux-arm-msm@vger.kernel.org, Bjorn Andersson , Vinod Koul , Andrzej Hajda , Neil Armstrong , Laurent Pinchart , Jonas Karlman , Jernej Skrabec , Rob Herring , devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, dri-devel@lists.freedesktop.org, Emil Velikov , Sam Ravnborg , Rob Herring , John Stultz Subject: [PATCH v4 1/4] dt-bindings: vendor-prefixes: Add Lontium vendor prefix Date: Wed, 8 Jul 2020 12:29:21 +0530 Message-Id: <20200708065924.59257-2-vkoul@kernel.org> X-Mailer: git-send-email 2.26.2 In-Reply-To: <20200708065924.59257-1-vkoul@kernel.org> References: <20200708065924.59257-1-vkoul@kernel.org> MIME-Version: 1.0 Sender: devicetree-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: devicetree@vger.kernel.org Add prefix for Lontium Semiconductor Corporation Acked-by: Rob Herring Tested-by: John Stultz Signed-off-by: Vinod Koul --- Documentation/devicetree/bindings/vendor-prefixes.yaml | 2 ++ 1 file changed, 2 insertions(+) -- 2.26.2 diff --git a/Documentation/devicetree/bindings/vendor-prefixes.yaml b/Documentation/devicetree/bindings/vendor-prefixes.yaml index 9aeab66be85f..31cdb21a3d22 100644 --- a/Documentation/devicetree/bindings/vendor-prefixes.yaml +++ b/Documentation/devicetree/bindings/vendor-prefixes.yaml @@ -595,6 +595,8 @@ patternProperties: description: Logic Technologies Limited "^longcheer,.*": description: Longcheer Technology (Shanghai) Co., Ltd. + "^lontium,.*": + description: Lontium Semiconductor Corporation "^loongson,.*": description: Loongson Technology Corporation Limited "^lsi,.*": From patchwork Wed Jul 8 06:59:22 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Vinod Koul X-Patchwork-Id: 235036 Delivered-To: patch@linaro.org Received: by 2002:a92:d244:0:0:0:0:0 with SMTP id v4csp172701ilg; Tue, 7 Jul 2020 23:59:59 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwhJU+DTx/XADf67+QOVpMPRp+1k2ZJ1EsH/E7fSiki8YpCJFvFHs8U8wGU+X3o35RMP4QR X-Received: by 2002:a05:6402:3058:: with SMTP id bu24mr47329964edb.242.1594191599686; Tue, 07 Jul 2020 23:59:59 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1594191599; cv=none; d=google.com; s=arc-20160816; b=iMAf9l/QIUSw5EyV+5V1CEOgxVMQ76AjbbMDTE9yvGPv1QkOcX4wE30fYljL+Od+TL b2p17/7813mbRT+Aechofz6glmtJ63oRjd8Uyi0nu5bgBej+zbDVWjxRSScP9h5YbRnf /Tqodd/MEGxS3gUoq2Wbw0bw9yARLFwhZvM8tSRjoJh84IhSDFLhEgoV54QfxYBjdUD2 5tH1tFq4vVNe+0wWxQpOQBCcQORZi6iITwraUdqLO4wRbmZFGAkr/fHNuqPMMna/0pUx X64zS0jYB0bmOlL1qXobQNO/IXK3pxw3zVm7sq48xVxiBuzpIRQR0j6U4D4dxaxzYpOf ly8Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=F7uz1Vaa6VZVdnQs66o7GgnTBnECZ8cG1uECJkFNj1U=; b=GqF7W1qYaNPt5ybb8HZe/xt30NlikzsBcXiKTIL8xBXQCWW/h0SFpcelV9gCnt9P2b 7UbtKexRPJ+vBsodEoWhCAfDPbK9jrlfH/6GHcwzzBV4nERm7M40awgBISiFHcSuKRkQ 0Vah1v0aXp/zfzRoqupg9Go3EQF6D3+dl0bDUqK12310Wz+laP5pDejCMQbuAPR1t/QJ NTi35vwnGq9Y/VnILPRHNZRrW+4X0RXsl+vfV4Mp/+U2jSB6CsdyHXBl2uXQUXfv8Z56 HGAe8l/Pt94uTw9F8GDbT8xpwGuSjpZdUP4KEsjdvm7xBACUXcvBDJWwd97RQF5Hpj4q TRNw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=VEwB3wC3; spf=pass (google.com: domain of devicetree-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=devicetree-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id c17si17017097edr.237.2020.07.07.23.59.59; Tue, 07 Jul 2020 23:59:59 -0700 (PDT) Received-SPF: pass (google.com: domain of devicetree-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=VEwB3wC3; spf=pass (google.com: domain of devicetree-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=devicetree-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729947AbgGHG77 (ORCPT + 6 others); Wed, 8 Jul 2020 02:59:59 -0400 Received: from mail.kernel.org ([198.145.29.99]:35440 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726194AbgGHG76 (ORCPT ); Wed, 8 Jul 2020 02:59:58 -0400 Received: from localhost.localdomain (unknown [122.182.251.219]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 82DC22075B; Wed, 8 Jul 2020 06:59:51 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1594191597; bh=pH9hCqHfdlU+w6Ab8i9hBud2GdbD3VXacsj5zyagtEA=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=VEwB3wC3ugbPvMrlH8chv3kwNGZtAFl+rA/nasLgzB4RQv1n9Zup2+2Mwxt6BztS4 9LvQ4t+rXLO0ZM68bddWE6Uk9ZfmZm4uY/3y6abKNH95nSSiv+sqKMO1qxBve0edsl 6v1n/dJfpfl8VlQf2UczKNqD4jVNl+If2N3Mostc= From: Vinod Koul To: Daniel Vetter , David Airlie , Rob Clark Cc: linux-arm-msm@vger.kernel.org, Bjorn Andersson , Vinod Koul , Andrzej Hajda , Neil Armstrong , Laurent Pinchart , Jonas Karlman , Jernej Skrabec , Rob Herring , devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, dri-devel@lists.freedesktop.org, Emil Velikov , Sam Ravnborg , Rob Herring , John Stultz Subject: [PATCH v4 2/4] dt-bindings: display: bridge: Add documentation for LT9611 Date: Wed, 8 Jul 2020 12:29:22 +0530 Message-Id: <20200708065924.59257-3-vkoul@kernel.org> X-Mailer: git-send-email 2.26.2 In-Reply-To: <20200708065924.59257-1-vkoul@kernel.org> References: <20200708065924.59257-1-vkoul@kernel.org> MIME-Version: 1.0 Sender: devicetree-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: devicetree@vger.kernel.org Lontium LT9611 is a DSI to HDMI bridge which supports 2 DSI ports and I2S port as input and one HDMI port as output Reviewed-by: Rob Herring Tested-by: John Stultz Signed-off-by: Vinod Koul --- .../display/bridge/lontium,lt9611.yaml | 176 ++++++++++++++++++ 1 file changed, 176 insertions(+) create mode 100644 Documentation/devicetree/bindings/display/bridge/lontium,lt9611.yaml -- 2.26.2 diff --git a/Documentation/devicetree/bindings/display/bridge/lontium,lt9611.yaml b/Documentation/devicetree/bindings/display/bridge/lontium,lt9611.yaml new file mode 100644 index 000000000000..d60208359234 --- /dev/null +++ b/Documentation/devicetree/bindings/display/bridge/lontium,lt9611.yaml @@ -0,0 +1,176 @@ +# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) +%YAML 1.2 +--- +$id: http://devicetree.org/schemas/display/bridge/lontium,lt9611.yaml# +$schema: http://devicetree.org/meta-schemas/core.yaml# + +title: Lontium LT9611 2 Port MIPI to HDMI Bridge + +maintainers: + - Vinod Koul + +description: | + The LT9611 is a bridge device which converts DSI to HDMI + +properties: + compatible: + enum: + - lontium,lt9611 + + reg: + maxItems: 1 + + "#sound-dai-cells": + const: 1 + + interrupts: + maxItems: 1 + + reset-gpios: + maxItems: 1 + description: GPIO connected to active high RESET pin. + + vdd-supply: + description: Regulator for 1.8V MIPI phy power. + + vcc-supply: + description: Regulator for 3.3V IO power. + + ports: + type: object + + properties: + "#address-cells": + const: 1 + + "#size-cells": + const: 0 + + port@0: + type: object + description: | + Primary MIPI port-1 for MIPI input + + properties: + reg: + const: 0 + + patternProperties: + "^endpoint(@[0-9])$": + type: object + additionalProperties: false + + properties: + remote-endpoint: + $ref: /schemas/types.yaml#/definitions/phandle + + required: + - reg + + port@1: + type: object + description: | + Additional MIPI port-2 for MIPI input, used in combination + with primary MIPI port-1 to drive higher resolution displays + + properties: + reg: + const: 1 + + patternProperties: + "^endpoint(@[0-9])$": + type: object + additionalProperties: false + + properties: + remote-endpoint: + $ref: /schemas/types.yaml#/definitions/phandle + + required: + - reg + + port@2: + type: object + description: | + HDMI port for HDMI output + + properties: + reg: + const: 2 + + patternProperties: + "^endpoint(@[0-9])$": + type: object + additionalProperties: false + + properties: + remote-endpoint: + $ref: /schemas/types.yaml#/definitions/phandle + + required: + - reg + + required: + - "#address-cells" + - "#size-cells" + - port@0 + - port@2 + +required: + - compatible + - reg + - interrupts + - vdd-supply + - vcc-supply + - ports + +additionalProperties: false + +examples: + - | + #include + #include + + i2c10 { + #address-cells = <1>; + #size-cells = <0>; + + hdmi-bridge@3b { + compatible = "lontium,lt9611"; + reg = <0x3b>; + + reset-gpios = <&tlmm 128 GPIO_ACTIVE_HIGH>; + interrupts-extended = <&tlmm 84 IRQ_TYPE_EDGE_FALLING>; + + vdd-supply = <<9611_1v8>; + vcc-supply = <<9611_3v3>; + + ports { + #address-cells = <1>; + #size-cells = <0>; + + port@0 { + reg = <0>; + lt9611_a: endpoint { + remote-endpoint = <&dsi0_out>; + }; + }; + + port@1 { + reg = <1>; + lt9611_b: endpoint { + remote-endpoint = <&dsi1_out>; + }; + }; + + port@2 { + reg = <2>; + lt9611_out: endpoint { + remote-endpoint = <&hdmi_con>; + }; + }; + }; + }; + }; + +... From patchwork Wed Jul 8 06:59:24 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Vinod Koul X-Patchwork-Id: 235038 Delivered-To: patch@linaro.org Received: by 2002:a92:d244:0:0:0:0:0 with SMTP id v4csp172839ilg; Wed, 8 Jul 2020 00:00:15 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwXhJ7rR5zg2mdFue9bdoXUwr6Iji9qz9xFdH2KgG8odyCZS0lK5AaqV6J/htYl9yx1NrOb X-Received: by 2002:a05:6402:31ad:: with SMTP id dj13mr22494831edb.88.1594191615097; Wed, 08 Jul 2020 00:00:15 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1594191615; cv=none; d=google.com; s=arc-20160816; b=NADvDbe2P4Mi8uDwTrQIm/y6xcO10ybUJMXnEx7fBvMDmXUm9I+mSUvIMlY+Y5wKML v7hlHaZgtmgQsdcweyreexCpVc5f0saJg66iuNsr+vZa74kuip/IwJ/vxLrjxzjp+V1G ED6tzzBNQ0pivCXsD4VbxNi1PkbrqNMO1HwtNlMN3CgXj2eJCyTrjbh1CqUxFX96dScX CagBY0a1sUFK0CIZeUkay/nhSkCqyDGzznP3+2QtxirJqP6LxYAFoTlt+RrlVk3B24vb 6hYgF1kNDxVTllQE2RBArDzq0RXqChZk6T0Qln8J0Ed+f1n6eofS9eS7Y5QVoSUtp6SQ HEPA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=kwJr06VZjw3DL1EB9ESLQFHEbo/wSdiyOPyY81ydWOA=; b=m8Fl/7rJJ/TLSdi76V2WJCaPZbOQh9SW+HWQU+HYZXoUQoGiaO47qgcHpcMrATGHUy YReYmY+ET0P0FN9+4Fx1iS2OQlawsbeJwrtbf7JakCkDraZKbzXKhkl3IJjYvik9IaSt I1RAqIicVjTNpjd+cpqOuGQZ0lKN9Vc+cJ+xeObW7awf36WoBDA2saZsI7Qybct8kAj9 yGzOkPFNT79sJNqEQ1BM1Alj2d478sv4FHhzjG7q4ODyXmANGIEhWimBRmNhbGJlGCq+ rNOufhk5NyTE++yChWBFfXfKl/AhH/1rXjKaBN2ZwYys7zNpNvmLYFyIxFC61b94kOQm T1uQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=UuF6eIm8; spf=pass (google.com: domain of devicetree-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=devicetree-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id i16si986665edx.275.2020.07.08.00.00.14; Wed, 08 Jul 2020 00:00:15 -0700 (PDT) Received-SPF: pass (google.com: domain of devicetree-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=UuF6eIm8; spf=pass (google.com: domain of devicetree-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=devicetree-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729465AbgGHHAO (ORCPT + 6 others); Wed, 8 Jul 2020 03:00:14 -0400 Received: from mail.kernel.org ([198.145.29.99]:35752 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726194AbgGHHAN (ORCPT ); Wed, 8 Jul 2020 03:00:13 -0400 Received: from localhost.localdomain (unknown [122.182.251.219]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 5DEA920771; Wed, 8 Jul 2020 07:00:06 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1594191612; bh=rIwQJ9XgMhIS4v7G1h7P96EkZRD4YP9JPOfTgw+cIoM=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=UuF6eIm83gFRGSPVdGCn1wDPNxbsmuI9l0gqDSBrKa6ohCKOxFMCc1sGCi2/1wrwS RadZz5K3T7vb3jZJ4mSwf7jvzJOXLveNTDC9dTBvb08lVUhax18ZzA5Rw694Rsmu9q KZ8p3DbvAz6U3A/ABXp1Z6cW6NXcukSqn+9UIhv0= From: Vinod Koul To: Daniel Vetter , David Airlie , Rob Clark Cc: linux-arm-msm@vger.kernel.org, Bjorn Andersson , Vinod Koul , Andrzej Hajda , Neil Armstrong , Laurent Pinchart , Jonas Karlman , Jernej Skrabec , Rob Herring , devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, dri-devel@lists.freedesktop.org, Emil Velikov , Sam Ravnborg , John Stultz Subject: [PATCH v4 4/4] drm/msm/dsi: attach external bridge with DRM_BRIDGE_ATTACH_NO_CONNECTOR Date: Wed, 8 Jul 2020 12:29:24 +0530 Message-Id: <20200708065924.59257-5-vkoul@kernel.org> X-Mailer: git-send-email 2.26.2 In-Reply-To: <20200708065924.59257-1-vkoul@kernel.org> References: <20200708065924.59257-1-vkoul@kernel.org> MIME-Version: 1.0 Sender: devicetree-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: devicetree@vger.kernel.org Modern bridges do not create the connector and expect the display driver to do so. Hence, create the drm connector in msm display driver and add use flag DRM_BRIDGE_ATTACH_NO_CONNECTOR to attach bridges Tested-by: John Stultz Signed-off-by: Vinod Koul --- drivers/gpu/drm/msm/dsi/dsi.c | 7 +------ drivers/gpu/drm/msm/dsi/dsi_manager.c | 27 +++++++++++++-------------- 2 files changed, 14 insertions(+), 20 deletions(-) -- 2.26.2 diff --git a/drivers/gpu/drm/msm/dsi/dsi.c b/drivers/gpu/drm/msm/dsi/dsi.c index 55ea4bc2ee9c..617075e3e3f0 100644 --- a/drivers/gpu/drm/msm/dsi/dsi.c +++ b/drivers/gpu/drm/msm/dsi/dsi.c @@ -219,12 +219,7 @@ int msm_dsi_modeset_init(struct msm_dsi *msm_dsi, struct drm_device *dev, goto fail; } - /* - * check if the dsi encoder output is connected to a panel or an - * external bridge. We create a connector only if we're connected to a - * drm_panel device. When we're connected to an external bridge, we - * assume that the drm_bridge driver will create the connector itself. - */ + /* Initialize the internal panel or external bridge */ ext_bridge = msm_dsi_host_get_bridge(msm_dsi->host); if (ext_bridge) diff --git a/drivers/gpu/drm/msm/dsi/dsi_manager.c b/drivers/gpu/drm/msm/dsi/dsi_manager.c index 4b363bd7ddff..72cfd0a8187b 100644 --- a/drivers/gpu/drm/msm/dsi/dsi_manager.c +++ b/drivers/gpu/drm/msm/dsi/dsi_manager.c @@ -3,6 +3,7 @@ * Copyright (c) 2015, The Linux Foundation. All rights reserved. */ +#include #include "msm_kms.h" #include "dsi.h" @@ -689,7 +690,7 @@ struct drm_bridge *msm_dsi_manager_bridge_init(u8 id) bridge = &dsi_bridge->base; bridge->funcs = &dsi_mgr_bridge_funcs; - ret = drm_bridge_attach(encoder, bridge, NULL, 0); + ret = drm_bridge_attach(encoder, bridge, NULL, DRM_BRIDGE_ATTACH_NO_CONNECTOR); if (ret) goto fail; @@ -709,7 +710,6 @@ struct drm_connector *msm_dsi_manager_ext_bridge_init(u8 id) struct drm_encoder *encoder; struct drm_bridge *int_bridge, *ext_bridge; struct drm_connector *connector; - struct list_head *connector_list; int_bridge = msm_dsi->bridge; ext_bridge = msm_dsi->external_bridge = @@ -717,22 +717,21 @@ struct drm_connector *msm_dsi_manager_ext_bridge_init(u8 id) encoder = msm_dsi->encoder; - /* link the internal dsi bridge to the external bridge */ - drm_bridge_attach(encoder, ext_bridge, int_bridge, 0); - - /* - * we need the drm_connector created by the external bridge - * driver (or someone else) to feed it to our driver's - * priv->connector[] list, mainly for msm_fbdev_init() + /* link the internal dsi bridge to the external bridge and attach + * the connector, we are supporting DRM_BRIDGE_ATTACH_NO_CONNECTOR + * so always create connector */ - connector_list = &dev->mode_config.connector_list; + drm_bridge_attach(encoder, ext_bridge, int_bridge, DRM_BRIDGE_ATTACH_NO_CONNECTOR); - list_for_each_entry(connector, connector_list, head) { - if (drm_connector_has_possible_encoder(connector, encoder)) - return connector; + connector = drm_bridge_connector_init(dev, encoder); + if (IS_ERR(connector)) { + DRM_DEV_ERROR(dev->dev, "drm_bridge_connector_init failed: %ld\n", + PTR_ERR(connector)); + return ERR_PTR(-ENODEV); } - return ERR_PTR(-ENODEV); + drm_connector_attach_encoder(connector, msm_dsi->encoder); + return connector; } void msm_dsi_manager_bridge_destroy(struct drm_bridge *bridge)