From owner-freebsd-hackers@FreeBSD.ORG Thu May 5 10:32:22 2005 Return-Path: Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 4E9BC16A4CE for ; Thu, 5 May 2005 10:32:22 +0000 (GMT) Received: from kalypso.opteqint.net (kalypso.opteqint.net [160.124.112.28]) by mx1.FreeBSD.org (Postfix) with ESMTP id CAF0243D6A for ; Thu, 5 May 2005 10:32:21 +0000 (GMT) (envelope-from cole@opteqint.net) Received: from rrba-165-32-77.telkomadsl.co.za ([165.165.32.77] helo=deadmind) by kalypso.opteqint.net with esmtpsa (TLSv1:RC4-MD5:128) (Exim 4.43 (FreeBSD)) id 1DTdeM-000N5x-T2 for freebsd-hackers@freebsd.org; Thu, 05 May 2005 12:32:15 +0200 Message-ID: <000701c5515e$aaf00700$4206000a@deadmind> From: "Cole" To: References: <000901c55159$da7fe080$4206000a@deadmind> Date: Thu, 5 May 2005 12:39:07 +0200 MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit X-Priority: 3 X-MSMail-Priority: Normal X-Mailer: Microsoft Outlook Express 5.50.4922.1500 X-MimeOLE: Produced By Microsoft MimeOLE V5.50.4939.300 X-Spam-Score: -100.0 (---------------------------------------------------) X-Spam-Report: Spam detection software, running on the system "kalypso.opteqint.net", hasmessagelabel similar future email. If you have any questions, see the administrator of that system for details.using outl_p to communicate with the device, and write the values. /Cole [...] Content analysis details: (-100.0 points, 4.2 required) pts rule name description -------------------------------------------------- -100 USER_IN_WHITELIST From: address is in the user's white-list Subject: Re: Pci Question X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list Reply-To: Cole List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 05 May 2005 10:32:22 -0000 Err, sorry. I meant the linux version of this is using outl_p to communicate with the device, and write the values. /Cole ----- Original Message ----- From: "Cole" To: Sent: Thursday, May 05, 2005 12:04 PM Subject: Pci Question > Hi > > Im trying to write a userland program that writes to the IOPORT BAR's of a pci card. I can find the card and all that fine. But im a > bit lost on exactly what address the IOPORT BAR's would be then? Im using the /dev/pci and pci(4) functions to find the card. > > Ive seen in the linux version of those code, that they take the base_address's and then & ~0x03 them, and use that value for reading > and writing with inb_l and outb_l. Ive tried using that on FreeBSD, but with outl and inl, as well as writel and readl, but I keep > getting "Bus error". > > Is there perhaps something that I am missing or forgetting, also im running the program as root. > > If anyone has any suggestions, they would be most welcome. > > Thanks > /Cole > > _______________________________________________ > freebsd-hackers@freebsd.org mailing list > http://lists.freebsd.org/mailman/listinfo/freebsd-hackers > To unsubscribe, send any mail to "freebsd-hackers-unsubscribe@freebsd.org"