FreeBSD/sys/dev/ofw/ofw_standard.c
/* Return the fully qualified pathname corresponding to a package. */
Return the fully qualified pathname corresponding to a package.
Return the fully qualified pathname corresponding to a package .
static ssize_t
ofw_std_package_to_path(ofw_t ofw, phandle_t package, char *buf, size_t len)
{
	struct {
		cell_t name;
		cell_t nargs;
		cell_t nreturns;
		cell_t package;
		cell_t buf;
		cell_t len;
		cell_t size;
	} args = {
		(cell_t)"package-to-path",
		3,
		1,
	};
	args.package = package;
	args.buf = (cell_t)buf;
	args.len = len;
	if (openfirmware(&args) == -1)
		return (-1);
	return (args.size);
}
static ssize_t ofw_std_package_to_path ( ofw_t ofw , phandle_t package , char * buf , size_t len ) { struct { cell_t name ; cell_t nargs ; cell_t nreturns ; cell_t package ; cell_t buf ; cell_t len ; cell_t size ; } args = { ( cell_t ) " " , 3 , 1 , } ; args . package = package ; args . buf = ( cell_t ) buf ; args . len = len ; if ( openfirmware ( & args ) == -1 ) return ( -1 ) ; return ( args . size ) ; }
Return the fully qualified pathname corresponding to a package.
Return the fully qualified pathname corresponding to a package .