Commit Graph

6532 Commits

Author SHA1 Message Date
Ingo Weinhold 0ee9bc97d0 Build libpackage for the build platform 2011-07-17 16:54:10 +02:00
Ingo Weinhold d451f7a329 Added several APIs to libbe_build/libshared_build 2011-07-17 16:54:09 +02:00
Ingo Weinhold a7bcad8194 Updated to current Haiku version 2011-07-17 16:54:09 +02:00
Ingo Weinhold f1eeb32334 Fixed x86_64 handling by the build system.
* Map build variables HOST_CPU and HOST_ARCH to x86_64, if it they are
* x86 and
  64 bit and define the __x86_64__ C macro instead of __INTEL__ in that
case.
* <OS.h>: Also handle __x86_64__.
2011-07-17 16:54:08 +02:00
Ingo Weinhold 1044b2eb82 Added missing <StorageDefs.h> include. 2011-07-17 16:54:07 +02:00
Ingo Weinhold bd9d1df3a0 Added very simple BLooper class to libbe_build. 2011-07-17 16:54:06 +02:00
Oliver Tappe 3dfd9cb95c Flat commit of all changes from package-management branch in svn 2011-07-17 16:54:06 +02:00
Ingo Weinhold b353a9a30a ANSI C doesn't like unnamed unions.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@42444 a95241bf-73f2-0310-859d-f6bbb57e9c96
2011-07-17 13:57:30 +00:00
Axel Dörfler 95009aeeb0 * Imported Andy Ritger's GTF code in compute_display_timing.cpp, and mangled it
into a usable function - this has some coding style issues I did not care to
  fix.
* _AddBaseMode() now computes the mode in case it is not present in the list
  yet.
* This should help with bug #7787.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@42420 a95241bf-73f2-0310-859d-f6bbb57e9c96
2011-07-13 23:26:26 +00:00
Philippe Saint-Pierre 8ec0a4a37d Cpu Identification :
* Don't return Core 2 Extreme as a fallback result, keep the more generic variant Core 2 for this.
 * Test the presence of "Pentium" in the name and in that case, use that word to identify, despite
   the family id/product name confusion.

Might fix #6136, #4427.  needs testing.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@42405 a95241bf-73f2-0310-859d-f6bbb57e9c96
2011-07-10 21:03:53 +00:00
Ingo Weinhold 85b41b15d9 * Added bool and double BString::operator<<() versions.
* Removed the clashing operator in JobSetupDlg. Automatic whitespace
  cleanup.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@42387 a95241bf-73f2-0310-859d-f6bbb57e9c96
2011-07-07 10:17:15 +00:00
Alexander von Gluck IV b6c5f46896 * Add D2 GRPH update lock register to priv headers
* Add crtControl global register
* Add grphUpdate storage
* Do some logical reordering of register writes
* Correct crt final power-on checks
* Enhance tracing
* Disable PLL, it is needed but seems to completely break
  the modesetting resulting in black-screen-of-doom.
  (fixing PLL set/calibration is now priority one)


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@42380 a95241bf-73f2-0310-859d-f6bbb57e9c96
2011-07-04 22:24:17 +00:00
Michael Lotz 4cde5cc228 * Fix binding to link level sockets. The bound type was constructed using the
sdl_e_type in network byte order, causing such a socket not to receive
  anything.
  When working around that by not using htons() on bind, sending would then fail
  on such a socket because the byte order is actually required to be swapped
  there.
* Extend the comment for the B_NET_FRAME_TYPE macro to document that the input
  types are supposed to be in host byte order to avoid future confusion.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@42357 a95241bf-73f2-0310-859d-f6bbb57e9c96
2011-07-01 20:26:37 +00:00
Rene Gollent 124cdd4f57 Applied patch by Gerald Zajac: Adds hardware overlay support to the ATI
mach64/Rage driver. Resolves #5314. Thanks!



git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@42335 a95241bf-73f2-0310-859d-f6bbb57e9c96
2011-06-28 19:13:49 +00:00
Axel Dörfler cefef1c371 * Header cleanup.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@42304 a95241bf-73f2-0310-859d-f6bbb57e9c96
2011-06-24 18:22:02 +00:00
Axel Dörfler 8c5a0accf5 * Do not reserve memory when the area is too large. This fixes #7740 where the
reserved amount was simply too small, but also works around address space
  waste with many larger bitmaps.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@42298 a95241bf-73f2-0310-859d-f6bbb57e9c96
2011-06-24 17:04:50 +00:00
Michael Lotz 97184c6965 Tiny comment cleanup.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@42275 a95241bf-73f2-0310-859d-f6bbb57e9c96
2011-06-21 12:35:50 +00:00
Clemens Zeidler c26c18e489 Apply a nice patch from Taos, thanks!
Localize the mail server and preferences. Get rid of MDRLanguage.h.
The Japanese translation is attached to #7689. Please give a notice when it is in the translation system and the ticket can be closed.



