Merge branch 'genodelabs:master' into master

This commit is contained in:
Michael Müller
2024-11-18 12:17:16 +01:00
committed by GitHub
887 changed files with 13376 additions and 7209 deletions

View File

@@ -4,6 +4,33 @@
=========== ===========
Sculpt OS release 24.10 | 2024-10-30
####################################
| Thanks to a largely revamped GUI stack, the Genode-based
| Sculpt OS 24.10 has gained profound support for multi-monitor setups.
Among the many usability-related topics on our road map, multi-monitor
support is certainly the most anticipated feature. It motivated a holistic
modernization of Genode's GUI stack over several months, encompassing drivers,
the GUI multiplexer, inter-component interfaces, up to widget toolkits. Sculpt
OS 24.10 combines these new foundations with a convenient
[https:/documentation/articles/sculpt-24-10#Multi-monitor_support - user interface]
for controlling monitor modes, making brightness adjustments, and setting up
mirrored and panoramic monitor configurations.
Besides this main theme, version 24.10 benefits from the advancements of the
Genode OS Framework over the past six months: compatibility with Qt6,
drivers ported from the Linux kernel version 6.6.47, and comprehensive
[https:/documentation/release-notes/24.08#Goa_SDK - debugging support]
for the Goa SDK.
Sculpt OS 24.10 is available as ready-to-use system image for PC hardware,
the PinePhone, and the MNT Reform laptop at the
[https:/download/sculpt - Sculpt download page] accompanied
with updated [https:/documentation/articles/sculpt-24-10 - documentation].
Genode OS Framework release 24.08 | 2024-08-29 Genode OS Framework release 24.08 | 2024-08-29
############################################## ##############################################

View File

@@ -1 +1 @@
2024-08-28 8f1db0e604a283f5d3aafea61d38d6852ee91911 2024-10-07 19deb3e25765c65bef7ec4b7dd7c657b0c63a49d

View File

@@ -1 +1 @@
2024-08-28 deb70ebec813a19ba26a28cd94fa7d25bbe52e78 2024-10-07 a906ce16359b301dda1031906fc6c9b3dd386d52

View File

@@ -1 +1 @@
2024-08-28 a4ae12d703c38248ac22905163479000020e0bb0 2024-10-07 8f88c87b67888d3aedccf628ceb214ec7305b2eb

View File

@@ -1 +1 @@
2024-08-28 4c4d4d5d96bc345947e90c42559e45fec4dcc4c0 2024-10-07 f2d0f8e9e79f3c4a11498d1df055488910d87279

View File

@@ -1 +1 @@
2024-08-28 b0160be55c422f860753dbd375f04ff8f7ffc7e9 2024-10-07 af4a1a784fac28f321443a0659914f0aeb92e466

View File

@@ -1 +1 @@
2024-08-28 3e92e9cf1ec41d5de0bfa754ff48c63476e60d67 2024-10-07 184b4030fb20c203ab996d46ddc029a1d6856f9c

View File

@@ -400,6 +400,7 @@ struct Foc_vcpu : Thread, Noncopyable
if (state.fpu.charged()) { if (state.fpu.charged()) {
state.fpu.charge([&] (Vcpu_state::Fpu::State &fpu) { state.fpu.charge([&] (Vcpu_state::Fpu::State &fpu) {
asm volatile ("fxrstor %0" : : "m" (fpu) : "memory"); asm volatile ("fxrstor %0" : : "m" (fpu) : "memory");
return 512;
}); });
} else } else
asm volatile ("fxrstor %0" : : "m" (_fpu_vcpu) : "memory"); asm volatile ("fxrstor %0" : : "m" (_fpu_vcpu) : "memory");
@@ -412,6 +413,7 @@ struct Foc_vcpu : Thread, Noncopyable
state.fpu.charge([&] (Vcpu_state::Fpu::State &fpu) { state.fpu.charge([&] (Vcpu_state::Fpu::State &fpu) {
asm volatile ("fxsave %0" : "=m" (fpu) :: "memory"); asm volatile ("fxsave %0" : "=m" (fpu) :: "memory");
asm volatile ("fxsave %0" : "=m" (_fpu_vcpu) :: "memory"); asm volatile ("fxsave %0" : "=m" (_fpu_vcpu) :: "memory");
return 512;
}); });
asm volatile ("fxrstor %0" : : "m" (_fpu_ep) : "memory"); asm volatile ("fxrstor %0" : : "m" (_fpu_ep) : "memory");

View File

@@ -62,6 +62,8 @@ SRC_CC += capability.cc
SRC_CC += stack_area_addr.cc SRC_CC += stack_area_addr.cc
SRC_CC += heartbeat.cc SRC_CC += heartbeat.cc
CC_OPT_platform += -DBOARD_NAME="\"$(BOARD)\""
# provide Genode version information # provide Genode version information
include $(BASE_DIR)/src/core/version.inc include $(BASE_DIR)/src/core/version.inc

View File

@@ -1 +1 @@
2024-08-28 de31628804f8541b6c0cf5a43ed621432befd5cb 2024-10-29 4bbe6a0fc64e242b3df0a4f888c69592a35c2c59

View File

@@ -1 +1 @@
2024-08-28 63ddb73a6a576208b86313411ea0e9ba78d2fe60 2024-10-29 eb59e89aad9feb09d6a868c30f68e6295439f06a

View File

@@ -1 +1 @@
2024-08-28 73ea0cda27023fee8a56c5c104f85875e0ce2597 2024-10-29 499d391798850ba3b784250d3b8a63bbb0ac27ab

View File

@@ -1 +1 @@
2024-08-28 268365a21014538c4524a43c86f1e4b1b9709a96 2024-10-29 bc12b6bd4fc27e351d863c79752fcdc1173797ce

View File

@@ -73,7 +73,8 @@ class Genode::Multiboot2_info : Mmio<0x8>
Multiboot2_info(addr_t mbi) : Mmio({(char *)mbi, Mmio::SIZE}) { } Multiboot2_info(addr_t mbi) : Mmio({(char *)mbi, Mmio::SIZE}) { }
void for_each_tag(auto const &mem_fn, void for_each_tag(auto const &mem_fn,
auto const &acpi_fn, auto const &acpi_rsdp_v1_fn,
auto const &acpi_rsdp_v2_fn,
auto const &fb_fn, auto const &fb_fn,
auto const &systab64_fn) auto const &systab64_fn)
{ {
@@ -103,6 +104,7 @@ class Genode::Multiboot2_info : Mmio<0x8>
if (tag.read<Tag::Type>() == Tag::Type::ACPI_RSDP_V1 || if (tag.read<Tag::Type>() == Tag::Type::ACPI_RSDP_V1 ||
tag.read<Tag::Type>() == Tag::Type::ACPI_RSDP_V2) { tag.read<Tag::Type>() == Tag::Type::ACPI_RSDP_V2) {
size_t const sizeof_tag = 1UL << Tag::LOG2_SIZE; size_t const sizeof_tag = 1UL << Tag::LOG2_SIZE;
addr_t const rsdp_addr = tag_addr + sizeof_tag; addr_t const rsdp_addr = tag_addr + sizeof_tag;
@@ -113,10 +115,12 @@ class Genode::Multiboot2_info : Mmio<0x8>
Hw::Acpi_rsdp rsdp_v1; Hw::Acpi_rsdp rsdp_v1;
memset (&rsdp_v1, 0, sizeof(rsdp_v1)); memset (&rsdp_v1, 0, sizeof(rsdp_v1));
memcpy (&rsdp_v1, rsdp, 20); memcpy (&rsdp_v1, rsdp, 20);
acpi_fn(rsdp_v1); acpi_rsdp_v1_fn(rsdp_v1);
} else
if (sizeof(*rsdp) <= tag.read<Tag::Size>() - sizeof_tag) {
/* ACPI RSDP v2 */
acpi_rsdp_v2_fn(*rsdp);
} }
if (sizeof(*rsdp) <= tag.read<Tag::Size>() - sizeof_tag)
acpi_fn(*rsdp);
} }
if (tag.read<Tag::Type>() == Tag::Type::FRAMEBUFFER) { if (tag.read<Tag::Type>() == Tag::Type::FRAMEBUFFER) {

View File

@@ -61,7 +61,7 @@ static Hw::Acpi_rsdp search_rsdp(addr_t area, addr_t area_size)
} }
} }
Hw::Acpi_rsdp invalid; Hw::Acpi_rsdp invalid { };
return invalid; return invalid;
} }
@@ -143,10 +143,14 @@ Bootstrap::Platform::Board::Board()
lambda(base, size); lambda(base, size);
}, },
[&] (Hw::Acpi_rsdp const &rsdp) { [&] (Hw::Acpi_rsdp const &rsdp_v1) {
/* prefer higher acpi revisions */ /* only use ACPI RSDP v1 if nothing available/valid by now */
if (!acpi_rsdp.valid() || acpi_rsdp.revision < rsdp.revision) if (!acpi_rsdp.valid())
acpi_rsdp = rsdp; acpi_rsdp = rsdp_v1;
},
[&] (Hw::Acpi_rsdp const &rsdp_v2) {
/* prefer v2 ever, override stored previous rsdp v1 potentially */
acpi_rsdp = rsdp_v2;
}, },
[&] (Hw::Framebuffer const &fb) { [&] (Hw::Framebuffer const &fb) {
info.framebuffer = fb; info.framebuffer = fb;

View File

@@ -161,6 +161,9 @@ void Platform::_init_platform_info()
xml.attribute("acpi", true); xml.attribute("acpi", true);
xml.attribute("msi", true); xml.attribute("msi", true);
}); });
xml.node("board", [&] {
xml.attribute("name", BOARD_NAME);
});
_init_additional_platform_info(xml); _init_additional_platform_info(xml);
xml.node("affinity-space", [&] { xml.node("affinity-space", [&] {
xml.attribute("width", affinity_space().width()); xml.attribute("width", affinity_space().width());

View File

@@ -60,6 +60,7 @@ class Genode::Fpu_context
} }
addr_t fpu_context() const { return _fxsave_addr; } addr_t fpu_context() const { return _fxsave_addr; }
addr_t fpu_size() const { return sizeof(_fxsave_area); }
}; };
#endif /* _CORE__SPEC__X86_64__FPU_H_ */ #endif /* _CORE__SPEC__X86_64__FPU_H_ */

