[OpenWrt-Devel] kernel module runtime configuration
Geert Uytterhoeven
geert at linux-m68k.org
Fri Aug 15 11:17:51 EDT 2014
Hi Brent,
On Fri, Aug 15, 2014 at 12:45 AM, Brent Thomson <brentthomson at gmail.com> wrote:
> Hey all. I'm working on my first Linux kernel module. It's an
> adaptation of an hd44780-over-GPIO driver. You can see it here:
>
> https://github.com/brnt/openwrt-hd44780
>
> The driver is working fine, but I'd like to allow the user to
> configure which GPIOs are used by the driver. Rather than hard-coding
> the values in the C file (as they're currently done) I'd prefer to
> read values from a config file (or the equivalent).
The modern way to do this is to add a hd44780-gpio device node to the
device tree, cfr. spi-over-gpio:
Documentation/devicetree/bindings/spi/spi-gpio.txt
Gr{oetje,eeting}s,
Geert
--
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert at linux-m68k.org
In personal conversations with technical people, I call myself a hacker. But
when I'm talking to journalists I just say "programmer" or something like that.
-- Linus Torvalds
_______________________________________________
openwrt-devel mailing list
openwrt-devel at lists.openwrt.org
https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel
More information about the openwrt-devel
mailing list