Commit Graph

19986 Commits

Author SHA1 Message Date
Oliver Ruiz Dorantes
32d855f756 Add handling to retrieve the id assigned by the stack
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24037 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-02-20 21:05:59 +00:00
Axel Dörfler
db55a020e6 * Started implementing node monitoring in the devfs and device manager.
* Right now, only already known loaded drivers will be monitored for changes;
  their devices aren't republished, though, since that would cause a deadlock
  in the node notification mechanism (listeners are called synchronously);
  need to offload that the event handling to another thread.
* On changes of (known) driver directories, the device manager will now print
  some info to the syslog.
* Fixed republish_driver() I broke recently (would skip every other node), and
  moved it to the driver functions section of the devfs.cpp.
* Implemented currently unused unpublish_driver() function that would have to
  be called before reloading a driver.
* If a driver is in use when it's updated, we mark it, but we don't do anything
  with that info when we could.
* Minor cleanup.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24036 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-02-20 16:55:05 +00:00
Axel Dörfler
9448bb6e0b Added add_node_listener() and remove_node_listener() kernel private functions
to watch a node.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24035 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-02-20 16:48:16 +00:00
Stephan Aßmus
59312709ae * Maintain the previously selected partition when rescanning drives (ie also
when mounting/unmounting a partition).
* Set the enabled state of the Unmount menu item when a partition is not
  mounted (was using previous state from last partition).


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24034 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-02-20 14:23:13 +00:00
Stephan Aßmus
da5d970124 * Small code cleanups, a bigger style cleanup should be done, but I didn't
want to mix too much cleanups into real changes.
* Got rid of the weird lines between rows.
* Tweaked colors (selections are usually dark everywhere else in Haiku).
* Implemented slightly tinting alternating rows.
* Removed the code duplication to figure out the appropriate background
  row color, fixed some inconsistencies between Draw() and RedrawColumn()
  in this regard.

TODO: Default colors should be computed based on current panel color though.

TODO: Figure out why the outline view does not scroll (at least not visibly)
when the vertical scroll bar is used.

TODO: Remove remaining redraw bugs. I observe a column of pixels not being
updated in some cases when resizing columns.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24033 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-02-20 12:27:36 +00:00
Stefano Ceccherini
1d9a705ed4 Disable the apply button when settings have been...er.. applied. Do some
enabling/disabling of the revert button too.
Initialize Settings::fAuto to a default value on construction.



git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24032 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-02-20 10:37:11 +00:00
Stephan Aßmus
bbf31e4d1f * If bitmaps are drawn with alpha channel, it helps to setup the correct
alpha mode. Thanks to Ralf Schuelke for pointing this out.
* Also check the bitmap color space and only use alpha drawing for bitmaps
  with valid alpha channel.
* Don't just reset the parent to B_OP_OVER, but use the previous mode.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24031 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-02-20 09:56:26 +00:00
Stephan Aßmus
d755e1c073 Implemented Enable/DisableUpdates again on the app_server side. Untested. It
should prevent the app_server to send any update messages to the client. It
should just keep adding to the pending update sessions region until the client
enabled updates again. If anything is already in the pending session, an
update request will be send immediately.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24029 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-02-20 00:56:45 +00:00
Michael Lotz
b582e0a75e I really thought that such a small change wouldn't break the build...
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24028 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-02-20 00:52:05 +00:00
Stephan Aßmus
c3b57150e2 I was just going to implement Begin/EndViewTransaction(), but I saw
it is already implemented they way I thought it could be done - nice! Just
some simplifications.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24027 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-02-20 00:42:09 +00:00
Stephan Aßmus
f6a3e5637b * Looking at the diff I remember it contains a patch Andrea Anzani send me,
fixes indicating the focus of the resized column if it isn't the first one.
* Code cleanups by myself in the archiving implementation. No functional change.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24026 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-02-20 00:40:53 +00:00
Michael Lotz
94fec641a7 Implemented a small kernel debugger add-on that triggers a redraw of the
entire screen when exiting the kernel debugger. It sets up a thread that sends
a message to the (currently hardcoded) desktop message looper. The desktop then
does mark the whole screen dirty which causes a full redraw.
Since interrupts need to be enabled I went with an asynchronous thread and
releasing a request sem in the add-ons' exit hook.
Added the add-on to the image as it shouldn't hurt to have it for now.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24025 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-02-20 00:40:07 +00:00
Stephan Aßmus
99238ef54f Disable excessive debug output.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24024 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-02-20 00:37:40 +00:00
Jonas Sundström
1ddb0c6635 Added error checking of the return value of get_sem_info().
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24023 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-02-19 23:59:07 +00:00
Jonas Sundström
782c2e9035 Some rephrasing of help message.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24022 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-02-19 22:13:47 +00:00
Jonas Sundström
75998ed610 Added an Accounts menu item which opens the E-mail preferences.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24021 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-02-19 22:08:54 +00:00
Axel Dörfler
849246ba77 Improved (and tested) the advisory file locking mechanism a bit:
* our flock::l_len was inclusive, while it's exclusive (the last byte locked
  is (l_start - 1 + l_len) not just (l_start + l_len).
