Commit Graph

23569 Commits

Author SHA1 Message Date
Michael Lotz
463235a9a8 Add the usb_disk driver to the image.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24780 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-04-03 18:54:10 +00:00
Jérôme Duval
652df41ee5 fix warning
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24779 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-04-03 18:25:27 +00:00
Jérôme Duval
b5c24e59f2 fix typo
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24778 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-04-03 18:14:52 +00:00
Michael Lotz
06da81f012 Implement node monitoring in the kernel disk device manager.
* Added {Create|Delete}Device() analogous to {Create|Delete}FileDevice
* Added a small DeviceWatcher class that reacts to entry creation/removal
* Implemented a way to start/stop node monitoring
* Start watching for devices after the boot volume has been mounted and the
  the second initial scan was run

The disk device manager now creates and scans a device when a "raw" node is
published and deletes the device on removal. This makes hot-plugging of disk
devices (for example memory sticks using usb_disk) work. Their partitions will
be scanned and published so they can be mounted. Somehow the removal of the
partitions does not yet work however, any insights are welcome.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24777 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-04-03 18:14:11 +00:00
Stephan Aßmus
bacaf1148c Don't display error when BRoster::Launch() returns B_ALREADY_RUNNING...
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24776 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-04-03 17:21:34 +00:00
François Revol
dbbf08a95a Just make sure someone copying it as UserBuildConfig will understand what is wrong and where instead of reporting build breakage induced by their misbehaviour.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24775 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-04-03 14:59:04 +00:00
Axel Dörfler
0f6b6c36dc Added syskonnect driver to the build to close ticket #1945 again that
diver reopened so fast.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24774 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-04-03 14:36:39 +00:00
Stephan Aßmus
64379118a9 * Revised boot splash artwork, the logo is back in the lower right corner,
the icons are centered.
* The boot loader and kernel now use the placement info that
  generate_boot_screen now generates.
* Made the code that draws the images handle the case where any of the images
  is larger than the frame buffer.
* All drawing functions need to know the image width (analogous for bytes per
  row).


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24773 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-04-03 14:24:10 +00:00
Axel Dörfler
e63c117011 Looks like some bloke forgot to commit *some* files that should have been part
of r24768 (block cache notification mechanism rewrite).
Thanks for the note, Vasilis!


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24772 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-04-03 14:14:27 +00:00
Axel Dörfler
4b7af69340 * I'm not sure if that puts more or less pressure on stippi, but the
PackageInstaller, ZipOMatic, and the Expander now all have the same
  icon (instead of none, resp. a BeOS bitmap icon).


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24771 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-04-03 12:39:06 +00:00
Axel Dörfler
70f87b87d9 Cleanup.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24770 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-04-03 12:19:44 +00:00
Axel Dörfler
9a87228642 * Removed the "transaction_changed" leftover member.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24769 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-04-03 11:22:14 +00:00
Axel Dörfler
816957bd74 * Decoupled notifications from the block cache functions; they are now
called without having the cache's lock held.
* The only downside to this approach is that ending a transaction now needs
  additional memory, and might therefore fail - that could be fixed by
  allocating that memory upfront with the start of the new transaction,
  though.
* Therefore, I reverted the cache lock to a benaphore, as the recursive
  lock is no longer needed.
* The block writer thread is now a block writer and notifier thread: it will
  wait for up to 2 seconds on the sEventSemaphore, and if nothing comes in,
  it will continue with its previously sole job.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24768 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-04-03 11:21:00 +00:00
Stephan Aßmus
f408d9a227 * Renamed placement constants to fit into the existing scheme.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24767 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-04-03 10:23:03 +00:00
Stephan Aßmus
a6e227c551 * Changed the generate_boot_screen build tool to take placement parameters
for the logo and the icons separately.
* Image data output uses full line width.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24766 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-04-03 10:19:00 +00:00
Stephan Aßmus
2af5f8952c Applied patch by Clemens Zeidler:
* The Media preflet itself is now font sensitive by using the new layout
  management.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24765 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-04-03 09:53:24 +00:00
Stephan Aßmus
13b895c5c6 Applied patch by Christof Lutteroth:
* The count/info view in Tracker truncates the text in a better way when
  it does not fit, and also used the space of the barber pool when it isn't
  displayed.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24764 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-04-03 09:04:07 +00:00
Stephan Aßmus
42014658ad Applied patch by James Woodcock:
* Implemented POSIX getpagesize() function in libroot.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24763 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-04-03 08:50:56 +00:00
Axel Dörfler
025b367502 * Renamed publish_node() to new_node().
* Introduced a new publish_node() which then actually publishs the node,
  similar to the VFS's new_vnode(), and publish_vnode() semantics.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24762 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-04-03 08:24:50 +00:00
