Note: This bug is displayed in read-only format because the product is no longer active in Red Hat Bugzilla.
RHEL Engineering is moving the tracking of its product development work on RHEL 6 through RHEL 9 to Red Hat Jira (issues.redhat.com). If you're a Red Hat customer, please continue to file support cases via the Red Hat customer portal. If you're not, please head to the "RHEL project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs in the statuses "NEW", "ASSIGNED", and "POST" are being migrated throughout September 2023. Bugs of Red Hat partners with an assigned Engineering Partner Manager (EPM) are migrated in late September as per pre-agreed dates. Bugs against components "kernel", "kernel-rt", and "kpatch" are only migrated if still in "NEW" or "ASSIGNED". If you cannot log in to RH Jira, please consult article #7032570. That failing, please send an e-mail to the RH Jira admins at rh-issues@redhat.com to troubleshoot your issue as a user management inquiry. The email creates a ServiceNow ticket with Red Hat. Individual Bugzilla bugs that are migrated will be moved to status "CLOSED", resolution "MIGRATED", and set with "MigratedToJIRA" in "Keywords". The link to the successor Jira issue will be found under "Links", have a little "two-footprint" icon next to it, and direct you to the "RHEL project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/RHEL-XXXX", where "X" is a digit). This same link will be available in a blue banner at the top of the page informing you that that bug has been migrated.

Bug 1314869

Summary: Backport of "cyclictest: SMI count/detection via MSR/SMI counter"
Product: Red Hat Enterprise Linux 7 Reporter: Daniel Bristot de Oliveira <daolivei>
Component: rt-testsAssignee: John Kacur <jkacur>
Status: CLOSED ERRATA QA Contact: Jiri Kastner <jkastner>
Severity: low Docs Contact:
Priority: unspecified    
Version: 7.3CC: bhu, jkastner, jshortt, williams
Target Milestone: rc   
Target Release: 7.3   
Hardware: x86_64   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2016-11-04 05:14:20 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Bug Depends On:    
Bug Blocks: 1274397    
Attachments:
Description Flags
backport of the feature
none
backport of man description of --smi option none

Description Daniel Bristot de Oliveira 2016-03-04 17:50:35 UTC
Description of problem:
The upstream --smi option of cyclictest helps to define if the worst-case latency is or is not caused by SMIs.

I used it on a customer, so I think it is good to have it in the official build.

Version-Release number of selected component (if applicable):
The last version of rt-tests does not have --smi option.

Comment 1 Daniel Bristot de Oliveira 2016-03-04 17:54:36 UTC
Created attachment 1133228 [details]
backport of the feature

cyclictest: SMI count/detection via MSR/SMI counter

Use the MSR/SMI counter on Intel's processor to detect/count SMIs. It is
based on turbostat's implementation.

SMI counting is enabled via --smi argument. When enabled, and additional
field is added on both regular and verbose ouput.

On the regular output, a SMI column shows how many SMIs occurred on
each CPU during cyclictest's execution. For example:

policy: fifo: loadavg: 0.09 0.05 0.02 1/194 2288

T: 0 ( 2285) P:80 I:1000 C:   9975 Min:      2 Act:    3 Avg:    4 Max:   20831 SMI:       2
T: 1 ( 2286) P:80 I:1500 C:   6650 Min:      2 Act:    2 Avg:    5 Max:   19910 SMI:       2
T: 2 ( 2287) P:80 I:2000 C:   4987 Min:      2 Act:    2 Avg:    6 Max:   20811 SMI:       2
T: 3 ( 2288) P:80 I:2500 C:   3990 Min:      2 Act:    3 Avg:    7 Max:   20322 SMI:       2

On verbose output, the last column shows how many SMIs occurred
on each loop. For example:

[  CPU  |   Loop |   Lat |  SMIs  ]
       0:    2156:       2       0
       0:    2157:       2       0
       0:    2158:       2       0
       0:    2159:   20981       2
       1:    1433:       2       0
       1:    1434:       2       0
       1:    1435:       2       0
       1:    1436:       3       0
       1:    1437:       2       0
       1:    1438:       2       0
       1:    1439:   20249       2

Signed-off-by: Daniel Bristot de Oliveira <bristot>
Signed-off-by: John Kacur <jkacur>

Comment 2 Daniel Bristot de Oliveira 2016-03-04 17:57:43 UTC
Created attachment 1133229 [details]
backport of man description of --smi option

cyclictest: Add --smi description on cyclictest man page

Add the description of the --smi command line option of cyclictest.

"--smi  Enable SMI count/detection on processors with SMI count support."

Signed-off-by: Daniel Bristot de Oliveira <bristot>
Signed-off-by: John Kacur <jkacur>

Comment 3 Daniel Bristot de Oliveira 2016-03-04 17:58:38 UTC
Brewbuild with the smi.patch:

https://brewweb.devel.redhat.com/taskinfo?taskID=10603781

Comment 4 John Kacur 2016-05-20 12:47:57 UTC
This was added in v0.97, so fixed earlier, but fixed at least in
rt-tests-1.0-1.el7 and up

Comment 9 errata-xmlrpc 2016-11-04 05:14:20 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://rhn.redhat.com/errata/RHBA-2016-2391.html