From owner-freebsd-hackers@FreeBSD.ORG Thu Mar 11 19:48:51 2010 Return-Path: Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 4272B1065670 for ; Thu, 11 Mar 2010 19:48:51 +0000 (UTC) (envelope-from kabaev@gmail.com) Received: from fg-out-1718.google.com (fg-out-1718.google.com [72.14.220.154]) by mx1.freebsd.org (Postfix) with ESMTP id C44368FC19 for ; Thu, 11 Mar 2010 19:48:50 +0000 (UTC) Received: by fg-out-1718.google.com with SMTP id e21so46213fga.13 for ; Thu, 11 Mar 2010 11:48:49 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:received:date:from:cc:subject :message-id:in-reply-to:references:x-mailer:mime-version :content-type; bh=FJEa/6UqLfs3DixVKI6bDw+1dLYqyRqdgD9r59fbFXM=; b=xEVg6JXUMFw0frQ0pF02cWBfsk0c2O0E/8peBk4W30moUfdGy1CoM9deZX1+/TAYM4 TlIAuFZ0plHZoz4ZWeTX+WIfbUZXRLdlT474Iqn7XcI/OiVfoiUghwB42EHQnWKzQ1lY nh9IVFstPxZjHR7XPvIEsN90QFLt9nNSZO5NQ= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=date:from:cc:subject:message-id:in-reply-to:references:x-mailer :mime-version:content-type; b=iwSSOvASWrY59DScEJpkQSkBGJLvcE0XXDjXObzufCo+uod4+w0WfRA7OUMdvoTWMl Cs3GY+qpCCD4Q73g8jzptAQVDNYaJRtvzYgz5gwbkqhQCPP+2whes7zW4wZz+FVD6tuJ Szgj2fPV7Jgim/tpS9CvUOBD0praAYFDiLjXA= Received: by 10.87.45.20 with SMTP id x20mr84518fgj.63.1268335074031; Thu, 11 Mar 2010 11:17:54 -0800 (PST) Received: from kan.dnsalias.net (c-24-63-226-98.hsd1.ma.comcast.net [24.63.226.98]) by mx.google.com with ESMTPS id d4sm68085fga.11.2010.03.11.11.17.51 (version=SSLv3 cipher=RC4-MD5); Thu, 11 Mar 2010 11:17:52 -0800 (PST) Date: Thu, 11 Mar 2010 14:17:46 -0500 From: Alexander Kabaev Cc: freebsd-hackers@freebsd.org Message-ID: <20100311141746.7bce7b98@kan.dnsalias.net> In-Reply-To: <201003110814.31009.jhb@freebsd.org> References: <9f206d1a1003110104p2f329103mc882c99bcc15ea51@mail.gmail.com> <201003110814.31009.jhb@freebsd.org> X-Mailer: Claws Mail 3.7.5 (GTK+ 2.18.7; amd64-portbld-freebsd9.0) Mime-Version: 1.0 Content-Type: multipart/signed; micalg=PGP-SHA1; boundary="Sig_/KkWBbKu+E5NGgF+tVYd=RJW"; protocol="application/pgp-signature" Subject: Re: bus_space_tag, bus_space_handle 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: Thu, 11 Mar 2010 19:48:51 -0000 --Sig_/KkWBbKu+E5NGgF+tVYd=RJW Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: quoted-printable On Thu, 11 Mar 2010 08:14:30 -0500 John Baldwin wrote: > On Thursday 11 March 2010 4:04:52 am Cole wrote: > > Hi. > >=20 > > Im currently needing to write to a few registers for a PCI device. > > The driver is provided, but it does not contain support for writing > > specific registers itself. I also do not with to modify the driver. > >=20 > > I would like to know what the best method would be for writing to > > these registers, the best way to go about getting bus_space_tag, and > > handle for the connected pci device. > >=20 > > Im currently using FreeBSD 7.x. >=20 > You will most likely need to modify the driver. The PCI bus code > only hands out valid resources for a given BAR to the device_t for a > given device. >=20 > --=20 > John Baldwin I used /dev/mem and dd in the past for this purpose. Not pretty and custom tool beats it any day, but it does work. --=20 Alexander Kabaev --Sig_/KkWBbKu+E5NGgF+tVYd=RJW Content-Type: application/pgp-signature; name=signature.asc Content-Disposition: attachment; filename=signature.asc -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.14 (FreeBSD) iD8DBQFLmUHeQ6z1jMm+XZYRAuT1AKDA7Ac2GZxICvQyyc/qgZySPjdudACeIvJh 89txqnr8KKl5cjAQ3z/P2Lg= =8xmK -----END PGP SIGNATURE----- --Sig_/KkWBbKu+E5NGgF+tVYd=RJW--