Commit Graph

3401 Commits

Author SHA1 Message Date
Hugo Santos cf5d9f4b8d added 'udp_endpoints' debugger command.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@20908 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-04-29 19:03:06 +00:00
Hugo Santos 0be6e97788 minimal cleanups
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@20901 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-04-29 13:11:30 +00:00
Ingo Weinhold dac7faad8d Added volume initialization support.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@20900 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-04-29 07:22:22 +00:00
Hugo Santos 6bad493439 pushed the slab init a bit deeper. added a object cache based allocator, including a bootstrap mechanism to have it init during bootup.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@20896 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-04-29 02:23:37 +00:00
Ingo Weinhold 3b8715d804 Provide a way to convert FS shell error codes to host platform error
codes.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@20890 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-04-28 23:40:04 +00:00
Hugo Santos 6e31ae98f9 some object cache / slab improvements.
- call the reclaimer callback when low on memory.
 - use the depot when on multi-cpu setups (for scalability).
 - fixed the amount of memory spent on slabs for very large objects.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@20889 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-04-28 21:35:23 +00:00
Hugo Santos 11b5020f2f rewrote the object cache (slab) implementation a bit, preparing for further integration.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@20887 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-04-28 18:53:58 +00:00
Hugo Santos 8a96ba39e3 some slab cleanups, split the C interface to another file.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@20875 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-04-28 09:37:38 +00:00
Hugo Santos 4e8a1b331f miniature cleanups.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@20874 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-04-28 09:37:26 +00:00
Ingo Weinhold 90c0876839 FS shell changes:
* Added basic built-in module support.
* Added rootfs.
* Added "kernel" initialization.
* Exposed the FS syscalls.
* Mounting/unmounting the FS works now.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@20873 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-04-27 22:37:01 +00:00
Hugo Santos 505e98538a introduced MultiHashTable, similiar to multimap, but with hash table semantics.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@20864 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-04-27 15:06:30 +00:00
Hugo Santos 01a10fc527 fixed OpenHashTable::Iterator, it wasn't working for a single item.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@20862 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-04-27 14:47:34 +00:00
Ingo Weinhold a38a92c955 Beginnings of a new, better portable FS shell with Haiku FS interface.
Doesn't do anything ATM, but already provides the required system
interface (VFS, caches, POSIX functions).


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@20859 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-04-27 12:17:22 +00:00
Ingo Weinhold f38eff6aa2 Added a few more functions to the host platform BeOS compatibility layer:
* thread related functions,
* semaphore related functions,
* atomic_*() functions,
* readv_pos(), writev_pos().


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@20858 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-04-27 12:11:30 +00:00
Hugo Santos 8ac2dba331 added iterator to OpenHashTable.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@20853 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-04-27 08:07:38 +00:00
Hugo Santos 5084c83901 addressed Axel's suggestion regarding SocketAddress' GetPort() name.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@20851 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-04-27 07:20:43 +00:00
Hugo Santos 25a2744f9e adapted UDP to use AddressUtilities, for readability.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@20850 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-04-27 07:10:11 +00:00
Hugo Santos 4b55736dde added new helper ProtocolSocket. Moved some stuff together to achieve better inlining.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@20848 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-04-27 07:09:46 +00:00
Marcus Overhagen 4b095722c7 new debug header for media kit
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@20846 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-04-26 20:40:27 +00:00
Marcus Overhagen a4c8b51d3a changed header guard
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@20845 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-04-26 20:39:30 +00:00
Hugo Santos 5d6551d69f removed some of the slab's initial heavy debugging. we now merge the links into the slab itself resulting in zero overhead per buffer with MergedLink strategy.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@20841 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-04-26 15:40:53 +00:00
Hugo Santos e6fb3d3947 more slab fixes, also introduced a new strategy optimized for medium sized buffers (64 >= x < 512) with lengths other than power of 2 (has an overhead of 2 words per buffer).
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@20839 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-04-26 11:38:24 +00:00
Hugo Santos dd89ad0e7e added locking to slab's Cache<>. Now we react to system's low memory conditions freeing up empty slabs.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@20836 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-04-26 07:31:19 +00:00
Hugo Santos b8c0d6618e gcc 4 compilation fixes.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@20835 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-04-26 06:32:25 +00:00
Hugo Santos 81bc570922 assorted slab fixes.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@20833 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-04-26 06:05:08 +00:00
Hugo Santos 81423c91c7 added initial slab code to the kernel. It is still unused, and there is still no VM interaction.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@20832 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-04-26 03:41:24 +00:00
Hugo Santos 77e70865e1 moved the storage requirements (i.e. ParentType *) to OpenHashTable's Definition which we now instantiate per OpenHashTable.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@20824 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-04-25 19:21:06 +00:00
Hugo Santos 2586c25e31 use Chaining in OpenHashTable.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@20822 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-04-25 18:55:05 +00:00
Hugo Santos 66a4a42802 added Recv-Q/Send-Q output to netstat.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@20819 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-04-25 17:41:18 +00:00
Hugo Santos 585195c28d introduced SocketAddress wrappers and use them in TCP.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@20818 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-04-25 17:41:01 +00:00
Jérôme Duval c36e4d4c9f updated freetype to 2.3.4
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@20817 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-04-25 17:18:01 +00:00
Hugo Santos 53f23f85a2 partially rewrote TCP's endpoint manager. Fixes #1173
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@20814 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-04-25 16:14:14 +00:00
Axel Dörfler 5c03270bea Added block_cache_sync_etc() that allows you to sync single blocks.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@20811 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-04-25 12:07:30 +00:00
Hugo Santos 85dbe747c4 open addressing self-extending hash table implementation.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@20791 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-04-24 11:04:35 +00:00
Jérôme Duval 56490cf3b7 virtualized DirectConnected() and EnableDirectMode()
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@20786 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-04-23 22:08:34 +00:00
Hugo Santos 8a819b17e4 retrieve the incoming interface on the domain_receive_adapter(). This should fix potential issues with packets addressed to the IP broadcast address, such as in with some DHCP implementations.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@20767 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-04-20 04:40:53 +00:00
Hugo Santos 74b0e85845 merged a bit more of functionality into DatagramSocket so we don't require a custom ReadData in the link protocol.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@20765 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-04-20 02:13:54 +00:00
Hugo Santos 2445c00e64 some internal reorganization of getsockopt()/setsockopt() handling. TCP is now able to fully use the application requested sender/receiver buffer sizes for improved performance.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@20764 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-04-20 01:58:14 +00:00
Stephan Aßmus 375dc591e6 * thought of an extension for the icon editor protocol
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@20755 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-04-19 19:28:57 +00:00
Stephan Aßmus f591eb8ba0 * cleanup license header (and convert Jérôme to UTF8)
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@20754 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-04-19 19:26:44 +00:00
Stephan Aßmus 66cd7e6cc6 * define some more stuff
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@20753 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-04-19 19:22:49 +00:00
Jérôme Duval 31ebfe61e4 added default sound events
implemented system_beep() by sending an event to the media addon server


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@20728 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-04-16 19:15:46 +00:00
Hugo Santos d5b5a2c2f8 introduced Checksum::PseudoHeader helper.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@20717 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-04-15 23:18:15 +00:00
Hugo Santos 1408d1f0ce introduced datalink's send_datagram to perform route and source address selection and dispatch the datagram to appropriate domain/protocol.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@20714 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-04-15 22:11:12 +00:00
Hugo Santos 624c52d8b7 ARP now queues packets while resolving a destination instead of blocking on send_data(). This fixes several issues:
- TCP now behaves correctly when receiving new connections as its SYN/ACK is queued, or if lost correctly retransmitted when the peer resends a SYN.
 - The first ICMP Replies from an external on-link host pinging Haiku are no longer lost.
 - Reduced the number of ARP messages Haiku needs to generate until resolving an entry.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@20712 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-04-15 21:00:12 +00:00
