lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <53F1FA49.5000508@linaro.org>
Date:	Mon, 18 Aug 2014 21:06:17 +0800
From:	Guodong Xu <guodong.xu@...aro.org>
To:	Axel Lin <axel.lin@...ics.com>, Mark Brown <broonie@...nel.org>,
	Liam Girdwood <lgirdwood@...il.com>
CC:	Stephen Rothwell <sfr@...b.auug.org.au>,
	"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>
Subject: Re: [PATCH] regulator: core: Fix build error due to const qualifier
 for ops

I'm sending a patch to fix the build error on mc13892-regulator.c

-Guodong

On 08/18/2014 10:34 AM, Axel Lin wrote:
> Drop const qualifier for ops of struct regulator_desc.
> Allow regulator drivers to update ops before registering regulator.
> 
> Fix below build error:
>   CC [M]  drivers/regulator/mc13892-regulator.o
> drivers/regulator/mc13892-regulator.c: In function 'mc13892_regulator_probe':
> drivers/regulator/mc13892-regulator.c:586:3: error: assignment of member 'set_mode' in read-only object
> drivers/regulator/mc13892-regulator.c:588:3: error: assignment of member 'get_mode' in read-only object
> make[2]: *** [drivers/regulator/mc13892-regulator.o] Error 1
> make[1]: *** [drivers/regulator] Error 2
> make: *** [drivers] Error 2
> 
> Reported-by: Stephen Rothwell <sfr@...b.auug.org.au>
> Signed-off-by: Axel Lin <axel.lin@...ics.com>
> ---
>  include/linux/regulator/driver.h | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/include/linux/regulator/driver.h b/include/linux/regulator/driver.h
> index efe058f..3abda75 100644
> --- a/include/linux/regulator/driver.h
> +++ b/include/linux/regulator/driver.h
> @@ -246,7 +246,7 @@ struct regulator_desc {
>  	int id;
>  	bool continuous_voltage_range;
>  	unsigned n_voltages;
> -	const struct regulator_ops *ops;
> +	struct regulator_ops *ops;
>  	int irq;
>  	enum regulator_type type;
>  	struct module *owner;
> 
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