* F_UNLCK removes all locks of the calling process that are within the specified
  region - existing locks might also cut or divided.
* Apparently, a single team can lock the same region as often as it wants.
* advisory_locking is now using a DoublyLinkedList instead of its C counterpart.
* advisory_lock now has start + end fields, instead of offset + len, it's
  handier this way.
* This fixes bug #1791.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24020 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-02-19 19:16:36 +00:00
Stephan Aßmus
33def0ba07 * Small cleanups, renamed "md" (for "mouse device") to "device" among other
stuff.
* It's a while since I wrote this code, and I don't remember why I don't
  always "set the configuration". Appearantly on BeOS and ZETA, the
  active configuration was not yet set on the device when the driver examined
  it, but on Haiku it is. The special control command which puts a tablet
  into tablet mode is then not executed. I simply commented out this check
  (always set the configuration) and now my Wacom Intuos 2 is working fine
  in Haiku.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24019 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-02-19 16:06:32 +00:00
Stephan Aßmus
d4122828d4 * Reworked debugging feature, it's now much more simple to use, copied
from the input_server implementation to create a log file.
* DeviceReader already provided the data byte count, since this is a USB
  only Wacom driver, we can simply use the max_packet_size from the endpoint
  descriptor. Changed TabledDevice accordingly to use the already existing
  DeviceReader::MaxPacketSize().
* Reworked DeviceReader::ReadData(). Renamed variables for clarity and
  removed the restriction to read exactly the requested ammount of bytes,
  reading more than the "header" (which contains vendor id, product id
  and max packet size) is already considered a successful read.
* Refactored TabledDevice::poll_usb_device().


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24018 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-02-19 16:03:15 +00:00
Axel Dörfler
b4c82732fb Added test program for our advisory locking implementation - looks like
it has several issues, and a F_UNLCK semantic different from other OSs,
causing bug #1791.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24017 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-02-19 16:00:11 +00:00
Axel Dörfler
350e0b20a5 * Simplified devfs_rescan_driver() since the driver hash is now based on the
name of the drivers.
* Allow driver::publish_devices() to return NULL to hint that it has no devices
  to publish anymore (ie. existing devices will be unpublished in this case).
* republish_driver() now also calls load_driver() in case the driver is not
  loaded.
* publish_device() and unpublish_node() now maintain the new
  driver_entry::devices_published field, so we always know how many devices
  a driver has now.
* Minor cleanup.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24016 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-02-19 14:59:30 +00:00
Alexandre Deckner
644c84564a - fixes the Keymap preflet instead, as suggested by korli.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24015 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-02-19 12:43:52 +00:00
Stephan Aßmus
ddb44fda2c Fixed the log file output when DEBUG=2. PRINT() is called from global
initializers before sLogFile was created in the InputServer constructor.
Even moving the log file creation to a global initializer didn't help,
since the order is not guaranteed. So I changed the code to create the
log file on the fly in the PRINT method.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24014 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-02-19 11:32:41 +00:00
Michael Lotz
b024c395d7 Fix bad error in calculating the leak check info address when updating the
size of a reallocated block. If you had kernel heap leak checking on, this
could have caused the first four bytes of the next block to be overwritten
with the size of the reallocation of the previous block.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24011 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-02-19 00:42:54 +00:00
Michael Lotz
d4d25a55bd We should lock around register_elf_image() as we modify the image hash in there.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24010 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-02-18 22:54:12 +00:00
Ingo Weinhold
306fe53248 We forgot to unpublish our temporary condition variable. Since it was
allocated on the stack, condition variable related structures would be
trashed, causing all kinds of problems. Fixes #1811 and #1812.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24009 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-02-18 21:51:34 +00:00
Alexandre Deckner
3831b0dcd0 - Revert button's first update didn't work since revert data is stored in the Show() method.
- Default data is defined in two places, and was inconsistent.
- Color comparisons could be done with the wrong alpha. note: BColorControl's behavior wrt alpha might differ from R5's.   

