IRC channel logs
2026-07-23.log
back to list of logs
<jab>yang3: have you started the upgrade? <jab>definitely do it on the console <jab>also make sure you update via: <jab> # apt upgrade --without-new-pkgs <yang3>jab I did exactly that, and it finished, hoping for a safe reboot now <yang3>computer screen matrix is worn out, it barely has any light <yang3>but I can always plug in the external monitor <yang3>it came back as "GNU hurd 0.9 GNU-Mach 1.8+git20260224-up-486/Hurd-0.9 i686-AT386 GNU" <yang3>ps auxw (works), but ps wuxa (doesnt) <damo22>youpi: does PV-grub run as dom0? <damo22>that would be kind of cool if grub itself could be the dom0 <damo22>that would remove the linux dependency <youpi>again, dom0 needs to be running some management tools <youpi>it also provides hardware access (disk/network) <damo22>youpi: from what i read about pvgrub2 it starts in dom0 and can load a lower privileged xen guest <youpi>no it starts inside the domU <youpi>that's the whole point of pvgrub, running from within the guest <youpi>(not to be cofused with pygrub which indeed runs inside dom0, thus a security risk) <damo22>Zhou-Yutao: your IRC client keeps disconnecting <azul_>i think i still have, damo22 the thing i debugged <azul_>for user32 to work in 64 bit mach <azul_>at least to the loading of the modules <damo22>the interfaces it generates on 32 bit are not consistent <azul_>why is so difficult to generete them? <azul_>i suggest to remove mig from the design <azul_>after much more implementation would be harder <damo22>user32 is broken specifically because the 32 bit interfaces have different struct member sizes than the actual structs <azul_>why do you hardcode messages? <Zhou-Yutao>My internet connection here is not very good, it keeps disconnecting <azul_>which type of connection is it? <Zhou-Yutao>On the web page, my device is currently connecting to a VPN <damo22>the mach interface generator is supposed to generate interfaces that are compatible with the data being sent but unfortunately i think there were changes that were made for structs in particular that made it not compatible anymore <damo22>youpi: is it possible we can fix it without rebuilding all of world? <Zhou-Yutao>Unable to connect to libera.chat due to special restrictions imposed on Chinese Mainland <azul_>i mean, is it fiber, cable, mobile, ? <Zhou-Yutao>Under these circumstances, I can only connect through a VPN <youpi>damo22: see the mail I have just sent <youpi>I believe it is not wrong, it does match the C semantic <youpi>user32 just has to cope with the fact that 64b and 32b don't have the same alignment requirements <azul_>and what you do in the hurd, Zhou-Yutao? <youpi>azul_: there is no hardcoding, on the contrary, it's based on a common .defs definition <youpi>the concern is the proper translation between the 32b interpretation and the 64b interpretation of it <Zhou-Yutao>Just exploring for now. I'm interested in the microkernel design and how Hurd handles IPC. <azul_>why don't you remove those restrictions? <azul_>what do you need those hardcoded interfaces (even in .defs) for?= <damo22>youpi: why does alignment of struct matter for sending contents of structs? <damo22>if it knows there is a 64b value there, it can read it out and then send it as a unit <youpi>azul_: that's not a restriction, on the contrary <youpi>damo22: because the stub function is given the adress within the mig message, so it has to have the proper alignment <azul_>why don't you to ipc a-la-tcp-udp-ip? <youpi>and doesn't actually provide the features we need <youpi>way slower than direct kernel messages <youpi>you don't seem to actually understand what we are talking about <azul_>unix domain sockets are slow? <youpi>unix domain sockets are not tcp/ip <azul_>direct kernel messages you say <youpi>and still, unix domain sockets don't provide the features we need <azul_>i said a-la-tcpip, not tcpip <azul_>which ones dont they provide? <youpi>what tcp-ip feature you'd want? <youpi>please do read about things before proposing replacements <azul_>i mean, streams of bytes or streams with limits <youpi>you can't propose something without knowing what we need <youpi>we don't need streams for ipc <azul_><youpi> port sets, send-once, etc. <azul_>you dont study the field as much <damo22>azul_: cmon man hes the maintainer <damo22>he knows a little more than you give credit for <azul_>and you dont know how to change <damo22>i wasnt sure why the alignment matters <damo22>apparently the mach message is addressable <damo22>but if the msgs are addressed how can they not all have to be packed structs? <azul_>so come close to unix domain sockets (address messages, less hardcoded) you learned a bit, yes <youpi>the mig types do provide the alignment requirements, and thus give knowledge of possible holes <damo22>if packed, the alignment wont matter again <youpi>alignment always matter on some archs <youpi>you just can't always pack completely :) <damo22>so if _alignof__ (member) == 4 then you have to use 32 bit representation to send the data, and split it over multiple values <damo22>even if the underlying type is wider <damo22>but kernel64/user32 needs to be taught how to read the sizes properly then? <youpi>problem being that the kernel needs an alignment that is higher than what will be in the message <youpi>that's an eternal problem with messages, we have the same issue with network headers etc. on archs which can't access unaligned data <youpi>possibly by luck the message is already aligned by construction <youpi>then you can just claim it's a 64b value since it actually has the 64b alignment <youpi>that being said on x86_64 we don't need to care <youpi>there are also the holes questions <youpi>possibly by luck by construction there are no holes both in 32b and 64b <youpi>so possibly we don't need to actually implement the real translation and just need to type-cast to get the host_get_time64 etc. working <azert>may I propose a solution? revert the new style struct definitions and go back to standard mig structs (array). And deprecate any RPC that breaks in doing that <youpi>that's to be discussed with sergio, who spent the time on fixing the struct support :) <youpi>giving up on this just for the sake of user32/kernel64 is sad <youpi>linux itself leans to just drop such translation actually <azert>I understand that it is sad. But fixing it looks like even more work to do <youpi>note that the array-based mig structures do pose the problem of alignment <youpi>if you give an non-64b aligned array to the kernel server stub, it'll crash on 64b archs that require alignment <youpi>so it's not a long-term solution for 64b values in rpcs <azert>also holes, if you end up just memcpy the struct in the array <youpi>as long as the structures don't mix types, we'll be fine, but only by luck <youpi>but some of our structures do contain both numbers and size_t etc. <youpi>that won't work with 64b alignment requirements <youpi>azert: but the holes do have to match between the client and the server <youpi>if the client and the server inherently do not have the same notion of holes, arrays won't save you <youpi>and properly typing data is the only way to avoid longterm issues <damo22>why cant we define a serialization that is agnostic to alignment? <youpi>because it's less efficient than a memcpy? <damo22>but the old style structs only allow one type <damo22>which is pretty much the only way to guarantee it will work if the first member is aligned <azert>linux doesn't have an universal translator for 32bit to 64bit. They explicitly implement compatibility sys calls and ioctls for this issue <youpi>which makes it very hairy yes <youpi>at least we fix all rpcs in one fix <damo22>i never liked the idea of value = (*(struct thing *)data) <damo22>its fast but has a lot of things that can go wrong <damo22>a stream representing a data structure is not necessarily the same as the laid out memory for that data structure <azert>thunk_convert() does exactly what we need <azert>even better, since mig is already parsing the struct code, it could generate on the fly inTran and outTran functions in C when the ABI of the server is different from the expected client. This could result in very fast code <azert>the fact that mig itself is written in C.. I guess is good for bootstrapping. I'd implement such a tool in python otherwise <youpi>that could be an approach indeed <youpi>but we can as well just translate the message itself only when there is an alignment mismatch <etno>Do I understand it well that waitid() can currently be used only on a child process ? <etno>savannah gitweb is broken, let me find a source pointer to the lines I am wondering about <etno>Well... it is hurd/proc/wait.c:220-221 <youpi>etno: only the parent can wait for a child <etno>But something is odd, as the hurd hacking guide suggests to attach gdb to a running translator <etno>Does gdb reparent the process it attaches to when it ptrace() ? <youpi>I would be surprised it does <youpi>trying it doesn't show a difference in ppid <etno>AIUI, gdb is calling proc_wait on the proc server. Which validated that the calling process have children in the referenced lines. Or maybe this is not what it does <etno>Those lines did not change since befor e2000, so it would be surprising that gdb attach to a translao <etno> ...r hasn't been working since then <etno>There must be something happening when gdb calls ptrace(ATTACH) . <etno>Could it be that the tracee becomes a child, but the child parent stays the same ?