ACIL FM
Dark
Refresh
Current DIR:
/lib/python3.9/site-packages/tuned/plugins
/
lib
python3.9
site-packages
tuned
plugins
Upload
Zip Selected
Delete Selected
Pilih semua
Nama
Ukuran
Permission
Aksi
instance
-
chmod
Open
Rename
Delete
__pycache__
-
chmod
Open
Rename
Delete
base.py
22.76 MB
chmod
View
DL
Edit
Rename
Delete
decorators.py
983 B
chmod
View
DL
Edit
Rename
Delete
exceptions.py
99 B
chmod
View
DL
Edit
Rename
Delete
hotplug.py
4.62 MB
chmod
View
DL
Edit
Rename
Delete
plugin_acpi.py
2.39 MB
chmod
View
DL
Edit
Rename
Delete
plugin_audio.py
3.16 MB
chmod
View
DL
Edit
Rename
Delete
plugin_bootloader.py
24.86 MB
chmod
View
DL
Edit
Rename
Delete
plugin_cpu.py
30.58 MB
chmod
View
DL
Edit
Rename
Delete
plugin_disk.py
16.77 MB
chmod
View
DL
Edit
Rename
Delete
plugin_eeepc_she.py
3 MB
chmod
View
DL
Edit
Rename
Delete
plugin_irq.py
9.73 MB
chmod
View
DL
Edit
Rename
Delete
plugin_irqbalance.py
3.54 MB
chmod
View
DL
Edit
Rename
Delete
plugin_modules.py
4.8 MB
chmod
View
DL
Edit
Rename
Delete
plugin_mounts.py
5.44 MB
chmod
View
DL
Edit
Rename
Delete
plugin_net.py
26.38 MB
chmod
View
DL
Edit
Rename
Delete
plugin_rtentsk.py
1.12 MB
chmod
View
DL
Edit
Rename
Delete
plugin_scheduler.py
58.48 MB
chmod
View
DL
Edit
Rename
Delete
plugin_script.py
3.91 MB
chmod
View
DL
Edit
Rename
Delete
plugin_scsi_host.py
3.89 MB
chmod
View
DL
Edit
Rename
Delete
plugin_selinux.py
2.26 MB
chmod
View
DL
Edit
Rename
Delete
plugin_service.py
10.45 MB
chmod
View
DL
Edit
Rename
Delete
plugin_sysctl.py
6.01 MB
chmod
View
DL
Edit
Rename
Delete
plugin_sysfs.py
2.63 MB
chmod
View
DL
Edit
Rename
Delete
plugin_systemd.py
5.32 MB
chmod
View
DL
Edit
Rename
Delete
plugin_uncore.py
5.97 MB
chmod
View
DL
Edit
Rename
Delete
plugin_usb.py
1.97 MB
chmod
View
DL
Edit
Rename
Delete
plugin_video.py
5.97 MB
chmod
View
DL
Edit
Rename
Delete
plugin_vm.py
8.67 MB
chmod
View
DL
Edit
Rename
Delete
repository.py
1.49 MB
chmod
View
DL
Edit
Rename
Delete
__init__.py
49 B
chmod
View
DL
Edit
Rename
Delete
Edit file: /lib/python3.9/site-packages/tuned/plugins/plugin_acpi.py
from . import base from .decorators import * import os import errno import tuned.logs from tuned.consts import ACPI_DIR log = tuned.logs.get() class ACPIPlugin(base.Plugin): """ Configures the ACPI driver. The only currently supported option is [option]`platform_profile`, which sets the ACPI platform profile sysfs attribute, a generic power/performance preference API for other drivers. Multiple profiles can be specified, separated by `|`. The first available profile is selected. .Selecting a platform profile ==== ---- [acpi] platform_profile=balanced|low-power ---- Using this option, *TuneD* will try to set the platform profile to `balanced`. If that fails, it will try to set it to `low-power`. ==== """ def __init__(self, *args, **kwargs): super(ACPIPlugin, self).__init__(*args, **kwargs) @classmethod def _get_config_options(cls): return {"platform_profile": None} def _instance_init(self, instance): instance._has_static_tuning = True instance._has_dynamic_tuning = False def _instance_cleanup(self, instance): pass @classmethod def _platform_profile_choices_path(cls): return os.path.join(ACPI_DIR, "platform_profile_choices") @classmethod def _platform_profile_path(cls): return os.path.join(ACPI_DIR, "platform_profile") @command_set("platform_profile") def _set_platform_profile(self, profiles, instance, sim, remove): if not os.path.isfile(self._platform_profile_path()): log.debug("ACPI platform_profile is not supported on this system") return None profiles = [profile.strip() for profile in profiles.split('|')] avail_profiles = set(self._cmd.read_file(self._platform_profile_choices_path()).split()) for profile in profiles: if profile in avail_profiles: if not sim: log.info("Setting platform_profile to '%s'" % profile) self._cmd.write_to_file(self._platform_profile_path(), profile, \ no_error=[errno.ENOENT] if remove else False) return profile log.warning("Requested platform_profile '%s' unavailable" % profile) log.error("Failed to set platform_profile. Is the value in the profile correct?") return None @command_get("platform_profile") def _get_platform_profile(self, instance, ignore_missing=False): if not os.path.isfile(self._platform_profile_path()): log.debug("ACPI platform_profile is not supported on this system") return None return self._cmd.read_file(self._platform_profile_path()).strip()
Simpan
Batal
Isi Zip:
Unzip
Create
Buat Folder
Buat File
Terminal / Execute
Run
Chmod Bulk
All File
All Folder
All File dan Folder
Apply