bug-hurd
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [RFC PATCH 00/34] The rest of the x86_64-gnu port


From: Luca
Subject: Re: [RFC PATCH 00/34] The rest of the x86_64-gnu port
Date: Tue, 21 Mar 2023 17:30:21 +0100

Il 21/03/23 15:38, Sergey Bugaev ha scritto:
But how does a core know its CPU number?

Currently through the APIC_ID register, see the CPU_NUMBER macro in i386/i386/cpu_number.h.

This would've been easier if we could pass the port name as an env
variable, then we could pick some predefined name (e.g.
DEVICE_MASTER_PORT) and have glibc pick it up early. But I don't think
there is a way to set env in boot scripts, nor is it worth it, really.

Actually on the stack there are both args and envs, it's just that by default gnumach passes an empty env (unless in compatibility mode, but that doesn't seems used anymore). I guess the reason for the argument instead of env is that it can be enabled/disabled at will, but the port name could potentially be passed in both ways, when required.


Luca



reply via email to

[Prev in Thread] Current Thread [Next in Thread]