[PATCH 1/3] ARM: SAMSUNG: Add config option for number of additional GPIO pins.

Ben Dooks ben-linux at fluff.org
Mon Jan 11 07:27:15 EST 2010


On Mon, Jan 11, 2010 at 10:33:39AM +0000, Mark Brown wrote:
> On Mon, Jan 11, 2010 at 06:44:06PM +0900, Kukjin Kim wrote:
> 
> > +config SAMSUNG_GPIO_EXTRA
> > +	int "Number of additional GPIO pins"
> > +	default 0
> > +	help
> > +	  Use additional GPIO space in addition to the GPIO's the SOC
> > +	  provides. This allows expanding the GPIO space for use with
> > +	  GPIO expanders.
> > +
> 
> The way this has been handled for previous Samsung variants is to make
> it entirely hidden from users and provide selectable values for defining
> the number so you end up with something like:
> 
> 	config SAMSUNG_GPIO_EXTRA
> 	int
> 	default 64 if SAMSUNG_GPIO_64
> 	default 32 if SAMSUNG_GPIO_32
> 	default 0
> 
> The board drivers then select one of the numeric options.  They should
> know how many GPIOs they need, while end users rebuilding their kernels
> don't need to know this since at least code if not hardware changes will
> be required to change it usefully.

I've put a question out about trying to change Kconfig to allow
a configuration like this to be set to a minimum value from other
config variables.

Having this as a user settable field might be useful if plugging on
GPIO expanders at runtime.

-- 
Ben

Q:      What's a light-year?
A:      One-third less calories than a regular year.




More information about the linux-arm-kernel mailing list