Commit Graph

189 Commits

Author SHA1 Message Date
Norman Feske
fb673fe4fd os: Add Rect::contains() to geometry utils 2014-05-07 10:37:36 +02:00
Norman Feske
3e4eb0d135 os: Refine Attached_rom_dataspace::update 2014-05-07 10:37:36 +02:00
Norman Feske
34dd7f982c os: Make buffer size of 'Reporter' configurable 2014-05-07 10:37:36 +02:00
Norman Feske
5de17d4223 os: Add 'Framebuffer::Session::sync_sigh'
The new framebuffer-session function allows a client to register a
handler for receiving display-synchronization events.
2014-05-07 10:37:35 +02:00
Norman Feske
8e74fdc585 vfs: inline file system 2014-04-29 15:19:27 +02:00
Norman Feske
959b26fee0 vfs: ROM file system 2014-04-29 15:19:27 +02:00
Norman Feske
83a03df6a4 vfs: LOG file system 2014-04-29 15:19:27 +02:00
Norman Feske
c3c6a82d13 Move VFS from noux to 'os/include/vfs'
By separating the VFS from Noux, we become able to reuse the
VFS for libc-using programs. The most substantial change is the
removal of Noux::Sysio data structures from the VFS. Instead, the
Noux::Sysio refers to the VFS types now.

The new VFS library is located at 'os/include/vfs/'.

Furthermore, the patch removes various code duplications related
to pseudo file systems that provide a single file (block, zero,
random, terminal, null). The new 'Single_file_system' holds the
common boilerplate code for those.

Issue #999
2014-04-29 15:19:27 +02:00
Norman Feske
2b5f4b0aaf file system: Exception for non-permitted symlinks
Until now, there was not exception type for the condition where a
symlink was created on a file system w/o supporting symlinks, e.g., FAT.
The corresponding file-system server (ffat_fs) used to return a negative
handle as a work around. I added 'Permission_denied' to the list of
exceptions thrown by 'File_system::Session::symlink' to handle this case
in a clean way.
2014-04-24 14:56:36 +02:00
Norman Feske
d83e076f11 terminal_session: Add label argument to connection 2014-04-24 14:56:36 +02:00
Alexander Boettcher
73f71322f0 init: put ep for child in affinity space of child
Issue #1107
2014-04-14 12:32:30 +02:00
Alexander Boettcher
a604ea6851 os: reprogram timer solely if needed
If an alarm/timeout object became head of the timeout queue, then the
low level timer must be reprogrammed.

Issue #1106
2014-04-01 16:42:37 +02:00
Johannes Schlatow
da9e764c47 Init: bugfix
Fix a use-after-free bug concerning the use case where the config
of the init process changes dynamically. The childs' services were not
removed from the corresponding Service_registry properly.

Fixes #1094
2014-03-14 13:17:37 +01:00
Norman Feske
6525ec5951 Simplify Framebuffer::Session interface
This patch removes the 'Framebuffer::Session::release()' function from
the interface to make the mode-change protocol consistent with the way
the Rom_session interface handles ROM-module changes. That is, the
client acknowledges the release of its current dataspace by requesting a
new dataspace via the 'Framebuffer::Session::dataspace()' function.

