Commit Graph

4501 Commits

Author SHA1 Message Date
Stephan Aßmus 162a7f5f8e * Implemented new BView drawing functions DrawBitmap[Async](
const BBitmap* bitmap, BRect bitmapRect, BRect viewRect, uint32 options).
  Only option so far is B_FILTER_BITMAP_BILINEAR.
* BView::DrawBitmap[Async](const BBitmap* bitmap, BRect viewRect) was accessing
  the bitmap pointer without checking it. Would therefore crash when passing
  NULL, unlike the other methods.
* The BPicture code already reserved room for the BBitmap flags, but did not
  store the actual flags and neiter use them for anything. Since the bitmap
  data is stored anyways, the bitmap creation flags do not matter. So I reused
  this for the new bitmap drawing options.
* Rewrote Bitmap.h and removed the B_BITMAP_SCALE_BILINEAR flag again.
* Tried to optimize Painter::_DrawBitmapBilinearCopy32() a little by giving
  the compiler better hints. There seems to be a marginal, possibly imagined
  speed increase < 0.05 ms. ;-)


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26665 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-07-28 18:58:30 +00:00
Stephan Aßmus 3c7dd7c346 Added const versions of the methods that should have been declared like
that from the start. Please review for possible binary compatibility problems!


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26663 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-07-28 18:50:07 +00:00
Stephan Aßmus 1c111165b0 Cleanup only.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26661 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-07-28 16:27:13 +00:00
Ingo Weinhold ec598fe493 * Added FS interface hooks io() and cancel_io(). The former is supposed
to provide asynchrounous (or only synchronous, if asynchronous is not
  supported) I/O request support. It will eventually replace
  {read,write}_pages(). None of the FS implementations implement them
  yet.
* Implemented some support functions for request-based I/O. File system
  implementations can use do_fd_io() which passes an I/O request to the
  layer responsible for a given FD, and do_iterative_fd_io(), which
  translates a request for a file to subrequests for the underlying
  device and passes them on. Both fall back to synchrounous processing
  when the io() hook is not supported.
  Furthermore added vfs_synchronous_io() which should be handy for the
  devfs to perform io_requests synchronously for devices that don't
  support the io() hook.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26655 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-07-28 02:07:20 +00:00
Stephan Aßmus dcd70f0e39 * Introduced new BBitmap flag B_BITMAP_SCALE_BILINEAR.
* When drawing BBitmaps with scaling in the app_server, use a bilinear
  filter when a bitmap has this flag set. (Hope nobody objects, otherwise
  I can revert or improve this. Performance can certainly be improved, since
  the AGG implementation is too generic. But that goes for the nearest
  neighbor implementation as well.)
* Flags are uint32, fix app_server side code to declare them correctly. Use
  appropriate link methods in BBitmap and ServerApp.
* Enable the BeOS compatibility mode for B_RGB32 (works just like B_RGBA32
  in B_OP_ALPHA mode).


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26649 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-07-26 23:40:13 +00:00
Karsten Heimrich 0ca6b749f4 * merge parts of libprint and libprintutils to make both indepentend
* adjust all drivers to take that into account
* fix UpdateText() signature in JSDSlider to avoid warning



git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26648 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-07-26 22:36:01 +00:00
Jérôme Duval 27a76e1d73 added amd phenom cpu type, untested
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26642 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-07-26 18:35:39 +00:00
Ingo Weinhold c53e844a89 Moved ENABLE_SWAP_SUPPORT definition to vm_types.h
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26640 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-07-26 14:36:24 +00:00
François Revol e70ba4e482 Fix build.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26634 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-07-25 15:36:05 +00:00
François Revol 60b11851d4 partial support for 68901 MFP chip as interrupt controller, untested.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26633 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-07-25 15:05:52 +00:00
François Revol 36ee9f5c62 - use a physical page for natfeat debug output for now
- add 040 cpu and mmu stuff
- use leftover from the page root table to put interrupt vector table to set VBR to


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26627 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-07-25 00:25:27 +00:00
Ingo Weinhold 3f59678453 Missed in r26625.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26626 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-07-24 23:34:40 +00:00
Oliver Ruiz Dorantes 76646d9f67 Cleanups
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26615 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-07-24 20:54:32 +00:00
Oliver Ruiz Dorantes 3205e523cd Implement pairing with a remote bluetooth device
- Fix PincodeWindow to send the pincode commands dissapear after clicking 
- Improve the debug output of bluetooth_server
- Handle all needed events for the pairing
- Simple request could send and receive the event before adding the request to the events wanted list. Inverted the order of this sequence.



git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26614 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-07-24 20:50:49 +00:00
Ingo Weinhold 6e60a6ac03 Added function get_memory_map_etc() which works similar to
get_memory_map(), but has a saner semantics and allows specifying a
team.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26600 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-07-24 04:07:14 +00:00
François Revol 0ae1957465 - Cleanup
- rewrote early_query() to use the TT0 mapping to remove the page_hole stuff.
- fixed natfeat, using a page set up from the bootloader for now as it wants physical address. At least it's enough to see from the debugger:
load kernel...
kernel entry at 8003711a
Welcome to kernel debugger output!
Haiku revision: 26582
PANIC: unknown cpu_type 68040

Welcome to Kernel Debugging Land...
Running on CPU 0
kdebug>


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26599 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-07-24 02:59:47 +00:00
Ingo Weinhold 902559ce32 * Added a mutex to IORequest. It doesn't look like we can get around
using a lock and I'm not very much in favor of a global one.
* Added "finished" callback to IORequest.
* IOOperation::Finish() no longer invokes its parent request's
  ChunkFinished(). The finisher does this instead. ChunkFinished()
  can optionally remove the chunk from the parent.
* Added IORequest::Wait() which waits for the completion of the request.
* Introduced IORequestChunk::ResetStatus() to make setting the status to
  "pending" somewhat more explicit.
* Implemented the missing IOScheduler::SetCallback() methods.
* The NotifyAll() calls on the IOScheduler's condition variables were
  missing, so it just waited forever.
* Added some more debug output.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26597 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-07-24 01:54:41 +00:00
François Revol 77cbdee787 Add platform specific kernel args, use them to pass nat_feat info so at least the kernel can print something from the emulator...
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26596 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-07-24 01:10:36 +00:00
Maurice Kalinowski dff0e735eb julun+mauricek:
* Cygwin does not have regex support, so we use the one we already have in our glibc.
   * Keymap.h has a automatic forward declaration of re_registers, which causes a compile break on Cygwin, but not on other platforms. So add a include for regex.h in the header and remove it in the source file.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26587 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-07-23 21:40:12 +00:00
Maurice Kalinowski 59c40b2f95 julun+mauricek:
* Cygwin needs some additional defines compared to other platforms
   * Additionally stpcpy and strcasestr are unknown on Cygwin. Thus we need to use the one from our posix library.
   * ECANCELED is not defined on Cygwin, so only add error in case it is.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26584 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-07-23 21:39:13 +00:00
