From patchwork Fri Nov 3 14:47:38 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Sudeep Holla X-Patchwork-Id: 117932 Delivered-To: patch@linaro.org Received: by 10.80.245.45 with SMTP id t42csp3405758edm; Fri, 3 Nov 2017 07:53:37 -0700 (PDT) X-Google-Smtp-Source: ABhQp+QnDcqL3+uYpE/G14lJAciPLfMC/15K31214L7R0Vk8a0q2A4lLY2i0uPxycfkjp7Maa790 X-Received: by 10.98.147.23 with SMTP id b23mr7944200pfe.5.1509720817819; Fri, 03 Nov 2017 07:53:37 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1509720817; cv=none; d=google.com; s=arc-20160816; b=T5WmtQMzji6dSh2votsYyZyokBbBK/xW6E6tMsjXSq4BfDmTkccFHo6G3934t3JPCa VnFdBGJ0e+3VJFopFAJQQdkYG8CFhlJ0i0O7up2X1ZHKjeMALWjw80yZ4IjlzhUvWvgR SFZbb31HgyAycRpbDviQhMVXn5I/NV5fkYrz8KQRnydBhDj1hHEGg8PTiIGucONZDSul /8ScbmtSB4b0X1M48xBMxbetoe5F4rCftqCMDl9GlcTa6aGMDAfcju2tAS7+fuc5OVSQ 3Xhr9uiDMb+sJ5X9gKdNSy/Kcp3f7yxTR+kIg74YqiT5ZeydiP1BwVNogGgU95OP04bb XUyA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:references:in-reply-to:message-id:date :subject:cc:to:from:arc-authentication-results; bh=gxGR7bZ00RcPMxdzG1zm0ZpuijseVr2VvuB23nvc6So=; b=sFL6fd9eVq3KZGwvxiWA+mCY7F94wIl/LT3tJJzGSZcD6llbYB3QptkzsXIV1lmRRU AhP2oJ0MewbyRNdC76ZrFFwtLtbzw5VKE7S89Cw1htSqBRTxP9Qs6gCKrrz055PQKFnt ayiD9Fi+Zg6NfCxF9YzQ0BlBhWDDP1acPXEUSK/JiaJR6pZZPxOgX3e7GCYeE36C7iqY PgVCOrIjMq2lPDXf52SNyYa3Y2p9XJPj2cuTw0AHzeh0ZV4TtLmtdcEv9pH9ROkRzp5K hyzO4slr6q/rmzRWWHGLRsn8lINMne69Ii0y0Xcl8DnuFxkcnyKnIB3W/z1cy+7fCfdy 143A== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id 1si4960949plh.303.2017.11.03.07.53.37; Fri, 03 Nov 2017 07:53:37 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1755908AbdKCOxg (ORCPT + 26 others); Fri, 3 Nov 2017 10:53:36 -0400 Received: from foss.arm.com ([217.140.101.70]:44210 "EHLO foss.arm.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752377AbdKCOsw (ORCPT ); Fri, 3 Nov 2017 10:48:52 -0400 Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.72.51.249]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id 521981596; Fri, 3 Nov 2017 07:48:52 -0700 (PDT) Received: from e107155-lin.cambridge.arm.com (e107155-lin.cambridge.arm.com [10.1.210.28]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPA id 1BF6C3F3DF; Fri, 3 Nov 2017 07:48:49 -0700 (PDT) From: Sudeep Holla To: ALKML , LKML , DTML Cc: Sudeep Holla , Roy Franz , Harb Abdulhamid , Nishanth Menon , Arnd Bergmann , Loc Ho , Ryan Harkin , Jassi Brar , Rob Herring , Mark Rutland Subject: [PATCH v4 01/20] dt-bindings: mailbox: add support for mailbox client shared memory Date: Fri, 3 Nov 2017 14:47:38 +0000 Message-Id: <1509720477-18936-2-git-send-email-sudeep.holla@arm.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1509720477-18936-1-git-send-email-sudeep.holla@arm.com> References: <1509720477-18936-1-git-send-email-sudeep.holla@arm.com> Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Many users of the mailbox controllers depend on the shared memory between the two end points to exchange the main data while using simple doorbell mechanism to alert the end points of the presence of a message. This patch defines device tree bindings to represent such shared memory in a generic way. Cc: Rob Herring Cc: Mark Rutland Acked-by: Rob Herring Signed-off-by: Sudeep Holla --- .../devicetree/bindings/mailbox/mailbox.txt | 28 ++++++++++++++++++++++ 1 file changed, 28 insertions(+) -- 2.7.4 diff --git a/Documentation/devicetree/bindings/mailbox/mailbox.txt b/Documentation/devicetree/bindings/mailbox/mailbox.txt index be05b9746c69..af8ecee2ac68 100644 --- a/Documentation/devicetree/bindings/mailbox/mailbox.txt +++ b/Documentation/devicetree/bindings/mailbox/mailbox.txt @@ -23,6 +23,11 @@ assign appropriate mailbox channel to client drivers. Optional property: - mbox-names: List of identifier strings for each mailbox channel. +- shmem : List of phandle pointing to the shared memory(SHM) area between the + users of these mailboxes for IPC, one for each mailbox. This shared + memory can be part of any memory reserved for the purpose of this + communication between the mailbox client and the remote. + Example: pwr_cntrl: power { @@ -30,3 +35,26 @@ assign appropriate mailbox channel to client drivers. mbox-names = "pwr-ctrl", "rpc"; mboxes = <&mailbox 0 &mailbox 1>; }; + +Example with shared memory(shmem): + + sram: sram@50000000 { + compatible = "mmio-sram"; + reg = <0x50000000 0x10000>; + + #address-cells = <1>; + #size-cells = <1>; + ranges = <0 0x50000000 0x10000>; + + cl_shmem: shmem@0 { + compatible = "client-shmem"; + reg = <0x0 0x200>; + }; + }; + + client@2e000000 { + ... + mboxes = <&mailbox 0>; + shmem = <&cl_shmem>; + .. + };