/* -*- Mode: C; tab-width: 4; indent-tabs-mode: 't; c-basic-offset: 4 -*-
*
* Name : $RCSfile: virtmem.h $
*
* Copyright : 2001,2002 by Imagination Technologies Limited.
* All rights reserved.
* No part of this software, either material or conceptual
* may be copied or distributed, transmitted, transcribed,
* stored in a retrieval system or translated into any
* human or computer language in any form by any means,
* electronic, mechanical, manual or other-wise, or
* disclosed to third parties without the express written
* permission of:
* Imagination Technologies Limited,
* HomePark Industrial Estate,
* Kings Langley,
* Hertfordshire,
* WD4 8LZ,
* UK
*
* Description : Declares functions providing virtually contiguous memory
* allocations under Linux.
*
* Version : $Revision: 1.7 $
*
**************************************************************************/
typedef struct tag_VirtAllocRec
{
struct tag_VirtAllocRec* pNext;
unsigned long pkvMem;
unsigned long pkvPageAlignedMem;
unsigned long nBytes;
} VIRT_ALLOC_REC, *PVIRT_ALLOC_REC;
/* Allocate virtually contiguous memory and mark it as reserved */
void* virtual_allocate_reserve(unsigned long nBytes, unsigned long bCached);
/* Unreserve & deallocate virtually contiguous memory */
void virtual_deallocate_unreserve(void* pkvPageAlignedMem);
/* Free any remaining memory allocations */
void virtual_memory_cleanup(void);
/* Prototype for function borrowed from hostfunc.c */
struct page *ConvertKVToPage(unsigned long pkvAddr);
/* EOF */
|