git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@42268 a95241bf-73f2-0310-859d-f6bbb57e9c96
2011-06-20 21:15:27 +00:00
Jérôme Duval aa56e459e0 revert r42251. Cast the enum to uint32 before use in switchs to please GCC 4.5.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@42266 a95241bf-73f2-0310-859d-f6bbb57e9c96
2011-06-20 21:12:10 +00:00
Jérôme Duval 11977ba83b added more cpu feature flags for x86
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@42263 a95241bf-73f2-0310-859d-f6bbb57e9c96
2011-06-20 17:00:50 +00:00
Axel Dörfler 21c22141b8 * Removed default_sent_directory(), and introduced
default_mail{_in|_out}_directory() methods in the BPrivate namespace.
* Used these methods in the inbound/outbound protocols.
* Moved WriteMessageFile() into the BPrivate namespace as well, and put its
  prototype into a new header MailPrivate.h along with the new directory
  getters.
* Removed the automatic copy to the sent directory again, and only have one
  directory for incoming mail. Incidentally, this fixed #7509, although the
  underlying filter restriction remains.
* Automatic whitespace cleanups, some style cleanups. Sorry for the mess.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@42260 a95241bf-73f2-0310-859d-f6bbb57e9c96
2011-06-19 22:11:04 +00:00
Axel Dörfler ab383924fc * Style cleanup.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@42258 a95241bf-73f2-0310-859d-f6bbb57e9c96
2011-06-19 22:03:49 +00:00
Jérôme Duval ad1263fce3 Part of patch from #6840:
* GCC 4.5 complains about switchs with cases not part of the directory_which enum
* Merge FSUtils directory_which values into the enum


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@42251 a95241bf-73f2-0310-859d-f6bbb57e9c96
2011-06-19 18:15:25 +00:00
Clemens Zeidler 6e1a22610f Add a comment about who is responsible to clean up.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@42226 a95241bf-73f2-0310-859d-f6bbb57e9c96
2011-06-18 01:29:27 +00:00
Alex Wilson 8ef1944247 Add new constructors to BLayoutBuilder::Grid and BLayoutBuilder::Group that accept a plain old BView, and give it a new layout. These are very similar to the constructors that are already in place taking a BWindow. This solves a problem I have come across a few times, where one wants to build a layout in something like a BBox. Althought there is currently a way to do it with the layout builders, this is prettier.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@42224 a95241bf-73f2-0310-859d-f6bbb57e9c96
2011-06-18 01:12:29 +00:00
Alex Wilson d90a465e08 Change the value of other spacing/inset constants so that B_USE_DEFAULT_SPACING has its own unique value. Also adjust BControlLook::ComposeSpacing() to reflect this.
closes #7447


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@42222 a95241bf-73f2-0310-859d-f6bbb57e9c96
2011-06-18 00:37:39 +00:00
Alexander von Gluck IV f7f3828178 pass device pciid through to accelerant
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@42203 a95241bf-73f2-0310-859d-f6bbb57e9c96
2011-06-16 03:10:17 +00:00
Alexander von Gluck IV 58ddd30b23 add universal RadeonHD power states
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@42189 a95241bf-73f2-0310-859d-f6bbb57e9c96
2011-06-15 15:44:14 +00:00
Ingo Weinhold 40f4cf2aca Attempt to fix the FreeBSD build. We don't really what KernelExport.h defines,
so include OS.h instead.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@42185 a95241bf-73f2-0310-859d-f6bbb57e9c96
2011-06-14 13:44:07 +00:00
Ingo Weinhold 9437559db1 * Added function team_init_exit_info_on_error() which initializes the team's
exit info with some generic status.
* team_create_thread_start(), common_thread_entry(): Initializes the team's
  exit info (if that's the main thread) before calling thread_exit(). Fixes
  #7686.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@42183 a95241bf-73f2-0310-859d-f6bbb57e9c96
2011-06-14 13:04:31 +00:00
Ingo Weinhold dc3ba981d4 Added try_acquire_spinlock().
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@42180 a95241bf-73f2-0310-859d-f6bbb57e9c96
2011-06-14 12:41:11 +00:00
Ingo Weinhold 4cc4f7bb18 * Added KMessage to libroot_build.
* libbe_build: Where possible we directly use the actual Haiku headers and
  sources, now. In the headers/build headers we just include the respective
  Haiku headers as needed. That still allows overrides where necessary. The
  intention is to make it easier to keep the build stuff in sync.
* Fixed a few printf() format and signed/unsigned comparison warnings.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@42179 a95241bf-73f2-0310-859d-f6bbb57e9c96
2011-06-14 11:42:49 +00:00
Ingo Weinhold 54cf3a72ba Changed sReplyPortInUse type from long to int32, so it be used with
atomic_add() also on 64 bit architectures.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@42174 a95241bf-73f2-0310-859d-f6bbb57e9c96
2011-06-14 11:25:37 +00:00
Ingo Weinhold eff23a8157 Added missing header <Size.h>.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@42166 a95241bf-73f2-0310-859d-f6bbb57e9c96
2011-06-14 01:25:51 +00:00
Ingo Weinhold a928c3f001 operation <<(): Use the standard types [unsigned] long [long] instead of
[u]int32 and [u]int64 to avoid clashes with the int/unsigned int versions.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@42165 a95241bf-73f2-0310-859d-f6bbb57e9c96
2011-06-14 01:07:16 +00:00
Michael Lotz 16c5a72847 * Seperate out the tty_close_cookie from tty_destory_cookie and make the former
available as a module function as well.
* Remove some unneeded resetting from tty_destroy_cookie.
* Move the public module functions to the public API section of the file and
  order them by their declaration order in the module info.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@42154 a95241bf-73f2-0310-859d-f6bbb57e9c96
2011-06-13 20:44:22 +00:00
Michael Lotz f1ec739ed7 Style and text cleanups and some added clarifications. No functional changes.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@42148 a95241bf-73f2-0310-859d-f6bbb57e9c96
2011-06-13 13:06:45 +00:00
Ingo Weinhold 90ade5e298 * Added file_system_module_info::uninitialize() analogously to
partition_module_info::uninitialize().
* Implemented the hook for BFS.
* Implemented KFileSystem::Uninitialize().

Fixes failure to initialize a BFS initialized device with an intel partition
map.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@42142 a95241bf-73f2-0310-859d-f6bbb57e9c96
2011-06-13 01:53:11 +00:00
Ingo Weinhold 0b7fe5cbe2 partition_module_info::uninitialize(): Added block size parameter for
convenience.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@42141 a95241bf-73f2-0310-859d-f6bbb57e9c96
2011-06-13 01:38:03 +00:00
Ingo Weinhold 285f4cf441 * Added optional partition_module_info::uninitialize() hook. It is supposed to
destroy the partitioning system's on-disk structure.
* Adjusted the existing partitioning system implementations accordingly.
  Actually implemented the hook for the intel partitioning system.
* Added Uninitialize() method to KDiskSystem and KPartitioningSystem. The latter
  implements the method calling the new module hook.
* _user_uninitialize_partition(): Also let the disk system uninitialize the
  on-disk structure.

This fixes the failure to initialize a disk device with BFS, when it contains a
valid partition map with at least one partition.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@42140 a95241bf-73f2-0310-859d-f6bbb57e9c96
2011-06-13 01:27:13 +00:00
Ingo Weinhold 5e78920c12 * Added platform_debug_get_log_buffer() which returns the debug log buffer and
its size.
* Added "Display current boot loader log" item to the "Debug Options" boot
  loader menu. It displays what the boot loader has logged so far. Might be
  interesting for early boot issues when serial debugging is not possible.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@42134 a95241bf-73f2-0310-859d-f6bbb57e9c96
2011-06-12 23:31:57 +00:00
Rene Gollent 73df2f2086 * Add validation of the RSDP checksums.
* If we detect ACPI 2.0 or higher, the spec says we should use the XSDT rather
  than the RSDT. Attempt to do so, falling back to the RSDT if the former fails
  to be mapped/validated.
* Refactored acpi_find_table into a templated version to account for the fact
  that the XSDT exports different pointer widths for its links to other tables
  than the RSDT.



git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@42133 a95241bf-73f2-0310-859d-f6bbb57e9c96
2011-06-12 22:01:43 +00:00
Rene Gollent e8d73efc9c Should have been part of previous commit.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@42130 a95241bf-73f2-0310-859d-f6bbb57e9c96
2011-06-12 20:18:01 +00:00
Rene Gollent 36dc99a323 Add private get_memory_properties() syscall which allows one to retrieve the
address protection bits as well as the wiring flags for an arbitrary address
in a team's address space. Will be used in the debugger for the purposes
of the memory inspector/editor, in order to determine whether it can in fact
allow editing for the currently inspected address range.



git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@42129 a95241bf-73f2-0310-859d-f6bbb57e9c96
2011-06-12 20:17:14 +00:00
Ingo Weinhold 8bcc50c336 * Added arch_debug_blue_screen_try_getchar() and arch_debug_serial_try_getchar()
which don't wait for a character, but return -1 when no character is
  available ATM. Implemented correctly for x86 only.
* Changed the semantics of the debugger_module_info::debugger_getchar() hook.
  It is supposed to return immediately now.
* Adjusted usb_keyboard accordingly. Hacked UHCI's debug_process_transfer() to
  achieve that. It does now start, check, or cancel a transfer. Split
  UHCI::ProcessDebugTransfer() into StartDebugTransfer(), and
  CheckDebugTransfer() accordingly, and also added a CancelDebugTransfer().
  The latter seems to have issues. Michael, please have a look. I have no clue
  what I'm doing. :-)
* Adjusted kgetc() to poll all possible inputs using the new
  functions/semantics. This allows to use any input (USB, PS/2, serial) in KDL.
* Removed the no longer needed "serial_input" command.
* read_line(): Also support 0x7f as backspace code. That's what xterm sends.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@42126 a95241bf-73f2-0310-859d-f6bbb57e9c96
2011-06-12 17:15:42 +00:00
Rene Gollent 6b0007fb77 Rename rsdt_length to xsdt_length to avoid future confusion.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@42119 a95241bf-73f2-0310-859d-f6bbb57e9c96
2011-06-12 02:12:07 +00:00
Ingo Weinhold 24df65921b Merged signals-merge branch into trunk with the following changes:
* Reorganized the kernel locking related to threads and teams.
* We now discriminate correctly between process and thread signals. Signal
  handlers have been moved to teams. Fixes #5679.
* Implemented real-time signal support, including signal queuing, SA_SIGINFO
  support, sigqueue(), sigwaitinfo(), sigtimedwait(), waitid(), and the addition
  of the real-time signal range. Closes #1935 and #2695.
* Gave SIGBUS a separate signal number. Fixes #6704.
* Implemented <time.h> clock and timer support, and fixed/completed alarm() and
  [set]itimer(). Closes #5682.
* Implemented support for thread cancellation. Closes #5686.
* Moved send_signal() from <signal.h> to <OS.h>. Fixes #7554.
* Lots over smaller more or less related changes.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@42116 a95241bf-73f2-0310-859d-f6bbb57e9c96
2011-06-12 00:00:23 +00:00
bonefish ea71d6eb4f Made Remove() safe to be called with an element not in the list and changed its
return type to bool to indicate whether it was.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@42096 a95241bf-73f2-0310-859d-f6bbb57e9c96
2011-06-11 13:02:41 +00:00
Rene Gollent 8c3c117201 Adjust ReleaseReference() to also return the previous ref count as
AcquireReference() now does, and adjust all callers that relied on the previous
return type.



git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@42091 a95241bf-73f2-0310-859d-f6bbb57e9c96
2011-06-10 22:31:33 +00:00
Rene Gollent a99d0dd7b7 AcquireReference() now returns the previous ref count.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@42079 a95241bf-73f2-0310-859d-f6bbb57e9c96
2011-06-10 01:55:12 +00:00
Alex Wilson 813147df83 * Add new SetInsets() methods to BTwoDimensionalLayout, BSplitView
* Also add equivalent methods to the layout builders in LayoutBuilder.h
* BSplitView now calls BControlLook::ComposeSpacing(), instead of BSplitLayout
* part of #7447


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@42077 a95241bf-73f2-0310-859d-f6bbb57e9c96
2011-06-09 20:58:52 +00:00
Alex Wilson 6648dd3cf1 * Add new spacing/inset constants for the layout API. For now, leave B_USE_DEFAULT_SPACING, but this will go soon.
* Rename BControlLook::ComposeItemSpacing() to ComposeSpacing(), and extend it to handle the new constants.
* Adjust users of BControlLook::ComposeItemSpacing() accordingly.
* part of #7447


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@42025 a95241bf-73f2-0310-859d-f6bbb57e9c96
2011-06-07 20:40:56 +00:00
Stephan Aßmus e750d35cbf Applied patch by Pete Goodeve from ticket #7182. It improves
keyboard navigation/tracking of BMenus and BMenuBars, although
many issues remain.
Should not yet go into alpha, since there is one issue which
I am not sure if it's not a regression. The issue is that
invoking a menu item with Enter for the first time seems to
have no effect, while invoking it subsequently works as
expected. I don't know, yet, if that's a regression of this patch.
In any case, it's better than before, thanks, Pete!


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@42004 a95241bf-73f2-0310-859d-f6bbb57e9c96
2011-06-07 12:46:00 +00:00
Ryan Leavengood 2530274ddc Missed this in my previous Time commit, hence the build break, sorry!
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@41933 a95241bf-73f2-0310-859d-f6bbb57e9c96
2011-06-05 06:09:55 +00:00
Michael Lotz a4aa4541c1 * Make it a valid C header again.
* Cleanup of include grouping as pointed out by Axel.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@41899 a95241bf-73f2-0310-859d-f6bbb57e9c96
2011-06-03 23:31:05 +00:00
Alexandre Deckner 596bb6891a * Finally rewrote the filthy, busy-looping, mouse tracking in Tracker.
The new asynchronous tracking doesn't lock the view and makes desktop 
replicants happy while clicking and dragging around. Fixes #880, #7241 
and certainly other tickets, that i will revisit, about refresh locks 
on the desktop or mouse related bugs. Based on a reusable MessageFilter and the 
recent B_MOUSE_IDLE message. Some parts are ported from the old code
and could use further simplification.

There should be no intentional user fonctional change, except: 
- slightly bigger threshold radius, shorter duration thresholds
 (= 1.0 x the system-wide doubleclick setting)
- not reimplemented: quickening threshold when holding shift while dragging
 a pose over a destination pose.

Some parts are ported from the old code and could use further simplification.
There is one known minor regression with autoscrolling while 
rect-selecting but that will be better fixed with some changes to the 
autoscroll code. Will address that ASAP. As for the unknown regressions, 
please test :)


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@41892 a95241bf-73f2-0310-859d-f6bbb57e9c96
2011-06-03 21:12:14 +00:00
Michael Lotz 34f0d87a9d Add initialize[_to_extended_joystick]() methods to variable_joystick. With those
methods the members are populated, the flat data size is calcualted, the data
buffer is allocated and the convenience pointers are set up automatically. With
initialize() an arbitrary configuration can be created, with
initialize_to_extended_joystick() a configuration is created that exactly
matches the data structure of the extended_joystick struct.
Having them here makes it easy to use the structure from a driver as well
without the need to set up everything manually.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@41888 a95241bf-73f2-0310-859d-f6bbb57e9c96
2011-06-03 20:54:05 +00:00
Michael Lotz 6e0cca2f96 * Remove the JoystickPrivate.h again and move the variable_joystick structure
into joystick_driver.h as it is convenient to have also on the driver side.
* Added comments explaining the data structure and use case of the structure.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@41886 a95241bf-73f2-0310-859d-f6bbb57e9c96
2011-06-03 19:48:16 +00:00
Michael Lotz ab1763688f * Replace the fixed size extended_joystick structure with a variably sized one
inside BJoystick.
* Add joystick_module_info flag to communicate support for variably sized reads.
* The variably sized data structure is set up to describe either the actual
  amount of data, when variably sized reads are supported by the driver, or it
  is set up so that it exactly matches the data layout of the extended_joystick
  structure. This allows us to support both as input data, while only needing to
  care about a single format inside BJoystick. Convenience pointers allow the
  data to be retrieved without additional overhead or extra logic.