This fixes part of #254


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24008 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-02-18 18:08:48 +00:00
Axel Dörfler
02b3446666 * Wrote a multi audio test application to debug the HD-Audio driver.
* Right now, it even plays something, but it doesn't sound like it should
  (more like noise).
* Also, the hda driver only works once, unlike the auich driver.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24007 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-02-18 18:04:30 +00:00
Stefano Ceccherini
1134e85609 fixed a few problems in BMenuBar, triggered by the particular use the
Menu preflet makes of it.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24006 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-02-18 14:30:49 +00:00
Stefano Ceccherini
ec20f9f60d reverted r21961. A menu could be closed, if the user
clicked (with the menu opened) on a view which uses GetMouse() in a loop 
(PE, tracker), since it stealed the mousedown message.



git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24005 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-02-18 13:24:13 +00:00
Stefano Ceccherini
50cd4d0280 Patch by Denis Washington: menubars now, like menus, can be navigated
without keeping the mouse button pressed.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24004 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-02-18 13:21:02 +00:00
Stefano Ceccherini
44cd9847e9 pass -1 as first parameter of StartMenuBar(), otherwise it will hide the
cursor (used for keyboard navigation). Fixes bug #1807


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24003 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-02-18 13:04:52 +00:00
Axel Dörfler
4db9f96954 Added "FTP" facility string.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24002 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-02-18 12:42:34 +00:00
Axel Dörfler
72c9a68780 * Added keyword "full" that will try to send about 1 MB at once.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24001 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-02-18 12:33:06 +00:00
Axel Dörfler
447c081fe4 * sigsuspend() must only block blockable signals.
* Minor comment cleanup.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24000 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-02-18 12:31:17 +00:00
Axel Dörfler
ed7d0f52bf Added a bit more debug output.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@23999 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-02-18 12:28:31 +00:00
Stefano Ceccherini
e70bc53485 Renamed libtiff to tiff
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@23998 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-02-18 09:04:48 +00:00
Stefano Ceccherini
96f0c48768 removed duplicated and obsolete tiff translator
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@23997 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-02-18 09:01:20 +00:00
Stefano Ceccherini
dc0d6e4c0d Set the LowColor as ViewColor, so text looks better. Fix a few menufield
position/size issues. Use B_PANEL_BACKGROUND_COLOR instead of the raw 
numbers. Fixes bug #1800.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@23996 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-02-18 08:57:35 +00:00
Stefano Ceccherini
2e0ba90d3f We can't use the be_app looper, since it can be already locked from
another thread (for example, when quitting the app/window), and that 
would cause a deadlock. Fixes bug #1645.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@23995 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-02-18 08:15:29 +00:00
Michael Lotz
cf46897b4c Use a dedicated heap to allocate everything that is needed during heap growth.
This eliminates the edge case where the grow thread would not be able to create
a new area because no memory could be allocated for the allocation of the area.
As this case cannot happen anymore, it is also not possible to deadlock in
memalign. Therefore the timeout (which would only have prevented the deadlock
but wouldn't have solved the edge case anyway) has been removed too.
Add options to dump the dedicated grow heap and to only print the current heap
count to the "heap" debugger command.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@23994 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-02-18 01:04:19 +00:00
Marcus Overhagen
08c01f715f gcc4 build fix
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@23992 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-02-17 19:18:31 +00:00
Marcus Overhagen
b91371e409 gcc4 build fix
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@23991 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-02-17 19:14:50 +00:00
Ingo Weinhold
5d06d46935 Removed debugging leftover.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@23990 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-02-17 18:07:25 +00:00
François Revol
32d33c44e5 Fix build on BeOS host, seems it was trying to instanciate a struct stat instead...
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@23988 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-02-17 17:53:54 +00:00
Axel Dörfler
5e42a6bdd7 bonefish+axeld:
* the net_server leaked file descriptors for every opened session.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@23987 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-02-17 16:40:03 +00:00
Axel Dörfler
12a5e9a4a2 bonefish+axeld:
The runtime loader did not correctly resolve %A correctly with the
actual normalized program path. IOW it would not work correctly with
symlinks to applications that had their own lib directory.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@23986 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-02-17 16:38:07 +00:00
Ingo Weinhold
8b3b2b4ff1 Test program for syscall restarts. Only a few syscalls are tested yet.
Nested syscall restarts (interrupted syscall in a signal handler)
aren't tested yet.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@23985 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-02-17 16:27:17 +00:00
Ingo Weinhold
058494285a axeld + bonefish:
* Added syscall restart support for connect(), accept(), send(), recv(),
  which are implemented via ioctl()s. The actual restart support is done
  in the net stack driver's ioctl() hook. Lower layers need to correctly
  deal with socket timeouts, though, for which the stack module provides
  support functions.
* TCPEndpoint::_WaitForEstablished() does abort now when an error
  occurred earlier, so that trying to connect to an unused port fails
  immediately, as it should.
* Fixed and refactored TCP connection reset handling. The new
  TCPEndpoint::_HandleReset() does the job. Got rid of
  TCPEndpoint::fError.
* Fixed sequence numbers for SYNC/FINI packets.
* The former two fix the problem that connections wouldn't be closed
  correctly and could even be reused when trying to connect again (as
  was reproducible with svnserve + svn).
* Some style cleanup in CPEndpoint.h.



git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@23984 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-02-17 16:25:07 +00:00
Ingo Weinhold
4048494ce4 axeld + bonefish:
* Implemented automatic syscall restarts:
  - A syscall can indicate that it has been interrupted and can be
    restarted by setting a respective bit in thread::flags. It can
    store parameters it wants to be preserved for the restart in
    thread::syscall_restart::parameters. Another thread::flags bit
    indicates whether it has been restarted.
  - handle_signals() clears the restart flag, if the handled signal
    has a handler function installed and SA_RESTART is not set. Another
    thread flag (THREAD_FLAGS_DONT_RESTART_SYSCALL) can prevent syscalls
    from being restarted, even if they could be (not used yet, but we
    might want to use it in resume_thread(), so that we stay
    behaviorally compatible with BeOS).
  - The architecture specific syscall handler restarts the syscall, if
    the restart flag is set. Implemented for x86 only.
  - Added some support functions in the private <syscall_restart.h> to
    simplify the syscall restart code in the syscalls.
  - Adjusted all syscalls that can potentially be restarted accordingly.
  - _user_ioctl() sets new thread flag THREAD_FLAGS_IOCTL_SYSCALL while
    calling the underlying FS's/driver's hook, so that syscall restarts
    can also be supported there.
* thread_at_kernel_exit() invokes handle_signals() in a loop now, as
  long as the latter indicates that the thread shall be suspended, so
  that after waking up signals received in the meantime will be handled
  before the thread returns to userland. Adjusted handle_signals()
  accordingly -- when encountering a suspending signal we don't check
  for further signals.
* Fixed sigsuspend(): Suspending the thread and rescheduling doesn't
  result in the correct behavior. Instead we employ a temporary
  condition variable and interruptably wait on it. The POSIX test
  suite test passes, now.
* Made the switch_sem[_etc]() behavior on interruption consistent.
  Depending on when the signal arrived (before the call or when already
  waiting) the first semaphore would or wouldn't be released. Now we
  consistently release it.
* Refactored _user_{read,write}[v]() syscalls. Use a common function for
  either pair. The iovec version doesn't fail anymore, if anything could
  be read/written at all. It also checks whether a complete vector
  could be read/written, so that we won't skip data, if the underlying
  FS/driver couldn't read/write more ATM.
* Some refactoring in the x86 syscall handler: The int 99 and sysenter
  handlers use a common subroutine to avoid code duplication.



git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@23983 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-02-17 15:48:30 +00:00
Marcus Overhagen
4af8877673 build fix for r23929
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@23982 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-02-17 14:59:52 +00:00
Marcus Overhagen
6af5db20f4 Reuse virtual bus numbers when a mapping already exists.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@23981 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-02-17 14:44:33 +00:00
Ingo Weinhold
fe19cba8f0 axeld + bonefish:
Before starting to wait on a condition variable check for pending
signals first, if the call is interruptable.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@23980 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-02-17 14:38:23 +00:00
Ingo Weinhold
7d2d758d46 axeld + bonefish:
Make ktrace_printf() available in the kernel, too.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@23979 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-02-17 14:36:47 +00:00
Ingo Weinhold
d63cbbe2df Added "error" debugger command to print the error string for a given
numeric error code.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@23978 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-02-17 14:36:03 +00:00
Jonas Sundström
b19e377dab 0L constant typo? Remove menu item before deleting it.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@23977 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-02-17 14:36:01 +00:00
Ingo Weinhold
25f0ac90a9 axeld + bonefish:
The return value of Inode::WaitForRequest() is status_t not bool. So the
method would always fail when it actually succeeded. This affected reads
from pipes which didn't have data. The bug was hidded since VFS code
mostly checks error codes only against < B_OK, so that such a read would
be treated as 0 byte read.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@23976 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-02-17 14:34:34 +00:00
Ingo Weinhold
392ad2822d axeld + bonefish:
BeOS R5's glue code incorrectly calls _thread_do_exit_notification()
when main() returns, while Haiku does that in exit(). Therefore when
terminating this way the exit hooks were called twice for executables
built under BeOS R5. This caused e.g. NetPositive or the R5 svn to
crash on exit (our network code actually uses those hooks).
Fixes bug #1742.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@23975 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-02-17 14:12:02 +00:00
Ingo Weinhold
2dd86b93a6 axeld + bonefish:
Adjusted PATH, LIBRARY_PATH, and the paths built into the runtime loader
to included the /boot/common tree.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@23974 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-02-17 13:59:29 +00:00
Ingo Weinhold
01335789e4 axeld + bonefish:
Removed the "config" subdirectory in the /boot/common directory
structure.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@23973 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-02-17 13:57:36 +00:00
Ingo Weinhold
a17d1cf43e axeld + bonefish:
Added parameter --start-offset to allow writing the boot code not only
at the beginning of the given file.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@23971 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-02-17 13:45:47 +00:00
Ingo Weinhold
3e61704042 axeld + bonefish:
Added parameters --start-offset and --end-offset to restrict the
access of the file system to only that part of the given file.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@23970 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-02-17 13:42:27 +00:00
Ingo Weinhold
9ae93dcd7f _user_normalize_path() was broken for symlinks in absolute paths.
Fixes #1778.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@23969 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-02-17 13:32:08 +00:00
Ryan Leavengood
5cea25bfaf Adding patch from Juan Sebastian Muñoz Arango to fix bug #1571:
This creates a new tab Info to contain the information for the media
mixer instead of placing it next to the setup controls.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@23967 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-02-17 01:08:28 +00:00
Jérôme Duval
75b402646b added copyright for OpenEXR
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@23966 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-02-16 19:23:17 +00:00
Jérôme Duval
2c5ab413c2 updated marvell_yukon to 1.26 for the source file and 1.11 for the header
should help with bug #1787


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@23965 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-02-16 18:46:40 +00:00
Jérôme Duval
e47368c84e publish_devices() can return NULL, ie for Wacom devices which are not handled by usb_hid
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@23964 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-02-16 15:54:51 +00:00
Jérôme Duval
c9794bddd7 added a PCX translator with some supported formats
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@23963 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-02-16 13:02:03 +00:00
François Revol
d5e76d2b5b Fix Haiku build, sorry ;)
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@23962 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-02-15 02:38:39 +00:00
Michael Lotz
aabef40563 * Add a "stats" argument to the kernel heap leak checker to only print the
total count of allocations and bytes.
* Also add a few more bin sizes (for 8, 24 and 48 bytes) turns out especially
  allocations of 20-24 bytes are pretty common. And as it only wastes a few
  bytes per page this doesn't hurt at all.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@23961 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-02-14 23:16:50 +00:00
