1
0
Fork 0
Commit graph

1353 commits

Author SHA1 Message Date
Jaroslav Škarvada
a37e1d17fb
Merge pull request #217 from olysonek/fix-epb-support-check
cpu: Update checking if EPB is supported
2019-11-22 15:46:37 +01:00
Jaroslav Škarvada
46c8ea434d
Merge pull request #216 from olysonek/udev-matcher-fix
Use re.DOTALL in the udev device matcher
2019-11-22 15:43:21 +01:00
Ondřej Lysoněk
43375e6bbe cpu: Update checking if EPB is supported
Update checking if EPB is supported so that it works with recent
versions of the x86_energy_perf_policy tool. Newer versions of
x86_energy_perf_policy, unlike older versions, exit with a zero exit
code even if the CPU doesn't support EPB. Newer versions of the tool
give no ouput on stdout if EPB is not supported, so check for that.

In the future, we might like to determine if EPB is supported by
searching /proc/cpuinfo for specific CPU flags. However the solution
described in the previous paragraph should work just fine for now.

Resolves: rhbz#1690929

Signed-off-by: Ondřej Lysoněk <olysonek@redhat.com>
2019-11-22 14:29:36 +01:00
Ondřej Lysoněk
d0b43e8b74 Use re.DOTALL in the udev device matcher
In order to allow matching multiple parameter-value pairs in a single
regex, we need to use re.DOTALL, because the parameter-value pairs are
on separate lines. Consider the following regex:

^ID_MODEL=SD_MMC$.*^ID_MODEL_ID=0316$

Previously it would not much a string such as the following:

ID_MODEL=SD_MMC
ID_MODEL_ENC=SD\x2fMMC\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20
ID_MODEL_ID=0316

Now it does match.

It should be noted that this change is not entirely
backwards-compatible. Some user-written regexes can now start to match
where they shouldn't. For example the following regex will now match
even if 'ID_MODEL_ID' and '0316' are on different lines.

ID_MODEL_ID.*0316

The primary motivation for this change is making the udev matcher
behave the same as the cpuinfo matcher that will be written to resolve
rhbz#1748965.

Signed-off-by: Ondřej Lysoněk <olysonek@redhat.com>
2019-11-22 13:28:58 +01:00
Jaroslav Škarvada
3792d6320f
Merge pull request #215 from olysonek/irq_affinity_verification
scheduler: Make IRQ SMP affinity verification respect ignore_missing
2019-11-21 15:33:11 +01:00
Ondřej Lysoněk
f7ccf6f092 scheduler: Make IRQ SMP affinity verification respect ignore_missing
Changing the SMP affinity of some IRQs is not supported. The semantics
of ignore_missing is that unsupported tunings are not treated as
errors during verification. IRQ SMP affinity being unchangeable can be
regarded as an unsupported tuning, so skip verification of these IRQs
when ignore_missing is set.

The code assumes that the IRQ numbers point to the same device/event
throughout the Tuned run time. We might need to break this assumption
in the future (or maybe not; I haven't looked into how IRQ numbers are
allocated). Either way, the assumption is already present in the code
- rollback assumes the same thing.

Resolves: rhbz#1729936

Signed-off-by: Ondřej Lysoněk <olysonek@redhat.com>
2019-11-21 13:51:15 +01:00
Jaroslav Škarvada
4c3d45c259 docs: disabled docs generation on RHEL, there is no asciidoctor
And asciidoc doesn't seem to be compatible, so disable the docs
generation for now on RHEL.

