Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 17 Mar 2003 01:09:49 -0500
From:      Jake Burkholder <jake@locore.ca>
To:        Robert Watson <rwatson@FreeBSD.ORG>
Cc:        arch@FreeBSD.ORG
Subject:   Re: sizeof(void *)!=sizeof(vm_paddr_t)
Message-ID:  <20030317010949.A76446@locore.ca>
In-Reply-To: <Pine.NEB.3.96L.1030317005448.57214A-100000@fledge.watson.org>; from rwatson@FreeBSD.ORG on Mon, Mar 17, 2003 at 12:58:44AM -0500
References:  <Pine.NEB.3.96L.1030317005448.57214A-100000@fledge.watson.org>

next in thread | previous in thread | raw e-mail | index | archive | help
Apparently, On Mon, Mar 17, 2003 at 12:58:44AM -0500,
	Robert Watson said words to the effect of;

> 
> I just committed a new column to our increasingly complicated driver
> status table on the web site.  This column is intended to capture whether
> or not drivers are able to handle (both compile and run properly in) an
> environment where the assumption that a physical memory address can be
> stored in a variable of a pointer type.  Intel PAE support will operate
> only with drivers that meet this assumption.  If driver developers could
> review the table at
> 
>   http://www.FreeBSD.org/projects/busdma/
> 
> to make sure their driver is accurately characterized from the perspective
> of the current criteria: busdma, INTR_MPSAFE, SMPng locked, and p!=a
> safety.  In addition, if your driver is not safe on one or more of these
> counts, fixing it prior to 5.1-RELEASE would be a very good idea.  Drivers
> not adapted for these requirements will perform less well than drivers
> that are adapted, run on few hardware architectures, and may not run with
> large memory systems.  I've set the "default" for p!=a safety to "New",
> but I suspect a moderate number of drivers are already safe from this
> regard (including syscons, ata, ...)

Note that vm_paddr_t doesn't actually exist yet, but it will soon;
vm_offset_t can be more or less substituted.  The point is to always
use an arithmetic type for physical or bus addresses, not a pointer
type.  In general the only portable way to print these things is with
the %j modifier and to cast to uintmax_t.

Jake

> 
> Thanks,
> 
> Robert N M Watson             FreeBSD Core Team, TrustedBSD Projects
> robert@fledge.watson.org      Network Associates Laboratories
> 
> ---------- Forwarded message ----------
> Date: Sun, 16 Mar 2003 21:44:30 -0800 (PST)
> From: Robert Watson <rwatson@FreeBSD.org>
> To: doc-committers@FreeBSD.org, cvs-doc@FreeBSD.org, cvs-all@FreeBSD.org
> Subject: cvs commit: www/en/projects/busdma index.sgml
> 
> rwatson     2003/03/16 21:44:30 PST
> 
>   FreeBSD doc repository
> 
>   Modified files:
>     en/projects/busdma   index.sgml 
>   Log:
>   Add a new driver status column to indicate whether the driver can
>   safely handle sizeof(void *) != sizeof(vm_paddr_t) or !=
>   sizeof(bus_addr_t).  In order for drivers to be supported with PAE,
>   they must be able to handle this, including avoiding casting of
>   physical addresses to pointers for printfs, pointer arithmetic,
>   etc.
>   
>   Thought reasonable by:  jake
>   
>   Revision  Changes    Path
>   1.50      +88 -0     www/en/projects/busdma/index.sgml
> 
> 
> To Unsubscribe: send mail to majordomo@FreeBSD.org
> with "unsubscribe freebsd-arch" in the body of the message

To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-arch" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20030317010949.A76446>