Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

sysfs: read address bits from sysfs file #1966

Merged
merged 2 commits into from Jan 2, 2023

Conversation

t-8ch
Copy link
Member

@t-8ch t-8ch commented Dec 21, 2022

If setarch is running as 32bit userspace on a 64bit kernel we should use
the kernel personality.
intel-lab-lkp pushed a commit to intel-lab-lkp/linux that referenced this pull request Dec 21, 2022
This can be used by userspace to determine the address size of the
running kernel.
It frees userspace from having to interpret this information from the
UTS machine field.

Userspace implementation:
util-linux/util-linux#1966

Signed-off-by: Thomas Weißschuh <linux@weissschuh.net>
t-8ch added a commit to t-8ch/linux that referenced this pull request Dec 24, 2022
This can be used by userspace to determine the address size of the
running kernel.
It frees userspace from having to interpret this information from the
UTS machine field.

Userspace implementation:
util-linux/util-linux#1966

Signed-off-by: Thomas Weißschuh <linux@weissschuh.net>
@karelzak karelzak merged commit 1ad0eff into util-linux:master Jan 2, 2023
@t-8ch
Copy link
Member Author

t-8ch commented Jan 2, 2023

This was only a draft PR. The kernel implementation has not been merged yet. (Or even reviewed)

@t-8ch
Copy link
Member Author

t-8ch commented Jan 21, 2023

The kernel part for this has been picked up by Greg in https://git.kernel.org/pub/scm/linux/kernel/git/gregkh/driver-core.git/commit/?h=driver-core-next&id=00142bfd5a916a0b3899cc709bf8f5042cf3d084

It should make it into Linux 6.3.

@t-8ch t-8ch deleted the address_bits branch January 21, 2023 15:52
intel-lab-lkp pushed a commit to intel-lab-lkp/linux that referenced this pull request Jan 23, 2023
This can be used by userspace to determine the address size of the
running kernel.
It frees userspace from having to interpret this information from the
UTS machine field.

Userspace implementation:
util-linux/util-linux#1966

Signed-off-by: Thomas Weißschuh <linux@weissschuh.net>
Link: https://lore.kernel.org/r/20221221-address-bits-v1-1-8446b13244ac@weissschuh.net
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants