PCMCIA: soc_common: remove explicit wrprot initialization in socket drivers
soc_common already initializes state.wrprot to zero, so explicitly setting wrprot to zero in the socket drivers has no additional effect. Acked-by: Dominik Brodowski <linux@dominikbrodowski.net> Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
This commit is contained in:
parent
a7670151a4
commit
1c3d038bd5
|
@ -81,7 +81,6 @@ static void balloon3_pcmcia_socket_state(struct soc_pcmcia_socket *skt,
|
|||
state->bvd2 = 0; /* not available */
|
||||
state->vs_3v = 1; /* Always true its a CF card */
|
||||
state->vs_Xv = 0; /* not available */
|
||||
state->wrprot = 0; /* not available */
|
||||
}
|
||||
|
||||
static int balloon3_pcmcia_configure_socket(struct soc_pcmcia_socket *skt,
|
||||
|
|
|
@ -58,7 +58,6 @@ static void cmx255_pcmcia_socket_state(struct soc_pcmcia_socket *skt,
|
|||
{
|
||||
state->vs_3v = 0;
|
||||
state->vs_Xv = 0;
|
||||
state->wrprot = 0; /* not available */
|
||||
}
|
||||
|
||||
|
||||
|
|
|
@ -48,7 +48,6 @@ static void cmx270_pcmcia_socket_state(struct soc_pcmcia_socket *skt,
|
|||
{
|
||||
state->vs_3v = 0;
|
||||
state->vs_Xv = 0;
|
||||
state->wrprot = 0; /* not available */
|
||||
}
|
||||
|
||||
|
||||
|
|
|
@ -84,7 +84,6 @@ static void colibri_pcmcia_socket_state(struct soc_pcmcia_socket *skt,
|
|||
state->ready = !!gpio_get_value(colibri_pcmcia_gpios[READY].gpio);
|
||||
state->bvd1 = !!gpio_get_value(colibri_pcmcia_gpios[BVD1].gpio);
|
||||
state->bvd2 = !!gpio_get_value(colibri_pcmcia_gpios[BVD2].gpio);
|
||||
state->wrprot = 0;
|
||||
state->vs_3v = 1;
|
||||
state->vs_Xv = 0;
|
||||
}
|
||||
|
|
|
@ -44,7 +44,6 @@ static void e740_pcmcia_socket_state(struct soc_pcmcia_socket *skt,
|
|||
struct pcmcia_state *state)
|
||||
{
|
||||
state->vs_3v = 1;
|
||||
state->wrprot = 0;
|
||||
state->vs_Xv = 0;
|
||||
}
|
||||
|
||||
|
|
|
@ -83,7 +83,6 @@ static void mst_pcmcia_socket_state(struct soc_pcmcia_socket *skt,
|
|||
state->bvd2 = (status & MST_PCMCIA_nSPKR_BVD2) ? 1 : 0;
|
||||
state->vs_3v = (status & MST_PCMCIA_nVS1) ? 0 : 1;
|
||||
state->vs_Xv = (status & MST_PCMCIA_nVS2) ? 0 : 1;
|
||||
state->wrprot = 0; /* not available */
|
||||
}
|
||||
|
||||
static int mst_pcmcia_configure_socket(struct soc_pcmcia_socket *skt,
|
||||
|
|
|
@ -47,7 +47,6 @@ static void palmld_pcmcia_socket_state(struct soc_pcmcia_socket *skt,
|
|||
struct pcmcia_state *state)
|
||||
{
|
||||
state->detect = 1; /* always inserted */
|
||||
state->wrprot = 0;
|
||||
state->vs_3v = 1;
|
||||
state->vs_Xv = 0;
|
||||
}
|
||||
|
|
|
@ -51,7 +51,6 @@ static void palmtc_pcmcia_socket_state(struct soc_pcmcia_socket *skt,
|
|||
struct pcmcia_state *state)
|
||||
{
|
||||
state->detect = 1; /* always inserted */
|
||||
state->wrprot = 0;
|
||||
state->vs_3v = 1;
|
||||
state->vs_Xv = 0;
|
||||
}
|
||||
|
|
|
@ -47,7 +47,6 @@ static void palmtx_pcmcia_socket_state(struct soc_pcmcia_socket *skt,
|
|||
struct pcmcia_state *state)
|
||||
{
|
||||
state->detect = 1; /* always inserted */
|
||||
state->wrprot = 0;
|
||||
state->vs_3v = 1;
|
||||
state->vs_Xv = 0;
|
||||
}
|
||||
|
|
|
@ -54,7 +54,6 @@ static void sg2_pcmcia_socket_state(struct soc_pcmcia_socket *skt,
|
|||
state->bvd2 = 0; /* not available */
|
||||
state->vs_3v = 1; /* not available - voltage detect for card */
|
||||
state->vs_Xv = 0; /* not available */
|
||||
state->wrprot = 0; /* not available - write protect */
|
||||
}
|
||||
|
||||
static int sg2_pcmcia_configure_socket(struct soc_pcmcia_socket *skt,
|
||||
|
|
|
@ -75,7 +75,6 @@ static void trizeps_pcmcia_socket_state(struct soc_pcmcia_socket *skt,
|
|||
state->bvd2 = (status & ConXS_CFSR_BVD2) ? 1 : 0;
|
||||
state->vs_3v = (status & ConXS_CFSR_VS1) ? 0 : 1;
|
||||
state->vs_Xv = (status & ConXS_CFSR_VS2) ? 0 : 1;
|
||||
state->wrprot = 0; /* not available */
|
||||
break;
|
||||
|
||||
#ifndef CONFIG_MACH_TRIZEPS_CONXS
|
||||
|
@ -87,7 +86,6 @@ static void trizeps_pcmcia_socket_state(struct soc_pcmcia_socket *skt,
|
|||
state->bvd2 = 0;
|
||||
state->vs_3v = 0;
|
||||
state->vs_Xv = 0;
|
||||
state->wrprot = 0;
|
||||
break;
|
||||
|
||||
#endif
|
||||
|
|
|
@ -81,7 +81,6 @@ static void viper_pcmcia_hw_shutdown(struct soc_pcmcia_socket *skt)
|
|||
static void viper_pcmcia_socket_state(struct soc_pcmcia_socket *skt,
|
||||
struct pcmcia_state *state)
|
||||
{
|
||||
state->wrprot = 0;
|
||||
state->vs_3v = 1; /* Can only apply 3.3V */
|
||||
state->vs_Xv = 0;
|
||||
}
|
||||
|
|
|
@ -69,7 +69,6 @@ static void vpac270_pcmcia_hw_shutdown(struct soc_pcmcia_socket *skt)
|
|||
static void vpac270_pcmcia_socket_state(struct soc_pcmcia_socket *skt,
|
||||
struct pcmcia_state *state)
|
||||
{
|
||||
state->wrprot = 0;
|
||||
state->vs_3v = 1;
|
||||
state->vs_Xv = 0;
|
||||
}
|
||||
|
|
|
@ -34,7 +34,6 @@ static int assabet_pcmcia_hw_init(struct soc_pcmcia_socket *skt)
|
|||
static void
|
||||
assabet_pcmcia_socket_state(struct soc_pcmcia_socket *skt, struct pcmcia_state *state)
|
||||
{
|
||||
state->wrprot = 0; /* Not available on Assabet. */
|
||||
state->vs_3v = 1; /* Can only apply 3.3V on Assabet. */
|
||||
state->vs_Xv = 0;
|
||||
}
|
||||
|
|
|
@ -48,7 +48,6 @@ static void cerf_pcmcia_hw_shutdown(struct soc_pcmcia_socket *skt)
|
|||
static void
|
||||
cerf_pcmcia_socket_state(struct soc_pcmcia_socket *skt, struct pcmcia_state *state)
|
||||
{
|
||||
state->wrprot = 0;
|
||||
state->vs_3v = 1;
|
||||
state->vs_Xv = 0;
|
||||
}
|
||||
|
|
|
@ -96,7 +96,6 @@ h3600_pcmcia_socket_state(struct soc_pcmcia_socket *skt, struct pcmcia_state *st
|
|||
{
|
||||
state->bvd1 = 0;
|
||||
state->bvd2 = 0;
|
||||
state->wrprot = 0; /* Not available on H3600. */
|
||||
state->vs_3v = 0;
|
||||
state->vs_Xv = 0;
|
||||
}
|
||||
|
|
|
@ -106,7 +106,6 @@ static void nanoengine_pcmcia_socket_state(
|
|||
|
||||
state->bvd1 = 1;
|
||||
state->bvd2 = 1;
|
||||
state->wrprot = 0; /* Not available */
|
||||
state->vs_3v = 1; /* Can only apply 3.3V */
|
||||
state->vs_Xv = 0;
|
||||
}
|
||||
|
|
|
@ -44,7 +44,6 @@ shannon_pcmcia_socket_state(struct soc_pcmcia_socket *skt,
|
|||
{
|
||||
switch (skt->nr) {
|
||||
case 0:
|
||||
state->wrprot = 0; /* Not available on Shannon. */
|
||||
state->bvd1 = 1;
|
||||
state->bvd2 = 1;
|
||||
state->vs_3v = 1; /* FIXME Can only apply 3.3V on Shannon. */
|
||||
|
@ -52,7 +51,6 @@ shannon_pcmcia_socket_state(struct soc_pcmcia_socket *skt,
|
|||
break;
|
||||
|
||||
case 1:
|
||||
state->wrprot = 0; /* Not available on Shannon. */
|
||||
state->bvd1 = 1;
|
||||
state->bvd2 = 1;
|
||||
state->vs_3v = 1; /* FIXME Can only apply 3.3V on Shannon. */
|
||||
|
|
|
@ -46,7 +46,6 @@ simpad_pcmcia_socket_state(struct soc_pcmcia_socket *skt,
|
|||
|
||||
state->bvd1 = 1; /* Might be cs3reg & PCMCIA_BVD1 */
|
||||
state->bvd2 = 1; /* Might be cs3reg & PCMCIA_BVD2 */
|
||||
state->wrprot=0; /* Not available on Simpad. */
|
||||
|
||||
if ((cs3reg & (PCMCIA_VS1|PCMCIA_VS2)) ==
|
||||
(PCMCIA_VS1|PCMCIA_VS2)) {
|
||||
|
|
Loading…
Reference in New Issue