From patchwork Mon Dec 3 10:07:43 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jagan Teki X-Patchwork-Id: 10709071 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 D1A7213BF for ; Mon, 3 Dec 2018 10:08:48 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id A32A62A9C0 for ; Mon, 3 Dec 2018 10:08:46 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 947E82AA66; Mon, 3 Dec 2018 10:08:46 +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,DKIM_SIGNED, DKIM_VALID,MAILING_LIST_MULTI,RCVD_IN_DNSWL_MED autolearn=ham version=3.3.1 Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id 3F3152A9C0 for ; Mon, 3 Dec 2018 10:08:46 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:Cc:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Message-Id:Date:Subject:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=d69i+IrcVutJmK6WAGanbtR7LZWXtvsVkX8yus05M04=; b=QIL6G+zwYhQMcF qzo10HDxKD9st/zoD1Luv91d6c572ihz1oYtYdr9qM4lLsG9hMk6pdNNjMNCA/IdnqEeMOCq5sp5C r0T5C4mSPoPsjeIdXnq8iHo7OkXOalGk37ZCZdUWNxhgeWCaFxGC5RL/zRL/6sL4NUhSW9xL7vo5j 9V/ckDCGDwAB5jnSBKWdOo1thnrKZs9U4/KMv03Q9dx575UQo598DqSMWqA0/ZSQKHrSObbpgFYup gw93frm1h4X12UH+7JeaWjhDGkjQRFMlPMamKvDUtia8m7Lpi3eMDM4LUImLMvNDu69xYB0+xxzB4 I1iTjPMgW1o+TsNhRAEA==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.90_1 #2 (Red Hat Linux)) id 1gTl9X-0001y0-MY; Mon, 03 Dec 2018 10:08:35 +0000 Received: from mail-wr1-x442.google.com ([2a00:1450:4864:20::442]) by bombadil.infradead.org with esmtps (Exim 4.90_1 #2 (Red Hat Linux)) id 1gTl96-0001JY-9V for linux-arm-kernel@lists.infradead.org; Mon, 03 Dec 2018 10:08:10 +0000 Received: by mail-wr1-x442.google.com with SMTP id 96so11486738wrb.2 for ; Mon, 03 Dec 2018 02:07:57 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=amarulasolutions.com; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=RQOdFC9CjkWwFX8rp28xoDvtflvd5veREOu6vb3xEl4=; b=PrRwAGZpg1WSrlH+nDKOti9QiT/ISdGKiiT4vfkKVsyTZVwnWnbKZPr7Obm0IpQlCa XabiZsDcWjoAP54MnwGasjqYwpsrdMVThmbNZ97Rz+2QOjIvgzfl8XrfbrchG6syivEf EPRkfutL2oPKkSfwvSzTDm2cbN7sz82/gGum8= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=RQOdFC9CjkWwFX8rp28xoDvtflvd5veREOu6vb3xEl4=; b=Y/tcQzkk9ULZjED5iP4oawmzq3vw3NNt6/FSWOZdeiXKHoutcaL2PlTWuCW2WQ9kwb 0LxM5ZRnyzlyRDszcQ6G+Yi++6wMG13cbk2Gty1jaEfEqeNV59bRfbWYB4MkwrIUhi/0 ATzYbaH8cSqME8Kc0wvh48LlxWwx4EmR3N/38pGfXqvpOaeTsNCLqR/BRWxnMAqtnTFU VYliRvROG25IL1YzxhB8xY31/Z4W8w2NP0T4zA5c+7wOyCcvKdMwWys7aMutBhcWFmu7 pwvuRsj6M7qnzNX+6e7M6ysjzaR5jcE+mWdbAX/lqhMWMtahIW2iNJOsLkqqkwl2rqjZ BPzw== X-Gm-Message-State: AA+aEWZ5FlrEQ4evg9Ky874S9awszp92J9F4Ky3P+pj4vS2bvJELVnJ3 yXkIdMdpiAZSriYksBexrtATXA== X-Google-Smtp-Source: AFSGD/VPp+6EJ1yRntChb1CpYmwMyPbxm1MNxORzNUzpMr2buG2vPfa1uRSYwFnePbVCUHlq6tSumg== X-Received: by 2002:a5d:45d0:: with SMTP id b16mr12686122wrs.86.1543831676559; Mon, 03 Dec 2018 02:07:56 -0800 (PST) Received: from localhost.localdomain (conf.hotelmediterraneo.com. [2.228.78.71]) by smtp.gmail.com with ESMTPSA id n15sm18589236wrt.21.2018.12.03.02.07.55 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Mon, 03 Dec 2018 02:07:55 -0800 (PST) From: Jagan Teki To: Yong Deng , Mauro Carvalho Chehab , Maxime Ripard , Rob Herring , Mark Rutland , Chen-Yu Tsai , linux-media@vger.kernel.org, linux-arm-kernel@lists.infradead.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH 1/5] dt-bindings: media: sun6i: Add A64 CSI compatible (w/ H3 fallback) Date: Mon, 3 Dec 2018 15:37:43 +0530 Message-Id: <20181203100747.16442-2-jagan@amarulasolutions.com> X-Mailer: git-send-email 2.18.0.321.gffc6fa0e3 In-Reply-To: <20181203100747.16442-1-jagan@amarulasolutions.com> References: <20181203100747.16442-1-jagan@amarulasolutions.com> MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20181203_020808_388202_4E590885 X-CRM114-Status: GOOD ( 13.51 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Jagan Teki Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org X-Virus-Scanned: ClamAV using ClamSMTP Allwinner A64 CSI has single channel time-multiplexed BT.656 CMOS sensor interface like H3. Add a compatible string for it with H3 fallback compatible string, in this case the H3 driver can be used. Signed-off-by: Jagan Teki --- Documentation/devicetree/bindings/media/sun6i-csi.txt | 1 + 1 file changed, 1 insertion(+) diff --git a/Documentation/devicetree/bindings/media/sun6i-csi.txt b/Documentation/devicetree/bindings/media/sun6i-csi.txt index cc37cf7fd051..e78cf4f9bc8c 100644 --- a/Documentation/devicetree/bindings/media/sun6i-csi.txt +++ b/Documentation/devicetree/bindings/media/sun6i-csi.txt @@ -7,6 +7,7 @@ Required properties: - compatible: value must be one of: * "allwinner,sun6i-a31-csi" * "allwinner,sun8i-h3-csi" + * "allwinner,sun50i-a64-csi", "allwinner,sun8i-h3-csi" * "allwinner,sun8i-v3s-csi" - reg: base address and size of the memory-mapped region. - interrupts: interrupt associated to this IP From patchwork Mon Dec 3 10:07:44 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jagan Teki X-Patchwork-Id: 10709079 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 525921932 for ; Mon, 3 Dec 2018 10:10:25 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 430FC2AF6C for ; Mon, 3 Dec 2018 10:10:25 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 376972AF78; Mon, 3 Dec 2018 10:10:25 +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,DKIM_SIGNED, DKIM_VALID,MAILING_LIST_MULTI,RCVD_IN_DNSWL_MED autolearn=ham version=3.3.1 Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id E3E922AF8C for ; Mon, 3 Dec 2018 10:10:24 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:Cc:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Message-Id:Date:Subject:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=6DoUV/lyz7ICl+t8fH9YpK5L3aS7e8cfaQqWL4/uX5w=; b=cvSaCuOgX4v29d lPJXBOPoq2Q+eP0zBd36ze8FwnhT91grx6u1WeCCkb8bGo3ciuH4A1sdkct70+PiZFFAa5iViJd4E HiZ2+mj8TK0FBLHKVnDSWx03iSOqj4bGTzw2sDrlJ0gKnINd2uoJYKcEqKH7kA07MF8DmBL7IAXes mU4p67vJ+xddxXfvrSHWTknr0saq9lKmCz+LhoawJqfrjMGy/LpthJ3aj7v+TK2CdbOve4WeyBhom PaHKyc42QxfHxGGUXCqK0s9elyjRS+xvIs2hS3HNCBgJpwW1reBKz+NtWrd6Bt41n2b6H3FaXOeti /MIGUYWy6z+KPy5o6tBQ==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.90_1 #2 (Red Hat Linux)) id 1gTlBG-0005WG-DX; Mon, 03 Dec 2018 10:10:22 +0000 Received: from mail-wm1-x342.google.com ([2a00:1450:4864:20::342]) by bombadil.infradead.org with esmtps (Exim 4.90_1 #2 (Red Hat Linux)) id 1gTl97-0001Lj-BN for linux-arm-kernel@lists.infradead.org; Mon, 03 Dec 2018 10:08:11 +0000 Received: by mail-wm1-x342.google.com with SMTP id r11-v6so5078267wmb.2 for ; Mon, 03 Dec 2018 02:07:59 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=amarulasolutions.com; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=pZwHMdseiN89HEVSRgqoNt8QGqFQI8aSS6wIp4a9e3c=; b=WYp4dBnqnA6t8f4+3/r7Q81AkOf/D53JEKyfYAKWJED6IieqTZDwsiyXXmPKJHl1xZ /RjT7/ug/RPxhzKJPKHYNYqijoS9xqNrGjrvmsOWZH9G4OWsogzCYTTqJlJaQJNndrHy X2iaiTd7eBx3Cf+srP9C9KRZChXve5BWfRZUs= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=pZwHMdseiN89HEVSRgqoNt8QGqFQI8aSS6wIp4a9e3c=; b=taHBt2rBxms4/HMNYp9ipprzjq9COtWtYjb9GvDFk87bWOaoGr7OHNzNbwaFUI0DMF DMfIIhd/9navarxlzh7tvhpDG0RyeJDet+Em0jHwyTI5H2z++/0CiiiAdJ1/jcaYJohZ o8I4zHkNr37p+iGTcEkRi/V/b1RB3mO6nUVlbJAYFqCJtICxx06DfKai7A99mqy17DKu /4b11I3Mx9J6zDHcnpSj3b+Pa7t16MEed7HxQxT/lYjfzZG8BZpNh6ukKGja0Mt47z0Z Ez/tUbh5ksyOYV8kc6CeF9zHz905vQy+9cz+AXTWAJYsJ4mcAF8QQKDZyhkxP9aKq89a MMSQ== X-Gm-Message-State: AA+aEWY3tOK7q2hFMLmPtWaMPCobHgIx20ofPkXQQUDMIsyO8NSYg6HI tPnFgdUyy1GodfbqInBeKDln+w== X-Google-Smtp-Source: AFSGD/XnbFNuiD20WI4SVXVx7wsH0dmxqBf/ID0DyAkKyFtb/MOGzGfmOYAWr2InYDDaGLbjQuGBFw== X-Received: by 2002:a1c:307:: with SMTP id 7-v6mr7540895wmd.146.1543831677859; Mon, 03 Dec 2018 02:07:57 -0800 (PST) Received: from localhost.localdomain (conf.hotelmediterraneo.com. [2.228.78.71]) by smtp.gmail.com with ESMTPSA id n15sm18589236wrt.21.2018.12.03.02.07.56 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Mon, 03 Dec 2018 02:07:57 -0800 (PST) From: Jagan Teki To: Yong Deng , Mauro Carvalho Chehab , Maxime Ripard , Rob Herring , Mark Rutland , Chen-Yu Tsai , linux-media@vger.kernel.org, linux-arm-kernel@lists.infradead.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH 2/5] dt-bindings: media: sun6i: Add vcc-csi supply property Date: Mon, 3 Dec 2018 15:37:44 +0530 Message-Id: <20181203100747.16442-3-jagan@amarulasolutions.com> X-Mailer: git-send-email 2.18.0.321.gffc6fa0e3 In-Reply-To: <20181203100747.16442-1-jagan@amarulasolutions.com> References: <20181203100747.16442-1-jagan@amarulasolutions.com> MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20181203_020809_390330_703D8CAB X-CRM114-Status: GOOD ( 13.24 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Jagan Teki Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org X-Virus-Scanned: ClamAV using ClamSMTP Most of the Allwinner A64 CSI controllers are supply with VCC-PE pin. which need to supply for some of the boards to trigger the power. So, document the supply property as vcc-csi so-that the required board can eable it via device tree. Used vcc-csi instead of vcc-pe to have better naming convention wrt other controller pin supplies. Signed-off-by: Jagan Teki --- Documentation/devicetree/bindings/media/sun6i-csi.txt | 3 +++ 1 file changed, 3 insertions(+) diff --git a/Documentation/devicetree/bindings/media/sun6i-csi.txt b/Documentation/devicetree/bindings/media/sun6i-csi.txt index e78cf4f9bc8c..5fb6fd4e2c7d 100644 --- a/Documentation/devicetree/bindings/media/sun6i-csi.txt +++ b/Documentation/devicetree/bindings/media/sun6i-csi.txt @@ -18,6 +18,9 @@ Required properties: - clock-names: the clock names mentioned above - resets: phandles to the reset line driving the CSI +Optional properties: + - vcc-csi-supply: the VCC-CSI power supply of the CSI PE group + The CSI node should contain one 'port' child node with one child 'endpoint' node, according to the bindings defined in Documentation/devicetree/bindings/media/video-interfaces.txt. From patchwork Mon Dec 3 10:07:45 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jagan Teki X-Patchwork-Id: 10709067 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 D902414BD for ; Mon, 3 Dec 2018 10:08:24 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id C74FB2AFDA for ; Mon, 3 Dec 2018 10:08:24 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id B87AC2AFDD; Mon, 3 Dec 2018 10:08:24 +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,DKIM_SIGNED, DKIM_VALID,MAILING_LIST_MULTI,RCVD_IN_DNSWL_MED autolearn=unavailable version=3.3.1 Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id 6D43D2AFDA for ; Mon, 3 Dec 2018 10:08:24 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:Cc:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Message-Id:Date:Subject:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=Z3h5kwNnTyz8GvOYJ6nOTVo/O1SqOxVJJ57FvKNcWPg=; b=p9i0pCjZzHpYey Uh7BoP1AE0IovQ2U3nsPw3CXWNP6cQZbIiW67Ioe691HVW/pDg8oEEloIZojO4SwGLkGZaaeEknjO gr1ubd2Iy6fvEaB0xLeaX50NtE3G6O1qHdWq9AwnmfFms+oeY5E+Cn8wdSU34zwhvsa16G1A1uNsj zz1Lff96wKVEo7XuqRt7OHeR81UxRjUetQH1fSS9vdeRme7yqCKpZMhj76j69Ot+Va+9eJiksfYG7 aDJtIYmcA1QO7nV2Elj91xVZPHTA5r7pD9dMqkXK/RJd/cUyrU1uZUrkVtf++DC8OFUPw672WKJUz mFdhza3tRSCviTrFjaLA==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.90_1 #2 (Red Hat Linux)) id 1gTl9I-0001eO-EW; Mon, 03 Dec 2018 10:08:20 +0000 Received: from mail-wr1-x442.google.com ([2a00:1450:4864:20::442]) by bombadil.infradead.org with esmtps (Exim 4.90_1 #2 (Red Hat Linux)) id 1gTl96-0001Lq-9U for linux-arm-kernel@lists.infradead.org; Mon, 03 Dec 2018 10:08:09 +0000 Received: by mail-wr1-x442.google.com with SMTP id x10so11449458wrs.8 for ; Mon, 03 Dec 2018 02:08:00 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=amarulasolutions.com; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=Dg+DbPWOiIWTEBIboqaFlKrQScH+lEmDG+NCL3SG4qM=; b=Hr/xAyT52bglpYPM26vtwVjw0lVi0riGdwBTt/Uqb6wsvE2smy8q0cbYurg03WIILo cG805J7COWGGGcN1i/oPutV5O29qrzM/zr6QKkWDl7I1ma9c7znHWIEClb+j0PzuWgIu NIhsAm9mzdwTmQmwt2f9mKA0av9nbuxKtVIss= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=Dg+DbPWOiIWTEBIboqaFlKrQScH+lEmDG+NCL3SG4qM=; b=AwGjCuQe8kolhPmO/4LfsZ5niRKj0awHUfyJmCmV0r7/M+wKEcduu1gsnIeHXG/1qL dtBD4bm0ONqPQ7Pc7I75spg/g3hmQNxdyeBRPTIG5dwtt92Q0efHDvuxVxuznmxZqWU7 qTDNr/8DythCHf21Xlnbs9FEAVNg5heZUFNLi8q4W4PhUhGmx1rXm3RWsYbjl5YJU6OX JD0Ep+c2fg69LwWIv6fDtCkReY9Nin1M42O0yMZxOqdIwjy5apXl7528rJDy88f7RcqB oHXpb7G4KFY2re6tOZWzQUYGhdBm4WYsRRUtrTalQzP40fE1Hukob4XNWXHqDQSimBha S9BQ== X-Gm-Message-State: AA+aEWZaUEvbN2viizFhSR6eIEQdSovp4PiMlyoVQXAQMu1kayRka1If grPAg+mZveYw2nbqJwb+Vx2aWw== X-Google-Smtp-Source: AFSGD/UK9g8q6lqOZkyiIHQVvaX8DUIaGiep5wexUKg8ZFn8bAxbcvqvPj7E0tiWbgOM/Hf0bE/ZmQ== X-Received: by 2002:adf:f8d2:: with SMTP id f18mr9094939wrq.265.1543831679146; Mon, 03 Dec 2018 02:07:59 -0800 (PST) Received: from localhost.localdomain (conf.hotelmediterraneo.com. [2.228.78.71]) by smtp.gmail.com with ESMTPSA id n15sm18589236wrt.21.2018.12.03.02.07.57 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Mon, 03 Dec 2018 02:07:58 -0800 (PST) From: Jagan Teki To: Yong Deng , Mauro Carvalho Chehab , Maxime Ripard , Rob Herring , Mark Rutland , Chen-Yu Tsai , linux-media@vger.kernel.org, linux-arm-kernel@lists.infradead.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH 3/5] media: sun6i: Add vcc-csi supply regulator Date: Mon, 3 Dec 2018 15:37:45 +0530 Message-Id: <20181203100747.16442-4-jagan@amarulasolutions.com> X-Mailer: git-send-email 2.18.0.321.gffc6fa0e3 In-Reply-To: <20181203100747.16442-1-jagan@amarulasolutions.com> References: <20181203100747.16442-1-jagan@amarulasolutions.com> MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20181203_020808_333363_D0BA3E1F X-CRM114-Status: GOOD ( 15.65 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Jagan Teki Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org X-Virus-Scanned: ClamAV using ClamSMTP Most of the Allwinner A64 CSI controllers are supply with VCC-PE pin, which may not be turned on by default. Add support for such boards by adding voltage regulator handling code to sun6i csi driver. Used vcc-csi instead of vcc-pe to have better naming convention wrt other controller pin supplies. Signed-off-by: Jagan Teki --- .../media/platform/sunxi/sun6i-csi/sun6i_csi.c | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/drivers/media/platform/sunxi/sun6i-csi/sun6i_csi.c b/drivers/media/platform/sunxi/sun6i-csi/sun6i_csi.c index 6950585edb5a..5836fa5e6b01 100644 --- a/drivers/media/platform/sunxi/sun6i-csi/sun6i_csi.c +++ b/drivers/media/platform/sunxi/sun6i-csi/sun6i_csi.c @@ -18,6 +18,7 @@ #include #include #include +#include #include #include #include @@ -36,6 +37,7 @@ struct sun6i_csi_dev { struct clk *clk_mod; struct clk *clk_ram; struct reset_control *rstc_bus; + struct regulator *regulator; int planar_offset[3]; }; @@ -163,9 +165,16 @@ int sun6i_csi_set_power(struct sun6i_csi *csi, bool enable) clk_disable_unprepare(sdev->clk_ram); clk_disable_unprepare(sdev->clk_mod); reset_control_assert(sdev->rstc_bus); + regulator_disable(sdev->regulator); return 0; } + ret = regulator_enable(sdev->regulator); + if (ret) { + dev_err(sdev->dev, "Enable vcc csi supply err %d\n", ret); + return ret; + } + ret = clk_prepare_enable(sdev->clk_mod); if (ret) { dev_err(sdev->dev, "Enable csi clk err %d\n", ret); @@ -809,6 +818,12 @@ static int sun6i_csi_resource_request(struct sun6i_csi_dev *sdev, if (IS_ERR(io_base)) return PTR_ERR(io_base); + sdev->regulator = devm_regulator_get(&pdev->dev, "vcc-csi"); + if (IS_ERR(sdev->regulator)) { + dev_err(&pdev->dev, "Unable to acquire csi vcc supply\n"); + return PTR_ERR(sdev->regulator); + } + sdev->regmap = devm_regmap_init_mmio_clk(&pdev->dev, "bus", io_base, &sun6i_csi_regmap_config); if (IS_ERR(sdev->regmap)) { From patchwork Mon Dec 3 10:07:46 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jagan Teki X-Patchwork-Id: 10709073 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 4149514BD for ; Mon, 3 Dec 2018 10:08:55 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 2D6BB2AB22 for ; Mon, 3 Dec 2018 10:08:55 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 1D2622AB26; Mon, 3 Dec 2018 10:08:55 +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,DKIM_SIGNED, DKIM_VALID,MAILING_LIST_MULTI,RCVD_IN_DNSWL_MED autolearn=ham version=3.3.1 Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id BE7872AB22 for ; Mon, 3 Dec 2018 10:08:54 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:Cc:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Message-Id:Date:Subject:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=5PPPVLFJMoC6PtAwHlKsUeRZYgZAqCfQYYzZFzWeK4k=; b=BZWiW48+e3i1Y9 DItQ+mMbjZuKJxVZvgvr/x/yFqp6O+Ngh0OMjXSth/eRZ17ANp2kuSG15OBeMtGKi8aim1bGp9Ccz ezG/lP6PkUhg3lhBV38jlIzCjYlnSSY7ftm0lwYmofI9IKsYsF7SV3RTSUYNGrHbRicpMmaxC+3EX YQIkczMB7HwVkgclAggFFCc1DFcC+MuILG/aoVF23dyC/TZFi8jC466XhxrDm5jTxjW9b+ZFEUm01 +SB2iOFEkLCNkZGA1nPqmYRI13fiCl19x9meN0iZ6NhMqqZJ5CULziVJaPHjZhSViC7xSQF+SUTkJ XUJuzwa9/Xb7ruY9l1bA==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.90_1 #2 (Red Hat Linux)) id 1gTl9n-0002NW-Lz; Mon, 03 Dec 2018 10:08:51 +0000 Received: from mail-wm1-x342.google.com ([2a00:1450:4864:20::342]) by bombadil.infradead.org with esmtps (Exim 4.90_1 #2 (Red Hat Linux)) id 1gTl97-0001Ly-BK for linux-arm-kernel@lists.infradead.org; Mon, 03 Dec 2018 10:08:10 +0000 Received: by mail-wm1-x342.google.com with SMTP id z18so5089798wmc.4 for ; Mon, 03 Dec 2018 02:08:01 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=amarulasolutions.com; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=SaTHXuzdJjMTWekY2/DsirLmYaUh6d39j/40yOw9ADA=; b=aVmN+pEPQpdTu26ytBH6ev469JzbamvV7CCnubiDPyOpmzonabtdr3gd//ELjNxIgM cGOYPfwYML5EoVHTlkG1sAAYiQOBPai3zb+4elxLYiyRImtP/NYnSgIMLs0a01woZb/z o8vORLdcIToa0TyHYyYc+IFw9CPmu207BMDx8= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=SaTHXuzdJjMTWekY2/DsirLmYaUh6d39j/40yOw9ADA=; b=pEAuqQMgIFhHGuIRBsnlM3/+Z6L4eWkf/xVaM1p9Vx9tW03OEnMM1PRfNBHACdpoyJ RY7uOcP/mhI4pvSWZztcmsn8M1KlWZfnaVrdM3DGUGZqwx+m55gGD4S9PQmrUh+a29LT EiGD5/SqhoNm1JfWUglVJ9ubc/b6shuOcQKwjsVT9KQAKAZeg1n8DK6wdrQBOL+h5+Ld EYphrNJBlcA5cfhxUI8kxCGbg4DUK8qWIpMF0AArdgtiRvBTk+iLNHhgTHCw0Cv/DUtK GXOIcEy92T8QRFsxz9hTTHpvEyZYVbA481LIjxrxNXkfSz+yMGZwAO3gEOkH10fJJg4Q iKCA== X-Gm-Message-State: AA+aEWbT/k/ImkXz39mINza/5RNOICrWIMY9FmHj0zW+BllRS0md7CZt KBatd7joggHpY1P+cFIEcX2Cnw== X-Google-Smtp-Source: AFSGD/XXID2lcNa2SrO9/ABXfaFcfhJBWMw99ZZqav47P2OVn/8dG2m9kDDGnVhHa33Fr1z3Y/KK/A== X-Received: by 2002:a1c:b687:: with SMTP id g129mr7464602wmf.59.1543831680419; Mon, 03 Dec 2018 02:08:00 -0800 (PST) Received: from localhost.localdomain (conf.hotelmediterraneo.com. [2.228.78.71]) by smtp.gmail.com with ESMTPSA id n15sm18589236wrt.21.2018.12.03.02.07.59 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Mon, 03 Dec 2018 02:07:59 -0800 (PST) From: Jagan Teki To: Yong Deng , Mauro Carvalho Chehab , Maxime Ripard , Rob Herring , Mark Rutland , Chen-Yu Tsai , linux-media@vger.kernel.org, linux-arm-kernel@lists.infradead.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH 4/5] arm64: dts: allwinner: a64: Add A64 CSI controller Date: Mon, 3 Dec 2018 15:37:46 +0530 Message-Id: <20181203100747.16442-5-jagan@amarulasolutions.com> X-Mailer: git-send-email 2.18.0.321.gffc6fa0e3 In-Reply-To: <20181203100747.16442-1-jagan@amarulasolutions.com> References: <20181203100747.16442-1-jagan@amarulasolutions.com> MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20181203_020809_385982_AE09872D X-CRM114-Status: GOOD ( 13.16 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Jagan Teki Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org X-Virus-Scanned: ClamAV using ClamSMTP Allwinner A64 CSI controller has similar features as like in H3, So add support for A64 via H3 fallback. Signed-off-by: Jagan Teki --- arch/arm64/boot/dts/allwinner/sun50i-a64.dtsi | 21 +++++++++++++++++++ 1 file changed, 21 insertions(+) diff --git a/arch/arm64/boot/dts/allwinner/sun50i-a64.dtsi b/arch/arm64/boot/dts/allwinner/sun50i-a64.dtsi index 384c417cb7a2..d32ff694ac5c 100644 --- a/arch/arm64/boot/dts/allwinner/sun50i-a64.dtsi +++ b/arch/arm64/boot/dts/allwinner/sun50i-a64.dtsi @@ -532,6 +532,12 @@ interrupt-controller; #interrupt-cells = <3>; + csi_pins: csi-pins { + pins = "PE0", "PE2", "PE3", "PE4", "PE5", "PE6", + "PE7", "PE8", "PE9", "PE10", "PE11"; + function = "csi0"; + }; + i2c0_pins: i2c0_pins { pins = "PH0", "PH1"; function = "i2c0"; @@ -899,6 +905,21 @@ status = "disabled"; }; + csi: csi@1cb0000 { + compatible = "allwinner,sun50i-a64-csi", + "allwinner,sun8i-h3-csi"; + reg = <0x01cb0000 0x1000>; + interrupts = ; + clocks = <&ccu CLK_BUS_CSI>, + <&ccu CLK_CSI_SCLK>, + <&ccu CLK_DRAM_CSI>; + clock-names = "bus", "mod", "ram"; + resets = <&ccu RST_BUS_CSI>; + pinctrl-names = "default"; + pinctrl-0 = <&csi_pins>; + status = "disabled"; + }; + hdmi: hdmi@1ee0000 { compatible = "allwinner,sun50i-a64-dw-hdmi", "allwinner,sun8i-a83t-dw-hdmi"; From patchwork Mon Dec 3 10:07:47 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jagan Teki X-Patchwork-Id: 10709077 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 EC3F31923 for ; Mon, 3 Dec 2018 10:10:24 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id D71D12AF34 for ; Mon, 3 Dec 2018 10:10:24 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id CB3932AF82; Mon, 3 Dec 2018 10:10:24 +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,DKIM_SIGNED, DKIM_VALID,MAILING_LIST_MULTI,RCVD_IN_DNSWL_MED autolearn=unavailable version=3.3.1 Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id 6857D2AF34 for ; Mon, 3 Dec 2018 10:10:24 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:Cc:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Message-Id:Date:Subject:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=aB0j6QEMbrA1fCRm3p097/Mmo8KSjUAadePdGg+UqlM=; b=dv29FNOhhytAxs g8TjWNq+4ovfyMVMqmePBRMN7XJn4DCdk7+XfXcZ/wbup4wnMZUlG/9umaJR0QNnNTrBsPyqIR+xn 8l1NBo4ZORiPz+y/PQ0PxpcMXHBK7esqLp8e+HYSp2c1CWkK8MuQgMGLTUpqrtwObbzIp2R8H0690 fUcrMqK0gw1brITZ8t8U7IK/GW2zdAZLVbUaJ0H+YzRjzRAsbm1LLUkDb8KMNQH8fPQy5U9M5UdhZ dZS4qFWFRK3nPuI2erWt2bl/8hhLOVJLbD10ykzi5x7kXYq9h7l5fvcf5lIKD4vtF44TPiChA8hhD IBytRCe9gYD/56VA7tbQ==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.90_1 #2 (Red Hat Linux)) id 1gTlBH-0005X3-JG; Mon, 03 Dec 2018 10:10:23 +0000 Received: from mail-wr1-x42b.google.com ([2a00:1450:4864:20::42b]) by bombadil.infradead.org with esmtps (Exim 4.90_1 #2 (Red Hat Linux)) id 1gTl9B-0001MQ-Nx for linux-arm-kernel@lists.infradead.org; Mon, 03 Dec 2018 10:08:22 +0000 Received: by mail-wr1-x42b.google.com with SMTP id v6so11422819wrr.12 for ; Mon, 03 Dec 2018 02:08:03 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=amarulasolutions.com; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=8g+uoe2D0wbUmeVGWobhlMg09E9u+QyXMer1oiBcYAk=; b=AYMfQAZYz5o2/kkSAsIQmbtkGPKTB4spjIXNR78pptmK9KqHI1S0qOiAXe3PIPUt2V 6cdy3GA7OWSQ8rNjvPHvrBMflwbnR3cKp1YFBn2C/D2DDtwxo7vm6oF7QYLOMAWNHCjy jXdBOT9NDpQf2ZAocmFItxwTfI/uDxMHEApmA= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=8g+uoe2D0wbUmeVGWobhlMg09E9u+QyXMer1oiBcYAk=; b=Fm8zXEm8A7/G0a5eIe9DLXE3cHnk0eT4xZzNF85ZR/bP9dVchtE8sjfCUptVHnM83T K6GOzqrTB9+TCNRXhWhiH0s1SqxBg2vy/zKh9LH/EthoTDwUJJQnlgz3mGZiuGkKdU7A ejne7L+DbYTZXHkw84QBXKoX92dBRXWL1EPUzmQt6BBsLWLj3uS0UuuW4Ros96iBKAc1 8YX1COyPOOKMQ6gX99P+fvFiJUibcAey80IEOGZ+7mbIyDcXXd2HxITCC4CXIbVPTs4a rwmK4HV6jbN1U+2gUUpKHV/WjFtcOqprEs1/meDrBUEUEVvm9FrlBaWDruz9pYlPjbfF ob8g== X-Gm-Message-State: AA+aEWbZgz4difGwHqwD2B+TWK62BZY4v2ExX0+3p9VTet8BZnXPena0 DF0HlhVER3Sfm05FBKZTHVAyTfxxzfU= X-Google-Smtp-Source: AFSGD/XXnRvxPu+v/q0zi96QmqEJxLzAnSJQrpfhNl1nyainR2UMa5onjVEXfYEj5+c4mOqkVdyVbA== X-Received: by 2002:adf:e846:: with SMTP id d6mr14057493wrn.72.1543831681810; Mon, 03 Dec 2018 02:08:01 -0800 (PST) Received: from localhost.localdomain (conf.hotelmediterraneo.com. [2.228.78.71]) by smtp.gmail.com with ESMTPSA id n15sm18589236wrt.21.2018.12.03.02.08.00 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Mon, 03 Dec 2018 02:08:01 -0800 (PST) From: Jagan Teki To: Yong Deng , Mauro Carvalho Chehab , Maxime Ripard , Rob Herring , Mark Rutland , Chen-Yu Tsai , linux-media@vger.kernel.org, linux-arm-kernel@lists.infradead.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH 5/5] arm64: dts: allwinner: a64-amarula-relic: Add OV5640 camera node Date: Mon, 3 Dec 2018 15:37:47 +0530 Message-Id: <20181203100747.16442-6-jagan@amarulasolutions.com> X-Mailer: git-send-email 2.18.0.321.gffc6fa0e3 In-Reply-To: <20181203100747.16442-1-jagan@amarulasolutions.com> References: <20181203100747.16442-1-jagan@amarulasolutions.com> MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20181203_020814_423847_3247D44A X-CRM114-Status: GOOD ( 14.46 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Jagan Teki Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org X-Virus-Scanned: ClamAV using ClamSMTP Amarula A64-Relic board by default bound with OV5640 camera, so add support for it with below pin information. - PE13, PE12 via i2c-gpio bitbanging - CLK_CSI_MCLK as external clock - PE1 as external clock pin muxing - DLDO3 as vcc-csi supply - DLDO3 as AVDD supply - ALDO1 as DOVDD supply - ELDO3 as DVDD supply - PE14 gpio for reset pin - PE15 gpio for powerdown pin Signed-off-by: Jagan Teki --- .../allwinner/sun50i-a64-amarula-relic.dts | 54 +++++++++++++++++++ arch/arm64/boot/dts/allwinner/sun50i-a64.dtsi | 5 ++ 2 files changed, 59 insertions(+) diff --git a/arch/arm64/boot/dts/allwinner/sun50i-a64-amarula-relic.dts b/arch/arm64/boot/dts/allwinner/sun50i-a64-amarula-relic.dts index 6cb2b7f0c817..9ac6d773188b 100644 --- a/arch/arm64/boot/dts/allwinner/sun50i-a64-amarula-relic.dts +++ b/arch/arm64/boot/dts/allwinner/sun50i-a64-amarula-relic.dts @@ -22,6 +22,41 @@ stdout-path = "serial0:115200n8"; }; + i2c-csi { + compatible = "i2c-gpio"; + sda-gpios = <&pio 4 13 (GPIO_ACTIVE_HIGH|GPIO_OPEN_DRAIN)>; + scl-gpios = <&pio 4 12 (GPIO_ACTIVE_HIGH|GPIO_OPEN_DRAIN)>; + i2c-gpio,delay-us = <5>; + #address-cells = <1>; + #size-cells = <0>; + + ov5640: camera@3c { + compatible = "ovti,ov5640"; + reg = <0x3c>; + pinctrl-names = "default"; + pinctrl-0 = <&csi_mclk_pin>; + clocks = <&ccu CLK_CSI_MCLK>; + clock-names = "xclk"; + + AVDD-supply = <®_dldo3>; + DOVDD-supply = <®_aldo1>; + DVDD-supply = <®_eldo3>; + reset-gpios = <&pio 4 14 GPIO_ACTIVE_LOW>; /* CSI-RST-R: PE14 */ + powerdown-gpios = <&pio 4 15 GPIO_ACTIVE_HIGH>; /* CSI-STBY-R: PE15 */ + + port { + ov5640_ep: endpoint { + remote-endpoint = <&csi_ep>; + bus-width = <8>; + hsync-active = <1>; /* Active high */ + vsync-active = <0>; /* Active low */ + data-active = <1>; /* Active high */ + pclk-sample = <1>; /* Rising */ + }; + }; + }; + }; + wifi_pwrseq: wifi-pwrseq { compatible = "mmc-pwrseq-simple"; clocks = <&rtc 1>; @@ -30,6 +65,25 @@ }; }; +&csi { + vcc-csi-supply = <®_dldo3>; + status = "okay"; + + port { + #address-cells = <1>; + #size-cells = <0>; + + csi_ep: endpoint { + remote-endpoint = <&ov5640_ep>; + bus-width = <8>; + hsync-active = <1>; /* Active high */ + vsync-active = <0>; /* Active low */ + data-active = <1>; /* Active high */ + pclk-sample = <1>; /* Rising */ + }; + }; +}; + &ehci0 { status = "okay"; }; diff --git a/arch/arm64/boot/dts/allwinner/sun50i-a64.dtsi b/arch/arm64/boot/dts/allwinner/sun50i-a64.dtsi index d32ff694ac5c..844bb44a78af 100644 --- a/arch/arm64/boot/dts/allwinner/sun50i-a64.dtsi +++ b/arch/arm64/boot/dts/allwinner/sun50i-a64.dtsi @@ -538,6 +538,11 @@ function = "csi0"; }; + csi_mclk_pin: csi-mclk { + pins = "PE1"; + function = "csi0"; + }; + i2c0_pins: i2c0_pins { pins = "PH0", "PH1"; function = "i2c0";