From: "Russell King (Oracle)" <linux@armlinux.org.uk>
To: Sven Peter <sven@svenpeter.dev>
Cc: Jassi Brar <jassisinghbrar@gmail.com>,
Hector Martin <marcan@marcan.st>,
Alyssa Rosenzweig <alyssa@rosenzweig.io>,
asahi@lists.linux.dev, linux-arm-kernel@lists.infradead.org
Subject: Re: [PATCH 2/2] mailbox: apple: Implement poll_data() operation
Date: Tue, 6 Sep 2022 08:58:25 +0100 [thread overview]
Message-ID: <Yxb9oRcbz6qTddr+@shell.armlinux.org.uk> (raw)
In-Reply-To: <aea7b62d-9cc1-4590-9d6b-9419b5af62a2@www.fastmail.com>
On Mon, Sep 05, 2022 at 07:03:39PM +0200, Sven Peter wrote:
>
>
> On Mon, Sep 5, 2022, at 18:48, Russell King wrote:
> > From: Hector Martin <marcan@marcan.st>
> >
> > This allows clients running in atomic context to poll for messages to
> > arrive.
> >
> > Signed-off-by: Hector Martin <marcan@marcan.st>
> > Signed-off-by: Russell King (Oracle) <rmk+kernel@armlinux.org.uk>
>
> Reviewed-by: Sven Peter <sven@svenpeter.dev>
>
> with one small comment below:
>
> > ---
> > drivers/mailbox/apple-mailbox.c | 37 ++++++++++++++++++++++++++++++---
> > 1 file changed, 34 insertions(+), 3 deletions(-)
> >
> > diff --git a/drivers/mailbox/apple-mailbox.c b/drivers/mailbox/apple-mailbox.c
> > index 33e7acf71e3e..1c14ff63f3d3 100644
> > --- a/drivers/mailbox/apple-mailbox.c
> > +++ b/drivers/mailbox/apple-mailbox.c
> > @@ -26,6 +26,7 @@
> > #include <linux/module.h>
> > #include <linux/of.h>
> > #include <linux/platform_device.h>
> > +#include <linux/spinlock.h>
> > #include <linux/types.h>
> >
> > #define APPLE_ASC_MBOX_CONTROL_FULL BIT(16)
> > @@ -101,6 +102,7 @@ struct apple_mbox {
> >
> > struct device *dev;
> > struct mbox_controller controller;
> > + spinlock_t rx_lock;
> > };
> >
> > static const struct of_device_id apple_mbox_of_match[];
> > @@ -204,13 +206,16 @@ static irqreturn_t apple_mbox_send_empty_irq(int
> > irq, void *data)
> > return IRQ_HANDLED;
> > }
> >
> > -static irqreturn_t apple_mbox_recv_irq(int irq, void *data)
> > +static int apple_mbox_poll(struct apple_mbox *apple_mbox)
> > {
> > - struct apple_mbox *apple_mbox = data;
> > +
>
> small nit: there's a spurious white line here
Thanks, well spotted. Will fix.
--
RMK's Patch system: https://www.armlinux.org.uk/developer/patches/
FTTP is here! 40Mbps down 10Mbps up. Decent connectivity at last!
WARNING: multiple messages have this Message-ID (diff)
From: "Russell King (Oracle)" <linux@armlinux.org.uk>
To: Sven Peter <sven@svenpeter.dev>
Cc: Jassi Brar <jassisinghbrar@gmail.com>,
Hector Martin <marcan@marcan.st>,
Alyssa Rosenzweig <alyssa@rosenzweig.io>,
asahi@lists.linux.dev, linux-arm-kernel@lists.infradead.org
Subject: Re: [PATCH 2/2] mailbox: apple: Implement poll_data() operation
Date: Tue, 6 Sep 2022 08:58:25 +0100 [thread overview]
Message-ID: <Yxb9oRcbz6qTddr+@shell.armlinux.org.uk> (raw)
In-Reply-To: <aea7b62d-9cc1-4590-9d6b-9419b5af62a2@www.fastmail.com>
On Mon, Sep 05, 2022 at 07:03:39PM +0200, Sven Peter wrote:
>
>
> On Mon, Sep 5, 2022, at 18:48, Russell King wrote:
> > From: Hector Martin <marcan@marcan.st>
> >
> > This allows clients running in atomic context to poll for messages to
> > arrive.
> >
> > Signed-off-by: Hector Martin <marcan@marcan.st>
> > Signed-off-by: Russell King (Oracle) <rmk+kernel@armlinux.org.uk>
>
> Reviewed-by: Sven Peter <sven@svenpeter.dev>
>
> with one small comment below:
>
> > ---
> > drivers/mailbox/apple-mailbox.c | 37 ++++++++++++++++++++++++++++++---
> > 1 file changed, 34 insertions(+), 3 deletions(-)
> >
> > diff --git a/drivers/mailbox/apple-mailbox.c b/drivers/mailbox/apple-mailbox.c
> > index 33e7acf71e3e..1c14ff63f3d3 100644
> > --- a/drivers/mailbox/apple-mailbox.c
> > +++ b/drivers/mailbox/apple-mailbox.c
> > @@ -26,6 +26,7 @@
> > #include <linux/module.h>
> > #include <linux/of.h>
> > #include <linux/platform_device.h>
> > +#include <linux/spinlock.h>
> > #include <linux/types.h>
> >
> > #define APPLE_ASC_MBOX_CONTROL_FULL BIT(16)
> > @@ -101,6 +102,7 @@ struct apple_mbox {
> >
> > struct device *dev;
> > struct mbox_controller controller;
> > + spinlock_t rx_lock;
> > };
> >
> > static const struct of_device_id apple_mbox_of_match[];
> > @@ -204,13 +206,16 @@ static irqreturn_t apple_mbox_send_empty_irq(int
> > irq, void *data)
> > return IRQ_HANDLED;
> > }
> >
> > -static irqreturn_t apple_mbox_recv_irq(int irq, void *data)
> > +static int apple_mbox_poll(struct apple_mbox *apple_mbox)
> > {
> > - struct apple_mbox *apple_mbox = data;
> > +
>
> small nit: there's a spurious white line here
Thanks, well spotted. Will fix.
--
RMK's Patch system: https://www.armlinux.org.uk/developer/patches/
FTTP is here! 40Mbps down 10Mbps up. Decent connectivity at last!
_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
next prev parent reply other threads:[~2022-09-06 7:58 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-09-05 16:48 [PATCH 0/2] apple-mailbox: add support for atomc mailbox operations Russell King (Oracle)
2022-09-05 16:48 ` Russell King (Oracle)
2022-09-05 16:48 ` [PATCH 1/2] mailbox: apple: Implement flush() operation Russell King
2022-09-05 16:48 ` Russell King
2022-09-05 16:58 ` Sven Peter
2022-09-05 16:58 ` Sven Peter
2022-09-05 16:48 ` [PATCH 2/2] mailbox: apple: Implement poll_data() operation Russell King
2022-09-05 16:48 ` Russell King
2022-09-05 17:03 ` Sven Peter
2022-09-05 17:03 ` Sven Peter
2022-09-06 7:58 ` Russell King (Oracle) [this message]
2022-09-06 7:58 ` Russell King (Oracle)
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=Yxb9oRcbz6qTddr+@shell.armlinux.org.uk \
--to=linux@armlinux.org.uk \
--cc=alyssa@rosenzweig.io \
--cc=asahi@lists.linux.dev \
--cc=jassisinghbrar@gmail.com \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=marcan@marcan.st \
--cc=sven@svenpeter.dev \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.