summaryrefslogtreecommitdiff
path: root/firmware/target
diff options
context:
space:
mode:
authorMichael Sevakis <jethead71@rockbox.org>2010-06-22 04:00:34 +0000
committerMichael Sevakis <jethead71@rockbox.org>2010-06-22 04:00:34 +0000
commit831707d99191cfd7ed7d72725821bc2d9844baed (patch)
tree5a2bfbded1c8b0bec56629bd931bf3186adc44b3 /firmware/target
parent94c23e167c3f652b900b5f670f4cf3658247edb0 (diff)
lv24020lp tuner: On PP targets (c200/e200), use the atomic GPIO bitwise macros for the interface since it shares GPIOH with the clickwheel interrupt.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@27038 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'firmware/target')
-rw-r--r--firmware/target/arm/sandisk/power-c200_e200.c20
1 files changed, 10 insertions, 10 deletions
diff --git a/firmware/target/arm/sandisk/power-c200_e200.c b/firmware/target/arm/sandisk/power-c200_e200.c
index cc9d16f466..6637111ec8 100644
--- a/firmware/target/arm/sandisk/power-c200_e200.c
+++ b/firmware/target/arm/sandisk/power-c200_e200.c
@@ -107,18 +107,18 @@ bool tuner_power(bool status)
in host read mode: */
/* 1. Set direction of the DATA-line to input-mode. */
- GPIOH_OUTPUT_EN &= ~(1 << 5);
- GPIOH_ENABLE |= (1 << 5);
+ GPIO_CLEAR_BITWISE(GPIOH_OUTPUT_EN, 1 << 5);
+ GPIO_SET_BITWISE(GPIOH_ENABLE, 1 << 5);
/* 2. Drive NR_W low */
- GPIOH_OUTPUT_VAL &= ~(1 << 3);
- GPIOH_OUTPUT_EN |= (1 << 3);
- GPIOH_ENABLE |= (1 << 3);
+ GPIO_CLEAR_BITWISE(GPIOH_OUTPUT_VAL, 1 << 3);
+ GPIO_SET_BITWISE(GPIOH_OUTPUT_EN, 1 << 3);
+ GPIO_SET_BITWISE(GPIOH_ENABLE, 1 << 3);
/* 3. Drive CLOCK high */
- GPIOH_OUTPUT_VAL |= (1 << 4);
- GPIOH_OUTPUT_EN |= (1 << 4);
- GPIOH_ENABLE |= (1 << 4);
+ GPIO_SET_BITWISE(GPIOH_OUTPUT_VAL, 1 << 4);
+ GPIO_SET_BITWISE(GPIOH_OUTPUT_EN, 1 << 4);
+ GPIO_SET_BITWISE(GPIOH_ENABLE, 1 << 4);
lv24020lp_power(true);
}
@@ -127,8 +127,8 @@ bool tuner_power(bool status)
lv24020lp_power(false);
/* set all as inputs */
- GPIOH_OUTPUT_EN &= ~((1 << 5) | (1 << 3) | (1 << 4));
- GPIOH_ENABLE &= ~((1 << 3) | (1 << 4));
+ GPIO_CLEAR_BITWISE(GPIOH_OUTPUT_EN, (1 << 5) | (1 << 3) | (1 << 4));
+ GPIO_CLEAR_BITWISE(GPIOH_ENABLE, (1 << 3) | (1 << 4));
/* turn off mystery amplification device */
#if defined (SANSA_E200)