Commit Graph

1236 Commits

Author SHA1 Message Date
Alexander Boettcher
df26dc07e9 trace_subject_reporter: adjust ram usage
to trace connection

Issue #2638
2018-02-09 13:26:02 +01:00
Alexander Boettcher
7c0894159f top: consider dead thread with execution time
which executed in the current measurement period but are now dead.
Keep the Entry object up to next period, where the recent_execution_time will
become 0 since it will not execute definitely.

Issue #2638
2018-02-09 13:26:02 +01:00
Alexander Boettcher
2a0f940bd7 top: adapt to ram usage of trace connection
Issue #2638
2018-02-09 13:26:02 +01:00
Martin Stein
1936667a53 test/xml_node: test Xml_node::decoded_content
Issue #2644
2018-02-09 13:26:01 +01:00
Christian Helmuth
6013889028 depot: update recipe hashes 2018-01-17 12:14:44 +01:00
Josef Söntgen
4009239328 vfs: skip synced file systems in complete_sync
Fixes #2606.
2018-01-17 12:14:43 +01:00
Josef Söntgen
fb1c504568 gpu: the Intel multiplexer is only for x86_64
Require x86_64 because memory/adress space limitations on x86_32
restrict the use-cases on such a platform anyway. Doing that,
we can also assume that memory adresses are always 64bit long and
do not have to handle 32bit adresses.
2018-01-17 12:14:43 +01:00
Martin Stein
8844c57254 net-stat: remove as it is not used and outdated
According to the creator of the net-stat lib, this lib was a mere debugging
tool that is not used anymore nor worth the work of updating the it to
modern Genode coding paradigms. Also, there exist no tests for the lib.
2018-01-17 12:14:42 +01:00
Martin Stein
fbd545ae70 net: remove unused enums
Issue #465
2018-01-17 12:14:41 +01:00
Martin Stein
4f1d43ce21 net: remove placement new operators
They are not used any more.

Issue #465
2018-01-17 12:14:41 +01:00
Martin Stein
f4a2d932e3 net: check packet data size in accessor
Instead of having a method validate_size in each packet class, check
sizes in the data accessor of the surrounding packet class. This packet
accessor is the one that casts the data pointer to the desired data type
so it is sensible that it also checks whether the desired type would
exceed the available RAM before doing the cast. This also fits nicely
the fact that for the top-level packet-class of a packet, the size must
not be checked (which was previously done).

Issue #465
2018-01-17 12:14:41 +01:00
Sebastian Sumpf
89a9e88a7e vfs: GNU long file name support for tar 2018-01-17 12:14:41 +01:00
Christian Helmuth
2b711f59ed nit_fb: fix resizing on framebuffer-mode change
Respect relative width/height configuration if the underlying
framebuffer dimensions change.
2018-01-17 12:14:40 +01:00
Norman Feske
95a2fc7167 os: component to reflect ROMs as reports 2018-01-17 12:14:37 +01:00
Norman Feske
366bba0227 Exclude higher-level repos from strict warnings
This is a follow-up commit to "Increase default warning level", which
overrides Genode's new default warning level for targets contained in
higher-level repositories. By explicitly whitelisting all those targets,
we can selectively adjust them to the new strictness over time - by
looking out for 'CC_CXX_WARN_STRICT' in the target description files.

Issue #465
2018-01-17 12:14:36 +01:00
Norman Feske
eba9c15746 Follow practices suggested by "Effective C++"
The patch adjust the code of the base, base-<kernel>, and os repository.
To adapt existing components to fix violations of the best practices
suggested by "Effective C++" as reported by the -Weffc++ compiler
argument. The changes follow the patterns outlined below:

* A class with virtual functions can no longer publicly inherit base
  classed without a vtable. The inherited object may either be moved
  to a member variable, or inherited privately. The latter would be
  used for classes that inherit 'List::Element' or 'Avl_node'. In order
  to enable the 'List' and 'Avl_tree' to access the meta data, the
  'List' must become a friend.

* Instead of adding a virtual destructor to abstract base classes,
  we inherit the new 'Interface' class, which contains a virtual
  destructor. This way, single-line abstract base classes can stay
  as compact as they are now. The 'Interface' utility resides in
  base/include/util/interface.h.

* With the new warnings enabled, all member variables must be explicitly
  initialized. Basic types may be initialized with '='. All other types
  are initialized with braces '{ ... }' or as class initializers. If
  basic types and non-basic types appear in a row, it is nice to only
  use the brace syntax (also for basic types) and align the braces.

