Commit Graph

6488 Commits

Author SHA1 Message Date
Ingo Weinhold d61a8548f9 Add support for bind-mounting directories
* Add support function vfs_get_mount_point(), so a file system can get
  its own mount point (i.e. the node it covers). Re-added
  fs_mount::covers_vnode for that purpose -- the root node isn't know to
  the VFS before the mount() hook returns.
* Add function vfs_bind_mount_directory() which bind-mounts a directory
  to another. The Vnode::covers/covered_by mechanism is used, so this
  isn't true bind-mounting, but sufficient for what we need ATM and
  cheaper as well. The vnodes connected thus aren't tracked yet, which
  is needed for undoing the connection when unmounting.
* get_vnode_name(): Don't use dir_read() to read the directory. Since we
  have already resolved vnode to the covered vnode, we don't want the
  dirents to be "fixed" to refer to the covering nodes. Such a vnode
  simply wouldn't be found.
2011-07-17 16:54:21 +02:00
Ingo Weinhold 313e1e37f2 Add vfs_ prefix to resolve_vnode_to_covering_vnode() 2011-07-17 16:54:20 +02:00
Ingo Weinhold 2e21fc5436 Generalize use of Vnode::covered_by/covers
* Introduce Vnode flags for covered and covering. Can be used as a quick
  check when one doesn't already hold sVnodeLock.
* Rename resolve_mount_point_to_volume_root() to
  resolve_vnode_to_covering_vnode().
* Adjust all code that deals with transitions between mount points and
  volume root vnodes to generally support covered/covering vnodes.
2011-07-17 16:54:20 +02:00
Ingo Weinhold 533833f646 Add kernel args boot volume "packaged" flag
* Add BOOT_VOLUME_PACKAGED boot volume message field name constant.
* register_boot_file_system():
  - Now takes a BootVolume& parameter.
  - If the boot volume is packaged, add that info to the boot volume
    message.
2011-07-17 16:54:15 +02:00
Ingo Weinhold cbc85916fb Add boot loader packagefs support
* Add pread().
* Add Node::ReadLink() to read a symbolic link path.
* Add Directory::LookupDontTraverse() and make Lookup() non-abstract.
  Lookup() is implemented via LookupDontTraverse() and Node::ReadLink().
* Adjust all FS implementations accordingly.
* Add a packagefs implementation. Unlike other FS implementations it
  isn't a pseudo-module, but provides a function to explicitly mount a
  package file (packagefs_mount_file()).
* Finish BootVolume::SetTo() implementation, mounting the package file
  and replacing fSystemDirectory.

Now the boot loader can load the kernel and boot modules from a packaged
system. The kernel boots up to the point where the boot volume is
mounted.
2011-07-17 16:54:15 +02:00
Ingo Weinhold d11ea2b5ed Introduce BootVolume abstraction class
BootVolume is initialized from a root directory of a volume. It finds
the system directory, and -- not implemented yet -- mounts the system
package, if the system is packaged, replacing the system directory with
it. Adjusted several functionality (main(), the loader functions,
user_menu()) to use BootVolume instead of the root directory.
2011-07-17 16:54:13 +02:00
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