Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1165472 > unrolled thread

Re: [PATCH ljones-mfd] mfd: cros_ec:: ec_p can be static

Started byJavier Martinez Canillas <javier.martinez@collabora.co.uk>
First post2015-06-15 21:10 +0200
Last post2015-06-15 21:10 +0200
Articles 1 — 1 participant

Back to article view | Back to linux.kernel

This discussion starts older than the indexed window; earlier articles aren't shown. The article labeled Started by below is the oldest one visible, not the original post.


Contents

  Re: [PATCH ljones-mfd] mfd: cros_ec:: ec_p can be static Javier Martinez Canillas <javier.martinez@collabora.co.uk> - 2015-06-15 21:10 +0200

#1165472 — Re: [PATCH ljones-mfd] mfd: cros_ec:: ec_p can be static

FromJavier Martinez Canillas <javier.martinez@collabora.co.uk>
Date2015-06-15 21:10 +0200
SubjectRe: [PATCH ljones-mfd] mfd: cros_ec:: ec_p can be static
Message-ID<pBHVE-40I-5@gated-at.bofh.it>
Hello Fengguang,

Thanks a lot for your patch.

On 06/15/2015 03:39 PM, kbuild test robot wrote:
> 
> Signed-off-by: Fengguang Wu <fengguang.wu@intel.com>
> ---
>  cros_ec.c |    6 +++---
>  1 file changed, 3 insertions(+), 3 deletions(-)
> 
> diff --git a/drivers/mfd/cros_ec.c b/drivers/mfd/cros_ec.c
> index 11b1884b..dd6f4ff 100644
> --- a/drivers/mfd/cros_ec.c
> +++ b/drivers/mfd/cros_ec.c
> @@ -27,7 +27,7 @@
>  #define CROS_EC_DEV_EC_INDEX 0
>  #define CROS_EC_DEV_PD_INDEX 1
>  
> -struct cros_ec_platform ec_p = {
> +static struct cros_ec_platform ec_p = {
>  	.ec_name = CROS_EC_DEV_NAME,
>  	.cmd_offset = EC_CMD_PASSTHRU_OFFSET(CROS_EC_DEV_EC_INDEX),
>  };
> @@ -37,13 +37,13 @@ struct cros_ec_platform pd_p = {
>  	.cmd_offset = EC_CMD_PASSTHRU_OFFSET(CROS_EC_DEV_PD_INDEX),
>  };

This can also be static

>  
> -struct mfd_cell ec_cell = {
> +static struct mfd_cell ec_cell = {
>  	.name = "cros-ec-ctl",
>  	.platform_data = &ec_p,
>  	.pdata_size = sizeof(ec_p),
>  };
>  
> -struct mfd_cell ec_pd_cell = {
> +static struct mfd_cell ec_pd_cell = {
>  	.name = "cros-ec-ctl",
>  	.platform_data = &pd_p,
>  	.pdata_size = sizeof(pd_p),
> 

These two should in fact be static const since mfd_add_devices()
expects a const struct mfd_cell * as third argument. I forgot on
my patch, sorry about that.

With these changes:

Acked-by: Javier Martinez Canillas <javier.martinez@collabora.co.uk>

Best regards,
Javier
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

[toc] | [standalone]


Back to top | Article view | linux.kernel


csiph-web