From owner-svn-src-head@FreeBSD.ORG Mon Dec 10 23:40:22 2012 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 0C83D278; Mon, 10 Dec 2012 23:40:22 +0000 (UTC) (envelope-from zeising@freebsd.org) Received: from mail.lysator.liu.se (mail.lysator.liu.se [IPv6:2001:6b0:17:f0a0::3]) by mx1.freebsd.org (Postfix) with ESMTP id 5F7748FC14; Mon, 10 Dec 2012 23:40:21 +0000 (UTC) Received: from mail.lysator.liu.se (localhost [127.0.0.1]) by mail.lysator.liu.se (Postfix) with ESMTP id 4B64F40006; Tue, 11 Dec 2012 00:40:20 +0100 (CET) Received: by mail.lysator.liu.se (Postfix, from userid 1004) id 3B51740005; Tue, 11 Dec 2012 00:40:20 +0100 (CET) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on bernadotte.lysator.liu.se X-Spam-Level: X-Spam-Status: No, score=0.0 required=5.0 tests=AWL autolearn=disabled version=3.3.1 X-Spam-Score: 0.0 Received: from mx.daemonic.se (mx.daemonic.se [IPv6:2001:470:dca9:0:1::3]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by mail.lysator.liu.se (Postfix) with ESMTPSA id 7DD1B40003; Tue, 11 Dec 2012 00:40:19 +0100 (CET) Received: from mailscanner.daemonic.se (mailscanner.daemonic.se [IPv6:2001:470:dca9:0:1::6]) by mx.daemonic.se (Postfix) with ESMTPS id 3YL143137Kz8hVn; Tue, 11 Dec 2012 00:40:19 +0100 (CET) X-Virus-Scanned: amavisd-new at daemonic.se Received: from mx.daemonic.se ([10.1.0.3]) (using TLS with cipher CAMELLIA256-SHA) by mailscanner.daemonic.se (mailscanner.daemonic.se [10.1.0.6]) (amavisd-new, port 10025) with ESMTPS id CvAV-5ZiHyT3; Tue, 11 Dec 2012 00:40:16 +0100 (CET) Received: from mail.daemonic.se (mail.daemonic.se [10.1.0.4]) by mx.daemonic.se (Postfix) with ESMTPS id 3YL1404N7Gz8hVm; Tue, 11 Dec 2012 00:40:16 +0100 (CET) Received: from vivi.daemonic.se (vivi.daemonic.se [10.32.0.4]) by mail.daemonic.se (Postfix) with ESMTPSA id 3YL1403k25z9Ctj; Tue, 11 Dec 2012 00:40:16 +0100 (CET) Message-ID: <50C672D0.9090908@freebsd.org> Date: Tue, 11 Dec 2012 00:40:00 +0100 From: Niclas Zeising User-Agent: Mutt/1.5.21 MIME-Version: 1.0 To: Carl Delsey Subject: Re: svn commit: r243960 - in head/sys: amd64/include i386/include x86/include References: <201212062233.qB6MXWpP046167@svn.freebsd.org> <50C66E2E.5040302@freebsd.org> <50C67129.6090704@intel.com> In-Reply-To: <50C67129.6090704@intel.com> X-Enigmail-Version: 1.4.6 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-Virus-Scanned: ClamAV using ClamSMTP Cc: svn-src-head@freebsd.org, Jim Harris , svn-src-all@freebsd.org, src-committers@freebsd.org X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 10 Dec 2012 23:40:22 -0000 On 12/11/12 00:32, Carl Delsey wrote: > On 12/10/12 16:20, Niclas Zeising wrote: >> On 12/06/12 23:33, Jim Harris wrote: >>> Author: jimharris >>> Date: Thu Dec 6 22:33:31 2012 >>> New Revision: 243960 >>> URL: http://svnweb.freebsd.org/changeset/base/243960 >>> >>> Log: >>> Add amd64 implementations for 8-byte bus_space routines. >>> +#include >>> #include >>> + >>> +#define KASSERT_BUS_SPACE_MEM_ONLY(tag) \ >>> + KASSERT((tag) == X86_BUS_SPACE_MEM, \ >>> + ("%s: can only handle mem space", __func__)) >>> + >>> +static __inline uint64_t >>> +bus_space_read_8(bus_space_tag_t tag, bus_space_handle_t bsh, >>> + bus_size_t ofs) >>> +{ >>> + >>> + KASSERT_BUS_SPACE_MEM_ONLY(tag); >>> + >>> + return (*(volatile uint64_t *)(bsh + ofs)); >>> +} >> Hi! >> Can the include of and the added KASSERTs please be hidden >> under #ifdef _KERNEL or something similar? devel/libpciaccess from the >> experimental xorg-dev tree >> (http://trillian.chruetertee.ch/ports/browser/trunk/devel/libpciaccess) >> uses machine/bus.h on amd64 and i386 to be able to read/write to the pci >> bus, and this change breaks the compile of devel/libpciaccess. >> It is probably so that libpciaccess is wrong in using >> but I have no idea how to fix it. If you have a better suggestion on >> how to fix libpciaccess I am all ears. >> Regards! > Does libpciaccess make use of the bus_space_read/write_* routines in > these files, or does it just use some constants and types from them? > libpciaccess uses bus_space_[read,write]_[1,2,4], which are defined in x86/bus.h. It does not use the quad functions. Regards! -- Niclas Zeising