Jérôme Duval 33c487a43e implemented add_system_beep_event()
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@20711 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-04-15 20:40:12 +00:00
Jérôme Duval 88ec4b1dbe fixed some warnings
code style of MMediaFilesManager.* 


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@20703 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-04-15 13:59:59 +00:00
Hugo Santos 6a60618094 glued the multicast filter handling to the receive path: we are now capable of receiving multicast frames in datagram sockets.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@20695 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-04-15 07:31:04 +00:00
Hugo Santos 6c501a4085 support RFC 3678's Protocol-Independent setsockopt()s for IPv4 multicast.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@20691 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-04-15 03:07:28 +00:00
Hugo Santos 46527f6806 initial steps towards IPv4 Multicast Filter Delta API (RFC 3678)
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@20690 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-04-15 02:44:01 +00:00
Axel Dörfler ffcc37a0aa * Added and implemented B_INVALIDATE as available on Dano; to invalidate only a certain
part of the view, you can add a BRect "be:area" to that message - very handy.
* Cleaned up AppDefs.h a bit.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@20683 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-04-14 18:11:42 +00:00
Hugo Santos 49f3c71e21 respect SO_BROADCAST for received and sent datagrams.
- check if the destination address is specified in IPv4's SendData()
 - minor cleanups to IPv4's TRACE()s.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@20681 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-04-13 21:33:13 +00:00
