diff options
author | Daniel Ritz <daniel.ritz@gmx.ch> | 2005-09-06 18:16:50 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@g5.osdl.org> | 2005-09-07 19:57:21 -0400 |
commit | ea2f1590aaffbd02f1850c19c3895ff4d092c6e0 (patch) | |
tree | 472a30659fc1e32f25730d62d46a9dee481cf245 /drivers/pcmcia/topic.h | |
parent | 36d57ac4a818cb4aa3edbdf63ad2ebc31106f925 (diff) |
[PATCH] yenta: make ToPIC95 bridges work with 16bit cards
ToPIC95 brides (and maybe some other too) require to use the ExCA registers
to power up the socket if a 16bit card is pluged. allow socket drivers to
set a flag so that yenta does just that. also clean up yenta_get_status()
a bit to use the new yenta_get_power() function.
Side note: ToPIC97 bridges (at least in Rev.5 i have) don't require this.
Ryan Underwood <nemesis-lists@icequake.net> said:
According to the mail that David Hinds received from a Toshiba engineer,
ToPIC95 and 97 do require this, and ToPIC100 does not. Maybe you have a
later revision.
For all chips, 16-bit cards can be enabled through ExCA. So doesn't it
make sense just to make this the default behavior for all Toshiba chips,
to avoid corner cases showing up later?
Daniel responded:
I disagree with ryan to change anything for topic97 bridges. they work.
and I couldn't find (read google) any report of a topic97 breaking on
applying power with the CB registers.
I'm having several toshba notebooks at work (and home) with topic95,97,100
bridges. Only the ones with a topic95 didn't work.
Signed-off-by: Daniel Ritz <daniel.ritz@gmx.ch>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Diffstat (limited to 'drivers/pcmcia/topic.h')
-rw-r--r-- | drivers/pcmcia/topic.h | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/drivers/pcmcia/topic.h b/drivers/pcmcia/topic.h index be420bb29113..edccfa5bb400 100644 --- a/drivers/pcmcia/topic.h +++ b/drivers/pcmcia/topic.h | |||
@@ -101,6 +101,8 @@ | |||
101 | #define TOPIC97_AVS_AUDIO_CONTROL 0x02 | 101 | #define TOPIC97_AVS_AUDIO_CONTROL 0x02 |
102 | #define TOPIC97_AVS_VIDEO_CONTROL 0x01 | 102 | #define TOPIC97_AVS_VIDEO_CONTROL 0x01 |
103 | 103 | ||
104 | #define TOPIC_EXCA_IF_CONTROL 0x3e /* 8 bit */ | ||
105 | #define TOPIC_EXCA_IFC_33V_ENA 0x01 | ||
104 | 106 | ||
105 | static void topic97_zoom_video(struct pcmcia_socket *sock, int onoff) | 107 | static void topic97_zoom_video(struct pcmcia_socket *sock, int onoff) |
106 | { | 108 | { |
@@ -137,4 +139,19 @@ static int topic97_override(struct yenta_socket *socket) | |||
137 | return 0; | 139 | return 0; |
138 | } | 140 | } |
139 | 141 | ||
142 | |||
143 | static int topic95_override(struct yenta_socket *socket) | ||
144 | { | ||
145 | u8 fctrl; | ||
146 | |||
147 | /* enable 3.3V support for 16bit cards */ | ||
148 | fctrl = exca_readb(socket, TOPIC_EXCA_IF_CONTROL); | ||
149 | exca_writeb(socket, TOPIC_EXCA_IF_CONTROL, fctrl | TOPIC_EXCA_IFC_33V_ENA); | ||
150 | |||
151 | /* tell yenta to use exca registers to power 16bit cards */ | ||
152 | socket->flags |= YENTA_16BIT_POWER_EXCA | YENTA_16BIT_POWER_DF; | ||
153 | |||
154 | return 0; | ||
155 | } | ||
156 | |||
140 | #endif /* _LINUX_TOPIC_H */ | 157 | #endif /* _LINUX_TOPIC_H */ |