* Add some sanity checks and ensure some boundaries when dealing reading data
  from the variably sized structure (as there might not be any buttons, hats,
  axis at all now).
* Ensure that the extended_joystick structure doesn't change in size due to
  padding by making it _PACKED (it wasn't padded though).

This is still supposed to work exactly as before. However, it opens up the
possibility to actually support arbitrary controllers with arbitrary axis, hat
and button counts. It therefore allows to actually deliver what the BJoystick
API was designed to handle all along.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@41885 a95241bf-73f2-0310-859d-f6bbb57e9c96
2011-06-03 18:33:43 +00:00
Michael Lotz 4b5bcc6684 Introduce a BJoystick::GetButtonValues() function that aligns with the other
Get*Values() functions but retrieves an arbitrary amount of button states using
a boolean array. This overcomes the 32 button limitation on the API side. Right
now the function does simply set the first 32 states from the button bitmap, as
the BJoystick to driver interface hasn't been adapted yet.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@41882 a95241bf-73f2-0310-859d-f6bbb57e9c96
2011-06-03 15:40:31 +00:00
Ingo Weinhold 9536ec0297 Reimplemented the gdb stub support for the 'g' command (read registers):
* Added an arch_debug_gdb_get_registers() interface that is supposed to provide
  the register values in the format expected by gdb and implemented it for x86.
* Reimplemented gdb_regreply() to use that. Also made it buffer overflow safe.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@41880 a95241bf-73f2-0310-859d-f6bbb57e9c96
2011-06-03 15:35:10 +00:00
Michael Lotz bb2420a474 Remove two unimplemented private functions. Since their signature was changed
already anyway (as compared to the original BeOS ones) this won't introduce any
missing symbols.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@41879 a95241bf-73f2-0310-859d-f6bbb57e9c96
2011-06-03 13:26:22 +00:00
Michael Lotz 1147fabd67 Move function definitions to match their declaration order. Also move some
declarations to group them more logically. No functional changes.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@41878 a95241bf-73f2-0310-859d-f6bbb57e9c96
2011-06-03 12:45:35 +00:00
Michael Lotz 464e0351d3 * Add a BJoystick::RescanDevices() public function. It allows the BJoystick
to be updated with newly plugged in devices without the need to recreate a
  BJoystick object.
* Do an initial (re-)scan on object creation instead of always scanning in
  CountDevices() and by extension GetDeviceName().
* This makes CountDevices() and GetDeviceName() stable with regards to the
  device list, so that an enumerating application doesn't suddenly get more/less
  devices than it might expect.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@41870 a95241bf-73f2-0310-859d-f6bbb57e9c96
2011-06-02 15:10:31 +00:00
Michael Lotz 393ca9a124 Cleanup of the _BJoystickTweaker:
* Include sorting, header style, macro naming, variable naming, spacing, ...
* Some simplifications, early returns and the like.
* The device name list items were allocated with new but deleted with free. The
  whole private BJoystick list being modified by a friend class is dubious
  though and should be reworked. Ideally node monitoring would be implemented
  so that the list can be re-populated on demand instead of scanning through
  every time.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@41868 a95241bf-73f2-0310-859d-f6bbb57e9c96
2011-06-02 12:42:18 +00:00
Michael Lotz ef13dbda92 * Actually implement the relevant parts of BJoystick, i.e. reading the joystick
info and values. Inspired by and in parts based on the patch by caz_haiku in
  ticket #7429 (though rewritten completely due to the other changes). Thanks
  for the pointers!
* Clean up the mixup of internal joystick info and the one from
  joystick_driver.h so that BJoystick and the drivers talk about the same
  structures.
* Extensive coding style cleanup, simplifications, NULL checks, early returns,
  std::nothrow allocations, include sorting, argument naming, ... that kind of
  stuff.
* Added some TODO notes for remaining stuff.
* Automatic (and manual) whitespace cleanup.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@41849 a95241bf-73f2-0310-859d-f6bbb57e9c96
2011-05-31 02:05:39 +00:00
Clemens Zeidler a4710c0d46 Move ServerConnection class from the IMAP add-on to libmail.so. This avoids to init SSL each time an IMAP add-on
is loaded. SMTP and POP still have this problem! TODO: use the ServerConnection class in these add-ons too.
This would also remove a lot of #ifdef SSL form these add-ons. Will not do it in the near future, feel free to fix it
...



git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@41840 a95241bf-73f2-0310-859d-f6bbb57e9c96
2011-05-30 21:36:06 +00:00
Jérôme Duval 6ec9dff3f3 ppc build fix
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@41834 a95241bf-73f2-0310-859d-f6bbb57e9c96
2011-05-30 19:51:45 +00:00
Oliver Tappe d9a26469df Fix #6969 (hopefully for real this time):
* move all the isw... functions from wchar.h to wctype.h (just following version 7
  of the POSIX base specs)
* remove all declarations from wchar.h that are in wctype.h, too


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@41832 a95241bf-73f2-0310-859d-f6bbb57e9c96
2011-05-30 18:44:22 +00:00
Axel Dörfler 48ae3e3808 * Followed Ingo's suggestion, and added a BWindow::Layout() method.
* Changed ShowImage to use that function.
+alpha in case Ingo gives his okay :-)


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@41782 a95241bf-73f2-0310-859d-f6bbb57e9c96
2011-05-27 22:21:59 +00:00
Alexander von Gluck IV 217c0b1d48 Add surface address high handling; set primary and secondary surface frame buffer offset
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@41769 a95241bf-73f2-0310-859d-f6bbb57e9c96
2011-05-27 02:14:54 +00:00
Alexander von Gluck IV fffb954b89 add D2 secondary surface address, not sure why it was missing in radeonhd driver
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@41761 a95241bf-73f2-0310-859d-f6bbb57e9c96
2011-05-26 18:10:43 +00:00
Axel Dörfler 702526b17f * Added BLanguage::GetIcon(), and BLocaleRoster::GetFlagIconForLanguage(). The
former just calls the latter. Getting the flag for a language is pretty
  simplistic for now, but it won't return the wrong flag, just only a few known
  ones (should be enough for ReadOnlyBootPrompt, at least).
