1 /*---------------------------------------------------------------------------*
2   Project:      Utilities for sample programs of NAND library
3   File:         util.h
4   Programmer:   HIRATSU Daisuke
5 
6   Copyright (C) 2006 Nintendo.  All rights reserved.
7 
8   These coded instructions, statements, and computer programs contain
9   proprietary information of Nintendo of America Inc. and/or Nintendo
10   Company Ltd., and are protected by Federal copyright law.  They may
11   not be disclosed to third parties or copied or duplicated in any form,
12   in whole or in part, without the prior written consent of Nintendo.
13 
14   $Log: util.h,v $
15   Revision 1.2  03/17/2006 02:39:58  hiratsu
16   Implemented MEM library wrapper in order to allocate buffer from MEM2 with 32byte alignment.
17 
18   Revision 1.1  01/24/2006 12:35:50  hiratsu
19   Utility functions for NAND library demo program.
20 
21  *---------------------------------------------------------------------------*/
22 
23 #ifndef __UTIL_H__
24 #define __UTIL_H__
25 
26 #include <revolution/types.h>
27 
28 #ifdef __cplusplus
29 extern "C" {
30 #endif
31 
32 void  initializeHeap(void);
33 void  finalizeHeap(void);
34 void* alloc32(u32 size);
35 void  free32(void *addr);
36 void  printErrMsg(s32 err);
37 
38 
39 #ifdef __cplusplus
40 }
41 #endif
42 
43 #endif // end of __UTIL_H__
44