From b1e4016c2b7f3148eb5084184a1006426b6609a2 Mon Sep 17 00:00:00 2001 From: Max Becker Date: Tue, 15 Sep 2026 11:21:27 +0200 Subject: [PATCH] mpm: Update X4xx GPIO SPI support Update MPM GPIO handling for the updated X4xx GPIO SPI register interface. Require the FPGA compatibility number bump introduced with the new SPI support so MPM does not operate against an incompatible FPGA image. Bump MPM compat number. --- mpm/python/usrp_mpm/periph_manager/x4xx.py | 2 +- mpm/python/usrp_mpm/periph_manager/x4xx_dio_control.py | 2 +- mpm/python/usrp_mpm/rpc_server.py | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/mpm/python/usrp_mpm/periph_manager/x4xx.py b/mpm/python/usrp_mpm/periph_manager/x4xx.py index 38161bf8b..36d70dd2b 100644 --- a/mpm/python/usrp_mpm/periph_manager/x4xx.py +++ b/mpm/python/usrp_mpm/periph_manager/x4xx.py @@ -39,7 +39,7 @@ from usrp_mpm.sys_utils.sysfs_hwmon import HwmonTempSensors from usrp_mpm.sys_utils.udev import dt_symbol_get_spidev from usrp_mpm.xports import XportMgrUDP -X400_FPGA_COMPAT = (11, 0) +X400_FPGA_COMPAT = (12, 0) # The compat number at which remote streaming was added: X400_REMOTE_STREAMING_COMPAT = (7, 9) # The compat number at which DNA support was added: diff --git a/mpm/python/usrp_mpm/periph_manager/x4xx_dio_control.py b/mpm/python/usrp_mpm/periph_manager/x4xx_dio_control.py index 824ff1315..07fd47959 100644 --- a/mpm/python/usrp_mpm/periph_manager/x4xx_dio_control.py +++ b/mpm/python/usrp_mpm/periph_manager/x4xx_dio_control.py @@ -192,7 +192,7 @@ class DioControl: FPGA_DIO_SW_DIO_CONTROL_REGISTER = FPGA_DIO_REGISTER_BASE + 0x20 FULL_DIO_FPGA_COMPAT = (7, 5) - FULL_SPI_FPGA_COMPAT = (7, 7) + FULL_SPI_FPGA_COMPAT = (12, 0) LINEAR_PIN_MAPPING_COMPAT = (10, 1) # DIO registers addresses in CPLD diff --git a/mpm/python/usrp_mpm/rpc_server.py b/mpm/python/usrp_mpm/rpc_server.py index 7c766c369..254fe8729 100644 --- a/mpm/python/usrp_mpm/rpc_server.py +++ b/mpm/python/usrp_mpm/rpc_server.py @@ -44,7 +44,7 @@ grpc._cython.cygrpc.init_grpc_gevent() TIMEOUT_INTERVAL = 5.0 # Seconds before claim expires (default value) LOCK_ACQ_TIMEOUT = 1 # Seconds to wait for acquiring shared lock (default value) TOKEN_LEN = 16 # Length of the token string -MPM_COMPAT_NUM = (7, 0) # Compatibility number for MPM +MPM_COMPAT_NUM = (8, 0) # Compatibility number for MPM # Maximum gRPC message size (in bytes) to accommodate large FPGA bitfiles while # preventing trivial memory exhaustion / DoS attacks. MAX_GRPC_MESSAGE_SIZE = 128 * 1024 * 1024 # 128 MB in bytes