/*
 * @DEC_COPYRIGHT@
 */
/*
 * HISTORY
 * $Log:	vmmac.h,v $
 * Revision 4.2  91/09/19  23:03:10  devbld
 * Adding ODE Headers
 * 
 * $EndLog$
 */
/*	
 *	@(#)$RCSfile: vmmac.h,v $ $Revision: 4.2 $ (DEC) $Date: 91/09/19 23:03:10 $
 */ 
/*
 */
/*
 * (c) Copyright 1990, OPEN SOFTWARE FOUNDATION, INC.
 * ALL RIGHTS RESERVED
 */
/* 
 * Mach Operating System
 * Copyright (c) 1989 Carnegie-Mellon University
 * All rights reserved.  The CMU software License Agreement specifies
 * the terms and conditions for use and redistribution.
 */
/*
 * OSF/1 Release 1.0
 */
/*
 * Copyright (c) 1982, 1986 Regents of the University of California.
 * All rights reserved.  The Berkeley software License Agreement
 * specifies the terms and conditions for redistribution.
 *

 */

/*
 * Virtual memory related conversion macros
 */

#ifndef	_SYS_VMMAC_H_
#define _SYS_VMMAC_H_

/* Bytes to pages without rounding, and back */
#define btop(x)		(((unsigned)(x)) >> PGSHIFT)
#define ptob(x)		((caddr_t)((x) << PGSHIFT))

/* Average new into old with aging factor time */
#define ave(smooth, cnt, time) \
	smooth = ((time - 1) * (smooth) + (cnt)) / (time)

#endif	/* _SYS_VMMAC_H_ */
