23 #include <linux/serial.h>
26 #include <linux/reboot.h>
27 #include <linux/i2c.h>
35 #define DSMG600_SDA_PIN 5
36 #define DSMG600_SCL_PIN 4
39 #define DSMG600_FREQ 66000000
42 #define DSMG600_PB_GPIO 15
43 #define DSMG600_RB_GPIO 3
46 #define DSMG600_PO_GPIO 2
49 #define DSMG600_LED_PWR_GPIO 0
50 #define DSMG600_LED_WLAN_GPIO 14
53 .map_name =
"cfi_probe",
57 static struct resource dsmg600_flash_resource = {
62 .name =
"IXP4XX-Flash",
64 .dev.platform_data = &dsmg600_flash_data,
66 .resource = &dsmg600_flash_resource,
78 .platform_data = &dsmg600_i2c_gpio_data,
88 static struct gpio_led dsmg600_led_pins[] = {
90 .name =
"dsmg600:green:power",
94 .name =
"dsmg600:green:wlan",
102 .leds = dsmg600_led_pins,
108 .dev.platform_data = &dsmg600_led_data,
111 static struct resource dsmg600_uart_resources[] = {
147 .name =
"serial8250",
149 .dev.platform_data = dsmg600_uart_data,
150 .num_resources =
ARRAY_SIZE(dsmg600_uart_resources),
151 .resource = dsmg600_uart_resources,
160 static void dsmg600_power_off(
void)
172 static int power_button_countdown;
175 #define PBUTTON_HOLDDOWN_COUNT 4
177 static void dsmg600_power_handler(
unsigned long data);
178 static DEFINE_TIMER(dsmg600_power_timer, dsmg600_power_handler, 0, 0);
180 static void dsmg600_power_handler(
unsigned long data)
189 if (power_button_countdown > 0)
190 power_button_countdown--;
195 if (power_button_countdown == 0) {
220 static void __init dsmg600_timer_init(
void)
229 static struct sys_timer dsmg600_timer = {
230 .init = dsmg600_timer_init,
233 static void __init dsmg600_init(
void)
241 dsmg600_flash_resource.
end =
259 "DSM-G600 reset button",
NULL) < 0) {
281 .atag_offset = 0x100,
285 .timer = &dsmg600_timer,
286 .init_machine = dsmg600_init,
287 #if defined(CONFIG_PCI)