Date: Fri, 18 Jun 1999 13:47:26 -0400 (EDT) From: Thomas David Rivers <rivers@dignus.com> To: freebsd-mobile@freebsd.org, rivers@lakes.dignus.com Subject: Fix to readcis.c for "bad" cards (EP-210 is such a card.) Message-ID: <199906181747.NAA83933@lakes.dignus.com>
index | next in thread | raw e-mail
My particular EP-210 card has a bad "Version 1 info" tuple.
From the cis dump:
Tuple #9, code = 0x15 (Version 1 info), length = 27
000: 04 01 45 50 2d 32 31 30 20 50 43 4d 43 49 41 20
010: 4c 41 4e 20 43 41 52 44 2e 00 ff
Version = 4.1, Manuf = [EP-210 PCMCIA LAN CARD.]
Wrong length for version-1 info tuple
In this case, readcis() leaves trash in the "vers" field of
the tuple... making it almost impossible to match a card description
in the data base. (Sometimes it's NULL, sometimes it's just
left-over trash.)
I thought it might be better to have a "?" instead of random
trash, which lets my EP-210 card work reliably. (All of the code
in pccardd assumes that the `vers' field of a tuple is a valid string.)
(By the way, is there an "official" place for posting pccard bugs/fixes?)
Here's the change to the 3.2-PAO release,
/usr/src/PAO3/usr.sbin/pccard/pccardd/readcis.c:
*** readcis.c.ori Fri Jun 18 10:44:30 1999
--- readcis.c Fri Jun 18 12:39:21 1999
***************
*** 203,208 ****
--- 203,210 ----
if (len > 1 && *p != 0xff) {
cp->vers = strdup(p);
while (*p++ && --len > 0);
+ } else {
+ cp->vers = strdup("?");
}
if (cp->add_info1) {
free(cp->add_info1);
If this is integrated into the next PAO release, will someone please
let me know. That way, I can be assured my card will be recognized
for my install of subsequent versions of FreeBSD.
- Thanks -
- Dave Rivers -
p.s. I'm not on the freebsd-mobile list... please send e-mail directly.
To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-mobile" in the body of the message
help
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?199906181747.NAA83933>
