On Thu, 2008-10-30 at 08:45 +0100, Peter Korsgaard wrote: > I would write a dedicated driver for something like that instead of > using gpiolib. > > Gpiolib has quite some overhead compared to the actual work for > changing a SoC gpio pin, but it also has some very nice > advantages. For most stuff people use GPIO pins for, the overhead is > not an issue (SPI chip selects, leds, keys, reset signals, ..). It's > very handy that we nowadays have generic drivers that work with any > GPIO (being SoC gpios or stuff on spi/i2c).
For what it's worth, I think it could be useful to have an optimally fast gpiolib driver. This would let you have truly generic bit-bang drivers. Take a look at drivers/spi for example -- there's ~7 bit-bang drivers in there that use spi_bitbang.c for a library of functions. I am not familiar with these drivers, but at a glance it seems feasible that with fast gpiolib implementations you could reduce all of those to a single spi_bitbang.c driver. Trent, it looks like the big performance wins for you were obtained by deviating from the gpiolib interface? In that case a generic SPI/JTAG bit bang driver wouldn't benefit from the speed boosts in your MPC8572 GPIO driver (without explicitly calling mpc8572_gpio_lock and _mpc8572_gpio_set, etc). Is that correct? In any case, I appreciate what you did with your driver, so please don't give up on getting some of your bits merged in :) -- Nate Case <[EMAIL PROTECTED]> _______________________________________________ Linuxppc-dev mailing list Linuxppc-dev@ozlabs.org https://ozlabs.org/mailman/listinfo/linuxppc-dev