ar71xx: cleanup AR933X UART driver
[openwrt.git] / target / linux / ar71xx / files / arch / mips / include / asm / mach-ar71xx / mach-rb750.h
1 /*
2 * MikroTik RouterBOARD 750 definitions
3 *
4 * Copyright (C) 2010 Gabor Juhos <juhosg@openwrt.org>
5 *
6 * This program is free software; you can redistribute it and/or modify it
7 * under the terms of the GNU General Public License version 2 as published
8 * by the Free Software Foundation.
9 */
10 #ifndef _MACH_RB750_H
11 #define _MACH_RB750_H
12
13 #include <linux/bitops.h>
14
15 #define RB750_GPIO_LVC573_LE 0 /* Latch enable on LVC573 */
16 #define RB750_GPIO_NAND_IO0 1 /* NAND I/O 0 */
17 #define RB750_GPIO_NAND_IO1 2 /* NAND I/O 1 */
18 #define RB750_GPIO_NAND_IO2 3 /* NAND I/O 2 */
19 #define RB750_GPIO_NAND_IO3 4 /* NAND I/O 3 */
20 #define RB750_GPIO_NAND_IO4 5 /* NAND I/O 4 */
21 #define RB750_GPIO_NAND_IO5 6 /* NAND I/O 5 */
22 #define RB750_GPIO_NAND_IO6 7 /* NAND I/O 6 */
23 #define RB750_GPIO_NAND_IO7 8 /* NAND I/O 7 */
24 #define RB750_GPIO_NAND_NCE 11 /* NAND Chip Enable (active low) */
25 #define RB750_GPIO_NAND_RDY 12 /* NAND Ready */
26 #define RB750_GPIO_NAND_CLE 14 /* NAND Command Latch Enable */
27 #define RB750_GPIO_NAND_ALE 15 /* NAND Address Latch Enable */
28 #define RB750_GPIO_NAND_NRE 16 /* NAND Read Enable (active low) */
29 #define RB750_GPIO_NAND_NWE 17 /* NAND Write Enable (active low) */
30
31 #define RB750_GPIO_BTN_RESET 1
32 #define RB750_GPIO_SPI_CS0 2
33 #define RB750_GPIO_LED_ACT 12
34 #define RB750_GPIO_LED_PORT1 13
35 #define RB750_GPIO_LED_PORT2 14
36 #define RB750_GPIO_LED_PORT3 15
37 #define RB750_GPIO_LED_PORT4 16
38 #define RB750_GPIO_LED_PORT5 17
39
40 #define RB750_LED_ACT BIT(RB750_GPIO_LED_ACT)
41 #define RB750_LED_PORT1 BIT(RB750_GPIO_LED_PORT1)
42 #define RB750_LED_PORT2 BIT(RB750_GPIO_LED_PORT2)
43 #define RB750_LED_PORT3 BIT(RB750_GPIO_LED_PORT3)
44 #define RB750_LED_PORT4 BIT(RB750_GPIO_LED_PORT4)
45 #define RB750_LED_PORT5 BIT(RB750_GPIO_LED_PORT5)
46
47 #define RB750_LVC573_LE BIT(RB750_GPIO_LVC573_LE)
48
49 #define RB750_LED_BITS (RB750_LED_PORT1 | RB750_LED_PORT2 | RB750_LED_PORT3 | \
50 RB750_LED_PORT4 | RB750_LED_PORT5 | RB750_LED_ACT)
51
52 struct rb750_led_data {
53 char *name;
54 char *default_trigger;
55 u32 mask;
56 int active_low;
57 };
58
59 struct rb750_led_platform_data {
60 int num_leds;
61 struct rb750_led_data *leds;
62 };
63
64 int rb750_latch_change(u32 mask_clr, u32 mask_set);
65
66 #endif /* _MACH_RB750_H */
This page took 0.043597 seconds and 5 git commands to generate.