summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAidan MacDonald <amachronic@protonmail.com>2022-01-09 19:57:55 +0000
committerAidan MacDonald <amachronic@protonmail.com>2022-01-09 19:58:35 +0000
commitb490f08b7c6f8b32b214e0fbf6dd3974066ec150 (patch)
tree2aa54c4d6b2a971f7fe0a648dc0f5fabacd177d2
parenteee8243102460986ba1733222ebdbe9ac3200d77 (diff)
downloadrockbox-b490f08b7c6f8b32b214e0fbf6dd3974066ec150.tar.gz
rockbox-b490f08b7c6f8b32b214e0fbf6dd3974066ec150.zip
axp-pmu: remove chip ID code
It's useless except to developers, who can easily add code somewhere to print the ID. Change-Id: I486240f1c7b45808a1a830abdb22b9381d69cb3f
-rw-r--r--firmware/drivers/axp-pmu.c13
1 files changed, 0 insertions, 13 deletions
diff --git a/firmware/drivers/axp-pmu.c b/firmware/drivers/axp-pmu.c
index e9af3c0b05..ed284ee9c2 100644
--- a/firmware/drivers/axp-pmu.c
+++ b/firmware/drivers/axp-pmu.c
@@ -128,18 +128,12 @@ static const struct axp_supply_info axp_supply_info[AXP_NUM_SUPPLIES] = {
static struct axp_driver {
int adc_enable;
- int chip_id;
} axp;
static void axp_init_enabled_adcs(void)
{
axp.adc_enable = 0;
- /* Read chip ID, so we can display it on the debug screen.
- * This is undocumented but there's Linux driver code floating around
- * which suggests this should work for many AXP chips. */
- axp.chip_id = i2c_reg_read1(AXP_PMU_BUS, AXP_PMU_ADDR, AXP_REG_CHIP_ID);
-
/* Read enabled ADCs from the hardware */
uint8_t regs[2];
int rc = i2c_reg_read(AXP_PMU_BUS, AXP_PMU_ADDR,
@@ -494,7 +488,6 @@ void axp_power_off(void)
#ifndef BOOTLOADER
enum {
- AXP_DEBUG_CHIP_ID,
AXP_DEBUG_BATTERY_STATUS,
AXP_DEBUG_INPUT_STATUS,
AXP_DEBUG_CHARGE_CURRENT,
@@ -568,12 +561,6 @@ static const char* axp_debug_menu_get_name(int item, void* data,
}
switch(item) {
- case AXP_DEBUG_CHIP_ID: {
- snprintf(buf, buflen, "Chip ID: %d (%02x) [Driver: AXP%d]",
- axp.chip_id, axp.chip_id, HAVE_AXP_PMU);
- return buf;
- } break;
-
case AXP_DEBUG_BATTERY_STATUS: {
switch(axp_battery_status()) {
case AXP_BATT_FULL: