devicetree.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Suman Anna <s-anna-l0cyMroinI0@public.gmane.org>
To: Andrew Bresticker
	<abrestic-F7+t8E8rja9g9hUCZPvPmw@public.gmane.org>,
	Stephen Warren <swarren-3lzwWm7+Weoh9ZMKESR00Q@public.gmane.org>,
	Thierry Reding
	<thierry.reding-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>,
	Alexandre Courbot
	<gnurou-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
Cc: devicetree-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
	linux-tegra-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
	linux-usb-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
	linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r@public.gmane.org,
	linux-kernel-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
	Jon Hunter <jonathanh-DDmLM1+adcrQT0dZR+AlfA@public.gmane.org>,
	Jassi Brar
	<jassisinghbrar-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>,
	Ashwin Chaugule
	<ashwin.chaugule-QSEj5FYQhm4dnm+yROfE0A@public.gmane.org>,
	Ley Foon Tan <lftan-EIB2kfCEclfQT0dZR+AlfA@public.gmane.org>
Subject: Re: [PATCH v8 2/9] mailbox: Make mbox_chan_ops const
Date: Mon, 4 May 2015 14:22:41 -0500	[thread overview]
Message-ID: <5547C701.8010305@ti.com> (raw)
In-Reply-To: <1430761002-9327-3-git-send-email-abrestic-F7+t8E8rja9g9hUCZPvPmw@public.gmane.org>

On 05/04/2015 12:36 PM, Andrew Bresticker wrote:
> The mailbox controller's channel ops ought to be read-only.  Update
> all the mailbox drivers to make their mbox_chan_ops const as well.
> 
> Signed-off-by: Andrew Bresticker <abrestic-F7+t8E8rja9g9hUCZPvPmw@public.gmane.org>
> Cc: Jassi Brar <jassisinghbrar-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
> Cc: Suman Anna <s-anna-l0cyMroinI0@public.gmane.org>
> Cc: Ashwin Chaugule <ashwin.chaugule-QSEj5FYQhm4dnm+yROfE0A@public.gmane.org>
> Cc: Ley Foon Tan <lftan-EIB2kfCEclfQT0dZR+AlfA@public.gmane.org>

Thanks, the new patch looks good.

Acked-by: Suman Anna <s-anna-l0cyMroinI0@public.gmane.org>

