Message ID | 20230213232537.2040976-1-quic_eberman@quicinc.com |
---|---|
Headers |
Return-Path: <linux-kernel-owner@vger.kernel.org> Delivered-To: ouuuleilei@gmail.com Received: by 2002:adf:eb09:0:0:0:0:0 with SMTP id s9csp2645074wrn; Mon, 13 Feb 2023 15:47:29 -0800 (PST) X-Google-Smtp-Source: AK7set9TSzbw4g4JxEYdw0medyPNxge3efFOJHtRUCfqqLSqrjjzjzfyUS5P8qwa/2hxJXcA4H8d X-Received: by 2002:a50:9b18:0:b0:4ac:b31c:83d3 with SMTP id o24-20020a509b18000000b004acb31c83d3mr481608edi.14.1676332048855; Mon, 13 Feb 2023 15:47:28 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1676332048; cv=none; d=google.com; s=arc-20160816; b=rKfVtBF1Dro5U6ibltak1q/f1PlYHCjAp+MDzpsktEIwhR7hRU+ks5DEvY6i9II3k9 IcdugVw9/F2LYEtUJo5nE8QxBILYwoffOadTEcXdOHjNsnR/LXDqIxvI9XG8So9tbzGq O1OY2UY1iAgFq4TjLj36GeXGe0vRQhaztzIgqct+FVdVlronegAnMYzMS+ruBqiMNPZg HE1a+8VTMuLz9W42Yy9x7J2I08EaVYUx5sxAIPE34nKaYXaBgkVkTtK0H96CsdCpSPSm fpJNXV99oHM+tMWwOa7ADIwGzmIG/cqHp9NpVMskZxtOY9hYoExYn/C+LabEsfajQaxl VTlQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :message-id:date:subject:cc:to:from:dkim-signature; bh=9zOsI7wDgUioyr1LYFvU/oJQKYz2SyKvRYNSma0iYpQ=; b=Pcv8+X5ZihHEdkilB8AsqOG5y8l0JzxoTzfuG4WHOVMC0kMJi6pz1VKtE2//NZVzLf I3sbxvUmSRHg8SzZo479z7py1Rv5r4zyaSXyUmISKgLNulxocAlw8fDQUf0tua60LONl yop+ssyc+spNUqAOMzve6EgVdTZrl17kUL+Mt50PnzKK+UqN4bKjOgo+Yj4x8ofnZdhj mGI8/pD3ZXfhc7PNCZZY4mlYdi3ZCtJxPbN7DhjK161eRMY5uZUPGGzwuYkWniCvp2qz CAPLhc1Ri6i1h6z0FQwW78OKCybcdzz1njuhZRHhT2s+wRSpzsPtrmvv7EVZH63DpZpF XgxQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@quicinc.com header.s=qcppdkim1 header.b=dt0UaPjU; 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=NONE dis=NONE) header.from=quicinc.com Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id m7-20020aa7d347000000b004ab4d025978si10795829edr.245.2023.02.13.15.47.05; Mon, 13 Feb 2023 15:47:28 -0800 (PST) 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=@quicinc.com header.s=qcppdkim1 header.b=dt0UaPjU; 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=NONE dis=NONE) header.from=quicinc.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230459AbjBMX0V (ORCPT <rfc822;tebrre53rla2o@gmail.com> + 99 others); Mon, 13 Feb 2023 18:26:21 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:39836 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230367AbjBMX0U (ORCPT <rfc822;linux-kernel@vger.kernel.org>); Mon, 13 Feb 2023 18:26:20 -0500 Received: from mx0a-0031df01.pphosted.com (mx0a-0031df01.pphosted.com [205.220.168.131]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 4B03D9D; Mon, 13 Feb 2023 15:26:19 -0800 (PST) Received: from pps.filterd (m0279864.ppops.net [127.0.0.1]) by mx0a-0031df01.pphosted.com (8.17.1.19/8.17.1.19) with ESMTP id 31DMXXEo006618; Mon, 13 Feb 2023 23:26:15 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=quicinc.com; h=from : to : cc : subject : date : message-id : mime-version : content-transfer-encoding : content-type; s=qcppdkim1; bh=9zOsI7wDgUioyr1LYFvU/oJQKYz2SyKvRYNSma0iYpQ=; b=dt0UaPjUxGFQVPgKkEB/KKbQB/rInofyOQz5ph0A2DspCfXW0TahZyP0xV0O5SxYPuV6 WfAxfvHqspt+XiO56cP+HlhaPMfg/bqvXBlksKO5amUDtffpW/NE/29i8CF3R2IyHc4d DXxxce4WRC4kp4eduDBL1ViKTx38Xv43TfTTAFLsDSHiYscEgvdtxemBL/dTHaMuIkwF CkhgXIlX6Plm9VXRfZABPxSn9GECSmBMsXxRfNniZ8pRNL0rnPUZDgtRyRBegOvuCOQp QSV9jIWEjCOyM4QpfVzeQ9D9e6duqfZlGPzFB6bAev1e9FqYY6m3FP1xyD+tgVf0WQgQ AQ== Received: from nasanppmta02.qualcomm.com (i-global254.qualcomm.com [199.106.103.254]) by mx0a-0031df01.pphosted.com (PPS) with ESMTPS id 3nqpmmh4y5-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Mon, 13 Feb 2023 23:26:15 +0000 Received: from nasanex01b.na.qualcomm.com (nasanex01b.na.qualcomm.com [10.46.141.250]) by NASANPPMTA02.qualcomm.com (8.17.1.5/8.17.1.5) with ESMTPS id 31DNQEe7015102 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Mon, 13 Feb 2023 23:26:14 GMT Received: from hu-eberman-lv.qualcomm.com (10.49.16.6) by nasanex01b.na.qualcomm.com (10.46.141.250) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.986.36; Mon, 13 Feb 2023 15:26:13 -0800 From: Elliot Berman <quic_eberman@quicinc.com> To: Jassi Brar <jassisinghbrar@gmail.com> CC: Elliot Berman <quic_eberman@quicinc.com>, Sudeep Holla <sudeep.holla@arm.com>, <linux-kernel@vger.kernel.org>, <linux-acpi@vger.kernel.org>, <linux-arm-msm@vger.kernel.org> Subject: [PATCH 0/3] mailbox: Allow direct registration to a channel Date: Mon, 13 Feb 2023 15:25:34 -0800 Message-ID: <20230213232537.2040976-1-quic_eberman@quicinc.com> X-Mailer: git-send-email 2.39.1 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Content-Type: text/plain X-Originating-IP: [10.49.16.6] X-ClientProxiedBy: nalasex01b.na.qualcomm.com (10.47.209.197) To nasanex01b.na.qualcomm.com (10.46.141.250) X-QCInternal: smtphost X-Proofpoint-Virus-Version: vendor=nai engine=6200 definitions=5800 signatures=585085 X-Proofpoint-ORIG-GUID: qe4rdIla3ZIoRo8CM9jeNAGxf6fWRCgt X-Proofpoint-GUID: qe4rdIla3ZIoRo8CM9jeNAGxf6fWRCgt X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.219,Aquarius:18.0.930,Hydra:6.0.562,FMLib:17.11.170.22 definitions=2023-02-13_12,2023-02-13_01,2023-02-09_01 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 lowpriorityscore=0 spamscore=0 priorityscore=1501 suspectscore=0 adultscore=0 impostorscore=0 bulkscore=0 clxscore=1011 mlxscore=0 mlxlogscore=651 phishscore=0 malwarescore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.12.0-2212070000 definitions=main-2302130205 X-Spam-Status: No, score=-2.8 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_LOW,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: <linux-kernel.vger.kernel.org> X-Mailing-List: linux-kernel@vger.kernel.org X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1757761554149274737?= X-GMAIL-MSGID: =?utf-8?q?1757761554149274737?= |
Series |
mailbox: Allow direct registration to a channel
|
|
Message
Elliot Berman
Feb. 13, 2023, 11:25 p.m. UTC
Two mailbox controllers have channel/client binding mechanisms that are controller-specific and not using the devicetree binding mechanisms. Mailbox channel/client is conceptually done in two steps: selecting the channel and binding the selected to channel to a client. Channel selection is sometimes controller specific (pcc and omap are examples). The channel/client binding code is all the same. This small series de-duplicates and refactors the channel/client binding into a common framework function: "mbox_bind_client" which all of the channel selection mechanisms can use. I found this duplicate code while working on the support for Gunyah hypervisor message queues [1]. I've only been able to compile-test omap-maiblox and pcc, however it is a straightforward conversion here. [1]: https://lore.kernel.org/all/20230120224627.4053418-9-quic_eberman@quicinc.com/ Elliot Berman (3): mailbox: Allow direct registration to a channel mailbox: omap: Use mbox_bind_client mailbox: pcc: Use mbox_bind_client drivers/mailbox/mailbox.c | 96 ++++++++++++++++++++++++---------- drivers/mailbox/omap-mailbox.c | 22 ++------ drivers/mailbox/pcc.c | 82 ++++++++++++++++------------- include/linux/mailbox_client.h | 1 + 4 files changed, 118 insertions(+), 83 deletions(-) base-commit: 09e41676e35ab06e4bce8870ea3bf1f191c3cb90
Comments
On Mon, Feb 13, 2023 at 03:25:34PM -0800, Elliot Berman wrote: > Two mailbox controllers have channel/client binding mechanisms that are > controller-specific and not using the devicetree binding mechanisms. Mailbox > channel/client is conceptually done in two steps: selecting the channel > and binding the selected to channel to a client. Channel selection is sometimes > controller specific (pcc and omap are examples). The channel/client binding > code is all the same. > > This small series de-duplicates and refactors the channel/client binding > into a common framework function: "mbox_bind_client" which all of the > channel selection mechanisms can use. > > I found this duplicate code while working on the support for Gunyah hypervisor > message queues [1]. I've only been able to compile-test omap-maiblox and pcc, > however it is a straightforward conversion here. > > [1]: https://lore.kernel.org/all/20230120224627.4053418-9-quic_eberman@quicinc.com/ > > Elliot Berman (3): > mailbox: Allow direct registration to a channel I am unable to find the above patch either in my inbox or in lore[1]. Can you please repost the same ? I would like to test/review w.r.t PCC driver. -- Regards, Sudeep [1] https://lore.kernel.org/all/20230213232537.2040976-1-quic_eberman@quicinc.com/
On 2/15/2023 2:17 AM, Sudeep Holla wrote: > On Mon, Feb 13, 2023 at 03:25:34PM -0800, Elliot Berman wrote: >> Two mailbox controllers have channel/client binding mechanisms that are >> controller-specific and not using the devicetree binding mechanisms. Mailbox >> channel/client is conceptually done in two steps: selecting the channel >> and binding the selected to channel to a client. Channel selection is sometimes >> controller specific (pcc and omap are examples). The channel/client binding >> code is all the same. >> >> This small series de-duplicates and refactors the channel/client binding >> into a common framework function: "mbox_bind_client" which all of the >> channel selection mechanisms can use. >> >> I found this duplicate code while working on the support for Gunyah hypervisor >> message queues [1]. I've only been able to compile-test omap-maiblox and pcc, >> however it is a straightforward conversion here. >> >> [1]: https://lore.kernel.org/all/20230120224627.4053418-9-quic_eberman@quicinc.com/ >> >> Elliot Berman (3): >> mailbox: Allow direct registration to a channel > > I am unable to find the above patch either in my inbox or in lore[1]. > Can you please repost the same ? I would like to test/review w.r.t PCC > driver. > Hi Sudeep, Not sure why the patch didn't end up your inbox; lore seems to have linked it correctly and indicates you were in To:. If I missed something, let me know and I'll make sure you're properly included if future versions needed. https://lore.kernel.org/all/20230213232537.2040976-4-quic_eberman@quicinc.com/ Thanks, Elliot > -- > Regards, > Sudeep > > [1] https://lore.kernel.org/all/20230213232537.2040976-1-quic_eberman@quicinc.com/ >
On Wed, Feb 15, 2023 at 08:58:10AM -0800, Elliot Berman wrote: > > > On 2/15/2023 2:17 AM, Sudeep Holla wrote: > > On Mon, Feb 13, 2023 at 03:25:34PM -0800, Elliot Berman wrote: > > > Two mailbox controllers have channel/client binding mechanisms that are > > > controller-specific and not using the devicetree binding mechanisms. Mailbox > > > channel/client is conceptually done in two steps: selecting the channel > > > and binding the selected to channel to a client. Channel selection is sometimes > > > controller specific (pcc and omap are examples). The channel/client binding > > > code is all the same. > > > > > > This small series de-duplicates and refactors the channel/client binding > > > into a common framework function: "mbox_bind_client" which all of the > > > channel selection mechanisms can use. > > > > > > I found this duplicate code while working on the support for Gunyah hypervisor > > > message queues [1]. I've only been able to compile-test omap-maiblox and pcc, > > > however it is a straightforward conversion here. > > > > > > [1]: https://lore.kernel.org/all/20230120224627.4053418-9-quic_eberman@quicinc.com/ > > > > > > Elliot Berman (3): > > > mailbox: Allow direct registration to a channel > > > > I am unable to find the above patch either in my inbox or in lore[1]. > > Can you please repost the same ? I would like to test/review w.r.t PCC > > driver. > > > > Hi Sudeep, > > Not sure why the patch didn't end up your inbox; lore seems to have linked > it correctly and indicates you were in To:. If I missed something, let me > know and I'll make sure you're properly included if future versions needed. > > https://lore.kernel.org/all/20230213232537.2040976-4-quic_eberman@quicinc.com/ No, I do have patch 2/3 and 3/3 in my inbox along with the cover letter. Patch 1/3 is missing in both my inbox and lore. Can you send me the lore link for patch 1/3 if you are able to find it ? Or just repost the series if you can't.
On 2/16/2023 1:58 AM, Sudeep Holla wrote: > On Wed, Feb 15, 2023 at 08:58:10AM -0800, Elliot Berman wrote: >> >> >> On 2/15/2023 2:17 AM, Sudeep Holla wrote: >>> On Mon, Feb 13, 2023 at 03:25:34PM -0800, Elliot Berman wrote: >>>> Two mailbox controllers have channel/client binding mechanisms that are >>>> controller-specific and not using the devicetree binding mechanisms. Mailbox >>>> channel/client is conceptually done in two steps: selecting the channel >>>> and binding the selected to channel to a client. Channel selection is sometimes >>>> controller specific (pcc and omap are examples). The channel/client binding >>>> code is all the same. >>>> >>>> This small series de-duplicates and refactors the channel/client binding >>>> into a common framework function: "mbox_bind_client" which all of the >>>> channel selection mechanisms can use. >>>> >>>> I found this duplicate code while working on the support for Gunyah hypervisor >>>> message queues [1]. I've only been able to compile-test omap-maiblox and pcc, >>>> however it is a straightforward conversion here. >>>> >>>> [1]: https://lore.kernel.org/all/20230120224627.4053418-9-quic_eberman@quicinc.com/ >>>> >>>> Elliot Berman (3): >>>> mailbox: Allow direct registration to a channel >>> >>> I am unable to find the above patch either in my inbox or in lore[1]. >>> Can you please repost the same ? I would like to test/review w.r.t PCC >>> driver. >>> >> >> Hi Sudeep, >> >> Not sure why the patch didn't end up your inbox; lore seems to have linked >> it correctly and indicates you were in To:. If I missed something, let me >> know and I'll make sure you're properly included if future versions needed. >> >> https://lore.kernel.org/all/20230213232537.2040976-4-quic_eberman@quicinc.com/ > > No, I do have patch 2/3 and 3/3 in my inbox along with the cover letter. > Patch 1/3 is missing in both my inbox and lore. Can you send me the lore > link for patch 1/3 if you are able to find it ? Or just repost the series > if you can't. > Huh, not sure what happened there. I got a copy of Patch 1/3 but I also don't see it in lore. Resent: https://lore.kernel.org/all/20230216163804.456714-1-quic_eberman@quicinc.com/
On Thu, Feb 16, 2023 at 08:41:05AM -0800, Elliot Berman wrote: > > > On 2/16/2023 1:58 AM, Sudeep Holla wrote: > > On Wed, Feb 15, 2023 at 08:58:10AM -0800, Elliot Berman wrote: > > > > > > > > > On 2/15/2023 2:17 AM, Sudeep Holla wrote: > > > > On Mon, Feb 13, 2023 at 03:25:34PM -0800, Elliot Berman wrote: > > > > > Two mailbox controllers have channel/client binding mechanisms that are > > > > > controller-specific and not using the devicetree binding mechanisms. Mailbox > > > > > channel/client is conceptually done in two steps: selecting the channel > > > > > and binding the selected to channel to a client. Channel selection is sometimes > > > > > controller specific (pcc and omap are examples). The channel/client binding > > > > > code is all the same. > > > > > > > > > > This small series de-duplicates and refactors the channel/client binding > > > > > into a common framework function: "mbox_bind_client" which all of the > > > > > channel selection mechanisms can use. > > > > > > > > > > I found this duplicate code while working on the support for Gunyah hypervisor > > > > > message queues [1]. I've only been able to compile-test omap-maiblox and pcc, > > > > > however it is a straightforward conversion here. > > > > > > > > > > [1]: https://lore.kernel.org/all/20230120224627.4053418-9-quic_eberman@quicinc.com/ > > > > > > > > > > Elliot Berman (3): > > > > > mailbox: Allow direct registration to a channel > > > > > > > > I am unable to find the above patch either in my inbox or in lore[1]. > > > > Can you please repost the same ? I would like to test/review w.r.t PCC > > > > driver. > > > > > > > > > > Hi Sudeep, > > > > > > Not sure why the patch didn't end up your inbox; lore seems to have linked > > > it correctly and indicates you were in To:. If I missed something, let me > > > know and I'll make sure you're properly included if future versions needed. > > > > > > https://lore.kernel.org/all/20230213232537.2040976-4-quic_eberman@quicinc.com/ > > > > No, I do have patch 2/3 and 3/3 in my inbox along with the cover letter. > > Patch 1/3 is missing in both my inbox and lore. Can you send me the lore > > link for patch 1/3 if you are able to find it ? Or just repost the series > > if you can't. > > > > Huh, not sure what happened there. I got a copy of Patch 1/3 but I also > don't see it in lore. Resent: > > https://lore.kernel.org/all/20230216163804.456714-1-quic_eberman@quicinc.com/ Thanks. You can add(tested PCC driver) Tested-by: Sudeep Holla <sudeep.holla@arm.com>