Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 2 Dec 1995 16:06:41 -0800 (PST)
From:      Archie Cobbs <archie@tribe.com>
To:        julian@ref.tfs.com (Julian Elischer)
Cc:        archie@tribe.com, erich@lodgenet.com, hackers@FreeBSD.ORG
Subject:   Re: ethernet card configuration programs
Message-ID:  <199512030006.QAA02784@bubba.tribe.com>
In-Reply-To: <199512020715.XAA01029@ref.tfs.com> from "Julian Elischer" at Dec 1, 95 11:15:32 pm

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

> > > this is a linux web page with sources for ethernet
> > > card configuration.  I've compiled the 3c509, but
> > > I haven't tested it yet.
> > > 
> > > http://cesdis.gsfc.nasa.gov/linux/diag/diagnostic.html
> > > 
> > > eric.
> > > --
> > > erich@lodgenet.com
> > > erich@rrnet.com
> > 
> > Would it be possible for someone to port these to FreeBSD? This
> > would be great because I always have to boot DOS to run the stupid
> > config program for NE2000 compatible cards... for some reason the
> > default card configuration and the default FreeBSD "ed1" configuration
> > don't agree.
> > 
> > I don't know what the equivalent/substitute for #include <asm/io.h>
> > would be... but it looks like it shouldn't be too difficult
> > since the programs are very short.
> 
> #include <machine/cpufunc.h>
> 
> you have to open /dev/io to get permissions to do inb() and outb()
> instructions..
> otherwise it should just about compile...

Well, I tried this and... it seems to work! That is, it works with
"atlantic.c" but not with "ne2k.c", because ne2k.c also uses "outb_p"
and "inb_p", which this command has something to do with, I think:

    /* The following is needed for SLOW_DOWN_IO. */
    if (ioperm(0x80, 1, 1)) {
	perror("io-perm");
	return 1;
    }

Thanks for the help!
-Archie

_______________________________________________________________________________
Archie L. Cobbs, archie@tribe.com  *  Tribe Computer Works http://www.tribe.com



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