All of lore.kernel.org
 help / color / mirror / Atom feed
From: Andy Shevchenko <andy.shevchenko@gmail.com>
To: Tomas Winkler <tomas.winkler@intel.com>
Cc: Lee Jones <lee.jones@linaro.org>,
	Andy Shevchenko <andriy.shevchenko@linux.intel.com>,
	Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
	Linux Kernel Mailing List <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH] mfd: constify properties in mfd_cell
Date: Tue, 4 Feb 2020 23:22:06 +0200	[thread overview]
Message-ID: <CAHp75VeC4R2XG3rfx3+G6po-JS6U0RPoXg2y+JMhd-s+E_sirA@mail.gmail.com> (raw)
In-Reply-To: <20200204201651.15778-1-tomas.winkler@intel.com>

On Tue, Feb 4, 2020 at 10:18 PM Tomas Winkler <tomas.winkler@intel.com> wrote:
>
> Constify 'struct property_entry *properties' in
> mfd_cell and platform_device. It is always passed
> around as a pointer const struct.
>

After

commit 277036f05be242540b7bfe75f226107d04f51b06
Author: Jan Kiszka <jan.kiszka@siemens.com>
Date:   Fri Jun 2 07:43:27 2017 +0200

    platform: Accept const properties

this one makes sense.

Reviewed-by: Andy Shevchenko <andy.shevchenko@gmail.com>

Does intel-lpss* compile with this change?

> Signed-off-by: Tomas Winkler <tomas.winkler@intel.com>
> ---
>  include/linux/mfd/core.h        | 2 +-
>  include/linux/platform_device.h | 2 +-
>  2 files changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/include/linux/mfd/core.h b/include/linux/mfd/core.h
> index d01d1299e49d..7e5ac3c00891 100644
> --- a/include/linux/mfd/core.h
> +++ b/include/linux/mfd/core.h
> @@ -70,7 +70,7 @@ struct mfd_cell {
>         size_t                  pdata_size;
>
>         /* device properties passed to the sub devices drivers */
> -       struct property_entry *properties;
> +       const struct property_entry *properties;
>
>         /*
>          * Device Tree compatible string
> diff --git a/include/linux/platform_device.h b/include/linux/platform_device.h
> index 276a03c24691..8e83c6ff140d 100644
> --- a/include/linux/platform_device.h
> +++ b/include/linux/platform_device.h
> @@ -89,7 +89,7 @@ struct platform_device_info {
>                 size_t size_data;
>                 u64 dma_mask;
>
> -               struct property_entry *properties;
> +               const struct property_entry *properties;
>  };
>  extern struct platform_device *platform_device_register_full(
>                 const struct platform_device_info *pdevinfo);
> --
> 2.21.1
>


-- 
With Best Regards,
Andy Shevchenko

  reply	other threads:[~2020-02-04 21:22 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-02-04 20:16 [PATCH] mfd: constify properties in mfd_cell Tomas Winkler
2020-02-04 21:22 ` Andy Shevchenko [this message]
2020-02-04 21:33   ` Winkler, Tomas
2020-02-04 22:48 ` Greg Kroah-Hartman

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=CAHp75VeC4R2XG3rfx3+G6po-JS6U0RPoXg2y+JMhd-s+E_sirA@mail.gmail.com \
    --to=andy.shevchenko@gmail.com \
    --cc=andriy.shevchenko@linux.intel.com \
    --cc=gregkh@linuxfoundation.org \
    --cc=lee.jones@linaro.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=tomas.winkler@intel.com \
    /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.