mirror of
https://github.com/EttusResearch/uhd.git
synced 2026-10-25 17:36:10 +00:00
mpm: n3xx: Don't set time and clock source without dboards
When there are no daughterboards present, clock and time source are meaningless. It's also possible that corresponding FPGA images are not loaded, in which case trying to set those could crash the system. Unless daughterboards are actually present, these settings won't get applied any more.
This commit is contained in:
parent
8ecb09be8b
commit
8ee3da3ef9
@ -229,12 +229,20 @@ class n310(PeriphManagerBase):
|
||||
self._ext_clock_freq = float(
|
||||
default_args.get('ext_clock_freq', N3XX_DEFAULT_EXT_CLOCK_FREQ)
|
||||
)
|
||||
self.set_clock_source(
|
||||
default_args.get('clock_source', N3XX_DEFAULT_CLOCK_SOURCE)
|
||||
)
|
||||
self.set_time_source(
|
||||
default_args.get('time_source', N3XX_DEFAULT_TIME_SOURCE)
|
||||
)
|
||||
if len(self.dboards) == 0:
|
||||
self.log.warning(
|
||||
"No dboards found, skipping setting clock and time source " \
|
||||
"configuration."
|
||||
)
|
||||
self._clock_source = N3XX_DEFAULT_CLOCK_SOURCE
|
||||
self._time_source = N3XX_DEFAULT_TIME_SOURCE
|
||||
else:
|
||||
self.set_clock_source(
|
||||
default_args.get('clock_source', N3XX_DEFAULT_CLOCK_SOURCE)
|
||||
)
|
||||
self.set_time_source(
|
||||
default_args.get('time_source', N3XX_DEFAULT_TIME_SOURCE)
|
||||
)
|
||||
|
||||
def init(self, args):
|
||||
"""
|
||||
|
||||
Loading…
Reference in New Issue
Block a user