Marcus Overhagen 36e0e8a8bd Interface definition of DVB drivers. Currently private API.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@20677 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-04-13 15:52:58 +00:00
Hugo Santos 658a550639 use module_dependencies to load the required modules by udp, tcp, ipv4, icmp and arp.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@20676 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-04-13 14:37:48 +00:00
Hugo Santos 57e2a3d584 only deliver frames to IPv4 raw sockets of the specified protocol.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@20675 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-04-13 04:20:39 +00:00
Hugo Santos d438fa4c12 added buffer, datalink and socket module references to the stack module so we don't have to load them in each other module.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@20673 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-04-13 03:06:36 +00:00
Hugo Santos bfb45f717c introduced a new helper class DatagramSocket which provides a consistent base interface and functionality for the implementation of datagram-based sockets.
- made the ipv4 raw, udp and link protocols use DatagramSocket.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@20672 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-04-13 00:55:32 +00:00
Jérôme Duval 72b4b94081 use __builtin_offsetof for gcc4 and superior, it avoids a gcc4 broken build with template use of offsetof()
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@20669 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-04-12 18:36:37 +00:00
Jérôme Duval b342ed59fb gcc4 is picky with in-template symbols, they must be qualified
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@20668 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-04-12 18:17:31 +00:00
Jérôme Duval b12aab90c7 fixed typo
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@20667 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-04-12 18:11:11 +00:00
Hugo Santos 6c35350908 moved address selection logic to a new 'get_buffer_route'.
- IPv4 now assumes the addresses it is supplied in send_routed_data are already the appropriate ones.
 - made the Data(), operator* and operator-> methods in NetBufferFieldReader const so we can use them in the same expression as the constructor.
 - fixed an issue with UDP where the wrong source address could be used in the calculating the checksum.
 - changed ipv4_print_address to use the more common 0.0.0.0 format.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@20660 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-04-11 22:24:12 +00:00
Hugo Santos 87001e059c some NetBufferUtility revamp.
- introduced base NetBufferFieldReader which deals with obtaining a continuguous field to deal with.
 - renamed Detach() to Sync() to better express the fact that we may be writing to the buffer.
 - Fixed IPv4's and ICMP's checksum calculation as it assumed the underlying header was contiguous.
 - ICMP is now able to reply to ICMP Echo Requests which were split across data nodes.
 - in split_buffer(), make sure we were able to trim() the new buffer before damaging the original one.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@20657 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-04-11 16:40:40 +00:00
Hugo Santos af56b5b233 fixed add_tcp_header() as it wasn't considering the possibility that prepending data would not result in a contiguous buffer. This would result in wrong checksums for apparent no reason.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@20643 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-04-10 19:04:13 +00:00
Hugo Santos 8107b19403 Fixed some more TCP issues.
- Properly flag sockets using non-blocking connects() when in SYN SENT.
 - and when in LISTEN, we should use the socket's connection queue size.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@20631 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-04-10 05:28:56 +00:00
Hugo Santos e53357d57a Prepared net_device_monitor to accept device removal events.
- Introduced public net_device_monitor.
 - Changed the link protocol to maintain a lock per instance instead of inside the FIFO. Now all of the link instance data is protected.
 - Adapted the link protocol to use net_device_monitor.
 - Introduced a private Fifo class which doesn't maintain it's own lock.
  - Maybe we should add something like a public net_protocol_implementation which maintains a fifo and a benaphore? With the fifo using the structure's lock instead of maintaining it's own.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@20614 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-04-08 09:15:52 +00:00
