3
À<×eU ã @ s` d dl mZ d dlT ddlZddlmZ ddlZddlZddl Z ej
jƒ ZG dd„ dej
ƒZdS )é )Úbase)Ú*é N)Úcommandsc @ s e Zd ZdZdd„ Zdd„ ZdS )Ú
RTENTSKPluginzË
`rtentsk`::
Plugin for avoiding interruptions due to static key IPIs due
to opening socket with timestamping enabled (by opening a
socket ourselves the static key is kept enabled).
c C sL d|_ d|_d}d}tjtjtjtjƒ}|jtj||ƒ || _t j
dƒ d S )NTFé r é z*opened SOF_TIMESTAMPING_OPT_TX_SWHW socketi @ )Z_has_static_tuningZ_has_dynamic_tuningÚsocketZAF_INETZ
SOCK_DGRAMZIPPROTO_UDPZ
setsockoptZ
SOL_SOCKETÚrtentsk_socketÚlogÚinfo)ÚselfÚinstanceZSO_TIMESTAMPZSOF_TIMESTAMPING_OPT_TX_SWHWÚs© r ú$/usr/lib/python3.6/plugin_rtentsk.pyÚ_instance_init s zRTENTSKPlugin._instance_initc C s | j }|jƒ d S )N)r
Úclose)r
r r r r r Ú_instance_cleanup$ s zRTENTSKPlugin._instance_cleanupN)Ú__name__Ú
__module__Ú__qualname__Ú__doc__r r r r r r r s r )Ú r Z
decoratorsZ
tuned.logsZtunedZtuned.utils.commandsr Zglobr ZtimeZlogsÚgetr ZPluginr r r r r Ú