* Ordered methods in declaration order.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@41744 a95241bf-73f2-0310-859d-f6bbb57e9c96
2011-05-25 17:09:30 +00:00
Alexander von Gluck IV 3be5e03652 * rename graphics_memory to frame_buffer. lets keep consistant
* pass mapped frame buffer area id to accelerant
* remove my temporary hacked together frame buffer memory mapping
* completely rely on PCI BAR for now for aperture size / location instead of
  R6XX_CONFIG_FB_BASE reg.
* Remove my temporary AllocateFB function.
* set grphPrimarySurfaceAddr to physical memory frame buffer location (offset 0)
* fix P/N sync setting.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@41722 a95241bf-73f2-0310-859d-f6bbb57e9c96
2011-05-24 22:08:54 +00:00
Rene Gollent 8837310ce7 * Slightly alter the semantics of the input gathering function to take the
menu item it's associated with rather than an input string. This allows it
  to calculate the position to start the input at, as well as the correct
  line to place it on. The previous solution always put the input at the
  center line, which happened to be the right place by happy coincidence
  unless one also had the menu items for viewing/saving the debug syslog
  present.
* Implement input buffer scrolling, and consequently lift the previous size
  limit on user input (it is now only limited by the size of the passed in
  buffer).
* Implement parsing of the input buffer to allow it to handle comma-separated
  options. Thus, one can now input things like "disable_smp true, serial_debug_output false"
  and it will be handled properly.



