From patchwork Wed Mar 6 09:50:27 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Bibby Hsieh X-Patchwork-Id: 10840737 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 55AE514DE for ; Wed, 6 Mar 2019 09:51:34 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 3E8D22D429 for ; Wed, 6 Mar 2019 09:51:34 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 320442D449; Wed, 6 Mar 2019 09:51: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,DKIM_SIGNED, DKIM_VALID,MAILING_LIST_MULTI,RCVD_IN_DNSWL_MED,UNPARSEABLE_RELAY 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 BFAFD2D429 for ; Wed, 6 Mar 2019 09:51:33 +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=iY29+P5UJq85M3NLqxv6RTKaSMADmltBhGF2syHXZ/Y=; b=g+wd9EnKDq6r8P Wy4w8mJopfuH45AAg+Xceo0lIf/FqPJUboBbuyX5h1b7m0qBsGErCsyTsvpTCvBWUTLXy+6Zt/Lut 4I7DRevR5bgs1dWuwXhJBme+zjNW51KsvFpozV5ASbUpAVGzMRM0qMRrHjdVahHe7qKcTFziLvZb5 kCGhinJ5ttM+Jhc3tlJU/BQulG9oULzwBPnHiQV4t7Xsj60WftpV902gkyheFWhYxvPWBVAJ7WP7b 7AxJMayH4w/2+uFkavmWiOw9wNkFAkuydQf0jMVPv9nHkPdJ3DwZZQa5iaFoXx54oJztk7UN8bsux UsOTSpwPs2MrS4Ukx/VA==; 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 1h1TCp-0004SF-19; Wed, 06 Mar 2019 09:51:19 +0000 Received: from mailgw01.mediatek.com ([216.200.240.184]) by bombadil.infradead.org with esmtps (Exim 4.90_1 #2 (Red Hat Linux)) id 1h1TCL-0003mL-C8; Wed, 06 Mar 2019 09:50:51 +0000 X-UUID: 6e31c36c337b463aa6814be11179c28f-20190306 X-UUID: 6e31c36c337b463aa6814be11179c28f-20190306 Received: from mtkcas68.mediatek.inc [(172.29.94.19)] by mailgw01.mediatek.com (envelope-from ) (musrelay.mediatek.com ESMTP with TLS) with ESMTP id 2004760382; Wed, 06 Mar 2019 01:50:45 -0800 Received: from MTKMBS01N1.mediatek.inc (172.21.101.68) by MTKMBS62DR.mediatek.inc (172.29.94.18) with Microsoft SMTP Server (TLS) id 15.0.1395.4; Wed, 6 Mar 2019 01:50:44 -0800 Received: from MTKCAS06.mediatek.inc (172.21.101.30) by mtkmbs01n1.mediatek.inc (172.21.101.68) with Microsoft SMTP Server (TLS) id 15.0.1395.4; Wed, 6 Mar 2019 17:50:37 +0800 Received: from mtkslt302.mediatek.inc (10.21.14.115) by MTKCAS06.mediatek.inc (172.21.101.73) with Microsoft SMTP Server id 15.0.1395.4 via Frontend Transport; Wed, 6 Mar 2019 17:50:37 +0800 From: Bibby Hsieh To: Jassi Brar , Matthias Brugger , Rob Herring , CK HU Subject: [PATCH v2 02/10] dt-binding: gce: add binding for gce event property Date: Wed, 6 Mar 2019 17:50:27 +0800 Message-ID: <1551865835-50974-3-git-send-email-bibby.hsieh@mediatek.com> X-Mailer: git-send-email 1.9.1 In-Reply-To: <1551865835-50974-1-git-send-email-bibby.hsieh@mediatek.com> References: <1551865835-50974-1-git-send-email-bibby.hsieh@mediatek.com> MIME-Version: 1.0 X-MTK: N X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20190306_015049_420067_DCF6C019 X-CRM114-Status: GOOD ( 12.14 ) X-BeenThere: linux-mediatek@lists.infradead.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: devicetree@vger.kernel.org, Nicolas Boichat , Philipp Zabel , srv_heupstream@mediatek.com, Daoyuan Huang , Sascha Hauer , linux-kernel@vger.kernel.org, Dennis-YC Hsieh , kendrick.hsu@mediatek.com, linux-mediatek@lists.infradead.org, Houlong Wei , Sascha Hauer , Frederic Chen , Jiaguang Zhang , Bibby Hsieh , linux-arm-kernel@lists.infradead.org, ginny.chen@mediatek.com Sender: "Linux-mediatek" Errors-To: linux-mediatek-bounces+patchwork-linux-mediatek=patchwork.kernel.org@lists.infradead.org X-Virus-Scanned: ClamAV using ClamSMTP cmdq driver provide a function that get event number from device node for client. add specification for #event-cells, mediatek,gce-event-names, mediatek,gce-events. Signed-off-by: Bibby Hsieh --- Documentation/devicetree/bindings/mailbox/mtk-gce.txt | 16 +++++++++++++--- 1 file changed, 13 insertions(+), 3 deletions(-) diff --git a/Documentation/devicetree/bindings/mailbox/mtk-gce.txt b/Documentation/devicetree/bindings/mailbox/mtk-gce.txt index 9c0d982..812698f 100644 --- a/Documentation/devicetree/bindings/mailbox/mtk-gce.txt +++ b/Documentation/devicetree/bindings/mailbox/mtk-gce.txt @@ -21,12 +21,20 @@ Required properties: priority: Priority of GCE thread. atomic_exec: GCE processing continuous packets of commands in atomic way. +- #event-cells: Should be 1. + <&phandle event_number> + phandle: Label name of a gce node. + event_number: the event number defined in 'dt-bindings/gce/mt8173-gce.h' + or 'dt-binding/gce/mt8183-gce.h'. Required properties for a client device: - mboxes: Client use mailbox to communicate with GCE, it should have this property and list of phandle, mailbox specifiers. - mediatek,gce-subsys: u32, specify the sub-system id which is corresponding to the register address. +- mediatek,gce-event-names: the event name can be defined by user. +- mediatek,gce-events: u32, the event number defined in + 'dt-bindings/gce/mt8173-gce.h' or 'dt-binding/gce/mt8183-gce.h'. Some vaules of properties are defined in 'dt-bindings/gce/mt8173-gce.h' or 'dt-binding/gce/mt8183-gce.h'. Such as sub-system ids, thread priority, event ids. @@ -41,6 +49,7 @@ Example: clock-names = "gce"; thread-num = CMDQ_THR_MAX_COUNT; #mbox-cells = <3>; + #event-cells = <1>; }; Example for a client device: @@ -50,8 +59,9 @@ Example for a client device: mboxes = <&gce 0 CMDQ_THR_PRIO_LOWEST 1>, <&gce 1 CMDQ_THR_PRIO_LOWEST 1>; mediatek,gce-subsys = ; - mutex-event-eof = ; - + mediatek,gce-event-names = "rdma0_sof", + "rsz0_sof"; + mediatek,gce-events = <&gce CMDQ_EVENT_MDP_RDMA0_SOF>, + <&gce CMDQ_EVENT_MDP_RSZ0_SOF>; ... };