to the private VM types are including vm_types.h now.
* Removed vm_page, vm_area, vm_cache, and vm_address_space typedefs; it's
cleaner this way, and the actual types are only used in C++ files now,
anyway.
* And that caused changes in many files...
* Made commpage.h self-containing.
* Minor cleanup.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@22329 a95241bf-73f2-0310-859d-f6bbb57e9c96
opaque types for C.
* As a result, I've renamed some more source files to .cpp, and fixed
all warnings caused by that.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@22326 a95241bf-73f2-0310-859d-f6bbb57e9c96
introduced a new vm_page_write_modified_page().
* Resolved a TODO: vm_page_write_modified_pages() did not mark a to be
written page busy but unlocked its cache which could let someone else
steal that page in the mean time.
* Moved the logic when to move a page to the active or inactive queue to
a new function move_page_to_active_or_inactive_queue().
* Moved page_state_to_string() to vm_page(); it's now also used by the
"page" and "page_queue" KDL commands.
* Made the output of the "page_queue list" command more useful.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@22323 a95241bf-73f2-0310-859d-f6bbb57e9c96
are locked, there is now a vm_page_reserve_pages() call to ensure upfront that
there is a page for me when I need it, and may have locked some caches.
* The vm_soft_fault() routine now makes use of that feature.
* vm_page_allocate_page() now resets the vm_page::usage_count, so that the file
cache does not need to do this in read_chunk_into_cache() and
write_chunk_to_cache().
* In cache_io() however, it need to update the usage_count - and it does that
now. Since non-mapped caches don't have mappings, the page scanner will punish
the cache pages stronger than other pages which is accidently just what we
want.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@22319 a95241bf-73f2-0310-859d-f6bbb57e9c96
* Removed the vm_cache/vm_store ref_count duality that besides being a bit ugly
also created the page dameon cache retrieval problem: now, only areas (and
cache consumers) retrieve a reference to the store (and therefore, the vnode).
The page daemon doesn't need to care about this at all anymore, and the pseudo
references of the vm_cache could be removed again.
* Rearranged deletion of vnodes such that its ID can be reused directly after
fs_remove_vnode() has been called.
* vm_page_allocate_page() no longer panics when it runs out of pages, but just
waits for new pages to become available using the new sFreeCondition condition
variable - to make sure this happens in an acceptable time frame, it'll
trigger a run of the low memory handlers.
* Implemented a page_thief() that steals inactive pages from caches and puts
them into the free queue. It runs as a low memory handler.
* The file cache now sets the usage count on the pages it inserts into the
cache (needs some rework though, cache_io() doesn't do it yet).
* Instead of panicking, the kernel will currently dead lock in low memory
situations, since BFS does a bit too much in bfs_release_vnode().
* Some minor cleanup.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@22315 a95241bf-73f2-0310-859d-f6bbb57e9c96
* Replaced release_sem() with release_sem_etc() for future addition of the
B_DO_NOT_RESCHEDULE flag.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@22308 a95241bf-73f2-0310-859d-f6bbb57e9c96
* Fixed vm_page_allocate_page_run(): it did not take the pageState into account,
and would therefore return uninitialized memory (ie. B_CONTIGUOUS areas would
contain garbage).
Now, it stores if a page is cleared in a new vm_page::is_cleared field.
* Some cleanup.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@22306 a95241bf-73f2-0310-859d-f6bbb57e9c96
not take the VCO limits into account; both could (and would during testing) create invalid
frequencies.
* Also reverted the order in which the PLL divisors are traversed to match the order of what
is used in the X driver to create comparable output (our error computation is based on float,
though, and should therefore create more accurate values).
* The i965 introduced a special register for the surface; the former display base register
is now only used for the view offset. Instead of setting the base manually here and there,
there is now a set_frame_buffer_base() function.
* The DPMS code will now also turn off/on the PLL clock generator.
* The code needs some more cleanup, and while the driver now produces the correct timing on
my i965 system, I'm now greeted by a black screen after startup.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@22289 a95241bf-73f2-0310-859d-f6bbb57e9c96
nothing is done with the data yet (besides dumping them to the serial output).
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@22272 a95241bf-73f2-0310-859d-f6bbb57e9c96
* i2c_bus now contains a i2c_timing structure, so that you don't need
both to talk to the I2C bus.
* Therefore, there is now a void ddc2_init_timing() function to get the
the timing DDC needs.
* Cleanup in radeon's monitor_detection.c, and updated it to work with
the DDC/I2C changes.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@22265 a95241bf-73f2-0310-859d-f6bbb57e9c96
diagnostic purposes).
* hash_init() adjusts the table size to a prime number, which should
result in a better element distribution, particularly since usually a
power of two is passed.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@22210 a95241bf-73f2-0310-859d-f6bbb57e9c96
a reference to a by them not yet referenced cache was not correct.
They only incremented the reference count, but a vnode cache reference
includes also a vnode reference. In case of the page daemon this would
cause vnode references to be lost (causing bug #1465).
* The page daemon used an unsafe method to access a yet unreferenced
page cache. There was nothing that prevented the cache from being
deleted while the page daemon tried to get a reference. The
vm_page::cache field is now protected by the page cache table
spinlock, too, which the new function
vm_cache_acquire_page_cache_ref(), used by the page daemon, also
acquires while trying to get the reference.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@22208 a95241bf-73f2-0310-859d-f6bbb57e9c96
group ID with the session and let the terminal update them.
* Added an "orphaned" flag to the process_group structure and code to
maintain it.
* Handle the death of a controlling process correctly: The
foreground process group gets a SIGHUP and all newly-orphaned process
groups containing at least one stopped processes are sent
SIGHUP+SIGCONT.
* The tty handles the O_NOCTTY flag correctly, now.
* The tty handles reads/writes from processes from other sessions
correctly, now.
* Handle tcsetpgrp() from background processes correctly.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@22187 a95241bf-73f2-0310-859d-f6bbb57e9c96
* Defined flag SIGNAL_FLAG_TEAMS_LOCKED for send_signal_etc(), so it can
be called with the team lock being held.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@22186 a95241bf-73f2-0310-859d-f6bbb57e9c96
blocked and no other child status is available.
* Respect SA_NOCLDWAIT and ignored SIGCHLD in waitpid(): Unless a child
status is available immediately, the thread shall block until all
children are gone.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@22161 a95241bf-73f2-0310-859d-f6bbb57e9c96
* The vm_translation_map is now correctly held in all of the vm_ mapping
functions.
* Removed the old vm_daemons.c file - there is now a new vm_daemons.cpp
which contains the beginnings of our new page daemon.
So far, it's pretty static and not much tested. What it currently does
is to rescan all pages in the system with a two-handed clock algorithm
and push pages into the modified and inactive lists.
* These inactive pages aren't really stolen yet, even though their mappings
are removed (ie. their next access will cause a page fault). This should
slow down Haiku a bit more, great, huh? :-)
* The page daemon currently only runs on low memory situations, though.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@22156 a95241bf-73f2-0310-859d-f6bbb57e9c96
DEBUG_CACHE_LIST) that prints an unspectacular list of pointers to all
existing caches. Feel free to extend.
* Enhanced MultiAddressSpaceLocker:
- It supports choosing between read and write lock per address space,
now.
- Added AddAreaCacheAndLock(), which adds the address spaces of all
areas that are attached to a given area's cache, locks them, and
locks the cache. It makes sure that the area list didn't change in
the meantime and optionally also that all areas have their
no_cache_change flags cleared.
* Changed vm_copy_on_write_area() to take a cache instead of an area,
requiring it to be locked and all address spaces of affected areas to
be read-locked, plus all areas' no_cache_change flags to be cleared.
Callers simply use MultiAddressSpaceLocker:: AddAreaCacheAndLock() to
do that. This resolves an open TODO, that the areas' base, size, and
protection fields were accessed without their address spaces being
locked.
* vm_copy_area() does now always insert a cache for the target area. Not
doing that would cause source and target area being attached to
the same cache in case the target protection was read-only. This
would make them behave like cloned areas, which would lead to trouble
when one of the areas would be changed to writable later.
* Fixed the !writable -> writable case in vm_set_area_protection(). It
would simply change the protection of all mapped pages for this area,
including ones from lower caches, thus causing later writes to the
area to be seen by areas that shouldn't see them. This fixes a problem
with software breakpoints in gdb. They could cause other programs to
be dropped into the debugger.
* resize_area() uses MultiAddressSpaceLocker::AddAreaCacheAndLock() now,
too, and could be compacted quite a bit.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@22152 a95241bf-73f2-0310-859d-f6bbb57e9c96
Condition variables would never be interrupted.
* ConditionVariableEntry::Add() did not correctly insert the entry into
the per-thread list of entries (the next link of the previous entry
was not adjusted), which could leave the entry unnotified when the
previous entry was notified, thus leaving it in the respective
condition variable's list after the end of its life time. This should
fix a crashing bug I rarely encountered.
* Added debug checks in the PrivateConditionVariableEntry
constructor/destructor that should have helped me to find
forementioned bug hours earlier, had I been bright enough to realize
that I didn't include <debug.h> and those KDEBUG guarded checks were
never executed. :-/
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@22151 a95241bf-73f2-0310-859d-f6bbb57e9c96
Can be enabled by defining KERNEL_BREAKPOINTS in arch/user_debugger.h
and will provide the arch_{set,clear}_kernel_{break,watch}point()
function. Hitting a break-/watchpoint will throw the thread into KDL.
* Finally added a comment, what's the point of
i386_reinit_user_debug_after_context_switch(), since I wonder every
time I see it. Should be optimized aways soon.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@22150 a95241bf-73f2-0310-859d-f6bbb57e9c96
(needs to account for the parts that the BMenuField draws, ie the shadow
on the right)
* fixed follow mode of BMenuBar in fixed size mode (B_FOLLOW_LEFT_RIGHT)
* don't resize the BMenuField in fixed size mode (endless loop), this should
be more robust anyways, since this endless loop would be triggered if an
application tried to manually resize menuField->MenuBar() in auto resizing
mode
* fixed calculation of the parts that need to be redrawn on resize
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@22127 a95241bf-73f2-0310-859d-f6bbb57e9c96
is used instead of death_entry for team::dead_children.
* Added team::{stopped,continued}_children, which, analoguously to
dead_children, are used to track the state of stopped/continued
children.
* A team does have a job_control_entry, which is allocated at team
creation time. It will be inserted into the parent's
{stopped,continued}_children lists as the team's main thread is
stopped/continued and removed when waitpid() retrieves the child
state. When the team dies the entry is detached from the team and goes
into the parent's dead_children list.
* Removed the wait_for_any field from team_dead_children. It was solely
used to avoid deletion of the contained entries in certain situations.
wait_for_child() (the waitpid() backend) always deletes an entry now,
regardless of whether other threads are waiting; that's in
accordance with the waidpid() specification. wait_for_thread() removes
the entry only, if the caller is the parent of the respective team.
* Introduced team_set_job_control_state() which performes the job
control entry transitions between the respective lists and wakes up
threads waiting in wait_for_child(). It is invoked on team death and
when the team's main thread receives job control signals.
* Reorganized wait_for_child(). It handles WCONTINUED and WUNTRACED now,
too. Removed a block that interpreted the supplied ID as thread ID.
* Added missing parts in waitpid().
Job control starts to work, though it seems to have some glitches.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@22088 a95241bf-73f2-0310-859d-f6bbb57e9c96
* Added class InterruptsSpinLocker, which disables interrupts and
acquires a spinlock all in one.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@22086 a95241bf-73f2-0310-859d-f6bbb57e9c96
variable. Due to C code including the header I had to turn it from and
aggregated member to a pointer. I'm very close to starting to convert
all remaining .c to .cpp files. :-/
* Got rid of the "waiters" field. It was only written, never read.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@22084 a95241bf-73f2-0310-859d-f6bbb57e9c96
exists and thread was notified), B_ENTRY_NOT_FOUND (condition variable
not found or Unpublish()ed while waiting), or B_INTERRUPTED
(interrupted by a signal).
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@22083 a95241bf-73f2-0310-859d-f6bbb57e9c96
* Removed left-over commented C implementation.
* It is now possible for a thread to wait for more than one condition
variable at a time.
* Made waiting for condition variables optionally interruptable.
* Renamed Notify() method to NotifyAll() and added a NotifyOne(), so
that it is now possible to wake up only one of the waiting threads.
Pretty much untested at the moment.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@22081 a95241bf-73f2-0310-859d-f6bbb57e9c96
content name are supported.
* Added file_system_module_info::flags (analogously to
partition_module_info::flags) which indicate which disk device
features the FS supports.
* Replaced the
file_system_module_info/partition_module_info::supports_*()
hooks by a get_supported_operations() hook and for partitioning
systems additionally a get_supported_child_operations() hook.
* Updated file and partitioning systems accordingly.
* Updated fs_shell accordingly.
* Updated the DDM accordingly. The syscall interface remains unchanged,
though.
* _user_supports_initializing_partition() also checks whether the parent
partitioning system is content now.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@22043 a95241bf-73f2-0310-859d-f6bbb57e9c96
* handle out of memory situations
* don't try to copy (and assign op!) in SetData if opCount/ptCount is 0
-> FontDemo doesn't crash anymore eventually when cycling fonts in outline
mode
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@22000 a95241bf-73f2-0310-859d-f6bbb57e9c96
* On exec() the new function thread_reset_for_exec() is called which clears the signals
and cancels an eventually set alarm. Both things weren't done before...
* Some minor cleanups.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21989 a95241bf-73f2-0310-859d-f6bbb57e9c96
as Marcus pointed out, having it outside wasn't thread safe. Moved
PicturePlayer into the BPrivate namespace.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21982 a95241bf-73f2-0310-859d-f6bbb57e9c96
this should fix bug #1293.
I've tested it here on two machines, one works better now, the other stayed the
same (Radeon 9250, and a laptop FireGL (id 4c66) version). This apparently also
fixed bug #1394.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21930 a95241bf-73f2-0310-859d-f6bbb57e9c96
AppendToPicture() (but still doesn't work :( ). Moved some functions
around in PictureDataWriter.h.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21925 a95241bf-73f2-0310-859d-f6bbb57e9c96
stroke/fill polygon, stroke/fill bezier. some work towards drawing of
nested pictures.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21918 a95241bf-73f2-0310-859d-f6bbb57e9c96
* Also swap the flattened size when creating the read buffer
* Define specialized byte_swap()s for unsigned types too so that type_code and the like get swapped correctly
This should fix bug #1371.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21901 a95241bf-73f2-0310-859d-f6bbb57e9c96
* Pulled the actual tree code into a non-templatized class AVLTree to
reduce the amount of code generated each time the template is
instantiated.
* Changed the iterator interface to Java-style.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21892 a95241bf-73f2-0310-859d-f6bbb57e9c96
* Removed a few instances where the page state was set busy directly after
allocating it. This is a no-op, since a page is always busy after
allocation.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21875 a95241bf-73f2-0310-859d-f6bbb57e9c96
cheap means to block threads until notified explicitely.
threads
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21874 a95241bf-73f2-0310-859d-f6bbb57e9c96
interrupts) and SpinLocker (acquires/releases spinlocks).
* Adjusted Jamfiles of components that used <util/AutoLock.h> but didn't
add all header directories required now (<int.h> was added).
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21873 a95241bf-73f2-0310-859d-f6bbb57e9c96
* Removed the ref_count from vm_areas. You now always need to have the address
space locked (read or write, depending on what you do) when dealing with
areas.
* Added helper classes for locking the address space: AddressSpace{Read|Write}Locker,
and MultiAddressSpaceLocker which can lock several spaces at once and makes
sure no dead locks can happen.
* resize_area() is now using the MultiAddressSpaceLocker instead of no locking
at all; ie. it should now be safely to use.
* Disabled transfer_area() for now; it will be changed to work like an atomic
clone_area()/delete_area(), that is, it will hand out a new ID for the
transfered area.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21848 a95241bf-73f2-0310-859d-f6bbb57e9c96
additional parameters that are fed into a dprintf() before panic() is
invoked.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21838 a95241bf-73f2-0310-859d-f6bbb57e9c96
and DrawString() without
* this change also includes adding the penlocation to the shape to-screem
coordinate conversion (temporarily breaks shape rendering, will be fixed
in next commit)
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21821 a95241bf-73f2-0310-859d-f6bbb57e9c96
* the previous AGG implementation is superfluous
* the new implementation is based on that one, but in a way that allows
read/write locking to the list of cache entries (fonts) as well as
read/write locking to the cached glyphs per individual font cache entry
* new GlyphLayoutEngine.h, which is to be the central place for layouting
glyphs along the baseline.
It handles the locking for getting the font cache entries.
It works by giving it a template class GlyphConsumer which does the
actual work.
* changed AGGTextRenderer to use the new font cache
* changed ServerFont::StringWidth(), and the bounding box stuff to use it
* changed DrawingEngine, it doesn't need the global font lock anymore
* our BFont thought that GetBoundingBoxesAsGlyphs and GetBoundingBoxesAsString
is the same, which of course it isn't, hence the two separate functions...
AsGlyphs just gets the bounding box of each glyph in a string, not treating
the string as an actual word
AsString adds the offset of the glyph in the word to the bounding box
* changed ServerProtocol.h accordingly for the different bounding box meaning
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21797 a95241bf-73f2-0310-859d-f6bbb57e9c96
that OpenHashTable.h does not collide with all the other places that this
is used, it seems everything still builds fine. Most problematic could be
the OpenHashTable.h at kernel/util, but it seems it the target using
that are not affected.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21792 a95241bf-73f2-0310-859d-f6bbb57e9c96
* Adjusted the FS initialize() hook to have FD and partition_id
parameters like the other hooks instead of the partition path.
* Adjusted initialization in BFS accordingly.
* Implemented the FS initialization method in KFileSystem.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21788 a95241bf-73f2-0310-859d-f6bbb57e9c96
* Simplified the notification framework: removed the updater stuff completely;
it was only there to account for some peculiarities of the node monitor which
we now solved differently.
* NotificationListener no longer includes a doubly linked list link for convenience;
it might want to listen to more than just one service.
* NotificationService cannot have an abstract destructor.
* Changed the _user_stop_watching() syscall to mirror the Be API; ie. it's no
longer possible to just remove some flags separately, just to stop listening
completely.
* Adapted the node monitor implementation to live in the NodeMonitorService class
that uses the new notification framework.
* Removed the public kernel node monitor API - it wasn't useful that way since you
couldn't do a lot with the KMessage in the kernel without using a private API.
Now you will have to use the (private) notification manager to use the node monitor
from inside the kernel. At a later point, we might introduce a public API for that,
too.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21780 a95241bf-73f2-0310-859d-f6bbb57e9c96
* Added a Current() method to the same class that returns the current element again.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21779 a95241bf-73f2-0310-859d-f6bbb57e9c96
Will be used for node monitoring and other stuff, too (like the Registrar or the
VM low memory handler).
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21768 a95241bf-73f2-0310-859d-f6bbb57e9c96
private/shared.
* Made AddReference() and CountReferences() inlines.
* The registrar is now using the private Referenceable version in libbe.so.
* Minor cleanup.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21767 a95241bf-73f2-0310-859d-f6bbb57e9c96
therefore, we could remove the ugly defines from KMessage again, and compile it
with KMESSAGE_CONTAINER_ONLY.
* Added KMessage::SetDeliveryInfo() to be able to send messages with a correct
header.
* Fixed a bug in KMessage::SendTo() that would not send the senderTeam when passing
a negative value for the parameter, but override it when passing in a valid
value.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21740 a95241bf-73f2-0310-859d-f6bbb57e9c96
* Moved method documentation from headers to source files.
* Fixed small problems (memory leaks, unsafe string duplication,...).
* Added TODOs where I spotted problems.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21721 a95241bf-73f2-0310-859d-f6bbb57e9c96
for _kern_load_image().
* Added KMessage to the runtime_loader (a bit hacky, though) - it will use
it to deliver the above mentioned functionality.
* load_dependencies() did return the wrong status code in case a library
was missing; now it returns B_MISSING_LIBRARY.
* load_dependencies() will now try to load all dependencies when a report
message is requested; therefore, all missing libraries are listed.
* Renamed uspace_program_args to user_space_program_args.
* The kernel filled in various members of the user_space_program_args structure
unsafely, ie. was not using user_memcpy().
* Renamed some local variables in team.c to better fit our style guide (ie.
uargs to userArgs).
* Changed Tracker to use the new _kern_load_image() variant on Haiku to retrieve
and report all missing libraries. This fixes bug #1324.
* Adapted kernel_cpp.cpp to the runtime loader as well; the latter will now
compile with _LOADER_MODE defined.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21715 a95241bf-73f2-0310-859d-f6bbb57e9c96
of the active ViewLayer is now always mirrored in the Painter instance
of a ServerWindow, so that it doesn't need to be synced on every drawing
command, this was previously incomplete for font handling
* removed the DrawState parameter from all the DrawingEngine functions
* adjusted ServerWindow and ServerPicture accordingly
* made sure that string related functions used by non-drawing related
parts (ServerApp, Decorator) don't interfere with the current drawing
state
* moved AS_SYNC handling from _DispatchViewMessage to _DispatchMessage,
it is actually a window message and doesn't require fCurrentLayer to
be valid
* fixed bug #1300, fCurrentLayer was not updated when a ViewLayer was
deleted by client request which happened to be fCurrentLayer (I am now
handling it so that the parent becomes the current layer, could be
wrong)
* AGGTextRenderer is no longer using it's own scanline, which should save
a few bytes RAM, the Painter already had such an object
* StringWidth() in AGGTextRenderer is now taking the escapement_delta into
account
* Painter::StrokeLine() doesn't need to check the clipping as much, since
that is already done in DrawingEngine
* if a ServerWindow message is not handled because fCurrentLayer is NULL,
a reply is sent in case the messages needs it (client window could
freeze otherwise, waiting for the reply for ever)
* removed unused AS_SET_FONT and AS_SET_FONT_SIZE
* added automatic RGBColor -> rgb_color conversion to RGBColor.h
* minor cleanup for 80 char/line limit
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21685 a95241bf-73f2-0310-859d-f6bbb57e9c96
* More conditional debug code (wrt page transitions between caches).
* Replaced debugger command cache_chain by a nicer cache_tree.
* While handling a soft fault: When we temporarily unlock a cache, it
can theoretically become busy. One such occurrence is now handled
properly, two more panic() ATM, though should be fixed.
* When merging caches, we do now always replace a dummy page in the
upper cache, not only when the concurrent page fault is a read fault.
This prevents a page from the lower (to be discarded) cache from still
remaining mapped (causing a panic).
* When merging caches and replacing a dummy page, we were trying to
remove the dummy page from the wrong cache (causing a panic).
The Haiku kernel seems now to run shockingly stable. ATM, we have more
than two hours uptime of a system booted and running over network. We
didn't manage to get it down by fully building Pe, downloading, unzipping,
and playing with various stuff. Someone should finally fix all those app
server drawing bugs, though (hint, hint! ;-)).
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21672 a95241bf-73f2-0310-859d-f6bbb57e9c96
stack hungry and would previously hit the stack limit and thus cause a
double fault. Hopefully we'll be able to reduce the stack foot print at
some time.
PXE boot does now fully work.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21663 a95241bf-73f2-0310-859d-f6bbb57e9c96
* Images preloaded by the boot loader had to be modules to be of any use
to the kernel. Extended the mechanism so that any images not accepted
by the module code would later be tried to be added as drivers by the
devfs. This is a little hacky ATM, since the devfs manages the drivers
using a hash map keyed by the drivers inode ID, which those drivers
obviously don't have.
* The devfs emulates read_pages() using read(), if the device driver
doesn't implement the former (all old-style drivers), thus making it
possible to BFS, which uses the file cache which in turn requires
read_pages(), on the device. write_pages() emulation is still missing.
* Replaced the kernel_args::boot_disk structure by a KMessage, which can
more flexibly be extended and deals more gracefully with
arbitrarily-size data. The disk_identifier structure still exists,
though. It is added as message field in cases where needed (non net
boot). Moved the boot_drive_number field of the bios_ia32 platform
specific args into the message.
* Made the stage 1 PXE boot loader superfluous. Moved the relevant
initialization code into the stage 2 loader, which can now be loaded
directly via PXE.
* The PXE boot loader does now download a boot tgz archive via TFTP. It
does no longer use the RemoteDisk protocol (it could actually be
removed from the boot loader). It also parses the DHCP options in the
DHCPACK packet provided by PXE and extracts the root path to be
mounted by the kernel.
* Reorganized the boot volume search in the kernel (vfs_boot.cpp) and
added support for network boot. In this case the net stack is
initialized and the network interface the boot loader used is brought
up and configured. Since NBD and RemoteDisk are our only options for
net boot (and those aren't really configurable dynamically) ATM, the
the boot device is found automatically by the disk device manager.
Booting via PXE does work to some degree now. The most grievous problem
is that loading certain drivers or kernel modules (or related activity)
causes a reboot (likely a triple fault, though one wonders where our
double fault handler is on vacation). Namely the keyboard and mouse input
server add-ons need to be deactivated as well as the media server.
A smaller problem is the net server, which apparently tries to
(re-)configure the network interface we're using to boot, which
obviously doesn't work out that well. So, if all this stuff is disabled
Haiku does fully boot, when using the RemoteDisk protocol (not being
able to use keyboard or mouse doesn't make this a particular fascinating
experience, though ;-)). I had no luck with NBD -- it seemed to have
protocol problems with the servers I tried.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21611 a95241bf-73f2-0310-859d-f6bbb57e9c96
with the same size as the class is defined.
* The SetTo() methods do now accept an unspecified (negative) bufferSize
in case of being told to initialize from the given buffer.
* Added handy Get*() methods returning a field element value or a
supplied default value, if the field element doesn't exist.
* Added also handy Set*() methods setting the value of first element of
a field, i.e. adding it, if it didn't exist before, otherwise
replacing the old value. Only for fixed size types.
* Moved _FindType() inline template method into the header.
* Made the source file fit for use in the boot loader. If the macro
KMESSAGE_CONTAINER_ONLY is defined, the message sending/receiving part
is omitted.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21605 a95241bf-73f2-0310-859d-f6bbb57e9c96
with the other partition types.
* Added kPartitionTypeEFI to the constants.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21574 a95241bf-73f2-0310-859d-f6bbb57e9c96
* Removed r5_message.cpp and dano_message.cpp accordingly
* Also moved out KMessage handling from Message.cpp to MessageAdapter.cpp
* Fixed some minor style issues in Message.cpp
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21514 a95241bf-73f2-0310-859d-f6bbb57e9c96
are now only enabled if there are any inbound accounts.
* BMailSettings::StatusWindowFrame() now returns some useful defaults.
* Minor cleanup.
* The MDR kit needs some serious overhaul before it can be part of R1.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21493 a95241bf-73f2-0310-859d-f6bbb57e9c96
* Added a TRACE_S3SAVAGE macro that turns on debug output - should be set conditionally
if DEBUG is defined (see DriverInterface.h), but is currently always on, as requested
by Gerald.
* Some minor style fixes.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21492 a95241bf-73f2-0310-859d-f6bbb57e9c96
* vm_copy_on_write_area() now does no longer overwrite the ref_count, but keeps
it's reference to the cache until it has unlocked it.
* It now also locks its reference from the start, preventing any other thread
to interfere.
* vm_cache_remove_consumer() now detects if it has to remove a foreign busy
page itself in order to preserve a mapped page.
* vm_soft_fault() now keeps a reference to the cache that owns the page to be
mapped until it has actually mapped it.
* vm_unmap_pages() removed the mappings of all pages of the area instead of only
those that are within the requested range.
* Kept (disabled) debug output for convenience.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21482 a95241bf-73f2-0310-859d-f6bbb57e9c96
Disabled by default, but all kernel devs are *highly* recommended to turn them on for your builds and see if it trips anything, and then fix it.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21477 a95241bf-73f2-0310-859d-f6bbb57e9c96
the maximum width. The latter supports unlimited maximum width. The
_BMCMenuBar_ draws fine when resized wider than its min/preferred width, but
not the complete "button" area will cause the menu to open when being pressed.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21465 a95241bf-73f2-0310-859d-f6bbb57e9c96
fixed warnings and code style. Please, from now on, provide *patches* to this version.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21421 a95241bf-73f2-0310-859d-f6bbb57e9c96
Implemented SetIndexedColors hook, although not really correct.
I don't know why the driver's 8 bit mode were disabled. They seem to
work fine. I had to enable at least 640x480x8 to be able to test
WindowScreen. There are some TODOs in the code. I'll look into them
later.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21410 a95241bf-73f2-0310-859d-f6bbb57e9c96
despite being talked about repeatedly, does not currently exist.
Adding this required adding some new Jam rules to deal with this shared source
directory and headers. I had some fun figuring this out. Despite writing
articles about Jam in the Haiku newsletter a few years ago I still find Jam to
be a PITA at times.
But my solution seems to work pretty well. Basically you just call the rule
UseSharedSource and pass the name of the shared source file you want to use.
This rule sets up the header directories and the right Jam variables for the
source file. You then add the source file to the source list in the Application
rule like any other source file.
I also made the authors list sent to the about window constructor null
terminated instead of passing the size of the array, as suggested by Hugo.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21391 a95241bf-73f2-0310-859d-f6bbb57e9c96
realized that calling it a window may not be strictly correct since it isn't a
decendent of BWindow, but just uses a BAlert. Oh well, it can be changed if
need be.
I'm also checking in the first use of it, in ShowImage. Since ShowImage can
still be compiled for R5 I've added a #ifdef around the new BAboutWindow
related code.
I'm open for suggestions for the interface for this class, well mostly the
constructor. I'm not a big fan of having to specify the number of authors.
For now I'm making the header private, but I don't think it would be a big deal
to expose it publically.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21389 a95241bf-73f2-0310-859d-f6bbb57e9c96
BMenuWindow. BMenuScroller now is just the scroller button, and it's a
child of BMenuWindow. This simplifies attaching/detaching the
scrollers, and it's also a bit cleaner.
The lower scroller wasn't shown anymore for some reason, and this commit also fixes this problem.
A drawing bug shows up now, though: when scrolling the menu UP, some
spurious lines are drawn over the menu. I wonder if this is an
app_server bug or what.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21326 a95241bf-73f2-0310-859d-f6bbb57e9c96
correctly.
* Got rid of this superfluous cookie stuff - either the VFS behaves correctly, or
we're screwed anyway.
* Made adding debugger commands optional depending on if DEBUG_COMMANDS is defined
or not.
* Minor other cleanup.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21322 a95241bf-73f2-0310-859d-f6bbb57e9c96
doesn't work on i965 yet.
* B_GET_DISPLAY_MODE now returns the mode actually configured in the chip instead
of the last mode set; while this isn't really necessary, it allows to check what
mode was used during startup.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21321 a95241bf-73f2-0310-859d-f6bbb57e9c96
libroot). It's available in the kernel through the private
get_haiku_revision() and added to the kernel syslog output.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21173 a95241bf-73f2-0310-859d-f6bbb57e9c96
* PowerStatus is now using this API when compiled for Haiku.
* Note, I'm not sure why yet, but running PowerStatus in the background
crashes at least my laptop after some time.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21154 a95241bf-73f2-0310-859d-f6bbb57e9c96
* Change name of header for Haiku specific multi_audio to hmulti_audio (in line with the rename of the media addon itself)
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21136 a95241bf-73f2-0310-859d-f6bbb57e9c96
and add wrappers for watch_node() as well, though.
* Implemented more or less all what is needed for the path monitoring to work.
* Added a test application: works fine under Haiku, but somewhat flaky under BeOS,
dunno why yet.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21066 a95241bf-73f2-0310-859d-f6bbb57e9c96
make both gcc 2.95.3 and the plethora of gcc 4s happy: Typedefed
struct fssh_stat to fssh_struct_stat, thus hopefully avoiding spurious
errors concerning clashes with the function or regarding namespacing.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21055 a95241bf-73f2-0310-859d-f6bbb57e9c96
* The API is just a proposal at this time, please comment.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21020 a95241bf-73f2-0310-859d-f6bbb57e9c96
also renamed their accelerants and settings files accordingly.
* Added Mandelbrot and GLDirectMode as demo applications.
* Moved CortexAddOnHost to /bin.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21010 a95241bf-73f2-0310-859d-f6bbb57e9c96