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: <10870776.N30IekZOBt@wuerfel>
Date:	Mon, 09 Nov 2015 21:51:12 +0100
From:	Arnd Bergmann <arnd@...db.de>
To:	"Andrew F. Davis" <afd@...com>
Cc:	Sebastian Reichel <sre@...nel.org>, linux-pm@...r.kernel.org,
	Pali Rohar <pali.rohar@...il.com>,
	Xiong Zhou <jencce.kernel@...il.com>,
	linux-i2c@...r.kernel.org,
	Dmitry Eremin-Solenikov <dbaryshkov@...il.com>,
	David Woodhouse <dwmw2@...radead.org>,
	linux-kernel@...r.kernel.org, linux-arm-kernel@...ts.infradead.org
Subject: Re: [PATCH] power: bq27xxx_battery: Revert "Remove unneeded dependency in Kconfig"

On Monday 09 November 2015 10:56:13 Andrew F. Davis wrote:
> On 11/09/2015 07:50 AM, Arnd Bergmann wrote:
> Nothing enabled by BATTERY_BQ27XXX depends on I2C, this workaround is not
> correct as it prevents BATTERY_BQ27XXX from being built-in when I2C is a
> module, there is no reason for this limitation.
> 
> The undefined references are caused by BATTERY_BQ27XXX being built-in AND
> its I2C functionality being enabled (BATTERY_BQ27XXX_I2C) while I2C is a
> module. Reorganizing this driver is being discussed anyway, but in the
> meantime a more correct fix would be along the lines of:
> 
> diff --git a/drivers/power/Kconfig b/drivers/power/Kconfig
> index 6de6ec2..d1d32f9 100644
> --- a/drivers/power/Kconfig
> +++ b/drivers/power/Kconfig
> @@ -167,6 +167,7 @@ config BATTERY_BQ27XXX_I2C
>          bool "BQ27xxx I2C support"
>          depends on BATTERY_BQ27XXX
>          depends on I2C
> +       depends on !(I2C=m && BATTERY_BQ27XXX=y)
>          default y
>          help
>            Say Y here to enable support for batteries with BQ27xxx (I2C) chips.

That works too, there is just very little difference in the end here,
and it's easier to revert an patch that only introduces a regression
than to do a different hack, especially if it's going to be reworked
soon anyway.

Do you want to submit the above as a fixup to your other patch or
should we just do the revert? It would be good to get one of the two
into -rc1.

	Arnd
--
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