diff options
author | NeilBrown <neilb@suse.de> | 2009-02-02 11:09:09 +1100 |
---|---|---|
committer | NeilBrown <neilb@suse.de> | 2009-02-02 11:09:09 +1100 |
commit | 6c40598f598874d1d4c2c4d0da0c2a9b873d768d (patch) | |
tree | 5f05871358e150e7173e84ed6b3c2e42066fbe52 | |
parent | caf8d2317519df27b805919c3878fe3c3acc6923 (diff) | |
parent | b47dff6675026053dc574f305df570d79754484e (diff) | |
download | mdadm-6c40598f598874d1d4c2c4d0da0c2a9b873d768d.tar.gz mdadm-6c40598f598874d1d4c2c4d0da0c2a9b873d768d.tar.xz mdadm-6c40598f598874d1d4c2c4d0da0c2a9b873d768d.zip |
Merge branch 'master' into devel-3.0
-rw-r--r-- | Detail.c | 4 | ||||
-rw-r--r-- | Makefile | 3 | ||||
-rw-r--r-- | ReadMe.c | 3 | ||||
-rw-r--r-- | bitmap.c | 2 | ||||
-rw-r--r-- | md5.h | 2 | ||||
-rw-r--r-- | mdadm.h | 7 |
6 files changed, 11 insertions, 10 deletions
@@ -261,8 +261,8 @@ int Detail(char *dev, int brief, int export, int test, char *homehost) unsigned long long dsize = get_component_size(fd); if (dsize > 0) printf(" Used Dev Size : %llu%s\n", - dsize, - human_size((long long)dsize<<10)); + dsize/2, + human_size((long long)dsize<<9)); else printf(" Used Dev Size : unknown\n"); } else @@ -122,9 +122,6 @@ mdadm.static : $(OBJS) $(STATICOBJS) mdadm.tcc : $(SRCS) mdadm.h $(TCC) -o mdadm.tcc $(SRCS) -dadm.uclibc : $(SRCS) mdadm.h - $(UCLIBC_GCC) -DUCLIBC -DHAVE_STDINT_H -o mdadm.uclibc $(SRCS) $(STATICSRC) - mdadm.klibc : $(SRCS) mdadm.h rm -f $(OBJS) gcc -nostdinc -iwithprefix include -I$(KLIBC)/klibc/include -I$(KLIBC)/linux/include -I$(KLIBC)/klibc/arch/i386/include -I$(KLIBC)/klibc/include/bits32 $(CFLAGS) $(SRCS) @@ -520,7 +520,8 @@ char Help_grow[] = " --layout= -p : For a FAULTY array, set/change the error mode.\n" " --size= -z : Change the active size of devices in an array.\n" " : This is useful if all devices have been replaced\n" -" : with larger devices.\n" +" : with larger devices. Value is in Kilobytes, or\n" +" : the special word 'max' meaning 'as large as possible'.\n" " --raid-devices= -n : Change the number of active devices in an array.\n" " --bitmap= -b : Add or remove a write-intent bitmap.\n" " --backup-file= file : A file on a differt device to store data for a\n" @@ -163,7 +163,7 @@ bitmap_info_t *bitmap_fd_read(int fd, int brief) sb_le_to_cpu(&info->sb); /* convert superblock to CPU byte ordering */ - if (brief || info->sb.sync_size == 0) + if (brief || info->sb.sync_size == 0 || info->sb.chunksize == 0) goto out; /* read the rest of the file counting total bits and dirty bits -- @@ -27,7 +27,7 @@ #if HAVE_INTTYPES_H # include <inttypes.h> #endif -#if HAVE_STDINT_H || _LIBC +#if HAVE_STDINT_H || _LIBC || defined __UCLIBC__ # include <stdint.h> #endif @@ -662,8 +662,11 @@ struct stat64; #define HAVE_NFTW we assume #define HAVE_FTW -#ifdef UCLIBC +#ifdef __UCLIBC__ # include <features.h> +# ifndef __UCLIBC_HAS_LFS__ +# define lseek64 lseek +# endif # ifndef __UCLIBC_HAS_FTW__ # undef HAVE_FTW # undef HAVE_NFTW @@ -888,7 +891,7 @@ static inline int xasprintf(char **strp, const char *fmt, ...) { va_list ap; int ret; va_start(ap, fmt); - ret = asprintf(strp, fmt, ap); + ret = vasprintf(strp, fmt, ap); va_end(ap); assert(ret >= 0); return ret; |