From dab2d92b007935a860120ec3ec7963659c29706f Mon Sep 17 00:00:00 2001 From: imp Date: Fri, 9 Nov 2001 06:26:57 +0000 Subject: Fix the 3.3V support for Cirrus Logic CL-PD6710. This appears to work on my CL-PD6722, but won't work on the CL-PD6729. The latter two need more sophisticated detection of 3.3V cards than I'm up to at the moment. Also, only a few of the ISA chipsets that support 3.3V will likely work at the moment. It appears that for 3.3V cards we must detect them and adjust the pwr.vcc value from 50 to 33. Give a strong hint to automatically power up the card for PD_POWER cards. This makes my SMC 2602W (the 3.3V version of the 2632W) work on my Fujitsu Stylistic 500. SMC 3.3V card donated by: Ryan Losh Thanks to: bsd-nomads for reviews of past 3.3V code --- sys/pccard/pcic.c | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) (limited to 'sys/pccard') diff --git a/sys/pccard/pcic.c b/sys/pccard/pcic.c index f801e11..aaa683a 100644 --- a/sys/pccard/pcic.c +++ b/sys/pccard/pcic.c @@ -575,6 +575,28 @@ pcic_power(struct slot *slt) if ((c & PCIC_VS1STAT) == 0) slt->pwr.vcc = 33; } + if (sc->flags & PCIC_PD_POWER) { + /* + * Datasheets indicate that this is only supported on + * the CL-PD6710. However, my 6722 seems to support + * it as well. The datasheet for the '22 talks about + * the need to read this from register 0x6f.0xa (both + * slots are read from the same register). The + * datasheet is a little vauge. The '29 datasheet is + * clear and spells out the recommends way on the '22 + * is the way on the '29. Note: PCIC_MISC1_5V_DETECT + * is definitely not defined on the '29. + */ + c = sp->getb(sp, PCIC_MISC1); + if ((c & PCIC_MISC1_5V_DETECT) == 0) + slt->pwr.vcc = 33; + + /* + * Regardless of the above, setting the Auto Power Switch + * enable for the CL-PD 6722 seems to help too. + */ + reg |= PCIC_APSENA; + } /* * XXX Note: The Vpp controls varies quit a bit between bridge chips -- cgit v1.1