Michael Lotz
4f045f9cba Turns out the only thing we didn't do in bfs_free_cookie was - actually
free the cookie. One memory leak less...

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@23960 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-02-14 22:55:02 +00:00
François Revol
608aae69a1 * make sure an url mime type is registered before using it.
* lines and cols are 1-based.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@23959 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-02-14 22:53:34 +00:00
Oliver Ruiz Dorantes
f72093d929 Make the driver almost build for target R5. How is the best way in the Jamfile to compile it together with src/system/kernel/util/list.c only for target R5?
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@23957 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-02-13 20:07:51 +00:00
Michael Lotz
cf2687e48f Only clear 0xdeadbeef if there is 0xdeadbeef present. The size field of the
heap leak check info would otherwise be overwritten for allocations that still
fit the 16 byte bin (i.e. allocations of 0-4 bytes).

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@23956 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-02-12 22:25:18 +00:00
Oliver Ruiz Dorantes
e6b529a362 Build the device path in devfs from the configuration file
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@23955 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-02-12 21:08:43 +00:00
Oliver Ruiz Dorantes
485b82bace Thanks pointing this out Axel, my commits mails were arriving to a dead mail and I did not read until now. My apologiesfor delay
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@23954 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-02-12 20:56:29 +00:00
Michael Lotz
4af6cd5f38 Adding two debug features to the new heap implementation:
* Tracing of allocations, reallocations and frees
* Leak checking infrastructure to dump allocations

