Commit Graph

1487 Commits

Author SHA1 Message Date
Christian Helmuth
cd6701c483 depot: update recipe hashes 2024-12-11 08:35:22 +01:00
Christian Helmuth
1d73cf2003 Prevent false warnings in memcpy (GCC 12)
GCC 12 tree-loop-distribute-patterns generates false warnings of
-Warray-bounds, -Wstringop-overflow, or -Wstringop-overread in memcpy()
and memcpy_cpu() in static/inline cases for code that obviously prevents
its execution by invariant checking. On -O3, even more warnings are
produced.
2024-12-10 14:12:24 +01:00
Benjamin Lamowski
b21c8729ea base: provide core_ram_allocator via platform_add_local_services()
This is a prerequisite to rework the allocation of core data structures
for VM sessions in hw.

Issue #5221
2024-12-10 14:11:57 +01:00
Christian Helmuth
011b44c282 depot: update recipe hashes 2024-11-20 08:58:39 +01:00
Norman Feske
4d7a5b6829 base: add Attached_dataspace::clear()
This alleviates the need (and risk) of manually parametrizing 'memset'
whenever the entire dataspace shall be cleared.

Issue #3897
2024-11-20 08:58:39 +01:00
Christian Helmuth
30f3ef25ad depot: update recipe hashes 2024-10-30 14:02:44 +01:00
Christian Helmuth
61c9706353 depot: update recipe hashes 2024-10-08 11:30:26 +02:00
Norman Feske
88dc4c878f util/geometry.h: test (in)equality of rectangles
The operators == and != make the 'Rect' consistent with 'Point' and
'Area'. The patch also adds the 'Rect::clamp' method, which is generally
useful for sanitizing input.

Issue #5352
2024-10-08 09:09:24 +02:00
Norman Feske
bf064874db util/string.h: Byte_range_ptr::with_skipped_bytes
The new method provides a safe way to narrow the byte range to a
given offset.

Issue #5351
2024-10-08 09:09:23 +02:00
Norman Feske
5c20de212a base: Attached_dataspace::bytes accessor
The new bytes() accessor returns a Byte_range_pointer as an alternative
to the 'local_addr' for accessing the content of the dataspace. This
facilitates the safe practice of passing (and validating) the buffer
bounds along with the pointer.

Issue #5351
2024-10-08 09:09:23 +02:00
Alexander Boettcher
ff506b0375 vm/x86: support extended fpu state transfer
Extend Genode's vCPU FPU state and adjust all users to copy
at most FPU data they actually support.

Issue #5314
2024-10-07 15:54:59 +02:00
Norman Feske
034de3b1b1 base/connection.h: allow customized cap-quota arg
By default, a 'Connection' donates an amount of caps as declared in
SESSION_TYPE::CAP_QUOTA to the server at session-creation time.

In some situations, however, a client may deliberately want to donate a
larger amount. For example, when opening a GUI session at the wm, the
total amount of needed caps is the sum of those consumed by the wm plus
those consumed by nitpicker. Using this knowledge, the Gui::Connection
may specify a sufficient amount to avoid iterative session-creation
retries. The new 'Connection' constructor accommodates this use case by
accepting an explicit 'cap_quota' argument.

Issue #5340
2024-10-07 14:44:31 +02:00
Christian Helmuth
26002a5482 depot: update recipe hashes 2024-08-29 12:32:25 +02:00
Alexander Boettcher
b443375cde timer_accuracy: disable nova on qemu 2024-08-27 15:29:38 +02:00
Alexander Boettcher
2e92b7ae32 nova: enable FPU AVX support
Add extended FPU state detection and handling (via xsave and friends) to the
kernel, which has to store/load more FPU state (~512 -> 2k++) during context
switching of threads. Additional the referenced nova branch contains various
optimization during VM destruction and cross core IPC resource caching.

This FPU work is based upon upstream NOVA kernel and Hedron commits.

Issue #5314
Fixes #3914
2024-08-27 15:29:37 +02:00
Stefan Kalkowski
6afe4f79a2 base: tie quota_lim_downscale template to size_t
* Always use size_t instead of template type
* Thereby we can remove 128-bit type from all architectures in base-hw