> ---
> Changes from v7:
>  - Constify all drivers' mbox_chan_ops.
> No changes from v5/v6.
> New for v5.
> ---
>  drivers/mailbox/arm_mhu.c          | 2 +-
>  drivers/mailbox/mailbox-altera.c   | 2 +-
>  drivers/mailbox/omap-mailbox.c     | 2 +-
>  drivers/mailbox/pcc.c              | 2 +-
>  include/linux/mailbox_controller.h | 2 +-
>  5 files changed, 5 insertions(+), 5 deletions(-)
> 
> diff --git a/drivers/mailbox/arm_mhu.c b/drivers/mailbox/arm_mhu.c
> index ac693c6..d9e99f9 100644
> --- a/drivers/mailbox/arm_mhu.c
> +++ b/drivers/mailbox/arm_mhu.c
> @@ -110,7 +110,7 @@ static void mhu_shutdown(struct mbox_chan *chan)
>  	free_irq(mlink->irq, chan);
>  }
>  
> -static struct mbox_chan_ops mhu_ops = {
> +static const struct mbox_chan_ops mhu_ops = {
>  	.send_data = mhu_send_data,
>  	.startup = mhu_startup,
>  	.shutdown = mhu_shutdown,
> diff --git a/drivers/mailbox/mailbox-altera.c b/drivers/mailbox/mailbox-altera.c
> index a266265..bb682c9 100644
> --- a/drivers/mailbox/mailbox-altera.c
> +++ b/drivers/mailbox/mailbox-altera.c
> @@ -285,7 +285,7 @@ static void altera_mbox_shutdown(struct mbox_chan *chan)
>  	}
>  }
>  
> -static struct mbox_chan_ops altera_mbox_ops = {
> +static const struct mbox_chan_ops altera_mbox_ops = {
>  	.send_data = altera_mbox_send_data,
>  	.startup = altera_mbox_startup,
>  	.shutdown = altera_mbox_shutdown,
> diff --git a/drivers/mailbox/omap-mailbox.c b/drivers/mailbox/omap-mailbox.c
> index 0f332c1..03f8545 100644
> --- a/drivers/mailbox/omap-mailbox.c
> +++ b/drivers/mailbox/omap-mailbox.c
> @@ -604,7 +604,7 @@ static int omap_mbox_chan_send_data(struct mbox_chan *chan, void *data)
>  	return ret;
>  }
>  
> -static struct mbox_chan_ops omap_mbox_chan_ops = {
> +static const struct mbox_chan_ops omap_mbox_chan_ops = {
>  	.startup        = omap_mbox_chan_startup,
>  	.send_data      = omap_mbox_chan_send_data,
>  	.shutdown       = omap_mbox_chan_shutdown,
> diff --git a/drivers/mailbox/pcc.c b/drivers/mailbox/pcc.c
> index 7e91d68..26d121d 100644
> --- a/drivers/mailbox/pcc.c
> +++ b/drivers/mailbox/pcc.c
> @@ -198,7 +198,7 @@ static int pcc_send_data(struct mbox_chan *chan, void *data)
>  	return 0;
>  }
>  
> -static struct mbox_chan_ops pcc_chan_ops = {
> +static const struct mbox_chan_ops pcc_chan_ops = {
>  	.send_data = pcc_send_data,
>  };
>  
> diff --git a/include/linux/mailbox_controller.h b/include/linux/mailbox_controller.h
> index d4cf96f..68c4245 100644
> --- a/include/linux/mailbox_controller.h
> +++ b/include/linux/mailbox_controller.h
> @@ -72,7 +72,7 @@ struct mbox_chan_ops {
>   */
>  struct mbox_controller {
>  	struct device *dev;
> -	struct mbox_chan_ops *ops;
> +	const struct mbox_chan_ops *ops;
>  	struct mbox_chan *chans;
>  	int num_chans;
>  	bool txdone_irq;
> 

  parent reply	other threads:[~2015-05-04 19:22 UTC|newest]

Thread overview: 46+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-05-04 17:36 [PATCH v8 0/9] Tegra xHCI support Andrew Bresticker
2015-05-04 17:36 ` [PATCH v8 5/9] mfd: Add driver for NVIDIA Tegra XUSB Andrew Bresticker
     [not found]   ` <1430761002-9327-6-git-send-email-abrestic-F7+t8E8rja9g9hUCZPvPmw@public.gmane.org>
2015-05-13 14:37     ` Lee Jones
2015-05-13 16:31       ` Andrew Bresticker
     [not found] ` <1430761002-9327-1-git-send-email-abrestic-F7+t8E8rja9g9hUCZPvPmw@public.gmane.org>
2015-05-04 17:36   ` [PATCH v8 1/9] xhci: Set shared HCD's hcd_priv in xhci_gen_setup Andrew Bresticker
     [not found]     ` <1430761002-9327-2-git-send-email-abrestic-F7+t8E8rja9g9hUCZPvPmw@public.gmane.org>
2015-05-19 18:39       ` Andrew Bresticker
     [not found]         ` <CAL1qeaGo2-T=suBiCTtHmyR1sNeS_ZG-2j2FuuLdGc9vmct2ug-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2015-05-22 12:19           ` Mathias Nyman
2015-05-04 17:36   ` [PATCH v8 2/9] mailbox: Make mbox_chan_ops const Andrew Bresticker
     [not found]     ` <1430761002-9327-3-git-send-email-abrestic-F7+t8E8rja9g9hUCZPvPmw@public.gmane.org>
2015-05-04 19:22       ` Suman Anna [this message]
2015-05-04 17:36   ` [PATCH v8 3/9] mailbox: Fix up error handling in mbox_request_channel() Andrew Bresticker
2015-05-04 17:36   ` [PATCH v8 4/9] mfd: Add binding document for NVIDIA Tegra XUSB Andrew Bresticker
     [not found]     ` <1430761002-9327-5-git-send-email-abrestic-F7+t8E8rja9g9hUCZPvPmw@public.gmane.org>
2015-05-13 14:39       ` Lee Jones
2015-05-13 16:26         ` Andrew Bresticker
     [not found]           ` <CAL1qeaF-7aAx0gqPe-_D4ZaZET0Kejr801KrbvuQ_2w6c8mcnA-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2015-05-13 16:50             ` Lee Jones
2015-05-13 17:03               ` Andrew Bresticker
     [not found]                 ` <CAL1qeaE7XHmreQ_b52iop6fOY1osAhjij81c4vVr7_8wO_cYxQ-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2015-05-14  7:29                   ` Lee Jones
2015-05-14  7:32                     ` Jon Hunter
     [not found]                       ` <55544F91.4060402-DDmLM1+adcrQT0dZR+AlfA@public.gmane.org>
2015-05-14  7:45                         ` Lee Jones
2015-05-14  7:20         ` Jon Hunter
     [not found]           ` <55544CC5.9050001-DDmLM1+adcrQT0dZR+AlfA@public.gmane.org>
2015-05-14  7:40             ` Lee Jones
2015-05-14  9:14               ` Jon Hunter
2015-05-14  9:30                 ` Lee Jones
2015-05-14 10:09                   ` Jon Hunter
     [not found]                     ` <5554746A.4000608-DDmLM1+adcrQT0dZR+AlfA@public.gmane.org>
2015-05-14 10:23                       ` Lee Jones
2015-05-14 11:21                         ` Jon Hunter
2015-05-14 17:38               ` Andrew Bresticker
     [not found]                 ` <CAL1qeaEqNejuGkN-ke11mtWnaaRo+XieCBkQ6+NQ-Afym6uxVA-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2015-05-19 18:36                   ` Andrew Bresticker
     [not found]                     ` <CAL1qeaHy0h7bXhuLHh4AG2Zfu48JYeawgVo4dp_k4oX8YFw6tA-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2015-05-20  6:35                       ` Lee Jones
2015-05-20 14:52                         ` Thierry Reding
     [not found]                           ` <20150520145227.GA3787-AwZRO8vwLAwmlAP/+Wk3EA@public.gmane.org>
2015-05-21  7:19                             ` Linus Walleij
2015-05-21  8:40                             ` Lee Jones
2015-05-21 10:12                               ` Thierry Reding
     [not found]                                 ` <20150521101247.GA8073-AwZRO8vwLAwmlAP/+Wk3EA@public.gmane.org>
2015-05-26 15:18                                   ` Lee Jones
2015-06-30 18:22                                     ` Grant Likely
2015-05-04 17:36   ` [PATCH v8 6/9] mailbox: Add NVIDIA Tegra XUSB mailbox binding Andrew Bresticker
     [not found]     ` <1430761002-9327-7-git-send-email-abrestic-F7+t8E8rja9g9hUCZPvPmw@public.gmane.org>
2015-05-08 20:42       ` Benson Leung
     [not found]         ` <CANLzEksWtzSmz=OCuwVdY5RSG6gDrOoMyGsW3i9jMcjD3WtPKQ-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2015-05-08 20:53           ` Andrew Bresticker
2015-05-08 21:03             ` Benson Leung
2015-05-04 17:36   ` [PATCH v8 7/9] mailbox: Add NVIDIA Tegra XUSB mailbox driver Andrew Bresticker
2015-05-04 17:36   ` [PATCH v8 8/9] usb: Add NVIDIA Tegra xHCI controller binding Andrew Bresticker
2015-05-04 17:36   ` [PATCH v8 9/9] usb: xhci: Add NVIDIA Tegra xHCI host-controller driver Andrew Bresticker
2015-05-12  3:56   ` [PATCH v8 0/9] Tegra xHCI support Jassi Brar
     [not found]     ` <CABb+yY2WhH2gGbCr4n=m9HOa_843MuZDp=QWNDHbtB8AMYYwYA-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2015-05-26 16:27       ` Andrew Bresticker
2015-05-05 14:28 ` Jon Hunter
2015-05-05 14:42   ` Thierry Reding
2015-05-05 14:57     ` Jon Hunter

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=5547C701.8010305@ti.com \
    --to=s-anna-l0cymroini0@public.gmane.org \
    --cc=abrestic-F7+t8E8rja9g9hUCZPvPmw@public.gmane.org \
    --cc=ashwin.chaugule-QSEj5FYQhm4dnm+yROfE0A@public.gmane.org \
    --cc=devicetree-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
    --cc=gnurou-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org \
    --cc=jassisinghbrar-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org \
    --cc=jonathanh-DDmLM1+adcrQT0dZR+AlfA@public.gmane.org \
    --cc=lftan-EIB2kfCEclfQT0dZR+AlfA@public.gmane.org \
    --cc=linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r@public.gmane.org \
    --cc=linux-kernel-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
    --cc=linux-tegra-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
    --cc=linux-usb-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
    --cc=swarren-3lzwWm7+Weoh9ZMKESR00Q@public.gmane.org \
    --cc=thierry.reding-Re5JQEeQqe8AvxtiuMwx3w@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).