The leak checking code records the team and thread id when an allocation is
made as well as stores the originally requested size. It also adds the
"allocations" debugger command that can dump all current allocations (usually
a huge list) or filter by either a team or thread id. This way it's easily
possible to find leftover allocations of no more active teams/threads.
Combined with the tracing support one might be able to track down the time and
reason of an allocation and possibly find the corresponding leak if it is one.
Note that kernel heap leak checking has to be enabled manually by setting the
KERNEL_HEAP_LEAK_CHECK define to 1.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@23953 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-02-12 20:20:35 +00:00
Michael Lotz
d9b0e6addd Two very small changes that help compiling Haiku under Haiku.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@23947 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-02-12 00:54:04 +00:00
Ithamar R. Adema
f2f3c67292 Use new transport callbacks from printer preference.... transport addons now choose what to publish in the printers pref add printer dialog...
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@23946 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-02-11 23:48:05 +00:00
François Revol
d9dea4ae01 Fix build after mmlr's heap change. Thanks René!
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@23945 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-02-11 23:09:56 +00:00
Marcus Overhagen
bc3318b640 Rewrote mapping of domains and busses into a virtual bus number to
allow arbitrary bus numbers. Disabled domain support for __INTEL__.
This should fix bug #1774


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@23944 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-02-10 23:39:35 +00:00
François Revol
3ecd55ed65 Handle command line args. It still opens an empty window though.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@23943 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-02-10 22:29:42 +00:00
Michael Lotz
75fe8391f9 Fix the build. Apparently this file wasn't recompiled on my end before.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@23942 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-02-10 21:53:53 +00:00
François Revol
6eafd65d00 Fix freeing uninitialized pointer.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@23941 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-02-10 21:52:05 +00:00
Jérôme Duval
6c1399c4b0 fixed looping mode, and bug #1730
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@23940 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-02-10 21:03:34 +00:00
Michael Lotz
5c4d1c5e21 Complete rework of the heap implementation. Freelists are now part of the pages
and pages are now kept in lists as well. This allows to return free pages once
a bin does not need them anymore. Partially filled pages are kept in a sorted
linked list so that allocation will always happen on the fullest page - this
favours having full pages and makes it more likely lightly used pages will get
completely empty so they can be returned. Generally this now goes more in the
direction of a slab allocator.
The allocation logic has been extracted, so a heap is now simply attachable to
a region of memory. This allows for multiple heaps and for dynamic growing. In
case the allocator runs out of free pages, an asynchronous growing thread is
notified to create a new area and attach a new heap to it.
By default the kernel heap is now set to 16MB and grows by 8MB each time all
heaps run full.
This should solve quite a few issues, like certain bins just claiming all pages
so that even if there is free space nothing can be allocated. Also it obviously
does aways with filling the heap page by page until it overgrows.
I think this is now a well performing and scalable allocator we can live with
for quite some time. It is well tested under emulation and real hardware and
performs as expected. If problems come up there is an extensive sanity checker
that can be enabled by PARANOID_VALIDATION that covers most aspects of the
allocator. For normal operation this is not necessary though and is therefore
disabled by default.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@23939 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-02-10 21:00:13 +00:00
Jérôme Duval
a0c4a29faf added B_RGBA15 colorspace, and explicitly print which colorspce is unsupported
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@23938 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-02-09 18:08:34 +00:00
Jérôme Duval
cad9eceb7a added missing api_version
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@23937 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-02-09 17:55:11 +00:00
Jérôme Duval
cbc337d925 have libilmimf built with libstdc++v2
added EXRTranslator to the image


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@23936 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-02-09 17:48:10 +00:00
Jonas Sundström
cd6b83ddc1 The title of the (primary) window of (non-document) apps and preferences should be the filename of the executable. File and window names should be changed in tandem in the future. All IMO. Sorry, Marcus, for changing TV-O-Rama. :/ We may want to consider using more proper language, e.g. 'Screensaver' or 'Screen Saver' instead of 'ScreenSaver'. DeskCalc or 'Desk Calculator' should be just Calculator. We should avoid clinging to BeOS history, like with the name CodyCam, which hardly makes any sense anymore, even if you happen to be one of the few BeOS oldtimers.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@23935 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-02-09 13:26:28 +00:00
Stefano Ceccherini
2614ac772b Moved call to SetSteps() from SetTermSize() to FrameResized(), where it
makes more sense (and also completes the fix for bug #1759). Retrieve 
the command from the message archive.



git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@23931 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-02-08 12:16:49 +00:00
Ingo Weinhold
6918dbf421 Normalize the given image path in load_container(). Just constructing
some absolute path was not enough to always recognize a library as
already loaded. This fixes problems with Perl where loading an add-on
would cause another instance of libperl.so to be loaded, which would
lead to crashes due to uninitialized static vars in the new instance.
Perl builds now and the tests run, but quite a few do fail.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@23930 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-02-08 03:18:26 +00:00
Ingo Weinhold
2c986936df Added new syscall _kern_normalize_path() to normalize a path.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@23929 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-02-08 03:06:14 +00:00
Ithamar R. Adema
eb5a25ca41 Slight rework of my previous commit... now ports can be asked too ;)
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@23928 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-02-08 02:00:08 +00:00
Ithamar R. Adema
62cb58a8ef Make print_server track Transport addons too. This is because some of the NewTransportAddOns(tm) can also autodetect devices, e.g. USB printers. For this, the print_server needs to keep those transport addons loaded at all times. This code now also enables dynamic Transport discovery for the Printer prefs, e.g. 'hey print_server GET Transport 0' or 'hey print_server GET Transport 'USB Port'' will now work too ;)
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@23927 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-02-08 00:34:53 +00:00
Michael Lotz
cfc9593fa8 Fix possible though unlikely SMP issue reported by Robert Szeleney. One must
not use a single static variable to synchronize CPUs at two points. In an
environment where CPUs do not really run concurently (in emulation or with
logical processors) it would be possible for CPUs to get trapped in the first
synchronization while another CPU might just do its thing and change the
sync variable again. These CPUs would then never leave the first loop as the
exit condition has already passed again. The key is to use two different sync
variables like it is done in early kernel initialization. As I didn't manage
to trigger this code though I am not sure if this is gonna work.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@23926 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-02-07 23:19:28 +00:00
Jérôme Duval
2836442b70 window is not zoomable, bug #1761
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@23925 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-02-07 20:21:32 +00:00
Jérôme Duval
4bbe697365 fix warning
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@23923 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-02-07 19:33:53 +00:00
Jérôme Duval
6be75ff237 fix gcc4 build
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@23922 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-02-07 19:31:49 +00:00
Ingo Weinhold
7486b72dd1 Added some kernel tracing to the runtime loader.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@23921 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-02-07 19:22:39 +00:00