FreeBSD/sys/dev/ofw/ofw_standard.c
/* Claim an area of memory. */
Claim an area of memory.
Claim an area of memory .
static caddr_t
ofw_std_claim(ofw_t ofw, void *virt, size_t size, u_int align)
{
	struct {
		cell_t name;
		cell_t nargs;
		cell_t nreturns;
		cell_t virt;
		cell_t size;
		cell_t align;
		cell_t baseaddr;
	} args = {
		(cell_t)"claim",
		3,
		1,
	};
	args.virt = (cell_t)virt;
	args.size = size;
	args.align = align;
	if (openfirmware(&args) == -1)
		return ((void *)-1);
	return ((void *)args.baseaddr);
}
static caddr_t ofw_std_claim ( ofw_t ofw , void * virt , size_t size , u_int align ) { struct { cell_t name ; cell_t nargs ; cell_t nreturns ; cell_t virt ; cell_t size ; cell_t align ; cell_t baseaddr ; } args = { ( cell_t ) " " , 3 , 1 , } ; args . virt = ( cell_t ) virt ; args . size = size ; args . align = align ; if ( openfirmware ( & args ) == -1 ) return ( ( void * ) -1 ) ; return ( ( void * ) args . baseaddr ) ; }
Claim an area of memory.
Claim an area of memory .