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]
Date:	Wed, 5 Mar 2008 15:40:57 -0800
From:	David Brownell <david-b@...bell.net>
To:	Anton Vorontsov <avorontsov@...mvista.com>
Cc:	Andrew Morton <akpm@...ux-foundation.org>,
	linux-kernel@...r.kernel.org
Subject: Re: [PATCH] gpiolib: implement dynamic base allocation

On Wednesday 05 March 2008, Andrew Morton wrote:
> On Tue, 4 Mar 2008 20:03:07 +0300
> Anton Vorontsov <avorontsov@...mvista.com> wrote:
> 
> > If gpio_chip->base is negative during registration, gpiolib requests
> > dynamic base allocation. This is useful for devices being registered
> > at run-time (in contrast to platform devices).
> > 
> > Signed-off-by: Anton Vorontsov <avorontsov@...mvista.com>
> > ---
> >  drivers/gpio/gpiolib.c |   42 ++++++++++++++++++++++++++++++++++++------
> >  1 files changed, 36 insertions(+), 6 deletions(-)
> > 
> 
> This conflicts in non-trivial ways with gpio-define-gpio_is_valid.patch. 
> Could you please redo and retest against 2.6.25-rc3-mm1?

And when you do that, could you make it assign GPIO numbers from
the biggest number on down, instead of from the smallest on up?

Platforms normally assign those numbers from the bottom up ... so
dynamic assignment should try to avoid reusing any numbers that may
have been explicitly assigned, but not yet registered.  (Of course,
if you can come up with a cleaner solution than that, it'd be great.
Maybe platforms should also be able to mark ranges as "in use" as
they start up, or something.)

And please add a pr_debug level message reporting dynamically
assigned ranges.  That way, when problems crop up it'll be that
much easier to notice what went wrong.

- Dave

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