Ingo Weinhold
a5140cad6a cache_end_transaction() doesn't remove the transaction, so that the
check in notify_transaction_listeners() didn't hold, although the
cache_hooks were deleted anyway. I've introduced a listener_change
counter to detect changes to the listener list while iterating, since
any change makes the iteration unsafe. Should fix bug #2008 for real.
Nevertheless I thing the transaction listener concept needs revision.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24761 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-04-03 02:24:46 +00:00
Michael Lotz
3130aa793d Change the NodeMonitorService lock from a mutex to a recursive_lock. This
allows event listeners to add new listeners inside a node monitoring event
(i.e. if one wants to add a listener for the entry that has just been created
and triggered the current notification).

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24760 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-04-02 23:20:37 +00:00
Michael Lotz
2509807a53 Change publish_node() of the devfs to not insert the node into the directory.
Instead return the directory vnode, so the calling function can insert it after
all vnode initialization is done. Otherwise entry created notifications are
sent upon inserting the node into the directory for vnodes that are not yet
fully initialized (i.e. they have no type or the device hooks are not yet set).
That would cause for example ioctls to fail when someone would react to a
notification of a newly created device.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24759 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-04-02 23:07:22 +00:00
Jérôme Duval
f6604eaad7 updated libpng to 1.2.26
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24758 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-04-02 20:58:54 +00:00
Ingo Weinhold
a0a9d225d3 Added a new fancy build system feature called "build profiles".
Especially people building various kinds of images with different
settings may want to have a look at the respective section in the
UserBuildConfig.ReadMe.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24757 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-04-02 20:29:43 +00:00
Karsten Heimrich
e1a5b29760 * gcc4 build fix
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24756 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-04-02 19:17:59 +00:00
Axel Dörfler
9da0e4408d * Added MIME type for packages for our PackageInstaller based on the
patch by Philippe Saint-Pierre that is part of ticket #2006.
* Added sniffer rule.
* For now, added package icon without any flags.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24753 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-04-02 16:09:48 +00:00
Axel Dörfler
12952eddd7 * Quick fix for a possible deadlock I introduced with the block_cache
idle notification. We should rework the cache notifications to work
  asynchronously.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24752 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-04-02 15:54:22 +00:00
Ingo Weinhold
0931d2f309 Use the thread-safe getpwuid_r() instead of getpwuid().
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24751 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-04-02 15:09:50 +00:00
Ingo Weinhold
f8cb30712e * Replaced the dummy implementations of the <grp.h> and <pwd.h>
functions by ones reading /etc/{group,passwd}.
* Added quasi-standard getpwent_r() and getgrent_r().
* Added _SC_GETGR_R_SIZE_MAX and _SC_GETPW_R_SIZE_MAX sysconf()
  constants.
* Moved initgroups() and getgrouplist() definition to grp.cpp. They use
  the same backend as the <grp.h> functions.
* Set the permissions of files created by the build system to what they
  should be on the image (executables: 755, others: 644). Otherwise only
  root could do anything under Haiku.
* Added build system variables HAIKU_ROOT_USER_NAME and
  HAIKU_ROOT_USER_REAL_NAME to customize name and real name of Haiku's
  root user.
* Added build system rules AddUserToHaikuImage and AddGroupToHaikuImage
  for adding additional users and groups (by default only root user and
  group and a "users" group are created).
* Adjusted BIND port and coreutils config.h files according to what
  features have become available.
* Fixed HAIKU_DOCUMENTATION_OBJECT_DIR definition. Untested, but it used
  a wrong variable name before.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24750 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-04-02 14:02:52 +00:00
Axel Dörfler
38c4c33487 * A notification can cause a transaction to be deleted - in this case, the
block_writer() as well as notify_transaction_listeners() must update their
  data or quit. This fixes newly introduced bug #2008.
* Minor cleanup.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24749 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-04-02 13:51:34 +00:00
Ingo Weinhold
f9ed63eb2d Copied the benaphore implementation from the kernel for use in libroot.
Would be nice to actually share those.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24748 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-04-02 13:39:43 +00:00
Axel Dörfler
33808d63f4 * AttachUser() now creates the user directory if it's not there yet. Added
a TODO comment that find_directory() won't return the correct directory in
  a multi-user environment. This fixes bug #2003.
