Modify protocol initialization callback adding a new parameter representing
a reference to the available xfer core operations and introduce a macro to
simply register with the core new protocols as loadable drivers.
Keep standard protocols as builtin.
Signed-off-by: Cristian Marussi <cristian.marussi@xxxxxxx>
---
drivers/firmware/arm_scmi/base.c | 56 ++++++++++--------
drivers/firmware/arm_scmi/bus.c | 14 ++++-
drivers/firmware/arm_scmi/clock.c | 56 +++++++++---------
drivers/firmware/arm_scmi/common.h | 42 +++++++++-----
drivers/firmware/arm_scmi/driver.c | 50 ++++++++++------
drivers/firmware/arm_scmi/perf.c | 88 +++++++++++++++--------------
drivers/firmware/arm_scmi/power.c | 46 ++++++++-------
drivers/firmware/arm_scmi/reset.c | 46 ++++++++-------
drivers/firmware/arm_scmi/sensors.c | 52 +++++++++--------
drivers/firmware/arm_scmi/system.c | 16 ++++--
include/linux/scmi_protocol.h | 18 +++++-
11 files changed, 288 insertions(+), 196 deletions(-)
diff --git a/drivers/firmware/arm_scmi/base.c b/drivers/firmware/arm_scmi/base.c
index f40821eeb103..8d7214fd2187 100644
--- a/drivers/firmware/arm_scmi/base.c
+++ b/drivers/firmware/arm_scmi/base.c
@@ -15,6 +15,8 @@
#define SCMI_BASE_NUM_SOURCES 1
#define SCMI_BASE_MAX_CMD_ERR_COUNT 1024
+static const struct scmi_xfer_ops *ops;