From: Leo Yan <leo.yan-QSEj5FYQhm4dnm+yROfE0A@public.gmane.org>
To: Jassi Brar <jassisinghbrar-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
Cc: Kaihua Zhong
<zhongkaihua-hv44wF8Li93QT0dZR+AlfA@public.gmane.org>,
Rob Herring <robh+dt-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org>,
Mark Rutland <mark.rutland-5wv7dgnIgG8@public.gmane.org>,
Wei Xu <xuwei5-C8/M+/jPZTeaMJb+Lgu22Q@public.gmane.org>,
Catalin Marinas <catalin.marinas-5wv7dgnIgG8@public.gmane.org>,
Will Deacon <will.deacon-5wv7dgnIgG8@public.gmane.org>,
Devicetree List
<devicetree-u79uwXL29TY76Z2rM5mHXA@public.gmane.org>,
Linux Kernel Mailing List
<linux-kernel-u79uwXL29TY76Z2rM5mHXA@public.gmane.org>,
linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r@public.gmane.org,
Guodong Xu <guodong.xu-QSEj5FYQhm4dnm+yROfE0A@public.gmane.org>,
Haojian Zhuang
<haojian.zhuang-QSEj5FYQhm4dnm+yROfE0A@public.gmane.org>,
suzhuangluan-C8/M+/jPZTeaMJb+Lgu22Q@public.gmane.org,
xuezhiliang-C8/M+/jPZTeaMJb+Lgu22Q@public.gmane.org,
kevin.wangtao-C8/M+/jPZTeaMJb+Lgu22Q@public.gmane.org
Subject: Re: [PATCH v4 2/3] mailbox: Add support for Hi3660 mailbox
Date: Fri, 5 Jan 2018 16:08:55 +0800 [thread overview]
Message-ID: <20180105080854.GB26855@leoy-linaro> (raw)
In-Reply-To: <CABb+yY2z4jDWJdDY2WRw5Mhv+ArTuvLgqJ9RyVoUJj3O1d=o6A-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
Hi Jassi,
On Fri, Jan 05, 2018 at 09:58:57AM +0530, Jassi Brar wrote:
> On Tue, Dec 19, 2017 at 4:45 PM, Kaihua Zhong <zhongkaihua-hv44wF8Li93QT0dZR+AlfA@public.gmane.org> wrote:
>
> .....
> > diff --git a/drivers/mailbox/hi3660-mailbox.c b/drivers/mailbox/hi3660-mailbox.c
> > new file mode 100644
> > index 0000000..3ceca40
> > --- /dev/null
> > +++ b/drivers/mailbox/hi3660-mailbox.c
> > @@ -0,0 +1,319 @@
> > +// SPDX-License-Identifier: GPL-2.0
> > +// Copyright (c) 2017 Hisilicon Limited.
> > +// Copyright (c) 2017 Linaro Limited.
>
> A blank here please.
Will fix.
> > +#include <linux/bitops.h>
> > +#include <linux/delay.h>
> > +#include <linux/device.h>
> > +#include <linux/err.h>
> > +#include <linux/interrupt.h>
> > +#include <linux/io.h>
> > +#include <linux/iopoll.h>
Will add blank.
> .....
> > +
> > +static inline struct hi3660_mbox *to_hi3660_mbox(struct mbox_controller *mbox)
> >
> inline in .c is out of fasion these days
Will remove 'inline'.
> > +{
> > + return container_of(mbox, struct hi3660_mbox, controller);
> > +}
> > +
>
> ....
> > +
> > +static int hi3660_mbox_startup(struct mbox_chan *chan)
> > +{
> > + int ret;
> > +
> > + ret = hi3660_mbox_check_state(chan);
> > + if (ret)
> > + return ret;
> > +
> > + ret = hi3660_mbox_unlock(chan);
> > + if (ret)
> > + return ret;
> > +
> > + ret = hi3660_mbox_acquire_channel(chan);
> > + if (ret)
> > + return ret;
> > +
> > + return 0;
> > +}
> Do you not need to do "release channel" for shutdown() ?
>From my testing, the driver don't need "release channel" operations.
> .....
> > +
> > +static int hi3660_mbox_send_data(struct mbox_chan *chan, void *msg)
> > +{
> > + return hi3660_mbox_send(chan, msg);
> >
> Please directly have hi3660_mbox_send as .send_data
Will fix.
Thanks,
Leo Yan
--
To unsubscribe from this list: send the line "unsubscribe devicetree" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
next prev parent reply other threads:[~2018-01-05 8:08 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-12-19 11:15 [PATCH v4 0/3] Add support for Hi3660 mailbox driver Kaihua Zhong
2017-12-19 11:15 ` [PATCH v4 1/3] dt-bindings: mailbox: Introduce Hi3660 controller binding Kaihua Zhong
2017-12-19 23:30 ` Rob Herring
2017-12-20 0:27 ` Leo Yan
[not found] ` <1513682145-19892-1-git-send-email-zhongkaihua-hv44wF8Li93QT0dZR+AlfA@public.gmane.org>
2017-12-19 11:15 ` [PATCH v4 2/3] mailbox: Add support for Hi3660 mailbox Kaihua Zhong
[not found] ` <1513682145-19892-3-git-send-email-zhongkaihua-hv44wF8Li93QT0dZR+AlfA@public.gmane.org>
2018-01-05 4:28 ` Jassi Brar
[not found] ` <CABb+yY2z4jDWJdDY2WRw5Mhv+ArTuvLgqJ9RyVoUJj3O1d=o6A-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2018-01-05 8:08 ` Leo Yan [this message]
2017-12-19 11:15 ` [PATCH v4 3/3] dts: arm64: Add mailbox binding for hi3660 Kaihua Zhong
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=20180105080854.GB26855@leoy-linaro \
--to=leo.yan-qsej5fyqhm4dnm+yrofe0a@public.gmane.org \
--cc=catalin.marinas-5wv7dgnIgG8@public.gmane.org \
--cc=devicetree-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
--cc=guodong.xu-QSEj5FYQhm4dnm+yROfE0A@public.gmane.org \
--cc=haojian.zhuang-QSEj5FYQhm4dnm+yROfE0A@public.gmane.org \
--cc=jassisinghbrar-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org \
--cc=kevin.wangtao-C8/M+/jPZTeaMJb+Lgu22Q@public.gmane.org \
--cc=linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r@public.gmane.org \
--cc=linux-kernel-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
--cc=mark.rutland-5wv7dgnIgG8@public.gmane.org \
--cc=robh+dt-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org \
--cc=suzhuangluan-C8/M+/jPZTeaMJb+Lgu22Q@public.gmane.org \
--cc=will.deacon-5wv7dgnIgG8@public.gmane.org \
--cc=xuezhiliang-C8/M+/jPZTeaMJb+Lgu22Q@public.gmane.org \
--cc=xuwei5-C8/M+/jPZTeaMJb+Lgu22Q@public.gmane.org \
--cc=zhongkaihua-hv44wF8Li93QT0dZR+AlfA@public.gmane.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).