Axel Dörfler b4395038ee * Replaced the sAreaHashLock with an rw_lock.
* As this was the last user of the READ_COUNT/WRITE_COUNT definitions in
  vm_priv.h, I removed those as well.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26582 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-07-23 16:10:52 +00:00
François Revol 8881176ff3 A module that hooks into the debugger to provide it with a demangle() so at least when using C++ in the kernel stack crawls are meaningful.
It does its job by using part of libsupc++, with fake malloc and friends to make sure it won't double fault.
Works here, but cp-demangle must be extracted by hand from the lib, can't get the rule to work as I want, Ingo ?
Maybe using it directly without malloc hack would be ok with 16KB buffer, but I'm not sure of that.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26581 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-07-23 16:08:16 +00:00
Ingo Weinhold e6bd90c58d * bfs_fsync() was the only place which could cause the
fs_vnode_ops::write_pages() to be called with fsReenter = true. Since
  this is no longer the case, the argument has become superfluous. For
  read_pages() it always was. Removed the argument from the functions
  and all functions that propagated it.
* Some whitespace at the end of lines was removed.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26579 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-07-23 15:47:47 +00:00
Axel Dörfler 4ed05c6869 * Replaced the simplistic semaphore based R/W lock in the vm_address_space with
the new rw_lock locking primitive.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26578 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-07-23 15:45:40 +00:00
Ingo Weinhold 5c99d63970 Merged branch haiku/branches/developer/bonefish/vm into trunk. This
introduces the following relevant changes:
* VMCache:
  - Renamed vm_cache to VMCache, merged it with vm_store and made it a
    C++ class with virtual methods (replacing the store operations).
    Turned the different store implementations into subclasses.
  - Introduced MergeStore() callback, changed semantics of Commit().
  - Changed locking and referencing semantics. A reference can only be
    acquired/released with the cache locked. An unreferenced cache is
    deleted and a mergeable cache merged when it is unlocked. This
    removes the "busy" state of a cache and simplifies the page fault
    code.
* Added VMAnonymousCache, which will implement swap support (work by
  Zhao Shuai). It is not integrated and used yet, though.
* Enabled the mutex/recursive lock holder asserts.
* Fixed DoublyLinkedList::Swap().
* Generalized the low memory handler to a low resource handler. And made
  semaphores and reserved memory handled resources. Made
  vm_try_resource_memory() optionally wait (with timeout), and used that
  feature to reserve memory for areas.
...


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26572 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-07-22 20:36:32 +00:00
Karsten Heimrich 12fd6cc2e7 * move libprint sources into libs, as it is a 3rdparty lib
* move libprint headers into libs headers folder accordingly
* merge all shared folders sources into kits print, we might build later on a
  real print kit, propably also to access cups from an nicely API, atm static
* move all shared headers into private print, also pr_server.h from interface
* adjust build to work with the changed folder layout



git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26570 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-07-22 20:30:14 +00:00
Stefano Ceccherini 85f2668898 Patch by Dustin Howett (GSOC): Move ACPI probing out of the
bootloader's smp init and into its own unit.
ACPI tables can now generally be found with acpi_find_table(signature).


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26538 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-07-21 07:13:51 +00:00
François Revol 1b5a395d01 Cleanup and fix 040 definitions.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26529 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-07-20 22:08:39 +00:00
François Revol d14351d2c6 - better not check an entry for validity when we want to fill it
- bitfield definitions of page dirs were reversed... 040 is still wrong though.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26528 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-07-20 21:16:37 +00:00
François Revol 74c5e8bd10 - move VADDR_TO_* to headers
- move part of mmu handling to mmu-dependant files and extend ops
- implemented 040 mmu init. doing so I spotted a bug in ARAnyM which ignored [ID]TT0. Linux likely doesn't use them but I was too lazy touse temporary page tables. I also noticed bitfields were in wrong order, to be fixed.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26527 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-07-20 20:31:48 +00:00
Ingo Weinhold 7cb66f0ff0 Added __printf__ format attribute to TraceOutput::Print().
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26520 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-07-20 12:30:22 +00:00
Jérôme Duval 82e3aced80 updated freetype to 2.3.7
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26495 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-07-19 10:41:42 +00:00
Michael Lotz 69dddbdea1 Initial work towards supporting IO APICs. This cannot work for PCI interrupts
though until we use ACPI for proper PCI IRQ routing through the IO APIC.
Therefore the IO APIC code path is not yet enabled and the IO APIC isn't used.
ISA interrupts would work though, as would PCI interrupts if you'd hardcode
them for your specific configuration.
Note that this change also modifies some parts in the bootloader and in the PIC
setup to make local APICs available even on non-SMP systems. This causes APIC
timers to be used instead the normal PIT if it is available (also on non-SMP
configurations).
Also fixes some general errors in SMP and PIC code as well as some code cleanup.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26492 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-07-18 23:19:41 +00:00
Michael Lotz eb0dca1d33 Add a KDEBUG_ONLY macro for easier handling of code only needed in case of KDEBUG.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26483 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-07-18 02:05:27 +00:00
Oliver Ruiz Dorantes 0a95b2a34b An automatic way to define max number of packet types
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26475 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-07-17 20:38:09 +00:00
Axel Dörfler eaf71fbdb6 * Build fix: coreutils had a replacement for dirfd().
* Made DIR argument const in dirfd().


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26469 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-07-17 01:22:13 +00:00
Michael Lotz d73327e274 Make dirfd() publically available. It used on other systems as well it seems.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26466 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-07-17 01:01:52 +00:00
Axel Dörfler 50baef55f2 * Removed some old working_set/page daemon stuff from the address space.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26457 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-07-16 23:36:25 +00:00
Axel Dörfler 6db6b628d6 * Added B_PHYSICAL_BASE_ADDRESS address specification for anonymous areas.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26456 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-07-16 23:32:25 +00:00
Axel Dörfler 736352dcf5 * Added [un]lock_memory_etc() versions that accept a team_id as first argument.
This allows drivers to lock the memory outside of the original team context.
* create_area_etc() got a struct team as first argument, but that should have
  been a team_id.
* Removed delete_area_etc() - there is already vm_delete_area() doing the same
  thing.
* Renamed vm_get_address_space_by_id() to vm_get_address_space(), as there is
  no other method of getting an address space.
* Removed erroneous white space.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26455 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-07-16 22:55:17 +00:00
Axel Dörfler cb9191556c bonefish + axeld:
* Removed the superfluous "flags" parameter from ConditionVariable::Add()
  that we forgot there when we moved the flags field from
  ConditionVariableEntry::Add() to Wait().
* Using this method was therefore not a good idea - only UnixFifo did, though.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26454 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-07-16 22:43:50 +00:00
Oliver Ruiz Dorantes 6e82afcc18 -Update copyright
-whitespaces cleanups 


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26452 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-07-16 19:30:45 +00:00
Oliver Ruiz Dorantes 7434b76048 Add to the command manager the connection accept and reject commands
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26451 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-07-16 19:25:44 +00:00
François Revol 3a7f25d039 Add identifier for 64 bit float raw audio format, really just to show we can support it without hacking the API :)
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26450 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-07-16 19:06:39 +00:00
Oliver Ruiz Dorantes 870ae24a6d Resolve allocation of multiple Messengers,(Mika Lindqvist)
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26449 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-07-16 19:04:53 +00:00
Stephan Aßmus 1ae794159a * Changed the signature of UpdateText() to return a "const char*" (char*
really makes no sense if the pointer belongs to the derived class and
  only confuses). Note this change does not affect binary compatibility.