Ref genodelabs/genode#5310
2024-08-27 15:26:51 +02:00
Sebastian Sumpf
ddcfe51ef5 base/global.mk: TAR_OPT
Add TAR_OPT to global.mk that defaults to user and group 1, while
setting mtime to 0 for tar archives. This can be used in components to
produce consistent (reproducible) tar archives.

issue #5255
2024-07-02 12:00:11 +02:00
Norman Feske
943dfa10e7 base/child.h: remove exceptions from process init
This patch replaces the former Child::Process and
Child::Process::Loaded_executable classes by static functions that
return failure conditions as return values.

Issue #5245
2024-07-02 12:00:11 +02:00
Norman Feske
0288cffaee Remove exceptions from 'Parent' interface
Issue #5245
2024-07-02 12:00:11 +02:00
Norman Feske
19c13877ca Replace use of 'typedef' by 'using'
Issue #5227
2024-07-02 12:00:11 +02:00
Norman Feske
361557e1f0 base-*: omit () for lambas w/o argument
Issue #5227
2024-07-02 12:00:11 +02:00
Norman Feske
a2b0553c51 base-*: use C++20 function template syntax
Issue #5227
2024-07-02 12:00:11 +02:00
Johannes Schlatow
b5c9107465 use /depot as depot directory in debug info
By using GCC's --debug-prefix-map argument, we can make sure that debug
archives always refer to source files at /depot. With this change, GDB
can be pointed to the correct source-file location by using the `set
substitute-path /depot /path/to/local/depot`.

Fixes #5260
2024-07-02 12:00:10 +02:00
Norman Feske
d44ec53cd3 core: tie Platform_thread to Platform_pd
This patch tightens the coupling of the 'Platform_thread' objects
with their corresponding 'Platform_pd' objects by specifying the
'Platform_pd' as constructor argument, keeping the relationship
as a reference (instead of a pointer), and constraining the
lifetime of 'Platform_pd' objects to the lifetime of the PD.

It thereby clears the way to simplify the thread creation since all
PD-related information (like quota budgets) are now known at the
construction time of the 'Platform_thread'.

The return value of 'Platform_thread::start' has been removed because it
is not evaluated by 'Cpu_thread_component'.

Related to #5256
2024-07-02 11:59:16 +02:00
Alexander Boettcher
c18f7c7594 timer: remove old timer infrastructure
Fixes #5138
2024-07-02 11:59:16 +02:00
Alexander Boettcher
462718bcf0 epit: move timer to imx repository
Issue #5138
2024-07-02 11:59:16 +02:00
Norman Feske
0105494223 Rework Region_map interface
- Remove exceptions
- Use 'Attr' struct for attach arguments
- Let 'attach' return 'Range' instead of 'Local_addr'
- Renamed 'Region_map::State' to 'Region_map::Fault'

Issue #5245
Fixes #5070
2024-07-02 11:59:16 +02:00
Norman Feske
d866b6b053 Remove exceptions from Cpu_session interface
The 'Thread_creation_failed' error is now reflected as
'Thread::Start_result' return value. This change also removes the
use of 'Invalid_thread' within core as this exception is an alias
of Cpu_session::Thread_creation_failed.

Issue #5245
2024-07-02 11:59:16 +02:00
Stefan Kalkowski
e93f5fe8e0 base-hw: move imx53-specifics to imx repository
Ref genodelabs/genode#5252
2024-06-20 13:25:06 +02:00
Stefan Kalkowski
5a8d149fe3 hw: move all imx7d specifics to imx repository
Ref genodelabs/genode#5252
2024-06-20 13:24:41 +02:00
Alexander Boettcher
ed522d51c8 linux: use new timer scheme
Issue #5138
2024-06-20 13:19:43 +02:00
Alexander Boettcher
32c5ef32e9 foc: use new timer scheme
Issue #5138
2024-06-20 13:19:43 +02:00
Norman Feske
299951ced5 depot: update recipe hashes 2024-06-20 12:59:00 +02:00
Norman Feske
14d3c4cb5e Remove Cpu_session::State_access_failed exception
This patch removes the exception formerly thrown by 'Cpu_thread::state'
and turns the 'Thread_state' structure into a plain compound type w/o a
constructor.

