From patchwork Fri May 14 12:20:49 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ikjoon Jang X-Patchwork-Id: 12257703 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-17.4 required=3.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_CR_TRAILER, INCLUDES_PATCH,MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED, USER_AGENT_GIT autolearn=unavailable autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id A7B53C433ED for ; Fri, 14 May 2021 12:23:55 +0000 (UTC) Received: from desiato.infradead.org (desiato.infradead.org [90.155.92.199]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 2B91861285 for ; Fri, 14 May 2021 12:23:55 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 2B91861285 Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=chromium.org Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=desiato.20200630; h=Sender:Content-Transfer-Encoding :Content-Type:List-Subscribe:List-Help:List-Post:List-Archive: List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To:Message-Id:Date: Subject:Cc:To:From:Reply-To:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Owner; bh=5U96jVskYWqOtK7v4m4VWCPi1q7ymypxCotHyrcAUSY=; b=pYHnPebOxyL/ChWoJ5EYqWYKx Q4MhQcqjD3R1naPmoERbfSiZFGPqE/rsP7T6No/t50DMAxz4MfGMHhx0TChkz2jJF+fKBOyttkbCG eL0CPuynLW1KnCwQuZpBxueLKOe5iGH6nuz3elEH8OBOp/dlf57aA3z9UdoiBpM0tnz1b/CEUJwEC IP/ADTjsU/5+OLBi6XE8Ev/0jCz2+cQUdprOeANOH+6KCZrnQ99JnQTPvHGI1O2/tH7mqYKr4VGBd fHbPsIaacC2qTWBTtJVMVoGe4/+youT/Jo0C4FyfUC/etKC6Bb5+cseG/ueoi0UlfO3iRMp2da0s3 AEuQPegyA==; Received: from localhost ([::1] helo=desiato.infradead.org) by desiato.infradead.org with esmtp (Exim 4.94 #2 (Red Hat Linux)) id 1lhWpR-0080v3-9k; Fri, 14 May 2021 12:22:06 +0000 Received: from bombadil.infradead.org ([2607:7c80:54:e::133]) by desiato.infradead.org with esmtps (Exim 4.94 #2 (Red Hat Linux)) id 1lhWpB-0080rj-D7 for linux-arm-kernel@desiato.infradead.org; Fri, 14 May 2021 12:21:49 +0000 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=bombadil.20210309; h=Content-Transfer-Encoding: MIME-Version:References:In-Reply-To:Message-Id:Date:Subject:Cc:To:From:Sender :Reply-To:Content-Type:Content-ID:Content-Description; bh=eDsBcMn1LjQ/hDt4A5VW4rjJ3axqBAgkESJwxk85dos=; b=IL7XtchJHBgS32oCzxKzxol2/u 8ND5zUaAo2D0Zk+LpgmPzVip47gRUzEm4sFn5imtUyY3CdMhPmD5/F5UEVBx9IBhoR8WXGg+CqRYs qYPFRgTbXejB2p81g3g2mkHTmmdmZ/1cBoUnyovVHFxnNXmHwp6ttf50ZFsl3tppIdyKBETNqlcqk NwHGt1jifq6lLfNZkVx88r6ShVmSsmWOpZjkfXfEU1hkIeJLtnwXzipqYfw4AAx2P/uNBWAU8bRzk +YwNsIAtqr/jKrGEYIYN3ckRsvB5jgwYTZs+UG1VUeaiF8Ssemrb0KPlTtUVT4UvqX/kETCGWkfdd 0JGcZlLQ==; Received: from mail-pf1-x429.google.com ([2607:f8b0:4864:20::429]) by bombadil.infradead.org with esmtps (Exim 4.94 #2 (Red Hat Linux)) id 1lhWp8-00By5l-S1 for linux-arm-kernel@lists.infradead.org; Fri, 14 May 2021 12:21:48 +0000 Received: by mail-pf1-x429.google.com with SMTP id e19so6265282pfv.3 for ; Fri, 14 May 2021 05:21:44 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chromium.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=eDsBcMn1LjQ/hDt4A5VW4rjJ3axqBAgkESJwxk85dos=; b=SW5DJIHQpxkxWhkboLIm5KcifPgzvhRktiH30n6bS+X4SKEPha2DWC3KR5gyqr83hB YQPLn3bgk3aUNnuGPtDGve2THPWaS26HYtEvXb7Dr1y0ewiZLuhKY8KViKhfrhDk62QM K6LMvy3EL5Djw/52hUfs3ULA0sFQAiWklQQSw= 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=eDsBcMn1LjQ/hDt4A5VW4rjJ3axqBAgkESJwxk85dos=; b=nyOMFHeuuKMlZ+mB1Su/DD7UHixcGXKiBP7f4w7EfzjSWKsgYP878e0IG6w/qQAK/x q7r5R4nHrSNuNf2XRsLtYGCpt1/dKB3fesDAMka9NPIzsZtBlDqj/hpKld9y7oe2yE6e a7rTOaxCVPeWlooJ9VRGi7mNIy0KuJlWdNBgqhk2BDlFCZcK7kH9yNubfmua6/JmoY7S fECAzByTnb+eFFa988eew7xEHoebWKXR2Q72SpevciEjHUGIKqqrHTmf4PAsWf3YlJLX ptuA3lU7bsRNEUnI4S2mfKTIQpB3CKilBUocL4uYkylwgCunFPrkPXohG9aehUd5NSrg Lb1Q== X-Gm-Message-State: AOAM530EptdQBgg+AVRynFCE8d6Sj2eYrKcWpCcn/4EgpNXwcS7Z9wHg b1Nvk3ZwI8h9hxL24jHkBbOvRg== X-Google-Smtp-Source: ABdhPJx6jr5fCAdWz8NJtqocenE0PKs3M5FF1QRbK4QlEM50P2vcTu20RWzMWUzaKu1vMlPRqVRlZg== X-Received: by 2002:a62:80d2:0:b029:2b3:fca1:8829 with SMTP id j201-20020a6280d20000b02902b3fca18829mr31868512pfd.2.1620994904194; Fri, 14 May 2021 05:21:44 -0700 (PDT) Received: from ikjn-p920.tpe.corp.google.com ([2401:fa00:1:b:7641:4b1d:694e:6ea2]) by smtp.gmail.com with ESMTPSA id u17sm4010117pfm.113.2021.05.14.05.21.41 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 14 May 2021 05:21:43 -0700 (PDT) From: Ikjoon Jang To: devicetree@vger.kernel.org, Lee Jones Cc: linux-kernel@vger.kernel.org, linux-mediatek@lists.infradead.org, Matthias Brugger , linux-arm-kernel@lists.infradead.org, Guenter Roeck , Enric Balletbo i Serra , Benson Leung , linux-input@vger.kernel.org, Hsin-Yi Wang , Jiri Kosina , Stephen Boyd , Ikjoon Jang , Rob Herring , Rob Herring Subject: [RESEND PATCH v7 1/2] mfd: google, cros-ec: add DT bindings for a baseboard's switch device Date: Fri, 14 May 2021 20:20:49 +0800 Message-Id: <20210514122051.266169-2-ikjn@chromium.org> X-Mailer: git-send-email 2.31.1.751.gd2f1c929bd-goog In-Reply-To: <20210514122051.266169-1-ikjn@chromium.org> References: <20210514122051.266169-1-ikjn@chromium.org> MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20210514_052146_913073_2877E712 X-CRM114-Status: GOOD ( 14.45 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org This is for ChromeOS tablets which have a 'cros_cbas' switch device in the "Whiskers" base board. This device can be instantiated only by device tree on ARM platforms. ChromeOS EC doesn't provide a way to probe the device. Signed-off-by: Ikjoon Jang Reviewed-by: Rob Herring Acked-by: Enric Balletbo i Serra Reviewed-by: Stephen Boyd --- Changes in v7: - no changes from v6 Changes in v6: - Remove a label for cbas node in a example Changes in v5: - Add missing blank lines and change the description property's position. - Add a note to description: "this device cannot be detected at runtime." Changes in v4: Define cros-cbase bindings inside google,cros-ec.yaml instead of a separated binding document. .../bindings/mfd/google,cros-ec.yaml | 20 +++++++++++++++++++ 1 file changed, 20 insertions(+) diff --git a/Documentation/devicetree/bindings/mfd/google,cros-ec.yaml b/Documentation/devicetree/bindings/mfd/google,cros-ec.yaml index 76bf16ee27ec..929c17552d8b 100644 --- a/Documentation/devicetree/bindings/mfd/google,cros-ec.yaml +++ b/Documentation/devicetree/bindings/mfd/google,cros-ec.yaml @@ -114,6 +114,22 @@ properties: - "#address-cells" - "#size-cells" + cbas: + type: object + + description: + This device is used to signal when a detachable base is attached + to a Chrome OS tablet. This device cannot be detected at runtime. + + properties: + compatible: + const: google,cros-cbas + + required: + - compatible + + additionalProperties: false + patternProperties: "^i2c-tunnel[0-9]*$": type: object @@ -180,6 +196,10 @@ examples: interrupts = <99 0>; interrupt-parent = <&gpio7>; spi-max-frequency = <5000000>; + + cbas { + compatible = "google,cros-cbas"; + }; }; }; From patchwork Fri May 14 12:20:50 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ikjoon Jang X-Patchwork-Id: 12257705 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-17.4 required=3.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_CR_TRAILER, INCLUDES_PATCH,MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED, USER_AGENT_GIT autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 51F1DC433B4 for ; Fri, 14 May 2021 12:24:06 +0000 (UTC) Received: from desiato.infradead.org (desiato.infradead.org [90.155.92.199]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id D19E661285 for ; Fri, 14 May 2021 12:24:05 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org D19E661285 Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=chromium.org Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=desiato.20200630; h=Sender:Content-Transfer-Encoding :Content-Type:List-Subscribe:List-Help:List-Post:List-Archive: List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To:Message-Id:Date: Subject:Cc:To:From:Reply-To:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Owner; bh=lXTU1fce6PTLR69G2CVuqr5WyPj9Hf4cX6WZwVIbqF0=; b=ey+Hb25sTLxLEWKbTnG7EYYKU ma4RyblBEAweG2fFrJiVKHmwqHPkClrsP1XhSrt53ZDA2pilIkCmAAEdTqdK2PYGFcsZjpZPAeWv+ XkGgd/igvEHoX2OQ4q8mqdogauqE8jOQdc0g8tFNaVwswCJlAjqwNaWz+ollXhxEZq/YP1pFcOgEA 4sBO5olyqzaN6ruSTr1t9DlL+vRLfkg6CaY5GT1Ejc7E0/3bPN9DijrQb5GzceB4SulKiuS89WObj Vku2kaGre3ibtj7tHF1Q8xrGa2qF25ot8iZkW8COZjP5GXaE8R8xwlhjygoi1Sbk3DcQsIM8DfhDw qD/7tB4jg==; Received: from localhost ([::1] helo=desiato.infradead.org) by desiato.infradead.org with esmtp (Exim 4.94 #2 (Red Hat Linux)) id 1lhWpd-0080yP-Nz; Fri, 14 May 2021 12:22:17 +0000 Received: from bombadil.infradead.org ([2607:7c80:54:e::133]) by desiato.infradead.org with esmtps (Exim 4.94 #2 (Red Hat Linux)) id 1lhWpC-0080s3-Ho for linux-arm-kernel@desiato.infradead.org; Fri, 14 May 2021 12:21:50 +0000 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=bombadil.20210309; h=Content-Transfer-Encoding: MIME-Version:References:In-Reply-To:Message-Id:Date:Subject:Cc:To:From:Sender :Reply-To:Content-Type:Content-ID:Content-Description; bh=sKjlU1Buo3yAKav8pJKU6YPJruDt7qvnKtW5oGGLMB0=; b=kNNGuL5h3ldxMAx6nPpn2xz/PL S0fotlTxOcY1F10zpr8/VKAGoItB1H+clru+R7Et25cjIA0WpFqCopRd9yjbczFIeUlmPeWI34MkY F/r5f/4am5o4Ox8yYfI83ce8O7tgqaNxHvdgzgk0oGDJ2PxDfJYH91mMrPKTOcgd9PvgdpJ88zl8E W0/OzyG7ZMfvq/3HPxvNOmd9B2QIDti4orPFvDb+2jHd7XQKTT5wSUbXmvaDEj5QPkF0V9qNo3EfC t6/XyAjXFNf4tIHcLpZOh3wjw936JgbbgHrBt16NuBb9bTqCjzbKxdXNpYcQ3rDLutILIxpuWYzqK dEwR2peA==; Received: from mail-pj1-x1032.google.com ([2607:f8b0:4864:20::1032]) by bombadil.infradead.org with esmtps (Exim 4.94 #2 (Red Hat Linux)) id 1lhWp9-00By6s-UR for linux-arm-kernel@lists.infradead.org; Fri, 14 May 2021 12:21:49 +0000 Received: by mail-pj1-x1032.google.com with SMTP id b9-20020a17090a9909b029015cf9effaeaso1572020pjp.5 for ; Fri, 14 May 2021 05:21:47 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chromium.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=sKjlU1Buo3yAKav8pJKU6YPJruDt7qvnKtW5oGGLMB0=; b=NLXYC/fCzff42RFMo4JsKua3S2IUCUzTzaHkCXxtiZNbwuwiwTdCxz6oz87Jq392+5 geLJgwyMNlpMjsQV1eMcrdPMIIz9KPJl2FVhKbTfE+rCCtZm/96BW7tBnrHuaVnZBnfw DjDsx2hnn3ihtXF61OzbVgrDk0P2cCFWKerUE= 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=sKjlU1Buo3yAKav8pJKU6YPJruDt7qvnKtW5oGGLMB0=; b=PBlxhZguUfc1ge9rR7gxHVDVq45EDeyUGMxHdHw02nmEsW7UWEhSAldtFyOXBi8ejZ Xw+hZB9wLZepJL1UwPOYLE4auTiHH+syRWziJS06iafztFt+rv0dhoSuyQ4oPJCtrOW8 80WnRTzaq7g2mBp/hwwzoVkl83IGo/hdEfK8oacrWo4A9xxt8NwVa/Z/liVTy/1ngXZJ AI4dRLTIdDstuYXwJM1KLPwXlgGT5+em1nj0m0f3FdBDXUyhDIoWtSeiAC/RE5DTRaSJ UOUcnm/BXCWYr+B1MwlQaIE1s0HnMhTIibQ1FaZ+Pw+tCYh0uleROED/hl17+NK1BQv/ Ji9A== X-Gm-Message-State: AOAM532QFLuh0OewCG2BHCN3DEdQttgXqMOC994Vr1Dxle7ZrrgCUWoj WP6126SaQmTdAxu/Z9oI0L4sFQ== X-Google-Smtp-Source: ABdhPJzbhRjGp805y3Hi2jGWtbTzWzNP/rtCinbBrDZStuzJwfwKrzHfxCMVKpvvbNeU+KgrFdTwVA== X-Received: by 2002:a17:90a:f87:: with SMTP id 7mr33610983pjz.38.1620994906861; Fri, 14 May 2021 05:21:46 -0700 (PDT) Received: from ikjn-p920.tpe.corp.google.com ([2401:fa00:1:b:7641:4b1d:694e:6ea2]) by smtp.gmail.com with ESMTPSA id u17sm4010117pfm.113.2021.05.14.05.21.44 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 14 May 2021 05:21:46 -0700 (PDT) From: Ikjoon Jang To: devicetree@vger.kernel.org, Lee Jones Cc: linux-kernel@vger.kernel.org, linux-mediatek@lists.infradead.org, Matthias Brugger , linux-arm-kernel@lists.infradead.org, Guenter Roeck , Enric Balletbo i Serra , Benson Leung , linux-input@vger.kernel.org, Hsin-Yi Wang , Jiri Kosina , Stephen Boyd , Ikjoon Jang , Rob Herring Subject: [RESEND PATCH v7 2/2] arm64: dts: mt8183: add cbas node under cros_ec Date: Fri, 14 May 2021 20:20:50 +0800 Message-Id: <20210514122051.266169-3-ikjn@chromium.org> X-Mailer: git-send-email 2.31.1.751.gd2f1c929bd-goog In-Reply-To: <20210514122051.266169-1-ikjn@chromium.org> References: <20210514122051.266169-1-ikjn@chromium.org> MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20210514_052148_004429_14D979C9 X-CRM114-Status: GOOD ( 12.53 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org Add a 'cbas' device node for supporting tablet mode switch in kukui devices. Kukui platforms with detacheable base have an additional input device under cros-ec, which reports SW_TABLET_MODE regarding its base state (e.g. base flipped or detached). Signed-off-by: Ikjoon Jang Reviewed-by: Enric Balletbo i Serra Reviewed-by: Stephen Boyd Reviewed-by: Enric Balletbo i Serra --- Changes in v7: - remove a label in cbas node - fix an erratum in commit message (table --> tablet) - dt-binding patchess merged altogether with mt8183 dts arch/arm64/boot/dts/mediatek/mt8183-kukui.dtsi | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/arch/arm64/boot/dts/mediatek/mt8183-kukui.dtsi b/arch/arm64/boot/dts/mediatek/mt8183-kukui.dtsi index ff56bcfa3370..1512605a438e 100644 --- a/arch/arm64/boot/dts/mediatek/mt8183-kukui.dtsi +++ b/arch/arm64/boot/dts/mediatek/mt8183-kukui.dtsi @@ -816,6 +816,10 @@ usbc_extcon: extcon0 { compatible = "google,extcon-usbc-cros-ec"; google,usb-port-id = <0>; }; + + cbas { + compatible = "google,cros-cbas"; + }; }; };