Lines Matching +full:wakeup +full:- +full:source
1 // SPDX-License-Identifier: GPL-2.0
12 #include <asm/mach-au1x00/au1000.h>
13 #include <asm/mach-au1x00/gpio-au1000.h>
14 #include <asm/mach-db1x00/bcsr.h>
19 * can be used by userspace to en/disable all au1x-provided wakeup
21 * is to trigger a wakeup.
45 /* enable GPIO based wakeup */ in db1x_pm_enter()
48 /* clear and setup wake cause and source */ in db1x_pm_enter()
54 /* setup 1Hz-timer-based wakeup: wait for reg access */ in db1x_pm_enter()
91 printk(KERN_ERR "db1x: no wakeup source activated!\n"); in db1x_pm_begin()
92 return -EINVAL; in db1x_pm_begin()
100 /* read and store wakeup source, the clear the register. To in db1x_pm_end()
116 #define ATTRCMP(x) (0 == strcmp(attr->attr.name, #x))
137 idx = (attr->attr.name)[4] - '0'; in db1x_pmattr_show()
145 return -ENOENT; in db1x_pmattr_show()
172 tmp = (attr->attr.name)[4] - '0'; in db1x_pmattr_store()
187 bytes = -ENOENT; in db1x_pmattr_store()
197 ATTR(gpio0) /* GPIO-based wakeup enable */
205 ATTR(timer) /* TOYMATCH2-based wakeup enable */
206 ATTR(timer_timeout) /* timer-based wakeup timeout value, in seconds */
207 ATTR(wakesrc) /* contents of SYS_WAKESRC after last wakeup */