* Introduced a new MaxUpdateTextWidth() virtual method which is really
  necessary to handle the update text correctly in the layout.
* Introduced a new UpdateTextChanged() method which can be called to
  notify the control of a changed update text. Internally, SetValue()
  also uses it.
* Handle the width or height of the UpdateText() correctly in the layout.
  For horizontal layout, the width was forgotten to be included in
  GetPreferredSize(), for vertical layout, it was completely broken before.
* Handle invalidation correctly when the UpdateText() changes.
* Remove the arbitrary insets for labels from the border the control. This
  makes it easier to align the control's labels with other controls.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26447 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-07-16 18:37:44 +00:00
Oliver Ruiz Dorantes 0501b7cd80 Add AF_BLUETOOTH sockets family
- Feel free to change the index
 


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26445 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-07-16 17:30:36 +00:00
Stephan Aßmus 423b124450 First round of BSlider fixes to be more layout friendly:
* Improve the minimum size calculation and cache it.
* Invalidate the layout on various property changes that require it.

Vertical BSliders are very broken... that's up next.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26441 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-07-16 14:41:10 +00:00
Stephan Aßmus cdcfa5945d * Added layout friendly constructor
* Use constructor lists for initializing members
* Simplified initial SetBarColor()
* Update the offscreen view with ViewColor() and LowColor(), someone might
  have changed it after AttachedToWindow() was called.
* Cleanup here and there


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26440 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-07-16 13:46:05 +00:00
Stephan Aßmus e87506af4d * Implement SetFont() and invalidate the layout. More controls should probably
do this.
* Fix build, appearantly I made a last minute change in Draw()...

BTW, confirmed that adding virtuals declared in the base class is ok for
binary compatibility.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26425 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-07-15 13:55:44 +00:00
Stephan Aßmus d3fe87ce70 * Cache a fPreferredSize following the example of BButton. Changed
GetPreferredSize() accordingly.
* No longer adds margins to the left/right side and top/bottom. These will
  make it difficult to make exact visual alignments with other controls and
  labels.
* Invalidate the layout in SetText().


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26422 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-07-15 13:20:26 +00:00
Michael Lotz e149b13af5 Avoid redefinition of B_NOT_SUPPORTED on BeOS build platform.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26419 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-07-15 11:53:07 +00:00
François Revol 3594171541 This weren't typedefed, using them without struct is invalid in C.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26412 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-07-14 18:47:02 +00:00
Axel Dörfler b6c3ddcfb4 * Cleaned up odd indentation.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26410 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-07-14 17:30:59 +00:00
Oliver Tappe 49a22456dd Overhauled BNetEndpoint implementation (and BNetAddress, too):
* added NetEndpointTest that exposed a couple of bugs
* fixed several bugs in the implementation of BNetEndpoint, some of which kept 
  NetPenguin from working
* fixed a couple of constness issues in BNetEndpoint and BNetAddress


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26405 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-07-13 19:58:35 +00:00
Ingo Weinhold f9f2d81621 Added helper function get_default_partition_content_name() that can be
used by file systems to get a useful name, if the file system (or just
that specific volume) doesn't have one.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26403 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-07-13 12:50:35 +00:00
Ingo Weinhold 60f2ef17be * Added "partition_id partition" field to fs_volume, so that file
systems can get the partition they reside on easily.
* Updated TODO.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26401 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-07-13 12:47:08 +00:00
Karsten Heimrich a80e05e225 * fixes for ticket #2378
* adjust ui code to be more font sensitive
* add/ rename some of the utils message manipulation functions
* use ReadAttrString instead of ReadAttr to get the printer name



git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26398 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-07-13 11:11:43 +00:00
Karsten Heimrich 4db0488ead * reordered MarinView.h, MarginView.cpp
* rename private functions to use underscore
* rename some public functions to match the usual style
* adjust pdf/ preview driver to use the renamed functions
* we where leaking a single message in _ConstructGui, otherwise no functional change
  


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26396 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-07-12 21:09:49 +00:00
Oliver Tappe aebcc506e2 Corrected by previous assumption, since gethostbyname() has nothing to do with
struct sockaddr_in - the real culprits were BNetAddress::GetAddr(sockaddr_in&)
and BNetAddress::SetTo(const sockaddr_in&):
* moved check_r5_compatibility() into r5_compatibility.h to make that function
  available to BNetAddress, too
* adjusted sockaddr_in-handling methods of BNetAddress to deal with R5-addresses
  if in compatibility mode
* removed is_r5_sockaddr() again, since it is no longer needed

With this less hacky solution, Beam, NetPositive, NetworkTime and Vision still work. So, there's hope that the R5 compatibility layer is now complete.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26377 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-07-10 21:25:19 +00:00
Axel Dörfler b4147ed317 * RescanDiskSystems() now locks the disk device manager, as it clobbers the
disk system lists.
* Added module watching; on module changes, it will now automatically rescan
  the disk systems.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26368 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-07-10 12:21:05 +00:00
Axel Dörfler 30e5affa9f * Added comment about a missing Remove() variant.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26367 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-07-10 12:19:22 +00:00
Axel Dörfler a120934388 * Moved KMessage field printing from vfs_boot.cpp::get_boot_partitions() into
KMessage::Dump().
* Improved message dump output a bit (more concise).
* get_boot_partitions() now simply calls KMessage::Dump() instead.
* Added a KMessage::IsEmpty() method.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26365 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-07-10 10:06:17 +00:00
Stephan Aßmus b09e2f6f4b Patch by Andrej Spielmann (GSOC):
* Extend the app_server protocol by configuration options to turn
  subpixel font rendering on/off and also make the glyph hinting optional
  (aligning of glyph shapes to the pixel grid).
* Implement the setting in the app_server and also handle the persistency.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26362 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-07-10 08:29:50 +00:00
Stephan Aßmus 3a0814fdae patch by Andrej Spielmann (GSOC):
* Prepared the AGG base_renderer code with two more functions needed to
  handle subpixel scanline coverage values.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26356 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-07-10 08:11:04 +00:00
Axel Dörfler 8d79c7db81 * Made Dump() const.
* Removed superfluous whitespace.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26347 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-07-09 21:32:37 +00:00
Oliver Ruiz Dorantes d04eb939af -Move the launching of the Local Device to an IOCTL from the open hook to be more compatible with the net_stack
-Implement Launch method in the accesors regarding previous comment
-Fix KDL at removing device