View File

@@ -222,7 +222,7 @@ void Board::Vcpu_context::read_vcpu_state(Vcpu_state &state)
if (state.fpu.charged()) { if (state.fpu.charged()) {
state.fpu.with_state( state.fpu.with_state(
[&](Vcpu_state::Fpu::State const &fpu) { [&](Vcpu_state::Fpu::State const &fpu) {
memcpy((void *) regs->fpu_context(), &fpu, sizeof(fpu)); memcpy((void *) regs->fpu_context(), &fpu, regs->fpu_size());
}); });
} }
} }
@@ -233,7 +233,8 @@ void Board::Vcpu_context::write_vcpu_state(Vcpu_state &state)
state.exit_reason = (unsigned) exit_reason; state.exit_reason = (unsigned) exit_reason;
state.fpu.charge([&](Vcpu_state::Fpu::State &fpu) { state.fpu.charge([&](Vcpu_state::Fpu::State &fpu) {
memcpy(&fpu, (void *) regs->fpu_context(), sizeof(fpu)); memcpy(&fpu, (void *) regs->fpu_context(), regs->fpu_size());
return regs->fpu_size();
}); });
/* SVM will overwrite rax but VMX doesn't. */ /* SVM will overwrite rax but VMX doesn't. */

View File

@@ -1 +1 @@
2024-08-28 cbea0285f523b6943841f460fb1dab4471cb72f5 2024-10-07 acb4a463ec1b2b6868f923900c2b04ee1a6487a8

View File

@@ -697,7 +697,7 @@ namespace Nova {
} gdtr, idtr; } gdtr, idtr;
unsigned long long tsc_val, tsc_off, tsc_aux; unsigned long long tsc_val, tsc_off, tsc_aux;
unsigned long long exit_reason; unsigned long long exit_reason;
uint8_t fpu[512]; uint8_t fpu[2560];
} __attribute__((packed)); } __attribute__((packed));
mword_t mr[(4096 - 4 * sizeof(mword_t)) / sizeof(mword_t)]; mword_t mr[(4096 - 4 * sizeof(mword_t)) / sizeof(mword_t)];
}; };

View File

@@ -1 +1 @@
e8997fb0870b6f8bdcb6da34a9b333ed4a304305 dd4d2aba9dd83ec08e956cb31274c62cbcaf91f6

View File

