mirror of
https://github.com/home-assistant/supervisor.git
synced 2025-07-28 11:36:32 +00:00
Use the cpu_rt support check also for rtprio (#2605)
This commit is contained in:
parent
bb44ce5cd2
commit
e2faf906de
@ -265,7 +265,7 @@ class DockerAddon(DockerInterface):
|
|||||||
limits: List[docker.types.Ulimit] = []
|
limits: List[docker.types.Ulimit] = []
|
||||||
|
|
||||||
# Need schedule functions
|
# Need schedule functions
|
||||||
if self.addon.with_realtime:
|
if self.addon.with_realtime and self.sys_docker.info.support_cpu_realtime:
|
||||||
limits.append(docker.types.Ulimit(name="rtprio", soft=99))
|
limits.append(docker.types.Ulimit(name="rtprio", soft=99))
|
||||||
|
|
||||||
# Return None if no capabilities is present
|
# Return None if no capabilities is present
|
||||||
|
@ -59,6 +59,8 @@ class DockerAudio(DockerInterface, CoreSysAttributes):
|
|||||||
@property
|
@property
|
||||||
def ulimits(self) -> List[docker.types.Ulimit]:
|
def ulimits(self) -> List[docker.types.Ulimit]:
|
||||||
"""Generate ulimits for audio."""
|
"""Generate ulimits for audio."""
|
||||||
|
if not self.sys_docker.info.support_cpu_realtime:
|
||||||
|
return None
|
||||||
return [docker.types.Ulimit(name="rtprio", soft=99)]
|
return [docker.types.Ulimit(name="rtprio", soft=99)]
|
||||||
|
|
||||||
@property
|
@property
|
||||||
|
Loading…
x
Reference in New Issue
Block a user