diff options
author | Karel Zak | 2011-03-31 13:09:50 +0200 |
---|---|---|
committer | Karel Zak | 2011-03-31 13:09:50 +0200 |
commit | 4e740fd81a8722e7bcfc04d44d0c1d2327b1da02 (patch) | |
tree | 23c22636d2180909fc377c3cead332397c6fc1eb /sys-utils/lscpu.c | |
parent | lscpu: fix threads-per-core calculation (diff) | |
download | kernel-qcow2-util-linux-4e740fd81a8722e7bcfc04d44d0c1d2327b1da02.tar.gz kernel-qcow2-util-linux-4e740fd81a8722e7bcfc04d44d0c1d2327b1da02.tar.xz kernel-qcow2-util-linux-4e740fd81a8722e7bcfc04d44d0c1d2327b1da02.zip |
lscpu: fix op-mode for /{sys,proc} dumps
Signed-off-by: Karel Zak <kzak@redhat.com>
Diffstat (limited to 'sys-utils/lscpu.c')
-rw-r--r-- | sys-utils/lscpu.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/sys-utils/lscpu.c b/sys-utils/lscpu.c index c3bb536cd..d3abb98b7 100644 --- a/sys-utils/lscpu.c +++ b/sys-utils/lscpu.c @@ -342,6 +342,11 @@ init_mode(void) { int m = 0; + if (sysrootlen) + /* reading info from any /{sys,proc} dump, don't mix it with + * information about our real CPU */ + return 0; + #if defined(__alpha__) || defined(__ia64__) m |= MODE_64BIT; /* 64bit platforms only */ #endif |