Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 9 Jan 2000 23:21:34 +0100 (MET)
From:      Gerard Roudier <groudier@club-internet.fr>
To:        Peter Wemm <peter@netplex.com.au>
Cc:        "Rodney W. Grimes" <freebsd@gndrsh.dnsmgr.net>, obrien@NUXI.com, "Chris D. Faulhaber" <jedgar@fxp.org>, cvs-committers@FreeBSD.org, cvs-all@FreeBSD.org
Subject:   Re: cvs commit: src/sys/i386/conf GENERIC LINT 
Message-ID:  <Pine.LNX.3.95.1000109224806.340A-100000@localhost>
In-Reply-To: <20000109151602.C6BAE1CC6@overcee.netplex.com.au>

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

On Sun, 9 Jan 2000, Peter Wemm wrote:

> Just for reference, this is the patch I am talking about and think we sho=
uld
> use:
> Index: ncr.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: /home/ncvs/src/sys/pci/ncr.c,v
> retrieving revision 1.141.2.4
> diff -u -r1.141.2.4 ncr.c
> --- ncr.c=091999/08/29 16:31:53=091.141.2.4
> +++ ncr.c=092000/01/09 15:10:39
> @@ -39,6 +39,8 @@
>  ************************************************************************=
***
>  */
> =20
> +#include "sym.h"=09=09/* for NSYM */
> +
>  #define NCR_DATE "pl30 98/1/1"
> =20
>  #define NCR_VERSION=09(2)
> @@ -3314,6 +3316,14 @@
>  =09
>  =09found =3D -1;
>  =09for (i =3D 0; i < sizeof(ncr_chip_table)/sizeof(ncr_chip_table[0]); i=
++) {
> +#if NSYM > 0
> +=09=09/*
> +=09=09 *  Ignore chips that support LOAD/STORE, so the sym_hipd
> +=09=09 *  driver will attach them without any conflict.
> +=09=09 */
> +=09=09if (ncr_chip_table[i].features & FE_LDSTR)
> +=09=09=09continue;
> +#endif
>  =09=09if (device_id=09=3D=3D ncr_chip_table[i].device_id &&
>  =09=09    ncr_chip_table[i].minrevid <=3D revision_id) {
>  =09=09=09if (found < 0 ||=20
>=20

Hmmm... In fact this patch hasn't the expected effect :). I didn't provide=
=20
a better one since nobody seems to need to configure both drivers.

The one we should want to use, if needed, looks like the below one, modulo
the '#if NSYM' and friends:=20

Index: ncr.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: /home/ncvs/src/sys/pci/ncr.c,v
retrieving revision 1.141.2.4
diff -u -r1.141.2.4 ncr.c
--- ncr.c=091999/08/29 16:31:53=091.141.2.4
+++ ncr.c=091999/11/20 17:15:10
@@ -3314,8 +3314,16 @@
 =09
 =09found =3D -1;
 =09for (i =3D 0; i < sizeof(ncr_chip_table)/sizeof(ncr_chip_table[0]); i++=
) {
+/*
+ *  Ignore chips that support LOAD/STORE, so the sym_hipd driver will=20
+ *  attach them without any conflict.
+ */
 =09=09if (device_id=09=3D=3D ncr_chip_table[i].device_id &&
 =09=09    ncr_chip_table[i].minrevid <=3D revision_id) {
+=09=09=09if (ncr_chip_table[i].features & FE_LDSTR) {
+=09=09=09=09found =3D -1;
+=09=09=09=09continue;
+=09=09=09}
 =09=09=09if (found < 0 ||=20
 =09=09=09    ncr_chip_table[found].minrevid=20
 =09=09=09      < ncr_chip_table[i].minrevid) {

The previous patch was broken since the ncr driver inspects the whole chip
table and use as 'best' entry the one that corresponds to the highest
minrevid field value.=20

For example a 810A, will be caught by a previous entry that fits the 810
(revid < 0x10) and that hasn't the FE_LDSTR bit set.

And, by the way, I donnot bet that the second patch is quite ok.:-)
It should be fine given that the LOAD/STORE has never been dropped by=20
later chip revisions once it has been supported.

Do we really need such a patch ? :)

G=E9rard.



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




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?Pine.LNX.3.95.1000109224806.340A-100000>