/* * Power driver for HTC blueangel * * Copyright 2007 Anton Vorontsov * Copyright 2005 SDG Systems, LLC * Copyright 2005 Aric D. Blumer * Copyright 2005 Phil Blundell * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License version 2 as * published by the Free Software Foundation. */ #include #include #include #include #include #include #include #include #define DRIVER_NAME "blueangel_power" extern struct platform_device blueangel_asic3; static void blueangel_set_charge(int flags) { //SET_BLUEANGEL_GPIO_N(CHARGE_EN, flags & PDA_POWER_CHARGE_AC); //SET_BLUEANGEL_GPIO(USB_CHARGE_RATE, flags & PDA_POWER_CHARGE_USB); return; } static int blueangel_is_ac_online(void) { return !(asic3_get_gpio_status_d(&blueangel_asic3.dev) & (1<