10 #include <linux/module.h>
11 #include <linux/types.h>
18 #include <linux/slab.h>
20 #include <lantiq_soc.h>
28 #define LTQ_EBU_BUSCON 0x1e7ff
29 #define LTQ_EBU_WP 0x80000000
51 spin_unlock_irqrestore(&
ebu_lock, flags);
62 static void ltq_mm_set(
struct gpio_chip *
gc,
unsigned offset,
int value)
64 struct of_mm_gpio_chip *mm_gc = to_of_mm_gpio_chip(gc);
83 static int ltq_mm_dir_out(
struct gpio_chip *gc,
unsigned offset,
int value)
85 ltq_mm_set(gc, offset, value);
94 static void ltq_mm_save_regs(
struct of_mm_gpio_chip *mm_gc)
113 dev_err(&pdev->
dev,
"failed to get memory resource\n");
121 chip->
mmchip.gc.ngpio = 16;
122 chip->
mmchip.gc.label =
"gpio-mm-ltq";
123 chip->
mmchip.gc.direction_output = ltq_mm_dir_out;
124 chip->
mmchip.gc.set = ltq_mm_set;
125 chip->
mmchip.save_regs = ltq_mm_save_regs;
139 { .compatible =
"lantiq,gpio-mm" },
145 .probe = ltq_mm_probe,
147 .name =
"gpio-mm-ltq",
149 .of_match_table = ltq_mm_match,
153 static int __init ltq_mm_init(
void)