Issue #5245
Fixes #5250
2024-06-20 12:56:20 +02:00
Norman Feske
5181d08d05 Remove exceptions from Rm_session interface
Issue #5245
2024-06-20 12:56:20 +02:00
Norman Feske
0d7d60a1f4 Remove exceptions from Pd_session interface
This patch replaces exceptions of the PD session RPC interface with
result types.
The change of the quota-transfer RPC functions required the adaptation
of base/quota_transfer.h and base/child.h.
The 'alloc_signal_source' method has been renamed to 'signal_source'
to avoid an exceedingly long name of the corresponding result type.
The Pd_session::map function takes a 'Virt_range' instead of basic-type
arguments.
The 'Signal_source_capability' alias for 'Capability<Signal_source>' has
been removed.

Issue #5245
2024-06-20 12:56:19 +02:00
Norman Feske
24342db476 base/signal.h: remove pointers from API
This patch updates the signal API to avoid raw pointers, and
replaces the Context_already_in_use and Context_not_associated
exceptions by diagnostic messages.

Fixes #5247
2024-06-20 12:56:19 +02:00
Norman Feske
8a0689d832 Remove Pd_session::Invalid_signal_source exception
While changing 'Pd_session::alloc_context', this patch also tightens the
type of the imprint argument.

Issue #5245
2024-06-20 12:56:19 +02:00
Norman Feske
a52c2ce141 Remove exceptions from TRACE session interface
- Use attempt pattern for error handling
- Replace lookup of pointers by with_ pattern
- Remove virtual Trace::Session methods
- Merge client.h into connection.h
- Update coding style of test/trace

Issue #5245
2024-06-20 12:56:19 +02:00
Norman Feske
7de2f57ef2 Remove Xml_node::attribute accessors
This patch removes the two 'Xml_node::attribute' accessors along with
the 'Nonexistent_attribute' exception.

Issue #5245
Fixes #5246
2024-06-20 12:56:19 +02:00
Norman Feske
ef385696f6 base/child.h: remove Nonexistent_id_space exception
This exception got introduced as a mere convenience for implementers of
'Child_policy' but required a special case in the base library.
Following the goal of eliminating exceptions from the base system,
this patch removes it by making a server_id_space mandatory.

Issue #5245
2024-06-20 12:54:30 +02:00
Norman Feske
dd4b19cda7 base: Remove use of Id_space::Unknown_id exception
Issue #5244
2024-06-20 12:54:30 +02:00
Norman Feske
7c91596922 Exception-less overload of 'Id_space::apply'
This patch allows the use of the 'Id_space' utility without catching
'Unknown_id' exceptions. Instead, the new 'apply' overload takes a
second functor 'missing_fn' as argument, which is called whenever the
lookup fails.

Issue #5244
2024-06-20 12:54:30 +02:00
Christian Helmuth
73d18261dc Fix calculation in timer_ticks_to_us()
Added missing factoring of the upper-half division remainder into the
lower-half calculation.

Fixes #5243
2024-06-20 12:54:30 +02:00
Norman Feske
c629c54153 Make util/geometry.h C++20 friendly
- Move header to base/include to make it applicable for base types
  like 'Affinity' down the road.
- Represent 'Rect' as typle of point and area, which is the most
  common form of initialization, creates in valid 'Rect' by default.
- Turn Point, Area, and Rect into compound types, making x, y, w, h, at,
  area accessible without a method call
- 'Rect::Compound' function for constructing a 'Rect' from two points,
  replacing a former constructor
- Use result type 'Rect::Cut_remainder' instead of out parameters.

Fixes #5239
2024-06-20 12:54:30 +02:00
Norman Feske
8943a3e949 Remove '_drv' suffix
Issue #4420
2024-06-20 12:54:30 +02:00
Christian Helmuth
996b2fe79f base: log invalid address value in heap 2024-06-20 12:54:29 +02:00
Alexander Boettcher
a3a84b25e8 image: support shim usage for uefi and disk
Fixes #5230
2024-06-20 12:54:29 +02:00
Christian Helmuth
4b9f4d8c38 depot: update recipe hashes 2024-05-30 08:20:21 +02:00
Norman Feske
5e862b2cd3 base/include: use C++20 function template syntax
Issue #5227
2024-05-29 09:18:12 +02:00