Fixes #1057
2014-03-14 13:17:35 +01:00
Norman Feske
4c45f3451c os/reporter.h: Don't enable if connection fails
If opening a report session fails (for example because of invalid
session arguments) and an exception is thrown during the session
construction, the report would wrongly keep the enabled state.
By moving the assignment of the state after the construction,
the report stays disabled as it should be.
2014-02-28 10:11:51 +01:00
Norman Feske
1498bb740b nitpicker: Parent-child relation between views
Fixes #1020
2014-02-28 10:11:50 +01:00
Alexander Boettcher
5d9b563503 framebuffer: fix ambiguity for strncpy 2014-02-28 10:11:10 +01:00
Stefan Kalkowski
6ca8a41232 core: lower default verbosity when quota exceeds
* only print quota exceeded message and statistic when explicitly enabled
* turn init's error message "cannot respond to request" into a warning
2014-02-25 14:58:06 +01:00
Stefan Kalkowski
746011ee28 blk_cache: fix deadlock in allocator hierarchy
This commit generalizes the bit array in 'base/util/bit_array.h',
so that it can be used in a statically, when the array size is known
at compile time, or dynamically. It uses the dynamic approach of the
bit array for a more generalized version of the packet allocator,
formerly only used by NIC session clients. The more generic packet
allocator is used by the block cache to circumvent the allocation
deadlock described in issue #1059.

Fixes #1059
2014-02-25 14:58:06 +01:00
Norman Feske
276a1775f1 Accessors for Xml_node utility
This patch adds accessors to obtain the buffer of an attribute value,
which is useful to avoid the copying-out of such information by
maintaining pointers into the XML string as meta data.
2014-02-25 14:58:04 +01:00
Norman Feske
c265cfa593 Add 'operator *' to os/volatile_object.h
This operator is needed when we want to create a reference to (the
content of) a volatile object.
2014-02-25 14:58:04 +01:00
Norman Feske
6f9e15aff8 base: Add 'construct_at' utility
This utility allows for the manual placement of objects without the need
to have a global placement new operation nor the need for type-specific
new operators.

Issue #989
2014-02-25 14:58:03 +01:00
Stefan Kalkowski
eeb2d95b1f block: prevent from dereferencing invalid pointers
Until now, block drivers had to deal with a pointer to the client
session component, e.g.: to acknowledge block packets already processed.
When a session was closed, the driver object wasn't informed explicitly,
which leads to defensive programming, or lastly to a race-condition in
test-blk-srv. To prevent from this class of errors, the pointer is now
private to the generic block driver base class, and not accessible to
the concrete driver implementation. Moreover, the driver gets explicitly
informed when a session got invalidated.