Signed-off-by: Jaroslav Škarvada <jskarvad@redhat.com>
2019-11-20 13:36:44 +01:00
Jaroslav Škarvada
94a80127e4 unittests: disabled on RHEL due to missing dependency
Signed-off-by: Jaroslav Škarvada <jskarvad@redhat.com>
2019-11-20 13:36:44 +01:00
Jaroslav Škarvada
77fa615963
Merge pull request #214 from psss/beakerlib-cleanup
Remove obsolete rhts imports from beakerlib tests
2019-11-20 13:36:15 +01:00
Petr Šplíchal
e82271a6bb Remove obsolete rhts imports from beakerlib tests 2019-11-20 13:15:58 +01:00
Jaroslav Škarvada
2bafe790be
beakerlib: fixed beakerlib path used in beakerlib test
Signed-off-by: Jaroslav Škarvada <jskarvad@redhat.com>
2019-11-20 11:56:25 +01:00
Jaroslav Škarvada
8a984ffb21
Merge pull request #213 from psss/fix-tests
Remove extra fmf root, move test under beakerlib
2019-11-20 11:45:46 +01:00
Petr Šplíchal
2ca4f84792 Remove extra fmf root, move test under beakerlib 2019-11-20 10:50:16 +01:00
Jaroslav Škarvada
cc974087a0
Merge pull request #212 from pvalena/fix-tmt
Fix packit / TMT tests.
2019-11-19 22:34:18 +01:00
Pavel Valena
2100a53b44 Fix packit / TMT tests. 2019-11-19 18:32:09 -02:00
Jaroslav Škarvada
7623044b58
packit: minor updates
Signed-off-by: Jaroslav Škarvada <jskarvad@redhat.com>
2019-11-19 19:58:43 +01:00
Jaroslav Škarvada
4fc46101b8
Merge pull request #211 from yarda/beakerlib-tests
Beakerlib tests
2019-11-18 17:16:50 +01:00
Jaroslav Škarvada
55d382bf13
beakerlib: enabled testing in yaml
Signed-off-by: Jaroslav Škarvada <jskarvad@redhat.com>
2019-11-18 16:50:41 +01:00
Jaroslav Škarvada
9841c1250f
beakerlib: added Robin's name and fixed description
Signed-off-by: Jaroslav Škarvada <jskarvad@redhat.com>
2019-11-18 16:38:01 +01:00
Jaroslav Škarvada
cff78c537c tests: moved tests under directory 'tests'
Also renamed directories to be more consistent.

Signed-off-by: Jaroslav Škarvada <jskarvad@redhat.com>
2019-11-18 16:34:11 +01:00
Jaroslav Škarvada
98ada2ba71
Merge pull request #210 from marmolak/master
tests-beakerlib: Convert metadata to fmf format.
2019-11-18 16:03:48 +01:00
Jaroslav Škarvada
58d5dde0aa
Merge pull request #209 from yarda/python3-by-default
Use python3 interpreter by default
2019-11-18 15:57:20 +01:00
Jaroslav Škarvada
dd747f35f6
Merge pull request #208 from yarda/make-test-enable
spec: added %check to run unit tests
2019-11-18 11:27:49 +01:00
Jaroslav Škarvada
476be07b46
Use python3 interpreter by default
This may ease development, because development environment will
be probably already on python3.

Signed-off-by: Jaroslav Škarvada <jskarvad@redhat.com>
2019-11-18 11:21:33 +01:00
Robin Hack
c95ef6f9e0 tests-beakerlib: Convert metadata to fmf format. 2019-11-18 03:53:54 -05:00
Jaroslav Škarvada
dba0ec0c65
spec: added %check to run unit tests
Also shipped 'tests' in sources.

Signed-off-by: Jaroslav Škarvada <jskarvad@redhat.com>
2019-11-17 23:37:17 +01:00
Jaroslav Škarvada
d46abffa62
Merge pull request #205 from dhodovsk/packit-onboard-w-copr
Enable copr builds and add packit config
2019-11-14 15:13:11 +01:00
Marcelo Tosatti
785128af2d realtime profile: fix nowatchdog kernel command line option
The correct string for the option is "tsc=nowatchdog", and
not "nowatchdog".