* If a class contains pointers as members, it must now also provide a
  copy constructor and assignment operator. In the most cases, one
  would make them private, effectively disallowing the objects to be
  copied. Unfortunately, this warning cannot be fixed be inheriting
  our existing 'Noncopyable' class (the compiler fails to detect that
  the inheriting class cannot be copied and still gives the error).
  For now, we have to manually add declarations for both the copy
  constructor and assignment operator as private class members. Those
  declarations should be prepended with a comment like this:

        /*
         * Noncopyable
         */
        Thread(Thread const &);
        Thread &operator = (Thread const &);

  In the future, we should revisit these places and try to replace
  the pointers with references. In the presence of at least one
  reference member, the compiler would no longer implicitly generate
  a copy constructor. So we could remove the manual declaration.

Issue #465
2018-01-17 12:14:35 +01:00
Stefan Kalkowski
6611c38184 depot: recipe for log_terminal
issue #2447 prequisite for #2621
2018-01-17 12:14:34 +01:00
Martin Stein
226c4a475b nic_router: do not warn on sending to empty domain
The warning "no interface connected to domain" was introduced when only one NIC
session at a time could be connected to a domain. It should help to track
packet drops that were caused by startup timing issues between servers and
clients. However, a user should watch the "NIC sessions" value of a domain
(verbose_domain_state) instead when debugging packet loss. With support for
multiple sessions per domain, even a non-empty domain may still miss the
session that connects the desired server.

Fix #2629
2018-01-17 12:14:33 +01:00
Martin Stein
57bfd09328 nic_router: no memcpy on self-written packets
Previously, all packets that the router wanted to sent were first prepared to
their final state and then copied at once into the packet stream RAM. This is
fine for packets that the router only passes through with modifying merely
a few values. But for packets that the router writes from scratch on its own,
it is better to compose the packet directly in the packet stream RAM.

Fix #2626
2017-12-22 11:43:39 +01:00
Martin Stein
b6991f9c03 nic_router: send with individual composing functor
Normally, Interface::send always takes the base and size of the RAM region
where a packet was composed and copies this finished packet at once into the
packet stream RAM. But we want to be able to also compose packets directly in
the packet stream RAM, so that no memcpy is needed. Thus, Interface::send now
takes a functor that describes how to compose the packet, then allocates the
packet stream RAM and applies the functor to this RAM. there is also a version
of Interface::send that provides the old behavior but with the new back end.
This way, we stay backwards-compatible.

Issue #2626
2017-12-22 11:43:39 +01:00
Martin Stein
4c76a87fec nic_router: explanatory comment about link objects
Issue #2609
2017-12-22 11:43:39 +01:00
Christian Helmuth
553cf556af depot: update recipe hashes 2017-12-21 15:01:56 +01:00
Stefan Kalkowski
7499379862 depot: recipe for part_blk 2017-12-21 15:01:55 +01:00
Martin Stein
b0e155d316 nic_router: fix available IP count in DHCP server 2017-12-21 15:01:55 +01:00
Martin Stein
d6d0bcd960 nic_router: no Arp_packet constructor when sending
When composing an ARP packet for sending, it's pointless to use the Arp_packet
constructor as the constructor only checks whether the packet is malformed.

Issue #2618
2017-12-21 15:01:55 +01:00
Martin Stein
1cae5ec8f6 nic_router: handle all "No_X_packet" exceptions
Issue #2618
2017-12-21 15:01:55 +01:00
Martin Stein
edf1f9d849 nic_router: report some useful information
The NIC router can now be configured to periodically send reports.
Configuration example (shows default values):

<config>
	<report interval_sec="5" bytes="yes" config="yes">
</config>

If the 'report' tag is not available, no reports are send.
The attributes of the 'report' tag:

'bytes'        : Boolean : Whether to report sent bytes and received bytes per
                           domain
'config'       : Boolean : Whether to report ipv4 interface and gateway per
                           domain
'interval_sec' : 1..3600 : Interval of sending reports in seconds

Issue #2614
2017-12-21 15:01:54 +01:00
Martin Stein
869297a672 nic_router: avoid "close" where we mean "dissolve"
In the context of link state objects we often used the term "close" were we
actually meant "dissolve". The term "close" originated from the TCP connection
state and is still used in TCP links in the correct manner.

Issue #2609
2017-12-21 15:01:54 +01:00
Martin Stein
859a5fd208 nic_router: simplify Interface::_new_link
Issue #2609
2017-12-21 15:01:53 +01:00
Martin Stein
4927a6f679 nic_router: multiple interfaces at one domain
Act as hub for the interfaces at a domain. This also changes the roles of the
Domain and Interface classes. By now the Interface held the data structures for
the ARP cache, foreign ARP waiters, and the searchtrees for layer 3 links. All
these structures have moved to the Domain while the memory allocations and
lifetime management for the contents of these structures still come from from
the according Interface object. The mentioned data structures were also adapted
to fit the fact that they now may maintain objects of different interfaces.