@@ -4,7 +4,7 @@ DOWNLOADS := nova.git
# r10 branch # r10 branch
URL(nova) := https://github.com/alex-ab/NOVA.git URL(nova) := https://github.com/alex-ab/NOVA.git
REV(nova) := bca1aa3553d8c5df4f4b6ed5a2ee72f69bdf7a7f REV(nova) := 60419b83599fbe506308b0375371c49136e00985
DIR(nova) := src/kernel/nova DIR(nova) := src/kernel/nova
PATCHES := $(sort $(wildcard $(REP_DIR)/patches/*.patch)) PATCHES := $(sort $(wildcard $(REP_DIR)/patches/*.patch))

View File

@@ -1 +1 @@
2024-08-28 80901e07dc386b2dcc259a85ea60fdd2bb4c1b6a 2024-10-07 d1a751a3b41d145c3a97b3431ae1f006050fee10

View File

@@ -1 +1 @@
2024-08-28 2bdb13a64a152f7cb2601222245eb6f132d5325b 2024-10-07 3fdd714b4cf479987b027a09aa2b470dfc46a92a

View File

@@ -177,7 +177,10 @@ void Nova_vcpu::_read_nova_state(Nova::Utcb &utcb)
if (utcb.mtd & Nova::Mtd::FPU) { if (utcb.mtd & Nova::Mtd::FPU) {
_vcpu_state.fpu.charge([&] (Vcpu_state::Fpu::State &fpu) { _vcpu_state.fpu.charge([&] (Vcpu_state::Fpu::State &fpu) {
memcpy(&fpu, utcb.fpu, sizeof(fpu)); auto const fpu_size = unsigned(min(_vcpu_state.fpu.size(),
sizeof(utcb.fpu)));
memcpy(&fpu, utcb.fpu, fpu_size);
return fpu_size;
}); });
} }

View File

@@ -297,27 +297,27 @@ void test_pat(Genode::Env &env)
Xml_node const hardware = platform_info.xml().sub_node("hardware"); Xml_node const hardware = platform_info.xml().sub_node("hardware");
uint64_t const tsc_freq = hardware.sub_node("tsc").attribute_value("freq_khz", 1ULL); uint64_t const tsc_freq = hardware.sub_node("tsc").attribute_value("freq_khz", 1ULL);
enum { DS_ORDER = 12, PAGE_4K = 12 }; enum { DS_ORDER = 12, PAGE_4K = 12, DS_SIZE = 1ul << (DS_ORDER + PAGE_4K) };
Attached_dataspace ds { env.rm(), env.ram().alloc (1 << (DS_ORDER + PAGE_4K),
WRITE_COMBINED) };
addr_t const map_addr = addr_t(ds.local_addr<void>());
enum { STACK_SIZE = 4096 };
static Rpc_entrypoint ep(&env.pd(), STACK_SIZE, "rpc_ep_pat",
Affinity::Location());
Genode::Rm_connection rm(env); Genode::Rm_connection rm(env);
Genode::Region_map_client rm_free_area(rm.create(1 << (DS_ORDER + PAGE_4K))); Genode::Region_map_client rm_unused(rm.create(DS_SIZE));
Attached_dataspace remap { env.rm(), rm_free_area.dataspace() }; Attached_dataspace ds_wc { env.rm(), env.ram().alloc (DS_SIZE, WRITE_COMBINED) };
Attached_dataspace ds { env.rm(), env.ram().alloc (DS_SIZE) };
Attached_dataspace remap { env.rm(), rm_unused.dataspace() };
addr_t const remap_addr = addr_t(remap.local_addr<void>()); auto const memory = addr_t(ds .local_addr<void>());
auto const memory_wc = addr_t(ds_wc.local_addr<void>());
auto const memory_remap = addr_t(remap.local_addr<void>());
static Rpc_entrypoint ep(&env.pd(), 4096 /* STACK */, "rpc_ep_pat",
Affinity::Location());
/* trigger mapping of whole area */ /* trigger mapping of whole area */
for (addr_t i = map_addr; i < map_addr + (1 << (DS_ORDER + PAGE_4K)); i += (1 << PAGE_4K)) for (auto offset = 0; offset < DS_SIZE; offset += (1u << PAGE_4K)) {
touch_read(reinterpret_cast<unsigned char *>(map_addr)); touch_read_write(reinterpret_cast<unsigned char *>(memory_wc + offset));
touch_read_write(reinterpret_cast<unsigned char *>( memory + offset));
}
/* /*
* Establish memory mapping with evilly wrong mapping attributes * Establish memory mapping with evilly wrong mapping attributes
@@ -331,8 +331,8 @@ void test_pat(Genode::Env &env)
native_pd.alloc_rpc_cap(thread_cap, (addr_t)portal_entry, 0 /* MTD */); native_pd.alloc_rpc_cap(thread_cap, (addr_t)portal_entry, 0 /* MTD */);
Nova::Rights const all(true, true, true); Nova::Rights const all(true, true, true);
Nova::Mem_crd const rcv_crd(remap_addr >> PAGE_4K, DS_ORDER, all); Nova::Mem_crd const rcv_crd(memory_remap >> PAGE_4K, DS_ORDER, all);
Nova::Mem_crd const snd_crd(map_addr >> PAGE_4K, DS_ORDER, all); Nova::Mem_crd const snd_crd(memory_wc >> PAGE_4K, DS_ORDER, all);
Nova::Crd const old_crd = utcb.crd_rcv; Nova::Crd const old_crd = utcb.crd_rcv;
utcb.crd_rcv = rcv_crd; utcb.crd_rcv = rcv_crd;
@@ -348,36 +348,45 @@ void test_pat(Genode::Env &env)
} }
/* sanity check - touch re-mapped area */ /* sanity check - touch re-mapped area */
for (addr_t i = remap_addr; i < remap_addr + (1 << (DS_ORDER + PAGE_4K)); i += (1 << PAGE_4K)) for (auto offset = 0; offset < DS_SIZE; offset += (1 << PAGE_4K))
touch_read(reinterpret_cast<unsigned char *>(remap_addr)); touch_read_write(reinterpret_cast<unsigned char *>(memory_remap + offset));
/* /*
* measure time to write to the memory * measure time to write to the memory
*/ */
memset(reinterpret_cast<void *>(map_addr), 0, 1 << (DS_ORDER + PAGE_4K)); memset(reinterpret_cast<void *>(memory), 0, DS_SIZE);
Trace::Timestamp normal_start = Trace::timestamp();
memset(reinterpret_cast<void *>(memory), 0, DS_SIZE);
Trace::Timestamp normal_end = Trace::timestamp();
memset(reinterpret_cast<void *>(memory_wc), 0, DS_SIZE);
Trace::Timestamp map_start = Trace::timestamp(); Trace::Timestamp map_start = Trace::timestamp();
memset(reinterpret_cast<void *>(map_addr), 0, 1 << (DS_ORDER + PAGE_4K)); memset(reinterpret_cast<void *>(memory_wc), 0, DS_SIZE);
Trace::Timestamp map_end = Trace::timestamp(); Trace::Timestamp map_end = Trace::timestamp();
memset(reinterpret_cast<void *>(remap_addr), 0, 1 << (DS_ORDER + PAGE_4K)); memset(reinterpret_cast<void *>(memory_remap), 0, DS_SIZE);
Trace::Timestamp remap_start = Trace::timestamp(); Trace::Timestamp remap_start = Trace::timestamp();
memset(reinterpret_cast<void *>(remap_addr), 0, 1 << (DS_ORDER + PAGE_4K)); memset(reinterpret_cast<void *>(memory_remap), 0, DS_SIZE);
Trace::Timestamp remap_end = Trace::timestamp(); Trace::Timestamp remap_end = Trace::timestamp();
Trace::Timestamp map_run = map_end - map_start; auto normal_run = normal_end - normal_start;
Trace::Timestamp remap_run = remap_end - remap_start; auto map_run = map_end - map_start;
auto remap_run = remap_end - remap_start;
Trace::Timestamp diff_run = map_run > remap_run ? map_run - remap_run : remap_run - map_run; auto diff_run = map_run > remap_run ? map_run - remap_run : remap_run - map_run;
if (check_pat && diff_run * 100 / tsc_freq) { log("memory non writecombined ", normal_run * 1000 / tsc_freq, " us");
log("memory writecombined ", map_run * 1000 / tsc_freq, " us");
log("memory writecombined remapped ", remap_run * 1000 / tsc_freq, " us");
log("variance writecombined tests ", diff_run * 1000 / tsc_freq, " us");
if (check_pat && diff_run * 10 / tsc_freq) {
failed ++; failed ++;
error("map=", Hex(map_run), " remap=", Hex(remap_run), " --> " error("PAT test considered failed - time difference above 100us");
"diff=", Hex(diff_run), " freq_tsc=", tsc_freq, " ",
diff_run * 1000 / tsc_freq, " us");
} }
Nova::revoke(Nova::Mem_crd(remap_addr >> PAGE_4K, DS_ORDER, all)); Nova::revoke(Nova::Mem_crd(memory_remap >> PAGE_4K, DS_ORDER, all));
} }
void test_server_oom(Genode::Env &env) void test_server_oom(Genode::Env &env)

View File

@@ -1 +1 @@
2024-08-28 4b22e47966d13c2de61a2d7349bd8fa83520fd1c 2024-10-07 0dfc585477f27e02dbe67acf3a23f48718c113f7

View File

@@ -1 +1 @@
2024-08-28 ef60eabef7b6a62cb0ca9844e76dcaa0d5fd9032 2024-10-07 4ec8eaa528d706f5b2a267f95443a48430a87a91

View File

@@ -1 +1 @@
2024-08-28 6a6ef31c10a65d90eaba97c45324b4e6835f14db 2024-10-07 b23d40bed9c8b9ed8fc8d8d1e2c5cac4e719580a

View File

@@ -1 +1 @@
2024-08-28 5656ef6d7282894b67b9aab50364f12f42aded49 2024-10-07 9929145b5c04edaf41b0f726743eabb2de9cc832

View File