git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26345 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-07-09 17:01:30 +00:00
Ingo Weinhold 383a9ac435 * Added an explicit boot_splash_uninit(). Not really needed, but makes
it clear when boot_splash_set_stage() must no longer be used.
* Free the memory associated with the kernel args before starting the
  init process. Unlike the original TODO stated there are quite a few
  more users of the kernel args (including the boot splash screen),
  hence we can't really do that earlier, unless we decide to copy the
  data over to the kernel heap. 


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26344 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-07-09 15:25:01 +00:00
Stephan Aßmus bb73c05fd7 * Introduced a new view event mask flag: B_FULL_POINTER_HISTORY which,
when set, prevents any old mouse moved message discarding.
* BWindow::DispatchMessage(B_MOUSE_MOVED) checks the event time of the
  message and discards too old events, but only if there is another event
  in the queue and the view does not specify B_FULL_POINTER_HISTORY.
* BView::GetMouse() ignores the checkHistory flag passed to the function
  in case the event mask specifies B_NO_POINTER_HISTORY.
  B_FULL_POINTER_HISTORY on the other hand prevents the dropping of old
  messages.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26341 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-07-09 14:13:03 +00:00
Axel Dörfler 191a03fd11 * {add|remove}_node_listener() erroneously had "dev_t" as type of "node".
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26340 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-07-09 13:04:54 +00:00
Axel Dörfler 9c5c79ad86 * Made DIR definition private, and moved it into the new dirent_private.h
header.
* Added fields necessary to make it possible to retrieve more than one
  dirent from the underlying file system.
* Unless some app creates a DIR on its own to it to feed readdir(), this
  change should be binary compatible. If we find an application misbehaving,
  we can still make it a GCC4 only thing.
* fs_attr/fs_index/fs_query now all use readdir() directly (as that one
  contains the logic to iterate through a number of dirents in userspace).


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26339 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-07-09 11:16:00 +00:00
Axel Dörfler 78b32dd026 * The rw_lock is now able to nest read/write locks when you have a write lock.
It follows the semantics of the BFS R/W lock, though, that is, if you unlock
  your write lock before the read locks, the read locks effectively become
  write locks, too.
* Added a mutex_transfer_lock() function that will allow you to unlock a mutex
  in a different thread than the one which locked it (only matters if KDEBUG
  is enabled, though).


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26316 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-07-08 07:56:49 +00:00
Karsten Heimrich f56301c9e8 * maintain our own rect while printing, this makes it possible to print all pages e.g. syslog from StyledEdit
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26304 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-07-07 19:10:39 +00:00
Axel Dörfler 06d5e1b3b6 * Added ReadLocker/WriteLocker classes to auto lock an rw_lock.
* Added *_init_etc() functions to the fs_shell.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26302 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-07-07 18:12:33 +00:00
Axel Dörfler e2dfe00484 * Replaced most of the error enums with #defines.
* fssh_auto_locker.h should probably better use an FS-Shell header instead of
  stddef.h.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26301 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-07-07 18:10:21 +00:00
Axel Dörfler e0fc5e7380 * The fssh_auto_locker.h header was not self-contained.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26299 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-07-07 16:26:57 +00:00
Axel Dörfler af370c702a * Added a recursive_lock_trylock() function.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26297 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-07-07 16:17:34 +00:00
Axel Dörfler 589f1a9133 * Made the private kernel locking primitives available to file systems as well.
* Applied Korli's mutex_unlock() fix to block_cache.cpp.
* Removed block_cache_priv.h, as it's no longer needed (moved its definitions
  into block_cache.cpp, as in the kernel file).


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26296 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-07-07 15:19:19 +00:00
Axel Dörfler 52ecda6ecf * Added some optional KDL command and statistics to the file map implementation.
* Turned them on for now.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26291 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-07-07 12:02:24 +00:00
François Revol 26e45f0523 Would work better with the definition...
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26289 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-07-07 11:30:12 +00:00
Oliver Tappe 1aa3d2e3f3 Resolved a couple of problems in BNetAddress implementation:
* fixed several byte order inconsistencies, it does not make sense to always
  convert the byte order input/output values - no we convert where it can
  be expected and leave it where it is confusing
* fixed size inconsistencies with respect to family and port, both of which
  were sometimes handled as int8, as int16 and as int32 in different places
  (now they are always int16)
These fixes make Beam connect to the correct address and port, but it still doesn't work, as it seems to be using UDP instead of TCP (doh!). Will look into that tomorrow.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26269 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-07-05 22:37:06 +00:00
Stefano Ceccherini 165db546bf should've been part of the previous commit.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26266 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-07-05 20:45:17 +00:00
Stefano Ceccherini 6e29a04d36 Patch by Dustin Howett which 'modularizes' timers. The best timer is
automatically selected at boot time. Pit and Apic timers are implemented
for now. Thanks Dustin!



git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26265 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-07-05 20:40:06 +00:00
Axel Dörfler 0875ae984f * Preparations for a module listener API - this will be used in the (disk)
device managers.
* Cleanup.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26239 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-07-03 11:52:36 +00:00
Oliver Ruiz Dorantes 75c310bc5b Fix EOL
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26232 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-07-02 21:12:07 +00:00
Oliver Ruiz Dorantes ade530ec1d Fix EOL
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26231 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-07-02 21:10:24 +00:00
Oliver Ruiz Dorantes c8bc2d8897 Fix EOL
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26228 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-07-02 20:01:02 +00:00
Oliver Ruiz Dorantes 9bfe62f9aa Cleapups, Fix memory leaks,
Patch by Mika Lindqvist. Could we give give him Commit access? 
I am getting daily patches from him with fixes and new features.
 


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26227 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-07-02 19:41:45 +00:00
Jérôme Duval 765ae3a785 Applied patch from Mika Lindqvist: This patch implements both strlwr() and strupr() functions in libroot and includes strupr() in kernel build.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26226 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-07-02 19:30:46 +00:00
Michael Lotz b1f4df4a62 Implement heap classes that each have their own range of allocation sizes they
serve, bin sizes and page size. This minimizes the amount of "large"
allocations made in heaps that don't have a bin for the allocation size
(combining multiple pages). This is desirable as such large allocations
are generally pretty inefficient, and also because it separates larger from
smaller allocations better, making the chance of a heap becoming empty higher.
For now there are three heap classes "small", "large" and "huge", with a
predefined set of bin sizes for each. This might need some finetuning later on.
Reduce the grow size to 4MB though as the allocations should now be spread
across heap classes which each grow on their own.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26210 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-07-01 23:19:35 +00:00
Oliver Ruiz Dorantes 51ac4f530a Patch by Mika Lindqvist
FromString Implementation for the bdaddr utils class 



git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26182 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-06-30 21:43:21 +00:00
Axel Dörfler 8531599a27 * KDiskDeviceManager::RescanDiskSystems() now also rescans all partitions with
the newly found disk systems.
* _ScanPartition() now allows to restrict the disk systems to a predefined set.
* _ScanPartition() now even scans partitions that already have a disk system
  assigned; if a better one is found, the existing one is replaced. It will
  ignore mounted or partitions with children, though.