Issue #2609
2017-12-21 15:01:53 +01:00
Martin Stein
f524fb8e61 nic_router: support domain-local IPv4
If an IPv4 packet targets an IP local to the domain it comes from and doesn't
target the routers IP of that domain, forward it to all other interfaces of
the domain without considering any other routing.

Issue #2609
2017-12-21 15:01:53 +01:00
Martin Stein
b63d83e6a3 nic_router: get rid of Interface::print
Actually interfaces have no own human-readable identifier. They shall instead
use the print functionality of their domain.

Issue #2609
2017-12-21 15:01:52 +01:00
Martin Stein
0a77987778 nic_router: support domain-local ARP
Improve ARP handling code in general:
Make the several cases and their handling more clear by using a more
readable if/else statement structure. Drop gratuitous ARP requests.

Domain-local ARP:
Handle ARP packets that target local IPs other than the routers IP
(forward them to all other interfaces of the domain).

Issue #2609
2017-12-21 15:01:52 +01:00
Martin Stein
bfddad17a3 nic_router: avoid use of old term "IP allocation"
IP allocations were renamed DHCP allocations without fixing the according
places in log messages and comments. This commit rectifies this omission.

Issue #2609
2017-12-21 15:01:52 +01:00
Martin Stein
54532b99f9 nic_router: don't use color codes in log
Issue #2609
2017-12-21 15:01:51 +01:00
Emery Hemingway
ed89f2f7f0 Add millisecond accessor to Genode::Duration value object
Add a 'trunc_to_plain_ms' method to Gende::Duration to make
millisecond-accurate timing safer and more convenient.

Ref #2335
2017-12-21 15:01:51 +01:00
Josef Söntgen
6b89eaaf79 mixer: handle config verbosity update 2017-12-21 15:01:49 +01:00
Norman Feske
e23fc5a1fc init: refine verbosity handling
This patch makes service-announce messages depend on the configured
verbosity. It also omits "parent provides" title messages if no new
parent services are added during a config update.
2017-12-21 15:01:48 +01:00
Norman Feske
30f96657f1 rom_filter: make verbosity configurable 2017-12-21 15:01:48 +01:00
Norman Feske
48132c9ca3 fs_rom: remove debug message 2017-12-21 15:01:48 +01:00
Norman Feske
e4bb85b4de fs_rom: style (avoid Genode:: prefix) 2017-12-21 15:01:48 +01:00
Alexander Boettcher
892f51ab1c os: add app to transform kernel/core output to LOG
Issue #2207
2017-12-21 15:01:48 +01:00
Norman Feske
9f140ab843 chroot: adjust license header to AGPLv3 2017-12-21 15:01:46 +01:00
Emery Hemingway
4d9037d112 Hard-link loop detection for VFS tar file-system
Detect loops by walking hard-links at two different speeds and checking
for lapping. Tar link walking is no longer a recursive procedure.

Caught a loop created by GNU tar 1.29.

Fix #2611
2017-12-21 15:01:45 +01:00
Martin Stein
4dd69b1d5a nic_router: do not warn when using default values
Issue  #2590
2017-12-21 15:01:44 +01:00
Alexander Boettcher
c5f59ddfb1 signal.run: avoid deadlock during test destruction 2017-12-21 15:01:40 +01:00
Christian Prochaska
58cbd11f6a drivers_interactive-pbxa9: add input_filter
Fixes #2604
2017-12-21 15:01:38 +01:00
Martin Stein
9c0bd03363 nic_router: no DHCP fail on unexpected DISCOVER
If a client decides to spontaneously send a DHCP DISCOVER again, even though
he has received a still valid IP config from the router, we don't want to
discard the DISCOVER like it was done before but discard the IP config
assignment and offer a new one.

Issue #2534
2017-12-21 15:01:38 +01:00
Martin Stein
70c5c31ec9 nic_router: better warnings on bad DHCP requests
Be more descriptive about why the NIC router thinks that a DHCP request
sent to him is bad.

Issue #2534
2017-12-21 15:01:38 +01:00
Sebastian Sumpf
8808b99cc5 vfs: remove session ram quota checks
The first client that creates a session, has to pay for possibly large
vfs plugin allocations (e.g., rump), which should be payed for by the
server.
2017-12-21 15:01:37 +01:00