summaryrefslogtreecommitdiff
path: root/kvmd/plugins/msd/relay/__init__.py
diff options
context:
space:
mode:
authorMaxim Devaev <[email protected]>2022-07-23 04:41:54 +0300
committerMaxim Devaev <[email protected]>2022-07-24 05:38:26 +0300
commit2eef9bd26394f5f98f1324012a3c77570e80a7e2 (patch)
tree5aef8e1650bc02b0bb65552a5d5f6d45cfb6eec8 /kvmd/plugins/msd/relay/__init__.py
parent06bf0fcd17e58d0a719baed57fca9aa786340237 (diff)
basic msd rw api
Diffstat (limited to 'kvmd/plugins/msd/relay/__init__.py')
-rw-r--r--kvmd/plugins/msd/relay/__init__.py12
1 files changed, 11 insertions, 1 deletions
diff --git a/kvmd/plugins/msd/relay/__init__.py b/kvmd/plugins/msd/relay/__init__.py
index 3c17a1ff..125f5fb9 100644
--- a/kvmd/plugins/msd/relay/__init__.py
+++ b/kvmd/plugins/msd/relay/__init__.py
@@ -49,6 +49,7 @@ from .. import MsdConnectedError
from .. import MsdDisconnectedError
from .. import MsdMultiNotSupported
from .. import MsdCdromNotSupported
+from .. import MsdRwNotSupported
from .. import BaseMsd
from .. import MsdImageWriter
@@ -141,6 +142,7 @@ class Plugin(BaseMsd): # pylint: disable=too-many-instance-attributes
"features": {
"multi": False,
"cdrom": False,
+ "rw": False,
},
}
@@ -178,12 +180,20 @@ class Plugin(BaseMsd): # pylint: disable=too-many-instance-attributes
# =====
@aiotools.atomic
- async def set_params(self, name: Optional[str]=None, cdrom: Optional[bool]=None) -> None:
+ async def set_params(
+ self,
+ name: Optional[str]=None,
+ cdrom: Optional[bool]=None,
+ rw: Optional[bool]=None,
+ ) -> None:
+
async with self.__working():
if name is not None:
raise MsdMultiNotSupported()
if cdrom is not None:
raise MsdCdromNotSupported()
+ if rw is not None:
+ raise MsdRwNotSupported()
@aiotools.atomic
async def set_connected(self, connected: bool) -> None: