Bug 97848 - [PATCH] Allow non-bash shells
Summary: [PATCH] Allow non-bash shells
Status: RESOLVED FIXED
Alias: None
Product: pm-utils
Classification: Unclassified
Component: General (show other bugs)
Version: unspecified
Hardware: All Linux (All)
: medium enhancement
Assignee: Richard Hughes
QA Contact:
URL:
Whiteboard:
Keywords: patch
Depends on:
Blocks:
 
Reported: 2016-09-18 13:03 UTC by Mihail Konev
Modified: 2016-09-24 08:24 UTC (History)
0 users

See Also:
i915 platform:
i915 features:


Attachments
The proposed patch (1.38 KB, patch)
2016-09-18 13:03 UTC, Mihail Konev
Details | Splinter Review

Description Mihail Konev 2016-09-18 13:03:54 UTC
Created attachment 126601 [details] [review]
The proposed patch

Pm-suspend would not function with /bin/sh pointing to /bin/dash.
(The machine just stays awake).

There would always be a:

  <date>: performing suspend
  sh: echo: I/O error
  <date>: Awake

in /var/log/pm-suspend.log

Trough editing /usr/lib64/pm-utils/pm-functions, it was learnt that do_suspend() performs an 'echo -n "mem" >/sys/power/state'.

The
  dash -c "echo mem >/sys/power/state"
however, results in system being suspended.

So the fix is not to pass an "-n" to echo.


Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.