| 12 | | |
| 13 | | int ConfigAddIntEntry(struct KeFsEntry* dir, char* name, void* value) |
| 14 | | { |
| 15 | | return IcFsAddIntEntry(dir, name, (int*)value, VFS_ATTR_RW); |
| 16 | | } |
| 17 | | |
| 18 | | SYMBOL_EXPORT(ConfigAddIntEntry); |
| 19 | | |
| 20 | | int ConfigAddArrayEntry(struct KeFsEntry* dir, char* name, BYTE* value, int minLen, int maxLen, int size) |
| 21 | | { |
| 22 | | /* TODO: Create general IcFs function. */ |
| 23 | | struct IcFsEntry* entry; |
| 24 | | |
| 25 | | entry=IcFsAddStrEntry(dir, name, (char*)value, VFS_ATTR_RW); |
| 26 | | |
| 27 | | if (!entry) |
| 28 | | return -EINVAL; |
| 29 | | |
| 30 | | entry->type=ICFS_TYPE_BYTE; |
| 31 | | entry->minLen=minLen; |
| 32 | | entry->maxLen=maxLen; |
| 33 | | entry->size=size; |
| 34 | | |
| 35 | | return 0; |
| 36 | | } |
| 37 | | |
| 38 | | SYMBOL_EXPORT(ConfigAddArrayEntry); |
| 39 | | |
| 40 | | int ConfigAddSoftLink(struct KeFsEntry* dir, char* name, int (*followLink)(char* buffer, int size)) |
| 41 | | { |
| 42 | | return IcFsAddSoftLink(dir, name, followLink); |
| 43 | | } |
| 44 | | |
| 45 | | SYMBOL_EXPORT(ConfigAddSoftLink); |
| 46 | | |
| 47 | | struct KeFsEntry* ConfigCreateDir(struct KeFsEntry* dir, char* name) |
| 48 | | { |
| 49 | | return IcFsCreateDir(dir, name); |
| 50 | | } |
| 51 | | |
| 52 | | SYMBOL_EXPORT(ConfigCreateDir); |