* Fixed coding style issues pointed out by Axel.
* Fixed potential buffer overflow and fault in default-client-up code path
(OF counts terminating zero char, too).
* Added an intermediate fallback to parsing the boot path
* Added himself to the copyright holders
Thanks a lot! Fixes ticket #5189.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@34918 a95241bf-73f2-0310-859d-f6bbb57e9c96
a timeout leaks these transfers. In the end this would at least lead to a flood
of canceled transfers on device unplug or, worse yet, exhaust the USB memory
pool stalling all further transfers as seen in #4604. Probably fixes both
issues, can't test though as I don't have the hardware.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@34915 a95241bf-73f2-0310-859d-f6bbb57e9c96
mapping is actually present. This would have resulted in page 0 being freed
over and over again, if we hadn't also incorrectly tried to look up the page
by the virtual instead of the physical address. So we were actually freeing
random pages. Fortunately the virtual addresses are kernel addresses, so that
the affected pages lay beyond 2 GB and probably weren't used at this point
yet.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@34912 a95241bf-73f2-0310-859d-f6bbb57e9c96
spacing and insets).
* Added a check box for disalbling the index generation on BFS volumes.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@34908 a95241bf-73f2-0310-859d-f6bbb57e9c96
the internal dependencies into account. This should fix bugs #5166, #5120,
and #5150.
* Also, the time source object manager, as well as the dormant node manager
are now recreated on media roster restart (when the media server is
restarted).
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@34906 a95241bf-73f2-0310-859d-f6bbb57e9c96
(in libgnu.so) with my current rsync port:
* Node now opens its fd with O_RDONLY, as otherwise BFS will refuse to open
(the attributes of) directories
* Node::Get() and Node::Set() now make use of the encoded attribute type,
as otherwise all created attributes would have the type 'XATR' (instead
of the encoded haiku-specific type)
* minor cleanup with respect to the line width limit
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@34904 a95241bf-73f2-0310-859d-f6bbb57e9c96
'+' as part of their name, which is illegal for shell variables (where the
corresponding replacement character is 'X').
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@34903 a95241bf-73f2-0310-859d-f6bbb57e9c96
Get the user shell with getpwuid(), since this should be the correct way
to do it (and mmu_man wants it like this).
Note that when opening a new terminal tab, this is ignored, and a fixed
invocation is used (in the Shell class)
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@34902 a95241bf-73f2-0310-859d-f6bbb57e9c96
Since the former is no longer guarded by any lock, there's a race condition
with vm_page_unreserve_pages() which would cause us to wait longer than
necessary.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@34898 a95241bf-73f2-0310-859d-f6bbb57e9c96
sHeapBase will probably not point to memory in the heap area. Use
sFreeHeapBase instead.
* When reserving the heap area range fails, set sHeapBase to NULL, so we'll
later know about the fact.
* hoardSbrk(): When resizing the area fails, we'll now try to allocate a new
one, if the former failure was not due to an "out of memory" situation.
E.g. if the heap range reservation failed or, if we just have exhausted the
range, another area could be in the way. Also when mmap()ing over
malloc()ed, the heap area count be split in two with the first part
retaining the old area ID, thus preventing resizing as well. Fixed#5168.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@34897 a95241bf-73f2-0310-859d-f6bbb57e9c96
(--update must be given as first option, but can be followed by others)
* added simple perl scripts that is used by configure to convert BuildSetup
from jam to shell format
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@34896 a95241bf-73f2-0310-859d-f6bbb57e9c96
Use convert_to/from_utf8() directly instead of the homebrewn proxy methods.
Removed CodeConv from the repository.
Remove UTF8WidthTbl.c from the repository, since it's not used anymore.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@34894 a95241bf-73f2-0310-859d-f6bbb57e9c96
TermParse::StopThreads() in Shell::DetachBuffer() to be never called.
Moved initialization of termios struct to its own functions.
Added const to some methods.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@34893 a95241bf-73f2-0310-859d-f6bbb57e9c96
* Determine HOST_LD and HOST_OBJCOPY in configure.
* Removed Solaris ld work-around in BuildSetup.
The change requires configure to be re-run. Alternatively HOST_{LD,OBJCOPY}
can be added to generated/build/BuildConfig.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@34892 a95241bf-73f2-0310-859d-f6bbb57e9c96
TODO: determine which other command line tools may also fit under this new group.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@34889 a95241bf-73f2-0310-859d-f6bbb57e9c96
sUnreservedFreePages which tracks the difference between free/clear and
reserved pages. Access to it uses atomic operations which allows the three
page (un)reservation to avoid locking in most cases, thus reducing contention
of the "pages" lock.
In the -j8 Haiku image build that decreases the contention of the "pages"
lock to about one third of the previous value. As a positive side effect the
VMCache lock contention drops about the same factor. The total build speedup
is about 20%, the total kernel time drops about 20%.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@34888 a95241bf-73f2-0310-859d-f6bbb57e9c96
-Updated one lituanian catalog from Algirdas. I'm too lazy to fix the others one, sorry.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@34884 a95241bf-73f2-0310-859d-f6bbb57e9c96
improve the reliability as long as our slab implementation is a PITA.
* Removed an assertion that will no longer work (due to the DoublyLinkedList
changes).
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@34877 a95241bf-73f2-0310-859d-f6bbb57e9c96
the next/previous pointers. There might be more, though.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@34875 a95241bf-73f2-0310-859d-f6bbb57e9c96
* Renamed page_queue to VMPageQueue and made it a proper C++ class. Use
DoublyLinkedList instead of own list code.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@34874 a95241bf-73f2-0310-859d-f6bbb57e9c96
have one anymore anyway.
* Removed unnecessary setting the list links to NULL after removing a node.
* Replaced "element == NULL" check in Insert() by an assert. This just hid
potential errors.
* Added Insert{Before,After}() methods and declared the Insert() version
with the InsertBefore() semantics obsolete.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@34873 a95241bf-73f2-0310-859d-f6bbb57e9c96
playing with the unused list manually. This also clears the vnode's unused
flag, which wasn't done before and would thus cause corruption of the
unused list a bit later.
* fs_unmount():
- Fixed an iteration bug I introduced previously. The iterator would be
advanced twice per iteration, leading to NULL pointer dereferencing
when the vnode count was odd and skipping the checks for every other
vnode.
- All vnodes are going to be freed, so vnode_to_be_freed() has to invoked
for every one of them. The code wasn't adjusted correctly when
introducing the hot vnodes handling.
* Adjusted/improved some comments.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@34871 a95241bf-73f2-0310-859d-f6bbb57e9c96
available in the boot loader.
* Simplified parse_ip_address() and use style conforming identifiers.
* Some cleanup.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@34870 a95241bf-73f2-0310-859d-f6bbb57e9c96
used for it that is.
* The main cause for the heavy contention of the unused vnodes mutex was that
relatively few vnodes are actually used for a longer time. Mainly those are
the volume roots, mmap()ed files, and the files opened by programs. A good
deal of nodes -- particularly directories -- are just referenced for a very
short time, e.g. to resolve a path to a contained entry. This caused those
nodes to be added to and removed from the unused vnodes list very
frequently, thus resulting in a high contention of the mutex guarding it.
To address the problem I've introduced an approximation of a set of "hot"
vnodes, i.e. vnodes that have recently been marked unused. They are stored
in an array that by means of an r/w locker and atomic operations can most
of the time be accessed concurrently. Whenever it gets full, it is flushed
to the actual unused vnodes list.
* dec_vnode_ref_count(): No longer check the unused vnode count every time.
The called new vnode_unused() does only from time to time and returns when
the caller is expected to free some of the unused vnodes. As a side effect
this also fixes a bug I previously introduced: The unused vnode to be freed
was marked busy without being locked first.
The -j8 Haiku image test build shows that the changes reduce the contention
of the unused vnode list mutex to virtually zero without introducing any
significant contention of the new r/w lock. The VMCache lock contention also
seems to be decreased somewhat, which is probably not that surprising
considering that the page writer acquires/releases vnode references with the
cache lock held. The "pages" lock takes over even more contention, now
causing more than 100000 waits per second.
The total build time reduction is about 4.5%. Kernel time drops more than
10%.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@34866 a95241bf-73f2-0310-859d-f6bbb57e9c96