#
3d43a905 |
|
30-Aug-2020 |
John Scipione <jscipione@gmail.com> |
bfs: Enable logging on DEBUG build Fix DEBUG build errors by using B_PRI macros in BlockAllocator.cpp, CheckVisitor.cpp, Inode.cpp, Journal.cpp, and kernel_interface.cpp Add optional type parameter from BlockAllocator::IsValidBlockRun() and actually PRINT it, type parameter is already optional on BlockAllocator::CheckBlockRun(). Remove a couple of casts as we are printing the expected type, int32. Cast mode_t to (unsigned int) and use %u because 32-bit Haiku didn't like B_PRIu32. Verified to compile on both regular and DEBUG builds on both 32-bit and 64-bit. Change-Id: I8bb39afd400768b7f69d36384974f0b91b3ef48c Reviewed-on: https://review.haiku-os.org/c/haiku/+/3184 Reviewed-by: Adrien Destugues <pulkomandy@gmail.com> Reviewed-by: John Scipione <jscipione@gmail.com>
|
#
a32381ee |
|
20-Jun-2020 |
Augustin Cavalier <waddlesplash@gmail.com> |
BFS: Fix typo in prior commit.
|
#
93845aec |
|
11-Jun-2020 |
Axel Dörfler <axeld@pinc-software.de> |
block_cache: Change signature of *_etc() functions * This allows file systems to retrieve the actual error code on a failure, and report it to the user. * All affected file systems have been adjusted to the API change. This is a binary incompatible change. Change-Id: Id73392aaf9c6cb7d643ff9adcb8bf80f3037874c Reviewed-on: https://review.haiku-os.org/c/haiku/+/2913 Reviewed-by: Axel Dörfler <axeld@pinc-software.de> Reviewed-by: Adrien Destugues <pulkomandy@gmail.com>
|
#
0bf9e7cb |
|
22-Nov-2019 |
Augustin Cavalier <waddlesplash@gmail.com> |
bfs: Use StackOrHeapArray in Journal::_WriteTransactionToLog(). The number of iovecs is usually < 8 (64 bytes), so this avoids a lot of unnecessary heap traffic. Plus, we don't have to call free() manually anymore.
|
#
14b62ae4 |
|
27-Jul-2019 |
Augustin Cavalier <waddlesplash@gmail.com> |
BFS: Make the log-flusher thread persistent. Previously, a new log-flush thread was created every time there was an idle transaction. Now we just release a semaphore for an already-existing thread. Change-Id: If788dbe17ef8e069ce12aa7b778626d051cce2d0
|
#
0ec6ced1 |
|
07-Aug-2012 |
ahenriksson <sausageboy@gmail.com> |
bfs: Flush transactions with no blocks in _FlushLog() Since the file system resizing code must reinitialize the block cache, it is necessary that it is completely empty. Change-Id: If0df9f8c003edb4ccc65c4b42940512400f8598c Reviewed-on: https://review.haiku-os.org/c/921 Reviewed-by: waddlesplash <waddlesplash@gmail.com>
|
#
add77fd6 |
|
12-Jan-2017 |
Axel Dörfler <axeld@pinc-software.de> |
bfs: The disk clean/dirty flags were written with host endian. * Not crucial, though, as this field is not actually used for anything.
|
#
de9c0613 |
|
03-Jul-2014 |
Axel Dörfler <axeld@pinc-software.de> |
bfs: Use the QueryParserUtils instead of its own copy. * Ingo copied the methods into a shared location, and then obviously "forgot" to let BFS use them. As a side note for Ingo: the complete error GCC reported was "std::fssh_size_t" not defined with the macro wrapper as code location. The actual problem was a "using std::size_t" in some C++ header that accidentally got included after the wrapper. * The shared Query code is not yet used. That'll be done another time. * Renamed BFS_SHELL define to FS_SHELL, such that QueryParserUtils can be used in any file system shell, not just the bfs_shell.
|
#
a1566b06 |
|
06-May-2013 |
Axel Dörfler <axeld@pinc-software.de> |
bfs: removed kernel_cpp.h's new operator. * This fixes bug #9715 from the POV of BFS, ie. the new operator seems to call the constructor on a NULL object on failure.
|
#
46cf7a5a |
|
14-Nov-2012 |
Przemysław Buczkowski <przemub@yahoo.pl> |
Fix typos: super block -> superblock (#8974) Signed-off-by: Przemysław Buczkowski <przemub@yahoo.pl> Signed-off-by: Matt Madia <mattmadia@gmail.com>
|
#
267b6463 |
|
12-Sep-2012 |
Axel Dörfler <axeld@pinc-software.de> |
Run the transaction flusher in another thread. * This fixes bug #8977.
|
#
1c24ebaa |
|
22-Jul-2012 |
Alex Smith <alex@alex-smith.me.uk> |
64-bit compilation fixes for BFS, add to x86_64 boot image.
|
#
fd91cf4d |
|
16-Feb-2010 |
Axel Dörfler <axeld@pinc-software.de> |
* Replaced the specialized inode in transaction mechanism with a generic one. That costs 12 more bytes per inode on 32 bit platforms, though. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@35491 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
8859eeab |
|
24-Nov-2009 |
Ingo Weinhold <ingo_weinhold@gmx.de> |
Replaced "%Ld" and "%lld" in printf()s by the new B_PRI* macros to avoid warnings when building with a 64 bit compiler. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@34216 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
73a19dfe |
|
04-Nov-2009 |
Axel Dörfler <axeld@pinc-software.de> |
* Nested transactions didn't really work in combination with the separate transaction mechanism. Now we keep track of the parent transactions, and restore fOwner on Journal::Unlock(). * This closes bug #4155 again. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@33883 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
bce831ef |
|
10-Aug-2009 |
Axel Dörfler <axeld@pinc-software.de> |
* Don't reset fSeparateSubTransactions but restore its previous value. This fixes bug #4201. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@32227 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
0f779d49 |
|
29-Jul-2009 |
Axel Dörfler <axeld@pinc-software.de> |
* Transaction::UnlockInodes() may start a new transaction, but we cannot reuse the one just closed anymore. The fSeparateSubTransactions mechanism should make sure that this won't happen. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@31954 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
65e04b05 |
|
29-Jul-2009 |
Axel Dörfler <axeld@pinc-software.de> |
* When a reentered fs function reuses a transaction of its caller, the Transaction::UnlockInodes() method was never called, leading to bug #4155. * In order to make sure that inodes are still going to be reverted, we actually need to move them into the parent transaction which we now do. This should fix #4155. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@31952 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
dd825d55 |
|
29-Jul-2009 |
Axel Dörfler <axeld@pinc-software.de> |
* The inode list link was supposed to be secured by the journal log - so it was definitely not a good idea to move _UnlockInodes() after the Journal::Unlock() call (which was done to achieve a revertable inode). * Instead, Journal::Unlock() is now responsible for calling the now public Transaction::UnlockInodes(), and always does this at the right time while holding the journal log. * While I don't understand how #4155 can happen, this bug should be the one that caused it. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@31944 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
1857ae60 |
|
29-Jul-2009 |
Axel Dörfler <axeld@pinc-software.de> |
* Let the transaction abort that caused the transaction to get too large. This fixes that the next action failed after the problem. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@31928 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
4e643107 |
|
28-Jul-2009 |
Axel Dörfler <axeld@pinc-software.de> |
* Some preparations to be able to split transactions if they become too large for the log. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@31860 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
0bad8397 |
|
28-Jul-2009 |
Axel Dörfler <axeld@pinc-software.de> |
* When aborting a transaction, we also need to revert any changes made to the cached bfs_inode of all changes inodes. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@31859 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
85c5c0b4 |
|
28-Jul-2009 |
Axel Dörfler <axeld@pinc-software.de> |
* We need to reset fUnwrittenTransactions when we abort a transaction without a sub transaction, or else we would try to continue using it. * It doesn't make any sense to increase fUnwrittenTransactions when _WriteTransactionToLog() failed. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@31857 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
2a3a8bfa |
|
28-Jul-2009 |
Axel Dörfler <axeld@pinc-software.de> |
* Journal::_WriteTransactionToLog()'s return value was ignored previously, leading BFS to report success on actually failed transactions. Those transactions were even kept open, leading to a panic when starting the next transaction. * Transaction::Done() now returns a status - currently, this is only handled correctly where this is likely to happen without a disk fault, ie. if the transaction was too large to be written back safely. * Improved "bfs_journal" command output. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@31850 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
66ae5b2d |
|
26-Jun-2009 |
Axel Dörfler <axeld@pinc-software.de> |
* The block allocator will no longer try to fix a missing allocation on a read-only volume. This fixes bug #3432. * Journal::ReplayLog() will now return an error on a read-only device, rendering read-only dirty volumes unmountable. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@31255 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
24b822d8 |
|
17-Apr-2009 |
Axel Dörfler <axeld@pinc-software.de> |
* No longer hold the write lock when calling Inode::FillGapWithZeros(), as this potentially deadlocks as described in bug #3768. The system is still completely unresponsive, but gets back to a working state after some time now. * Since the rw_lock is public, Transaction and InodeReadLocker no longer need to be friends with Inode. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@30221 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
992fba36 |
|
16-Apr-2009 |
Axel Dörfler <axeld@pinc-software.de> |
* There is now a list of removed vnodes in Volume - while asking the VFS for this seemed to be a good idea, there is one race condition that cannot be solved otherwise (the vnode must be added/removed to that list while holding the transaction lock, and we cannot guarantee that in the VFS). * We are using an unused area of the in-memory bfs_inode to store the list links (bfs_inode::pad - this will also work on 64 bit platforms). * Inode no longer adds a singly linked list link - the transaction list now shares the doubly linked list with the removed vnodes list. * Added an in-memory flag INODE_IN_TRANSACTION to avoid searching an inode to be added in the list. * Removing an attribute directory did not hold its write lock. * If removing an attribute failed for some reason, the INODE_DELETED flag was not removed (the transaction would not have failed because of that). git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@30203 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
41a6cf82 |
|
12-Mar-2009 |
Axel Dörfler <axeld@pinc-software.de> |
* The InodeAllocator must remove the inode from the transaction before deleting it, otherwise the transaction would access already freed memory when trying to release its write lock of the inode. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@29481 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
44e4ddfd |
|
03-Nov-2008 |
Axel Dörfler <axeld@pinc-software.de> |
* "checkfs" would run into a panic (transaction still open) when trying to write back the bitmap. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@28478 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
6c3348f1 |
|
01-Nov-2008 |
Axel Dörfler <axeld@pinc-software.de> |
* The check mechanism in the block allocator now locks the journal as well to fix a potential deadlock. * Journal::Lock() now accepts another parameter that specified whether child transactions should be split - this is nothing you would want in normal operation unless the parent transaction is only there to prevent others from writing (such as with the block allocator check stuff). git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@28438 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
e6679f9d |
|
07-Aug-2008 |
Axel Dörfler <axeld@pinc-software.de> |
* Since we're using ASSERT macros, still lock/unlock the nodes when initializing the file system. * This fixes bug #2580. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26865 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
02c8f6c8 |
|
02-Aug-2008 |
Axel Dörfler <axeld@pinc-software.de> |
* Coding style cleanups, no functional changes. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26728 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
2e3477e3 |
|
31-Jul-2008 |
Axel Dörfler <axeld@pinc-software.de> |
* Changed the inode write locking to be held as long as the transaction is running - this fixes several cases where someone could see outdated data when a transaction had to be reverted (the time between unlocking the inode and actually reverting the blocks). For that, Inodes can now be put into a singly linked list. * Added a TODO in Inode::WriteAt() which explains why it cannot use the above method: seems that our VFS/VM locking model isn't really that good. * Fixed a possible deadlock in Attribute::_Truncate() where the inode write lock was held before starting the transaction. * Added an InodeReadLocker convenience class, that should be used instead of ReadLocker - Inode::Lock() only still exists because of the needs of bfs_io(). * Moved the bfs_io() callback hooks out of the exported module API region, and removed their bfs_ prefix. * Added a Volume::IsInitializing() method that should be used rather than checking if Volume::ID() is >= 0. * Removed the MultiInodeLocker again, as it's pretty much superfluous now. * Moved openModeToAccess() to the Utility.h header. * Minor cleanup. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26715 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
03fa417b |
|
07-Jul-2008 |
Axel Dörfler <axeld@pinc-software.de> |
* Removed the home-brewn locking classes in BFS besides the read/write lock (for now). * Inode::fSmallDataLock is now a recursive_lock, Journal::fLock is now a recursive_lock, too, Journal::fEntriesLock is now a mutex, as is BPlusTree::fIteratorLock. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26298 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
8e8edffc |
|
29-Apr-2008 |
Axel Dörfler <axeld@pinc-software.de> |
* Fixed at least the "dd" part of bug #2148: the second double indirect array block would be incorrectly addressed when allocating a stream - this could cause random blocks to be overwritten, and therefore could cause many sorts of problems. * Moved BFS_TRACING macro to the tracing_config.h file, and let it follow the new semantics of those other macros in there. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@25249 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
8b5e5656 |
|
06-Apr-2008 |
Axel Dörfler <axeld@pinc-software.de> |
* BFS now panics if cache_sync_transaction() didn't free the space needed, instead of writing over the old log entries. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24856 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
797a92d8 |
|
07-Apr-2008 |
Axel Dörfler <axeld@pinc-software.de> |
* Made super block log handling endian-safe. * Made all debugging functions endian-safe. * Added tracing for log entries. * Added new KDL command "bfs_journal" to dump all pending log entries. * When BFS_DEBUGGER_COMMANDS is defined, the LogEntry class will also track the transaction ID it belonged to. * The "bfs" KDL command now sets some useful debugger variables. * The "bfs_allocator" KDL command now accepts the group index as 3rd argument. * Renamed Journal::_TransactionListener() to _TransactionIdle(), as that's all it is for. * Removed TODO comment in Volume::WriteSuperBlock(), as it's actually not true. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24852 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
64b7ef1d |
|
04-Apr-2008 |
Axel Dörfler <axeld@pinc-software.de> |
* As briefly discussed in ticket #2024, I've changed BFS to allow to mount volumes with a broken log. It will only allow the volume read-only then, though (unlike Be's BFS), as your disk could be corrupt. * Added InitCheck() method to the RecursiveLock class, and now only check this one in Journal::InitCheck() instead of also replaying the log there; this is now done directly in Volume::Mount(). git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24795 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
0bb7a9c0 |
|
04-Apr-2008 |
Axel Dörfler <axeld@pinc-software.de> |
* Journal::_TransactionWritten() updated Volume::LogStart() before it actually wrote the super block, so there was a race condition with what _WriteTransactionToLog() assumed was already written there (if it managed to write the log entry before the super block was written by _TransactionWritten(), and a reboot happened just then, the log start could point to an invalid log entry). Not very likely, but it could happen. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24791 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
e63c1170 |
|
03-Apr-2008 |
Axel Dörfler <axeld@pinc-software.de> |
Looks like some bloke forgot to commit *some* files that should have been part of r24768 (block cache notification mechanism rewrite). Thanks for the note, Vasilis! git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24772 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
12952edd |
|
02-Apr-2008 |
Axel Dörfler <axeld@pinc-software.de> |
* Quick fix for a possible deadlock I introduced with the block_cache idle notification. We should rework the cache notifications to work asynchronously. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24752 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
3c78c045 |
|
02-Apr-2008 |
Axel Dörfler <axeld@pinc-software.de> |
Resolved a TODO in Journal::Lock() that Urias reminded me about: * BFS now uses a transaction listener that flushes the current transaction in case it is idle; before, transactions would always be kept open when they weren't large, so that the block writer could not write back the blocks (they were busy from its POV). * This solves the described problem of the screen resolution not being written back even after minutes of inactivity. * Renamed _TransactionNotify() to _TransactionWritten() to differentiate it a bit more from the new _TransactionListener(). git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24738 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
98e10fd4 |
|
25-Mar-2008 |
Axel Dörfler <axeld@pinc-software.de> |
* _TransactionSize() did not take the block array into account. * Therefore, the log was not flushed often enough: _WriteTransactionToLog() did not check again, and would eventually overwrite incomplete transactions (leading to a corrupted log on reboot)! * _TransactionDone() now only flushes the log if the new transaction will be joined; _WriteTransactionToLog() now checks itself if there is enough space left to actually write the log entry. * Added a TODO about the logging code not being endian-aware. * Renamed _BlockNotify() to _TransactionNotify() as only complete transactions are notified, it's not working on block level anymore. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24577 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
d89cda9f |
|
16-Mar-2008 |
Axel Dörfler <axeld@pinc-software.de> |
* Fixed another big bug in the logging code: I obviously got confused what RunArrays::Length() meant; it should have been the length of a log entry, but was only the block count. * Now I've improved naming and fixed initializing the LogEntry with a wrong size, causing subsequent log entries to lose track in the log (the log_start pointer got wrong, so BFS would not be able to replay such a log). * This at least fixes one part of the problem of bug #1911. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24410 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
772506f8 |
|
15-Mar-2008 |
Axel Dörfler <axeld@pinc-software.de> |
Divided the _ReplayRunArray() method into two passes: first, the integrity of the blocks in the log entry will be checked, and only if this passed, all log entries are written back together; if the whole run array contained bad data, it's no longer written to disk at all if it's detectable. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24402 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
f4260712 |
|
15-Mar-2008 |
Axel Dörfler <axeld@pinc-software.de> |
* For whatever weird reason, BFS apparently restricts a log entry to 126 entries, even though many more could fit in the blog. This fixes mounting a dirty (original-)BFS volume with a block size larger than 1024 bytes, and probably vice versa. * Minor cleanup. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24401 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
0dc57dbe |
|
12-Mar-2008 |
Axel Dörfler <axeld@pinc-software.de> |
The log replay code now checks if a super block is valid before the current one gets overwritten; if the log contains invalid data, it will no longer render the whole disk unreadable. This should have helped to prevent bug #1911 (but of course the problem that there is invalid data in the log in the first place remains). git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24381 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
5d43cf2a |
|
19-Jan-2008 |
Axel Dörfler <axeld@pinc-software.de> |
* Added new debugger commands bfs_btree_header and bfs_btree_node that dump a B+tree header resp. node. * Use dprintf() when a transaction is too large instead of a panic; even though the file system has to revert the transaction, it's not lethal, and it does not corrupt your disk. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@23653 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
4a553d36 |
|
19-Jan-2008 |
Axel Dörfler <axeld@pinc-software.de> |
Forgot to update logStart after every written array - this caused old entries (that were part of the same transaction) to be overwritten. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@23642 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
ae16ab9d |
|
19-Jan-2008 |
Axel Dörfler <axeld@pinc-software.de> |
* When I ported over BFS to the new FS API, I pretty much toasted the logging code: - The vec array to contain the block list and the index block was one entry to small. - But that didn't really matter, as RunArrays/run_array was broken and never put anything into the log; we only ever wrote index headers. BFS would totally screw up the disk when trying to replay the log (even though the replay code itself was and is working fine). - If a log entry ended at the end of the log area, BFS could overwrite the first block after the log with the next entry. * run_array now adopt the sorting stuff from the sorted_array. Blocks in the log are now always sorted. * Added TODO item to sorted_array as it's not endian safe (will only work correctly when BFS is used in the native endian). * Minor cleanup. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@23638 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
5d0afa4e |
|
18-Jan-2008 |
Axel Dörfler <axeld@pinc-software.de> |
* cache_detach_sub_transaction() didn't really work: it did not put all needed blocks into the new transaction, but it would set that transaction on all blocks of the old transaction, too. Also, it did not correctly update the num_blocks/sub_num_blocks fields of the old transaction. Even worse, it did return B_OK instead of the ID of the new transaction... * get_writable_cached_block() did not correctly maintain the number of blocks in the sub transaction. * write_cached_block() did not free the original_data of a block when it wrote it back as part of a previous transaction. * Changed "cookie" for cache_next_block_in_transaction() to "long", so it will be 64 bits when needed. * Improved the API for detaching sub transactions: you can now get the blocks of only the main (parent) transaction as well, added new cache_block_in_main_transaction() function. * BFS now flushes the log when there is no space left for the current transaction. * _WriteTransactionToLog() allocated a "vecs" array, but never freed it. * _WriteTransactionToLog() now also supports detaching the current sub transaction if the whole thing is getting too large (it will now also panic if that doesn't work out). * Removed a useless optimization: making the blocks available in the cache isn't really needed, as all blocks in a transaction are locked into the cache, anyway. * Implemented Transaction::WriteBlocks(). * Minor cleanup, removed some dead code, fixed warnings in the fs_shell's block_cache when compiled with debug output on. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@23610 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
4fc4f2c8 |
|
13-Jan-2008 |
Axel Dörfler <axeld@pinc-software.de> |
* Added a transaction listener mechanism to be notified when a transaction ends or has been aborted. * BFS now listens for transactions when it created an inode to see if the transaction will be aborted without freeing the inode (in which case it will panic for now). * Started implementing tracing support, but it's not working yet. * Minor cleanup. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@23492 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
d1ba9c8a |
|
12-Jan-2008 |
Axel Dörfler <axeld@pinc-software.de> |
Fixed warnings when building the bfs_shell. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@23462 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
4afaeabb |
|
02-Dec-2007 |
Axel Dörfler <axeld@pinc-software.de> |
* bfs_free_cookie() accidently reverted a transaction after having updated the inode's internal last modified and size copies, causing in inconsistent data. This fixes #1643. * The block being replayed are now dumped to the debug output. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@23050 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
6edf637b |
|
11-Nov-2007 |
Axel Dörfler <axeld@pinc-software.de> |
Minor cleanup. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@22896 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
c391f84b |
|
26-Apr-2007 |
Ingo Weinhold <ingo_weinhold@gmx.de> |
* Prepared the BFS sources to be used with the new FS shell: - Moved all inclusions of system headers into a new system_dependencies.h header, which conditionally either includes these or the FS shell headers. - Fixed compiler warnings related to printf-like functions (int32 is int, not long on non-BeOS platforms). * Build a new bfs_shell. Compiles and links, but does nothing ATM. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@20860 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
eeb28bb7 |
|
03-Jun-2006 |
Axel Dörfler <axeld@pinc-software.de> |
Some more PPC fixes. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@17714 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
57808587 |
|
28-Feb-2006 |
Axel Dörfler <axeld@pinc-software.de> |
Fixed warning when build with DEBUG=1. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@16554 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
923e3aaf |
|
21-Jan-2006 |
Axel Dörfler <axeld@pinc-software.de> |
Fixed two crucial bugs: * When aborting the first sub-transaction, BFS didn't recognize this correctly, and aborted it via cache_abort_transaction() instead of cache_abort_sub_transaction() - that not only reversed the whole transaction, but also let subsequent cache_start_sub_transaction() fail (as there was no transaction to continue anymore). Reported in a reproducible way by Jerome Duval. * Haiku didn't want to replay logs anymore - the off-by-one fix I did in r14428 was not complete, it only let Be's BFS replay our logs, but our's rejected them afterwards. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@16018 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
9ebc6e3c |
|
20-Oct-2005 |
Axel Dörfler <axeld@pinc-software.de> |
Added a comment on what kind of functionality we need from the caching layer one day. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@14442 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
cb6d675c |
|
19-Oct-2005 |
Axel Dörfler <axeld@pinc-software.de> |
Aborting transactions doesn't change the number of unwritten transactions - that counter does not take the current transaction into account. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@14434 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
9a99234b |
|
19-Oct-2005 |
Axel Dörfler <axeld@pinc-software.de> |
Implemented basic sub transaction support - seems to work so far, but I haven't tested it heavily yet. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@14432 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
bd0b075c |
|
19-Oct-2005 |
Axel Dörfler <axeld@pinc-software.de> |
Now takes the off-by-one error in Be's BFS implemenation into account, too. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@14428 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
e620c932 |
|
18-Oct-2005 |
Axel Dörfler <axeld@pinc-software.de> |
Argl, turns out Be's replay log routine cannot handle block_runs with a size unequal 1 - IOW using block_runs here is completely bogus. Crippled our code to not create longer block_runs - at least, a dirty BFS image is now a dirty BFS image - you can mount a dirty image on either system and it will work :-) The R5 version of our BFS is still incompatible though - ie. running bfs_shell or copy_to_bfs_image on a dirty image will still potentially corrupt it. Maybe I'll even port the changes over one day... git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@14418 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
a59b9aff |
|
18-Oct-2005 |
Axel Dörfler <axeld@pinc-software.de> |
Rewrote the log entry writing so that it should be BFS compatible - not yet tested for compatibility, though! Writing is now combined into a few writev_pos() function calls to speed up log writing. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@14415 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
c0614f32 |
|
30-Jun-2005 |
Axel Dörfler <axeld@pinc-software.de> |
Ported r13366 back from the R5 BFS to the Haiku BFS: fixed bad bug in the journaling code, the super block log data could have been wrong. Moved the doubly linked list code to the kernel's util/DoublyLinkedList.h. Also removed Journal::fCurrent, as it's not really used. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@13367 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
1c12a6a3 |
|
08-Jun-2005 |
Axel Dörfler <axeld@pinc-software.de> |
Inode::ShrinkStream() now evaluates the return values from some functions - dunno if that's a good idea (it may still be a good idea to succeed for shrinking the stream, even if not everything worked), but it looks better :-) Improved debug output in case TrimPreallocation() fails. Journal::FlushLogAndBlocks() no longer ends the current transaction if called from within an ongoing transaction. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@13019 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
2dbdc141 |
|
30-May-2005 |
Axel Dörfler <axeld@pinc-software.de> |
Transactions can now be nested (bfs_release_vnode() actually did that before, but that was not working correctly): only the owning transaction (the one that came first) can now end a transaction. To do: if the owning transaction fails, it should actually not abort the transaction in case there were sub transactions, but does so right now (should do no harm, eventually file data is not freed as it should). git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@12913 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
5692a950 |
|
30-May-2005 |
Axel Dörfler <axeld@pinc-software.de> |
We don't stack transactions together, so we need to end each transaction, even if empty. Added some more debug output. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@12904 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
23b6e06a |
|
02-Mar-2005 |
Axel Dörfler <axeld@pinc-software.de> |
While the block list was written sorted to the log, the blocks were in transaction order which caused corrupted disks when a log was replayed. git-svn-id: file:///srv/svn/repos/haiku/trunk/current@11539 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
92a076fc |
|
22-Nov-2004 |
Axel Dörfler <axeld@pinc-software.de> |
Journal::FlushLogAndBlocks() no longer uses Journal::Lock() but the lock directly. That avoids starting a new transaction for no reason (which wouldn't do any harm, but still, it's not necessary to do that at all). log_entry::cached_blocks is no longer maintained or needed. git-svn-id: file:///srv/svn/repos/haiku/trunk/current@10185 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
fb02804a |
|
19-Nov-2004 |
Axel Dörfler <axeld@pinc-software.de> |
Big update while moving over completely to the Haiku kernel: - Ported over BFS to the new cache API - Inode no longer inherits from CachedBlock, and therefore, no longer keeps the whole inode block in memory. It now has a copy of the bfs_inode structure in memory instead. This has a number of advantages but also some disadvantages, so it might be reverted later, even if it's unlikely. - Added a NodeGetter class that can be used whenever the real block needs to be accessed (ie. for attributes) - Changed *transaction to &transaction where possible - Removed support for KEEP_WRONG_DIRENT_RECLEN - Removed support for uncached file access since that's no longer needed - Fixed some endian issues in bfs_write_stat() - Removed the install BFS rules, since they don't make any sense anymore (unless you are running Haiku ;-)) Note, logged streams are not supported anymore right now. Also, the transaction code is pretty simple and slow - it will be improved later on. Attribute code is pretty much untested in the new environment. git-svn-id: file:///srv/svn/repos/haiku/trunk/current@10053 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
dca5d901 |
|
07-Jun-2004 |
Axel Dörfler <axeld@pinc-software.de> |
Added missing include. git-svn-id: file:///srv/svn/repos/haiku/trunk/current@7820 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
feec20d6 |
|
07-May-2004 |
Axel Dörfler <axeld@pinc-software.de> |
It's now <util/kernel_cpp.h> rather than <kernel_cpp.h>. Forgot to commit that... git-svn-id: file:///srv/svn/repos/haiku/trunk/current@7442 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
a49b150f |
|
27-Jan-2004 |
Axel Dörfler <axeld@pinc-software.de> |
Removed the fOwningThread functionality from the Journal class; it now just uses a RecursiveLock instead. Changed Journal::CurrentTransaction() so that it returns the current transaction only if it's valid for the thread asking for it. That doesn't fix the bug, but changed its timing a bit. git-svn-id: file:///srv/svn/repos/haiku/trunk/current@6356 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
54343bbc |
|
25-Jan-2004 |
Axel Dörfler <axeld@pinc-software.de> |
Switched to kernel_cpp.h/cpp. git-svn-id: file:///srv/svn/repos/haiku/trunk/current@6291 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
1a49a098 |
|
07-Nov-2003 |
Nathan Whitehorn <nwhitehorn@nowhere.fake> |
Bunches of changes to make mwcc like the code. I also coded an _atomic_set() and _atomic_test_and_set() for PowerPC. Of course, there's already one in the kernel tree, but mine's better. :P Now builds (and works, after a fashion) on R5 PowerPC. git-svn-id: file:///srv/svn/repos/haiku/trunk/current@5280 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
24d6529a |
|
27-May-2003 |
Axel Dörfler <axeld@pinc-software.de> |
Journal::LogBlocks() now calls cache_write() if the block is already in the log entry - this is only necessary if the buffer is not the one of the CachedBlock object. Journal::TransactionDone() now properly aborts transactions if possible, instead of just writing them to disk (does only work if the log entry was not used by other transactions already). Added a comment about how to speed up writing the log entries a bit more (though it's not so easy to do, and might not be much faster). git-svn-id: file:///srv/svn/repos/haiku/trunk/current@3362 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
98b972c9 |
|
25-Feb-2003 |
Axel Dörfler <axeld@pinc-software.de> |
Fixed all warnings that appeared with DEBUG=1 set. Also fixed missing return codes in BufferPool::ReleaseBuffer() and Journal::WriteLogEntry(). git-svn-id: file:///srv/svn/repos/haiku/trunk/current@2845 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
ceeb00d4 |
|
24-Feb-2003 |
Axel Dörfler <axeld@pinc-software.de> |
Fixed a possibly crashing bug (missing strerror() with %s format). Fixed many warnings (due to -Wall). Some style cleanups. git-svn-id: file:///srv/svn/repos/haiku/trunk/current@2843 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
c42ee134 |
|
07-Aug-2002 |
Axel Dörfler <axeld@pinc-software.de> |
Initial revision git-svn-id: file:///srv/svn/repos/haiku/trunk/current@639 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
de9c0613398645390b8d450089051b2888e2e15b |
|
03-Jul-2014 |
Axel Dörfler <axeld@pinc-software.de> |
bfs: Use the QueryParserUtils instead of its own copy. * Ingo copied the methods into a shared location, and then obviously "forgot" to let BFS use them. As a side note for Ingo: the complete error GCC reported was "std::fssh_size_t" not defined with the macro wrapper as code location. The actual problem was a "using std::size_t" in some C++ header that accidentally got included after the wrapper. * The shared Query code is not yet used. That'll be done another time. * Renamed BFS_SHELL define to FS_SHELL, such that QueryParserUtils can be used in any file system shell, not just the bfs_shell.
|
#
a1566b06b7b53d14fa53c169b0989925c54fd69d |
|
06-May-2013 |
Axel Dörfler <axeld@pinc-software.de> |
bfs: removed kernel_cpp.h's new operator. * This fixes bug #9715 from the POV of BFS, ie. the new operator seems to call the constructor on a NULL object on failure.
|
#
46cf7a5a73679c6e4fde91710e4a4885242e49d1 |
|
14-Nov-2012 |
Przemysław Buczkowski <przemub@yahoo.pl> |
Fix typos: super block -> superblock (#8974) Signed-off-by: Przemysław Buczkowski <przemub@yahoo.pl> Signed-off-by: Matt Madia <mattmadia@gmail.com>
|
#
267b64639698c8aaca919137b8d65803abc1b026 |
|
12-Sep-2012 |
Axel Dörfler <axeld@pinc-software.de> |
Run the transaction flusher in another thread. * This fixes bug #8977.
|
#
1c24ebaa5fdc1d07cd40a296c59463c9477b8fbd |
|
22-Jul-2012 |
Alex Smith <alex@alex-smith.me.uk> |
64-bit compilation fixes for BFS, add to x86_64 boot image.
|
#
fd91cf4d189f91ecca91e6704796beeeee692cb5 |
|
16-Feb-2010 |
Axel Dörfler <axeld@pinc-software.de> |
* Replaced the specialized inode in transaction mechanism with a generic one. That costs 12 more bytes per inode on 32 bit platforms, though. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@35491 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
8859eeab5349da39ee9972ee0943919740754b77 |
|
24-Nov-2009 |
Ingo Weinhold <ingo_weinhold@gmx.de> |
Replaced "%Ld" and "%lld" in printf()s by the new B_PRI* macros to avoid warnings when building with a 64 bit compiler. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@34216 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
73a19dfe5d66e0cc860d4ab24868284571b0bf5b |
|
04-Nov-2009 |
Axel Dörfler <axeld@pinc-software.de> |
* Nested transactions didn't really work in combination with the separate transaction mechanism. Now we keep track of the parent transactions, and restore fOwner on Journal::Unlock(). * This closes bug #4155 again. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@33883 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
bce831ef4a524e13b93c684dacefa2f157e923c9 |
|
10-Aug-2009 |
Axel Dörfler <axeld@pinc-software.de> |
* Don't reset fSeparateSubTransactions but restore its previous value. This fixes bug #4201. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@32227 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
0f779d495becbe2d53f15faca15249defc71eb77 |
|
29-Jul-2009 |
Axel Dörfler <axeld@pinc-software.de> |
* Transaction::UnlockInodes() may start a new transaction, but we cannot reuse the one just closed anymore. The fSeparateSubTransactions mechanism should make sure that this won't happen. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@31954 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
65e04b057d095e47f9f132d726c9a5d3bac19bad |
|
29-Jul-2009 |
Axel Dörfler <axeld@pinc-software.de> |
* When a reentered fs function reuses a transaction of its caller, the Transaction::UnlockInodes() method was never called, leading to bug #4155. * In order to make sure that inodes are still going to be reverted, we actually need to move them into the parent transaction which we now do. This should fix #4155. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@31952 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
dd825d55562bcd6eb9f1d5dae3cb11adddbdff10 |
|
29-Jul-2009 |
Axel Dörfler <axeld@pinc-software.de> |
* The inode list link was supposed to be secured by the journal log - so it was definitely not a good idea to move _UnlockInodes() after the Journal::Unlock() call (which was done to achieve a revertable inode). * Instead, Journal::Unlock() is now responsible for calling the now public Transaction::UnlockInodes(), and always does this at the right time while holding the journal log. * While I don't understand how #4155 can happen, this bug should be the one that caused it. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@31944 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
1857ae604efbefed140b3ef1574587614a8a2786 |
|
29-Jul-2009 |
Axel Dörfler <axeld@pinc-software.de> |
* Let the transaction abort that caused the transaction to get too large. This fixes that the next action failed after the problem. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@31928 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
4e6431078812df05c84361aee80e27d458589cc5 |
|
28-Jul-2009 |
Axel Dörfler <axeld@pinc-software.de> |
* Some preparations to be able to split transactions if they become too large for the log. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@31860 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
0bad8397020c9c2e5b7b4be04497a7b8b34d87f9 |
|
28-Jul-2009 |
Axel Dörfler <axeld@pinc-software.de> |
* When aborting a transaction, we also need to revert any changes made to the cached bfs_inode of all changes inodes. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@31859 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
85c5c0b4d015b073a2b3e6ecf3404acaf1524b30 |
|
28-Jul-2009 |
Axel Dörfler <axeld@pinc-software.de> |
* We need to reset fUnwrittenTransactions when we abort a transaction without a sub transaction, or else we would try to continue using it. * It doesn't make any sense to increase fUnwrittenTransactions when _WriteTransactionToLog() failed. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@31857 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
2a3a8bfa9a0be87bead347e50959f9a67534bc55 |
|
28-Jul-2009 |
Axel Dörfler <axeld@pinc-software.de> |
* Journal::_WriteTransactionToLog()'s return value was ignored previously, leading BFS to report success on actually failed transactions. Those transactions were even kept open, leading to a panic when starting the next transaction. * Transaction::Done() now returns a status - currently, this is only handled correctly where this is likely to happen without a disk fault, ie. if the transaction was too large to be written back safely. * Improved "bfs_journal" command output. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@31850 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
66ae5b2d993e457764f5c72d2ea9ea604068187f |
|
26-Jun-2009 |
Axel Dörfler <axeld@pinc-software.de> |
* The block allocator will no longer try to fix a missing allocation on a read-only volume. This fixes bug #3432. * Journal::ReplayLog() will now return an error on a read-only device, rendering read-only dirty volumes unmountable. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@31255 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
24b822d843be9b891e7e9ebba99741b65e89647d |
|
17-Apr-2009 |
Axel Dörfler <axeld@pinc-software.de> |
* No longer hold the write lock when calling Inode::FillGapWithZeros(), as this potentially deadlocks as described in bug #3768. The system is still completely unresponsive, but gets back to a working state after some time now. * Since the rw_lock is public, Transaction and InodeReadLocker no longer need to be friends with Inode. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@30221 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
992fba36eef8b17808a06d483f2fdad90173b01d |
|
16-Apr-2009 |
Axel Dörfler <axeld@pinc-software.de> |
* There is now a list of removed vnodes in Volume - while asking the VFS for this seemed to be a good idea, there is one race condition that cannot be solved otherwise (the vnode must be added/removed to that list while holding the transaction lock, and we cannot guarantee that in the VFS). * We are using an unused area of the in-memory bfs_inode to store the list links (bfs_inode::pad - this will also work on 64 bit platforms). * Inode no longer adds a singly linked list link - the transaction list now shares the doubly linked list with the removed vnodes list. * Added an in-memory flag INODE_IN_TRANSACTION to avoid searching an inode to be added in the list. * Removing an attribute directory did not hold its write lock. * If removing an attribute failed for some reason, the INODE_DELETED flag was not removed (the transaction would not have failed because of that). git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@30203 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
41a6cf82b37f3225a11c11c8f74f3e9f8193e954 |
|
12-Mar-2009 |
Axel Dörfler <axeld@pinc-software.de> |
* The InodeAllocator must remove the inode from the transaction before deleting it, otherwise the transaction would access already freed memory when trying to release its write lock of the inode. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@29481 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
44e4ddfdc13060d3340f8d24477ff1029db30336 |
|
03-Nov-2008 |
Axel Dörfler <axeld@pinc-software.de> |
* "checkfs" would run into a panic (transaction still open) when trying to write back the bitmap. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@28478 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
6c3348f1cd611725029432cd0cb8c35a7e2e5924 |
|
01-Nov-2008 |
Axel Dörfler <axeld@pinc-software.de> |
* The check mechanism in the block allocator now locks the journal as well to fix a potential deadlock. * Journal::Lock() now accepts another parameter that specified whether child transactions should be split - this is nothing you would want in normal operation unless the parent transaction is only there to prevent others from writing (such as with the block allocator check stuff). git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@28438 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
e6679f9d0da980ecb1c893af3a54844e752636cf |
|
07-Aug-2008 |
Axel Dörfler <axeld@pinc-software.de> |
* Since we're using ASSERT macros, still lock/unlock the nodes when initializing the file system. * This fixes bug #2580. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26865 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
02c8f6c89d13b94c5507012eaadddc79982c976f |
|
02-Aug-2008 |
Axel Dörfler <axeld@pinc-software.de> |
* Coding style cleanups, no functional changes. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26728 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
2e3477e3d851cc46fa682712c3f73dbb82d64fd9 |
|
31-Jul-2008 |
Axel Dörfler <axeld@pinc-software.de> |
* Changed the inode write locking to be held as long as the transaction is running - this fixes several cases where someone could see outdated data when a transaction had to be reverted (the time between unlocking the inode and actually reverting the blocks). For that, Inodes can now be put into a singly linked list. * Added a TODO in Inode::WriteAt() which explains why it cannot use the above method: seems that our VFS/VM locking model isn't really that good. * Fixed a possible deadlock in Attribute::_Truncate() where the inode write lock was held before starting the transaction. * Added an InodeReadLocker convenience class, that should be used instead of ReadLocker - Inode::Lock() only still exists because of the needs of bfs_io(). * Moved the bfs_io() callback hooks out of the exported module API region, and removed their bfs_ prefix. * Added a Volume::IsInitializing() method that should be used rather than checking if Volume::ID() is >= 0. * Removed the MultiInodeLocker again, as it's pretty much superfluous now. * Moved openModeToAccess() to the Utility.h header. * Minor cleanup. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26715 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
03fa417b706f63305263982a61eb1002e6ff9d96 |
|
07-Jul-2008 |
Axel Dörfler <axeld@pinc-software.de> |
* Removed the home-brewn locking classes in BFS besides the read/write lock (for now). * Inode::fSmallDataLock is now a recursive_lock, Journal::fLock is now a recursive_lock, too, Journal::fEntriesLock is now a mutex, as is BPlusTree::fIteratorLock. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26298 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
8e8edffce7fdf16a8ae17b2de36bffa05082114e |
|
29-Apr-2008 |
Axel Dörfler <axeld@pinc-software.de> |
* Fixed at least the "dd" part of bug #2148: the second double indirect array block would be incorrectly addressed when allocating a stream - this could cause random blocks to be overwritten, and therefore could cause many sorts of problems. * Moved BFS_TRACING macro to the tracing_config.h file, and let it follow the new semantics of those other macros in there. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@25249 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
8b5e5656f49d0aa074dc4742e117d4336a3a7bbf |
|
06-Apr-2008 |
Axel Dörfler <axeld@pinc-software.de> |
* BFS now panics if cache_sync_transaction() didn't free the space needed, instead of writing over the old log entries. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24856 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
797a92d84d79bf10ac426c11fcee064b5bcc4609 |
|
07-Apr-2008 |
Axel Dörfler <axeld@pinc-software.de> |
* Made super block log handling endian-safe. * Made all debugging functions endian-safe. * Added tracing for log entries. * Added new KDL command "bfs_journal" to dump all pending log entries. * When BFS_DEBUGGER_COMMANDS is defined, the LogEntry class will also track the transaction ID it belonged to. * The "bfs" KDL command now sets some useful debugger variables. * The "bfs_allocator" KDL command now accepts the group index as 3rd argument. * Renamed Journal::_TransactionListener() to _TransactionIdle(), as that's all it is for. * Removed TODO comment in Volume::WriteSuperBlock(), as it's actually not true. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24852 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
64b7ef1d0f6354c8df9dacf557f76ff0a36c2de1 |
|
04-Apr-2008 |
Axel Dörfler <axeld@pinc-software.de> |
* As briefly discussed in ticket #2024, I've changed BFS to allow to mount volumes with a broken log. It will only allow the volume read-only then, though (unlike Be's BFS), as your disk could be corrupt. * Added InitCheck() method to the RecursiveLock class, and now only check this one in Journal::InitCheck() instead of also replaying the log there; this is now done directly in Volume::Mount(). git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24795 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
0bb7a9c0ca0743114de10ceebd5b9ee6d391afc0 |
|
04-Apr-2008 |
Axel Dörfler <axeld@pinc-software.de> |
* Journal::_TransactionWritten() updated Volume::LogStart() before it actually wrote the super block, so there was a race condition with what _WriteTransactionToLog() assumed was already written there (if it managed to write the log entry before the super block was written by _TransactionWritten(), and a reboot happened just then, the log start could point to an invalid log entry). Not very likely, but it could happen. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24791 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
e63c1170110084f5a21f81eb5b26f008ea68d35e |
|
03-Apr-2008 |
Axel Dörfler <axeld@pinc-software.de> |
Looks like some bloke forgot to commit *some* files that should have been part of r24768 (block cache notification mechanism rewrite). Thanks for the note, Vasilis! git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24772 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
12952eddd738281f3851472fd7ec758def2b7866 |
|
02-Apr-2008 |
Axel Dörfler <axeld@pinc-software.de> |
* Quick fix for a possible deadlock I introduced with the block_cache idle notification. We should rework the cache notifications to work asynchronously. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24752 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
3c78c04589c6c37a6ec71adbf127ad3056b23a44 |
|
02-Apr-2008 |
Axel Dörfler <axeld@pinc-software.de> |
Resolved a TODO in Journal::Lock() that Urias reminded me about: * BFS now uses a transaction listener that flushes the current transaction in case it is idle; before, transactions would always be kept open when they weren't large, so that the block writer could not write back the blocks (they were busy from its POV). * This solves the described problem of the screen resolution not being written back even after minutes of inactivity. * Renamed _TransactionNotify() to _TransactionWritten() to differentiate it a bit more from the new _TransactionListener(). git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24738 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
98e10fd47f98c697df4c06f765a6df5f0420dcc3 |
|
25-Mar-2008 |
Axel Dörfler <axeld@pinc-software.de> |
* _TransactionSize() did not take the block array into account. * Therefore, the log was not flushed often enough: _WriteTransactionToLog() did not check again, and would eventually overwrite incomplete transactions (leading to a corrupted log on reboot)! * _TransactionDone() now only flushes the log if the new transaction will be joined; _WriteTransactionToLog() now checks itself if there is enough space left to actually write the log entry. * Added a TODO about the logging code not being endian-aware. * Renamed _BlockNotify() to _TransactionNotify() as only complete transactions are notified, it's not working on block level anymore. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24577 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
d89cda9ff7655a5847beaa8c83cf9fb97f765d5a |
|
16-Mar-2008 |
Axel Dörfler <axeld@pinc-software.de> |
* Fixed another big bug in the logging code: I obviously got confused what RunArrays::Length() meant; it should have been the length of a log entry, but was only the block count. * Now I've improved naming and fixed initializing the LogEntry with a wrong size, causing subsequent log entries to lose track in the log (the log_start pointer got wrong, so BFS would not be able to replay such a log). * This at least fixes one part of the problem of bug #1911. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24410 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
772506f830c387b8468c67553df0b595e293d5ce |
|
15-Mar-2008 |
Axel Dörfler <axeld@pinc-software.de> |
Divided the _ReplayRunArray() method into two passes: first, the integrity of the blocks in the log entry will be checked, and only if this passed, all log entries are written back together; if the whole run array contained bad data, it's no longer written to disk at all if it's detectable. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24402 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
f426071223bd7a15f3d9d055a02ebbfa7fbe0e96 |
|
15-Mar-2008 |
Axel Dörfler <axeld@pinc-software.de> |
* For whatever weird reason, BFS apparently restricts a log entry to 126 entries, even though many more could fit in the blog. This fixes mounting a dirty (original-)BFS volume with a block size larger than 1024 bytes, and probably vice versa. * Minor cleanup. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24401 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
0dc57dbece497e28b8ab0560ba2eca862ff7c578 |
|
12-Mar-2008 |
Axel Dörfler <axeld@pinc-software.de> |
The log replay code now checks if a super block is valid before the current one gets overwritten; if the log contains invalid data, it will no longer render the whole disk unreadable. This should have helped to prevent bug #1911 (but of course the problem that there is invalid data in the log in the first place remains). git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24381 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
5d43cf2a84430afac1c53b996b0030c6d9855f09 |
|
19-Jan-2008 |
Axel Dörfler <axeld@pinc-software.de> |
* Added new debugger commands bfs_btree_header and bfs_btree_node that dump a B+tree header resp. node. * Use dprintf() when a transaction is too large instead of a panic; even though the file system has to revert the transaction, it's not lethal, and it does not corrupt your disk. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@23653 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
4a553d369626d1529af3ad857eeb83d3d470fde7 |
|
19-Jan-2008 |
Axel Dörfler <axeld@pinc-software.de> |
Forgot to update logStart after every written array - this caused old entries (that were part of the same transaction) to be overwritten. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@23642 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
ae16ab9d0f8bfc6f23f755a4d57468a567ae4c29 |
|
19-Jan-2008 |
Axel Dörfler <axeld@pinc-software.de> |
* When I ported over BFS to the new FS API, I pretty much toasted the logging code: - The vec array to contain the block list and the index block was one entry to small. - But that didn't really matter, as RunArrays/run_array was broken and never put anything into the log; we only ever wrote index headers. BFS would totally screw up the disk when trying to replay the log (even though the replay code itself was and is working fine). - If a log entry ended at the end of the log area, BFS could overwrite the first block after the log with the next entry. * run_array now adopt the sorting stuff from the sorted_array. Blocks in the log are now always sorted. * Added TODO item to sorted_array as it's not endian safe (will only work correctly when BFS is used in the native endian). * Minor cleanup. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@23638 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
5d0afa4e4e49f1537865d29b620e957fbcf97823 |
|
18-Jan-2008 |
Axel Dörfler <axeld@pinc-software.de> |
* cache_detach_sub_transaction() didn't really work: it did not put all needed blocks into the new transaction, but it would set that transaction on all blocks of the old transaction, too. Also, it did not correctly update the num_blocks/sub_num_blocks fields of the old transaction. Even worse, it did return B_OK instead of the ID of the new transaction... * get_writable_cached_block() did not correctly maintain the number of blocks in the sub transaction. * write_cached_block() did not free the original_data of a block when it wrote it back as part of a previous transaction. * Changed "cookie" for cache_next_block_in_transaction() to "long", so it will be 64 bits when needed. * Improved the API for detaching sub transactions: you can now get the blocks of only the main (parent) transaction as well, added new cache_block_in_main_transaction() function. * BFS now flushes the log when there is no space left for the current transaction. * _WriteTransactionToLog() allocated a "vecs" array, but never freed it. * _WriteTransactionToLog() now also supports detaching the current sub transaction if the whole thing is getting too large (it will now also panic if that doesn't work out). * Removed a useless optimization: making the blocks available in the cache isn't really needed, as all blocks in a transaction are locked into the cache, anyway. * Implemented Transaction::WriteBlocks(). * Minor cleanup, removed some dead code, fixed warnings in the fs_shell's block_cache when compiled with debug output on. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@23610 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
4fc4f2c8aeefd8548dc95f51af64beabc07a4ec5 |
|
13-Jan-2008 |
Axel Dörfler <axeld@pinc-software.de> |
* Added a transaction listener mechanism to be notified when a transaction ends or has been aborted. * BFS now listens for transactions when it created an inode to see if the transaction will be aborted without freeing the inode (in which case it will panic for now). * Started implementing tracing support, but it's not working yet. * Minor cleanup. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@23492 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
d1ba9c8adcff423098753d2ec8726a98f8a41f01 |
|
12-Jan-2008 |
Axel Dörfler <axeld@pinc-software.de> |
Fixed warnings when building the bfs_shell. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@23462 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
4afaeabbd858d959a57593f0ad52e4c481709495 |
|
02-Dec-2007 |
Axel Dörfler <axeld@pinc-software.de> |
* bfs_free_cookie() accidently reverted a transaction after having updated the inode's internal last modified and size copies, causing in inconsistent data. This fixes #1643. * The block being replayed are now dumped to the debug output. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@23050 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
6edf637ba6b7bc63919639c19085dd0ebc97ea73 |
|
11-Nov-2007 |
Axel Dörfler <axeld@pinc-software.de> |
Minor cleanup. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@22896 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
c391f84b2c732398288276bc8354ac4060dc5a4d |
|
26-Apr-2007 |
Ingo Weinhold <ingo_weinhold@gmx.de> |
* Prepared the BFS sources to be used with the new FS shell: - Moved all inclusions of system headers into a new system_dependencies.h header, which conditionally either includes these or the FS shell headers. - Fixed compiler warnings related to printf-like functions (int32 is int, not long on non-BeOS platforms). * Build a new bfs_shell. Compiles and links, but does nothing ATM. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@20860 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
eeb28bb7eebe356e2f9e8a5fbe41ac787bc3f8cb |
|
03-Jun-2006 |
Axel Dörfler <axeld@pinc-software.de> |
Some more PPC fixes. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@17714 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
57808587d5e33be2635cf8eb080ccc33cbe4636a |
|
28-Feb-2006 |
Axel Dörfler <axeld@pinc-software.de> |
Fixed warning when build with DEBUG=1. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@16554 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
923e3aaf6f7474dac6ccc017302a6b20136f5d3f |
|
21-Jan-2006 |
Axel Dörfler <axeld@pinc-software.de> |
Fixed two crucial bugs: * When aborting the first sub-transaction, BFS didn't recognize this correctly, and aborted it via cache_abort_transaction() instead of cache_abort_sub_transaction() - that not only reversed the whole transaction, but also let subsequent cache_start_sub_transaction() fail (as there was no transaction to continue anymore). Reported in a reproducible way by Jerome Duval. * Haiku didn't want to replay logs anymore - the off-by-one fix I did in r14428 was not complete, it only let Be's BFS replay our logs, but our's rejected them afterwards. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@16018 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
9ebc6e3c2de5ad15e7b95c22adbc76bc334ff2cb |
|
20-Oct-2005 |
Axel Dörfler <axeld@pinc-software.de> |
Added a comment on what kind of functionality we need from the caching layer one day. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@14442 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
cb6d675cf48242a441e3368fe0f214be20b28560 |
|
19-Oct-2005 |
Axel Dörfler <axeld@pinc-software.de> |
Aborting transactions doesn't change the number of unwritten transactions - that counter does not take the current transaction into account. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@14434 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
9a99234b1a158bf29f17d409c37ae8f4c51e3398 |
|
19-Oct-2005 |
Axel Dörfler <axeld@pinc-software.de> |
Implemented basic sub transaction support - seems to work so far, but I haven't tested it heavily yet. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@14432 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
bd0b075c13cdd879648f1ed118035e1e928b2cfb |
|
19-Oct-2005 |
Axel Dörfler <axeld@pinc-software.de> |
Now takes the off-by-one error in Be's BFS implemenation into account, too. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@14428 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
e620c9328cb8e95f6e3e3f74b3d1afa7b216f9ad |
|
18-Oct-2005 |
Axel Dörfler <axeld@pinc-software.de> |
Argl, turns out Be's replay log routine cannot handle block_runs with a size unequal 1 - IOW using block_runs here is completely bogus. Crippled our code to not create longer block_runs - at least, a dirty BFS image is now a dirty BFS image - you can mount a dirty image on either system and it will work :-) The R5 version of our BFS is still incompatible though - ie. running bfs_shell or copy_to_bfs_image on a dirty image will still potentially corrupt it. Maybe I'll even port the changes over one day... git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@14418 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
a59b9afff01a17005d3e9245c4789ff5788075e8 |
|
18-Oct-2005 |
Axel Dörfler <axeld@pinc-software.de> |
Rewrote the log entry writing so that it should be BFS compatible - not yet tested for compatibility, though! Writing is now combined into a few writev_pos() function calls to speed up log writing. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@14415 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
c0614f3291ad73663b85a1837fecbf24915bfa06 |
|
30-Jun-2005 |
Axel Dörfler <axeld@pinc-software.de> |
Ported r13366 back from the R5 BFS to the Haiku BFS: fixed bad bug in the journaling code, the super block log data could have been wrong. Moved the doubly linked list code to the kernel's util/DoublyLinkedList.h. Also removed Journal::fCurrent, as it's not really used. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@13367 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
1c12a6a33f1af79130b6b2da2ca7bf4d78610ab4 |
|
08-Jun-2005 |
Axel Dörfler <axeld@pinc-software.de> |
Inode::ShrinkStream() now evaluates the return values from some functions - dunno if that's a good idea (it may still be a good idea to succeed for shrinking the stream, even if not everything worked), but it looks better :-) Improved debug output in case TrimPreallocation() fails. Journal::FlushLogAndBlocks() no longer ends the current transaction if called from within an ongoing transaction. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@13019 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
2dbdc141cf0ea22fa3fb8425a4d74b74b1736b11 |
|
30-May-2005 |
Axel Dörfler <axeld@pinc-software.de> |
Transactions can now be nested (bfs_release_vnode() actually did that before, but that was not working correctly): only the owning transaction (the one that came first) can now end a transaction. To do: if the owning transaction fails, it should actually not abort the transaction in case there were sub transactions, but does so right now (should do no harm, eventually file data is not freed as it should). git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@12913 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
5692a950faa10d6774c2964898c7ce6f8faa188a |
|
30-May-2005 |
Axel Dörfler <axeld@pinc-software.de> |
We don't stack transactions together, so we need to end each transaction, even if empty. Added some more debug output. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@12904 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
23b6e06ac62c43eedcff6729b0a526568e5fd142 |
|
02-Mar-2005 |
Axel Dörfler <axeld@pinc-software.de> |
While the block list was written sorted to the log, the blocks were in transaction order which caused corrupted disks when a log was replayed. git-svn-id: file:///srv/svn/repos/haiku/trunk/current@11539 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
92a076fcce5c7a569279ede163efbd88b3e56a02 |
|
22-Nov-2004 |
Axel Dörfler <axeld@pinc-software.de> |
Journal::FlushLogAndBlocks() no longer uses Journal::Lock() but the lock directly. That avoids starting a new transaction for no reason (which wouldn't do any harm, but still, it's not necessary to do that at all). log_entry::cached_blocks is no longer maintained or needed. git-svn-id: file:///srv/svn/repos/haiku/trunk/current@10185 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
fb02804a89b1100c0f20c3e3c28be28215103c44 |
|
19-Nov-2004 |
Axel Dörfler <axeld@pinc-software.de> |
Big update while moving over completely to the Haiku kernel: - Ported over BFS to the new cache API - Inode no longer inherits from CachedBlock, and therefore, no longer keeps the whole inode block in memory. It now has a copy of the bfs_inode structure in memory instead. This has a number of advantages but also some disadvantages, so it might be reverted later, even if it's unlikely. - Added a NodeGetter class that can be used whenever the real block needs to be accessed (ie. for attributes) - Changed *transaction to &transaction where possible - Removed support for KEEP_WRONG_DIRENT_RECLEN - Removed support for uncached file access since that's no longer needed - Fixed some endian issues in bfs_write_stat() - Removed the install BFS rules, since they don't make any sense anymore (unless you are running Haiku ;-)) Note, logged streams are not supported anymore right now. Also, the transaction code is pretty simple and slow - it will be improved later on. Attribute code is pretty much untested in the new environment. git-svn-id: file:///srv/svn/repos/haiku/trunk/current@10053 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
dca5d901c7bc64af9a5ad354374fc894605d1965 |
|
07-Jun-2004 |
Axel Dörfler <axeld@pinc-software.de> |
Added missing include. git-svn-id: file:///srv/svn/repos/haiku/trunk/current@7820 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
feec20d64b8c5be705c76f8ac957408c7c95df97 |
|
07-May-2004 |
Axel Dörfler <axeld@pinc-software.de> |
It's now <util/kernel_cpp.h> rather than <kernel_cpp.h>. Forgot to commit that... git-svn-id: file:///srv/svn/repos/haiku/trunk/current@7442 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
a49b150fff1fec5e4d3f0f6c774617111304e916 |
|
27-Jan-2004 |
Axel Dörfler <axeld@pinc-software.de> |
Removed the fOwningThread functionality from the Journal class; it now just uses a RecursiveLock instead. Changed Journal::CurrentTransaction() so that it returns the current transaction only if it's valid for the thread asking for it. That doesn't fix the bug, but changed its timing a bit. git-svn-id: file:///srv/svn/repos/haiku/trunk/current@6356 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
54343bbc2d49684c7d85169ba9a4bab7fc53fac8 |
|
25-Jan-2004 |
Axel Dörfler <axeld@pinc-software.de> |
Switched to kernel_cpp.h/cpp. git-svn-id: file:///srv/svn/repos/haiku/trunk/current@6291 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
1a49a0986bd50ef30d406b4f5001a0784d344015 |
|
07-Nov-2003 |
Nathan Whitehorn <nwhitehorn@nowhere.fake> |
Bunches of changes to make mwcc like the code. I also coded an _atomic_set() and _atomic_test_and_set() for PowerPC. Of course, there's already one in the kernel tree, but mine's better. :P Now builds (and works, after a fashion) on R5 PowerPC. git-svn-id: file:///srv/svn/repos/haiku/trunk/current@5280 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
24d6529a935852c39c2048164bb7f91d522ff3b3 |
|
27-May-2003 |
Axel Dörfler <axeld@pinc-software.de> |
Journal::LogBlocks() now calls cache_write() if the block is already in the log entry - this is only necessary if the buffer is not the one of the CachedBlock object. Journal::TransactionDone() now properly aborts transactions if possible, instead of just writing them to disk (does only work if the log entry was not used by other transactions already). Added a comment about how to speed up writing the log entries a bit more (though it's not so easy to do, and might not be much faster). git-svn-id: file:///srv/svn/repos/haiku/trunk/current@3362 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
98b972c906051113e46d46cfe8c02f5adebdd599 |
|
25-Feb-2003 |
Axel Dörfler <axeld@pinc-software.de> |
Fixed all warnings that appeared with DEBUG=1 set. Also fixed missing return codes in BufferPool::ReleaseBuffer() and Journal::WriteLogEntry(). git-svn-id: file:///srv/svn/repos/haiku/trunk/current@2845 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
ceeb00d41ae707823f0a2658b0ff79b7afc85d58 |
|
24-Feb-2003 |
Axel Dörfler <axeld@pinc-software.de> |
Fixed a possibly crashing bug (missing strerror() with %s format). Fixed many warnings (due to -Wall). Some style cleanups. git-svn-id: file:///srv/svn/repos/haiku/trunk/current@2843 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
c42ee13401be80c431846910959d587949a1ad10 |
|
07-Aug-2002 |
Axel Dörfler <axeld@pinc-software.de> |
Initial revision git-svn-id: file:///srv/svn/repos/haiku/trunk/current@639 a95241bf-73f2-0310-859d-f6bbb57e9c96
|