git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@41706 a95241bf-73f2-0310-859d-f6bbb57e9c96
2011-05-24 03:21:51 +00:00
Axel Dörfler c329950ca7 * Put the decor stuff in the BPrivate namespace, as it should have been from
the beginning.
* Added header for the get_decorator() functions and friends.
* Minor coding style cleanup.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@41638 a95241bf-73f2-0310-859d-f6bbb57e9c96
2011-05-21 18:12:25 +00:00
Jérôme Duval db61366a55 Patch from Dhruwat Bhagat (bug #7537): Fix "'noreturn' function returns" warning on call to assert(0).
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@41628 a95241bf-73f2-0310-859d-f6bbb57e9c96
2011-05-21 13:15:46 +00:00
Axel Dörfler a1e3c32da9 * BIconButton now inherits from BControl, solving a TODO comment.
* I tried to reuse as much state from BControl as possible, so I removed a few
  states.
* Also made the flags private, and added protected SetInside()/IsInside()
  methods.
* Removed useless BIconButton::ID().
* Adjusted users.
* Minor cleanup, automatic white space cleanup.
-alpha


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@41611 a95241bf-73f2-0310-859d-f6bbb57e9c96
2011-05-20 21:10:15 +00:00
Alexander von Gluck IV 51a43d0ff4 ensure framebuffer doesn't exceed PCI bar; add basic monitoring of frame buffer memory allocation; fix return of framebuffer to OS to be the correct area
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@41586 a95241bf-73f2-0310-859d-f6bbb57e9c96
2011-05-19 17:39:07 +00:00
Stephan Aßmus b46615c55a Applied patch by Joseph "looncraz" Groover from ticket #7445.
This changes how Decorators are managed and applied. The app_server
no longer scans and maintains the available ones himself, but is
simply asked to load a Decorator add-on from a provided path.
The Decorator scanning is moved into DecorInfo and DecorInfoUtil,
private classes in the InterfaceKit. The bin command 'setdecor'
uses those.
I cleaned up all the coding style violations that I could find,
removed chunks of code which didn't make sense (if you never put
a NULL pointer into a list, you don't need to check for this and
so on) and also cleaned up other passages for improved clarity
and simplicity.
I also tested the functionality and it works fine. Would even be
Ok to include in Alpha 3, IMHO. Thanks for the patch!


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@41581 a95241bf-73f2-0310-859d-f6bbb57e9c96
2011-05-19 15:25:54 +00:00
Rene Gollent d2b49a0031 * Implement support for user input of additional safe mode options that
aren't otherwise exposed via the safe mode menus. The option can be 
found under the debug options menu, where additional settings can be 
added one at a time with the same syntax used in kernel settings files 
(i.e. disable_acpi on). 

