drivers: add lcd display support
Subsystems (6)
PATCH 1/1 drivers: add lcd display support
miguelojeda-2.6.18-add-lcd-display-support.patch
Changelog:
- Fixed mistakes found by Alexey Dobriyan
- coding style
- init() and exit() error management
- Fixed mistakes found by Greg KH
- coding style
- Apply for 2.6.18
- added const to class_create (2.6.18 hasn't add-const-to-class_create.patch)
- Fixed mistakes found by Pavel Machek
- no zero initialization
- GPL version
- use bitop generic functions
Brief:
- Adds const to class_create (2.6.18 hasn't add-const-to-class_create.patch)
- Adds a "lcddisplay" class for registering LCD devices.
- Adds support for the ks0108 LCD Controller as a device driver.
(uses lcddisplay class and parport interface)
- Adds support for the cfag12864b LCD Display as a device driver.
(uses ks0108 device driver)
- Adds a new ioctl() magic number/range (0xFF) in the list for the cfag12864b device.
- Adds the usual Documentation, includes, Makefiles, Kconfigs, MAINTAINERS, CREDITS...
Patched files Index:
patching file include/linux/device.h
patching file drivers/base/class.c
patching file drivers/Kconfig
patching file drivers/lcddisplay/cfag12864b.c patching file drivers/lcddisplay/cfag12864b_image.h patching file drivers/lcddisplay/Kconfig patching file drivers/lcddisplay/ks0108.c patching file drivers/lcddisplay/lcddisplay.c patching file drivers/lcddisplay/Makefile patching file drivers/Makefile
patching file include/linux/cfag12864b.h patching file include/linux/ks0108.h
patching file include/linux/lcddisplay.h patching file CREDITS
patching file Documentation/ioctl-number.txt patching file Documentation/drivers/lcddisplay/cfag12864b patching file Documentation/drivers/lcddisplay/lcddisplay patching file MAINTAINERS
Please review.
miguelojeda-2.6.18-add-lcd-display-support.patch
---
include/linux/device.h +1 -1
@@ -271,7 +271,7 @@ struct class_interface {extern int class_interface_register (struct class_interface *);extern void class_interface_unregister (struct class_interface *); -extern struct class *class_create (struct module *owner,char *name); +extern struct class *class_create (struct module *owner,const char *name);extern void class_destroy (struct class *cls); extern struct class_device *class_device_create(struct class *cls, struct class_device *parent,
drivers/base/class.c +1 -1
@@ -197,7 +197,7 @@ static int class_device_create_uevent(st* Note, the pointer created here is to be destroyed when finished by * making a call to class_destroy(). */ -struct class *class_create (struct module *owner,char *name) +struct class *class_create (struct module *owner,const char *name) {struct class *cls;int retval;
drivers/Kconfig +2 -0
@@ -74,4 +74,6 @@ source "drivers/rtc/Kconfig" source "drivers/dma/Kconfig" +source "drivers/lcddisplay/Kconfig" + endmenu
drivers/lcddisplay/cfag12864b.c +537 -0
537 lines not on this page · raw message
drivers/lcddisplay/cfag12864b_image.h +75 -0
75 lines not on this page · raw message
drivers/lcddisplay/Kconfig +61 -0
61 lines not on this page · raw message
drivers/lcddisplay/ks0108.c +175 -0
175 lines not on this page · raw message
drivers/lcddisplay/lcddisplay.c +71 -0
71 lines not on this page · raw message
drivers/lcddisplay/Makefile +7 -0
@@ -0,0 +1,7 @@ +# +# Makefile for the kernel LCD Display device drivers. +# + +obj-$(CONFIG_LCDDISPLAY) += lcddisplay.o +obj-$(CONFIG_KS0108) += ks0108.o +obj-$(CONFIG_CFAG12864B) += cfag12864b.o
drivers/Makefile +1 -0
@@ -76,3 +76,4 @@ obj-$(CONFIG_CRYPTO) += crypto/ obj-$(CONFIG_SUPERH) += sh/ obj-$(CONFIG_GENERIC_TIME) += clocksource/ obj-$(CONFIG_DMA_ENGINE) += dma/ +obj-$(CONFIG_LCDDISPLAY) += lcddisplay/
include/linux/cfag12864b.h +45 -0
45 lines not on this page · raw message
include/linux/ks0108.h +21 -0
@@ -0,0 +1,21 @@ +/* +* Filename: ks0108.h +* Version: 0.1.0 +* Description: ks0108 LCD Display Controller Driver Header +* License: GPLv2 +* +* Author: Miguel Ojeda Sandonis <[email protected]> +* Date: 2006-09-12 +*/ + +#ifndef _KS0108_H_ +#define _KS0108_H_ + +extern void ks0108_writedata (unsigned char byte); +extern void ks0108_writecontrol (unsigned char byte); +extern void ks0108_displaystate (unsigned char state); +extern void ks0108_startline (unsigned char startline); +extern void ks0108_address (unsigned char address); +extern void ks0108_page (unsigned char page); + +#endif /* _KS0108_H_ */
include/linux/lcddisplay.h +19 -0
@@ -0,0 +1,19 @@ +/* +* Filename: lcddisplay.h +* Version: 0.1.0 +* Description: Display Class Header +* License: GPLv2 +* +* Author: Miguel Ojeda Sandonis <[email protected]> +* Date: 2006-09-12 +*/ + +#ifndef _LCDDISPLAY_H_ +#define _LCDDISPLAY_H_ + +#include <linux/device.h> + +extern struct class * lcddisplay_class; + +#endif /* _LCDDISPLAY_H_ */ +
CREDITS +8 -0
@@ -2535,6 +2535,14 @@ S: Subiaco, 6008 S: Perth, Western Australia S: Australia +N: Miguel Ojeda Sandonis +E: [email protected] +D: Author: LCD Display Drivers (ks0108, cfag12864b) +D: Maintainer: LCD Display Drivers Tree (drivers/lcddisplay/*) +S: C/ Mieses 20, 9-B +S: Valladolid 47009 +S: Spain + N: Greg Page E: [email protected] D: IPX development and support
Documentation/ioctl-number.txt +2 -0
@@ -191,3 +191,5 @@ Code Seq# Include File Comments <mailto:[email protected]> 0xF3 00-3F video/sisfb.h sisfb (in development) <mailto:[email protected]> +0xFF 00-1F linux/cfag12864b.h cfag12864b LCD Display Driver + <mailto:[email protected]>
Documentation/drivers/lcddisplay/cfag12864b +367 -0
367 lines not on this page · raw message
Documentation/drivers/lcddisplay/lcddisplay +37 -0
@@ -0,0 +1,37 @@ + ================================= + LCD Display Drivers Documentation + ================================= + +License: GPL +Author & Maintainer: Miguel Ojeda Sandonis <[email protected]> +Date: 2006-09-12 + +-------- +0. INDEX +-------- + + 1. NEW DISPLAY DRIVERS + 2. GENERAL TIPS + + + +---------------------- +1. NEW DISPLAY DRIVERS +---------------------- + +Feel free to send me new display drivers. I will try to do my best. + +If you don't get any answer, send your patch directly to the linux-kernel ml. + + + +--------------- +2. GENERAL TIPS +--------------- + +- Divide your driver into the controller driver, like ks0108, + and the specific LCD display series driver, like cfag12864b. + +- Claim for your IO ports in the controller driver. + +EOF
MAINTAINERS +5 -0
@@ -1707,6 +1707,11 @@ M: [email protected] L: [email protected] S: Maintained +LCD DISPLAY DRIVERS +P: Miguel Ojeda Sandonis +M: [email protected] +S: Maintained + LED SUBSYSTEM P: Richard Purdie M: [email protected]