Port pnpinfo to alpha.
This commit is contained in:
parent
345a2a7d8e
commit
0ff387396e
@ -23,7 +23,7 @@
|
||||
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
|
||||
* SUCH DAMAGE.
|
||||
*
|
||||
* $Id: pnpinfo.c,v 1.3 1998/09/13 22:15:44 eivind Exp $
|
||||
* $Id: pnpinfo.c,v 1.4 1999/05/04 16:59:42 luoqi Exp $
|
||||
*/
|
||||
|
||||
#include <sys/time.h>
|
||||
@ -578,16 +578,22 @@ isolation_protocol()
|
||||
}
|
||||
|
||||
|
||||
void
|
||||
main()
|
||||
int
|
||||
main(int argc, char **argv)
|
||||
{
|
||||
int num_pnp_devs;
|
||||
|
||||
#ifdef __i386__
|
||||
/* Hey what about a i386_iopl() call :) */
|
||||
if (open("/dev/io", O_RDONLY) < 0) {
|
||||
fprintf (stderr, "pnpinfo: Can't get I/O privilege.\n");
|
||||
exit (1);
|
||||
}
|
||||
#endif
|
||||
#ifdef __alpha__
|
||||
ioperm(0x203, 0x400 - 0x203, 1);
|
||||
#endif
|
||||
|
||||
printf("Checking for Plug-n-Play devices...\n");
|
||||
|
||||
/* Try various READ_DATA ports from 0x203-0x3ff */
|
||||
@ -599,6 +605,6 @@ main()
|
||||
}
|
||||
if (!num_pnp_devs) {
|
||||
printf("No Plug-n-Play devices were found\n");
|
||||
return;
|
||||
return 0;
|
||||
}
|
||||
}
|
||||
|
@ -1,5 +1,5 @@
|
||||
# From: @(#)Makefile 5.20 (Berkeley) 6/12/93
|
||||
# $Id: Makefile,v 1.154 1999/05/05 07:37:03 wpaul Exp $
|
||||
# $Id: Makefile,v 1.155 1999/05/10 10:17:00 obrien Exp $
|
||||
|
||||
# XXX MISSING: mkproto
|
||||
SUBDIR= IPXrouted \
|
||||
@ -56,6 +56,7 @@ SUBDIR= IPXrouted \
|
||||
pciconf \
|
||||
periodic \
|
||||
pkg_install \
|
||||
pnpinfo \
|
||||
portmap \
|
||||
ppp \
|
||||
pppctl \
|
||||
@ -128,7 +129,6 @@ SUBDIR+=apm \
|
||||
mixer \
|
||||
mptable \
|
||||
pcvt \
|
||||
pnpinfo \
|
||||
rndcontrol \
|
||||
sgsc \
|
||||
sicontrol \
|
||||
|
@ -1,4 +1,4 @@
|
||||
# $Id: Makefile,v 1.1 1997/09/19 15:41:57 jmg Exp $
|
||||
# $Id: Makefile,v 1.2 1998/03/12 12:54:25 eivind Exp $
|
||||
|
||||
PROG= pnpinfo
|
||||
|
||||
@ -6,6 +6,10 @@ SRCS= pnpinfo.c
|
||||
CFLAGS+=-I${.CURDIR}/../../sys
|
||||
MAN8= pnpinfo.8
|
||||
|
||||
.if ${MACHINE_ARCH} == "alpha"
|
||||
LDADD+= -lio
|
||||
.endif
|
||||
|
||||
.PATH: ${.CURDIR}/../../contrib/pnpinfo
|
||||
|
||||
.include <bsd.prog.mk>
|
||||
|
Loading…
x
Reference in New Issue
Block a user