PCMCIA breakage
Francois-Rene Rideau
fare@tunes.org
Sun May 2 12:24:27 CEST 2004
Oops, I spoke too fast.
So that things may work for me, I must invert the voltage flag on socket 1,
but not on socket 0.
Darn.
[ François-René ÐVB Rideau | Reflection&Cybernethics | http://fare.tunes.org ]
[ TUNES project for a Free Reflective Computing System | http://tunes.org ]
As far as we know, our computer has never had an undetected error.
-- Weisert
------>8------>8------>8------>8------>8------>8------>8------>8------>8------
-- sa1100_jornada820.c.oleg 2004-05-02 11:56:28.000000000 +0200
+++ sa1100_jornada820.c 2004-05-02 12:19:17.000000000 +0200
@@ -20,6 +20,9 @@
/* return socket status */
/* ************************************************************************* */
+#undef JORNADA820_PCMCIA_INVERT_VOLTAGE_0
+#define JORNADA820_PCMCIA_INVERT_VOLTAGE_1 1
+
int jornada820_pcmcia_socket_state(struct pcmcia_state_array *state)
{
unsigned long status;
@@ -29,16 +32,26 @@
state->state[0].detect = (status & PCSR_S0_detected) ? 0 : 1;
state->state[0].ready = (status & PCSR_S0_ready) ? 1 : 0;
+#ifndef JORNADA820_PCMCIA_INVERT_VOLTAGE_0
+ state->state[0].vs_3v = (status & PCSR_S0_VS1) ? 1 : 0;
+ state->state[0].vs_Xv = (status & PCSR_S0_VS2) ? 1 : 0;
+#else
state->state[0].vs_3v = (status & PCSR_S0_VS1) ? 0 : 1;
state->state[0].vs_Xv = (status & PCSR_S0_VS2) ? 0 : 1;
- state->state[0].bvd1 = (status & PCSR_S0_BVD1_nSTSCHG) ? 1 : 0 ;
+#endif
+ state->state[0].bvd1 = (status & PCSR_S0_BVD1_nSTSCHG) ? 1 : 0;
state->state[0].bvd2 = (status & PCSR_S0_BVD2_nSPKR) ? 1 : 0;
state->state[0].wrprot = (status & PCSR_S0_WP) ? 1 : 0;
state->state[1].detect = (status & PCSR_S1_detected) ? 0 : 1;
state->state[1].ready = (status & PCSR_S1_ready) ? 1 : 0;
+#ifndef JORNADA820_PCMCIA_INVERT_VOLTAGE_1
+ state->state[1].vs_3v = (status & PCSR_S1_VS1) ? 1 : 0;
+ state->state[1].vs_Xv = (status & PCSR_S1_VS2) ? 1 : 0;
+#else
state->state[1].vs_3v = (status & PCSR_S1_VS1) ? 0 : 1;
state->state[1].vs_Xv = (status & PCSR_S1_VS2) ? 0 : 1;
+#endif
state->state[1].bvd1 = (status & PCSR_S1_BVD1_nSTSCHG) ? 1 : 0;
state->state[1].bvd2 = (status & PCSR_S1_BVD2_nSPKR) ? 1 : 0;
state->state[1].wrprot = (status & PCSR_S1_WP) ? 1 : 0;
More information about the Jornada820
mailing list