Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add memnotify plugin for signaling memory pressure level changes
If /dev/memnotify is available the plugin will set up two memory use triggering levels. These are used to determine normal/warning/critical memory pressure situations. The current state can be queried via D-Bus method call "get_memory_level" and changes are broadcast as D-Bus signal "sig_memory_level_ind". Introspect data for new signal and method call is: <node name="/com/nokia/mce/signal"> <interface name="com.nokia.mce.signal"> <signal name="sig_memory_level_ind"> <arg name="memory_level" type="s"/> </signal> </interface> </node> <node name="/com/nokia/mce/request"> <interface name="com.nokia.mce.request"> <method name="get_memory_level"> <arg direction="out" name="memory_level" type="s"/> </method> </interface> </node> While it is up to other components to react to changes in memory pressure, it is expected that on warning level non-essential caches should be released and on critical level non-essential processes should be terminated. As the actual level limits must device specific, the built in config does not specify warning/critical levels. The levels can be specified by installing configuration files to "/etc/mce/<priority><name>.conf". Where priority is two digit number from 00 to 99 (60 is used for other device specific configs) and name should be something unique enough (say, package name). The levels can be adjusted during mce runtime via mcetool options --set-memuse-warning-used=<page_count> --set-memuse-warning-active=<page_count> --set-memuse-critical-used=<page_count> --set-memuse-critical-active=<page_count> The mcetool --status option shows the current memory use level. [mce] Add memnotify plugin for signaling memory pressure level changes. Fixes JB#22490
- Loading branch information
Showing
8 changed files
with
1,266 additions
and
4 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.