summaryrefslogtreecommitdiffstats
path: root/rbutil/mkimxboot/dualboot
diff options
context:
space:
mode:
authorAmaury Pouly <amaury.pouly@gmail.com>2016-05-02 21:29:13 +0100
committerAmaury Pouly <amaury.pouly@gmail.com>2016-05-25 23:29:04 +0100
commita6b4bf3a338799ad6266f99ec0475142f120f863 (patch)
tree8e28a9108363fdc85079181d844ff103d9fbef34 /rbutil/mkimxboot/dualboot
parentb40ad7d269d131b153e6e97011c41ffdde68aaed (diff)
downloadrockbox-a6b4bf3a338799ad6266f99ec0475142f120f863.tar.gz
rockbox-a6b4bf3a338799ad6266f99ec0475142f120f863.zip
mkimxboot: remove code for NWZ-370/380
Since the stub code is shared with NWZ-360, it enables the pullup for the hold button, but the NWZ-370/380 doesn't have a hold button so don't compile this code in, it could potentially have unexpected effets or increase consumption Change-Id: I28c8aa40fc7f9373593ff105fb6df557a6f57ccd
Diffstat (limited to 'rbutil/mkimxboot/dualboot')
-rw-r--r--rbutil/mkimxboot/dualboot/dualboot.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/rbutil/mkimxboot/dualboot/dualboot.c b/rbutil/mkimxboot/dualboot/dualboot.c
index 4aa128e15b..17d02ebe08 100644
--- a/rbutil/mkimxboot/dualboot/dualboot.c
+++ b/rbutil/mkimxboot/dualboot/dualboot.c
@@ -160,8 +160,10 @@ static int local_decision(void)
* if back is pressed, boot to OF
* if play is pressed, boot RB
* otherwise power off */
+#ifdef SONY_NWZE360
if(read_gpio(0, 9) == 0)
return BOOT_STOP;
+#endif
if(val >= 1050 && val < 1150)
return BOOT_OF;
if(val >= 1420 && val < 1520)
@@ -172,7 +174,9 @@ static int local_decision(void)
static int boot_decision(int context)
{
setup_lradc(0); // setup LRADC channel 0 to read keys
+#ifdef SONY_NWZE360
HW_PINCTRL_PULLn_SET(0) = 1 << 9; // enable pullup on hold key (B0P09)
+#endif
/* make a decision */
int decision = local_decision();
/* in USB or alarm context, stick to it */