* KPartition now also stores the priority of the disk system assigned to it.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26177 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-06-30 10:36:47 +00:00
François Revol ff41eb66a3 Fix build.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26171 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-06-29 21:08:12 +00:00
François Revol f41c3a5bcd - Move Atari platform class out to a platform file.
- Use the platform object to determine the platform type in system_info.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26166 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-06-29 18:22:34 +00:00
Ingo Weinhold e1b630c55d * Replaced the global cache pages hash table by an IteratableSplayTree
per cache.
* Changed the strategy vm_cache_acquire_page_cache_ref() uses to ensure
  that the cache isn't deleted while trying to get a reference. Instead
  of the global cache pages hash table lock, it holds the global cache
  list lock now. We acquire + release this lock in delete_cache() after
  removing all pages and just before deleting the object.
* Some small optimizations using the property that the cache's pages are
  ordered, now (vm_cache_resize(), vm_page_write_modified_page_range(),
  vm_page_schedule_write_page_range()).
* Replaced some code counting a cache's pages by simply using
  vm_cache::page_count.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26160 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-06-28 23:42:41 +00:00
Ingo Weinhold c84d037f75 Added templatized SplayTree class derived from a Java implementation by
D. Sleater. Also added a IteratableSplayTree class that extends
SplayTree, additionally maintaining a singly-linked list, thus allowing
for efficient forward iteration.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26159 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-06-28 23:22:43 +00:00
Rene Gollent 84d75fa444 Rewrote SwapItems() so as to not fail in various cases.
Fixed logic error in CountItemsUnder() that would sometimes 
return the wrong count. This would result in issues such as
Vision's network reordering failing to reorder down due to
retrieving the wrong item based on the count.

This fixes ticket #2447.
 


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26149 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-06-28 03:03:56 +00:00
François Revol 63dff3f9a3 Placeholder for ARM.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26133 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-06-25 22:57:34 +00:00
Salvatore Benedetto 93dd5d6569 * Fix typo. Thanks mjw!
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26132 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-06-25 19:29:03 +00:00
Ingo Weinhold 276aa463ef * Replaced the useless InitCheck() method in {Open,Multi}HashTable (it
always returned B_OK) by a Init() method, which sets the initial size
  and returns an error, if that fails.
* Adjusted code using the classes accordingly. Replaced a few
  InitCheck() methods in the network code by Init().


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26127 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-06-24 22:23:57 +00:00
Axel Dörfler 9c557206db * Rewrote NetKit.h, and added the libnetapi headers.
* This closes bug #2444.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26120 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-06-24 09:03:44 +00:00
Ingo Weinhold 2965c99fea * Changed the _kern_exec() and _kern_load_image() syscalls. They expect
a flattened argument/environment buffer now. This simplifies the work
  for the kernel a bit, since it can just copy the buffer and check
  whether it looks OK instead of messing around with individual strings.
  The runtime loader also gets a flattened array.
* Set the maximum size of the arguments/environment buffer to 128 KB.
  When more arguments are passed, we fail with a proper error code
  (instead of just truncating the arguments as before).
* On exec*() the first argument was silently replaced by the given path
  name, which is not correct.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26119 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-06-24 03:37:07 +00:00
François Revol 5da61ace79 - 040 mmu descriptors, FIXME
- remove unneeded include to make those usable by bootloader.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26117 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-06-23 23:15:43 +00:00
François Revol 1fd024be6a - missing ppc stub
- kernel_m68K almost links now, jsut bails out on the linker script...


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26096 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-06-23 03:28:18 +00:00
François Revol f0c5a3da4b - Add missing globals
- stubbed commpage stuff.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26094 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-06-23 01:54:18 +00:00
François Revol 30629f410c - move atari platform subclass to platform/atari_m68k/
- fix exception handling, at least it builds now.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26089 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-06-23 00:16:23 +00:00
François Revol 375be9fa40 Add a machine type field. It should hold a platform dependant type. On Atari it's the high word of the _MCH cookie (2=TT,3=Falcon,5=ARAnyM).
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26085 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-06-22 20:57:49 +00:00
François Revol 35471ac53e - add fpu states
- add needed asm_offsets
- start of exception handling


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26073 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-06-22 01:36:52 +00:00
François Revol b409283372 Set max cpu count to 1 for ARM. Anyone knows a real SMP platform using it ?
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26069 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-06-21 21:48:18 +00:00
Salvatore Benedetto e65b3b4eac * Let's keep the alphabetical order
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26049 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-06-20 22:45:33 +00:00
Salvatore Benedetto 242b8e12a3 * Added italian keymap
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26048 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-06-20 22:40:15 +00:00
François Revol 04390361b5 - comment
- fix building arch_debug. Misses many regs still.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26042 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-06-20 02:22:26 +00:00
François Revol a3dc7ef06c - some cpu and platform fixes.
- we'll just use decimal chip number (68030, ...) to identify cpu, fpu, and mmu for simplicity.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26041 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-06-20 02:11:45 +00:00
Stephan Aßmus d6b036858b Move the now used boolean to the old place in order to avoid different padding
to happen and therefor changing the object size.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26021 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-06-19 14:17:56 +00:00
Stephan Aßmus eaa6da1ef7 Use a flag in BWindow to store whether an update to a view (Invalidate()) has
been requested. The first call to a BView::Invalidate() will flush the link
so that app_server is notified as soon as possible. It makes no sense for
further calls to Invalidate() to flush also, since Flush() is not cheap. This
trick makes Invalidate() about 3.2 times faster, making it a cheaper operation.
I could not see any negative effects, I tested with apps that invalidate
multiple different parts inside a window in reaction to something. Thanks go to
Ingo who had the idea.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26020 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-06-19 13:07:44 +00:00
Ingo Weinhold a2cf1d70ef Removed <syscalls.h>' dependency to <semaphore.h> by giving the sem_t
structure a name.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26015 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-06-19 00:05:01 +00:00
Ingo Weinhold 37deb72914 Define INT32_MAX, if not defined.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26014 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-06-19 00:03:56 +00:00
Oliver Ruiz Dorantes 24f4a20d25 Add UI classes to the build.
Adding some helper methods to the Local and remote devices



git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26011 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-06-18 21:01:26 +00:00
Oliver Ruiz Dorantes b12daa5f08 Add UI classes for handling incoming connections and pincode requests
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26010 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-06-18 20:57:27 +00:00
Michael Lotz df7096a4aa * Added malloc_nogrow() function that does allocation without triggering or
waiting for a heap grow.
* Use that nogrow version in the VM code to avoid a deadlock with the address
  space lock when a grow operation would try to create an area while a malloc
  happened from such a function in the VM.
* When waiting for a grow to happen, notify the waiting thread from the grower
  also if it failed to allocate a new heap. Otherwise a thread would just sit
  there and wait until another thread requested growing too and that one
  succeeded (or just forever in the worst case).
* Make the dedicated grow heap growable too. If the current grow heaps run low
  on memory it will instruct the grower to allocate a new grow heap. This
  reduces the likelyhood of running out of memory with no way to grow to a
  minimum. As the growing is done asynchronously it is still possible to
  happen, but it is highly unlikely as the grow heap is solely used to
  allocate memory in the process of creating new heap areas and it will even
  try using normal public memory if the dedicated memory has run out.
