From owner-freebsd-hackers@FreeBSD.ORG Sun Oct 24 00:22:48 2010 Return-Path: Delivered-To: freebsd-hackers@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 1233) id F17481065670; Sun, 24 Oct 2010 00:22:48 +0000 (UTC) Date: Sun, 24 Oct 2010 00:22:48 +0000 From: Alexander Best To: freebsd-hackers@freebsd.org Message-ID: <20101024002248.GA73346@freebsd.org> Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="G4iJoqBmSsgzjUCe" Content-Disposition: inline Subject: fix pnpinfo on arch=amd64 X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 24 Oct 2010 00:22:49 -0000 --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--