/*static char *SCCSID = "@(#)pr_alloc.h	6.4 92/01/31";*/
#include "PR_ALLOC.NAM"
/* Prototypes for all ALLOC\ functions */

	extern BOOL AddExt (LSN lsnFNode,
			PALBLK palb,
			union LASTRUN far *pLastRun,
			BOOL fWriteThru,
			LSN lsnNewPhys,
			LSN lsnNewLog,
			ULONG ulLen,
			PFRAME pfrm);


	extern BOOL AFB (ULONG culSec,
			LSN lsnPrefer,
			PLSN plsnRet,
			PFRAME pfrm);

	extern VOID ChooseBand( USHORT cusSecToAlloc,
			LSN lsnprefer,
			PVOLTAB pvoltab,
			PBANDTAB far *ppbtb1,
			PBANDTAB far *ppbtb2 );

	extern LSN ChooseDB(PFRAME pfrm);

	extern LSN COLS (POFT poft, PFRAME pfrm);

	extern BOOL EFA (ULONG ulNewLen,
			POFT poft,
			BOOL fWriteThru,
			PFRAME pfrm);

	extern PVOID GAS (LSN lsnPrefer,
			PBUFNODE far *ppbuf,
			PFRAME pfrm);


	extern BOOL GroExt (POFT poft,
			BOOL fWriteThru,
			ULONG culSectors,
			LSN lsnFirst,
			PFRAME pfrm);

	extern BOOL InitFil (PDIRBLK  pdbNewBlk,
			PDIRENT pdeNewEnt,
			PULONG pulLen,
			PLSN plsnFirst,
			PFRAME pfrm);

	extern PVOID PushTree (LSN lsnPrefer,
			PALBLK pAlBlk,
			PBUFNODE pBufNode,
			PALSEC pAlSec,
			LSN lsnParent,
			PBUFNODE far *ppNewBuf,
			PFRAME pfrm);


	extern VOID RelVerDB (PFRAME pfrm);

	extern USHORT TFA (PALBLK palb,
			ULONG csec,
			BOOL fWT,
			PFRAME pfrm);

/*
 * USHORT TFN (ULONG culSectors, POFT poft)
 *	Truncate the FNODE.  (for more info see TFN_)
 */
#define TFN( culSectors, poft, pfrm)  TFN_( culSectors, poft, TRUE, pfrm )

	extern USHORT TFN_ (ULONG culSectors,
			    POFT poft,
			    BOOL fWrtThru,
			    PFRAME pfrm);

	extern BOOL VerifyDB (PFRAME pfrm);

	extern BOOL FreeAS (LSN lsn, PFRAME pfrm);
#include "PR_ALLOC.SEG"