Scrolling of the input buffer is not yet supported (will implement that 
soon), so currently the input is clamped to the size of one line. This 
shouldn't be a problem for our current set of options though.



git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@41577 a95241bf-73f2-0310-859d-f6bbb57e9c96
2011-05-19 01:38:02 +00:00
Alexander von Gluck IV 882e2ef79b remove frame_buffer_pci as it duplicates frame_buffer_phys, remove frame_buffer_base as it duplicates framebuffer_area
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@41570 a95241bf-73f2-0310-859d-f6bbb57e9c96
2011-05-18 18:43:28 +00:00
Alexander von Gluck IV 90af954387 * actually set device_chipset before reading it.
* make shared memory info naming clearer.
* move frame buffer internal offset read to driver
* remove check of > 512MB as we really should always use frame_buffer_size


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@41569 a95241bf-73f2-0310-859d-f6bbb57e9c96
2011-05-18 18:38:28 +00:00
Alexander von Gluck IV 56e6d991bb make math easier to read; fix chipset int length; additions to CardScale
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@41561 a95241bf-73f2-0310-859d-f6bbb57e9c96
2011-05-18 04:25:05 +00:00
Rene Gollent a6e171a7e2 Update trunk version to post-Alpha3 since the latter has now been branched.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@41549 a95241bf-73f2-0310-859d-f6bbb57e9c96
2011-05-16 21:53:38 +00:00
Alexander von Gluck IV 6c43ea6336 read and store aperture size (will be used in fblocation calculations)
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@41543 a95241bf-73f2-0310-859d-f6bbb57e9c96
2011-05-16 18:10:49 +00:00
Michael Lotz fb5a1727f4 * Implement interrupt source overrides. We install a relay interrupt handler
at the override entry to trigger the overriden vector so that we don't need
  to configure any additional redirections.