@@ -54,12 +54,6 @@ class Genode::Attached_dataspace : Noncopyable
[&] (Region_map::Attach_error) { return nullptr; }); [&] (Region_map::Attach_error) { return nullptr; });
} }
/*
* Noncopyable
*/
Attached_dataspace(Attached_dataspace const &);
Attached_dataspace &operator = (Attached_dataspace const &);
public: public:
/** /**
@@ -118,6 +112,11 @@ class Genode::Attached_dataspace : Noncopyable
[&] (Region_map::Attach_error) { return 0UL; }); [&] (Region_map::Attach_error) { return 0UL; });
} }
/**
* Return byte range of locally mapped dataspace
*/
Byte_range_ptr bytes() const { return { _ptr<char>(), size() }; }
/** /**
* Forget dataspace, thereby skipping the detachment on destruction * Forget dataspace, thereby skipping the detachment on destruction
* *

View File

@@ -163,6 +163,11 @@ class Genode::Attached_ram_dataspace
_alloc_and_attach(); _alloc_and_attach();
} }
/**
* Return byte range of locally mapped dataspace
*/
Byte_range_ptr bytes() const { return { local_addr<char>(), size() }; }
}; };
#endif /* _INCLUDE__BASE__ATTACHED_RAM_DATASPACE_H_ */ #endif /* _INCLUDE__BASE__ATTACHED_RAM_DATASPACE_H_ */

View File

