All of lore.kernel.org
 help / color / mirror / Atom feed
From: Andreas Herrmann <aherrman@arcor.de>
To: Sam Ravnborg <sam@ravnborg.org>
Cc: linux-kbuild@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Kconfig: ARCH=x86 causes wrong utsname.machine
Date: Fri, 16 Nov 2007 13:37:47 +0100	[thread overview]
Message-ID: <20071116123747.GA12086@devil> (raw)
In-Reply-To: <20071116111446.GA16968@devil>

The new ARCH=x86 kernel build causes weired machine strings on 32-bit.
For a cross-compiled kernel I have

	 $ uname -m
	 x66_64

For a kernel natively built on a 32 bit machine I have

	$ uname -m  
	x66

Looking at the sources, I think that utsname->machine was initially
set as "x86_64" and "x86", respectively.
But in arch/x86/kernel/cpu/bugs.c in check_bugs() the second character
is set to '6' on my K7.

I think the right solution for that problem is to use "x86_64" as the
machine name for 64-bit and to keep the old "i[3456]86" strings for
32-bit kernels.

Several tools (e.g. the kernel build itself) will be confused
otherwise (*).


Regards,

Andreas


(*) Example:
$ uname -m
x66_64
$ make menuconfig
Makefile:425: /projects/linux-2.6-x86/arch/x66_64/Makefile: No such file or directory
make: *** No rule to make target `/projects/linux-2.6-x86/arch/x66_64/Makefile'.  Stop.


  reply	other threads:[~2007-11-16 11:36 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-11-16 11:14 Kconfig: ARCH=x86 Andreas Herrmann
2007-11-16 12:37 ` Andreas Herrmann [this message]
2007-11-16 15:20   ` Kconfig: ARCH=x86 causes wrong utsname.machine H. Peter Anvin
2007-11-16 22:15     ` Sam Ravnborg
2007-11-16 22:58       ` H. Peter Anvin
2007-11-16 23:33         ` H. Peter Anvin
2007-11-17  7:57         ` Sam Ravnborg
2007-11-17 10:16           ` [PATCH] x86: fix UTS_MACHINE to be "i386" for 32-bit build and "x86_64" for 64-bit build Andreas Herrmann
2007-11-16 12:43 ` Kconfig: ARCH=x86 Andreas Herrmann
2007-11-16 12:58 ` Sam Ravnborg

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20071116123747.GA12086@devil \
    --to=aherrman@arcor.de \
    --cc=linux-kbuild@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=sam@ravnborg.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.