* Reduced the dedicated grow heap from 2 to 1MB. As it can now grow itself, it
  doesn't need to last so long.
* Extract heap creation into it's own function that does area creation and heap
  attach and use this function for growing normal and grow heaps.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26009 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-06-18 19:55:51 +00:00
Oliver Ruiz Dorantes 0df89492fb -Wrong header for function,
indenting...


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26008 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-06-18 19:17:35 +00:00
Rudolf Cornelissen 6ffc2359d4 removed last G8x defines.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26000 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-06-17 19:27:38 +00:00
Rudolf Cornelissen f433117839 removed all pre-NV40refs, removed all overlay code (no info on the current engine known). Driver cleanup mostly done now I hope.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@25999 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-06-17 19:16:40 +00:00
Jérôme Duval 49a0ff0c19 updated freetype to 2.3.6
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@25977 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-06-16 20:51:14 +00:00
Axel Dörfler 2d5f339dec Patch by Christopher Plymire, style-reworked by myself:
* first steps of supporting LVDS panels.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@25975 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-06-16 18:01:34 +00:00
Maurice Kalinowski 53779f07a4 fix gcc4 warning about wrong argument type.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@25967 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-06-15 19:21:00 +00:00
Rene Gollent 0c8bdbafd5 Revamp BList somewhat to further optimize the resizing behavior.
We now keep track of a lower bound as to when the list should scale
itself back down. When increasing the list size, we double the current,
with the lower bound set to 1/4 of the current size, not allowing it to
go any smaller than the block size. These combined allow us to do very
cheap tests to see if an operation requires a resize at all, and minimize
how often the list actually needs to be resized, since the difference in upper
and lower bounds prevents bouncing back and forth between a size in the case
of adding/removing an item while close to a boundary. All in all this should
make BList noticably more scalable when doing large numbers of add/remove
operations.



git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@25946 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-06-12 21:30:28 +00:00
Oliver Ruiz Dorantes c15ecd98ca - Add some core code for the L2CAP layer (l2cap commands)
- Tailor a bit the main module
- Fix definitions in the main header




git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@25943 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-06-12 19:31:29 +00:00
Oliver Ruiz Dorantes 350458a6ba - Add PinCode command replies
- Add CancelInquiry command


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@25942 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-06-12 19:18:32 +00:00
Rudolf Cornelissen 730ebb158c removed all pre-NV20 refs, removed all TVout stuff except clearing some flags, re-enabled force_ws option, force_ws is now default true, pgm_panel is now default false.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@25929 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-06-11 18:14:15 +00:00
François Revol 9f0d1cf39d Remove PAGE_SIZE define for ppc and m68k from kernel private headers. It's not needed there and should be in public header anyway.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@25921 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-06-11 01:16:48 +00:00
Rudolf Cornelissen 8981fa5d54 removed PIO mode acceleration completely.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@25908 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-06-10 17:56:54 +00:00
Rudolf Cornelissen b11432e092 removed all references to G80 and newer cards.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@25905 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-06-10 11:10:52 +00:00
Rudolf Cornelissen 0ddc7716d4 headers for nvidia_gpgpu driver
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@25874 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-06-09 14:53:17 +00:00
Michael Lotz ca7b0f375e Patch by Olivier Coursiere that removes unneeded special characters.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@25870 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-06-08 21:48:23 +00:00
Michael Lotz cfbfa8bade Add french KDL keymap contributed by Olivier Coursiere, thanks!
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@25858 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-06-08 00:32:14 +00:00
Stephan Aßmus 3d4b8c879e Added one more define that helps when host headers are included.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@25838 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-06-07 12:39:14 +00:00
Stephan Aßmus 896d01df1e Removed trailing white space.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@25837 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-06-07 12:38:28 +00:00
Jérôme Duval 75d2085651 fixed listdev and device_manager syscalls
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@25833 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-06-06 22:23:25 +00:00
Axel Dörfler 3b2c863f1c The "search.h" header had a couple of issues:
* It was not self containing, as it used size_t without defining it.
* It was not C++ safe.
* It used the restrict keyword that is not recognized in GCC2. This fixes bug
  #2262.
* It did not contain parameter names as demanded by our coding style.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@25818 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-06-06 07:42:58 +00:00
Michael Lotz f5b3a6a796 * Initialize all static mutexes in the kernel through a MUTEX_INITIALIZER()
and remove the then unneeded mutex_init() for them.
* Remove the workaround for allowing uninitialized mutexes on kernel startup.
  As they are all initialized statically through the MUTEX_INITIALIZER() now
  this is not needed anymore.
* An uninitialized mutex will now cause a panic when used to find possibly
  remaining cases.
* Remove now unnecessary driver_settings_init_post_sem() function.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@25812 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-06-05 23:19:27 +00:00
Michael Lotz 2c19d5ec25 * Add Dvorak keymap contributed by Darian Rackham, thanks!
* Cleanup the license header and add authors
* Sort the available keymaps list in the config file and add 'dv'

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@25806 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-06-05 16:34:30 +00:00
Michael Lotz 01e46bdb18 * Extract the KDL keymap to a separate header and provide a 'sg' swiss german
keymap there too.
* Add a config header where one can select what KDL keymap should be used
  (currently only 'us' and 'sg' are available though).
* Provide a third keymap that is used when the alt modifier is used (the swiss
  german keymap is pretty useless without alt as all the useful keys like
  backslash and curly braces use alt).

Our KDL is so powerful and nice to use, the only thing that bothered me was
that I always had to think about where some of the special keys are located in
the US keymap. So this simple compile-time keymap switching provided to be
helpful for me and might be for others too. Keymaps for other layouts obviously
have to be written before this becomes really useful.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@25803 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-06-04 17:56:30 +00:00
Axel Dörfler 0dedf9f081 * Removed the now superfluous pnp_devfs.h header.
* There was a leftover in devfs that still needed it.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@25800 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-06-04 10:38:59 +00:00
Jérôme Duval a5f249c795 use the typedef
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@25798 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-06-03 20:13:59 +00:00
Rene Gollent 6cd1b6f737 Fix GCC4 build.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@25797 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-06-03 19:24:56 +00:00
Axel Dörfler a2e19c60e2 This should have been part of r25793.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@25794 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-06-03 17:45:54 +00:00
Axel Dörfler 6ec21b4ad3 * Implemented retrieving additional bitmap support flags by the app_server.
* Added B_BITMAPS_SUPPORT_OVERLAY flag to indicate overlay support for the
  color space.
* Rewrote GraphicsDefs.h - the previous one was obvious a copy of the Be header,
  including typos and strange white space. I was a bit lazy with respect to
  the color space details, and mostly trusted the information provided by the
  Be header else.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@25793 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-06-03 17:44:46 +00:00
Axel Dörfler d16ddc579c * The boot loader now passes on its EDID info to the kernel, and that will
be put into a boot_item in frame_buffer_console_init().
* The VESA driver now supports gettings the EDID information as well; this
  is necessary now, since the app_server no longer takes over the mode the
  boot loader had chosen.
