summaryrefslogtreecommitdiff
path: root/pm
diff options
context:
space:
mode:
authorVictor Lowther <victor.lowther@gmail.com>2009-12-10 22:57:00 -0600
committerVictor Lowther <victor.lowther@gmail.com>2009-12-10 22:58:26 -0600
commitda03ab146c022b685b096ed7fe118eb4bb29ee6e (patch)
tree1f0bd4674698f73bf3684a8851e0425568c5e6bc /pm
parentd92323cbcb3c35896cc2969ff2fa9cb1d8365361 (diff)
Use --quirk-test to override the usual sanity checks.
This can be useful for testing to see if your system requires an unusual set of quirks, but can also make your system crash in new and exciting ways across suspend/resume. You have been warned.
Diffstat (limited to 'pm')
-rwxr-xr-xpm/sleep.d/98-video-quirk-db-handler13
1 files changed, 9 insertions, 4 deletions
diff --git a/pm/sleep.d/98-video-quirk-db-handler b/pm/sleep.d/98-video-quirk-db-handler
index 114cc74..ec8c892 100755
--- a/pm/sleep.d/98-video-quirk-db-handler
+++ b/pm/sleep.d/98-video-quirk-db-handler
@@ -346,7 +346,12 @@ case $1 in
# This logic can also be expressed using entries in the quirkdb,
# but I am too lazy to do that until a final quirk database is
# formalized.
- if using_kms; then
+ if has_parameter --quirk-test && has_video_parameters; then
+ # The user is explicitly testing video parameters.
+ # Use them without the usual filtering. This may cause the system
+ # to blow up, but they explicitly asked for it.
+ remove_parameters --quirk-test
+ elif using_kms; then
# Using kernel modesetting? No quirks, and do not change vts.
remove_parameters $possible_video_quirks
add_parameters --quirk-no-chvt
@@ -367,8 +372,8 @@ case $1 in
else
# Go ahead and get our quirks.
if has_video_parameters; then
- # command line video parameters override everything.
- # Honor them by doing nothing.
+ # Parameters from the command line take precedence
+ # over the database, so do not query it.
:
elif [[ $PM_QUIRKS ]]; then
# If we have $PM_QUIRKS. use it instead of the quirk database
@@ -419,7 +424,7 @@ case $1 in
QUIRKS=$(restorestate video_quirks);
write_last_known_working
elif has_parameter --store-quirks-as-lkw; then
- for x in $(get_paremeters); do
+ for x in $(get_parameters); do
for y in $possible_video_quirks; do
[[ $x = $y ]] && QUIRKS=" $QUIRKS $x"
done