@@ -107,13 +107,14 @@ class Genode::Connection : public Connection_base
Client_id const &id, Client_id const &id,
Session_label const &label, Session_label const &label,
Ram_quota const &ram_quota, Ram_quota const &ram_quota,
Cap_quota const &cap_quota,
Affinity const &affinity, Affinity const &affinity,
Args const &args) Args const &args)
{ {
/* supplement session quotas and label as session arguments */ /* supplement session quotas and label as session arguments */
Args const complete_args("label=\"", label, "\", " Args const complete_args("label=\"", label, "\", "
"ram_quota=", ram_quota, ", " "ram_quota=", ram_quota, ", "
"cap_quota=", unsigned(SESSION_TYPE::CAP_QUOTA), ", ", "cap_quota=", cap_quota, ", ",
args); args);
if (complete_args.length() == Args::capacity()) if (complete_args.length() == Args::capacity())
@@ -138,12 +139,26 @@ class Genode::Connection : public Connection_base
Connection(Env &env, Connection(Env &env,
Session_label const &label, Session_label const &label,
Ram_quota const &ram_quota, Ram_quota const &ram_quota,
Cap_quota const &cap_quota,
Affinity const &affinity, Affinity const &affinity,
Args const &args) Args const &args)
: :
Connection_base(env), Connection_base(env),
_cap(_request(env, _id_space_element.id(), _cap(_request(env, _id_space_element.id(),
label, ram_quota, affinity, args)) label, ram_quota, cap_quota, affinity, args))
{ }
/**
* Constructor using the cap quota declared in as SESSION_TYPE::CAP_QUOTA
*/
Connection(Env &env,
Session_label const &label,
Ram_quota const &ram_quota,
Affinity const &affinity,
Args const &args)
:
Connection(env, label, ram_quota, Cap_quota { unsigned(SESSION_TYPE::CAP_QUOTA) },
affinity, args)
{ } { }
/** /**

View File

@@ -206,8 +206,8 @@ class Genode::Vcpu_state
struct State struct State
{ {
uint8_t _buffer[512] { }; uint8_t _buffer[2560] { };
} __attribute__((aligned(16))); } __attribute__((aligned(64)));
private: private:
@@ -215,6 +215,7 @@ class Genode::Vcpu_state
State _state { }; State _state { };
bool _charged { false }; bool _charged { false };
uint64_t _state_size { };
/* see comment for Register::operator=() */ /* see comment for Register::operator=() */
Fpu & operator = (Fpu const &) Fpu & operator = (Fpu const &)
@@ -233,11 +234,13 @@ class Genode::Vcpu_state
void charge(auto const &fn) void charge(auto const &fn)
{ {
_charged = true; _charged = true;
fn(_state); _state_size = fn(_state);
} }
auto size() const { return _state_size; }
}; };
Fpu fpu __attribute__((aligned(16))) { }; Fpu fpu __attribute__((aligned(64))) { };
/* /*
* Registers transfered by hypervisor from guest on VM exit are charged. * Registers transfered by hypervisor from guest on VM exit are charged.

View File

@@ -224,10 +224,26 @@ struct Genode::Rect
*/ */
Point center(Area const area) const Point center(Area const area) const
{ {
return Point((CT(w()) - CT(area.w))/2, return Point { .x = (CT(w()) - CT(area.w))/2,
(CT(h()) - CT(area.h))/2) + at; .y = (CT(h()) - CT(area.h))/2 } + at;
} }
Point clamp(Point const p) const
{
return Point { .x = max(x1(), min(x2(), p.x)),
.y = max(y1(), min(y2(), p.y)) };
}
/**
* Operator for testing non-equality of two rectangled
*/
bool operator != (Rect const &r) const { return r.at != at || r.area != area; }
/**
* Operator for testing equality of two rectangles
*/
bool operator == (Rect const &r) const { return r.at == at && r.area == area; }
/** /**
* Print rectangle coordinates * Print rectangle coordinates
* *

View File

@@ -84,6 +84,15 @@ struct Genode::Byte_range_ptr : Noncopyable
Byte_range_ptr(char *start, size_t num_bytes) Byte_range_ptr(char *start, size_t num_bytes)
: start(start), num_bytes(num_bytes) { } : start(start), num_bytes(num_bytes) { }
void with_skipped_bytes(size_t const n, auto const &fn)
{
if (num_bytes <= n)
return;
Byte_range_ptr const remainder { start + n, num_bytes - n };
fn(remainder);
}
}; };

View File

@@ -1 +1 @@
2024-08-28 952cb023f90e6d847b6bfc8da87d8f7ba24f842c 2024-10-07 513edfd85657a2cea7224093f02ad8f2525056f3

View File

@@ -1 +1 @@
2024-08-28 38800f3da875e5de6f2d561358fa8f56c85a7b3c 2024-10-29 123419fe0f679a41e6e836a82f46be56644d36af

View File

@@ -1 +1 @@
2024-08-28 1263204bd1a920d6ea1a414c0a7de506ab225d54 2024-10-29 4121baf09683470114b15c6768cb939b7b78de65

View File

@@ -1 +1 @@
2024-08-28 916b2b926332cfcd7960395cbae045c2f79e22e1 2024-10-29 964df1f1eebb297399d37ffc42cd5b717f81ac65

View File

@@ -1 +1 @@
2024-08-28 e9ad6072bfb3d9b3a33bc1bc0d8d569e572a23aa 2024-10-29 8acfdc522214ab48f3ba2662deca84562aedb62f

View File

@@ -1 +1 @@
2024-08-28 eb64887a9855af98fd59ca684d76a117ad6bc218 2024-10-29 511875353e93f226ff52c3a79be5e6847fa95c19

View File

@@ -1 +1 @@
2024-08-28 2d87a4f1e768e5156bb2122e76aefe9b93250b98 2024-10-29 4eb04b36a4589581afe4b8e5c09cd1a8202e389e

View File

@@ -1 +1 @@
2024-08-28 9999549086b013d745b7c29d0d73ce16a7b44460 2024-10-29 ec0ee7597f35852ed2a1f0a3250ebc9de125141d

View File

@@ -1 +1 @@
2024-08-28 eb836fa23731d48906eb17a55f4493a1f1d5f31e 2024-10-29 2093c0cd6b5e73f07e682f8448abdf4bcc07ba90

View File

@@ -1 +1 @@
2024-08-28 b338f91749569157a0ee70bdac8b63b4604a10f1 2024-10-29 ea454149147f8535060bf076432dd67d473658dd

View File

@@ -1 +1 @@
2024-08-28 0c740d62b29e444a70f19786e73e919929b8a41b 2024-10-29 dde16843a89b11f0c76e73ab66906ccc68d65a0c

View File

@@ -1 +1 @@
2024-08-28 dcf9171eaf3917bc7dab03d2821105a25a8d9526 2024-10-29 0816774e285a09f371e1c7b11c661aeb9925e4dc

View File

@@ -1 +1 @@
2024-08-28 20da1561fd882dbd113366082471d95b8533e310 2024-10-29 1d173f7880db1f1252ab54cea4d8e6ba8e7ea77c

View File

@@ -1 +1 @@
2024-08-28 2179cbeaf81dd04431742572f2f685473cd84594 2024-10-29 50994e52f5f229a19d33169d3ae3aa1e1b06a83a

View File

@@ -1 +1 @@
2024-08-28 e9f6ccbe39344ae7f6a9e5787397d352383d50e9 2024-10-29 54f3e743c82cc972eebb16023de863fa5e539812

View File

@@ -1 +1 @@
2024-08-28 9a01b6b2d0d295435aa0a02ebc7348a285eeca8d 2024-10-29 5fde64bdb410c3b1d31e97f0d21cf3d064bbc2ce

View File

@@ -1 +1 @@
2024-08-28 ae27770a9af453d0c385aa2eedf3aeea9d017223 2024-10-29 f5a700f137cf815f7ce15b3fa9f5634b7828425e

View File

@@ -1 +1 @@
2024-08-28 ebeb7886af2d31d276ab768af6bd8f3220de8953 2024-10-29 d326468bba3e8af5f49179103fb74567410c016b

View File

@@ -1 +1 @@
2024-08-28 0f803f76ccc130569e39451c51626feec05a712b 2024-10-29 f5aa7c4c7928b4aa750133798ab5ced2862627ef

View File

@@ -1 +1 @@
2024-08-28 1fbbbbe8badb32ea8ec9b07cee8f8a5d95360acb 2024-10-29 0c302928b9f742d2dca1a7a7392217afc7d99518

View File

@@ -1 +1 @@
2024-08-28 b48cf2518250d49a57109e7038d837ab02b94d56 2024-10-29 778c0e244d381f663a04913e3fd490c9029454e7

View File

@@ -1 +1 @@
2024-08-28 27a6c8bd9c14310c772eceaa6ce8545fad4161a0 2024-10-07 a6a04c7c48e562c4450603757520e447af6ba3b7

View File

@@ -1 +1 @@
2024-08-28 81579f87117d620bded1b18b94d32f8dfcf798c0 2024-10-07 c65f3e117d0576e35c93be32795ae44e40905806

View File

@@ -1 +1 @@
2024-08-28 353ca16a476ea875269280a482133917404af2b4 2024-10-07 fd12392cdb6e8a73927eddb831b5a4a03f1dba99

View File

@@ -1 +1 @@
2024-08-28 5a105d705f54f092f8a5830a0ae6735ae9a4787a 2024-10-07 2d27a4ea191a544959688dddebc99c0158a2cc87

View File

@@ -1 +1 @@
2024-08-28 1e93c3437d41e6177b8063f48aad15f5ca340956 2024-10-07 a2f19169350426a2c92bfa82cd57ea1126ff40f9

View File

@@ -1 +1 @@
2024-08-28 215be20a911ed192b38c93319396f6a5b3f7cb6d 2024-10-07 fdd7695261277dcba03643f98bb2804c30c0cf04

View File

@@ -1 +1 @@
2024-08-28 a27dcf2ba32e600ce9b02a18222d8286d9220b6e 2024-10-07 45ffa221854a16794e7325d8ed6d6b5ce90635a5

View File

@@ -1 +1 @@
2024-08-28 34c983d620520d362a146f6c9f062885b2d98c38 2024-10-07 96b39a93b70d6732cd2f6a7e30ac3404f4f017d5

View File

@@ -1 +1 @@
2024-08-28 78709e0ea496651d938423d0bb18a0254a04acaf 2024-10-07 9843a171d4e781aec5597ce0b48ccc17431918d7

View File

@@ -1 +1 @@
2024-08-28 59c0abed548b66f8d54c74e82f1ab0ab7f0d0ee6 2024-10-07 b3d5f7577d058fd7d3a34846af555ba2ffec842b

View File

@@ -1 +1 @@
2024-08-28 3ea09d83887d1fc0e07409e68d52c99f794846f9 2024-10-07 40512d1349569b95538ce6c61613c295cf7f9487

View File

@@ -1 +1 @@
2024-08-28 e4c5cc271035fd20416eca2b23005800bdbe22d5 2024-10-07 4725441ba5bbe72651a38e5e13ac2ed3bda4af37

View File

@@ -1 +1 @@
2024-08-28 d30834f3bb7de0b8450835323179e126c057206d 2024-10-07 5c9f35640dd353fe429cac6d93c022a99a609fb5

View File

@@ -1 +1 @@
2024-08-28 6106585c8708899bc2b5580583ae3d80a873a4bb 2024-10-07 635ede2b3116c2dd4817b120ba9c346f72032fae

View File

@@ -1 +1 @@
2024-08-28 548d48fdd30db99f612a172dbb6733b9705de758 2024-10-07 a1eb033228bdbe39301dd2fae6502870c3162b26

View File

@@ -1 +1 @@
2024-08-28 e9bcac3043d0ec5b0f99cf70c79c6a4602d7b381 2024-10-07 f4fc22ec46e47ed91c121beb24657d911f6b7411

View File

@@ -1 +1 @@
2024-08-28 54a1cf1254fb7f5a3e21f19a4e93aaf48244e727 2024-10-07 83118776eba8117187854ababa680cb1fe4b2b77

View File

@@ -1 +1 @@
2024-08-28 a39e757b6833857b4ec32f2060305079d6cc068f 2024-10-07 b1c7aacfa16f9ecbd103e3df98a0a2bb36bae272

View File

@@ -1 +1 @@
2024-08-28 8fded3cec4f36bfe77abbed9060c577906c8f643 2024-10-07 472cfb4a2918d0ecb9251eba8cd3b624275a94ab

View File

@@ -1 +1 @@
2024-08-28 636f2fe518818087444a67b7fea94c7daf5dd5af 2024-10-07 17a0ac2f692ff963d89fab0ae111606a837bcaaf

View File

@@ -1 +1 @@
b6086e021be26a2f2a07463c0318b79fd8d0513e 931ffc4e67642ff7c5e639d8ca7b6f5bc345c803

View File

@@ -3,13 +3,12 @@ VERSION := individual (see sources)
DOWNLOADS := audio.archive DOWNLOADS := audio.archive
# #
# Audio drivers from OpenBSD 7.3 # Audio drivers from OpenBSD
# #
SRC_DIR_AUDIO := src/lib/audio SRC_DIR_AUDIO := src/lib/audio
VERSION(audio) := 7.3 VERSION(audio) := 8571a5a
BASE_URL := https://cdn.openbsd.org/pub/OpenBSD URL(audio) := https://distfiles.sysret.de/Genode/dde_bsd-8571a5a.tar.xz
URL(audio) := $(BASE_URL)/${VERSION(audio)}/sys.tar.gz SHA(audio) := 4a0de8a026d3a844022135c25bab5aabfd5f77146aaedaa6d7253b2cc110efca
SHA(audio) := bb0dfa11584d68464b3f788e43655f6454bb3ecba8ad5500377630bcf23570ec
DIR(audio) := $(SRC_DIR_AUDIO) DIR(audio) := $(SRC_DIR_AUDIO)
TAR_OPT(audio) := --strip-components=1 --files-from $(REP_DIR)/audio.list TAR_OPT(audio) := --strip-components=1 --files-from $(REP_DIR)/audio.list
HASH_INPUT += $(REP_DIR)/audio.list HASH_INPUT += $(REP_DIR)/audio.list

View File

@@ -1 +1 @@
2024-08-28 d9b3b6700616965b61c9cf673d1d2924d795437b 2024-10-07 49864c449ff2a8f7de7d54b6231c62ff4ad75dcd

View File

@@ -1,6 +1,6 @@
<runtime ram="2M" caps="105" binary="pci_audio"> <runtime ram="2M" caps="105" binary="pci_audio">
<requires> <platform/> <rm/> <timer/> </requires> <requires> <platform/> <timer/> </requires>
<provides> <provides>
<audio_out/> <audio_out/>

View File

@@ -1 +1 @@
2024-08-28 efd2b77afecdc8673da69eaa69f4e8baf3d03950 2024-10-07 9c7c095fe94c898d473c97596e50a29d1cfaa088

View File

@@ -14,14 +14,18 @@ if {[have_spec linux]} {
proc use_record_play_sessions { } { return 1 } proc use_record_play_sessions { } { return 1 }
create_boot_directory create_boot_directory
import_from_depot [depot_user]/src/[base_src] \
[depot_user]/src/acpi \
[depot_user]/src/bsd_audio \
[depot_user]/src/init \
[depot_user]/src/pci_decode \
[depot_user]/src/platform \
[depot_user]/src/report_rom
proc build_targets { } { proc build_targets { } {
set targets { set targets { driver/audio/pci }
core init timer
driver/acpi driver/platform app/pci_decode server/report_rom
driver/audio
}
if {[use_record_play_sessions]} { if {[use_record_play_sessions]} {
lappend targets server/record_play_mixer app/waveform_player \ lappend targets server/record_play_mixer app/waveform_player \
@@ -48,7 +52,7 @@ proc record_play_start_nodes { } {
return "" } return "" }
return { return {
<start name="mixer"> <start name="mixer" priority="-1">
<resource name="RAM" quantum="2M"/> <resource name="RAM" quantum="2M"/>
<resource name="CPU" quantum="20"/> <resource name="CPU" quantum="20"/>
<binary name="record_play_mixer"/> <binary name="record_play_mixer"/>
@@ -58,12 +62,12 @@ proc record_play_start_nodes { } {
<mix name="left"> <play label_suffix="left" /> </mix> <mix name="left"> <play label_suffix="left" /> </mix>
<mix name="right"> <play label_suffix="right"/> </mix> <mix name="right"> <play label_suffix="right"/> </mix>
<policy label_suffix="left" record="left" volume="1.0"/> <policy label_suffix="left" record="left" period_ms="12" jitter_ms="5" volume="1.0"/>
<policy label_suffix="right" record="right" volume="1.0"/> <policy label_suffix="right" record="right" period_ms="12" jitter_ms="5" volume="1.0"/>
</config> </config>
</start> </start>
<start name="test-audio_play"> <start name="test-audio_play" priority="-2">
<resource name="RAM" quantum="40M"/> <resource name="RAM" quantum="40M"/>
<config sample_path="sample.f32"> <config sample_path="sample.f32">
<vfs> <rom name="sample.f32"/> </vfs> <vfs> <rom name="sample.f32"/> </vfs>
@@ -94,7 +98,7 @@ proc audio_in_out_start_nodes { } {
} }
install_config { install_config {
<config verbose="yes"> <config verbose="yes" prio_levels="4">
<parent-provides> <parent-provides>
<service name="ROM"/> <service name="ROM"/>
<service name="IRQ"/> <service name="IRQ"/>
@@ -108,7 +112,7 @@ install_config {
<any-service> <parent/> <any-child/> </any-service> <any-service> <parent/> <any-child/> </any-service>
</default-route> </default-route>
<default caps="100"/> <default caps="100"/>
<start name="timer"> <start name="timer" priority="0">
<resource name="RAM" quantum="1M"/> <resource name="RAM" quantum="1M"/>
<provides><service name="Timer"/></provides> <provides><service name="Timer"/></provides>
</start> </start>
@@ -122,15 +126,15 @@ install_config {
</config> </config>
</start> </start>
<start name="acpi" caps="350"> <start name="acpi" caps="350" priority="-1">
<resource name="RAM" quantum="4M"/> <resource name="RAM" quantum="8M"/>
<route> <route>
<service name="Report"> <child name="report_rom"/> </service> <service name="Report"> <child name="report_rom"/> </service>
<any-service> <parent/> </any-service> <any-service> <parent/> </any-service>
</route> </route>
</start> </start>
<start name="pci_decode" caps="350"> <start name="pci_decode" caps="350" priority="-1">
<resource name="RAM" quantum="2M"/> <resource name="RAM" quantum="2M"/>
<route> <route>
<service name="Report"> <child name="report_rom"/> </service> <service name="Report"> <child name="report_rom"/> </service>
@@ -139,7 +143,7 @@ install_config {
</route> </route>
</start> </start>
<start name="platform" caps="100" managing_system="yes"> <start name="platform" caps="100" managing_system="yes" priority="-1">
<resource name="RAM" quantum="1M"/> <resource name="RAM" quantum="1M"/>
<provides> <provides>
<service name="Platform"/> <service name="Platform"/>
@@ -154,7 +158,7 @@ install_config {
</config> </config>
</start> </start>
<start name="audio"> <start name="audio" caps="150" priority="-1">
<binary name="pci_audio"/> <binary name="pci_audio"/>
<resource name="RAM" quantum="2M"/> <resource name="RAM" quantum="2M"/>
<provides> <service name="Audio_out"/> <service name="Audio_in"/> </provides> <provides> <service name="Audio_out"/> <service name="Audio_in"/> </provides>

View File

@@ -1 +1 @@
2024-08-28 7f3df4651694eb8b127d3dc0aabf16341b4cbf75 2024-10-07 ebc62d24f7c3bae4d285d96732c5c76a9d06da73

View File

@@ -1 +1 @@
2024-08-28 d0fdf4e7f4928d752541494d82dc0eb14adabed1 2024-10-07 11b76ee4b6ed52235d29283e1d8f377c65e71630

View File

@@ -14,33 +14,90 @@
#ifndef _WIFI__CTRL_H_ #ifndef _WIFI__CTRL_H_
#define _WIFI__CTRL_H_ #define _WIFI__CTRL_H_
#ifdef __cplusplus #include <util/string.h>
extern "C" {
#endif /* __cplusplus */
#define WPA_CTRL_FD 51 namespace Wifi {
struct Msg_buffer /*
* FD used to poll CTRL state from the supplicant.
*/
enum { CTRL_FD = 51, };
struct Msg_buffer;
struct Notify_interface : Genode::Interface
{
virtual void submit_response() = 0;
virtual void submit_event() = 0;
virtual void block_for_processing() = 0;
};
void ctrl_init(Msg_buffer &);
} /* namespace Wifi */
struct Wifi::Msg_buffer
{ {
unsigned char recv[4096*8]; char send[4096];
unsigned char send[4096];
unsigned recv_id;
unsigned send_id; unsigned send_id;
unsigned char event[1024];
char recv[4096*8];
unsigned recv_id;
unsigned last_recv_id;
char event[1024];
unsigned event_id; unsigned event_id;
} __attribute__((packed)); unsigned last_event_id;
Notify_interface &_notify;
Msg_buffer(Notify_interface &notify)
: _notify { notify } { }
/*
* Member functions below are called by the
* CTRL interface.
*/
void notify_response() const {
_notify.submit_response(); }
void notify_event() const {
_notify.submit_event(); }
void block_for_processing() {
_notify.block_for_processing(); }
/*
* Member functions below are called by the
* Manager.
*/
void with_new_reply(auto const &fn)
{
char const *msg = reinterpret_cast<char const*>(recv);
/* return early */
if (last_recv_id == recv_id)
return;
last_recv_id = recv_id;
fn(msg);
}
void with_new_event(auto const &fn)
{
char const *msg = reinterpret_cast<char const*>(event);
if (last_event_id == event_id)
return;
last_event_id = event_id;
fn(msg);
}
};
void wpa_ctrl_set_fd(void); void wpa_ctrl_set_fd(void);
void *wifi_get_buffer(void);
void wifi_notify_cmd_result(void);
void wifi_block_for_processing(void);
void wifi_notify_event(void);
#ifdef __cplusplus
}
#endif /* __cplusplus */
#endif /* _WIFI__CTRL_H_ */ #endif /* _WIFI__CTRL_H_ */

