3
À<×eQ ã @ sj d dl Z ddlmZ ddlT d dlZd dljZd dlm Z d dl
Z
d dlZejj
ƒ ZG dd„ dejƒZdS )é Né )Úhotplug)Ú*)Úcommandsc s¾ e Zd ZdZ‡ fdd„Z‡ fdd„Zdd„ Zedd „ ƒZd
d„ Z dd
„ Z
‡ fdd„Z‡ fdd„Z‡ fdd„Z
edd„ ƒZdd„ Zdd„ Zdd„ Zeddd�dd „ ƒZedƒd$d"d#„ƒZ‡ ZS )%ÚSCSIHostPluginaä
`scsi_host`::
Tunes options for SCSI hosts.
+
The plug-in sets Aggressive Link Power Management (ALPM) to the value specified
by the [option]`alpm` option. The option takes one of three values:
`min_power`, `medium_power` and `max_performance`.
+
NOTE: ALPM is only available on SATA controllers that use the Advanced
Host Controller Interface (AHCI).
+
.ALPM setting when extended periods of idle time are expected
====
----
[scsi_host]
alpm=min_power
----
====
c s t t| ƒj||Ž tƒ | _d S )N)Úsuperr Ú__init__r Ú_cmd)ÚselfÚargsÚkwargs)Ú __class__© ú&/usr/lib/python3.6/plugin_scsi_host.pyr " s zSCSIHostPlugin.__init__c sV t t| ƒjƒ d| _tƒ | _x,| jjdƒD ]}| j|ƒr*| jj |j
ƒ q*W tƒ | _d S )NTÚscsi)r r Ú
_init_devicesZ_devices_supportedÚsetZ
_free_devicesÚ_hardware_inventoryZget_devicesÚ_device_is_supportedÚaddZsys_nameZ_assigned_devices)r
Údevice)r
r r r ' s
zSCSIHostPlugin._init_devicesc s ‡ fdd„|D ƒS )Nc s g | ]}ˆ j jd |ƒ‘qS )r )r Z
get_device)Ú.0Úx)r
r r ú