X-Git-Url: http://www.aleph1.co.uk/gitweb/?p=yaffs2.git;a=blobdiff_plain;f=direct%2Fpython%2Fyaffs_python_helper.c;h=7c2c7e06dca623085597ca9f407a55d2ce3655ec;hp=aa63d5e541d31af32701a542d7fcbdea59bf6012;hb=c118b37070fa47650ca61c8c740da7461450d139;hpb=a6f6a1bb6ff2b876047173be7cec28a1e1faaaa4 diff --git a/direct/python/yaffs_python_helper.c b/direct/python/yaffs_python_helper.c index aa63d5e..7c2c7e0 100644 --- a/direct/python/yaffs_python_helper.c +++ b/direct/python/yaffs_python_helper.c @@ -1,8 +1,7 @@ - /* * YAFFS: Yet Another Flash File System. A NAND-flash specific file system. * - * Copyright (C) 2002-2007 Aleph One Ltd. + * Copyright (C) 2002-2010 Aleph One Ltd. * for Toby Churchill Ltd and Brightstar Engineering * * Created by Charles Manning @@ -22,10 +21,14 @@ */ #include "yaffsfs.h" +#include "yaffs_trace.h" +#include "yaffs_error_converter.h" int simulate_power_failure; int random_seed; +const char * yaffs_error_to_str(int err); /*this is not part of yaffs. it is a specialy built file for converting error codes to text*/ + int yaffs_print_constants(void) { printf( "O_CREAT........%d\n",O_CREAT); @@ -34,6 +37,7 @@ int yaffs_print_constants(void) printf( "O_RDWR.........%d\n",O_RDWR); printf( "O_TRUNC........%d\n",O_TRUNC); + printf( "sizeof(off_t)..%d\n",sizeof(off_t)); return 0; } @@ -43,5 +47,13 @@ int yaffs_O_WRONLY(void) { return O_WRONLY;} int yaffs_O_RDWR(void) { return O_RDWR;} int yaffs_O_TRUNC(void) { return O_TRUNC;} -int yaffs_set_trace(unsigned int tm) { return yaffs_traceMask=tm; } -int yaffs_get_trace(void) { return yaffs_traceMask; } + +int yaffs_S_IFMT(void){return S_IFMT;} +int yaffs_S_IFLNK(void){return S_IFLNK;} +int yaffs_S_IFDIR(void){return S_IFDIR;} +int yaffs_S_IFREG(void){return S_IFREG;} +int yaffs_S_IREAD(void){return S_IREAD;} +int yaffs_S_IWRITE(void){return S_IWRITE;} +int yaffs_S_IEXEC(void){return S_IEXEC;} +int yaffs_XATTR_CREATE(void){return XATTR_CREATE;} +int yaffs_XATTR_REPLACE(void){return XATTR_REPLACE;}