Ref #113
2014-02-25 14:58:02 +01:00
Stefan Kalkowski
7876dfcb5e block: free packet stream dataspace on destruction
Fixes #1033
2014-01-30 10:05:44 +01:00
Stefan Kalkowski
c888ff0d76 pci_session: add free_dma_buffer call (Fix #1037) 2014-01-30 10:05:44 +01:00
Christian Helmuth
3234e4f775 Make Deallocator::need_size_for_free() pure virtual 2014-01-30 10:05:43 +01:00
Norman Feske
99979e09ed Xml_node::Attribute::value_size accessor 2014-01-27 18:54:08 +01:00
Norman Feske
2a576da2b0 Infrastructure for posting status reports
This commit introduces the "Report" session interface and a simple
service to forward reports to the LOG service.

Fixes #1026
2014-01-27 18:54:08 +01:00
Norman Feske
bdfbe9f20e New 'os/attached_dataspace.h' utility
The new Attached_dataspace complements the existing Attached_*
utilities with a simple version that can be used with any kind of
dataspaces. It may be even useful as a common base type for the other
variants. For example, this patch simplifies Attached_rom_dataspace
and removes the Terminal::Client::Io_buffer.
2014-01-27 18:54:07 +01:00
Norman Feske
759e11f9af Add Attached_rom_dataspace::update
This patch enhances the 'Attached_rom_dataspace' utility to support
dynamic updates of ROM modules.
2014-01-27 18:54:07 +01:00
Norman Feske
b6f59fb9be XML generator and test
Fixes #1019
2014-01-27 18:54:07 +01:00
Norman Feske
865f2b263f New utility for managing volatile class members
Fixes #1025
2014-01-27 18:54:07 +01:00
Norman Feske
8c8d53777f Generalization of nitpicker's graphics backend
This patch re-arranges nitpicker's graphics backend in a more modular
and expandable way. Generalized versions of the 'Canvas',
'Chunky_canvas', and 'Pixel_*' classes have been moved to
'os/include/util/' and 'os/include/os'. The only remaining parts that
are specific to nitpicker's needs are a few drawing functions, each
located in a distinct header at 'os/include/nitpicker_gfx/'.
2014-01-27 18:54:06 +01:00
Norman Feske
765053ea94 Remove nitpicker_gfx/nitpicker_types.h 2014-01-27 18:54:06 +01:00
Norman Feske
0063f217ca Move nitpicker_gfx/color.h to util/color.h 2014-01-27 18:54:06 +01:00
Norman Feske
e809192b97 Remove nitpicker_gfx/miscmath.h 2014-01-27 18:54:06 +01:00
Norman Feske
35bfc34db5 Move nitpicker_gfx/geometry.h to util/geometry.h
This patch makes nitpicker's geometry utilities available for the use
by other programs. Thereby, the 'Point', 'Area', and 'Rect' classes
have become templates that take the coordinate type and distance type
as arguments.
2014-01-27 18:54:06 +01:00
Stefan Kalkowski
6a076ff621 block: use new server framework in block drivers
As a side effect, the entrypoints in the USB driver are merged into one thread.

Fixes #1027
2014-01-27 18:53:52 +01:00
Stefan Kalkowski
23ce0b2071 block: fix race in generic block driver component
Fixes #1023
2014-01-16 18:34:06 +01:00
Stefan Kalkowski
65291902e0 os: manage/dissolve Signal_rpc_member in class
Instead of, passing responsibility to manage and dissolve Signal_rpc_member
objects at a corresponding entrypoint to the user, hand over entrypoint's
reference to the constructor, and do it in the constructor resp. destructor
of the class.

Fixes #1022
2014-01-16 18:34:06 +01:00
Josef Söntgen
1c67e3bb43 os: extentend File_system interface with sync RPC
Users of a File_system_session might want to force a file system
to flush or rather to synchronize its internal cache. A concret
default implementation is provided because not all file systems
maintain an internal cache and are not required to synchronize
caches.

Fixes #1007.
2013-12-20 15:20:05 +01:00
Alexander Boettcher
b893968232 base: show size as %zu instead %zd
For big numbers otherwise negative sizes for memory chunks are displayed.

Issue #1011
2013-12-20 15:16:19 +01:00
Stefan Kalkowski
e73a71be12 packet stream: clean range allocator in destructor 2013-12-19 11:34:05 +01:00
Stefan Kalkowski
56a7d00a44 block: extend generic driver API (Ref #750)
* allow to handle a maximum of packets in parallel
  that fits free slots in the ack queue
* stop processing packets, when the driver can't handle
  more requests in parallel, and resume packet handling,
  when the driver is ready again
2013-12-19 11:34:04 +01:00
Stefan Kalkowski
b10b9e20a2 block: support for block number >32 bit (Fix #968) 2013-12-19 11:34:04 +01:00
Josef Söntgen
038fcf032a os: dissolve contexts in Packet_stream
Fixes #1003.
2013-12-11 08:25:44 +01:00
Stefan Kalkowski
c3c643bcf1 block: let generic driver API work asynchronously
Fix #990
2013-12-04 11:14:18 +01:00
Stefan Kalkowski
0c8a4f9f3a block: extend interface of generic driver class
To support read-only devices like CDROMs, or rom_blk the supported
block operations have to be stated by specific the device driver.

Ref #966
2013-12-03 08:33:26 +01:00
Stefan Kalkowski
5a4cb7fcfb block: eliminate thread in generic block_component
Instead of using an additional thread in each Session_component of a
block server, which uses the generic block component and driver classes,
replace it with signal dispatchers.

Ref #113
2013-12-03 08:33:26 +01:00
Christian Helmuth
76cd788479 Fix some typos 2013-11-26 14:32:06 +01:00