* Note, we might want to do this via vm86 instead in the future, and remove
  the kernel part again.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@25786 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-06-03 15:17:59 +00:00
Stefano Ceccherini fa827b37fc took the liberty to add this to the buiild and fix compilation :)
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@25774 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-06-03 05:02:59 +00:00
Stefano Ceccherini 54d9d37f9d Added patch by Dustin Howett: header with HPET definitions and (empty)
file for hpet implementation. Not yet added to the build.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@25773 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-06-03 04:37:18 +00:00
Oliver Ruiz Dorantes 3e24801283 L2CAP, without functionality, for the moment my playground in the netstack
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@25768 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-06-02 20:16:00 +00:00
Ingo Weinhold 1c8de8581b * Added optional spinlock contention measurement feature. Enabled when
B_DEBUG_SPINLOCK_CONTENTION is defined to 1. It typedefs spinlock to a
  structure (thus breaking BeOS binary compatibility), containing a
  counter which is incremented whenever a thread has to wait for the
  spinlock.
* Added macros for spinlock initialization and access and changed
  code using spinlocks accordingly. This breaks compilation for BeOS --
  the macros should be defined in the respective compatibility wrappers.
* Added generic syscall to get the spinlock counters for the thread and
  the team spinlocks.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@25752 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-06-02 02:04:12 +00:00
Ingo Weinhold 73aa393d73 * Introduced pipes in the kernel debugger. The syntax is similar to
pipes in the shell, though the semantics is a little different: The
  second command is invoked whenever the first command has written a
  complete line. The line is passed as last argument to the second
  command. The new command flag B_KDEBUG_PIPE_FINAL_RERUN causes the
  second command to be invoked again (with NULL argument) after the
  first command is done.
* Added kprintf_unfiltered() and kputs_unfiltered() which bypass the
  pipe mechanism and directly print to the bluescreen/serial output.
* Moved most commands from debug.cpp to the new
  debug_builtin_commands.cpp.
* B_KDEBUG_DONT_PARSE_ARGUMENTS commands don't get an argument anymore,
  if it would consist of white space only.
* Added new debugger command return value B_KDEBUG_ERROR, which
  indicates that executing the command failed. This return code will
  abort a complete pipe.
* Since debugger commands can nest (i.e. one command can invoke another
  one) the setjmp()/longjmp() mechanism to restore the stack after a
  page fault in a command needs more than one jump buffer.
* Added abort_debugger_command(), which longjmp()s out of the currently
  executed command. This will also abort the current pipe.
* When pagination is enabled pressing "a" will abort the running command
  (as opposed to "q" which only disables the blue screen output, but
  lets the command continue).
* Added debugger commands:
  - "grep" which can be used to filter output by pattern. Removed the
    "filter" command and the underlying mechanism that did that before.
  - "head" which prints only the first lines of output of another
    command.
  - "wc" counts lines, words, and characters of another command's
    output.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@25744 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-06-01 02:25:00 +00:00
Jérôme Duval 4eae685d97 replaced benaphore with mutex
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@25742 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-05-31 19:50:53 +00:00
Axel Dörfler e67cf5815b * Minor cleanup.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@25738 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-05-31 12:04:09 +00:00
Axel Dörfler fc128a4c76 * Made block_io.h usable from C++ (which doesn't like "typedef a *a" anymore).
* Renamed scsi_dsk to scsi_disk.
* Joined all scsi_disk sources together to a single scsi_disk.cpp file.
* Cleanup.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@25737 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-05-31 11:59:02 +00:00
Stephan Aßmus 590c0d667c Darn... should have been part of my last commit:
Export the Read/Write locking strategies from the BPrivate namespace. Fixes
Icon-O-Matic build (RWLocker).


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@25721 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-05-30 14:12:04 +00:00
Ingo Weinhold 72e3b6ffd3 Missing prefix.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@25712 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-05-29 20:51:59 +00:00
Axel Dörfler f20a8750cb * Enlarged the default BLooper port capacity to 200 messages. Since limiting
the message count doesn't really make much sense anyway (as opposed to
  limiting the maximum size of waiting messages), we might still want to
  enlarge this even more.
* This should further help with #2212.
* Minor cleanup.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@25709 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-05-29 18:24:19 +00:00
Ingo Weinhold 9101535322 Added new kernel thread "undertaker" which gets rid of dead thread
remains. This replaces the previous mechanism of switching the thread to
a dedicated death stack. We might consider moving more cleanup work to
the undertaker, but that seems a little more involved.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@25704 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-05-29 14:28:31 +00:00
François Revol ebc5ec193f fix gcc4... and style rules. I won't be the only one paying beers at BeGeistert ;)
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@25701 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-05-29 12:44:18 +00:00
Axel Dörfler 44b6c0f4b6 Oops, this shouldn't have been part of this file, forgot to delete it when
copying from the playground.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@25700 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-05-29 12:28:13 +00:00
François Revol 5bd8987ff0 fix C++ linkage of global var... it shouldn't be here anyway, but I suppose it's temporary.
This should fix the (gcc4 at least) build.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@25697 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-05-29 11:25:33 +00:00
Stephan Aßmus 5ebabf0952 Added new line at end of file.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@25694 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-05-29 08:32:12 +00:00
Ingo Weinhold 2daa4194d4 Added macros for static initialization of mutexes, recursive locks, and
R/W locks.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@25691 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-05-29 02:10:10 +00:00
Ingo Weinhold 2b07b8e0f1 * Replaced all instances of benaphores in the kernel code by mutexes.
* Removed kernel benaphores.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@25690 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-05-29 02:08:23 +00:00
Ingo Weinhold 1c18a5df87 Replaced R/W lock implementation. Should have a little less overhead
than a semaphore, and can already be used in the early boot process.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@25689 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-05-29 00:32:06 +00:00
Ingo Weinhold b0f5179aa5 * Changed recursive_lock to use a mutex instead of a semaphore.
* Adjusted code using recursive locks respectively. The initialization
  cannot fail anymore, and it is possible to use recursive locks in the
  early boot process (even uninitialized, if in BSS), which simplifies
  things a little.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@25687 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-05-28 23:12:36 +00:00
