summaryrefslogtreecommitdiff
path: root/firmware/target/arm/s5l8702/ipod6g/pmu-target.h
diff options
context:
space:
mode:
Diffstat (limited to 'firmware/target/arm/s5l8702/ipod6g/pmu-target.h')
-rw-r--r--firmware/target/arm/s5l8702/ipod6g/pmu-target.h25
1 files changed, 24 insertions, 1 deletions
diff --git a/firmware/target/arm/s5l8702/ipod6g/pmu-target.h b/firmware/target/arm/s5l8702/ipod6g/pmu-target.h
index d090f72a67..2274b4061f 100644
--- a/firmware/target/arm/s5l8702/ipod6g/pmu-target.h
+++ b/firmware/target/arm/s5l8702/ipod6g/pmu-target.h
@@ -30,7 +30,21 @@
30/* undocummented PMU registers */ 30/* undocummented PMU registers */
31#define PCF50635_REG_INT6 0x85 31#define PCF50635_REG_INT6 0x85
32#define PCF50635_REG_INT6M 0x86 32#define PCF50635_REG_INT6M 0x86
33#define PCF50635_REG_GPIOSTAT 0x87 /* bit1: GPIO2 status (TBC) */ 33#define PCF50635_REG_GPIOSTAT 0x87
34
35enum pcf50635_reg_int6 {
36 PCF50635_INT6_GPIO1 = 0x01, /* TBC */
37 PCF50635_INT6_GPIO2 = 0x02,
38};
39
40enum pcf50635_reg_gpiostat {
41 PCF50635_GPIOSTAT_GPIO1 = 0x01, /* TBC */
42 PCF50635_GPIOSTAT_GPIO2 = 0x02,
43};
44
45
46/* GPIO for external PMU interrupt */
47#define GPIO_EINT_PMU 0x7b
34 48
35/* LDOs */ 49/* LDOs */
36#define LDO_UNK1 1 /* TBC: SoC voltage (USB) */ 50#define LDO_UNK1 1 /* TBC: SoC voltage (USB) */
@@ -77,6 +91,15 @@ void pmu_read_rtc(unsigned char* buffer);
77void pmu_write_rtc(unsigned char* buffer); 91void pmu_write_rtc(unsigned char* buffer);
78void pmu_hdd_power(bool on); 92void pmu_hdd_power(bool on);
79 93
94int pmu_holdswitch_locked(void);
95int pmu_usb_present(void);
96#if CONFIG_CHARGING
97int pmu_firewire_present(void);
98#endif
99#ifdef IPOD_ACCESSORY_PROTOCOL
100int pmu_accessory_present(void);
101#endif
102
80void pmu_preinit(void); 103void pmu_preinit(void);
81#ifdef BOOTLOADER 104#ifdef BOOTLOADER
82unsigned char pmu_rd(int address); 105unsigned char pmu_rd(int address);