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] [day] [month] [year] [list]
Message-ID: <20110705162843.GA13707@sirena.org.uk>
Date:	Tue, 5 Jul 2011 17:28:43 +0100
From:	Mark Brown <broonie@...nsource.wolfsonmicro.com>
To:	ashishj3 <ashish.jangam@...tcummins.com>
Cc:	linaro-dev@...ts.linaro.org, lrg@...mlogic.co.uk,
	linux-kernel@...r.kernel.org, Dajun <dajun.chen@...semi.com>
Subject: Re: [Patch 5/11] Regulator: DA9052 regulator support v2

On Wed, Jun 29, 2011 at 06:46:03PM +0530, ashishj3 wrote:

> +static int verify_range(struct da9052_regulator_info *info,
> +			 int min_uV, int max_uV)
> +{
> +	if (min_uV < info->min_uV || min_uV > info->max_uV)
> +		return -EINVAL;
> +	if (max_uV < info->min_uV || max_uV > info->max_uV)
> +		return -EINVAL;

This is broken, think about what it's trying to do - it's trying to
check that the regulator can deliver a voltage within the requested
range.  These checks don't help with that.
--
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