View File

@@ -36,12 +36,20 @@ namespace Wifi {
bool rfkill_blocked(); bool rfkill_blocked();
/** /**
* Set RFKILL state from the frontend * Set RFKILL state from the manager
* *
* May be only called from an EP context. * May be only called from an EP context.
*/ */
void set_rfkill(bool); void set_rfkill(bool);
/**
* Trigger RFKILL notification signal
*
* Used by the supplicants RFKILL driver to notify
* the management-layer.
*/
void rfkill_notify();
} /* namespace Wifi */ } /* namespace Wifi */
#endif /* _WIFI__RFKILL_H_ */ #endif /* _WIFI__RFKILL_H_ */

View File

@@ -10,7 +10,8 @@ CC_OPT += -Wno-unused-function
CC_CXX_OPT += -fpermissive CC_CXX_OPT += -fpermissive
SRC_C += main.c ctrl_iface_genode.c SRC_C += main.c
SRC_CC += ctrl_iface_genode.cc
INC_DIR += $(REP_DIR)/include INC_DIR += $(REP_DIR)/include
@@ -31,6 +32,7 @@ SRC_C_wpa_supplicant = bssid_ignore.c \
scan.c \ scan.c \
sme.c \ sme.c \
wmm_ac.c \ wmm_ac.c \
wnm_sta.c \
wpa_supplicant.c \ wpa_supplicant.c \
wpas_glue.c wpas_glue.c
# #
@@ -45,7 +47,7 @@ CC_OPT += -DCONFIG_BACKEND_FILE -DCONFIG_NO_CONFIG_WRITE \
-DCONFIG_SME -DCONFIG_CTRL_IFACE \ -DCONFIG_SME -DCONFIG_CTRL_IFACE \
-DCONFIG_BGSCAN -DCONFIG_BGSCAN_SIMPLE \ -DCONFIG_BGSCAN -DCONFIG_BGSCAN_SIMPLE \
-DCONFIG_OPENSSL_CMAC -DCONFIG_SHA256 \ -DCONFIG_OPENSSL_CMAC -DCONFIG_SHA256 \
-DCONFIG_SAE -DCONFIG_ECC -DCONFIG_SAE -DCONFIG_ECC -DCONFIG_WNM
CC_OPT += -DTLS_DEFAULT_CIPHERS=\"DEFAULT:!EXP:!LOW\" CC_OPT += -DTLS_DEFAULT_CIPHERS=\"DEFAULT:!EXP:!LOW\"
@@ -53,7 +55,7 @@ INC_DIR += $(WS_CONTRIB_DIR)/src/
# common # common
SRC_C_common = ieee802_11_common.c wpa_common.c hw_features_common.c \ SRC_C_common = ieee802_11_common.c wpa_common.c hw_features_common.c \
ctrl_iface_common.c sae.c dragonfly.c ctrl_iface_common.c sae.c dragonfly.c ptksa_cache.c
SRC_C += $(addprefix src/common/, $(SRC_C_common)) SRC_C += $(addprefix src/common/, $(SRC_C_common))
INC_DIR += $(WS_CONTRIB_DIR)/src/common INC_DIR += $(WS_CONTRIB_DIR)/src/common

