Bug 1268604 - Cannot use -p option for over-256 processor systems
Cannot use -p option for over-256 processor systems
Status: CLOSED ERRATA
Product: Fedora EPEL
Classification: Fedora
Component: msr-tools (Show other bugs)
epel7
x86_64 Linux
unspecified Severity medium
: ---
: ---
Assigned To: Greg Bailey
Fedora Extras Quality Assurance
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2015-10-03 09:19 EDT by Seiichi Ikarashi
Modified: 2015-11-08 12:52 EST (History)
1 user (show)

See Also:
Fixed In Version: msr-tools-1.3-3.el7
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2015-11-08 12:52:02 EST
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description Seiichi Ikarashi 2015-10-03 09:19:06 EDT
Description of problem:
-p option is limited to processor number 255 intentionally but
nowadays, over-256 processor systems are coming.
Let's expand the max limit to, say, 65535 or more.

Version-Release number of selected component (if applicable):
msr-tools-1.3-1.el7

How reproducible:
Always

Steps to Reproduce:
1. Install msr-tools into a system that has 257 processors or more.
2. Use rdmsr command with "-p 256" option.

Actual results:
rdmsr exits with errno 127.

Expected results:
rdmsr should print the MSR value from CPU 256.

Additional info:

A sample fix is
https://github.com/sikarash/msr-tools/commit/3bfa9f712203bd0ad029df8489d2122bd51e0a7b
Comment 1 Greg Bailey 2015-10-03 09:40:37 EDT
Wouldn't we want a similar patch to wrmsr.c and cpuid.c?  It looks like your pull request on github only addresses rdmsr.c.
Comment 2 Seiichi Ikarashi 2015-10-04 01:12:10 EDT
Greg,

(In reply to Greg Bailey from comment #1)
> Wouldn't we want a similar patch to wrmsr.c and cpuid.c?  It looks like your
> pull request on github only addresses rdmsr.c.

You are correct. They are necessary.

https://github.com/sikarash/msr-tools/commit/34f8aa57d4fb571356fcefc5b1b0303af10d0d31
https://github.com/sikarash/msr-tools/commit/a6d856368a354532bf0218dfc334f4e14673271d
Comment 3 Seiichi Ikarashi 2015-10-04 10:21:27 EDT
I was wrong.
The value 65535 is nonsense because the variable is type of (int),
and also the theoretical max logical CPUs of RHEL7 is 5120.
https://access.redhat.com/articles/rhel-limits

So 5120 is enough here.
Comment 4 Seiichi Ikarashi 2015-10-04 10:24:31 EDT
I was wrong again, 2,147,483,647 is the maximum of signed int for x86_64.
Still, 5120 is enough for RHEL7.
Comment 5 Seiichi Ikarashi 2015-10-08 11:57:32 EDT
Greg, are you going to fix these three commands?
Comment 6 Greg Bailey 2015-10-09 11:40:33 EDT
(In reply to Seiichi Ikarashi from comment #5)
> Greg, are you going to fix these three commands?

Yes, of course, I just returned from vacation and will address these either today or tomorrow.
Comment 7 Fedora Update System 2015-10-10 08:04:41 EDT
msr-tools-1.3-3.el7 has been submitted as an update to Fedora EPEL 7. https://bodhi.fedoraproject.org/updates/FEDORA-EPEL-2015-ace89f67cb
Comment 8 Fedora Update System 2015-10-12 14:50:11 EDT
msr-tools-1.3-3.el7 has been pushed to the Fedora EPEL 7 testing repository. If problems still persist, please make note of it in this bug report.
If you want to test the update, you can install it with
$ su -c 'yum --enablerepo=epel-testing update msr-tools'
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-EPEL-2015-ace89f67cb
Comment 9 Fedora Update System 2015-11-08 12:52:00 EST
msr-tools-1.3-3.el7 has been pushed to the Fedora EPEL 7 stable repository. If problems still persist, please make note of it in this bug report.

Note You need to log in before you can comment on or make changes to this bug.