summaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2025-09-01libpager, ext2fs: add bulk page write supportHEADmasterMilos Nikic
Introduce a new pager_write_pages() entry point, allowing filesystems to implement multi-page writes in one call. libpager will attempt to coalesce contiguous dirty pages and call this bulk interface; if it is unsupported or only partially completes, the remaining pages are handled by the existing per-page path. ext2fs now provides file_pager_write_pages(), implemented using a small chunked write loop (currently 2 blocks per chunk) under alloc_lock. This reduces lock/unlock cycles, improves batching of store_write() calls, and avoids starvation by yielding between chunks. Other filesystems may continue using pager_write_page() unchanged. Test write 128 MiB dirty file: Before this change: store_write calls: 32,874; avg: 4,096 B After this change (coalesced runs, cap=128): store_write calls: 1,300; avg 103 KiB (~25 times fewer calls, ~25 times larger writes)
2025-08-31rumpdisk: Set USER_DEVICE ktype on device portsMichael Kelly
so that IPC messages destined for rumpdisk will use page lists rather than page map entries, to make them safe against swapping out.
2025-08-29streamio: Handle device_read_reply_inband getting D_WOULD_BLOCKYelninei
We do not want to consider this a real error, and not an EOF either.
2025-08-23Do not fail if std{in,out,err} exist in MAKEDEV (Closes: #1108605)Stéphane Glondu
2025-08-23libstore: use 512-byte blocks if file size is a multipleStéphane Glondu
As suggested in: https://lists.debian.org/aKheR0SX8yI5Aw9Q@begin
2025-08-22proc: cope with psets dying during host_processor_sets callSamuel Thibault
2025-08-21boot scripts: recommend using exec.staticSamuel Thibault
This avoids issues with differing versions of ld.so being used and libc actually installed.
2025-08-20boot: Fix loading 64b ELF filesSamuel Thibault
2025-08-20boot_script: Print missing symbol name on symbol lookup errorSamuel Thibault
2025-08-20boot: Add missing includeSamuel Thibault
2025-08-20boot: Give names to bootstrap tasksSamuel Thibault
so it's easy to spot them from the real kernel.
2025-08-20boot: fix ld.so name for x86_64 in default boot scriptSamuel Thibault
2025-08-1464-bit is mostly readySamuel Thibault
2025-08-01rumpnet: Add device translator for (Intel) NICsv0.9.git20250801Damien Zammit
This adds a working rump driver for /dev/wmX cards, which are Intel i8254x Gigabit Ethernet devices. (See man.netbsd.org for "wm(4)") This should be easily extended to support other NICs by contributing some makefile foo to netbsd/rump. TESTED: - On UP+apic it works 100% with hurd-i386. - On SMP it also works 100% with hurd-i386. Example usage: settrans -fgap /dev/rumpnet /hurd/rumpnet settrans -fgap /dev/wm0 /hurd/devnode -M /dev/rumpnet wm0 settrans -fgap /servers/socket/2 /hurd/pfinet -i /dev/wm0 ifup /dev/wm0 TODO: check tcpdump support Requires latest master of librump for nofifofs dynamic lib. Message-ID: <20250722092324.414844-1-damien@zamaudio.com>
2025-07-29lwip: allow setting an zero or broadcast addressJoan Lledó
After DHCPRELEASE, DHCP client sends a SIOCSIFADDR to set the interface address to 0.0.0.0. This is not accepted by our IP validator `ipv4config_is_valid()`. I think this use case is legit so this commit makes the translator accept 0.0.0.0 as a valid address. This assumes that a client trying to set IP to 0.0.0.0 is in fact trying to remove the IP from the interface. Then it sets all fields to NONE, in order to pass the validation. * lwip/lwip-util.c: `configure_device`: Add the exception for 0.0.0.0 and 255.255.255.255. Message-ID: <20250729155244.7976-2-jlledom@mailfence.com>
2025-07-20nfs: fix the handling of replies to MKNOD and SYMLINKMichael Kelly
The Linux NFS server does not accept a setting of file size to 0 for sockets and FIFOs so there is code to strip that for those cases. I also spotted that the file modification times were not being applied to a created file so there is now just one rpc to set all file attributes using xdr_encode_create_state(). This sets the times to be server time which is appropriate for a new file (even though it was created in the previous RPC call). The previous code was supplying the 'gid' based on that returned by the 'stat' but I don't think that can be relied on since the V3 protocol states that CREATE3 using EXCLUSIVE cannot guarantee any file attributes until after the SETATTR3.
2025-07-20nfs: generalise process_create_reply()Michael Kelly
to allow it to be used for MKNOD and SYMLINK rpc calls. These file types work differently to others in that a temporary file is created earlier and its 'struct node' is migrated to the new file later.  A few adjustments to the mutex locking to comply with the locking rules. A couple of mutex unlock errors spotted: not being unlocked on malloc failure and an unnecessary unlock in netfs_attempt_rename()
2025-07-20nfs: generalises the code for making a LOOKUP rpc callMichael Kelly
so that it can be used in a slightly different context in a following patch. I also removed the caching of rpc call results that were failed for errors other than ENOENT. For example, EPERM doesn't say anything about the lookup validity for other credentials that might be used.
2025-07-20nfs: generalise calling SETATTRMichael Kelly
2025-07-16vga: Also fallback to EGA when fb info is zeroSamuel Thibault
That e.g. happens with qemu -kernel option.
2025-07-14nfs: Implement --nfs-program command line option to enable v3 functionalityMichael Kelly
Note that I have altered the specification of the argument value so that the version can be specified without the program number rather than the other way around. I think it is much more likely the version would be specified than the program number.
2025-07-14nfs: couple of return code checksMichael Kelly
2025-07-14nfs: lookup root node handle specified by the mount serverMichael Kelly
to retrieve the true identity.
2025-07-14nfs: Use the variables for NFS program and NFS version rather than constants.Michael Kelly
2025-07-14nfs: mount_root: Fix and remove comment regarding getservbynameMichael Kelly
as its conclusion was valid and now implemented.
2025-07-14nfs: Implement statfs for V3.Michael Kelly
There was little overlap with the v2 code so it got an entirely separate implementation. There is the possibility of completing statfs.f_namelen properly using FSINFO3 and PATHCONF3 rpc calls but I didn't know if f_namelen should be the maximum length for a file name component or the entire file name path.
2025-07-14nfs: Removed inapplicable comment in netfs_report_access().Michael Kelly
2025-07-14nfs: nfs_attempt_rename() didn't unlock mutex after processing wcc_statMichael Kelly
2025-07-14nfs: nfs_attempt_rename() deadlocks performing an exclusive renameMichael Kelly
whilst attempting to lock an already held mutex.
2025-07-14nfs: nfs_attempt_lookup() did not unlock mutex on unlikely RPC init failureMichael Kelly
2025-07-13MAKEDEV: fix creating non-partstore nodesSamuel Thibault
We want to drop the slice part only in the partstore case. (but still want to change the device in case of USB disk)
2025-07-13MAKEDEV: Support /dev/ucd for USB cdromsSamuel Thibault
2025-07-13nfs: Fix netfs_attempt_create_file for nfsv3Michael Kelly
The v3 netfs_attempt_create_file() uses the 'exclusive' creation protocol which cannot specify the file permission bits or uid/gid. These need to be applied post-creation using SETATTR3. There was a missing call to do the chmod part  which I've added. Previously the call to chown that was present did not consider the return value. I have done so.
2025-07-13nfs: Fixes netfs_attempt_read() for nfsv3Michael Kelly
Use the 64 bit value required for v3 'offset' and process opaque_data part of the reply properly.
2025-07-13nfs: Fixes netfs_attempt_create_file() unlockingMichael Kelly
for unlikely case of RPC init failure and processing of v3 reply
2025-07-13nfs: Fix file creation for nfsv3Michael Kelly
This adds new code to process the reply from a file creation operation that applies equally to CREATE3, MKDIR3, SYMLINK3 and MKNOD3. RFC1813 permits a reply without the created file's handle and it might be necessary to perform a LOOKUP3 on the created file post-creation. Debian Linux NFSV3 server actually always returns the handle when compiling gnumach however I have tested the case where it might not by adding code (now removed) to pretend the handle wasn't present in the reply. I expect therefore that the 'skip_returned_stat' function that is added is rarely called. Fixed netfs_attempt_mkdir() to process the NFSv3 reply properly.
2025-07-12nfs: add support for NFSv3 in 'fetch_directory'Michael Kelly
2025-07-10nfs: Fix write encoding for v3Michael Kelly
2025-07-10nfs: Fix xdr_decode_fattr decoding for v3Michael Kelly
2025-07-10nfs: Clean xdr_encode/decode_64bitMichael Kelly
Better use the stdint. Also export them, they will be useful generally.
2025-07-10nfs: Fix pointer arithmeticMichael Kelly
2025-07-07procfs: Make /proc/stat multi-cpu awareDamien Zammit
This allows top to show Cpu0 to CpuN idle stats when you press 1. TESTED: on UP and SMP gnumach with debian hurd-i386. Message-ID: <20250707092520.62819-1-damien@zamaudio.com>
2025-07-03MAKEDEV: Fix substitution not supported by dashSamuel Thibault
2025-07-02rumpusbdisk: Protect against a running rumpusbdisk.staticSamuel Thibault
2025-07-01dev: Fix ud[0-9] device nameSamuel Thibault
2025-07-01rumpdisk: Allow rumpusbdisk operate even when gnumach operates SATASamuel Thibault
rumpusbdisk's driving of USB sticks won't interfere with gnumach operating SATA.
2025-07-01rumpdisk: Support dynamic linkage of librumpDamien Zammit
This provides a functional rumpdisk and rumpusbdisk with or without static linkage of librump. Message-ID: <20250701141609.152652-1-damien@zamaudio.com>
2025-07-01console: Fix hardcoded message sizes for 64b caseSamuel Thibault
2025-07-01console-client vga: Avoid using optimized string operations on vga_videomemSamuel Thibault
The VGA boards may not like AVX-whatnot-optimized 512B accesses. E.g. qemu does not support it and raises an invalid opcode trap.
2025-06-30console-client ncursesw: Fix confusion between color pair and video attributeSamuel Thibault
COLOR_PAIR takes a color pair, it does not produce one.