* Some cleanup.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24747 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-04-02 13:04:08 +00:00
Axel Dörfler
4f5bc0cfe9 * Reenabled used page reporting based on vm_available_memory().
* Prettyfied memory info in the sysinfo app.
* Minor cleanup.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24746 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-04-02 12:47:08 +00:00
Axel Dörfler
6b53669383 * Renamed vm_get_available_memory() to vm_available_memory() to fit better
into our usual naming scheme.
* Minor cleanup.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24745 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-04-02 12:30:06 +00:00
Ingo Weinhold
f9bf1195b8 Use a reasonable umask when creating directories.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24744 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-04-02 12:29:59 +00:00
Axel Dörfler
129d25e0da * Removed old /bin/init startup code - it hasn't been needed for ages anymore.
* Some cleanup.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24743 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-04-02 12:27:25 +00:00
Axel Dörfler
62f892990b * Fixed several occasions of bugs with respect to the handling of
overcommitting stores:
  - has_precommitted was incorrectly set to true in the constructor
  - when a precommitted page was committed, vm_store::committed_size
    was still changed.
  - unreserving memory did not update vm_store::committed_size.
  - when precommitted pages were committed, their page count instead of their
    size was reserved.
* All this lead to bug #1970 which should be fixed now.
* Cleanup of vm_cache.cpp, no functional change.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24742 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-04-02 12:19:28 +00:00
Stephan Aßmus
ace2d5ee37 HWInterface::Cursor() and therefor Desktop::Cursor() accessed the
current cursor without locking, and did not add a reference while
using the cursor. I have tried to solve both problems by introducing
a simple ServerCursorReference class, which makes sure that the
reference count is properly maintained. There are only two places
where this code was even used, from within ServerApp and when taking
screenshots. Axel, you mentioned in #837 that the code is unsafe, is
this what you meant? This hopefully fixes #837, but it is very hard
to reproduce in the first place, I will close the ticket, but it should
just be reopened if ever encountered again.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24741 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-04-02 11:12:39 +00:00
Stephan Aßmus
42cf275606 The scale of a state does not influence the origin. Only previous states
and their origin and scale influences the current state's origin, since
they can be regarded as within the parent state's coordinate system.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24740 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-04-02 11:04:03 +00:00
Axel Dörfler
0aee496bd0 * block_cache_private.h is no longer needed, moved its contents into
block_cache.cpp.
* Fixed warning.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24739 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-04-02 10:44:08 +00:00
Axel Dörfler
3c78c04589 Resolved a TODO in Journal::Lock() that Urias reminded me about:
* BFS now uses a transaction listener that flushes the current transaction
  in case it is idle; before, transactions would always be kept open when
  they weren't large, so that the block writer could not write back the blocks
  (they were busy from its POV).
* This solves the described problem of the screen resolution not being written
  back even after minutes of inactivity.
* Renamed _TransactionNotify() to _TransactionWritten() to differentiate it
  a bit more from the new _TransactionListener().


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24738 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-04-02 09:46:34 +00:00
Axel Dörfler
16d8ff2dad * Added a TRANSACTION_IDLE notification that is sent when the transaction
hasn't been used for more than 2 seconds.
* Replaced the block_cache::lock benaphore with a recursive lock, so that
  you can call cache functions from within the notification listeners.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24737 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-04-02 09:37:22 +00:00
Ingo Weinhold
de73100825 Also check whether the supplied vnode is a directory, if there's only
one path component.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24736 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-04-02 01:55:37 +00:00
Ingo Weinhold
0cc0b6fc8f * Fixed resolution of symlinks path components, broken since
r24721/r24722. After resolving a symlink we weren't updating the local
  type variable to the type of the link target, so that the directory
  check in the next iteration would always fail.
* Added TODO.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24735 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-04-02 00:51:43 +00:00
François Revol
b9044f36d9 Was missing BFilePanel class declaration.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24734 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-04-01 23:09:21 +00:00
Oliver Ruiz Dorantes
4b7428b564 - Implement the server understand the Inquiry complete, and the Inquiry result.
- With this, we should be able to discover other devices, but not tested yet. No application to use this part of the kit



git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24733 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-04-01 21:59:23 +00:00
Oliver Ruiz Dorantes
1ba54b5b31 Fix correct handling of more than one event wanted in a single request
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24732 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-04-01 21:51:31 +00:00
Oliver Ruiz Dorantes
1f3aa49890 Complete asking the server all the events needed to perform a complete(basic) discovery process
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24731 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-04-01 21:48:05 +00:00
Michael Lotz
ec6da14fee Adding device ids for the i965GM chipset present in my laptop to the
intel_extreme driver and agp_gart. These worked for me for quite some time now.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24730 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-04-01 20:48:14 +00:00
Michael Lotz
4ad0015d56 * Retry some times when the device reports it is not ready
* Use the CBW_SIGNATURE define instead of the numeric value

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24729 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-04-01 20:43:45 +00:00