Ingo Weinhold d307e81230 Added ENOATTR.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@20607 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-04-08 02:01:07 +00:00
Jérôme Duval 0c93c0a807 change the way FileGameSound works : avoid using a port
code style, some clean up


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@20603 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-04-06 22:40:23 +00:00
Hugo Santos 0d5afa4dec introduced fifo_socket_enqueue_buffer which clones the buffer, enqueues it to the fifo and notifies the socket.
- changed the link, ipv4 and udp modules to use fifo_socket_enqueue_buffer


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@20587 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-04-05 17:56:20 +00:00
Hugo Santos 17b77c3b92 consolidate all RECV/SEND ioctls into a single RECEIVE/SEND pair
- changed the socket module to use thew new RECEIVE/SEND in all forms of recv() and send()
 - changed libnetwork to use the new RECEIVE/SEND
 - remove transfer_args processing from strace since the structure was removed


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@20581 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-04-05 14:26:46 +00:00
Hugo Santos dae7f8ea46 initial recvmsg and sendmsg implementations
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@20562 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-04-04 17:39:43 +00:00
Hugo Santos 36883c5516 ipro1000: added ETHER_GET_LINK_STATE support
* use em_media_status to get link status
 * added IFM_1000_SX (Fiber Optic) to net/if_media.h


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@20551 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-04-04 12:50:54 +00:00
Axel Dörfler 9206bb3779 * Changed ETHER_GET_LINK_STATE ethernet driver interface, added ETHER_SET_LINK_STATE_SEM.
* The device interface list now uses class DoublyLinkedList instead of struct list.
* Implemented SIOC[SG]IFMEDIA for setting (not supported by any device yet), and
  retrieving the device media information.
* Fixed a locking bug in list_domain_interfaces().
* Added new stack function device_link_changed() that should be called in case the
  link state (media) changed.
* The ethernet device module now spawns a thread and will periodically check the media
  state of all ethernet devices that support this (if any).
* Minor cleanup.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@20546 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-04-04 09:41:04 +00:00
Axel Dörfler 1a3ab92b81 * Rewrote ether_driver.h, removed some BONE stuff we don't support at this point;
it might also be a good idea to change the constants to better match the usual
  style.
* Added a BSD-style if_media.h.
* Added interface flags IFF_LINK, IFF_AUTO_CONFIGURED, and IFF_CONFIGURING. The
  former will be set automatically by the stack, the rest will be set by the
  net_server depending on the current state.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@20535 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-04-03 14:42:07 +00:00
Ingo Weinhold ed07b9c7e3 The last missing hooks -- get_vnode_name(), write_attr_stat() and
rewind_query() -- are passed to the userland. get_vnode_name() has an
emulation in userland, in case the client FS doesn't implement it.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@20522 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-04-03 04:40:54 +00:00
Axel Dörfler 2d55afcdf7 Support getting route information for a specific destination
using SIOCGETRT. Patch by Hugo Santos.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@20494 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-04-01 12:06:16 +00:00
Ingo Weinhold 27d37d4d24 * Optional debug feature for tracking which page queue a page should be
in.
* New debugger command "find_page", which searches all page queues to
  find out, which one a page is actually in.
* Solved nasty race condition between the page scrubber and
  vm_page_allocate_page_run(): The page scrubber didn't mark the pages
  it was processing busy, so that vm_page_allocate_page_run() could claim
  them in the meantime. They would end up in the clear pages queue,
  although being assigned to a cache at the same time. This should
  finally solve bug #1056.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@20474 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-03-30 19:48:51 +00:00
Axel Dörfler 9c62a6ed7d Rewritten Debug.h by Vasilis Kaoutsis.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@20473 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-03-30 14:43:25 +00:00
Ingo Weinhold b8ba8f58d7 Added the disk device API to the libbe_haiku.so, so that libtracker.so builds
again for target libbe_test. Added respective syscall stubs and other functions
to libhaikucompat.a.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@20447 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-03-28 15:20:08 +00:00
Ingo Weinhold 2b2ec4382a * Moved the AutoLocker class out of the kernel/utils/AutoLock.h header
into its own shared/AutoLocker.h. It can be used by userland code too.
* Removed headers/private/shared/ObjectLocker.h and replaced all uses of
  BObjectLocker by AutoLocker.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@20432 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-03-27 12:05:33 +00:00
Axel Dörfler c6a7ff7a9f * The new vm_page_mappings weren't updated correctly in many cases.
* Added a comment to vm_remove_all_page_mappings() that shows that we need to
  change the mapping spinlock into a mutex.
* Pointed out some potential problems in the code.
* Added vm_page_at_index(), vm_clear_map_activation(), and vm_test_map_activation()
  in preparation of the page scanner rewrite.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@20407 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-03-23 11:48:37 +00:00
Ingo Weinhold 27810ccf5e Added the last useful features I dare imagine: A Lock() method and the
possibility to initialize the AutoLocker without locking the object even
if it is unlocked yet. Especially in loops Lock()/Unlock() come handy
when an otherwise constantly hold lock needs to be unlocked for a short
time.

