Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 13 Mar 2002 11:33:13 -0800
From:      Brooks Davis <brooks@one-eyed-alien.net>
To:        mobile@freebsd.org
Cc:        Oliver Brandmueller <ob@gruft.de>, Rasputin <rasputin@submonkey.net>, Dan Langille <dan@langille.org>
Subject:   patch for Lucent command timeouts
Message-ID:  <20020313113313.B11290@Odin.AC.HMC.Edu>

next in thread | raw e-mail | index | archive | help

--1UWUbFP1cBYEclgG
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
Content-Transfer-Encoding: quoted-printable

The following patch attempts to address the timeouts people have been
seeing in after my recent MFC of Linksys support.  Does two things,
first it doens't report timeouts of the INQUIRE command on non-Prism2
cards.  All the reports I saw were for Lucent cards so I left the
diagnostic in for others.  Second, it drasticly reduces the timeout from
500ms to 10ms.  10ms is a long time for a device and should not be
noticable to the user where 500ms was.  Please test and see if this
solves your problems.  Also, if Linksys WMP11 users could test this
patch to be sure it doesn't break their configuration, that would be
greatly appreciated.

-- Brooks

Index: if_wi.c
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D
RCS file: /usr/cvs/src/sys/dev/wi/if_wi.c,v
retrieving revision 1.80
diff -u -r1.80 if_wi.c
--- if_wi.c	11 Mar 2002 23:29:59 -0000	1.80
+++ if_wi.c	13 Mar 2002 19:27:49 -0000
@@ -1024,9 +1024,9 @@
 		DELAY(WI_DELAY);
 	}
=20
-	if (i =3D=3D WI_TIMEOUT) {
+	if (i =3D=3D WI_TIMEOUT && (sc->wi_prism2 || (cmd !=3D WI_CMD_INQUIRE))) {
 		device_printf(sc->dev,
-		    "timeout in wi_cmd %x; event status %x\n", cmd, s);
+		    "timeout in wi_cmd 0x%04X; event status 0x%04x\n", cmd, s);
 		return(ETIMEDOUT);
 	}
=20
Index: if_wireg.h
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D
RCS file: /usr/cvs/src/sys/dev/wi/if_wireg.h,v
retrieving revision 1.19
diff -u -r1.19 if_wireg.h
--- if_wireg.h	5 Mar 2002 16:06:54 -0000	1.19
+++ if_wireg.h	13 Mar 2002 19:16:57 -0000
@@ -150,7 +150,7 @@
 #define	WI_UNLOCK(_sc)
=20
 #define WI_DELAY	5
-#define WI_TIMEOUT	(500000/WI_DELAY)	/* 500 ms */
+#define WI_TIMEOUT	(10000/WI_DELAY)	/* 10 ms */
=20
 #define WI_PORT0	0
 #define WI_PORT1	1

--=20
Any statement of the form "X is the one, true Y" is FALSE.
PGP fingerprint 655D 519C 26A7 82E7 2529  9BF0 5D8E 8BE9 F238 1AD4

--1UWUbFP1cBYEclgG
Content-Type: application/pgp-signature
Content-Disposition: inline

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.0.6 (GNU/Linux)
Comment: For info see http://www.gnupg.org

iD8DBQE8j6l2XY6L6fI4GtQRAhdqAJ9wAaOhKVxyMBEjt4l8cJXuSEZRoACfSwV2
8DmydbKTjH4jWWz25QOQrE8=
=TDGd
-----END PGP SIGNATURE-----

--1UWUbFP1cBYEclgG--

To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-mobile" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20020313113313.B11290>