* Also configures the polarity and trigger modes found in the override entry.
* When disabling the legacy PIC, retrieve the enabled interrupts and re-enable
  then in the IO-APIC. This will for example make the ACPI SCI work that is
  installed prior to switching interrupt models. Through the transparent support
  for interrupt source overrides it'll also automatically relay from the old to
  the new vector.

This should make ACPI interrupts work and should support relocating the ISA PIT
from irq 0 to a different global system interrupt (usually 2) so that it can
still work when IO-APICs are in use.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@41528 a95241bf-73f2-0310-859d-f6bbb57e9c96
2011-05-16 12:57:40 +00:00
Michael Lotz 9c1714ec1a Enable IO-APICs by default. It's been tested on a broad spectrum of hardware and
all reports so far have been positive. We fall back to legacy mode in the cases
where we can't figure out the correct routing.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@41527 a95241bf-73f2-0310-859d-f6bbb57e9c96
2011-05-16 08:42:30 +00:00
Alexander von Gluck IV 2be925fd04 * turns out r800 has different register locations :(
* remove device_type and replace with device_chipset
* change MEMSIZE to >> 10 as r600-r700 store this in bytes (r800 uses MB and will be fixed soon)
* add if statement to select what register locations to use based on chipset
** Maybe use a struct or something to store these in a standardized way?


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@41525 a95241bf-73f2-0310-859d-f6bbb57e9c96
2011-05-16 04:03:18 +00:00
Alexander von Gluck IV 344802cb7d stir in evergreen/r800 mixins from Xorg radeonhd driver, may need to add to this as I just grep'ed evergreen; r800/evergreen has a different set of registers for some things, thus my work so far not working for me :(
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@41523 a95241bf-73f2-0310-859d-f6bbb57e9c96
2011-05-16 02:53:15 +00:00
Oliver Tappe 6a5ce30120 Move functions declared in private/system/system_info.h out of the public namespace.
* prepend private functions get_system_info_etc(), start_watching_system() and 
  stop_watching_system() with '__'
* adjust callers accordingly


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@41517 a95241bf-73f2-0310-859d-f6bbb57e9c96
2011-05-15 17:02:36 +00:00
Oliver Tappe 22a7fe9695 Cleanup system-revision stuff.
* move system_revision.h to headers/private/libroot
* unify libroot's get_system_revision() (the one I introduced recently) with kernel's
  get_haiku_revision(), the function is now called get_haiku_revision() in the kernel
  and __get_haiku_revision() in libroot
* system_revision.c is now being built as part of libroot and as part of the kernel
* adjusted all callers of get_system_revision() accordingly


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@41516 a95241bf-73f2-0310-859d-f6bbb57e9c96
2011-05-15 16:33:30 +00:00
Matt Madia 502fc780bf Updated the header files for the boot splash, to display the registered
trademark symbol.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@41499 a95241bf-73f2-0310-859d-f6bbb57e9c96
2011-05-14 18:59:26 +00:00
Oliver Tappe a961bbc69d * move sHaikuRevision from uname.c into new system_revision.c
* add private function get_system_revision() for accessing the
  revision string
* adjust uname to use get_system_revision

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@41479 a95241bf-73f2-0310-859d-f6bbb57e9c96
2011-05-13 20:38:14 +00:00
Michael Lotz 8908aef9c2 * Don't map the IO-APIC within the bootloader. We don't need it to set up SMP
at all and, since there can be multiple IO-APICs, we need to do the
  enumeration again in the kernel anyway. Also only set ioapic_phys the first
  time we encounter an IO-APIC object as it looks cleaner when we arrive at the
  first IO-APIC default address.
* Therefore we don't have to worry about already mapped IO-APICs when
  enumerating them in the kernel.
* Also remove the mapping function that is now not used anymore.
* We still use the ioapic_phys field of the kernel args to determine whether
  there is an IO-APIC at all to avoid needlessly doing the enumeration again.

This fixes multi IO-APIC configurations, because before we would indeed map
the last IO-APIC listed in the MADT, but then in the kernel assumed we mapped
the first one. We'd end up with mapping the last listed IO-APIC twice and the
first IO-APIC never, always programming the last one when we actually targetted
the first one.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@41476 a95241bf-73f2-0310-859d-f6bbb57e9c96
2011-05-13 16:31:31 +00:00
Michael Lotz a56cbb2afb * When initializing MSI support, don't assume a single 24 entry IO-APIC. Instead
mark the ISA interrupts as unusable and then use ioapic_is_interrupt_available
  to determine if that vector is possibly taken by an IO-APIC. If IO-APICs are
  not used, this will simply always return false, leaving all vectors free for
  MSI use.
* The msi_init() now has to be done after a potential IO-APIC init, so it is now
  done after ioapic_init() instead of inside apic_init().
* Add apic_disable_local_ints() to clear the local ints on the local APIC once
  we are in APIC mode (i.e. the IO-APIC is set up and we don't need the external
  routing anymore).


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@41445 a95241bf-73f2-0310-859d-f6bbb57e9c96
2011-05-11 18:05:05 +00:00
Michael Lotz 407af313ca Make the signature argument to get_table() const. Should fix the GCC4 build.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@41433 a95241bf-73f2-0310-859d-f6bbb57e9c96
2011-05-11 09:05:43 +00:00
Michael Lotz 2645ca0a28 Provide a function to gain ACPI table access.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@41429 a95241bf-73f2-0310-859d-f6bbb57e9c96
2011-05-11 08:22:22 +00:00
Michael Lotz 20537052a2 Quick build fix for the FreeBSD compatibility layer. Maybe the definition should
be moved to a (even) more private header?


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@41427 a95241bf-73f2-0310-859d-f6bbb57e9c96
2011-05-11 01:30:55 +00:00
Michael Lotz dc14d97b7f * Move the legacy PIC and the IO-APIC code into their own source file. No
functional change intended.
* Use an appropriately sized sLevelTriggeredInterrupts for each controller type.
  This also fixes an out of bound access for IO-APICs with more than 32 entries
  and also returns the right mode in such cases.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@41426 a95241bf-73f2-0310-859d-f6bbb57e9c96
2011-05-11 00:53:03 +00:00