make lazy RCU a boot time option

Bug #2045492 reported by Andrea Righi
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
linux (Ubuntu)
Fix Released
Undecided
Unassigned
Noble
Fix Released
Undecided
Unassigned
linux-lowlatency (Ubuntu)
Fix Released
Undecided
Unassigned
Noble
Fix Released
Undecided
Unassigned

Bug Description

[Impact]

With LP: #2023007 we have decided to enable CONFIG_RCU_LAZY in the lowlatency kernel to improve power consumption, but this option can potentially introduce performance regressions in some cases, due to the fact that RCU callbacks are now batched and flushed all at once after a timed delay.

It would be definitely safer to have a way to enable/disable lazy RCUs at boot time. In this way we could provide a simple kernel command line option that can be used in all those cases where the lowlatency kernel is required, but we don't want to risk performance regressions.

[Test case]

In this context providing a single test case is not relevant. After applying the fix any performance benchmark can be used to evaluate if lazy RCU feature should be enabled at boot time or not (according to the specific context where the lowlatency kernel is going to be used/deployed).

[Fix]

Apply this patch to the *generic* kernel:
https://<email address hidden>/T/#u

We want to apply this to the generic kernel, not just lowlatency, because in this way *all* derivatives will have the possibility to get this feature, in case some of them want to enable lazy RCUs (even generic itself).

Then make sure that lowlatency (or any other kernel with CONFIG_RCU_LAZY=y) also has CONFIG_RCU_LAZY_DEFAULT_OFF not set (so that the previous behavior is not changed).

[Regression potential]

We may receive reports of small performance regressions vs power consumption regressions, depending on the rcutree.enable_rcu_lazy command line option that is used. In such case we should suggest the user to test both with lazy RCU disabled or enabled.

Andrea Righi (arighi)
description: updated
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package linux - 6.8.0-11.11

---------------
linux (6.8.0-11.11) noble; urgency=medium

  * noble/linux: 6.8.0-11.11 -proposed tracker (LP: #2053094)

  * Miscellaneous Ubuntu changes
    - [Packaging] riscv64: disable building unnecessary binary debs

 -- Paolo Pisati <email address hidden> Wed, 14 Feb 2024 00:04:31 +0100

Changed in linux (Ubuntu Noble):
status: New → Fix Released
Revision history for this message
Launchpad Janitor (janitor) wrote :
Download full text (37.0 KiB)

This bug was fixed in the package linux-lowlatency - 6.8.0-7.7.1

---------------
linux-lowlatency (6.8.0-7.7.1) noble; urgency=medium

  * noble/linux-lowlatency: 6.8.0-7.7.1 -proposed tracker (LP: #2052773)

  * Packaging resync (LP: #1786013)
    - debian.lowlatency/dkms-versions -- update from kernel-versions
      (main/d2024.02.07)

  * Miscellaneous Ubuntu changes
    - [packaging] update rust, clang and bindgen build-deps
    - [Config] updateconfigs following 6.8.0-7.7 rebase

  [ Ubuntu: 6.8.0-7.7 ]

  * noble/linux: 6.8.0-7.7 -proposed tracker (LP: #2052691)
  * update apparmor and LSM stacking patch set (LP: #2028253)
    - SAUCE: apparmor4.0.0 [01/87]: LSM stacking v39: integrity: disassociate
      ima_filter_rule from security_audit_rule
    - SAUCE: apparmor4.0.0 [02/87]: LSM stacking v39: SM: Infrastructure
      management of the sock security
    - SAUCE: apparmor4.0.0 [03/87]: LSM stacking v39: LSM: Add the lsmblob data
      structure.
    - SAUCE: apparmor4.0.0 [04/87]: LSM stacking v39: IMA: avoid label collisions
      with stacked LSMs
    - SAUCE: apparmor4.0.0 [05/87]: LSM stacking v39: LSM: Use lsmblob in
      security_audit_rule_match
    - SAUCE: apparmor4.0.0 [06/87]: LSM stacking v39: LSM: Add lsmblob_to_secctx
      hook
    - SAUCE: apparmor4.0.0 [07/87]: LSM stacking v39: Audit: maintain an lsmblob
      in audit_context
    - SAUCE: apparmor4.0.0 [08/87]: LSM stacking v39: LSM: Use lsmblob in
      security_ipc_getsecid
    - SAUCE: apparmor4.0.0 [09/87]: LSM stacking v39: Audit: Update shutdown LSM
      data
    - SAUCE: apparmor4.0.0 [10/87]: LSM stacking v39: LSM: Use lsmblob in
      security_current_getsecid
    - SAUCE: apparmor4.0.0 [11/87]: LSM stacking v39: LSM: Use lsmblob in
      security_inode_getsecid
    - SAUCE: apparmor4.0.0 [12/87]: LSM stacking v39: Audit: use an lsmblob in
      audit_names
    - SAUCE: apparmor4.0.0 [13/87]: LSM stacking v39: LSM: Create new
      security_cred_getlsmblob LSM hook
    - SAUCE: apparmor4.0.0 [14/87]: LSM stacking v39: Audit: Change context data
      from secid to lsmblob
    - SAUCE: apparmor4.0.0 [15/87]: LSM stacking v39: Netlabel: Use lsmblob for
      audit data
    - SAUCE: apparmor4.0.0 [16/87]: LSM stacking v39: LSM: Ensure the correct LSM
      context releaser
    - SAUCE: apparmor4.0.0 [17/87]: LSM stacking v39: LSM: Use lsmcontext in
      security_secid_to_secctx
    - SAUCE: apparmor4.0.0 [18/87]: LSM stacking v39: LSM: Use lsmcontext in
      security_lsmblob_to_secctx
    - SAUCE: apparmor4.0.0 [19/87]: LSM stacking v39: LSM: Use lsmcontext in
      security_inode_getsecctx
    - SAUCE: apparmor4.0.0 [20/87]: LSM stacking v39: LSM: Use lsmcontext in
      security_dentry_init_security
    - SAUCE: apparmor4.0.0 [21/87]: LSM stacking v39: LSM:
      security_lsmblob_to_secctx module selection
    - SAUCE: apparmor4.0.0 [22/87]: LSM stacking v39: Audit: Create audit_stamp
      structure
    - SAUCE: apparmor4.0.0 [23/87]: LSM stacking v39: Audit: Allow multiple
      records in an audit_buffer
    - SAUCE: apparmor4.0.0 [24/87]: LSM stacking v39: Audit: Add record for
      multiple task security contexts
    - SAUCE: apparmor4.0.0 [25/8...

Changed in linux-lowlatency (Ubuntu Noble):
status: New → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.