Received: by 2002:a05:6359:c8b:b0:c7:702f:21d4 with SMTP id go11csp2496818rwb; Thu, 29 Sep 2022 10:56:04 -0700 (PDT) X-Google-Smtp-Source: AMsMyM4KFh4BxUa/N9X4p6E8SFJQwwlNojm2c7Qes+uITwV+HbctRONnx1cIXOnk6VV1cBjOJSvG X-Received: by 2002:a17:90b:4b11:b0:202:998b:71b1 with SMTP id lx17-20020a17090b4b1100b00202998b71b1mr5041937pjb.208.1664474164398; Thu, 29 Sep 2022 10:56:04 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1664474164; cv=none; d=google.com; s=arc-20160816; b=FLlJEMzpQHEFpgEyE9RrnNpKbbBHP7cxd9B9Qg3Zt6iDFmaGZA0VukmtiE7avbOhmL t+hO78orRYHM2fTRApYyATQyWQRQZxb5b+VDZNKqJQvWLxn6JSWwwB0sXayHpnq5df9H usuCd0aKnPYsWqfFUdYaMMbEoawon4jLdr5IpzMwmO+qOrVxGyTw4VRYC6VrwCwYjoVO QDGbkOjiw3Z8trgN9MzmISkqARRLE/ej8D77eZ9duyylVL5pb2xPsdEhDw4s2v+XGzoY u4qqTxjlxo1osOam6lOcN2344mWDTjQAYelBI/gMMvp9AcMC6rXSH2OP7fg7l8bEsKed 71Kg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:cc:to:subject:message-id:date:from:in-reply-to :references:mime-version:dkim-signature; bh=KTplSiuNaGRVGHmcAHJDO7FIE5Uxw7tsLd9tBIbz+hg=; b=ENKQHfWZfTLDfWJ5g7QRCg/E70SiyYTIS0p0d/wR4fu7lBkzXBFmebs2TKpKYo1cG9 3kWW3vghy9T9VMgFh+ScmPCh4it/qCE3RJX8wVzttP+qPEJjNL9RQ4ySPvqDxjykp9HC LlV7xq7vOyaC8friRRNFVlLgW0ETEMkALmrpvAXkqmJdyxXi8tmgTd2/pgG21BhP6OmL J3a9M705P0bMbPwV39uU+qnjHo86+EsriXvU9w10evSJ6tDbgDlF/EzB2Eb4J3Ikw5fN ueUS1/NM0utdsvV0Ln94SIKgvu/FRYa0Top6wsiX2I7VvCsST62Bg1PGegG8g1+IqZqM ksKA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20210112 header.b=DYQGSel2; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id kk8-20020a17090b4a0800b002006f9dc2e1si206578pjb.3.2022.09.29.10.55.52; Thu, 29 Sep 2022 10:56:04 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20210112 header.b=DYQGSel2; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234352AbiI2Rhb (ORCPT + 99 others); Thu, 29 Sep 2022 13:37:31 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:42468 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S235055AbiI2Rh1 (ORCPT ); Thu, 29 Sep 2022 13:37:27 -0400 Received: from mail-ej1-x62b.google.com (mail-ej1-x62b.google.com [IPv6:2a00:1450:4864:20::62b]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id D00D6123873; Thu, 29 Sep 2022 10:37:25 -0700 (PDT) Received: by mail-ej1-x62b.google.com with SMTP id lh5so4251909ejb.10; Thu, 29 Sep 2022 10:37:25 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:from:to:cc:subject:date; bh=KTplSiuNaGRVGHmcAHJDO7FIE5Uxw7tsLd9tBIbz+hg=; b=DYQGSel2ZufCHTaQSXdO0yn1SyYdDtR4dy4qLTygu79yK0az/iNW5w3jdP8qVGUcHn WL730l/ybcQhuB/mlHalJX/1m2Pe25iZ6rcZ5aP54T8C0A6ZcAxt2FHOgAC4Zs3LsY/R DnQ5D/t2SZU7NKOu/FvPzzvvs6kgx8mYmHNNvUvQWjHKzjtCfqJnDXvA/wb9DPlbn+42 3N+BCjNxUW0PlSG4o+F8r1wmseep5a4kWhyUrUhQ21jKC29oxAyUmuf89jd+KLQNGu7i bdiQAqTaQwR3Qy93S6gw6nMO8DeIOOVjX8sdUes6CKmwOwPXfnVQs+jwOLtYLwKqoeHf cC+Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:x-gm-message-state:from:to:cc:subject:date; bh=KTplSiuNaGRVGHmcAHJDO7FIE5Uxw7tsLd9tBIbz+hg=; b=Fquyqv0Z92u295UUDR99EOLKCOw/aoNBArIzny5FnzyPuVjlS/dueIr32Yf1T2qeHQ sIfQ1n0P4mjWS3faq7KYxDTv+6T/qkedVtkGgBNOOPtpgh+4/28tkd2kynIRPmCjy58u 24XjaQigMORQfUe5ZZtlrn+4QH/JV1KjiS8ikA+y+o9NlAkZntmq4P5/OGhpj1wgnerE lQ/lppYfZLyuJ9xeqi1IR93m7EARQjwbMMwdAs27kvUdoR2YUMYUL9emwPQ1bRPxMrQI iMKrQDUqxw/7OvAUfT9c3vKaCG9I3LZIwq/zKQjGwwhhwHHeubjhyyF+n7AVsHfVfhBK l/IQ== X-Gm-Message-State: ACrzQf1ECjA4wvLBDscW2pG23zh9AfAY25DbVVMlI69flDXXcxxDUJPt +KWRDnjlTi7Gff6EpljnRAdP79QbmC5W5S4vt6c= X-Received: by 2002:a17:906:8a5b:b0:781:7009:965e with SMTP id gx27-20020a1709068a5b00b007817009965emr3470982ejc.625.1664473044320; Thu, 29 Sep 2022 10:37:24 -0700 (PDT) MIME-Version: 1.0 References: <20220928195633.2348848-1-quic_eberman@quicinc.com> <20220928195633.2348848-10-quic_eberman@quicinc.com> <20220929165908.zgmlujhp42ihine5@builder.lan> In-Reply-To: <20220929165908.zgmlujhp42ihine5@builder.lan> From: Jassi Brar Date: Thu, 29 Sep 2022 12:37:12 -0500 Message-ID: Subject: Re: [PATCH v4 09/14] mailbox: Add Gunyah message queue mailbox To: Bjorn Andersson Cc: Elliot Berman , Bjorn Andersson , Murali Nalajala , Trilok Soni , Srivatsa Vaddagiri , Carl van Schaik , Andy Gross , Dmitry Baryshkov , linux-arm-kernel@lists.infradead.org, Mark Rutland , Lorenzo Pieralisi , Sudeep Holla , Marc Zyngier , Rob Herring , Krzysztof Kozlowski , Jonathan Corbet , Will Deacon , Catalin Marinas , Arnd Bergmann , Greg Kroah-Hartman , devicetree@vger.kernel.org, linux-doc@vger.kernel.org, linux-arm-msm@vger.kernel.org, linux-kernel@vger.kernel.org Content-Type: text/plain; charset="UTF-8" X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,FREEMAIL_FROM, RCVD_IN_DNSWL_NONE,SPF_HELO_NONE,SPF_PASS autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, Sep 29, 2022 at 11:59 AM Bjorn Andersson wrote: > > On Wed, Sep 28, 2022 at 12:56:28PM -0700, Elliot Berman wrote: > [..] > > diff --git a/drivers/mailbox/gunyah-msgq.c b/drivers/mailbox/gunyah-msgq.c > [..] > > +static int gh_msgq_send_data(struct mbox_chan *chan, void *data) > > +{ > > + struct gunyah_msgq *msgq = mbox_chan_to_msgq(chan); > > + struct gunyah_msgq_tx_data *msgq_data = data; > > The mailbox framework abstracts hardware mailboxes and @data > should be the data to be written to the hardware. > > Using the void * to pass composite data types means that the client and > provider are tightly coupled and as such the mailbox framework does not > provide you any abstraction. > It is so for every platform, because there is no "standard format" in which data is to be exchanged between endpoints. Mailbox api is used mainly to avoid redoing message queuing and response handling. cheers.