Signed-off-by: Marcelo Tosatti <mtosatti@redhat.com>
2019-11-13 21:01:43 +01:00
Dominika Hodovska
6ca96c9558 Enable copr builds and add packit config 2019-11-11 15:21:56 +01:00
Jaroslav Škarvada
2cb59c2ed6
Merge pull request #200 from marmolak/master
tests-beakerlib: Add first tests.
2019-11-04 14:31:05 +01:00
Jaroslav Škarvada
7ad091e4f7
Merge pull request #204 from olysonek/cpu_expand_vars
cpu: Expand variables in all commands
2019-11-04 14:28:19 +01:00
Marcelo Tosatti
0facf2ed5e realtime profile: add "nowatchdog" kernel command line option
This option disables the TSC clocksource watchdog
for isolated CPUs (which avoids interruptions
by the per-CPU clocksource watchdog timer).

Signed-off-by: Marcelo Tosatti <mtosatti@redhat.com>
2019-11-01 11:00:28 +01:00
Ondřej Lysoněk
a30d13687c cpu: Expand variables in all commands
Variables in force_latency, min_perf_pct, max_perf_pct and no_turbo
options were not being expanded. Fix it.

Fixes #203

Signed-off-by: Ondřej Lysoněk <olysonek@redhat.com>
2019-10-30 08:56:49 +01:00
Jaroslav Škarvada
ee06d010d8
defirqaffinity: write smp_affinity in text mode
We do not need to use binary mode. This fixes the code for python3.

Fixes: #201

Signed-off-by: Jaroslav Škarvada <jskarvad@redhat.com>
2019-10-21 19:34:27 +02:00
Robin Hack
31d66078f6 tests-beakerlib: Add first tests.
Upstream first.

Signed-off-by: Robin Hack <rhack@redhat.com>
2019-10-21 14:19:06 +02:00
Jaroslav Škarvada
252bd91ed0
latency-peformance: backup latency requirement increased to 3 us
In the kernel table of exit latencies of various CPUs the worst
exit latency for C1 seems to be 3 us, so increase the backup
value latency requirement to 3 us to match the worst C1 exit
latency.

Related: rhbz#1737628

Signed-off-by: Jaroslav Škarvada <jskarvad@redhat.com>
2019-09-24 09:00:41 +02:00
Jaroslav Škarvada
feb6e8b6f4
profiles_loader: added support for multiple include directive
Now multiple profiles can be included by:

[main]
include=profile1;profile2

Also comma "," can be used instead of the semicolon ";".
No escaping is done, so it's assumed there will be no comma or semicolon
in the profile name.

Signed-off-by: Jaroslav Škarvada <jskarvad@redhat.com>
2019-08-20 12:46:14 +02:00
Jaroslav Škarvada
e40b50a498
Used C-states in latency specification
For sap-hana and virtual-host profiles used state3 (i.e. usually C3)
C-state in latency specification instead of the hardcoded value 70 us,
i.e.:
force_latency=cstate.id:3|70

Also dropped obsoleted TODO note from the plugin_cpu.

Related: rhbz#1737628

Signed-off-by: Jaroslav Škarvada <jskarvad@redhat.com>
2019-08-16 18:13:02 +02:00
Jaroslav Škarvada
0ec40e0360
plugin_cpu: latency can be now specified as cstate
Maximal latency can be now specified multiple ways:
- directly in usec (this is the same as before), e.g. for 10 us:
  force_latency = 10
- as an ID of maximal cstate allowed, e.g. for the kernel state1:
  force_latency = cstate.id:1
- as a name (case sensitive) of maximal cstate allowed, e.g. for the state named C1:
  force_latency = cstate.name:C1

It is also possible to specify multiple fallback values separated by '|', e.g.:
  force_latency = cstate.name:C6|cstate.id:4|10

This will try to obtain latency of cstate named C6, if it fails (e.g.
there is no such cstate), it will try kernel state4 and if it also fails
it finally fallbacks to 10 us.

This commit also changes force_latency settings of latency-performance
profile to:
  force_latency=cstate.id:1|1

I.e. it tries kernel state1 and fallbacks to 1 us.

