christos
805187f5b9
Tidy up panic messages, no functional change.
2016-10-30 15:01:46 +00:00
jdolecek
b695bc874e
reorganize ffs_truncate()/ffs_indirtrunc() to be able to partially
...
succeed; change wapbl_register_deallocation() to return EAGAIN
rather than panic when code hits the limit
callers changed to either loop calling ffs_truncate() using new
utility ufs_truncate_retry() if their semantics requires it, or
just ignore the failure; remove ufs_wapbl_truncate()
this fixes possible user-triggerable panic during truncate, and
resolves WAPBL performance issue with truncates of large files
PR kern/47146 and kern/49175
2016-10-28 20:38:12 +00:00
jdolecek
3c9f488da8
revert 1.141 - the second ffs_truncate() can't really fail
...
requested by hannken@
2016-10-21 19:28:03 +00:00
jdolecek
e1aea9a285
allow also the snapshot_setup()'s call to ffs_truncate() fail, the code
...
should simply reuse the file blocks in that case; also make sure the
ffs_truncate() call is run within transaction if log is on
2016-10-20 20:17:46 +00:00
jdolecek
7470816b2a
add assertion to ensure ffs_cgupdate() is always called from
...
within a WAPBL transaction (if logging is on)
2016-10-20 19:31:32 +00:00
christos
e433d111ad
Grr, the optimizer on mips64 can't handle this... Use MIN_PAGE_SIZE.
2016-10-04 16:46:20 +00:00
christos
44548039a1
use __func__ and print the filesystem we are printing the message for.
2016-10-02 19:02:57 +00:00
jdolecek
16c7d9d735
allocate wapbl dealloc registration structures via pool, so that there is more
...
flexibility with limit handling
2016-10-01 13:15:45 +00:00
jdolecek
8de0ca1330
wapbl_remove_log(): add missing break; harmless, fallthrough just printed
...
extra debug message
2016-10-01 13:06:20 +00:00
jdolecek
9a0d9b14e1
adjust ffs_realloccg() so that the logic about allocating full
...
contiguous block for future fragment expansion doesn't need to
UFS_WAPBL_REGISTER_DEALLOCATION() or ffs_blkfree(); the free blocks
are now immediatelly available for use by the expanding file in further i/o
primary driver is safe removal of the deallocation registration and
hence failure point, but this also fixes degenerate case for wapbl,
and similar also for discard - if the file would be actually expanded
before wapbl commit, or before discard queue would be processed,
the filesystem would not yet see the contiguous free blocks, and
would be forced to allocate another fragment elsewhere
2016-09-25 17:14:59 +00:00
jdolecek
ae4b9ec77b
fix typo in #ifdef notyet part
2016-09-25 11:45:39 +00:00
jdolecek
7b230d53d8
fix swapped KASSERT()
2016-09-24 21:00:54 +00:00
jdolecek
f082cd3f0b
i/o optimization for wapbl flush - only sync superblock and cgs when
...
they were actually changed
2016-09-24 20:59:51 +00:00
christos
7a68f84aa4
put back second strlcpy; pointed out by dholland.
2016-08-25 07:18:35 +00:00
christos
36b34638d9
CID 1371648: off by one in index checking
...
KNF.
2016-08-23 06:40:54 +00:00
christos
9d3a5ca7ac
KNF, no functional change
2016-08-23 06:40:25 +00:00
christos
d7191ea7c2
CID 1371644: use strlcpy, remove dup copy.
2016-08-23 06:24:30 +00:00
christos
67894636ac
CID 1371645: remove dead code
2016-08-23 06:23:26 +00:00
jdolecek
54bc00f99d
fix code which sets REV1 e2fs_fsmnt, set also mount time and mount count
2016-08-20 21:22:25 +00:00
jdolecek
34f2997571
adjust ext2fs_loadvnode_content() to do the sanity checking before allocating
...
memory, and avoid reallocaing memory on vnode reload
2016-08-20 20:05:28 +00:00
jdolecek
fa4a02b45a
modify the comment to note code needs to brele() to have a shot on actually
...
working
2016-08-20 19:53:43 +00:00
jdolecek
cd053bea0c
#if 0 the check for ext2fs_mapsearch() failure (similar what was done
...
for ffs counterpart), it actually never fails, it panics instead
2016-08-20 19:51:50 +00:00
jdolecek
1a50fd75de
add support for GDT_CSUM AKA uninit_bg feature
2016-08-20 19:47:44 +00:00
jdolecek
7546c749f2
whitespace fix
2016-08-20 19:45:20 +00:00
hannken
7139aab724
Remove now obsolete operation vcache_remove().
...
Welcome to 7.99.36
2016-08-20 12:37:06 +00:00
jdolecek
39cc5f5a3f
fix bug introduced in rev 1.82 of ext2fs_lookup.c, when ext2fs_add_entry()
...
was introduced splitting code from ext2fs_direnter() - code used
incorrect new entry size, leading to incomplete entry copy or buffer
overflow; fixed by passing the right size from ext2fs_direnter()
2016-08-19 00:05:43 +00:00
jdolecek
6ab7375654
EXT2F_INCOMPAT_FLEX_BG feature actually doesn't require any explicit
...
code changes, all magic is done by setting the block offsets appropriately
in group descriptors by newfs; add it to the list of supported INCOMPAT flags
2016-08-15 18:46:11 +00:00
jdolecek
a9097f8578
bump link limit to 65000 for files, and add support for EXT2F_ROCOMPAT_DIR_NLINK to make link count unlimited for directories
2016-08-15 18:38:10 +00:00
jdolecek
0471133b8d
adjust ext2fs_makeinode() so that the direnter is optional, use the function (with the direnter off) in ext2fs_mkdir() instead of the code copy; adjust ext2fs_makeinode() to initialize extra_isize and set creation time, if supported by the filesystem
2016-08-15 18:29:34 +00:00
jdolecek
008c8916aa
when converting on-disk direntry, only use the on-disk filetype if the feature flag is present
2016-08-14 11:46:05 +00:00
jdolecek
35875a51bc
switch code to use the EXT2_HAS_{COMPAT|ROCOMPAT|INCOMPAT}_FEATURE() macros instead of open coding the checks
2016-08-14 11:44:54 +00:00
jdolecek
03d15df771
switch ext2fs_htree_has_idx() over to EXT2F_HAS_COMPAT_FEATURE() and remove EXT2F_HAS_COMPAT_FEATURE() - this also fixes it for BE machines, as EXT2F_HAS_COMPAT_FEATURE() did extra byte swap; also remove XXX comment about IN_E3INDEX
2016-08-14 11:42:50 +00:00
jdolecek
6bd2592f36
add EXT2F_HAS_ROCOMPAT_FEATURE() macro, and change the current EXT2F_HAS_{COMPAT|INCOMPAT}_FEATURE() to take fs as first parameter
2016-08-14 11:40:31 +00:00
jdolecek
e393710782
again remove IN_E4EXTENTS; it's not used anywhere any more, and it's better to keep fs-specific flags out of generic headers anyway
2016-08-14 11:31:41 +00:00
jdolecek
437b8a430a
whitespace cleanup
2016-08-14 11:26:35 +00:00
jdolecek
9a22ef9e75
check correct inode extents flag - IN_E4EXTENTS is defined as 0x8000, correct flag EXT2_EXTENTS is 0x80000
2016-08-14 11:25:36 +00:00
christos
01d303e744
KNF, no functional changes...
2016-08-13 07:40:10 +00:00
christos
8378c129b0
sync with hrishi's git
2016-08-13 07:25:29 +00:00
macallan
034ad7ec18
cast pointers to uintptr_t before comparing them, also ()s
...
now this at least compiles
2016-08-12 20:30:15 +00:00
macallan
fd4db18413
sprinkle ()s in macros with comparisons, shuts up compiler warnings
2016-08-12 20:26:15 +00:00
jdolecek
2058250b3f
add support for extended attributes in ext2fs for ext3/ext4; read-only for now
2016-08-12 19:04:03 +00:00
kre
58de1f8cbe
Undo revert now Christos has added the missing glue...
2016-08-09 21:08:02 +00:00
christos
998fd93a6d
merge missing function.
2016-08-09 20:18:08 +00:00
kre
a25bc2ccdc
Revert previous. This work isn't complete enough to include yet,
...
and the build of current really does need to go back to a working state.
2016-08-09 20:03:05 +00:00
kre
09e85cd4b1
Revert previous - which itself (incorrectly) reverted the previous
...
changes, breaking the build.
2016-08-09 13:18:50 +00:00
christos
50b9c754b0
More htree writing support (Hrishikesh Goyal GSoC 2016)
2016-08-09 07:15:35 +00:00
christos
0bed509624
KNF
2016-08-09 06:40:24 +00:00
dholland
96374a6fa7
Remove unused <sys/tree.h>
2016-08-07 05:09:12 +00:00
dholland
23132aeaca
Fix stupid thinko.
2016-08-07 02:42:32 +00:00
dholland
5a9be9571b
comments
2016-08-07 02:31:03 +00:00