X-Git-Url: https://git.ozlabs.org/?p=yaboot.git;a=blobdiff_plain;f=include%2Ffile.h;fp=include%2Ffile.h;h=03c5c6fe3e40877d317237b17196503384cb8e7a;hp=c68d84f66eeec8e0cbd08efd7806fc2923450a79;hb=8d5a42062f8b88eaea91434e53973ce9f55589d9;hpb=67d317029778e6f068badf7b8e3eec6482ecb00e diff --git a/include/file.h b/include/file.h index c68d84f..03c5c6f 100644 --- a/include/file.h +++ b/include/file.h @@ -31,18 +31,6 @@ struct boot_file_t; #define FILE_MAX_PATH 1024 -/* Simple error codes */ -#define FILE_ERR_OK 0 -#define FILE_ERR_EOF -1 -#define FILE_ERR_NOTFOUND -2 -#define FILE_CANT_SEEK -3 -#define FILE_IOERR -4 -#define FILE_BAD_PATH -5 -#define FILE_ERR_BAD_TYPE -6 -#define FILE_ERR_BAD_FSYS -7 -#define FILE_ERR_SYMLINK_LOOP -8 -#define FILE_ERR_LENGTH -9 - /* Device kind */ #define FILE_DEVICE_BLOCK 1 #define FILE_DEVICE_NET 2 @@ -73,9 +61,15 @@ struct boot_file_t { // unsigned int part_count; }; -extern int open_file( const struct boot_fspec_t* spec, - struct boot_file_t* file); +extern int +open_file(const struct boot_fspec_t* spec, + struct boot_file_t* file); + +extern int +parse_device_path(char *imagepath, char *defdevice, int defpart, + char *deffile, struct boot_fspec_t *result); +#if 0 extern int validate_fspec( struct boot_fspec_t* spec, char* default_device, @@ -84,7 +78,7 @@ extern char *parse_device_path( char* of_device, char** file_spec, int* partition); - +#endif #endif