Resolves: rhbz#1737628

Signed-off-by: Jaroslav Škarvada <jskarvad@redhat.com>
2019-08-14 16:34:17 +02:00
Jaroslav Škarvada
a8f2a8306e
plugin_sysctl: fixed traceback with modifiers '>', '<' and orig==new
It fixed the following problem e.g. the profile:
[sysctl]
kernel.pid_max=>131072

and if kernel.pid_max is already 131072 Tuned shows traceback.

Resolves: rhbz#1739418

Signed-off-by: Jaroslav Škarvada <jskarvad@redhat.com>
2019-08-09 11:40:48 +02:00
Marcelo Tosatti
25089296f3 realtime-virtual profiles: enable ktimer_lockless_check if available
RHEL will include a backport of the kernel patch
"do not raise timer softirq unconditionally (spinlockless version)"
(https://lkml.org/lkml/2019/4/15/1215), but disabled by default.

Enable it in realtime-virtual-{host/guest} profiles as it decreases
maximum cyclictest latency.

Signed-off-by: Marcelo Tosatti <mtosatti@redhat.com>
2019-07-18 10:57:33 +02:00
Jaroslav Škarvada
584f7dbe2c
Merge pull request #194 from xzpeter/irqbalance
Apply irqbalance service tuning for realtime-virtual-{host|guest} profiles
2019-07-10 13:50:49 +02:00
Peter Xu
7e93b6948f realtime: Apply irqbalance tunes too in realtime profiles
Realtime profiles require to restrict irqbalance too.  Apply them to
the realtime profile so that realtime-virtual-{host|guest} can benefit
from that too.

Signed-off-by: Peter Xu <peterx@redhat.com>
2019-07-10 13:09:03 +08:00
Peter Xu
4a8e64994e cpu-partitioning: Introduce irqbalance helpers and use
Provide irqbalance_banned_cpus_{setup|clear} for tuning irqbalance.
Use them in cpu-partitioning.

Signed-off-by: Peter Xu <peterx@redhat.com>
2019-07-10 13:09:03 +08:00
Ondřej Lysoněk
66924b8422 plugin_script: Execute all scripts regardless of errors
Due to commit d4038a7e64, if a script fails to execute or its exit
code is non-zero, no subsequent scripts are executed. This seems
logically wrong and it causes problems especially during rollback as some
tunings may not be reverted due to this behaviour. Also, it appears it
was not the intention of that commit to change this behaviour - the
intention rather seems to have been to make _call_scripts return
success/error information for use by the verification mechanism.

So let's aggregate the success/error information instead.

Related: https://github.com/redhat-performance/tuned/pull/194

Signed-off-by: Ondřej Lysoněk <olysonek@redhat.com>
2019-07-09 11:31:20 +02:00
Jaroslav Škarvada
b514cda168
new release (2.12.0)
Signed-off-by: Jaroslav Škarvada <jskarvad@redhat.com>
2019-06-27 17:08:55 +02:00
Jaroslav Škarvada
fd0ed00757
new release (2.12.0-rc.1)
Signed-off-by: Jaroslav Škarvada <jskarvad@redhat.com>
2019-06-12 15:00:23 +02:00
Jaroslav Škarvada
9b1c045d30
realtime-virtual-host: add tsc-deadline=on to qemu cmdline
So that QEMU uses the in kernel irqchip.

Original patch provided by Luiz Capitulino <lcapitulino@redhat.com>.

Resolves: rhbz#1554458

Signed-off-by: Jaroslav Škarvada <jskarvad@redhat.com>
2019-06-10 19:11:53 +02:00
Jaroslav Škarvada
35a7b93284
Merge pull request #190 from olysonek/sap-fixes
Drop sap-hana-vmware profile, fix other SAP profiles
2019-06-10 17:51:29 +02:00
Jaroslav Škarvada
75728c041a
Merge pull request #187 from olysonek/master
Fix a bare 'except' statement
2019-06-10 17:40:05 +02:00