Ingo Weinhold 90ca025688 Removed prototypes for openpty() (which lives in pty.h) and forkpty()
(which we don't implement ATM). Why do we have a header that declares
stuff that is for the most part not supported?


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@25684 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-05-28 20:44:47 +00:00
Ingo Weinhold d46a010c43 Patch by Vasilis Kaoutsis: Added sigpause().
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@25682 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-05-28 15:28:49 +00:00
Axel Dörfler 9f16184577 Patch by Jan Klötzke with minor changes by myself:
* Use vm86 mode to call the VESA BIOS to do the actual mode switching by
  providing an ioctl in the vesa driver.
* Fix vm86.h.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@25680 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-05-28 10:48:01 +00:00
Axel Dörfler 9c20d5cb7d * Fixed the byte order definitions.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@25671 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-05-27 12:42:04 +00:00
Axel Dörfler 187c576425 * Added sys/ipc.h header. As the functionality has not yet been implemented,
I added an #error directive, so configure scripts shouldn't be fooled.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@25663 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-05-26 16:55:57 +00:00
Axel Dörfler 368167ede8 * Integration of the new driver architecture.
* Moved devfs from fs/ to device_manager/, and separated the legacy driver
  support from it.
* Removed fast_log module.
* There are a couple of (temporary) regressions, though:
  - legacy SATA and ISA IDE support is disabled, the drivers haven't been
    ported yet.
  - The not yet used ATA bus manager hasn't been ported yet, either.
  - AHCI changes have not been tested.
  - the listdev command has been removed from the build (as it currently
    doesn't work anymore).
  - device manager generated IDs currently are not freed anymore when a device
    node is removed.
  - generic drivers can't yet use the new driver architecture.
  - simple busses that do not support device types won't work yet.
  - legacy driver publishing/unpublishing (ie. what USB needs) has not been
    tested, and may be broken.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@25662 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-05-26 16:52:27 +00:00
François Revol cb63d44e7a Remove hardcoding of endianness... that'll likely help ppc :)
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@25655 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-05-25 20:12:00 +00:00
Stephan Aßmus 5b30a26b7c Added additional font face flags for "condensed", "light" and "heavy".
Our font has some extra styles and these could be picked up as the
"regular" face by accident, as witnessed by Firefox. Tracked down by
Michael Lotz. Firefox uses the correct font now for it's interface.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@25636 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-05-24 14:54:18 +00:00
Marcus Overhagen 33e9755153 Small cleanup of ahci driver. Also clear the PCI interrupt disable bit during setup.
Add PCI command ID (interrupt disable) define to PCI.h


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@25634 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-05-24 13:40:58 +00:00
Axel Dörfler a411c76cd6 * Added pthread_attr_setscope(), and pthread_attr_getscope(). We only support
PTHREAD_SCOPE_SYSTEM which makes the implementation rather simple.
* This closed ticket #2242.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@25628 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-05-23 11:24:40 +00:00
François Revol 74be35c78b Some more funny sysconf()...
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@25627 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-05-23 01:38:05 +00:00
François Revol 4b9329efe1 Define PAGE_SIZE and PAGESIZE in limits.h. It should really depend on B_PAGE_SIZE, but I'm not sure we can #include anything in there...
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@25626 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-05-23 01:01:57 +00:00
François Revol 3a17a548da - factored out [f]pathconf().
- *pathconf() now uses statvfs and fs_info data when appropriate. It should also check for file type though, some only apply to directory or others.
- added confstr(_CS_PATH) with a sensible default.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@25625 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-05-23 00:33:08 +00:00
François Revol ca974ded95 Some more [f]pathconf() names, not yet handled. filesizebits returns 64 though.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@25623 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-05-22 23:22:26 +00:00
Ingo Weinhold 0f448d21e5 * Added vm_page_write_modified_page_range(), which is similar to
vm_page_write_modified_pages(), save that it only writes pages in the
  given range.
* Added vm_page_schedule_write_page_range() which schedules all modified
  pages in the given cache's range for writing by the page writer.
* Added _kern_sync_memory() syscall and the msync() POSIX function.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@25620 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-05-22 21:51:12 +00:00
Axel Dörfler 15173df4e9 Last patch of the vm86 patch series from Jan Klötzke - thanks!:
* The new function vm86_do_int(struct vm86_state *state, uint8 vec) provides a
  facility to call BIOS interupt handlers. The function must only be called from
  a user thread context because the lower 1MB of the address space is used.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@25610 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-05-22 13:54:28 +00:00
Axel Dörfler 7da0a81c0e Patch by Jan Klötzke (with additional TODO comments):
* Add a "fault_callback" to the thread structure which is called when a
  unhandled page fault happens in user space. A SIGSEGV will only be sent
  if the callback returns "true".


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@25609 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-05-22 12:33:30 +00:00
Axel Dörfler bb107c4e29 Patch by Jan Klötzke:
* In vm86 mode CS will have arbitrary values so we check for both USER_CODE_SEG
  and the VM flag in EFLAGS. This is also done when entering interrupt gates.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@25607 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-05-22 11:59:47 +00:00
Stephan Aßmus ae6b38b83e Patch by Andreas Faerber:
* Added "struct" to ancillary_data_container which fixes the build of the
  Bluetooth h2generic driver.
---
* Updated license header.
* Honour 80 char line width.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@25606 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-05-22 11:59:26 +00:00
Ingo Weinhold f3917584f1 Added missing INET_ADDRSTRLEN.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@25598 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-05-21 22:37:42 +00:00
Oliver Ruiz Dorantes 0963754edf Create a parent class for the 2 devices class (RemoteDevice LocalDevice)
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@25596 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-05-21 21:56:55 +00:00
Ingo Weinhold 43a4a6bacb Forgot closing parenthesis.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@25593 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-05-21 21:08:47 +00:00
Ingo Weinhold 3021393e36 Let's pretend we support POSIX threads.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@25588 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-05-21 00:03:09 +00:00
Ingo Weinhold 9ac19900c4 Added LOG_UPTO() macro. Not part of POSIX, but widely used anyway.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@25587 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-05-21 00:02:26 +00:00
François Revol e2a938c274 Add define for the kernel area to ppc & m68k. They still don't initialize TLS though.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@25584 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-05-20 21:28:32 +00:00
Axel Dörfler 35db13ea5a * Replaced the old s3savage driver with the new s3 driver, both written by
Gerald Zajac. Thanks a lot!
* Also put it on the image by default.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@25583 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-05-20 21:09:49 +00:00
Ingo Weinhold a8af2b6dda Some work on pthreads:
* Made the pthread_cond_t internals public. This is necessary to support
  process shared condition variables. Fixed initializer macro.
* Made the pthread_rwlockattr_t structure opaque.
* pthread_t is no longer typedef'ed to int. It's the pointer to the
  internal _pthread_thread structure.
* Removed __get_pthread(). pthread_self() can be used instead.
* No longer tunnel the pthread exit value through Haiku's thread exit
  value. We do have a separate field in the _pthread_thread structure
  for it, now.
* Handle detaching of threads correctly.
* pthread_rwlockattr_{g,s}etpshared() use the
  PTHREAD_PROCESS_{SHARED,PRIVATE} constants, now.
* Commented out yet unsupported structures (barriers, spinlocks).
* Rebuilt APR optional package. The pthread changes weren't binary
  compatible.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@25582 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-05-20 20:43:28 +00:00
Ingo Weinhold 89d327d66e Added missing spwd::sp_lstchg field.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@25560 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-05-19 02:16:12 +00:00
Marcus Overhagen 694c3b75f4 fix bridge control register size
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@25551 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-05-18 21:21:39 +00:00
Marcus Overhagen 1eace5fc53 fixed typo again ;)
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@25548 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-05-18 20:59:14 +00:00
Marcus Overhagen be121a1c53 fixed typo
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@25547 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-05-18 20:57:49 +00:00