Date: Sun, 24 Oct 2010 00:22:48 +0000 From: Alexander Best <arundel@freebsd.org> To: freebsd-hackers@freebsd.org Subject: fix pnpinfo on arch=amd64 Message-ID: <20101024002248.GA73346@freebsd.org>
next in thread | raw e-mail | index | archive | help
--G4iJoqBmSsgzjUCe
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
this tiny patch will fix pnpinfo so it doesn't core dump (bus error) any
longer on arch=amd64.
cheers.
alex
--
a13x
--G4iJoqBmSsgzjUCe
Content-Type: text/plain; charset=us-ascii
Content-Disposition: attachment; filename="pnpinfo.c.diff"
diff --git a/contrib/pnpinfo/pnpinfo.c b/contrib/pnpinfo/pnpinfo.c
index 790cfd8..c09f4ef 100644
--- a/contrib/pnpinfo/pnpinfo.c
+++ b/contrib/pnpinfo/pnpinfo.c
@@ -588,7 +588,7 @@ main(int argc, char **argv)
{
int num_pnp_devs;
-#ifdef __i386__
+#if defined(__i386__) || defined(__amd64__)
/* Hey what about a i386_iopl() call :) */
if (open("/dev/io", O_RDONLY) < 0)
errx(1, "can't get I/O privilege");
--G4iJoqBmSsgzjUCe--
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20101024002248.GA73346>
