Whamcloud - gitweb
Update files for 1.32 release.
[tools/e2fsprogs.git] / lib / ext2fs / ChangeLog
1 2002-11-09  Theodore Ts'o  <tytso@mit.edu>
2
3         * Release of E2fsprogs 1.32
4
5 2002-11-09  Theodore Ts'o  <tytso@mit.edu>
6
7         * unix_io.c (find_cached_block, reuse_cache, unix_read_blk, 
8                 unix_write_blk): Optimize routines so that we don't end up
9                 searching the cache twice when a block isn't in the
10                 cache.  If reads are larger than READ_DIRECT_SIZE, don't
11                 let them go through the cache.
12
13         * unix_io.c (find_cached_block): Fixed bug which caused some clean
14                 blocks to be erroneously marked as dirty, so they would
15                 get written back to the disk before they are evicted from
16                 the cache.  Harmless, but it slows down e2fsck
17                 significantly.
18
19 2002-11-08  Theodore Ts'o  <tytso@mit.edu>
20
21         * Release of E2fsprogs 1.31
22
23 2002-11-08    <tytso@snap.thunk.org>
24
25         * Makefile.in (check): Skip trying to compile test_byteswap
26                 if --disable-byteswaap had been given to configure.
27
28 2002-11-07    <tytso@snap.thunk.org>
29
30         * closefs.c (write_bgdesc, ext2fs_flush): Fix bug in meta_bg
31                 support when the MASTER_SB_ONLY flag is set.  Some of
32                 the descriptor blocks that should have been written out
33                 were getting skipped.
34
35 2002-10-31  Theodore Ts'o  <tytso@mit.edu>
36
37         * Release of E2fsprogs 1.30
38
39 2002-10-31  Theodore Ts'o  <tytso@mit.edu>
40
41         * ext2_fs.h: Add support for a new inode flag, which is to be used
42                 for indicating the top of directory hierarchies for the
43                 Orlov block allocator.
44         
45         * ismounted.c (check_mntent, check_mntent_file): Add better
46                 support for loopback-mounted filesystems.  Check /etc/mtab
47                 if /proc/mounts doesn't turn up any mount flags, since
48                 /etc/mtab has the loopback image filename, instead of
49                 /dev/loop0.  Also, check based on st_dev and st_ino, so
50                 that if a relative pathname or a pathnames using symbolic
51                 links are used, we can detect the the filesystem correctly
52                 in those cases.  (Addresses Sourceforge bug #619119)
53
54         * flushb.c (ext2fs_sync_device): If the BLKFLSBUF ioctl succeeds,
55                 don't try the FDFLUSH ioctl that was required for floppies
56                 with older kernels.  This avoids needless whining from the
57                 MD device driver.  (Addresses Sourceforge bug #545832).
58
59         * openfs.c (ext2fs_open): Fix bug which caused us to pass the
60                 wrong group_block to ext2fs_descriptor_block_loc if we're
61                 using the backup superblock/block group descriptors.
62                 (ext2fs_descriptor_block_loc): If we're using the backup
63                 superblock descriptors, use the backup descriptor block in
64                 the next block group.
65
66 2002-10-30  Theodore Ts'o  <tytso@mit.edu>
67
68         * alloc_tables.c (ext2fs_allocate_group_table): Allocate the inode
69                 table so that it buts up against the bitmap blocks, to
70                 avoid block fragmentation.
71
72         * closefs.c (write_bgdesc), initalize.c (ext2fs_initialize): Fix
73                 bug; only allocate group descriptor blocks up to
74                 s_first_meta_bg.
75
76 2002-10-25  Theodore Ts'o  <tytso@mit.edu>
77
78         * ext2_fs.h: Add a new superblock field, s_mkfs_time, so that we
79                 know when a filesystem was created.  (Sometimes this can
80                 be useful...)
81
82         * initialize.c (ext2fs_initialize): Set the s_mkfs_time field.
83
84 2002-10-20  Theodore Ts'o  <tytso@valinux.com>
85
86         * ext2_fs.h (EXT3_DEFM_JMODE): Add new default mount options for
87                 the journal data mode.
88
89         * closefs.c (ext2fs_flush, write_bgdesc), ext2_fs.h, ext2fs.h,
90         openfs.c (ext2fs_descriptor_block_loc, ext2fs_open), initialize.c
91         (ext2fs_initialize), swapfs.c (ext2fs_swap_super): Add support for
92         the meta_blockgroup filesystem format.
93
94 2002-10-15    <tytso@snap.thunk.org>
95
96         * ext2_fs.h: Add new field in superblock for default mount options.
97
98 2002-10-13  Theodore Ts'o  <tytso@mit.edu>
99
100         * ext2fs.h: Add #include of header files necessary for ext2fs.h to
101                 compile cleanly.
102
103 2002-10-02  Theodore Y. Ts'o  <tytso@mit.edu>
104
105         * rw_bitmaps.c (ext2fs_write_block_bitmap,
106                 ext2fs_read_block_bitmap): Don't set the CHANGED bit just
107                 because the bitmap is getting written to disk.  Make
108                 ext2fs_swap_bitmap be a static function, since it's not
109                 intended to be exported.
110
111         * swapfs.c (ext2fs_swap_super): Byte-swap the hash seed
112
113 2001-09-24  Theodore Tso  <tytso@mit.edu>
114
115         * Release of E2fsprogs 1.29
116
117 2001-08-31  Theodore Tso  <tytso@thunk.org>
118
119         * Release of E2fsprogs 1.28
120
121 2002-08-31  Theodore Ts'o  <tytso@valinux.com>
122
123         * dblist.c (ext2fs_dblist_sort): New function which allows the
124                 caller to pass in a special sort comparison function.
125
126 2002-08-20  Theodore Ts'o  <tytso@mit.edu>
127
128         * valid_blk.c (ext2fs_inode_has_valid_blocks): Fix bug which
129                 failed to accurately characterize non-standard slow
130                 symlinks.  (Which don't appear in practice on real-life
131                 systems, fortunately.)
132
133 2002-08-17  Theodore Ts'o  <tytso@mit.edu>
134
135         * Makefile.in: Remove inode_io.o from the standard object files,
136                 and only build it if debugfs is enabled (it requires
137                 fileio.o, which is only built if --disable-debugfs isn't
138                 specified to configure).
139
140         * dirhash.c (ext2fs_dirhash): Change the MD4 hash in a backwards
141                 incompatible way so that it is no longer
142                 endian-dependent.  Add the TEA hash.  Allow the seed
143                 parameter to be optional.
144
145         * ext2_fs.h: Remove the HALF_MD4_SEED and HALF_MD4_64 hashes.
146                 These features are all now in the HALF_MD4 hash.  Add
147                 definition for EXT2_HASH_TEA.
148
149         * ext2fs.h (ext2fs_dirhash): Change function prototype so it takes
150                 a pointer instead of an array.
151
152 2002-08-16  Theodore Ts'o  <tytso@mit.edu>
153
154         * ext2_err.et.in (EXT2_ET_BAD_EA_BLOCK_NUM): New error code
155
156         * ext2fs.h (ext2fs_inode_data_blocks): New function which returns
157                 the number of data blocks used by an inode exclusive of
158                 the EA block.
159
160         * ext_attr.c (ext2fs_adjust_ea_refcount): New function which
161                 adjusts the reference count in an extended attribute block.
162
163         * valid_blk.c (ext2fs_inode_has_valid_blocks): Add code to
164                 correctly deal with extended attribute blocks in symbolic
165                 links. 
166
167 2002-08-13    <tytso@snap.thunk.org>
168
169         * Makefile.in: Move dupfs.o and test_io.o from the
170                 needed-by-debugfs object list to the needed-by-resizer
171                 object list.  Fixes compile problem if the system is built
172                 with only --disable-debugfs.
173
174 2002-07-29  Theodore Ts'o  <tytso@mit.edu>
175
176         * link.c (ext2fs_link): When adding a new link to a directory,
177                 clear the HTREE bit.
178
179 2002-07-23  Theodore Ts'o  <tytso@mit.edu>
180
181         * dirhash.c (ext2fs_dirhash): Fix bug which caused MD4
182                 calculations for names > 32 characters to be completely
183                 bogus.  Changed MD4 calculation to match what is currently
184                 being used in the CVS gkernel tree.
185
186 2002-07-19  Theodore Ts'o  <tytso@mit.edu>
187
188         * ext2_fs.h: Add s_hash_seed and s_def_hash_version to the
189                 superblock definition.
190
191         * badblocks.c, freefs.c, ext2fs.h: Use the badblocks functions to
192                 create a set of u32_list functions.
193
194         * dirhash.c (halfMD4Transform): Shift the hash by one bit,
195                 since that's required by the directory indexing code.
196
197 2002-07-14  Theodore Ts'o  <tytso@mit.edu>
198
199         * ext2fs.h, read_bb_file.c: Change private to priv_data, to avoid
200                 using a C++ reserved word.
201
202         * unix_io.c (unix_open): Only attempt the setrlimit workaround if
203                 the kernel version is 2.4.10 -- 2.4.17, since otherwise an
204                 old version of glibc (built against 2.2 headers) will
205                 interact badly with the workaround to actually cause more
206                 problems.  I hate it when the glibc folks think they're
207                 being smarter than the kernel....
208
209 2002-06-28  Andreas Dilger <adilger@clusterfs.com>
210
211         * ext2_fs.h: Add superblock field for reserved group descriptors.
212
213 2002-06-28  Theodore Ts'o  <tytso@mit.edu>
214
215         * bitops.h: Add #define's for ext2fs_{l,b}e{32,16}_to_cpu and
216                 ext2fs_cpu_to_{l,b}e{32,16}
217
218 2002-06-27  Theodore Ts'o  <tytso@mit.edu>
219
220         * ismounted.c (check_mntent): In AIX 4.3, MOUNTED isn't defined.
221                 Add appropriate fallbacks in this case.
222
223 2002-06-26  Theodore Ts'o  <tytso@mit.edu>
224
225         * dirhash.c (ext2fs_dirhash): Change function signature to support
226                 a hash seed, and to return the minor hash (for 64-bit hash
227                 support).   Add support for the half MD4, half MD4 with
228                 seed, and half MD4 with seed and 64 bits.
229
230 2002-06-15  Theodore Ts'o  <tytso@mit.edu>
231
232         * ext2_fs.h (EXT2_DIRSYNC_FL): Add new file.
233
234 2002-06-09  Andreas Dilger <adilger@clusterfs.com>
235
236         * ext2_fs.h: Add macros for maximum block/inode counts:
237                 EXT2_INODES_PER_BLOCK, EXT2_MAX_BLOCKS_PER_GROUP,
238                 and EXT2_MAX_INODES_PER_GROUP.
239
240         * openfs.c (ext2fs_open): Check that the number of blocks in a group
241                 is less than 2^16, otherwise we need an INCOMPAT flag (not
242                 in existence yet, if ever) to open such a filesystem.
243
244         * initialize.c (ext2fs_initialize): Limit the number of blocks and
245                 inodes in a group to less than 2^16.
246
247 2002-06-09  Andreas Dilger <adilger@clusterfs.com>
248
249         * ext2_fs.h: Further minor cleanups of the header.  Consolidate
250                 some checks for __KERNEL__ into one place.
251
252 2002-05-22  Andreas Dilger <adilger@clusterfs.com>
253
254         * ext2_fs.h: Remove macros accessing u.ext2_sb field and use
255                 the EXT2_SB() macro instead.  Remove kernel function
256                 prototypes also.  This matches the 2.5 kernel, and
257                 is also cleaner for other reasons.  Whitespace cleanup.
258
259 2002-05-21  Theodore Ts'o  <tytso@mit.edu>
260
261         * ext2_ext_attr.h: Update to V2 version of the Bestbits format.
262
263 2002-05-16  Andreas Dilger <adilger@clusterfs.com>
264
265         * ext2_fs.h: Change limits to support filesystems with 8k blocks.
266
267         * initialize.c (ext2fs_initialize): Remove assumption that
268                 blocksizes are always <= 4k.
269
270 2002-05-11  Theodore Ts'o  <tytso@mit.edu>
271
272         * bmap.c (ext2fs_bmap): Fix bug which caused ext2fs_bmap to fail
273                 silently if inode pointer is NULL (and ext2fs_bmap is
274                 expected to read the inode itself).
275
276 2002-04-27  Theodore Ts'o  <tytso@mit.edu>
277
278         * ismounted.c (check_mntent_file, is_swap_device): Verify that the
279                 file we are checking is a block device file before looking
280                 at st_rdev, since it's not valid for normal files.
281                 (is_swap_device): Move so that it is outside the
282                 HAVE_MNTENT_H, so that it is always built.
283
284 2002-03-11  Theodore Tso  <tytso@mit.edu>
285
286         * dirblock.c (ext2fs_read_dir_block2, ext2fs_write_dir_block): New
287                 functions which take an extra flags argument.  The flag
288                 EXT2_DIRBLOCK_V2_STRUCT will reverse when the name_len
289                 field is byte swampped on big-endian machines, since in
290                 the V2 structure, name_len is a char field which is
291                 doesn't need to be byte swapped --- except if an
292                 old-style kernel had byte-swapped the name_len field
293                 as part of the V1 structure.
294
295         * ext2_err.et.in (EXT2_ET_DIRHASH_UNSUPP): New error code
296
297         * dirhash.c (ext2fs_dirhash): New function which calculates the
298                 hash for a filename in an indexed directory.
299
300 2002-03-08  Theodore Tso  <tytso@mit.edu>
301
302         * Release of E2fsprogs 1.27
303
304 2002-03-07  Theodore Tso  <tytso@mit.edu>
305
306         * ext2fs.h (ext2fs_inode_io_intern): Add missing function prototype.
307
308         * bmap.c, fileio.c, inode_io.c, tst_badblocks.c, 
309                 tst_byteswap.c: Fix gcc -Wall complaints
310
311         * Makefile.in (check): Use LD_LIBRARY_PATH to run test programs.
312                 (From Philipp Thomas <pthomas@suse.de>)
313
314 2002-02-25  Theodore Tso  <tytso@mit.edu>
315
316         * ext2_fs.h: Add structure definitions for the directory indexing
317                 extension.
318
319 2002-02-23  Theodore Tso  <tytso@mit.edu>
320
321         * unix_io.c (unix_open): Fix 2.4 resource limit workaround so that
322                 it doesn't break things on mis32, sparc32, and alpha
323                 platforms.
324
325 2002-02-21  Theodore Tso  <tytso@mit.edu>
326
327         * ismounted.c (is_swap_device): Fix file descriptor/memory leak;
328                 we were missing an fclose().
329
330 2002-02-20  Theodore Tso  <tytso@mit.edu>
331
332         * Makefile.in, inode_io.c, ext2fs.h, ext2_err.et.in: Add new io
333                 abstraction interface which exports an ext2 inode.
334
335         * ext2fs.h, fileio.c (ext2fs_file_flush): Export ext2fs_file_flush
336                 as a public interface.  Change void * to const void * in
337                 ext2fs_file_write's interface.
338
339         * test_io.c (test_close), unix_io.c (unix_close): Remove unneeded
340                 conditional; save a few bytes.
341         
342 2002-02-12  Theodore Tso  <tytso@mit.edu>
343
344         * Makefile.in (tst_badblocks): Add some extra .o files when
345                 linking the debugging program tst_badblocks which are
346                 needed if we aren't compiling with inline functions enable.
347
348         * kernel-list.h (__inline__): On non-gcc and non-Watcom compilers,
349                 define away __inline__ since it may not be supported.
350
351         * kernel-jbd.h (jbd_debug): For systems that don't do STDC, use a
352                 stripped down jbd_debug that doesn't use variadic
353                 arguments.  This will cause warnings under AIX, but things
354                 should still build.
355
356 2002-02-03  Theodore Tso  <tytso@thunk.org>
357
358         * Release of E2fsprogs 1.26
359
360 2002-02-03  Theodore Tso  <tytso@mit.edu>
361
362         * mkdir.c (ext2fs_mkdir): Change to use ext2fs_inode_alloc_stats2
363                 so that the number of directories in use is adjusted
364                 appropriately.
365
366         * alloc_stats.c (ext2fs_inode_alloc_stats2): Add new function
367                 which optionally will modify the number of directories
368                 count.
369
370 2002-01-03  Theodore Tso  <tytso@mit.edu>
371
372         * dir_iterate.c (ext2fs_dir_iterate2, ext2fs_process_dir_block):
373                 Add support for a new flag, DIRENT_FLAG_INCLUDE_REMOVED,
374                 which will return deleted directory entries.
375                 ext2fs_dir_iterate2 takes a new callback function which
376                 is identical with the one used by
377                 ext2fs_dblist_dir_iterate().  If the directory entry is
378                 deleted, the callback function will be called with the
379                 entry paraemter set to DIRENT_DELETED_FILE.
380
381         * Makefile.in, alloc_stats.c (ext2fs_inode_alloc_stats,
382                 ext2fs_block_alloc_stats): New functions which update
383                 block/inode allocation statistics in the bitmaps, block
384                 group descriptors, and superblock.
385
386         * mkjournal.c (mkjournal_proc), mkdir.c (ext2fs_mkdir),
387                 expanddir.c (expand_dir_proc), bb_inode.c
388                 (clear_bad_block_proc, set_bad_block_proc,
389                 ext2fs_update_bb_inode), alloc.c (ext2fs_alloc_block):
390                 Update to use new block/inode allocation statistics.
391
392 2001-12-24  Theodore Tso  <tytso@mit.edu>
393
394         * ismounted.c (is_swap_device): New function used by
395                 ext2fs_check_if_mounted and ext2fs_check_mount_point which
396                 determines whether or not the specified device is a swap
397                 device by using /proc/swaps.  More bulletproofing for
398                 idiotic/careless system administrators!
399
400         * ext2fs.h, openfs.c (ext2fs_open), initialize.c
401                 (ext2fs_initialize), mkdir.c (ext2fs_mkdir): Add a new
402                 field to struct_ext2_filsys, umask.  This field is
403                 initialize to 022, and affects ext2fs_mkdir in the obvious
404                 way.  (In the future umask should also affect new file
405                 creation routines, but the fileio functions don't
406                 currently support this yes.)
407
408         * ismounted.c (check_mntent_file): Stat all of the entries in
409                 /etc/mtab and/or /proc/mounts in order to catch dim-witted
410                 system administrators who might have created alias
411                 devices.
412  
413 2001-12-23  Theodore Tso  <tytso@mit.edu>
414
415         * Makefile.in, jfs_user.h: Move linux/jbd.h to
416                 ext2fs/kernel-jbd.h, to avoid using the system header
417                 file version of hbd.h when using diet glibc (since it
418                 forcibly adds /usr/include to the beginning of the
419                 include search path.)
420
421         * kernel-jbd.h, kernel-list.h, jfs_compat.h: Move files from
422                 include/linux directory.
423
424 2001-12-16  Theodore Tso  <tytso@mit.edu>
425
426         * bitops.h (ext2fs_mark_generic_bitmap, ext2fs_unmark_generic_bitmap),
427                 ext_attr.c (ext2fs_read_ext_attr, ext2fs_write_ext_attr),
428                 fileio.c (ext2fs_file_write): Fix gcc -Wall nits
429
430         * Makefile.in, jfs_user.h: linux/jfs.h has been renamed to
431                 linux/jbd.h
432
433 2001-12-03  Theodore Tso  <tytso@mit.edu>
434
435         * unix_io.c (unix_open): Make sure the ulimit workaround works
436                 regardless of the version of glibc which is used to
437                 compild e2fsprogs.
438
439 2001-11-26  Theodore Tso  <tytso@mit.edu>
440
441         * unix_io.c (unix_open): Work around a bug in 2.4.10+ kernels by
442                 trying to unset the filesize limit if at all possible,
443                 if a block device is getting opened.  (The filesize limit
444                 shouldn't be applied against writes to a block device, but
445                 starting in 2.4.10, the kernel is doing this.)
446         
447 2001-11-05  Theodore Tso  <tytso@mit.edu>
448
449         * mkjournal.c (ext2fs_add_journal_inode): When creating a .journal
450                 file on adding a journal to an already-mounted filesystem,
451                 try to clear the ext2 file attributes on an already
452                 existing .journal file so that we don't fail if on a
453                 partially added journal to the filesystem.
454
455         * ext2_fs.h: Define a new ext2 file attribute, EXT2_NOTAIL_FL,
456                 which signals that a particular inode should not have the
457                 last bits of data (the "tail") be merged with another
458                 file.  This is necessary to keep LILO happy.
459
460 2001-09-20  Theodore Tso  <tytso@thunk.org>
461
462         * Release of E2fsprogs 1.25
463
464 2001-09-16  Theodore Tso  <tytso@mit.edu>
465
466         * ext2_ext_attr.h: Remove unneeded #include of <linux/config.h>
467                 which was breaking the build on the Hurd.  (Addresses
468                 Debian bug #112414).
469
470 2001-09-13  Theodore Ts'o  <tytso@mit.edu>
471
472         * ismounted.c (check_mntent_file): We now validate the entry in
473                 /etc/mtab to make sure the filesystem is really mounted,
474                 since some broken distributions (read: Slackware) have
475                 buggy boot scripts that don't initialize /etc/mtab before
476                 checking non-root filesystems.  (Slackware also doesn't
477                 check the root filesystem separately, and reboot if the
478                 root filesystem had changes applied to it, which is
479                 dangerous and broken.)   
480
481 2001-09-02  Theodore Tso  <tytso@thunk.org>
482
483         * Release of E2fsprogs 1.24a
484
485 2001-08-30  Theodore Tso  <tytso@thunk.org>
486
487         * Release of E2fsprogs 1.24
488
489 2001-08-30  Theodore Tso  <tytso@valinux.com>
490
491         * getsize.c (ext2fs_get_device_size): Back out BLKGETSIZE64
492                 changes, since the ioctl number has been reused by another
493                 unofficial patch.
494
495 2001-08-15  Theodore Tso  <tytso@valinux.com>
496
497         * Release of E2fsprogs 1.23
498
499 2001-08-05  Theodore Tso  <tytso@valinux.com>
500
501         * alloc.c (ext2fs_new_inode, ext2fs_new_block): Use the fast
502                 version of the bitmap test routines to speed up these
503                 routines.  (At some point I may want to make these
504                 routines use the find_first_bit functions, but that will
505                 add a lot of complexity since it means that these
506                 functions will have to break the bitmap abstraction
507                 boundary.  It's not clear it's worth it.)
508
509         * mkjournal.c (mkjournal_proc): Remember the last block allocated
510                 to speed up ext2fs_new_block().
511
512 2001-07-29  Theodore Tso  <tytso@valinux.com>
513
514         * finddev.c (scan_dir): Fix memory leak; we weren't calling
515                 closedir() when exiting the function in all cases.
516
517 2001-07-27  Theodore Tso  <tytso@valinux.com>
518
519         * mkjournal.c (ext2fs_create_journal_superblock): Set the first
520                 block usable in the journal for external journals to be 2
521                 or 3, depending on the blocksize, so that the existing
522                 kernel code does the right thing.
523
524         * getsize.c (ext2fs_get_device_size): Add support for the
525                 BLKGETSIZE64 ioctl.  (Ioctl defined by unofficial patches
526                 from Ben LaHaise, but it's likely this interface won't
527                 change.)
528
529         * mkjournal.c (ext2fs_add_journal_device): Use the correct block
530                 when writing the journal superblock, too.  (Oops! Needed
531                 to make 1k filesystems with external journal to work.)
532
533 2001-07-26  Theodore Tso  <tytso@valinux.com>
534
535         * mkjournal.c (ext2fs_add_journal_device): Use the correct block
536                 to find the journal superblock if the blocksize is 1024.
537
538 2001-07-21  Theodore Tso  <tytso@valinux.com>
539
540         * ext2_err.et.in (EXT2_ET_LOAD_EXT_JOURNAL): Add new error code
541
542 2001-07-20  Theodore Tso  <tytso@valinux.com>
543
544         * ext_attr.c (ext2fs_write_ext_attr): When writing the extended
545                 attribute block, set the filesystem changed bit.
546
547         * bitops.h (ext2fs_find_first_bit_set, ext2fs_find_next_bit_set):
548                 Comment out these functions since we're not using them.
549
550 2001-07-10  Theodore Tso  <tytso@valinux.com>
551
552         * closefs.c (write_primary_superblock): After writing changes to
553                 the primary superblock, update the original superblock
554                 copy so we don't have to re-write those changes in the
555                 future.
556                 (ext2fs_flush): Clear the superblock dirty flag after
557                 we've flushed out changes to disk.
558
559 2001-07-07  Theodore Tso  <tytso@valinux.com>
560
561         * bitops.h (ext2fs_find_first_bit_set): Use %esi instead of %ebx
562                 to avoid register conflicts when compiling in PIC mode.
563
564 2001-07-04  Theodore Tso  <tytso@valinux.com>
565
566         * bitops.h (ext2fs_find_first_bit_set, ext2fs_find_next_bit_set):
567                 Add new functions (C and in i386 assembler) which quickly
568                 find bits set in a bitmask.
569
570 2001-06-23  Theodore Tso  <tytso@valinux.com>
571
572         * Makefile.in, ext_attr.c, ext2_attr.c, ext2fs.h: Add new files
573                 ext2_ext_attr.h and ext_attr.c for extended attributes
574                 support.
575
576         * Release of E2fsprogs 1.22
577
578 2001-06-22  Theodore Tso  <tytso@valinux.com>
579
580         * mkjournal.c (ext2fs_add_journal_inode): Move close of file
581                 descriptor so that adding a journal to a mounted
582                 filesystem doesn't die.  (Fixes a bug accidentally
583                 introduced in e2fsprogs 1.21.)
584
585         * mkjournal.c (ext2fs_add_journal_inode): Only use fchflags if
586                 HAVE_CHFLAGS and UF_NODUMP are defined, since the Hurd has
587                 fchflags without defining UF_NODUMP.  (Addresses Debian
588                 bug #101361)
589
590         * flushb.c: Use platform independent method of defining the
591                 BLKFLSBUF and FDFLUSH ioctl's.  Also include sys/mount.h
592                 since on newer glibc's BLKFLSBUF is defined there.
593
594         * bitops.h: The C language versions of ext2fs_swab16/32 need to be
595                 included if EXT2FS_ENABLE_SWAPFS is defined, since we need
596                 to support byte swapping even if we don't support the
597                 conversion functions.  (Fixes Debian bug #101686).
598
599         * dirblock.c (ext2fs_read_dir_block): Remove use of dir_entry_2
600                 since the byte-swapping code all assumes the
601                 ext2_dir_entry structure.  (It's a question of whether or
602                 not name_len should be byte-swapped or not, and whether
603                 it's a 16 bit or 8 bit field.)
604
605 2001-06-15  Theodore Tso  <tytso@valinux.com>
606
607         * Release of E2fsprogs 1.21
608
609 2001-06-15  Theodore Tso  <tytso@valinux.com>
610
611         * Makefile.in: Fix bug in installation of ext2_types.h.  It is a
612                 file which is generated and is therefore found in the
613                 build directory, not source directory.
614
615         * ismounted.c (check_mntent_file): Use a test file in / to check
616                 to see if the root filesystem is mounted read-only.  This
617                 protects against the case where /etc might not be on /, as
618                 well as the case where /etc/mtab doesn't exist.  (Both are
619                 should-never happen scenarios, but you never know...)
620
621 2001-06-14  Theodore Tso  <tytso@valinux.com>
622
623         * ismounted.c (ext2fs_check_if_mounted): Fix grammer in comment.
624                 Remove unneeded #pragma argsused, since the arguments are
625                 always used.
626
627 2001-06-13  Theodore Tso  <tytso@valinux.com>
628
629         * ext2_types.h.in: If linux/types.h has been defined, then don't
630                 try to redefine the typedefs.
631
632         * Makefile.in (HFILES): Add ext2_types.h to the list of files
633                 which should be installed.
634
635         * ismounted.c (check_mntent_file): Work around GNU hurd brain
636                 damage.  Addresses Debian bug #100304.
637
638         * Makefile.in: Limit some .o files from being included into the
639                 library if --disable-debugfs, --disable-swapfs,
640                 --disable-imager, or --disable-resizer are used.
641
642 2001-06-12  Theodore Tso  <tytso@valinux.com>
643
644         * inode.c, tst_iscan.c: Stop using the compatibility badblocks
645                 function, and use the ext2fs_badblocks_* functions
646                 instead.
647
648 2001-06-11  Theodore Tso  <tytso@valinux.com>
649
650         * Makefile.in, gen_bitmap.c, bitops.h: Move inline functions
651                 ext2fs_mark_generic_bitmap and
652                 ext2fs_unmark_generic_bitmap to gen_bitmap.c as normal
653                 functions.  (This saves space and doesn't significantly
654                 change the speed of e2fsck on a P-III.)
655
656         * ext2fs.h, bitops.h, block.c, bmap.c, closefs.c, dirblock.c,
657                 inode.c, native.c, openfs.c, rw_bitmaps.c, swapfs.c: Only
658                 include the byte-swapping logic if ENABLE_SWAPFS is turned
659                 on or if we're on a big-endian machine.
660         
661         * initialize.c (ext2fs_initialize):Use WORDS_BIGENDIAN directly to
662                 set EXT2_FLAG_SWAP_BYTES, instead of using
663                 ext2fs_native_flag.
664         
665         * native.c (ext2fs_native_flag): Use WORDS_BIGENDIAN provided by
666                 autoconf to determine whether or not return
667                 EXT2_FLAG_SWAP_BYTES.
668
669 2001-06-10  Theodore Tso  <tytso@valinux.com>
670
671         * Makefile.in: Remove the dependence on the libe2p library.
672
673         * mkjournal.c (ext2fs_add_journal_inode): Replace use of fsetflags
674                 with direct usage of the ioctl/fchflags so that we don't
675                 have to depend on the libe2p library.
676
677 2001-06-08  Theodore Tso  <tytso@valinux.com>
678
679         * ext2_types.h.in: Use unsigned ints in favor of unsigned longs
680                 when trying to find a 32-bit wide type.
681
682         * icount.c (insert_icount_el): Fix the code used to estimate the
683                 size of the new icount array to be more intelligent, to
684                 avoid reallocating the array too many times.  Thanks to
685                 Enrique Perez-Terron for pointing this out.
686
687 2001-06-02  Theodore Tso  <tytso@valinux.com>
688
689         * valid_blk.c (ext2fs_inode_has_valid_blocks): Only check i_blocks
690                 for a symlink to determine whether it is a fast symlink.
691
692 2001-06-01  Theodore Tso  <tytso@valinux.com>
693
694         * Makefile.in, dosio.c, ext2_fs.h, ext2_types.h.in, ext2fs.h:
695                 Move include/asm/types.h.in to lib/ext2fs/ext2_types.h.in.
696
697 2001-05-25  Theodore Tso  <tytso@valinux.com>
698
699         * Release of E2fsprogs 1.20
700
701 2001-05-25  Theodore Tso  <tytso@valinux.com>
702
703         * ismounted.c: More cleanups for ismounted.c, some from Andreas,
704                 some to clean up Andreas's patches.  Use strncpy instead
705                 of strcpy to save the root's mountpoint.  Clean up #ifdef
706                 structure.  Remove uneeded variable in testing/debug driver.
707
708 2001-05-24  Andreas Dilger  <adilger@turbolinux.com>
709
710         * ismounted.c: Add check for root device which doesn't depend on
711                 /etc/fstab or /proc/mounts to be correct.  Don't call
712                 endmntent() before we are done with mnt struct.
713
714 2001-05-23  Theodore Tso  <tytso@valinux.com>
715
716         * ext2_err.et.in (EXT2_ET_JOURNAL_UNSUPP_VERSION): Added new error
717                 code.
718
719 2001-05-21  Theodore Tso  <tytso@valinux.com>
720
721         * ext2_fs.h: Change assignment of EXT2_FEATURE_COMPAT_DIR_INDEX to
722                 make room for pre-existing usage of
723                 EXT2_FEATURE_COMPAT_EXT_ATTR.  Add flag EXT2_INDEX_FL with
724                 the same codepoint as EXT2_BTREE_FL.
725
726 2001-05-20  Theodore Tso  <tytso@valinux.com>
727
728         * ext2fs.h: #include <> instead of "" for ext2fs and et header
729                 files, since they will be installed in /usr/include
730
731 2001-05-14  Theodore Tso  <tytso@valinux.com>
732
733         * alloc.c, alloc_tables.c, badblocks.c, bb_compat.c, bb_inode.c,
734                 bitmaps.c, bitops.c, block.c, bmap.c, bmove.c, brel_ma.c,
735                 check_desc.c, closefs.c, cmp_bitmaps.c, dblist.c,
736                 dblist_dir.c, dir_iterate.c, dirblock.c, dupfs.c,
737                 expanddir.c, ext2_fs.h, fileio.c, finddev.c, flushb.c,
738                 freefs.c, get_pathname.c, getsize.c, icount.c, imager.c,
739                 initialize.c, inline.c, inode.c, irel_ma.c, ismounted.c,
740                 link.c, lookup.c, mkdir.c, mkjournal.c, namei.c, native.c,
741                 newdir.c, nt_io.c, openfs.c, read_bb.c, read_bb_file.c,
742                 rs_bitmap.c, rw_bitmaps.c, swapfs.c, test_io.c,
743                 tst_badblocks.c, tst_byteswap.c, tst_getsize.c,
744                 tst_iscan.c, unix_io.c, unlink.c, valid_blk.c, version.c,
745                 write_bb_file.c, ext2_fs.h: Moved file from include/linux.
746                 Adjust all files in this directroy to include this file.
747
748         * mkjournal.c (ext2fs_create_journal_superblock): Remove redundant
749                 code.
750
751 2001-05-05  Theodore Tso  <tytso@valinux.com>
752
753         * fileio.c (ext2fs_file_read): Factored out common code and
754                 cleaned up function.  Fixed a bug where if there was an
755                 error reading from the disk, the number of bytes read
756                 wasn't reliably set.  (Fixes Debian bug #79163)
757                 (ext2fs_file_write): Factored out common code and made
758                 function more efficient; if writing a full block, don't
759                 bother to do a read-modify-write cycle.
760
761 2001-05-04  Theodore Tso  <tytso@valinux.com>
762
763         * dirblock.c (ext2fs_read_dir_block): Check for an directory
764                 record length which isn't a multiple four, and treat that
765                 as an invalid.  Scan the directory and return an error
766                 (EXT2_ET_DIR_CORRUPTED) if the directory records are
767                 corrupted.
768                 (ext2fs_write_dir_block): If while byte-swapping the
769                 directory block, if there's an error, abort and return
770                 EXT2_ET_DIR_CORRUPTED.
771
772 2001-05-02  Theodore Tso  <tytso@valinux.com>
773
774         * ext2fs.h (EXT2_FLAG_IMAGE_FILE): Add new flag, and add
775                 image_header field in the ext2_filsys structure
776
777         * block.c (block_iterate_ind, block_iterate_dind, block_iterate_tind): 
778         * inode.c (ext2fs_read_inode): 
779         * rw_bitmaps.c (read_bitmaps): 
780         * openfs.c (ext2fs_open): Add support for EXT2_FLAG_IMAGE_FILE
781
782         * imager.c (ext2fs_image_bitmap_read): Fix bug in imager to make
783                 sure the full bitmap is saved.
784
785 2001-05-01  Theodore Tso  <tytso@valinux.com>
786
787         * e2image.h (struct ext2_image_hdr): Add space for the device name
788                 in the image header.
789
790         * dir_iterate.c (ext2fs_process_dir_block): Add a double-check to
791                 make sure the rec_len is a multiple of 4, to prevent
792                 bus-errors on architectures which care about mis-aligned
793                 pointer references.
794
795 2001-04-25  Theodore Tso  <tytso@valinux.com>
796
797         * getsize.c (ext2fs_get_device_size): Use an unsigned long to
798                 query the device sizes using the BLKGETSIZE ioctl.
799
800 2001-04-16  Theodore Tso  <tytso@valinux.com>
801
802         * ismounted.c (check_mntent): Check /proc/mounts on Linux systems
803                 before checking /etc/mtab.  The EXT2_MF_READONLY flag is
804                 now set from the /etc/mtab options field for all
805                 filesystems, not just the root filesystem.  Add debugging
806                 code to make it easier to test ext2fs_check_if_mounted().
807
808         * mkjournal.c (ext2fs_create_journal_superblock): Add safety
809                 check; return an error if there's an attempt to create a
810                 journal less than 1024 filesystem blocks.
811
812         * ext2_err.et.in, mkjournal.c: Change EXT2_JOURNAL_NOT_BLOCK and
813                 EXT2_NO_JOURNAL_SB to be EXT2_ET_*.
814
815 2001-02-20  Theodore Tso  <tytso@valinux.com>
816
817         * bitops.h (ext2fs_swab16, ext2fs_swab32): Add i386 assembly
818                 inline functions.
819
820         * tst_byteswap.c: New function to test the byteswap functions.
821                 Add to regression test suite.
822
823 2001-02-08  Theodore Tso  <tytso@valinux.com>
824
825         * e2image.h (struct ext2_image_hdr): Fix type for fs_hostname
826
827 2001-02-07  Theodore Tso  <tytso@valinux.com>
828
829         * mkjournal.c (ext2fs_create_journal_superblock): Fix the setting
830                 of s_first for external devices to always be 1, since
831                 jsb->s_first is always relative to the start of the
832                 journal superblock.  Use htonl(1) when setting s_nr_users.
833
834 2001-01-17  Theodore Ts'o  <tytso@valinux.com>
835
836         * mkjournal.c (ext2fs_add_journal_device): Fix bug where the
837                 device number of the filesystem (instead of the journal)
838                 was being dropped into s_journal_dev.
839
840 2001-01-15  Theodore Ts'o  <tytso@valinux.com>
841
842         * initialize.c (ext2fs_initialize): Add support for initializing
843                 the ext2 superblock for external journal devices.  This
844                 basically means we don't bother to allocate any block
845                 group descriptors.
846
847         * openfs.c (ext2fs_open): Only open external journal devices if
848                 the new flag EXT2_FLAG_JOURNAL_DEV_OK is passed to
849                 ext2fs_open.  When opening such devices, don't try to read
850                 the block group descriptors, since they're not there.
851
852         * ext2_err.et.in (EXT2_NO_JOURNAL_SB): Add new error code 
853         
854         * mkjournal.c: Export a new function,
855                 ext2fs_create_journal_superblock(), which allocates and
856                 returns a buffer containing a journal superblock.  This is
857                 needed by mke2fs to create an external journal.  Rewrote
858                 ext2fs_add_journal_device() so that it no longer creates
859                 the external journal, but rather adds a filesystem to an
860                 existing external journal.  It handles all of the UUID
861                 manipulation.
862
863         * ext2fs.h: List the EXT3_FEATURE_JOURNAL_DEV as a flag supported
864                 by the library.  Define the EXT2_FLAG_JOURNAL_DEV_OK.
865                 Changed function prototype for ext2fs_add_journal_device().
866                 
867 2001-01-14  Theodore Ts'o  <tytso@valinux.com>
868
869         * closefs.c (ext2fs_flush): Don't write out anything beyond the
870                  primary superblock if EXT2_INCOMPAT_JOURNAL_DEV is
871                  listed.
872
873 2001-01-12  Theodore Ts'o  <tytso@valinux.com>
874
875         * imager.c: Fix gcc -Wall complaints and a series of bugs where
876                 retval wasn't set correctly.  (Thanks to Andreas Dilger
877                 for pointing this out.)
878
879 2001-01-11    <tytso@snap.thunk.org>
880
881         * flushb.c (ext2fs_sync_device): New function which centralizes
882                 all of the places which might try to use the BLKFLSBUF
883                 or FDFLUSH ioctls (and usually failing to define them
884                 since the system header files don't usually do this for
885                 us, and we're trying to avoid usage of kernel include
886                 files now).
887
888 2001-01-10    <tytso@snap.thunk.org>
889
890         * alloc.c, bb_inode.c, bitmaps.c, bitops.h, block.c, bmap.c, 
891                 bmove.c, brel.h, cmp_bitmaps.c, dblist.c, dblist_dir.c, 
892                 dir_iterate.c, expanddir.c, ext2fs.h, ext2fsP.h, fileio.c,
893                 finddev.c, get_pathname.c, icount.c, inode.c, irel.h, 
894                 irel_ma.c, ismounted.c, link.c, lookup.c, mkdir.c, 
895                 mkjournal.c, namei.c, newdir.c, read_bb_file.c, test_io.c,
896                 tst_iscan.c, unix_io.c, unlink.c: Change use of ino_t to
897                 ext2_ino_t, to protect applications that attempt to
898                 compile -D_FILE_OFFSET_BITS=64, since this inexplicably
899                 changes ino_t(!?).  So we use ext2_ino_t  to avoid an
900                 unexpected ABI change.
901
902 2001-01-05    <tytso@snap.thunk.org>
903
904         * dirblock.c (ext2fs_read_dir_block): Fix a potential case where
905                 we may overrun allocated memory in case of a corrupted
906                 filesystem (or an e2fsck test case :-) when byte-swapping
907                 the directory block.
908
909         * ext2fs.h: Indent the #warning to fix gcc -Wall complaint.
910
911         * mkjournal.c (ext2fs_add_journal_device): Fix various gcc -Wall
912                 complaints including a missing return 0 at the end of
913                 ext2fs_add_journal_device.
914
915 2001-01-03    <tytso@snap.thunk.org>
916
917         * Makefile.in: Link in libe2p when creating libext2fs as a shared
918                 library, since mkjournal.c now references fsetflags().
919
920         * mkjournal.c (ext2fs_add_journal_inode): Folded in Andreas
921                 Dilger's changes (with fixups) to allow on-line creation
922                 of a journal file.
923
924         * ext2fs.h, closefs.c (ext2fs_flush): Add new flag,
925                 EXT2_FLAG_SUPER_ONLY, which the close routines to only
926                 update the superblock, and not the group descriptors.
927
928 2000-12-30  Andreas Dilger  <adilger@turbolinux.com>
929
930         * ismounted.c: add ext2fs_check_mount_point() function, which will
931                 optionally return the mount point of a device if mounted
932
933 2000-12-14  Andreas Dilger  <adilger@turbolinux.com>
934
935         * mkjournal.c: rename ext2fs_add_journal_fs() to the more descriptive
936                 ext2fs_add_journal_inode()
937
938 2001-01-01    <tytso@snap.thunk.org>
939
940         * ext2fs.h: Remove definition of ext2fs_sb.  Note: this may break
941                 source (but not binary) compatibility of some users of the
942                 ext2 library.  They should just simply do a global search
943                 and replace of struct ext2fs_sb with struct
944                 ext2_super_block, and use their own private copy of
945                 ext2_fs.h if they aren't already.
946
947         * closefs.c, initialize.c, link.c, newdir.c, openfs.c, swapfs.c:
948                 Replace use of ext2fs_sb with ext2_super_block.
949
950 2000-12-31    <tytso@snap.thunk.org>
951
952         * ext2fs.h: Cleaned up header file by removing definitions of
953                 feature flags that might not have been defined in older
954                 ext2 header files.  Now that we're using our own
955                 include/linux/ext2fs.h header file, this can never happen.
956
957         * jfs_dat.h: Removed old header file which is no longer needed.
958
959 2000-12-13  Theodore Ts'o  <tytso@valinux.com>
960
961         * closefs.c (ext2fs_update_dynamic_rev): New function suggested
962                 by Andreas Dilger to update the filesystem revision to
963                 EXT2_DYNAMIC_REV.
964
965         * swapfs.c (ext2fs_swap_super): Add byte swapping for the journal
966                 fields.
967
968 2000-12-09    <tytso@snap.thunk.org>
969
970         * ext2fs.h, mkjournal.c (ext2fs_add_journal_inode,
971                 ext2fs_add_journal_device): Add a new argument to the APIs
972                 of these function, which is a flags word.  This is used to
973                 allow the creation of a V1 superblock for those folks who
974                 are using ext3 0.3b in production.  Note, the user-land
975                 interface for getting at this flag won't be documented, as
976                 the V1 superblock is deprecated.
977
978         * mkjournal.c (init_journal_superblock): Sync Stephen's changes
979                 which creates a V2 superblock instead of a V1 superblock.
980
981 2000-11-21    <tytso@snap.thunk.org>
982
983         * test_io.c (test_write_blk, test_write_byte): Fix typos pointed
984                 out by Andreas Dilger.
985
986 2000-11-05    <tytso@snap.thunk.org>
987
988         * imager.c (ext2fs_image_{inode,super,bitmap}_{read,write},
989                 ext2_fs.h, Makefile.in: New file that has routines that
990                 save ext2fs metadata to a file.
991
992         * ext2_err.et.in (EXT2_ET_MAGIC_E2IMAGE): New error code assigned.
993
994         * e2image.h: New file which defines the file format for the ext2
995                 image file.  (Saved copy of ext2 metadata to a file as a
996                 saving throw against worst-case damage.)
997
998 2000-11-01    <tytso@snap.thunk.org>
999
1000         * inode.c (ext2fs_flush_icache): Add new function
1001                 ext2fs_flush_icache() which flushes the internal inode
1002                 cache.  Applications which modify the inode table blocks
1003                 directly must call this function.
1004
1005 2000-10-26    <tytso@snap.thunk.org>
1006
1007         * mkjournal.c: Add #include of netinet/in.h, since Solaris
1008                 requires it for ntohl().
1009
1010         * ext2_io.h (io_channel_write_byte): Add new interface to allow
1011                 callers to write specific byte ranges.  This is an
1012                 optional interface, which not all IO channels may
1013                 implement.
1014
1015         * unix_io.c (unix_write_byte):
1016         * test_io.c (test_write_byte): Add implementation of the
1017                 write_byte function.
1018
1019         * closefs.c (write_primary_superblock, ext2fs_flush): Add a new
1020                 function which writes the primary superblock.  If the IO
1021                 channel supports writing raw bytes directly, only fields
1022                 which were modified are written to the disk.  This makes
1023                 it safe(r) to use utilities like tune2fs on a mounted
1024                 filesystem. 
1025
1026         * freefs.c (ext2fs_free): Free the original superblock if it is
1027                 available. 
1028
1029         * openfs.c (ext2fs_open): Store a copy of the original superblock
1030                 when opening it.
1031
1032         * ext2fs.h: Add a field to store the original superblock in the
1033                 ext2 context structure.
1034
1035 2000-10-24    <tytso@snap.thunk.org>
1036
1037         * llseek.c: Add #ifdef's for IA64 (it's a 64-bit platform, so we
1038                 don't need to use llseek).
1039
1040 2000-10-24    <tytso@valinux.com>
1041
1042         * Makefile.in, ext2fs.h, jfs_dat.h, mkjournal.c: Add functions for
1043                 creating an ext3 journal on a filesystem.
1044
1045 2000-08-21    <tytso@valinux.com>
1046
1047         * ext2_err.et.in (EXT2_JOURNAL_NOT_BLOCK): Add new error code.
1048
1049 2000-08-22    <tytso@valinux.com>
1050
1051         * unix_io.c: Make massive changes to support a multiple block
1052                 writethrough cacheing.
1053
1054         * ext2_io.h: Added flags field to the io_channel structure.
1055
1056 2000-08-19    <tytso@valinux.com>
1057
1058         * finddev.c, ext2fs.h, Makefile.in: Add new file, finddev.c, which
1059                 provides the function ext2fs_find_block_device().  This
1060                 function returns the pathname to a block device, given its
1061                 device number.
1062
1063 2000-07-13    <tytso@valinux.com>
1064
1065         * Release of E2fsprogs 1.19
1066
1067 2000-07-07  Theodore Ts'o  <tytso@valinux.com>
1068
1069         * ext2fs.h (EXT2_LIB_FEATURE_INCOMPAT_SUPP): Add
1070                 EXT3_FEATURE_INCOMPAT_RECOVER (aka needs_recovery) to the
1071                 list of filesystem flags supported by the library.
1072
1073 2000-07-04  Theodore Ts'o  <tytso@valinux.com>
1074
1075         * ext2fs.h: Update to include latest journalling additions to the
1076                 superblock.
1077
1078         * dll/jump.funcs: Add new jumptable entries for
1079                 ext2fs_write_bb_FILE, ext2fs_read_bb_FILE2, and
1080                 ext2fs_badblocks_equal.
1081
1082         * tst_badblocks.c: Update test program to test
1083                 ext2fs_read_bb_FILE2 and ext2fs_write_FILE.
1084
1085         * write_bb_file.c (ext2fs_write_bb_FILE): New function which
1086                 writes out bad blocks list to a file.
1087
1088         * read_bb_file.c (ext2fs_read_bb_FILE2): Add new function which
1089                 changes the callback function to take two additional
1090                 arguments; a private blind pointer supplied by the caller,
1091                 and pointer to a char * containing a pointer to the
1092                 invalid string.
1093
1094         * badblocks.c (ext2fs_badblocks_equal): Add new function which
1095                 returns true if two badblocks list are equal.
1096
1097         * Makefile.in: Remove explicit link of -lc in the shared library.
1098                 (It shouldn't be necessary, and is harmful in some cases).
1099
1100 2000-06-10  Theodore Ts'o  <tytso@valinux.com>
1101
1102         * getsize.c (main): Add debugging code under #ifdef DEBUG
1103
1104 2000-05-27  Theodore Ts'o  <tytso@valinux.com>
1105
1106         * mkdir.c (ext2fs_mkdir): Read the parent directory's inode
1107                 earlier, so that if there's an error reading it, we can
1108                 more cleanly back out of the operation.
1109
1110 2000-05-25    <tytso@snap.thunk.org>
1111
1112         * getsize.c (ext2fs_get_device_size): Use open64() instead of
1113                 open() if it exists.  Under linux, manually define the
1114                 ioctl for BLKGETSIZE if it isn't already defined and it's
1115                 safe to do so.
1116
1117         * unix_io.c (unix_open): Use open64() instead of open() if it
1118                 exists. 
1119
1120         * llseek.c: Simplify header includes of unistd.h.  If lseek64 is
1121                 available (and prototypes are defined) use it in
1122                 preference to llseek.
1123
1124         * Makefile: Add hack dependency rule so that parallel makes work
1125                 correctly. 
1126
1127 2000-05-18  Theodore Ts'o  <tytso@valinux.com>
1128
1129         * ext2fs.h: Add appropriate ifdef's to support C++ compilation.
1130
1131 2000-04-03  Theodore Ts'o  <tytso@valinux.com>
1132
1133         * block.c: Readibility tweak in conditionals involving
1134                 ctx->fs->flags.
1135
1136         * ext2fs.h: Use AUTOCONF SIZEOF_* macros if available to determine
1137                 how to define __s64 and __u64.  Turn off "compression is
1138                 experimental" warning if the cpp macro
1139                 I_KNOW_THAT_COMPRESSION_IS_EXPERIMENTAL is defined.
1140
1141 2000-02-11    <tytso@snap.thunk.org>
1142
1143         * ext2fs.h: Define EXT2FS_COMPRESSED_BLKADDR and HOLE_BLKADDR.
1144                 Conditionally include Compression as a supported type if
1145                 ENABLE_COMPRESSION (via --enable-compression) is turned on.
1146
1147         * swapfs.c (ext2fs_swap_super): Swap the compression usage bitmap.
1148
1149 2000-02-08    <tytso@snap.thunk.org>
1150
1151         * bitops.h (ext2fs_mark_generic_bitmap, ext2fs_unmark_generic_bitmap,
1152                 ext2fs_mark_block_bitmap, ext2fs_unmark_block_bitmap,
1153                 ext2fs_mark_inode_bitmap, ext2fs_unmark_inode_bitmap):
1154                 Change to return the previous state of the bit that is
1155                 being marked or unmarked.  For speed optimization.
1156         
1157 2000-02-02  Theodore Ts'o  <tytso@valinux.com>
1158
1159         * getsize.c, ismounted.c: Remove unneeded include of linux/fs.h
1160
1161         * swapfs.c: Remove #ifdef HAVE_EXT2_INODE_VERSION since it's not
1162                 needed any more; we know it will always be i_generation.
1163                 Add support for swapping the high bits of the uid and gid.
1164
1165 1999-11-19    <tytso@valinux.com>
1166
1167         * mkdir.c (ext2fs_mkdir): Only update the parent's inode link
1168                 counts if the link was successful.  Patch suggested by
1169                 jeremy@goop.org.
1170
1171         * Makefile.in (distclean): Remove TAGS and Makefile.in.old from
1172                 the source directory.
1173
1174 1999-11-10    <tytso@valinux.com>
1175
1176         * Release of E2fsprogs 1.18
1177
1178 1999-11-08    <tytso@valinux.com>
1179
1180         * Makefile.in (tst_badblocks): Add freefs.o to the object list,
1181                 since ext2fs_badblocks_list_free was moved to freefs.c.
1182
1183         * tst_badblocks.c: Use the newer badblocks API names.  Add
1184                 duplicate blocks to the test inputs to test dealing with
1185                 adding blocks which are already in the badblocks list.
1186
1187         * badblocks.c (ext2fs_badblocks_list_add): If appending to the end
1188                 of the list, use a shortcut O(1) operations instead of an
1189                 O(n) operation.  (Idea suggested by David Beattie.)
1190
1191         * freefs.c (ext2fs_free): Use ext2fs_badblocks_list_free() instead
1192                 of badblocks_list_free(), to save a procedure call.
1193
1194 1999-10-26    <tytso@valinux.com>
1195
1196         * Release of E2fsprogs 1.17
1197
1198 1999-10-26    <tytso@valinux.com>
1199
1200         * ext2fs.h: Add kludge to deal with the fact that egcs cpp doesn't
1201                 seem to handle ~0UL the same way as they used to.
1202
1203 1999-10-25    <tytso@valinux.com>
1204
1205         * nt_io.c (_OpenNtName): Open the device using
1206                 FILE_SYNCHRONOUS_IO_NONALERT instead of
1207                 FILE_SYNCHRONOUS_IO_ALERT
1208                 (nt_open): At the end of the device open routine, unlock 
1209                 the drive but do not dismount it.
1210
1211         * initialize.c (CREATOR_OS): Use __GNU__ instead of __gnu__ to
1212                 detect the Hurd OS.
1213
1214 1999-10-22    <tytso@valinux.com>
1215
1216         * Release of E2fsprogs 1.16
1217
1218 1999-10-22    <tytso@valinux.com>
1219
1220         * mkdir.c (ext2fs_mkdir): Pass EXT2_FT_DIR flag to ext2fs_link().
1221
1222         * link.c (ext2fs_link): This call now uses the low three bits of
1223                 the flags parameter to pass the directory filetype
1224                 information; it will set the directory entry FILETYPE
1225                 information if the filesystem supports it.
1226
1227         * newdir.c (ext2fs_new_dir_block): If the FILETYPE superblock
1228                 option is set, then create the '.' and '..' entries with
1229                 the filetype set to EXT2_FT_DIR.
1230
1231 1999-09-24    <tytso@valinux.com>
1232
1233         * nt_io.c: New file which supports I/O under Windows NT.
1234
1235 1999-09-07    <tytso@valinux.com>
1236
1237         * ext2fs.h: Add new fields for journalling and define new
1238                 feature bits used by newer filesystems: IMAGIC_INODES,
1239                 HAS_JOURNAL, RECOVER.
1240
1241         * expanddir.c (ext2fs_expand_dir, expand_dir_proc): Change where
1242                 we update the inode block count and size files so that the
1243                 block count field is updated correctly when we create an
1244                 indirect block.
1245
1246 1999-07-18  Theodore Ts'o  <tytso@valinux.com>
1247
1248         * Release of E2fsprogs 1.15
1249
1250 1999-06-23    <tytso@valinux.com>
1251
1252         * swapfs.c (ext2fs_swap_inode): Add compatibility for Linux 2.3
1253                 kernels that use i_generation instead of i_version.  Patch
1254                 supplied by Jon Bright <sircus@sircus.demon.co.uk>.
1255
1256 1999-06-21    <tytso@valinux.com>
1257
1258         * dir_iterate.c (ext2fs_process_dir_block): Check for corrupted
1259                 directory entry before calling the callback function.
1260                 This should prevent some core dumps of insufficiently
1261                 paranoid callback functions.
1262
1263 1999-05-29    <tytso@rsts-11.mit.edu>
1264
1265         * ext2fs.h: Add feature definition for AFS IMAGIC inodes.
1266
1267         * fileio.c (ext2fs_file_open): Remove obsolete comment stating
1268                 that we don't handle writing yet (we do).  Fixed bug where
1269                 we weren't allocating a big enough buffer for ext2_bmap.
1270
1271 1999-05-03    <tytso@rsts-11.mit.edu>
1272
1273         * openfs.c (ext2fs_open): Check to make sure that the number of
1274                 blocks per group is not zero --- if so, it must be a bad
1275                 superblock!
1276
1277 1999-01-09  Theodore Ts'o  <tytso@rsts-11.mit.edu>
1278
1279         * Release of E2fsprogs 1.14
1280
1281 1999-01-07  Theodore Ts'o  <tytso@rsts-11.mit.edu>
1282
1283         * inode.c (ext2fs_read_inode, ext2fs_write_inode): Check to see if
1284                 the inode number is zero; if it's zero, return
1285                 EXT2_ET_BAD_INODE_NUM.
1286
1287 1998-12-30  Theodore Ts'o  <tytso@rsts-11.mit.edu>
1288
1289         * initialize.c (ext2fs_initialize): Use EXT2_FIRST_INODE instead
1290                 of EXT2_FIRST_INO to ensure compatibility with Linux 1.2
1291                 header files.
1292
1293 Mon Jan  4 02:32:09 1999  Theodore Y. Ts'o  <tytso@mit.edu>
1294
1295         * llseek.c (ext2fs_llseek): Change ext2fs_llseek() in the
1296                 non-Linux case to use EINVAL by default, unless it isn't
1297                 defined, in which case we use EXT2_ET_INVALID_ARGUMENT
1298                 instead.
1299
1300 1998-12-15  Theodore Ts'o  <tytso@rsts-11.mit.edu>
1301
1302         * Release of E2fsprogs 1.13
1303
1304 1998-12-03  Theodore Ts'o  <tytso@rsts-11.mit.edu>
1305
1306         * Makefile.in: Updated dependencies.
1307
1308 1998-09-22  Theodore Ts'o  <tytso@rsts-11.mit.edu>
1309
1310         * initialize.c (ext2fs_initialize): Make sure that we allocate
1311                 enough inodes so that we can make a valid filesystem.
1312
1313 1998-09-02  Theodore Ts'o  <tytso@rsts-11.mit.edu>
1314
1315         * rw_bitmaps.c: Fixed signed/unsigned warnings.
1316
1317         * fileio.c (ext2fs_file_set_size): Remove unneeded extern from the
1318                 function declaration.
1319
1320         * dblist.c (make_dblist): Add safety check in case the dblist
1321                 pointer passed in is null (in which case, assign it to
1322                 fs->dblist).  Fixed some signed/unsigned warnings.
1323
1324         * bmap.c: Make addr_per_block be of type blk_t to avoid
1325                 signed/unsigned warnings.
1326
1327         * namei.c (ext2fs_follow_link): Remove uneeded extern from the
1328                 function declaration.
1329
1330         * get_pathname.c (get_pathname_proc): Use return value from
1331                 ext2fs_get_mem, instead of checking if &gp->name is
1332                 NULL.
1333
1334         * dir_iterate.c (ext2fs_process_dir_block): 
1335         * dblist_dir.c (ext2fs_dblist_dir_iterate): Remove uneeded extern
1336                 from the function declaration.
1337
1338         * block.c (ext2fs_block_iterate2): If the read_inode call fails,
1339                 return the error directly instead of jumping to the
1340                 cleanup routine, since we don't need to do any cleanup.
1341
1342         * alloc_table.c (ext2fs_allocate_group_table): Make this
1343                 function take a dgrp_t for its group argument.
1344
1345         * ext2fs.h: Make dgrp_t an __u32 type, and make
1346                 fs->desc_group_count be of type dgrp_t.
1347
1348 1998-07-27  Theodore Ts'o  <tytso@rsts-11.mit.edu>
1349
1350         * badblocks.c (ext2fs_badblocks_list_add): Use a bigger increment
1351                 than 10 blocks when we need to expand the size of the
1352                 badblocks list.
1353
1354 1998-07-09  Theodore Ts'o  <tytso@rsts-11.mit.edu>
1355
1356         * Release of E2fsprogs 1.12
1357
1358 1998-06-30  Theodore Ts'o  <tytso@rsts-11.mit.edu>
1359
1360         * closefs.c (ext2fs_flush): Update the s_block_group_nr field as
1361                 appropriate for all of the block group copies, so that
1362                 it's clear where the beginning of the filesystem is on the
1363                 disk.  (For when the partition table gets scrod.)
1364
1365         * ext2fs.h: Change the name of the feature from
1366                 EXT2_FEATURE_INCOMPAT_DIRNAME_SIZE to
1367                 EXT2_FEATURE_INCOMPAT_FILESIZE (to match with the kernel).
1368
1369 1998-06-18  Theodore Ts'o  <tytso@rsts-11.mit.edu>
1370
1371         * inode.c (get_next_blockgroup): Fix bug where if
1372                 get_next_blockgroup() is called early because of a missing
1373                 inode table in a block group, the current_inode counter
1374                 wasn't incremented correctly.
1375
1376 1998-06-16  Theodore Ts'o  <tytso@rsts-11.mit.edu>
1377
1378         * read_bb.c (ext2fs_read_bb_inode): Make function more robust
1379                 against a completely trashed bad block inode.
1380
1381 1998-06-10  Theodore Ts'o  <tytso@rsts-11.mit.edu>
1382
1383         * alloc_tables.c (ext2fs_allocate_group_table): Fix bug so that if
1384                 the stride length hits a bad value, we retry the block
1385                 allocation starting at the beginning of the block group.
1386
1387         * ext2fs.h, bb_inode.c, block.c, bmove.c, dir_iterate.c,
1388                 expanddir.c, ext2fsP.h, read_bb.c: Change blkcnt_t to be
1389                 e2_blkcnt_t to avoid collision with LFS API.
1390
1391 1998-05-01  Theodore Ts'o  <tytso@rsts-11.mit.edu>
1392
1393         * initialize.c (ext2fs_initialize): Initialize s_inodes_count in a
1394                 way that avoids overflows on disk sizes greater than 4GB.
1395
1396 1998-04-28  Theodore Ts'o  <tytso@rsts-11.mit.edu>
1397
1398         * ext2fs.h: Define EXT2_QSORT_TYPE appropriately for the
1399                 return type for comparison functions for qsort.
1400
1401         * dblist.c (dir_block_cmp): Use EXT2_QSORT_TYPE in function
1402                 declaration.
1403
1404 1998-04-26  Theodore Ts'o  <tytso@rsts-11.mit.edu>
1405
1406         * ext2fs.h, bitops.h: Add support for the Watcom C compiler to do
1407                 inline functions.
1408
1409         * ext2fs.h, dosio.c: Use asm/types.h instead of linux/types.h to
1410                 evade a potential problem with glibc's header files trying
1411                 to spike out linux/types.h.
1412
1413         * ext2fs.h (ext2fs_resize_mem): Change the function prototype to
1414                 include the old size of the memory, which is needed for
1415                 some braindamaged memory allocation systems that don't
1416                 support realloc().
1417
1418         * badblocks.c (ext2fs_badblocks_list_add):
1419           bb_inode.c (clear_bad_block_proc):
1420           dblist.c (ext2fs_add_dir_block):
1421           icount.c (insert_icount_el):
1422           irel_ma.c (ima_put):
1423           rs_bitmap.c (ext2fs_resize_generic_bitmap): Update functions to
1424                   pass the old size of the memory to be resized to
1425                   ext2fs_resize_mem(). 
1426
1427 1998-03-30  Theodore Ts'o  <tytso@rsts-11.mit.edu>
1428
1429         * Makefile.in: Change to use new installation directory variables
1430                 convention.  Fix uninstall rules to take $(DESTDIR) into
1431                 account.
1432
1433 1998-03-29  Theodore Ts'o  <tytso@rsts-11.mit.edu>
1434
1435         * ext2fs.h: If __STRICT_ANSI__ is defined and we're on a platform
1436                 with 32 bit longs, then we need to manually define __s64
1437                 and __u64, since the current kernel header files don't
1438                 define these if __STRICT_ANSI__ is defined.  This is a
1439                 problem if we are compiling with full GCC warnings, since
1440                 we do need 64 bit support.
1441         
1442         * Makefile.in (OBJS): Remove bmove.o from files to be built,
1443                 since we're not using ext2fs_move_blocks() and there
1444                 is some question as to its usefulness in its current
1445                 form.
1446
1447         * bmap.c (block_bmap): Remove unused function.
1448
1449         * bmove.c (process_block): Fix -Wall warning.
1450
1451 1998-03-23  Theodore Ts'o  <tytso@rsts-11.mit.edu>
1452
1453         * block.c (ext2fs_block_iterate3): Make the ref_offset field
1454                 contain the offset into the inode.i_blocks array when
1455                 ref_block is zero.  Since we haven't done a formal
1456                 release of e2fsprogs since block_iterate2 was first
1457                 introduced, I removed block_iterate2, and renamed
1458                 block_iterate3 to be block_iterate2.
1459
1460         * bb_inode.c, bmove.c, dblist_dir.c, dir_iterate.c,
1461                 expanddir.c, ext2fs.h, ext2fsP.h, read_bb.c: Change
1462                 use of block_iterate and block_iterate2 to
1463                 block_iterate2 with the new prototype for the
1464                 interator function.  (using blkcnt_t forr blockcount)
1465
1466 1998-03-21  Theodore Ts'o  <tytso@rsts-11.mit.edu>
1467
1468         * ext2fs.h: Add new superblock fields (s_algorithm_usage_bitmap, 
1469                 s_prealloc_blocks, s_prealloc_dir_blocks).  Added
1470                 conditional defines of new features COMPAT_DIR_PREALLOC,
1471                 RO_COMPAT_LARGE_FILE RO_COMPAT_BTREE_DIR,
1472                 INCOMPAT_COMPRESSION, INCOMPAT_DIRNAME_SIZE.  Changed
1473                 the library to declare that we support COMPAT_DIR_PREALLOC, 
1474                 INCOMPAT_DIRNAME_SIZE, RO_COMPAT_LARGE_FILE.
1475
1476         * fileio.c: Rename function ext2fs_file_llseek to be
1477                 ext2fs_file_lseek, which is more accurate.
1478
1479         * block.c: Add new function ext2fs_block_iterate3 which calls
1480                 the iterator function with the blockcount argument of
1481                 type blkcnt_t.  This version of the function is
1482                 allowed to handle large files; the other fucntions are
1483                 not.
1484
1485         * ext2fs.h: Add new type blkcnt_t
1486
1487         * ext2_err.et.in: Add error code EXT2_ET_FILE_TOO_BIG
1488
1489         * block.c (ext2fs_block_iterate2): Fix bug where the block count
1490                 field wasn't getting correctly incremented for sparse
1491                 files when the indirect or doubly-indirect block
1492                 specified in the inode was zero.
1493
1494 Sun Mar  8 22:42:47 1998  Theodore Ts'o  <tytso@rsts-11.mit.edu>
1495
1496         * unlink.c (unlink_proc): 
1497         * lookup.c (lookup_proc): 
1498         * link.c (link_proc): 
1499         * get_pathname.c (get_pathname_proc): 
1500         * dir_iterate.c (ext2fs_process_dir_block): Mask off high 8 bits
1501                 from dirent->name_len, so it can be used for other
1502                 purposes.
1503
1504         * ext2fs.h: Add definition of EXT2_FEATURE_INCOMPAT_DIRNAME_SIZE,
1505                 and indicate that we have support for this incompatible
1506                 option.
1507
1508 Mon Feb 23 08:46:33 1998  Theodore Ts'o  <tytso@rsts-11.mit.edu>
1509
1510         * ext2_err.et.in: Added new error code, EXT2_ET_CANCEL_REQUESTED.
1511
1512 Fri Feb 20 23:58:01 1998  Theodore Ts'o  <tytso@rsts-11.mit.edu>
1513
1514         * dblist.c (ext2fs_get_num_dirs): Improve the estimation of the
1515                 number of directories when the block group information is
1516                 unreliable.
1517
1518 1998-02-20  Theodore Y. Ts'o  <tytso@edt.mit.edu>
1519
1520         * inode.c (ext2fs_get_next_inode): Always do the check to see if the
1521                 inode table is missing so that we catch the case where the
1522                 first block group is missing.
1523
1524         * getsize.c, ismounted.c, unix_io.c: #include errno.h since it's
1525                 needed.
1526
1527 Mon Feb 16 16:16:00 1998  Theodore Ts'o  <tytso@rsts-11.mit.edu>
1528
1529         * ext2_io.h, ext2fs.h: Protect against being included multiple times.
1530
1531         * bmove.c: #include ext2fsP.h instead of "ext2fs/ext2fs.h"
1532
1533         * test_io.c (test_flush): Add a debugging printf when the flush
1534                 method is called.
1535
1536         * rw_bitmaps.c (ext2fs_read_bitmaps): If the bitmaps are already
1537                 read in, return right away.
1538
1539 Sun Feb  1 08:20:24 1998  Theodore Ts'o  <tytso@rsts-11.mit.edu>
1540
1541         * bitops.h: Don't try to do i386 inline asm functions if the
1542                 compiler isn't GCC.
1543
1544         * ext2fs.h: If EXT2_FLAT_INCLUDES is defined, #include e2_types.h,
1545                 instead of linux/types.h, and e2_bitops.h instead of
1546                 ext2fs/bitops.h.
1547
1548         * icount.c, version.c: Don't #include <et/com_err.h>, as it isn't
1549                 necessary. 
1550
1551 Sat Jan 17 13:13:31 1998  Theodore Ts'o  <tytso@rsts-11.mit.edu>
1552
1553         * inode.c (ext2fs_open_inode_scan): Initialize the group variables
1554                 so that we don't need to call get_next_blockgroup() the
1555                 first time around.  Saves a bit of time, and prevents us
1556                 from needing to assign -1 to current_group (which is an
1557                 unsigned value).
1558
1559         * icount.c (insert_icount_el): Cast the estimated number of inodes
1560                 from a float to an ino_t.
1561
1562         * alloc.c, alloc_tables.c, badlbocks.c, bb_compat.c, bb_inode.c,
1563                 bitmaps.c, bitops.c, block.c, bmap.c, bmove.c, brel_ma.c,
1564                 check_desc.c, closefs.c, cmp_bitmaps.c, dblist.c,
1565                 dblist_dir.c, dir_iterate.c, dirblock.c, dupfs.c,
1566                 expanddir.c, ext2fs.h, fileio.c, freefs.c,
1567                 get_pathname.c, getsize.c, icount.c, initialize.c,
1568                 inline.c, inode.c, irel_ma.c, ismounted.c, link.c,
1569                 lookup.c, mkdir.c, namei.c, native.c, newdir.c,
1570                 openfs.c, read_bb.c, read_bb_file.c, rs_bitmap.c,
1571                 rw_bitmaps.c, swapfs.c, test_io.c, tst_badblocks.c,
1572                 tst_getsize.c, tst_iscan.c, unix_io.c, unlink.c,
1573                 valid_blk.c, version.c: If EXT2_FLAT_INCLUDES is
1574                 defined, then assume all of the
1575                 ext2-specific header files are in a flat directory.
1576
1577         * block.c, bmove.c, dirblock.c, fileio.c: Explicitly cast
1578                 all assignments from void * to be compatible with C++.
1579
1580 Tue Jan  6 11:28:15 1998  Theodore Ts'o  <tytso@rsts-11.mit.edu>
1581
1582         * closefs.c (ext2fs_flush): Add a call to io_channel_flush() to
1583                 make sure the contents of the disk are flushed to disk.
1584
1585 Mon Dec 29 14:39:13 1997  Theodore Ts'o  <tytso@rsts-11.mit.edu>
1586
1587         * dblist.c (ext2fs_add_dir_block): Change new to be new_entry to
1588                 avoid C++ namespace clash.
1589
1590         * bitmaps.c (ext2fs_copy_bitmap): Change new to be new_map to
1591                 avoid C++ namespace clash.
1592
1593         * ext2fs.h, bb_inode.c, block.c, bmove.c, brel.h, brel_ma.c,
1594                 irel.h, irel_ma.c, dblist.c, dblist_dir.c, dir_iterate.c,
1595                 ext2fsP.h, expanddir.c, get_pathname.c, inode.c, link.c,
1596                 unlink.c: Change private to be priv_data (to avoid C++
1597                 namespace clash)
1598
1599 Fri Nov 28 09:26:31 1997  Theodore Ts'o  <tytso@rsts-11.mit.edu>
1600
1601         * dblist.c (ext2fs_get_num_dirs): Make ext2fs_get_num_dirs more
1602                 paranoid about validating the directory counts from the
1603                 block group information.
1604
1605         * all files: Don't include stdlib.h anymore; include it in
1606                 ext2_fs.h, since that file requires stdlib.h
1607
1608 Thu Nov 20 16:07:38 1997  Theodore Ts'o  <tytso@rsts-11.mit.edu>
1609
1610         * expanddir.c (ext2fs_expand_dir): Check to make sure the block
1611                 bitmap is loaded, and return an error if it is not.
1612                 (expand_dir_proc): Only use ext2fs_write_dir_block when
1613                 writing a directory block, not when writing out a fresh
1614                 indirect block.
1615
1616 Tue Nov 11 22:46:45 1997  Theodore Ts'o  <tytso@rsts-11.mit.edu>
1617
1618         * Makefile.in, tst_getsize.c: Added new file which is used to test
1619                 the ext2fs_get_device_size function.
1620
1621         * ext2_err.et.in (EXT2_ET_UNIMPLEMENTED): Added new error code.
1622
1623 Sun Nov  2 20:36:13 1997  Theodore Ts'o  <tytso@rsts-11.mit.edu>
1624
1625         * ext2fs.h: Make ext2fs_get_mem take an unsigned argument.
1626
1627         * fileio.c (ext2fs_file_get_size, ext2fs_file_set_size,
1628                 ext2fs_file_get_fs): New functions added.
1629
1630
1631 Fri Oct 31 12:16:52 1997    <tytso@EDT.MIT.EDU>
1632
1633         * bitops.c (ext2fs_warn_bitmap, ext2fs_warn_bitmap2): Don't call
1634                 com_err if OMIT_COM_ERR is defined.
1635
1636 Thu Oct 30 11:33:57 1997  Theodore Ts'o  <tytso@rsts-11.mit.edu>
1637
1638         * Rename new error codes to _ET_ in them for consistency.
1639
1640 Sat Oct 25 00:06:58 1997  Theodore Ts'o  <tytso@rsts-11.mit.edu>
1641
1642         * [all files, basically]: Added definition of ext2fs_get_mem, 
1643                 ext2fs_free_mem, and ext2fs_resize_mem in ext2fs.h, and
1644                 changed all library routines to use these wrapper functions.
1645
1646         * dblist.c, mkdir.c: use EXT2_DIR_EXISTS and EXT2_DB_NOT_FOUND
1647                 instead of the system error messages.
1648         
1649         * ext2_err.et.in: Added new error messages EXT2_DIR_EXISTS and
1650                 EXT2_DB_NOT_FOUND
1651
1652         * ext2fs.h: Added function declarations and constants for bmap.c
1653                 and fileio.c.
1654
1655         * ext2_err.et.in: Added new error messages EXT2_FILE_RO and
1656                 EXT2_ET_MAGIC_EXT2_FILE
1657
1658         * Makefile.in: Added files bmap.c and fileio.c, and temporarily
1659                 commented out brel_ma.c and irel_ma.c
1660
1661         * bmap.c: New file which maps a file's logical block number to its
1662                 physical block number.
1663
1664         * fileio.c: New file which implements simple file reading and
1665                 writing primitives.
1666
1667         * alloc.c (ext2fs_alloc_block): New function which allocates a
1668                 block, zeros it, and updates the filesystem accounting
1669                 records appropriately.
1670
1671 Wed Oct 22 16:47:27 1997  Theodore Ts'o  <tytso@rsts-11.mit.edu>
1672
1673         * ext2_err.et.in: Added new error codes: EXT2_NO_MEMORY,
1674                 EXT2_INVALID_ARGUMENT, EXT2_BLOCK_ALLOC_FAIL,
1675                 EXT2_INODE_ALLOC_FAIL, EXT2_NOT_DIRECTORY
1676
1677         * Change various library files to use these functions instead of
1678                 EINVAL, ENOENT, etc.
1679
1680 Mon Oct 20 19:32:40 1997  Theodore Ts'o  <tytso@rsts-11.mit.edu>
1681
1682         * llseek.c: Check HAVE_LLSEEK_PROTOTYPE to see whether or not we
1683                 need to declare llseek().
1684
1685 Sun Oct 19 18:56:22 1997  Theodore Ts'o  <tytso@rsts-11.mit.edu>
1686
1687         * Rename io.h to be ext2_io.h (avoid namespace collisions)
1688
1689         * Add #ifdef's for HAVE_SYS_STAT_H and HAVE_SYS_TYPES_H
1690
1691 Fri Oct  3 13:35:59 1997  Theodore Ts'o  <tytso@rsts-11.mit.edu>
1692
1693         * llseek.c (ext2fs_llseek): Fix type error for ext2fs_llseek()
1694
1695         * icount.c (ext2fs_icount_validate): 
1696         * bmove.c (process_block): Fix lint error in type for fprintf().
1697
1698 Mon Sep 15 11:45:09 1997  Theodore Ts'o  <tytso@rsts-11.mit.edu>
1699
1700         * inode.c (ext2fs_check_directory): Add support for the callback
1701                 to return the error code EXT2_ET_CALLBACK_NOTHANDLED.
1702
1703 Thu Sep  4 12:28:22 1997  Theodore Ts'o  <tytso@rsts-11.mit.edu>
1704
1705         * bitmaps.c (ext2fs_set_bitmap_padding): New function which sets the
1706                 padding of the bitmap to be all one's.
1707
1708 Wed Sep  3 14:27:30 1997  Theodore Y. Ts'o  <tytso@edt.mit.edu>
1709
1710         * llseek.c: Added missing semicolon to glibc fixup declaration of
1711         llseek().
1712
1713         * bmove.c: Add #include of errno.h
1714
1715 Sat Aug 23 22:47:46 1997  Theodore Ts'o  <tytso@rsts-11.mit.edu>
1716
1717         * Makefile.in (ELF_SO_VERSION): Bump version to be 2.4 since we've
1718                 added a new field to the io_channel (app_data).
1719
1720         * io.h: Add a new element to the io_channel structure, app_data.
1721
1722         * initialize.c, openfs.c: Set io->app_data to point at the
1723                 filesystem handle.
1724
1725 Thu Aug 14 08:14:17 1997  Theodore Ts'o  <tytso@rsts-11.mit.edu>
1726
1727         * io.h: Change the prototype of ext2fs_llseek() to use int's
1728                 instead of unsigned int's.
1729
1730         * llseek.c: Change to allow PIC and !HAVE_LLSEEK.  Add a prototype
1731                 to make life easer for GNU Libc 2.
1732
1733         * rw_bitmaps.c: On the PowerPC, the big-endian variant of the ext2
1734                 filesystem has its bitmaps stored as 32-bit words with bit
1735                 0 as the LSB of each word.  Thus a bitmap with only bit 0
1736                 set would be, as a string of bytes, 00 00 00 01 00 ...  To
1737                 cope with this, we byte-reverse each word of a bitmap if
1738                 we have a big-endian filesystem, that is, if we are *not*
1739                 byte-swapping other word-sized numbers.
1740
1741 Mon Aug 11 03:30:48 1997  Theodore Ts'o  <tytso@rsts-11.mit.edu>
1742
1743         * dosio.c: New file to do DOS/BIOS disk accesses.
1744
1745         * namei.c (open_namei): Make pathlen be of type size_t.
1746
1747         * llseek.c: Always #include stdlib.h since it's need to define
1748                 size_t.  
1749
1750         * io.h: Use errcode_t for magic numbers.
1751
1752         * icount.c (get_icount_el): Use size_t where appropriate
1753         
1754         * dupfs.c (ext2fs_dup_handle): 
1755         * dblist.c (dir_block_cmp): Use size_t where appropriate.
1756
1757         * read_bb.c (ext2fs_read_bb_inode): 
1758         * cmp_bitmaps.c (ext2fs_compare_inode_bitmap): Use blk_t, ino_t
1759                 and size_t where appropriate.
1760
1761         * closefs.c (ext2fs_flush): Use dgrp_t instead of int where
1762                 appropriate.
1763
1764         * openfs.c (ext2fs_open): 
1765         * check_desc.c (ext2fs_check_desc): Use blk_t instead of int where
1766                 appropriate.
1767
1768         * rw_bitmaps.c (read_bitmaps): 
1769         * irel_ma.c: 
1770         * inode.c (ext2fs_write_inode): 
1771         * initialize.c (ext2fs_initialize):
1772         * brel_ma.c: Fix to make be 16-bit safe.
1773
1774         * link.c (ext2fs_link): 
1775         * unlink.c (ext2fs_unlink):
1776         * lookup.c (lookup_proc): 
1777         * ismounted.c (ext2fs_check_if_mounted): 
1778         * block.c (xlate_func): Add #pragma argsused for Turbo C.
1779
1780 Sun Aug 10 10:05:22 1997  Theodore Ts'o  <tytso@rsts-11.mit.edu>
1781
1782         * block.c (ext2fs_block_iterate2): Use retval which is a errcode_t
1783                 type.
1784
1785         * bitmaps.c (make_bitmap): Use size_t instead of int where
1786                 appropriate.
1787
1788         * bb_inode.c (set_bad_block_proc): Add #pragma argsused for Turbo C.
1789
1790         * alloc.c (ext2fs_new_inode): Use ino_t instead of int for the
1791                 group number.
1792
1793         * get_pathname.c: Use ino_t instead of int where appropriate.
1794
1795         * ext2fs.h: Make the magic structure element be errcode_t instead
1796                 of int.
1797
1798         * alloc.c alloc_tables.c badblocks.c bb_compat.c bb_inode.c
1799                 bitmaps.c block.c bmove.c brel_ma.c check_desc.c closefs.c
1800                 cmp_bitmaps.c dblist.c dblist_dir.c dir_iterate.c
1801                 dirblock.c dupfs.c expanddir.c freefs.c get_pathname.c
1802                 icount.c initialize.c inline.c inode.c irel_ma.c link.c
1803                 llseek.c lookup.c mkdir.c namei.c newdir.c read_bb.c
1804                 read_bb_file.c rs_bitmap.c rw_bitmaps.c swapfs.c 
1805                 test_io.c tst_badblocks.c tst_iscan.c unix_io.c unlink.c
1806                 valid_blk.c version.c: Add an #ifdef for HAVE_UNISTD_H
1807
1808 Tue Jun 17 01:33:20 1997  Theodore Ts'o  <tytso@rsts-11.mit.edu>
1809
1810         * unix_io.c (unix_read_blk): If ext2fs_llseek() fails, but errno
1811                 is zero, then return EXT2_IO_LLSEEK_FAILED.
1812
1813         * ext2_err.et.in: Add a new error code, EXT2_IO_LLSEEK_FAILED.
1814
1815         * Release of E2fsprogs 1.11
1816
1817 Mon Jun 16 23:53:06 1997  Theodore Ts'o  <tytso@rsts-11.mit.edu>
1818
1819         * dblist.c (ext2fs_dblist_count): Added new function which returns
1820                 the number of directory blocks in dblist.
1821
1822 Sat Jun 14 01:39:13 1997  Theodore Ts'o  <tytso@rsts-11.mit.edu>
1823
1824         * unix_io.c (unix_flush): Make the io_channel flush function do a
1825                 fsync to flush the kernel buffers to disk.
1826
1827 Wed Jun 11 18:25:31 1997  Theodore Ts'o  <tytso@rsts-11.mit.edu>
1828
1829         * inode.c (ext2fs_inode_scan_goto_blockgroup): Fix bug; the
1830                 current inode number wasn't being set by the
1831                 goto_blockgroup function.
1832
1833 Mon Jun  9 10:45:48 1997  Theodore Ts'o  <tytso@rsts-11.mit.edu>
1834
1835         * bmove.c (ext2fs_move_blocks): New function which takes a bitmap
1836                 of blocks which need to be moved, and moves those blocks
1837                 to another location in the filesystem.
1838
1839         * rs_bitmap.c (ext2fs_resize_generic_bitmap): When expanding a
1840                 bitmap, make sure all of the new parts of the bitmap are
1841                 zero. 
1842
1843 Sun Jun  8 16:24:39 1997  Theodore Ts'o  <tytso@rsts-11.mit.edu>
1844
1845         * bitmaps.c (ext2fs_copy_bitmap): Fix bug; the destination bitmap
1846                 wasn't being returned to the caller.
1847
1848         * alloc_tables.c (ext2fs_allocate_group_table): Add new function
1849                 ext2fs_allocate_group_table() which sets the group tables
1850                 for a particular block group.  The relevant code was
1851                 factored out of ext2fs_allocate_tables().
1852
1853         * dblist.c (make_dblist): Adjust the initial size of the directory
1854                 block list to be a bit more realistic (ten plus twice the
1855                 number of directories in the filesystem).
1856
1857 Thu May  8 22:19:09 1997  Theodore Ts'o  <tytso@rsts-11.mit.edu>
1858
1859         * badblocks.c (ext2fs_badblocks_list_test): Fix bug where
1860                 ext2fs_badblocks_list_test would test the list (and exceed
1861                 array boundaries) if there were no bad blocks on the bad
1862                 blocks list.  (Showed up when user tried: mke2fs -c -b 4096).
1863
1864 Thu Apr 24 12:16:42 1997  Theodre Ts'o  <tytso@localhost.mit.edu>
1865
1866         * Release of E2fsprogs version 1.10
1867
1868 Thu Apr 24 10:13:42 1997  Theodre Ts'o  <tytso@localhost.mit.edu>
1869
1870         * alloc_tables.c (ext2fs_allocate_tables): Correctly place the
1871                 inode and block bitmaps based on the RAID 0 stride
1872                 parameter (which is passed by mke2fs).
1873
1874         * ext2fs.h: Add "stride" parameter to ext2_filsys, to be used by
1875                 mke2fs to communicate the stride length to
1876                 ext2fs_allocate_tables()
1877
1878 Wed Apr 23 21:50:42 1997  Theodre Ts'o  <tytso@localhost.mit.edu>
1879
1880         * initialize.c (ext2fs_initialize): Fix to compile under Linux 1.2
1881                 systems.  (We can't assume that the new filesystem types
1882                 are supported.)
1883
1884 Wed Apr 23 18:40:53 1997  Theodore Ts'o  <tytso@rsts-11.mit.edu>
1885
1886         * alloc_tables.c (ext2fs_allocate_tables): Make sure that we
1887                 allocate the inode and block bitmaps inside block group at
1888                 all times.
1889
1890 Mon Apr 21 00:06:28 1997  Theodore Ts'o  <tytso@rsts-11.mit.edu>
1891
1892         * alloc.c (ext2fs_new_block): Fix bug where if goal==0 and the
1893                 filesystem has no free blocks, ext2fs_new_block would loop
1894                 forever.
1895
1896         * dupfs.c (ext2fs_dup_handle): Duplicate an ext2 filesystem handle
1897
1898         * freefs.c (ext2fs_free_inode_cache): Decrement refcount and only
1899                 free if refcount goes to zero.
1900
1901         * inode.c (create_icache): Initialize refcount to 1.
1902
1903         * ext2fsP.h: Added refcount to ext2_inode_cache
1904
1905         * dblist.c (ext2fs_copy_dblist): New function to copy a directory
1906                 block list.
1907
1908         * badblocks.c (ext2fs_badblocks_copy): New function to copy a
1909                 badblocks structure.
1910
1911 Sun Apr 20 23:19:51 1997  Theodore Ts'o  <tytso@rsts-11.mit.edu>
1912
1913         * bitmaps.c (ext2fs_copy_bitmap): New function to copy a bitmap.
1914
1915         * unix_io.c, test_io.c (unix_open, test_open): Initialize the
1916                 refcount to 1.
1917                 (unix_close, test_close): Decrement the refcount and only
1918                 close the io_channel if the refcount goes to 0.
1919
1920         * io.h: Add refcount to the io_channel structure.  Add new macro
1921                 interface io_channel_bumpcount() to bump the refcount.
1922
1923 Thu Apr 17 20:25:03 1997  Theodore Ts'o  <tytso@rsts-11.mit.edu>
1924
1925         * inode.c (ext2fs_read_inode, ext2fs_write_inode): Use the inode
1926                 cache in the filesystem handle, instead of the inode cache
1927                 in a static variable.
1928
1929         * freefs.c: Added static function to free the inode cache (called by
1930                 ext2fs_free). 
1931
1932         * ext2fsP.h: Added definition of the ext2_inode_cache structures.
1933
1934         * ext2fs.h: Added pointer to the inode_cache structure.
1935
1936         * block.c (block_iterate_ind, block_iterate_dind, 
1937                 block_iterate_tind): If there are holes in the indirect,
1938                 doubly indirect, or triply indirect blocks, increment the
1939                 block count field automatically.
1940
1941 Thu Apr 17 12:23:38 1997  Theodore Ts'o  <tytso@rsts-11.mit.edu>
1942
1943         * Release of E2fsprogs version 1.09
1944
1945 Mon Apr 14 20:38:56 1997  Theodore Ts'o  <tytso@rsts-11.mit.edu>
1946
1947         * version.c (ext2fs_parse_version_string): Check the passed in
1948                 version string (instead of the hard-coded one).
1949
1950         * alloc_tables.c (ext2fs_allocate_tables): If the last block is
1951                 greater filesystem size, clamp it to prevent allocating a
1952                 block or inode bitmap beyond the filesystem.
1953
1954         * initialize.c (ext2fs_initialize): Fix bug where the metatdata
1955                 overhead calculation was accidentally removed.
1956
1957 Fri Apr 11 18:56:26 1997  Theodore Ts'o  <tytso@rsts-11.mit.edu>
1958
1959         * Release of E2fsprogs version 1.08
1960
1961 Thu Apr 10 13:15:15 1997  Theodore Ts'o  <tytso@rsts-11.mit.edu>
1962
1963         * dblist.c (ext2fs_set_dir_block): New function which sets the
1964                 block of a dblist entry, given the directory inode and
1965                 blockcnt.
1966
1967 Sat Apr  5 12:42:42 1997  Theodore Ts'o  <tytso@rsts-11.mit.edu>
1968
1969         * alloc_tables.c (ext2fs_allocate_tables): Allocate the bitmap and
1970                 inode bitmaps at staggered locations across the block
1971                 groups, to avoid concentrating the bitmaps on a small
1972                 number of disks when using striped RAID arrays.
1973
1974         * initialize.c (ext2fs_initialize): By default, choose the maximum
1975                 possible number of blocks per group (based on the size of
1976                 the bitmaps in the blocksize).
1977
1978 Fri Apr  4 11:28:16 1997  Theodore Ts'o  <tytso@rsts-11.mit.edu>
1979
1980         * initialize.c (ext2fs_initialize): Add support for
1981                 EXT2_COMPAT_SPARSE_SUPER feature.
1982
1983         * closefs.c (ext2fs_bg_has_super): New function to determine
1984                 whether or a particular block group should have a
1985                 superblock and block group descriptor.  Used for the
1986                 EXT2_COMPAT_SPARSE_SUPER feature is turned on.
1987                 (ext2fs_flush):  Check ext2fs_bg_has_super to see whether
1988                 or not the superblock should be written out for the block
1989                 group. 
1990
1991         * ext2fs.h (EXT2_COMPAT_SPARSE_SUPER): Define compatibility flag
1992                 for sparse duplicate superblocks.
1993
1994         * version.c (ext2fs_get_library_version): New function which
1995                 returns the library version.
1996
1997         * version.c (ext2fs_parse_version_string): New function which
1998                 parses a version string and returns a version number,
1999                 so application programs can compare version numbers as
2000                 integers.
2001
2002 Wed Mar 26 00:43:52 1997  Theodore Ts'o  <tytso@rsts-11.mit.edu>
2003
2004         * icount.c (ext2fs_create_icount): Change function so that it also
2005                 takes a new argument which contains a "hint" icount
2006                 structure.  This "hint" icount allows the create function
2007                 to set up the sorted list in advance.  This reduces
2008                 significantly the amount of data moving needed to insert
2009                 these inodes into the list later.
2010         
2011         * icount.c (ext2fs_icount_validate): New function which validates
2012                 that the icount structure's rep invariant.
2013
2014         * icount.c (get_icount_el): Completely revamped implementation
2015                 to subsume put_icount_el().  Put_icount_el() used to
2016                 use an O(N) implementation to insert in the middle
2017                 of the icount list.  It now uses a O(ln N) to search
2018                 for where the icount should be inserted, and then uses
2019                 a memcpy to move the list down (instead of a for loop).
2020         
2021         * icount.c (ext2fs_icount_fetch, ext2fs_icount_store,
2022                 ext2fs_icount_increment, ext2fs_icount_decrement): Check
2023                 to see if the inode is within bounds; if it isn't, return
2024                 EINVAL.
2025
2026         * bitops.h (ext2fs_test_generic_bitmap): Fix error message given
2027                 when a bad inode number is passed to test_generic_bitmap
2028                 to be EXT2FS_TEST_ERROR instead of the wrong
2029                 EXT2FS_UNMARK_ERROR.
2030
2031 Wed Mar 12 13:32:05 1997  Theodore Y. Ts'o  <tytso@mit.edu>
2032
2033         * Release of E2fsprogs version 1.07
2034
2035 Sun Mar  2 16:46:18 1997  Theodore Ts'o  <tytso@rsts-11.mit.edu>
2036
2037         * Makefile.in (ELF_VERSION): Change version to be 2.2
2038
2039 Tue Feb 11 14:54:02 1997  Theodore Ts'o  <tytso@rsts-11.mit.edu>
2040
2041         * alloc.c (ext2fs_get_free_blocks): Change routine to use
2042                 ext2fs_fast_test_block_bitmap_range().
2043
2044         * bitops.h (ext2fs_fast_test_block_bitmap_range,
2045                 ext2fs_test_block_bitmap_range: New inline functions which
2046                 test to see whether a contiguous range of blocks is
2047                 available.
2048
2049 Thu Feb  6 10:00:13 1997  Theodore Ts'o  <tytso@rsts-11.mit.edu>
2050
2051         * badblocks.c (ext2fs_badblocks_list_create): Rename sybmols to use
2052                 use ext2fs_badblocks_* instead of badblocks_*
2053
2054         * bb_compat.c: New file which translates between old badblocks_*()
2055                 names to ext2fs_badblocks_*()
2056
2057         * unlink.c (ext2fs_unlink): New file, moved ext2fs_unlink() from
2058                 link.c (since e2fsck doesn't use ext2fs_unlink()).
2059
2060         * rs_bitmap.c (ext2fs_resize_generic_bitmap): New file, contains
2061                 bitmap resizing routine moved from bitmaps.c, since e2fsck
2062                 doesn't need to use this function.
2063
2064         * lookup.c (ext2fs_lookup): Moved ext2fs_lookup to its own file,
2065                 since e2fsck only needs ext2fs_lookup.
2066
2067 Mon Feb  3 10:11:40 1997  Theodore Ts'o  <tytso@rsts-11.mit.edu>
2068
2069         * inode.c (ext2fs_open_inode_scan): Set fs->badblocks if it is not
2070                 already set; this is needed so that programs like dump
2071                 which use the inode scan functions will deal with
2072                 filesystems that have bad blocks in the inode table.
2073
2074 Sun Feb  2 00:17:36 1997  Theodore Ts'o  <tytso@rsts-11.mit.edu>
2075
2076         * ext2fs.h (struct_badblocks_list, struct_badblocks_iterate): 
2077                 Moved to ext2fsP.h, since it doesn't need to be part of
2078                 the public interface.
2079
2080         * dir_iterate.c: Move ext2_dir_iterate out of namei.c.
2081
2082 Sat Feb  1 10:14:55 1997  Theodore Ts'o  <tytso@rsts-11.mit.edu>
2083
2084         * dblist.c (ext2fs_get_num_dirs): New file, which implements a
2085                 directory block list abstraction.  (Code moved from
2086                 e2fsck).
2087
2088         * ext2fs.h, inode.c: Moved definition of ext2_struct_inode_scan to
2089                 to inode.c (since no one else should be peeking inside it!)
2090
2091         * valid_blk.c (ext2_inode_has_valid_blocks): New function.
2092
2093         * openfs.c (ext2fs_open): Check the feature set in the ext2
2094                 superblock, and refuse to open filesystems if they contain
2095                 incompatible features.  (Can be overriden with the
2096                 EXT2_FLAG_FORCE 
2097
2098 Sun Jan 12 11:31:46 1997  Theodore Ts'o  <tytso@rsts-11.mit.edu>
2099
2100         * block.c (ext2fs_block_iterate2): Added new function
2101                 ext2fs_block_iterate2 which changes the function
2102                 signature of the callback function to include the
2103                 referencing block and offset.
2104
2105         * inode.c (ext2fs_inode_scan_goto_blockgroup): Added new function
2106                 ext2fs_inode_scan_goto_blockgroup which allows an
2107                 application to jump to a particular block group while
2108                 doing an inode scan.
2109
2110 Wed Jan  1 23:50:12 1997  Theodore Ts'o  <tytso@rsts-11.mit.edu>
2111
2112         * dirblock.c: Include string.h, since we use memcpy().
2113
2114 Tue Dec  3 12:27:29 1996  Theodore Ts'o  <tytso@rsts-11.mit.edu>
2115
2116         * getsize.c (ext2fs_get_device_size): The ioctl BLKGETSIZE returns
2117                 a long not an int; this doesn't matter on i386 machines,
2118                 but it does on Alpha's.
2119         
2120 Fri Nov 29 20:57:37 1996  Theodore Ts'o  <tytso@rsts-11.mit.edu>
2121
2122         * inode.c (ext2fs_write_inode, ext2fs_read_inode): If the inode
2123                 table pointer is NULL, then return an error indicating
2124                 that the inode table is missing.
2125                 (get_next_blockgroup, get_next_blocks,
2126                 ext2fs_get_next_inode): Don't treat a missing inode table
2127                 as permanent error.  Return MISSING_INODE_TABLE, but as an
2128                 advisory error code, much like BAD_BLOCK_IN_INODE_TABLE.
2129
2130         * rw_bitmaps.c (ext2fs_write_block_bitmap,
2131                 ext2fs_write_inode_bitmap): If the inode or block bitmap
2132                 block is zero, then don't write out the inode or block
2133                 bitmap.  The idea here is to avoid stomping on the
2134                 superblock.
2135                 (read_bitmaps): If the inode or block bitmap block is
2136                 zero, then fill in that portion of the inode or block
2137                 bitmap with all zeros.
2138
2139         * inode.c (ext2fs_get_next_inode): Fix bug in handling of bad
2140                 blocks in inode table when the inode table size is
2141                 non-standard (and can therefore span blocks).
2142
2143 Tue Oct 29 20:13:14 1996  Theodore Ts'o  <tytso@rsts-11.mit.edu>
2144
2145         * alloc.c (ext2fs_new_block): Fix fencepost error in
2146                 ext2fs_new_block; make sure we don't try to allocate the
2147                 first block beyond the end of the filesystem.
2148
2149 Mon Oct 14 11:00:48 1996  Theodore Ts'o  <tytso@rsts-11.mit.edu>
2150
2151         * inode.c (check_for_inode_bad_blocks): New function called by
2152                 get_next_blocks() to avoid reading in bad blocks marked in
2153                 fs->badblocks.  Inodes located in bad blocks are returned
2154                 by ext2fs_get_next_inode() returns the error code 
2155                 EXT2_ET_BAD_BLOCK_IN_INODE_TABLE.
2156         
2157         * alloc_tables.c (ext2fs_allocate_tables): New function which
2158                 performs the part of mke2fs's job of allocating the 
2159                 filesystem tables.
2160
2161         * test_io.c (test_close): IO manager which is used for testing
2162                 purposes.
2163
2164 Sun Oct 13 04:31:57 1996  Theodore Ts'o  <tytso@rsts-11.mit.edu>
2165
2166         * inode.c (ext2fs_get_next_inode): Separate out the function of
2167                 setting up for a new block group to get_next_blockgroup().
2168                 Separate out the function of reading in blocks of the
2169                 inode table to get_next_blocks().
2170
2171         * ext2fs.h: Add the badblocks list to the ext2_filsys entry
2172
2173         * badblocks.c (badblocks_list_add, badblocks_list_test): Add
2174                 blocks to the badblock list in sorted order.  This allows
2175                 badblocks_list_test to be coded using a binary search for
2176                 speed.
2177
2178 Tue Oct  8 02:02:03 1996  Theodore Ts'o  <tytso@rsts-11.mit.edu>
2179
2180         * Release of E2fsprogs version 1.06
2181
2182 Mon Oct  7 00:44:17 1996  Theodore Ts'o  <tytso@rsts-11.mit.edu>
2183
2184         * ext2fs.h, block.c, closefs.c, dirblock.c, inode.c, native.c,
2185                 open.c: Change EXT2_SWAP to EXT2_FLAG_SWAP for
2186                 consistency's sake.
2187         
2188         * closefs.c (ext2fs_flush): If the flag EXT2_MASTER_SB_ONLY is
2189                 set, then only write out the master superblock.
2190
2191 Sun Oct  6 21:45:26 1996  Theodore Ts'o  <tytso@rsts-11.mit.edu>
2192
2193         * block.c (ext2fs_block_iterate): Fixed bug which caused
2194                 block_iterate to fail to handle HURD created filesystems;
2195                 it tested the inode translator field before the inode was
2196                 loaded.
2197
2198 Tue Sep 17 14:08:24 1996  Theodore Ts'o  <tytso@rsts-11.mit.edu>
2199
2200         * initialize.c (ext2fs_initialize): Make sure the description for
2201                 the inode bitmap is set correctly.
2202
2203         * bitmaps.c (ext2fs_allocate_generic_bitmap): Fix minor type typo.
2204
2205 Thu Sep 12 15:23:07 1996  Theodore Ts'o  <tytso@rsts-11.mit.edu>
2206
2207         * Release of E2fsprogs version 1.05
2208
2209 Sat Sep  7 07:36:03 1996  Theodore Ts'o  <tytso@rsts-11.mit.edu>
2210
2211         * initialize.c: Override the kernel's idea of default
2212                 checkinterval from 0 (never) to 180 days.
2213
2214 Wed Aug 28 03:20:03 1996  Theodore Ts'o  <tytso@rsts-11.mit.edu>
2215
2216         * namei.c (ext2fs_namei_follow): New function which follows
2217                 symbolic link (if any) at the target.
2218
2219 Tue Aug 27 01:48:43 1996  Theodore Ts'o  <tytso@rsts-11.mit.edu>
2220
2221         * inode.c (ext2fs_read_inode, ext2fs_write_inode): Add support
2222                 for shortcut function fs->read_inode() and fs->write_inode().
2223                 Added inode_cache to reduce CPU time spent in doing
2224                 byte swapping.
2225
2226         * swapfs.c (ext2fs_swap_super): Swap the new fields in a V2
2227                 superblock.
2228
2229         * namei.c (ext2fs_follow_link): New function.
2230                 (ext2fs_namei): Extended to have support for chasing
2231                 symbolic links.  ext2fs_namei() still returns an inode
2232                 which is a symbolic link.  Symbolic links are only chased
2233                 while resolving the containing directory.  To chase
2234                 symbolic links of the final result, use
2235                 ext2fs_follow_link().
2236
2237 Mon Aug 26 23:46:07 1996  Theodore Ts'o  <tytso@rsts-11.mit.edu>
2238
2239         * ext2_err.et.in: Added new error code EXT2_ET_SYMLINK_LOOP.
2240
2241         * bitops.h (ext2fs_set_bit, ext2fs_celar_bit): Use asm inlines
2242                 provided by Pete A. Zaitcev (zaitcev@lab.sun.mcst.ru).
2243
2244 Thu Aug 22 00:40:18 1996  Theodore Ts'o  <tytso@rsts-11.mit.edu>
2245
2246         * initialize.c (ext2fs_initialize): On systems where the byte
2247                 order is not i386 compatible, set the swap_byte flag.
2248
2249         * inode.c (inocpy_with_swap): Check to see if inode contains a
2250                 fast symlink before swapping the inode block fields.  This
2251                 required adding a new argument to inocpy_with_swap to
2252                 determine whether the mode field is in host order or not.
2253
2254 Wed Aug 21 00:45:42 1996  Theodore Ts'o  <tytso@rsts-11.mit.edu>
2255
2256         * bitops.h (ext2fs_set_bit, ext2fs_clear_bit, ext2fs_test_bit): On
2257                 the sparc, if EXT2_STD_BITOPS set, use the standard
2258                 i386-compatible bitmask operations, instead on the
2259                 non-standard native bitmask operators.
2260
2261 Fri Aug  9 11:11:35 1996  Theodore Ts'o  <tytso@rsts-11.mit.edu>
2262
2263         * block.c (ext2fs_block_iterate): Cause block iterator to return
2264                 the HURD translator block (along with everything else).
2265                 If the flag BLOCK_FLAG_DATA_ONLY is passed to the block
2266                 iterator, then don't return any meta data blocks
2267                 (including the HURD translator).
2268
2269 Wed Jul 17 17:13:34 1996  Theodore Ts'o  <tytso@rsts-11.mit.edu>
2270
2271         * gen_uuid.c: New file, which generates DCE-compatible UUIDs.
2272
2273         * uuid.c: New file, containing UUID utility functions.
2274
2275 Tue Jul 16 10:19:16 1996  Theodore Ts'o  <tytso@rsts-11.mit.edu>
2276
2277         * ext2fs.h: Add a definition of the "real" ext2 superblock.
2278
2279 Fri May 24 14:54:55 1996  Theodore Ts'o  <tytso@rsts-11.mit.edu>
2280
2281         * ext2fs.h: Fix erroneous ino_t type used in block_bitmap type.
2282
2283 Sun May 19 15:39:03 1996  Theodore Ts'o  <tytso@rsts-11.mit.edu>
2284
2285         * openfs.c (ext2fs_open): If the blocksize in the superblock is
2286                 zero, return the error EXT2_ET_CORRUPT_SUPERBLOCK, since
2287                 that's a basic value that must be correct for the rest of
2288                 the library to work.
2289
2290         * ext2_err.et.in (EXT2_ET_CORRUPT_SUPERBLOCK): Added new error
2291                 code.
2292
2293 Thu May 16 11:12:30 1996  Theodore Ts'o  <tytso@rsts-11.mit.edu>
2294
2295         * Release of E2fsprogs version 1.04
2296
2297 Wed Mar 27 00:33:40 1996    <tytso@rsts-11.mit.edu>
2298
2299         * Release of E2fsprogs version 1.03
2300
2301 Tue Mar 26 12:06:32 1996    <tytso@rsts-11.mit.edu>
2302
2303         * bitops.h (ext2fs_set_bit, ext2fs_clear_bit, ext2fs_test_bit):
2304                 Change the m68k bit numbering for bitmasks to match with
2305                 the bit numbering used by all other ext2 implementations.
2306
2307 Thu Mar  7 03:37:00 1996    <tytso@rsts-11.mit.edu>
2308
2309         * inode.c (ext2fs_get_next_inode, ext2fs_close_inode_scan, 
2310         ext2fs_open_inode_scan): Support dynamically-sized inodes.
2311
2312 Wed Mar  6 12:26:29 1996    <tytso@rsts-11.mit.edu>
2313
2314         * inode.c (ext2fs_read_inode, ext2fs_write_inode): Support
2315                 dynamically-sized inodes.
2316
2317         * openfs.c (ext2fs_open): Allow dynamic revision filesystem to be
2318                 loaded.
2319
2320 Tue Mar  5 03:49:37 1996    <tytso@rsts-11.mit.edu>
2321
2322         * initialize.c (ext2fs_initialize): Catch an error condition where
2323                 the passed in size is *really* too small.
2324
2325         * alloc.c (ext2fs_new_inode): 
2326         * ext2fs.h (EXT2_FIRST_INODE): Add support for dynamic revision to
2327                 get first inode.
2328
2329 Wed Feb 21 15:56:17 1996    <tytso@rsts-11.mit.edu>
2330
2331         * getsize.c (ext2fs_get_device_size): Open the device read-only
2332                 when trying to determine its size.
2333
2334 Wed Jan 31 11:06:08 1996    <tytso@rsts-11.mit.edu>
2335
2336         * Release of E2fsprogs version 1.02
2337
2338 Sat Dec  9 09:57:50 1995    <tytso@rsts-11.mit.edu>
2339
2340         * rw_bitops.c (ext2fs_write_block_bitmap):
2341         * bitops.c (ext2fs_test_bit, ext2fs_clear_bit, ext2fs_set_bit):
2342         * bitops.h (ext2fs_test_bit, ext2fs_clear_bit, ext2fs_set_bit):
2343                 Rename {test,set,clear}_bit to ext2fs_{test,set,clear}_bit, 
2344                 to avoid conflicts with with kernel include files.  Also
2345                 rename ADDR and CONST_ADDR to EXT2FS_ADDR and
2346                 EXT2FS_CONST_ADDR. 
2347
2348 Thu Oct 26 12:09:16 1995    <tytso@rsts-11.mit.edu>
2349
2350         * ext2_err.et: Updated message in EXT2_ET_BASE to say version 0.5c
2351
2352         * swapfs.c (ext2fs_swap_super): Put an #ifdef check around
2353                 s_def_resuid and s_def_resgid for backwards compatibility.
2354
2355 Fri Oct 20 23:33:31 1995    <tytso@rsts-11.mit.edu>
2356
2357         * bitops.h: Added #ifdef's for Sparc.
2358
2359 Wed Sep  6 22:14:46 1995    <tytso@rsts-11.mit.edu>
2360
2361         * getsize.c: #include <sys/ioctl.h> under Linux to pick up ioctl()
2362                 declaration
2363
2364         * closefs.c: #include <string.h> to pick up memset() declaration
2365
2366 Mon Sep  4 21:45:29 1995  Remy Card  <card@bbj>
2367
2368         * Makefile.in: Added support for BSD shared libraries.
2369
2370         * initialize.c (ext2fs_initialize): Correctly set the s_creator_os
2371                 flag.
2372
2373 Mon Sep  4 09:55:30 1995    <tytso@rsts-11.mit.edu>
2374
2375         * unix_io.c (unix_open): Add a double check; if the passed in name
2376                 is NULL, return EXT2_ET_BAD_DEVICE_NAME.
2377
2378         * ext2_err.et (EXT2_ET_BAD_DEVICE_NAME): Added new error code
2379
2380 Wed Aug 16 15:44:10 1995    <tytso@rsts-11.mit.edu>
2381
2382         * inode.c (ext2fs_check_directory): Use LINUX_S_ISDIR instead of
2383                 S_ISDIR.
2384
2385 Tue Aug 15 13:08:36 1995    <tytso@rsts-11.mit.edu>
2386
2387         * getsize.c (ext2fs_get_device_size): Add support for reading the
2388                 partition size from a BSD disk label.
2389
2390 Thu Aug 10 09:33:26 1995  Theodore Y. Ts'o  <tytso@lurch.mit.edu>
2391
2392         * getsize.c (ext2fs_get_device_size): New function that determins
2393                 the size of a device.  Used by mke2fs and e2fsck.
2394
2395 Sat Aug 12 03:09:54 1995  Remy Card  <card@bbj>
2396
2397         * Makefile.in (install): Install static libraries in $(ulibdir)
2398                 (/usr/lib on Linux) instead of $(libdir) (/lib on Linux).
2399
2400 Wed Aug  9 17:04:23 1995  Theodore Y. Ts'o  <tytso@dcl>
2401
2402         * bitmaps.c (ext2fs_free_inode_bitmap, ext2fs_free_block_bitmap):
2403                 Move these functions to freefs.c.
2404
2405         * closefs.c (ext2fs_flush): If swapping blocks, clear the group
2406                 descriptors shadow memory to keep purify quiet.  (This
2407                 also has the nice benefit that the unused portion of the
2408                 shadow descriptors are zeroed out.)
2409
2410         * dirblock.c (ext2fs_write_dir_block): We need to use
2411                 dirent->rec_len *before* it's byteswapped to find the
2412                 location of the next directory structure!
2413
2414         * alloc.c (ext2fs_new_inode): Fix bug which could potentially
2415                 cause ext2fs_new_inode to loop infinitely if we're trying
2416                 to allocate an inode in group #0 and there are no free
2417                 inodes at all in the system.
2418
2419         * closefs.c: #include <errno.h> if it exists.
2420
2421 Sun Aug  6 13:27:50 1995  Theodore Y. Ts'o  <tytso@lurch.mit.edu>
2422
2423         * ext2fs.h (BLOCK_FLAG_HOLE): Added new definition for
2424                 BLOCK_FLAG_APPEND.  Added documentation for the block
2425                 interator flags.
2426
2427 Sat Aug  5 11:44:05 1995  Theodore Y. Ts'o  <tytso@lurch.mit.edu>
2428
2429         * Makefile.in (DLL_INSTALL_DIR, ELF_INSTALL_DIR): Set the
2430                 installation directories correctly.
2431
2432 Tue Jul 18 09:27:38 1995    <tytso@rsx-11.mit.edu>
2433
2434         * namei.c (process_dir_block): 
2435         * mkdir.c (ext2fs_mkdir): 
2436         * expanddir.c (expand_dir_proc): Use ext2fs_{read,write}_dir_block
2437                 to read/write the directory block.
2438
2439         * dirblock.c (ext2fs_read_dir_block), ext2fs_write_dir_block): New
2440                 file containing functions for reading and writing
2441                 directory blocks (byte swapping if necesssary)
2442
2443         * block.c (block_iterate_ind, block_iterate_dind, 
2444                 block_iterate_tind): Byte swap the block addresses if
2445                 EXT2_SWAP_BYTES is set (and swap them back before writing
2446                 them out.)
2447
2448         * inode.c (inocpy_with_swap): New function.
2449         (ext2fs_get_next_inode, ext2fs_read_inode, ext2fs_write_inode):
2450                 Call inocpy_with_swap if EXT2_SWAP_BYTES if set.
2451
2452         * closefs.c (ext2fs_flush): If EXT2_SWAP_BYTES is set, then swap
2453                 the superblock and group descriptors before writing it out.
2454
2455         * openfs.c (ext2fs_open): If the magic number is byte-swapped,
2456                 then set the EXT2_SWAP_BYTES and byte-swap the superblock
2457                 and group descriptors.
2458
2459         * swapfs.c (ext2fs_swap_super, ext2fs_swap_group_desc): New functions
2460                 to desp ext2 filesystem structures.
2461
2462         * bitops.c (set_bit, clear_bit, test_bit): Use modifications
2463                 supplied by Pete A. Zaitcev so that the C language
2464                 versions of these functions are more portable.  They will
2465                 now work on both little and big endian systems, and the
2466                 assumption that 32-bit integers are used is gone.
2467
2468         * bitops.h (ext2_swab16, ext2_swab32): Added new functions for
2469                 doing byte swapping.
2470
2471         * ext2fs.h (EXT2_SWAP_BYTES): Add new flag which indicates that
2472                 byte swapping should take place.
2473
2474 Sun Jul 16 06:21:43 1995    <tytso@rsx-11.mit.edu>
2475
2476         * Makefile.in, cmp_bitmaps.c (ext2fs_compare_block_bitmap_end,
2477                 ext2fs_compare_inode_bitmap_end): Added new file
2478                 containing routines to compare bitmaps.
2479
2480         * ext2_err.et (EXT2_ET_NEQ_BLOCK_BITMAP, EXT2_ET_NEQ_INODE_BITMAP): 
2481                 Added new error codes.
2482
2483 Sat Jul 15 04:23:37 1995    <tytso@rsx-11.mit.edu>
2484
2485         * inode.c (ext2fs_get_next_inode): Don't check scan->inode_buffer;
2486                 if the magic number is correct, it will be allocated.
2487
2488 Fri Jul 14 19:02:59 1995    <tytso@rsx-11.mit.edu>
2489
2490         * block.c (block_iterate_ind, block_iterate_dind, 
2491                 block_iterate_tind): Don't recompute block_nr each loop;
2492                 just increment it!  Factor check of BLOCK_FLAG_APPEND out
2493                 of the loop.  Factor mask of BLOCK_CHANGED into changed
2494                 variable out of the loop.  (block_iterate_ind, in
2495                 particular, gets called a lot, so every little
2496                 optimization helps.)
2497
2498 Thu Jul 13 08:02:45 1995    <tytso@rsx-11.mit.edu>
2499
2500         * block.c (block_iterate_ind, block_iterate_dind, 
2501                 block_iterate_tind): Precompute limit of loop to speed up
2502                 block_iterate_ind and company.
2503
2504         * bitops.h (ext2fs_fast_mark_block_bitmap, 
2505                 ext2fs_fast_unmark_block_bitmap, ext2fs_fast_test_block_bitmap,
2506                 ext2fs_fast_mark_inode_bitmap, ext2fs_fast_unmark_inode_bitmap,
2507                 ext2fs_fast_test_inode_bitmap): Add fast version of these
2508                 functions, which don't do range checking.
2509
2510         * bitops.h (ext2fs_get_block_bitmap_start, 
2511                 ext2fs_get_inode_bitmap_start, ext2fs_get_block_bitmap_end,
2512                 ext2fs_get_inode_bitmap_end): Add new accessor functions
2513                 which return the start and end points of the bitmaps.
2514
2515 Tue Jul 11 18:59:41 1995    <tytso@rsx-11.mit.edu>
2516
2517         * llseek.c (ext2_llseek): If the offset is small enough, use lseek
2518                 instead of llseek.  The errno if the offset is too large
2519                 and lseek is not supported should be EINVAL, not -EINVAL.
2520
2521 Thu Jun 15 23:43:02 1995  Remy Card  <card@bbj>
2522
2523         * Makefile.in: Added support for ELF shared libraries.
2524                 Fixed typos in the compilation rules.
2525                 (distclean): Added Makefile.
2526
2527         * llseek.c (llseek): New function, if llseek() does not exist in the
2528         C library.
2529         (ext2_llseek): Changed to call llseek().
2530
2531 Mon Jun 12 08:29:07 1995  Theodore Y. Ts'o  <tytso@lurch.mit.edu>
2532
2533         * ext2fs.h: Use __u32 to define blk_t, instead of unsigned long.
2534
2535 Sun Jun 11 15:02:54 1995  Theodore Y. Ts'o  <tytso@lurch.mit.edu>
2536
2537         * mkdir.c (ext2fs_mkdir): Use LINUX_S_IFDIR instead of S_IFDIR.
2538
2539         * ext2fs.h (LINUX_S_IFDIR): Define a linux specific versions of
2540                 the S_*, which are normally defined in <sys/stat.h>.  This
2541                 allows us to compile e2fsprogs on a non-Linux system,
2542                 which may have a different value for S_IFDIR.
2543
2544 Sat Jun 10 23:47:05 1995  Theodore Y. Ts'o  <tytso@lurch.mit.edu>
2545
2546         * bitops.c (clear_bit, set_bit): Remove calls to cli() and sti();
2547                 this is a user-mode application!
2548
2549 Thu Jun  8 13:13:22 1995  Miles Bader  <miles@churchy.gnu.ai.mit.edu>
2550
2551         * llseek.c: Put the include of <linux/unistd.h> inside the #ifdef
2552         __linux__ so that non-linux systems won't see it.
2553
2554         * alloc.c: Include <errno.h> if possible.
2555         * badblocks.c: Ditto.
2556         * bb_inode.c: Ditto.
2557         * bitmaps.c: Ditto.
2558         * block.c: Ditto.
2559         * expanddir.c: Ditto.
2560         * get_pathname.c: Ditto.
2561         * initialize.c: Ditto.
2562         * inode.c: Ditto.
2563         * llseek.c: Ditto.
2564         * mkdir.c: Ditto.
2565         * namei.c: Ditto.
2566         * newdir.c: Ditto.
2567         * openfs.c: Ditto.
2568         * rw_bitmaps.c: Ditto.
2569         * unix_io.c: Ditto.
2570
2571         * Makefile.in: Rewritten to conform to GNU coding standards and
2572         support separate compilation directories.
2573
2574 Thu May 11 04:13:12 1995    <tytso@rsx-11.mit.edu>
2575
2576         * initialize.c (ext2fs_initialize): Don't allow more than one
2577                 bitmaps's worth of inodes in a group.
2578
2579 Sat Mar 11 14:07:11 1995  Theodore Y. Ts'o  <tytso@localhost>
2580
2581         * llseek.c (ext2_llseek): Added error checking to the llseek()
2582                 compat code to protect against overflow.  This only
2583                 applies to 1.0 and early 1.1 kernels, which don't support
2584                 the llseek() system call.
2585
2586 Thu Nov 24 16:29:00 1994  Theodore Y. Ts'o  (tytso@rt-11)
2587
2588         * unix_io.c (unix_open): Initialize the read_error and write_error
2589                 io_channel pointers to be null.
2590
2591         * bb_inode.c (clear_bad_block_proc): If an illegal block number is
2592                 found, clear it but don't try to update the filesystem
2593                 accounting information, since that's hopeless anyway.
2594
2595         * block.c (bloblock_iterate_ind, bloblock_iterate_dind,
2596         bloblock_iterate_tind): Check to see if the indirect blocks are
2597                 valid before trying to read them.
2598
2599         * ext2_err.et (EXT2_ET_BAD_IND_BLOCK, EX2_ET_BAD_DIND_BLOCK,
2600         EXT2_ET_BAD_TIND_BLOCK): Add new error codes.
2601
2602         * bitops.h (ext2fs_mark_block_bitmap, ext2fs_unmark_block_bitmap,
2603         ext2fs_test_block_bitmap, ext2fs_mark_inode_bitmap,
2604         ext2fs_unmark_inode_bitmap, ext2fs_test_inode_bitmap):  If an
2605                 illegal block or inode number is passed in, return instead
2606                 of trying to test, set, or clear the bit.
2607
2608 Mon Nov  7 21:32:33 1994  Remy Card  <card@bbj>
2609
2610         * Makefile: Added a dummy install target in case shared libraries
2611                 are not built.
2612
2613 Mon Oct 24 14:11:44 1994    (tytso@rsx-11)
2614
2615         * bitmaps.c (ext2fs_allocate_block_bitmap): Fix calculation of how
2616                 the real last block of the bitmap should be calculated.
2617
2618 Wed Sep  7 10:05:36 1994    (tytso@rsx-11)
2619
2620         * bitmaps.c (ext2fs_fudge_inode_bitmap_end, 
2621                 ext2fs_fudge_block_bitmap_end, ext2fs_clear_inode_bitmap,
2622                 ext2fs_clear_block_bitmap, ext2fs_free_inode_bitmap,
2623                 ext2fs_free_block_bitmap): Add magic number checking for
2624                 the inode and block bitmaps.
2625
2626         * bitmaps.c (ext2fs_allocate_block_bitmap): Fix to set the correct
2627                 magic number for a block bitmap instead of an inode bitmap.
2628
2629         * inode.c (ext2fs_close_inode_scan, ext2fs_get_next_inode):  Add
2630                 magic number checking for the inode_scan structure.
2631
2632         * badblocks.c (badblocks_list_free, badblocks_list_add, 
2633                 badblocks_list_test, badblocks_list_iterate_begin,
2634                 badblocks_list_iterate, badblocks_list_iterate_end): Add
2635                 magic number checking for the badblocks_list and
2636                 badblocks_iterate structures.
2637
2638         * ext2_err.et (EXT2_ET_MAGIC_UNIX_IO_CHANNEL): 
2639         * unix_io.c (unix_open, unix_close, unix_set_blksize, unix_read_blk,
2640                 unix_write_blk, unix_flush): Add magic number checking
2641                 both for io_channel structure and unix_private_data
2642                 structure.
2643
2644         * openfs.c (ext2fs_open): Add check for io_manager structure's
2645                 magic number.
2646
2647         * rw_bitmaps.c (ext2fs_write_inode_bitmap, ext2fs_write_block_bitmap,
2648                 ext2fs_read_inode_bitmap, ext2fs_read_block_bitmap,
2649                 ext2fs_read_bitmaps, ext2fs_write_bitmaps): 
2650         * read_bb.c (ext2fs_read_bb_inode): 
2651         * read_bb_file.c (ext2fs_read_bb_FILE): 
2652         * newdir.c (ext2fs_new_dir_block): 
2653         * namei.c (ext2fs_dir_iterate, ext2fs_lookup, ext2fs_namei): 
2654         * link.c (ext2fs_link, ext2fs_unlink): 
2655         * inode.c (ext2fs_open_inode_scan, ext2fs_read_inode,
2656                 ext2fs_write_inode, ext2fs_get_blocks, 
2657                 ext2fs_check_directory): 
2658         * get_pathname.c (ext2fs_get_pathname): 
2659         * expanddir.c (ext2fs_expand_dir): 
2660         * block.c (ext2fs_block_iterate): 
2661         * bitmaps.c (ext2fs_allocate_inode_bitmap, 
2662                 ext2fs_allocate_block_bitmap): 
2663         * bb_inode.c (ext2fs_update_bb_inode): 
2664         * alloc.c (ext2fs_new_inode,ext2fs_new_block,ext2fs_get_free_blocks): 
2665         * check_desc.c (ext2fs_check_desc): 
2666         * closefs.c (ext2fs_close, ext2fs_flush): 
2667         * freefs.c (ext2fs_free): Add check for ext2_filsys magic number.
2668
2669         * Makefile:
2670         * ext2fs.h:
2671         * openfs.c:
2672         * check_desc.c (ext2fs_check_desc): Move ext2fs_check_desc from
2673         openfs.c into its own file.
2674
2675         * ext2fs.h (EXT2_CHECK_MAGIC): Added macro for checking for
2676         structure magic numbers.
2677
2678         * closefs.c (ext2fs_flush): Folded in Remy Card's changes to clear
2679         the EXT2_VALID_FS flag in the backup superblock blocks, so that if
2680         someone uses the -b option to specify the use of the backup
2681         superblock --- this usually means that the main superblock is
2682         toast.  :-)
2683
2684         * ext2fs.h: 
2685         * ext2_err.et (EXT2_ET_REV_TOO_HIGH): 
2686         * openfs.c (ext2fs_open): Folded in Remy Card's changes to add a
2687         revision level to the superblock.
2688
2689 Sun Aug 21 00:50:08 1994  Theodore Y. Ts'o  (tytso@rt-11)
2690
2691         * ext2fs.h:
2692         * bitmaps.c:
2693         * bitops.c
2694         * bitops.h:
2695         * openfs.c:
2696         * initialize.c: Completely revamped the inode and block bitmap
2697         structures, so that they can be better chance of being extensible
2698         in a shared library.  They are now their own type, instead of
2699         being a char *.  Also, the function signatures of
2700         ext2fs_test_block_bitmap, ext2fs_mark_block_bitmap,
2701         ext2fs_unmark_block_bitmap, ext2fs_test_inode_bitmap,
2702         ext2fs_mark_inode_bitmap, and ext2fs_unmark_inode_bitmap were
2703         changed to eliminate the ext2_filsys argument, since it is no
2704         longer necessary.
2705
2706 Wed Aug 17 21:46:44 1994  Remy Card  (card@bbj)
2707
2708         * unix_io.c (unix_read_blk and unix_write_blk): use the llseek
2709         system call if available.
2710
2711         * llseek.c: new file.  This is the stub calling the llseek system
2712         call which allows supports for 2GB+ file systems.
2713
2714         * initialize.c (ext2fs_initialize): Ext2fs_initialize now stores
2715         the creator operating system.
2716
2717 Wed Aug 17 10:03:24 1994  Theodore Y. Ts'o  (tytso@rt-11)
2718
2719         * initialize.c (ext2fs_initialize): Ext2fs_initialize now sets up
2720         the group descriptor statistics in addition to everything else.
2721         This relieves mke2fs of the responsibility of doing it.
2722
2723         * bitops.c, bitops.h: Add assembly inline functions for the 68000.
2724         Added a new #define, _EXT2_HAVE_ASM_BITOPS_ to control whether or
2725         not the generic C function equivalents should be included or not.
2726
2727         * openfs.c (ext2fs_open): If a superblock is specified, then use
2728         the backup group descriptors that go along with this superblock,
2729         instead of using the primary group descriptors.  This allows
2730         e2fsck to recover filesystems where the primary group descriptors
2731         have been trashed.
2732
2733