15 #include <linux/device.h>
19 #include <linux/reboot.h>
21 #include <linux/i2c.h>
25 #include <linux/input.h>
27 #include <mach/hardware.h>
33 static struct resource physmap_flash_resource = {
39 static struct resource puv3_i2c_resources[] = {
54 .max_brightness = 100,
55 .dft_brightness = 100,
56 .pwm_period_ns = 70 * 1024,
64 .desc =
"Power Button",
71 .gpio = GPI_BTN_TOUCH,
72 .desc =
"Touchpad Button",
79 .buttons = nb0916_gpio_keys,
93 static irqreturn_t nb0916_overheat_handler(
int irq,
void *dev_id)
111 platform_device_register_simple(
"PKUnity-v3-I2C", -1,
112 puv3_i2c_resources,
ARRAY_SIZE(puv3_i2c_resources));
114 platform_device_register_data(&
platform_bus,
"pwm-backlight", -1,
115 &nb0916_backlight_data,
sizeof(nb0916_backlight_data));
117 platform_device_register_data(&
platform_bus,
"gpio-keys", -1,
118 &nb0916_gpio_button_data,
sizeof(nb0916_gpio_button_data));
120 platform_device_register_resndata(&
platform_bus,
"physmap-flash", -1,
121 &physmap_flash_resource, 1,
122 &physmap_flash_data,
sizeof(physmap_flash_data));
125 &nb0916_lcdcaseoff_handler,
127 "NB0916 lcd case off",
NULL) < 0) {
135 "NB0916 overheating protection",
NULL) < 0) {