From: Jassi Brar <jassisinghbrar@gmail.com>
To: Lee Jones <lee.jones@linaro.org>
Cc: "linux-arm-kernel@lists.infradead.org"
<linux-arm-kernel@lists.infradead.org>,
Linux Kernel Mailing List <linux-kernel@vger.kernel.org>,
kernel@stlinux.com, Devicetree List <devicetree@vger.kernel.org>
Subject: Re: [PATCH v2 2/6] mailbox: dt-bindings: Add shared [driver <=> device tree] defines
Date: Mon, 10 Aug 2015 14:17:19 +0530 [thread overview]
Message-ID: <CABb+yY3jUKXXJys32bHY1u+dbdsix71Xq_H1Lrkkt27vZzmf7w@mail.gmail.com> (raw)
In-Reply-To: <20150810082445.GA3249@x1>
On Mon, Aug 10, 2015 at 1:54 PM, Lee Jones <lee.jones@linaro.org> wrote:
> On Mon, 10 Aug 2015, Jassi Brar wrote:
>> On Mon, Jul 27, 2015 at 3:14 PM, Lee Jones <lee.jones@linaro.org> wrote:
>> > This header is currently only used for defines pertaining to data
>> > direction i.e. Rx, Tx or Loopback.
>> >
>> > Signed-off-by: Lee Jones <lee.jones@linaro.org>
>> > ---
>> > include/dt-bindings/mailbox/mailbox.h | 14 ++++++++++++++
>> > 1 file changed, 14 insertions(+)
>> > create mode 100644 include/dt-bindings/mailbox/mailbox.h
>> >
>> > diff --git a/include/dt-bindings/mailbox/mailbox.h b/include/dt-bindings/mailbox/mailbox.h
>> > new file mode 100644
>> > index 0000000..82e929a
>> > --- /dev/null
>> > +++ b/include/dt-bindings/mailbox/mailbox.h
>> > @@ -0,0 +1,14 @@
>> > +/*
>> > + * This program is free software; you can redistribute it and/or modify
>> > + * it under the terms of the GNU General Public License version 2 as
>> > + * published by the Free Software Foundation.
>> > + */
>> > +
>> > +#ifndef __MAILBOX_CONTROLLER_DT_BINDINGS_H
>> > +#define __MAILBOX_CONTROLLER_DT_BINDINGS_H
>> > +
>> > +#define MBOX_TX 0x1
>> > +#define MBOX_RX 0x2
>> > +#define MBOX_LOOPBACK (MBOX_RX | MBOX_TX)
>> > +
>> Not sure I understand 'loopback'. Does it mean h/w has some
>> 'loopback' mode for testing purposes? Or it simply means the
>> controller can send as well as receive messages?
>
> 'loopback' allows firmware to conduct some early function tests.
> However, channels are simplex, so we provide protection against
> multiple allocation of single channel. By allocating a LOOPBACK
> channel we over-ride this protection and allow a single channel to be
> allocated twice, once for Rx and the other for Tx.
>
So basically hardware is half-duplex, not simplex. I think maybe you
should simply allow for RX and TX always. It should work. Just
handover any received data before send_data (reflecting the h/w
limitation). That way you don't need any such special flag.
next prev parent reply other threads:[~2015-08-10 8:47 UTC|newest]
Thread overview: 35+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-07-27 9:44 [PATCH v2 0/6] Mailbox: Provide support STi based platforms Lee Jones
2015-07-27 9:44 ` [PATCH v2 1/6] mailbox: dt: Supply bindings for ST's Mailbox IP Lee Jones
2015-07-27 9:44 ` [PATCH v2 2/6] mailbox: dt-bindings: Add shared [driver <=> device tree] defines Lee Jones
2015-08-10 6:58 ` Jassi Brar
2015-08-10 8:24 ` Lee Jones
2015-08-10 8:47 ` Jassi Brar [this message]
2015-08-12 8:53 ` Lee Jones
2015-08-12 10:16 ` Jassi Brar
2015-08-12 10:43 ` Lee Jones
2015-07-27 9:44 ` [PATCH v2 3/6] mailbox: Add support for ST's Mailbox IP Lee Jones
2015-07-28 22:06 ` Paul Bolle
2015-07-30 11:45 ` Lee Jones
2015-07-30 12:48 ` Paul Bolle
2015-07-30 13:31 ` Lee Jones
2015-08-13 15:40 ` Jassi Brar
2015-08-14 6:33 ` Lee Jones
2015-08-14 7:39 ` Jassi Brar
2015-08-14 10:41 ` Lee Jones
2015-07-27 9:44 ` [PATCH v2 4/6] ARM: STi: stih407-family: Add nodes for Mailbox Lee Jones
2015-07-27 9:44 ` [PATCH v2 5/6] mailbox: Add generic mechanism for testing Mailbox Controllers Lee Jones
2015-08-10 6:45 ` Jassi Brar
2015-08-12 10:23 ` Lee Jones
2015-08-13 8:51 ` Jassi Brar
2015-08-13 9:19 ` Lee Jones
2015-08-13 10:01 ` Jassi Brar
2015-08-13 10:23 ` Lee Jones
2015-08-13 10:41 ` Jassi Brar
2015-08-13 11:00 ` Lee Jones
2015-08-13 11:10 ` Jassi Brar
2015-08-13 11:40 ` Lee Jones
2015-08-13 12:47 ` Jassi Brar
2015-08-13 13:07 ` Lee Jones
2015-08-13 13:46 ` Jassi Brar
2015-08-13 14:26 ` Lee Jones
2015-07-27 9:44 ` [PATCH v2 6/6] ARM: STi: DT: STiH407: Enable Mailbox testing facility Lee Jones
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=CABb+yY3jUKXXJys32bHY1u+dbdsix71Xq_H1Lrkkt27vZzmf7w@mail.gmail.com \
--to=jassisinghbrar@gmail.com \
--cc=devicetree@vger.kernel.org \
--cc=kernel@stlinux.com \
--cc=lee.jones@linaro.org \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-kernel@vger.kernel.org \
/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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).