Merge ~alextu/pc-enablement/+git/oem-fix-misc-cnl-oem-image-helper:let-ubuntu-drivers-install-decide-default-mode into ~oem-solutions-engineers/pc-enablement/+git/oem-fix-misc-cnl-oem-image-helper:master

Proposed by Alex Tu
Status: Needs review
Proposed branch: ~alextu/pc-enablement/+git/oem-fix-misc-cnl-oem-image-helper:let-ubuntu-drivers-install-decide-default-mode
Merge into: ~oem-solutions-engineers/pc-enablement/+git/oem-fix-misc-cnl-oem-image-helper:master
Diff against target: 40 lines (+20/-11)
1 file modified
usr/sbin/auto-prime-select (+20/-11)
Reviewer Review Type Date Requested Status
OEM Solutions Group: Engineers Pending
Review via email: mp+407343@code.launchpad.net
To post a comment you must log in.

Unmerged commits

954e0c6... by Alex Tu

Obsolete the default mode and counting on ubuntu-drivers install

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1diff --git a/usr/sbin/auto-prime-select b/usr/sbin/auto-prime-select
2index 7e94d29..b86268f 100755
3--- a/usr/sbin/auto-prime-select
4+++ b/usr/sbin/auto-prime-select
5@@ -56,15 +56,24 @@ if [ -n "$BIOS_ID" ]; then
6 grep -iq "$BIOS_ID" "$old_conf" && prime-select nvidia && exit 0
7 fi
8 fi
9-if [ -e "/run/nvidia_runtimepm_supported" ]; then
10- prime-select on-demand
11-else
12- if [ "$chassis_type" = "Desktop" ] || [ "$chassis_type" = "Mini_Tower" ] ||
13- [ "$chassis_type" = "Tower" ] || [ "$chassis_type" = "Main_Server_Chassis" ] ||
14- [ "$chassis_type" = "Rack_Mount_Chassis" ]; then
15- prime-select nvidia
16- else
17- prime-select intel
18- fi
19-fi
20+# After Nvidia supported runtimepm.
21+# And Nvidia is commiting that all new Nvidia dgpu will support runtimepm.
22+# We are counting on `ubuntu-drivers install` which executed before this script
23+# to select the default mode so that we can close OEM gap.
24+# Another important reason counting on `ubuntu-drivers install` to select default mode is because
25+# the maintainer will always implement the logic with the detail requirement from Nvidia release note.
26+# refer to: http://us.download.nvidia.com/XFree86/Linux-x86_64/470.57.02/README/dynamicpowermanagement.html
27+# "This feature is supported only on notebooks. "
28
29+# Obsoleted logic:
30+#if [ -e "/run/nvidia_runtimepm_supported" ]; then
31+# prime-select on-demand
32+#else
33+# if [ "$chassis_type" = "Desktop" ] || [ "$chassis_type" = "Mini_Tower" ] ||
34+# [ "$chassis_type" = "Tower" ] || [ "$chassis_type" = "Main_Server_Chassis" ] ||
35+# [ "$chassis_type" = "Rack_Mount_Chassis" ]; then
36+# prime-select nvidia
37+# else
38+# prime-select intel
39+# fi
40+#fi

Subscribers

People subscribed via source and target branches