diff options
author | Ralf Corsepius <ralf.corsepius@rtems.org> | 2008-09-04 08:33:06 +0000 |
---|---|---|
committer | Ralf Corsepius <ralf.corsepius@rtems.org> | 2008-09-04 08:33:06 +0000 |
commit | 0a896eb9ce19799b55fec0c8add34846a9d0bd9a (patch) | |
tree | 02b015fa4b393bf70efc03d0d9a7c74f2a1d41ca | |
parent | Change "done" to bool. (diff) | |
download | rtems-0a896eb9ce19799b55fec0c8add34846a9d0bd9a.tar.bz2 |
Use "bool" instead of "rtems_boolean|boolean".
-rw-r--r-- | cpukit/libfs/src/dosfs/dosfs.h | 8 | ||||
-rw-r--r-- | cpukit/libfs/src/dosfs/fat.c | 14 | ||||
-rw-r--r-- | cpukit/libfs/src/dosfs/fat.h | 14 | ||||
-rw-r--r-- | cpukit/libfs/src/dosfs/msdos.h | 10 | ||||
-rw-r--r-- | cpukit/libfs/src/dosfs/msdos_dir.c | 2 | ||||
-rw-r--r-- | cpukit/libfs/src/dosfs/msdos_eval.c | 4 | ||||
-rw-r--r-- | cpukit/libfs/src/dosfs/msdos_format.c | 12 | ||||
-rw-r--r-- | cpukit/libfs/src/dosfs/msdos_misc.c | 8 | ||||
-rw-r--r-- | cpukit/libfs/src/imfs/imfs_initsupp.c | 4 | ||||
-rw-r--r-- | cpukit/libfs/src/imfs/ioman.c | 2 |
10 files changed, 39 insertions, 39 deletions
diff --git a/cpukit/libfs/src/dosfs/dosfs.h b/cpukit/libfs/src/dosfs/dosfs.h index 72353a2b7f..3292b02dc4 100644 --- a/cpukit/libfs/src/dosfs/dosfs.h +++ b/cpukit/libfs/src/dosfs/dosfs.h @@ -18,13 +18,13 @@ #ifndef _RTEMS_DOSFS_H #define _RTEMS_DOSFS_H +#include <rtems.h> +#include <rtems/libio.h> + #ifdef __cplusplus extern "C" { #endif -#include <rtems.h> -#include <rtems/libio.h> - extern rtems_filesystem_operations_table msdos_ops; #define MSDOS_FMT_FATANY 0 @@ -44,7 +44,7 @@ typedef struct { uint32_t files_per_root_dir; /* request value: file entries in root */ uint8_t fattype; /* request value: MSDOS_FMT_FAT12/16/32 */ uint8_t media; /* media code. default: 0xF8 */ - boolean quick_format; /* TRUE: do not clear out data sectors */ + bool quick_format; /* true: do not clear out data sectors */ uint32_t cluster_align; /* requested value: cluster alignment */ /* make sector number of first sector */ /* of first cluster divisible by this */ diff --git a/cpukit/libfs/src/dosfs/fat.c b/cpukit/libfs/src/dosfs/fat.c index 4dd61afdd9..d5a3a7907d 100644 --- a/cpukit/libfs/src/dosfs/fat.c +++ b/cpukit/libfs/src/dosfs/fat.c @@ -32,7 +32,7 @@ fat_buf_access(fat_fs_info_t *fs_info, uint32_t blk, int op_type, { rtems_status_code sc = RTEMS_SUCCESSFUL; uint8_t i; - rtems_boolean sec_of_fat; + bool sec_of_fat; if (fs_info->c.state == FAT_CACHE_EMPTY) @@ -110,7 +110,7 @@ fat_buf_release(fat_fs_info_t *fs_info) { rtems_status_code sc = RTEMS_SUCCESSFUL; uint8_t i; - rtems_boolean sec_of_fat; + bool sec_of_fat; if (fs_info->c.state == FAT_CACHE_EMPTY) return RC_OK; @@ -722,7 +722,7 @@ fat_get_unique_ino(rtems_filesystem_mount_table_entry_t *mt_entry) { register fat_fs_info_t *fs_info = mt_entry->fs_info; uint32_t j = 0; - rtems_boolean resrc_unsuff = FALSE; + bool resrc_unsuff = false; while (!resrc_unsuff) { @@ -745,10 +745,10 @@ fat_get_unique_ino(rtems_filesystem_mount_table_entry_t *mt_entry) if (fs_info->uino != NULL) fs_info->index = fs_info->uino_pool_size; else - resrc_unsuff = TRUE; + resrc_unsuff = true; } else - resrc_unsuff = TRUE; + resrc_unsuff = true; } return 0; } @@ -782,9 +782,9 @@ fat_free_unique_ino( * ino - ino to be tested * * RETURNS: - * TRUE if ino is allocated from unique ino pool, FALSE otherwise + * true if ino is allocated from unique ino pool, false otherwise */ -inline rtems_boolean +inline bool fat_ino_is_unique( rtems_filesystem_mount_table_entry_t *mt_entry, uint32_t ino diff --git a/cpukit/libfs/src/dosfs/fat.h b/cpukit/libfs/src/dosfs/fat.h index 244e57f087..2e00ef939a 100644 --- a/cpukit/libfs/src/dosfs/fat.h +++ b/cpukit/libfs/src/dosfs/fat.h @@ -17,10 +17,6 @@ #ifndef __DOSFS_FAT_H__ #define __DOSFS_FAT_H__ -#ifdef __cplusplus -extern "C" { -#endif - #include <string.h> #include <rtems/seterr.h> @@ -29,6 +25,10 @@ extern "C" { #include <errno.h> #include <rtems/bdbuf.h> +#ifdef __cplusplus +extern "C" { +#endif + #ifndef RC_OK #define RC_OK 0 #endif @@ -328,7 +328,7 @@ typedef struct fat_vol_s typedef struct fat_cache_s { uint32_t blk_num; - rtems_boolean modified; + bool modified; uint8_t state; rtems_bdbuf_buffer *buf; } fat_cache_t; @@ -413,7 +413,7 @@ fat_cluster_num_to_sector512_num( static inline void fat_buf_mark_modified(fat_fs_info_t *fs_info) { - fs_info->c.modified = TRUE; + fs_info->c.modified = true; } int @@ -465,7 +465,7 @@ fat_shutdown_drive(rtems_filesystem_mount_table_entry_t *mt_entry); uint32_t fat_get_unique_ino(rtems_filesystem_mount_table_entry_t *mt_entry); -rtems_boolean +bool fat_ino_is_unique(rtems_filesystem_mount_table_entry_t *mt_entry, uint32_t ino); diff --git a/cpukit/libfs/src/dosfs/msdos.h b/cpukit/libfs/src/dosfs/msdos.h index 050b283863..f420201788 100644 --- a/cpukit/libfs/src/dosfs/msdos.h +++ b/cpukit/libfs/src/dosfs/msdos.h @@ -15,16 +15,16 @@ #ifndef __DOSFS_MSDOS_H__ #define __DOSFS_MSDOS_H__ -#ifdef __cplusplus -extern "C" { -#endif - #include <rtems.h> #include <rtems/libio_.h> #include "fat.h" #include "fat_file.h" +#ifdef __cplusplus +extern "C" { +#endif + #define MSDOS_NAME_NOT_FOUND_ERR 0x7D01 /* @@ -382,7 +382,7 @@ int msdos_set_dir_wrt_time_and_date( int msdos_dir_is_empty( rtems_filesystem_mount_table_entry_t *mt_entry, fat_file_fd_t *fat_fd, - rtems_boolean *ret_val + bool *ret_val ); int msdos_find_name_in_fat_file( diff --git a/cpukit/libfs/src/dosfs/msdos_dir.c b/cpukit/libfs/src/dosfs/msdos_dir.c index c2fb72aedd..a0653de9e9 100644 --- a/cpukit/libfs/src/dosfs/msdos_dir.c +++ b/cpukit/libfs/src/dosfs/msdos_dir.c @@ -490,7 +490,7 @@ msdos_dir_rmnod(rtems_filesystem_location_info_t *pathloc) rtems_status_code sc = RTEMS_SUCCESSFUL; msdos_fs_info_t *fs_info = pathloc->mt_entry->fs_info; fat_file_fd_t *fat_fd = pathloc->node_access; - rtems_boolean is_empty = FALSE; + bool is_empty = false; sc = rtems_semaphore_obtain(fs_info->vol_sema, RTEMS_WAIT, MSDOS_VOLUME_SEMAPHORE_TIMEOUT); diff --git a/cpukit/libfs/src/dosfs/msdos_eval.c b/cpukit/libfs/src/dosfs/msdos_eval.c index a1a9b4401a..81cae010ad 100644 --- a/cpukit/libfs/src/dosfs/msdos_eval.c +++ b/cpukit/libfs/src/dosfs/msdos_eval.c @@ -266,7 +266,7 @@ msdos_eval4make( int i = 0; int len; char token[ MSDOS_NAME_MAX + 1 ]; - rtems_boolean done = 0; + bool done = false; sc = rtems_semaphore_obtain(fs_info->vol_sema, RTEMS_WAIT, MSDOS_VOLUME_SEMAPHORE_TIMEOUT); @@ -374,7 +374,7 @@ msdos_eval4make( goto error; } else - done = TRUE; + done = true; } break; diff --git a/cpukit/libfs/src/dosfs/msdos_format.c b/cpukit/libfs/src/dosfs/msdos_format.c index bbd4689dc0..1d012c29f5 100644 --- a/cpukit/libfs/src/dosfs/msdos_format.c +++ b/cpukit/libfs/src/dosfs/msdos_format.c @@ -61,7 +61,7 @@ typedef struct { uint8_t fattype; char OEMName[FAT_BR_OEMNAME_SIZE+1]; char VolLabel[FAT_BR_VOLLAB_SIZE+1]; - boolean VolLabel_present; + bool VolLabel_present; uint32_t vol_id; } msdos_format_param_t; @@ -217,8 +217,8 @@ static int msdos_format_eval_sectors_per_cluster \*=========================================================================*/ { - boolean finished = FALSE; - int ret_val = 0; + bool finished = false; + int ret_val = 0; uint32_t fatdata_cluster_cnt; uint32_t fat_capacity; uint32_t sectors_per_fat; @@ -264,7 +264,7 @@ static int msdos_format_eval_sectors_per_cluster sectors_per_cluster *= 2; } else { - finished = TRUE; + finished = true; } /* * when maximum cluster size is exceeded, we have invalid data, abort... @@ -272,7 +272,7 @@ static int msdos_format_eval_sectors_per_cluster if ((sectors_per_cluster * bytes_per_sector) > MS_BYTES_PER_CLUSTER_LIMIT) { ret_val = EINVAL; - finished = TRUE; + finished = true; } } while (!finished); @@ -583,7 +583,7 @@ static int msdos_format_determine_fmt_params if ((rqdata != NULL) && (rqdata->VolLabel != NULL)) { from = rqdata->VolLabel; - fmt_params->VolLabel_present = TRUE; + fmt_params->VolLabel_present = true; } for (cnt = 0; cnt < (sizeof(fmt_params->VolLabel)-1); diff --git a/cpukit/libfs/src/dosfs/msdos_misc.c b/cpukit/libfs/src/dosfs/msdos_misc.c index 077fb945b9..abf5eedbd4 100644 --- a/cpukit/libfs/src/dosfs/msdos_misc.c +++ b/cpukit/libfs/src/dosfs/msdos_misc.c @@ -689,7 +689,7 @@ int msdos_dir_is_empty( rtems_filesystem_mount_table_entry_t *mt_entry, fat_file_fd_t *fat_fd, - rtems_boolean *ret_val + bool *ret_val ) { ssize_t ret = 0; @@ -697,7 +697,7 @@ msdos_dir_is_empty( uint32_t j = 0, i = 0; /* dir is not empty */ - *ret_val = FALSE; + *ret_val = false; while ((ret = fat_file_read(mt_entry, fat_fd, j * fs_info->fat.vol.bps, fs_info->fat.vol.bps, @@ -725,14 +725,14 @@ msdos_dir_is_empty( if ((*MSDOS_DIR_NAME(fs_info->cl_buf + i)) == MSDOS_THIS_DIR_ENTRY_AND_REST_EMPTY) { - *ret_val = TRUE; + *ret_val = true; return RC_OK; } return RC_OK; } j++; } - *ret_val = TRUE; + *ret_val = true; return RC_OK; } diff --git a/cpukit/libfs/src/imfs/imfs_initsupp.c b/cpukit/libfs/src/imfs/imfs_initsupp.c index 05f7ab768a..62d6b11c7a 100644 --- a/cpukit/libfs/src/imfs/imfs_initsupp.c +++ b/cpukit/libfs/src/imfs/imfs_initsupp.c @@ -41,7 +41,7 @@ static int IMFS_determine_bytes_per_block( int default_bytes_per_block ) { - rtems_boolean is_valid = FALSE; + bool is_valid = false; int bit_mask; /* * check, whether requested bytes per block is valid @@ -50,7 +50,7 @@ static int IMFS_determine_bytes_per_block( !is_valid && (bit_mask <= 512); bit_mask <<= 1) { if (bit_mask == requested_bytes_per_block) { - is_valid = TRUE; + is_valid = true; } } *dest_bytes_per_block = ((is_valid) diff --git a/cpukit/libfs/src/imfs/ioman.c b/cpukit/libfs/src/imfs/ioman.c index 1ab3b38c99..ef5d4cf614 100644 --- a/cpukit/libfs/src/imfs/ioman.c +++ b/cpukit/libfs/src/imfs/ioman.c @@ -80,7 +80,7 @@ rtems_status_code rtems_io_lookup_name( int result; rtems_filesystem_node_types_t node_type; - result = rtems_filesystem_evaluate_path( name, 0x00, &loc, TRUE ); + result = rtems_filesystem_evaluate_path( name, 0x00, &loc, true ); the_jnode = loc.node_access; if ( !loc.ops->node_type_h ) { |