Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

nixos/gnome3: add realtime-scheduling option #99697

Merged

Conversation

@worldofpeace
Copy link
Contributor

@worldofpeace worldofpeace commented Oct 6, 2020

This adds an option services.gnome3.experimental-features.realtime-scheduling
See this comment for the motivation 0.
Having gnome-shell launched with capability seemed harmless at first,
but it caused these issues 1 2 for people who aren't even using
the feature. It makes more sense to make this optional.

Motivation for this change
Things done

I built the nixos manual.

  • Tested using sandboxing (nix.useSandbox on NixOS, or option sandbox in nix.conf on non-NixOS linux)
  • Built on platform(s)
    • NixOS
    • macOS
    • other Linux distributions
  • Tested via one or more NixOS test(s) if existing and applicable for the change (look inside nixos/tests)
  • Tested compilation of all pkgs that depend on this change using nix-shell -p nixpkgs-review --run "nixpkgs-review wip"
  • Tested execution of all binary files (usually in ./result/bin/)
  • Determined the impact on package closure size (by running nix path-info -S before and after)
  • Ensured that relevant documentation is up to date
  • Fits CONTRIBUTING.md.
This adds an option services.gnome3.experimental-features.realtime-scheduling
See this comment for the motivation [0].
Having gnome-shell launched with capability seemed harmless at first,
but it caused these issues [1] [2] for people who aren't even using
the feature. It makes more sense to make this optional.

[0]: NixOS#90201 (comment)
[1]: NixOS#90201
[2]: NixOS#86730
@@ -68,6 +68,38 @@ in
core-shell.enable = mkEnableOption "GNOME Shell services";
core-utilities.enable = mkEnableOption "GNOME core utilities";
games.enable = mkEnableOption "GNOME games";

experimental-features = {
Copy link
Member

@cole-h cole-h Oct 6, 2020

Style nit: why kebab case rather than camel case? Just mimicking nix's experimental-features flag/configuration option?

(Doesn't really matter, but it seems we use camel case everywhere else.)

Copy link
Contributor Author

@worldofpeace worldofpeace Oct 6, 2020

The options above mimic the element names for GNOME OS from gnome-build-meta. The actual dconf key this setting operates on is /org/gnome/mutter/experimental-features, and they just throw whatever feature in there. In the future it would be nice to have #54150 to extend with more experimental-feature options. (though I do see how it's named similar to how nix has experimental-features). I just happened to group it in services.gnome3 because that namespace made the most sense.

Though, you're correct we mix casing for options. But for these ones it would be really ugly to read in camel.

Copy link
Member

@cole-h cole-h Oct 6, 2020

Ah, OK, fair enough. Carry on :)

@TredwellGit
Copy link
Member

@TredwellGit TredwellGit commented Oct 6, 2020

Thanks for writing this. I was going to add the option myself but was busier than expected last week.

hedning
hedning approved these changes Oct 6, 2020
Copy link
Contributor

@hedning hedning left a comment

LGTM, should probably be backported too?

@TredwellGit
Copy link
Member

@TredwellGit TredwellGit commented Oct 6, 2020

Please backport since it is really not obvious that this is why scanners do not work.

@worldofpeace worldofpeace merged commit d83e5a1 into NixOS:master Oct 6, 2020
17 checks passed
GNOME automation moved this from In Progress to Done Oct 6, 2020
@worldofpeace
Copy link
Contributor Author

@worldofpeace worldofpeace commented Oct 6, 2020

LGTM, should probably be backported too?

Yep, absolutely.

@worldofpeace worldofpeace deleted the rt-sched-optional-and-off-by-default branch Oct 6, 2020
@worldofpeace
Copy link
Contributor Author

@worldofpeace worldofpeace commented Oct 6, 2020

backported to 20.09 in 001334b

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
GNOME
  
Done
Linked issues

Successfully merging this pull request may close these issues.

None yet

4 participants