I suppose we should move the kernel utils AutoLocker implementation
to headers/private/shared, and drop the less powerful ObjectLocker.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@20405 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-03-23 00:03:59 +00:00
Axel Dörfler bdfc47dbcd * Fixed the test for equality when a known ARP reply came in - you should no longer
see the "ARP entry updated with different address" message.
* sockaddr_dl::sdl_data is now unsigned (uint8_t instead of char).


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@20399 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-03-20 22:21:36 +00:00
Ingo Weinhold 44b5d72b5a Added new functions to the debugger API:
{set,clear}_debugger_{break,watch}point(), allowing to set/clear break
and watchpoints for the calling team. When a break/watchpoint is hit,
the team enters the debugger. Handy in situations when the program in
question can't really be started in a debugger (or it would be
complicated to do so). The functions work only as long as no debugger is
installed for the team.

We clear the arch specific team and thread debug infos now, when a new
debugger is installed, thus clearing break- and watchpoints.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@20396 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-03-20 16:20:13 +00:00
Ingo Weinhold 2c97a8d164 Use -I instead of -isystem for system header directories when building
with gcc 4. Fixed resulting build errors (gcc is more lenient for
headers in -isystem directories).


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@20386 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-03-14 20:36:42 +00:00
Jérôme Duval 4d275b2b21 added some Haiku media definitions
made mpglib beos compatible


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@20383 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-03-13 23:10:19 +00:00
Stefano Ceccherini a3d758e369 Added support for font settings in PictureDataWriter. Not used yet
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@20381 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-03-13 11:14:47 +00:00
Ingo Weinhold d0c61f232b More distinctive header guard.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@20370 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-03-11 21:20:23 +00:00
Axel Dörfler 826e857cf0 Implemented hash_remove_current() which removes the current iterator position
from the hash - not yet tested.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@20368 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-03-11 21:18:49 +00:00
Ingo Weinhold 9781d591cb Include <util/kernel_cpp.h> in DoublyLinkedList.h only when compiling
for the kernel. Added missing includes in userland code that uses the
header.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@20366 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-03-11 13:56:45 +00:00
Axel Dörfler 6e601ee88f get_memory_map() now panics (and fails) in case it was called on unmapped memory as
suggested by Ingo; before it would just fill the physical pages with NULL pointers.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@20364 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-03-11 13:27:42 +00:00
Axel Dörfler 1594e83f84 * All mapped pages that are not wired (ie. locked) now have a vm_page_mapping object
that points to both, the page and the area the page is in. This will allow a page
  scanner to steal unused pages when necessary.
* The locking is currently done with a spinlock which we might want to have another
  look at one day.
* dump_page() and dump_area_struct() now dump the page mappings as well.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@20356 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-03-08 14:35:26 +00:00
Ingo Weinhold 2f92537221 One unremove_vnode() prototype shall suffice.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@20339 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-03-06 01:22:47 +00:00
Axel Dörfler 863634b83f Patch by Euan Kirkhope:
* Initial support for Rage Theatre 200.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@20338 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-03-05 21:16:15 +00:00
Axel Dörfler 76b5213f47 Patch by Euan Kirkhope:
* Use AGP Bus manager module
* Fixed wrong framebuffer address computation; this should fix bug #1079.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@20336 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-03-05 17:06:27 +00:00
Ingo Weinhold 4e0e80ed6c We analyze a client FS's capabilities -- i.e. which hooks it provides or
can be emulated -- and pass this info to the kernel add-on. Thus we can
avoid passing requests to the userland that can't be serviced anyway.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@20331 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-03-05 05:16:08 +00:00
Ingo Weinhold cf4ccd6575 Renamed the FS interface hook read_link() to read_symlink().
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@20330 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-03-05 03:52:57 +00:00
Ingo Weinhold 12d359b85a * Removed write_link from the FS module interface. Adjusted all FS
add-ons accordingly and removed the syscall.
* Removed send_notification().
* Reimplemented notify_listener(). It used the unimplemented
  send_notification(). Now it has a chance to work. Note that
  notify_listener() is obsolete. I would already have removed it, if
  there weren't lots of FS implementations still using it (Hint!).


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@20329 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-03-05 00:46:57 +00:00
Ingo Weinhold 6aeea78c6e Made the UserlandFS code gcc4 friendly.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@20322 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-03-04 08:26:45 +00:00
Ingo Weinhold eb9b19800b Fixed gcc 4(.1.2) build problems.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@20320 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-03-04 05:00:40 +00:00
Ingo Weinhold 30589be58b Added C++ guard. I don't know, why we define the <wctype.h> protos both
there and in <wchar.h>. Any reason for not removing them in <wctype.h>? Or
maybe even nicer reverse the inclusion direction, i.e. remove the
duplicate protos in <wchar.h> and include <wctype.h> instead.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@20317 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-03-04 02:31:43 +00:00