]> git.baikalelectronics.ru Git - kernel.git/commit
kernel/utsname_sysctl.c: print kernel arch
authorPetr Vorel <pvorel@suse.cz>
Thu, 1 Sep 2022 19:44:03 +0000 (21:44 +0200)
committerAndrew Morton <akpm@linux-foundation.org>
Mon, 12 Sep 2022 04:55:12 +0000 (21:55 -0700)
commit78f1610ca0b3cd51af2997b8c94f5653760bb7ea
tree31be270b66428d2ea0ebfa65b55c2f3d5d015b3b
parent2d27ef0b6dcc4e8dacb5b127aadc4c0dd73a5017
kernel/utsname_sysctl.c: print kernel arch

Print the machine hardware name (UTS_MACHINE) in /proc/sys/kernel/arch.

This helps people who debug kernel with initramfs with minimal environment
(i.e.  without coreutils or even busybox) or allow to open sysfs file
instead of run 'uname -m' in high level languages.

Link: https://lkml.kernel.org/r/20220901194403.3819-1-pvorel@suse.cz
Signed-off-by: Petr Vorel <pvorel@suse.cz>
Acked-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Cc: David Sterba <dsterba@suse.com>
Cc: "Eric W . Biederman" <ebiederm@xmission.com>
Cc: Rafael J. Wysocki <rafael@kernel.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Documentation/admin-guide/sysctl/kernel.rst
kernel/utsname_sysctl.c