View File

@@ -22,5 +22,7 @@ wifi_ifname T
_ZN4Wifi20firmware_get_requestEv T _ZN4Wifi20firmware_get_requestEv T
_ZN4Wifi26firmware_establish_handlerERNS_24Firmware_request_handlerE T _ZN4Wifi26firmware_establish_handlerERNS_24Firmware_request_handlerE T
_ZN4Wifi10set_rfkillEb T _ZN4Wifi10set_rfkillEb T
_ZN4Wifi13rfkill_notifyEv T
_ZN4Wifi14rfkill_blockedEv T _ZN4Wifi14rfkill_blockedEv T
_ZN4Wifi24rfkill_establish_handlerERNS_27Rfkill_notification_handlerE T _ZN4Wifi24rfkill_establish_handlerERNS_27Rfkill_notification_handlerE T
convert_errno_from_linux T

View File

@@ -0,0 +1,15 @@
Disable IRQ coalescing as it seems to not work properly in our
port because at some point triggering interrupts stops altogether.
In this case the netperf tests produce around 0.1(!) MBit/s of
throughput.
--- src/linux/drivers/net/ethernet/realtek/r8169_main.c
+++ src/linux/drivers/net/ethernet/realtek/r8169_main.c
@@ -5374,7 +5374,7 @@
dev->hw_features |= NETIF_F_RXALL;
dev->hw_features |= NETIF_F_RXFCS;
- netdev_sw_irq_coalesce_default_on(dev);
+ // netdev_sw_irq_coalesce_default_on(dev);
/* configure chip for default features */
rtl8169_set_features(dev, dev->features);

View File

@@ -1,8 +1,38 @@
diff --git a/src/drivers/driver_nl80211.c b/src/drivers/driver_nl80211.c The nl80211 driver patch contains the following changes:
index aec179a..6c07c73 100644
- Convert inline error values from Linux to libc (FreeBSD) as otherwise
wpa_supplicant might come to the wrong conclusions.
- Show RFKILL operations at INFO level (so that the always appear in the
log) and generate a interface dis-/enable event that will be handled
by the management layer.
- Remove netlink messages that rely on newer libnl versions, e.g. signed
value where introduced in 3.2.27.
- Hardcode the I/O control socket rather than calling socket because it
is not used anyway (see wpa_driver_nl80211/ioctl.cc).
--- a/src/drivers/driver_nl80211.c --- a/src/drivers/driver_nl80211.c
+++ b/src/drivers/driver_nl80211.c +++ a/src/drivers/driver_nl80211.c
@@ -1985,13 +1985,13 @@ static void wpa_driver_nl80211_rfkill_blocked(void *ctx) @@ -487,6 +487,8 @@
}
+extern int convert_errno_from_linux(int linux_errno);
+
int send_and_recv(struct nl80211_global *global,
struct nl_sock *nl_handle, struct nl_msg *msg,
int (*valid_handler)(struct nl_msg *, void *),
@@ -579,7 +581,7 @@
/* Always clear the message as it can potentially contain keys */
nl80211_nlmsg_clear(msg);
nlmsg_free(msg);
- return err.err;
+ return convert_errno_from_linux(err.err);
}
@@ -2088,13 +2090,13 @@
{ {
struct wpa_driver_nl80211_data *drv = ctx; struct wpa_driver_nl80211_data *drv = ctx;
@@ -18,7 +48,7 @@ index aec179a..6c07c73 100644
wpa_supplicant_event(drv->ctx, EVENT_INTERFACE_DISABLED, NULL); wpa_supplicant_event(drv->ctx, EVENT_INTERFACE_DISABLED, NULL);
} }
@@ -1999,7 +1999,7 @@ static void wpa_driver_nl80211_rfkill_blocked(void *ctx) @@ -2102,7 +2104,7 @@
static void wpa_driver_nl80211_rfkill_unblocked(void *ctx) static void wpa_driver_nl80211_rfkill_unblocked(void *ctx)
{ {
struct wpa_driver_nl80211_data *drv = ctx; struct wpa_driver_nl80211_data *drv = ctx;
@@ -27,7 +57,7 @@ index aec179a..6c07c73 100644
if (i802_set_iface_flags(drv->first_bss, 1)) { if (i802_set_iface_flags(drv->first_bss, 1)) {
wpa_printf(MSG_DEBUG, "nl80211: Could not set interface UP " wpa_printf(MSG_DEBUG, "nl80211: Could not set interface UP "
"after rfkill unblock"); "after rfkill unblock");
@@ -2013,7 +2013,7 @@ static void wpa_driver_nl80211_rfkill_unblocked(void *ctx) @@ -2116,7 +2118,7 @@
* rtnetlink ifup handler will report interfaces other than the P2P * rtnetlink ifup handler will report interfaces other than the P2P
* Device interface as enabled. * Device interface as enabled.
*/ */
@@ -36,12 +66,34 @@ index aec179a..6c07c73 100644
wpa_supplicant_event(drv->ctx, EVENT_INTERFACE_ENABLED, NULL); wpa_supplicant_event(drv->ctx, EVENT_INTERFACE_ENABLED, NULL);
} }
@@ -8709,7 +8709,7 @@ static void * nl80211_global_init(void *ctx) @@ -7826,7 +7828,7 @@
[NL80211_STA_INFO_BEACON_SIGNAL_AVG] = { .type = NLA_U8},
[NL80211_STA_INFO_RX_DURATION] = { .type = NLA_U64 },
[NL80211_STA_INFO_ACK_SIGNAL] = { .type = NLA_U8 },
- [NL80211_STA_INFO_ACK_SIGNAL_AVG] = { .type = NLA_S8 },
+ [NL80211_STA_INFO_ACK_SIGNAL_AVG] = { .type = NLA_U8 },
[NL80211_STA_INFO_RX_MPDUS] = { .type = NLA_U32 },
[NL80211_STA_INFO_FCS_ERROR_COUNT] = { .type = NLA_U32 },
[NL80211_STA_INFO_TX_DURATION] = { .type = NLA_U64 },
@@ -7930,9 +7932,9 @@
nla_get_u8(stats[NL80211_STA_INFO_ACK_SIGNAL]);
data->flags |= STA_DRV_DATA_LAST_ACK_RSSI;
}
- if (stats[NL80211_STA_INFO_ACK_SIGNAL_AVG])
- data->avg_ack_signal =
- nla_get_s8(stats[NL80211_STA_INFO_ACK_SIGNAL_AVG]);
+ // if (stats[NL80211_STA_INFO_ACK_SIGNAL_AVG])
+ // data->avg_ack_signal =
+ // nla_get_s8(stats[NL80211_STA_INFO_ACK_SIGNAL_AVG]);
if (stats[NL80211_STA_INFO_RX_MPDUS])
data->rx_mpdus = nla_get_u32(stats[NL80211_STA_INFO_RX_MPDUS]);
if (stats[NL80211_STA_INFO_FCS_ERROR_COUNT])
@@ -9939,7 +9941,7 @@
if (wpa_driver_nl80211_init_nl_global(global) < 0) if (wpa_driver_nl80211_init_nl_global(global) < 0)
goto err; goto err;
- global->ioctl_sock = socket(PF_INET, SOCK_DGRAM, 0); - global->ioctl_sock = socket(PF_INET, SOCK_DGRAM, 0);
+ global->ioctl_sock = 42; + global->ioctl_sock = 12345; /* arbitrarily chosen number b/c it won't be used anyway */
if (global->ioctl_sock < 0) { if (global->ioctl_sock < 0) {
wpa_printf(MSG_ERROR, "nl80211: socket(PF_INET,SOCK_DGRAM) failed: %s", wpa_printf(MSG_ERROR, "nl80211: socket(PF_INET,SOCK_DGRAM) failed: %s",
strerror(errno)); strerror(errno));

View File

@@ -1 +1 @@
5fff60c84cc929423efe4d572ab9624da974ea25 5727b3009cb951578cd5478b6c3d2bf14c7236ea

View File

@@ -1,8 +1,8 @@
LICENSE := mixed (binary) LICENSE := mixed (binary)
VERSION := 896ed3fb7ebd785adc2c232ce1e7008e38f795dc VERSION := 6726071dc75e85fcf70558073a23faec3e976a08
DOWNLOADS := fw.archive DOWNLOADS := fw.archive
FW_REV := $(VERSION) FW_REV := $(VERSION)
URL(fw) := https://github.com/cnuke/dde_linux_firmware/archive/$(FW_REV).tar.gz URL(fw) := https://github.com/cnuke/dde_linux_firmware/archive/$(FW_REV).tar.gz
SHA(fw) := 0120f27ebf7950671bc27dc0a2142da41784a9a5522eeed8ee54508c3f4e1994 SHA(fw) := ed58a34df08fe962f97e827b3b89861963589b6d8c077d96da2209f1fb1981c6
DIR(fw) := firmware DIR(fw) := firmware

View File

@@ -1 +1 @@
403e8fecb5e0303605e2c7b913089710e66ad3d6 501de7d0dc5363c9f271c2cd853b963b2a881438

View File

@@ -18,6 +18,7 @@ PATCH_FILES := i915_irq.patch \
usb_net_cdc_ncm.patch \ usb_net_cdc_ncm.patch \
usb_net_pinephone.patch \ usb_net_pinephone.patch \
usb_net_smsc95xx.patch \ usb_net_smsc95xx.patch \
workqueue_deadlock.patch workqueue_deadlock.patch \
r8169_disable_irq_coalescing.patch
PATCHES += $(addprefix patches/,$(PATCH_FILES)) PATCHES += $(addprefix patches/,$(PATCH_FILES))

View File

@@ -1 +1 @@
6242912dd6f6c22550a7fe0b443bfd80c5cfedae 15974e67af9112d919f1625a5c2ed2d996cdbdfb

View File

@@ -1,12 +1,12 @@
LICENSE := BSD-3-Clause LICENSE := BSD-3-Clause
VERSION := 2.10 VERSION := 2.11
DOWNLOADS := wpa_supplicant.archive DOWNLOADS := wpa_supplicant.archive
# #
# wpa_supplicant sources # wpa_supplicant sources
# #
URL(wpa_supplicant) := https://w1.fi/releases/wpa_supplicant-2.10.tar.gz URL(wpa_supplicant) := https://w1.fi/releases/wpa_supplicant-2.11.tar.gz
SHA(wpa_supplicant) := 20df7ae5154b3830355f8ab4269123a87affdea59fe74fe9292a91d0d7e17b2f SHA(wpa_supplicant) := 912ea06f74e30a8e36fbb68064d6cdff218d8d591db0fc5d75dee6c81ac7fc0a
DIR(wpa_supplicant) := src/app/wpa_supplicant DIR(wpa_supplicant) := src/app/wpa_supplicant
# #

View File

@@ -1 +1 @@
2024-08-28 203107a559eaf5f4d23126894356dab42c76384a 2024-10-29 a0f80d05ac5f5d87e619cd2041ef4fab8f2c906f

View File

@@ -1 +1 @@
2024-08-28 461a4a470e6385e77585a1ed7b2d1c0f6a280275 2024-10-29 29712abb79c1d33c6cfff831b0a41de51c1f0479

View File

@@ -1 +1 @@
2024-08-28 1eca1b3baa82ba8cc89c6f0e34de3e0659ce2c13 2024-10-29 a0864eb06b2b8f868a024feda080ec1be04ad1b8

Some files were not shown because too many files have changed in this diff Show More