Skip to contentSkip to conversation

misc: amd-sbi: Split core driver as separate module

PATCH NAK Akshay Gupta 3 participants 15 messages Jul 28, 2025 – Aug 11, 2025

Subsystems (3)
lore
Share & tools
lore
#0 lore raw

PATCH 1/5 misc: amd-sbi: Split core driver as separate module

This change is in preparation for enabling SB-RMI access over I3C along with present I2C bus.
Split the core APIs into a separate module, export those APIs to be used by the I2C and I3C modules.
Introduce a config option in Kconfig and update Makefile accordingly.

---
 drivers/misc/amd-sbi/Kconfig     | 11 ++++++++++-
 drivers/misc/amd-sbi/Makefile    |  6 ++++--
 drivers/misc/amd-sbi/rmi-core.c  |  5 +++++
 drivers/misc/amd-sbi/rmi-hwmon.c |  4 ++++
 drivers/misc/amd-sbi/rmi-i2c.c   |  1 +
 5 files changed, 24 insertions(+), 3 deletions(-)
drivers/misc/amd-sbi/Kconfig +10 -1
index 4840831c84ca..9b1abeb6ab1a 100644
@@ -1,7 +1,14 @@
 # SPDX-License-Identifier: GPL-2.0-only
+
+menu "AMD side band Interface(APML)"
+
+config AMD_SBRMI
+	bool
+
 config AMD_SBRMI_I2C
-	tristate "AMD side band RMI support"
+	tristate "AMD side band RMI support over I2C"
 	depends on I2C
+	select AMD_SBRMI
 	help
 	  Side band RMI over I2C support for AMD out of band management.
 
@@ -16,3 +23,5 @@ config AMD_SBRMI_HWMON
 	  This provides support for RMI device hardware monitoring. If enabled,
 	  a hardware monitoring device will be created for each socket in
 	  the system.
+
+endmenu
drivers/misc/amd-sbi/Makefile +4 -2
index 38eaaa651fd9..6f3090fb9ff3 100644
@@ -1,4 +1,6 @@
 # SPDX-License-Identifier: GPL-2.0-only
-sbrmi-i2c-objs  		+= rmi-i2c.o rmi-core.o
-sbrmi-i2c-$(CONFIG_AMD_SBRMI_HWMON)	+= rmi-hwmon.o
+obj-$(CONFIG_AMD_SBRMI)		+= sbrmi_core.o
+sbrmi_core-y			:= rmi-core.o
+obj-$(CONFIG_AMD_SBRMI_HWMON)	+= rmi-hwmon.o
+sbrmi-i2c-y			:= rmi-i2c.o
 obj-$(CONFIG_AMD_SBRMI_I2C)	+= sbrmi-i2c.o
drivers/misc/amd-sbi/rmi-core.c +5 -0
index 3dec2fc00124..6a7d0bb33bf8 100644
@@ -352,6 +352,7 @@ int rmi_mailbox_xfer(struct sbrmi_data *data,
 	mutex_unlock(&data->lock);
 	return ret;
 }
+EXPORT_SYMBOL_NS_GPL(rmi_mailbox_xfer, "AMD_SBRMI");
 
 static int apml_rmi_reg_xfer(struct sbrmi_data *data,
 			     struct apml_reg_xfer_msg __user *arg)
@@ -482,3 +483,7 @@ int create_misc_rmi_device(struct sbrmi_data *data,
 
 	return misc_register(&data->sbrmi_misc_dev);
 }
+EXPORT_SYMBOL_NS_GPL(create_misc_rmi_device, "AMD_SBRMI");
+
+MODULE_DESCRIPTION("AMD SB-RMI common driver");
+MODULE_LICENSE("GPL");
drivers/misc/amd-sbi/rmi-hwmon.c +4 -0
index f4f015605daa..e5d234549b5c 100644
@@ -6,6 +6,7 @@
  */
 #include <linux/err.h>
 #include <linux/hwmon.h>
+#include <linux/module.h>
 #include <uapi/misc/amd-apml.h>
 #include "rmi-core.h"
 
@@ -118,3 +119,6 @@ int create_hwmon_sensor_device(struct device *dev, struct sbrmi_data *data)
 							 &sbrmi_chip_info, NULL);
 	return PTR_ERR_OR_ZERO(hwmon_dev);
 }
+EXPORT_SYMBOL(create_hwmon_sensor_device);
+
+MODULE_IMPORT_NS("AMD_SBRMI");
drivers/misc/amd-sbi/rmi-i2c.c +1 -0
index f891f5af4bc6..e90ab0a5f8eb 100644
@@ -127,6 +127,7 @@ static struct i2c_driver sbrmi_driver = {
 
 module_i2c_driver(sbrmi_driver);
 
+MODULE_IMPORT_NS("AMD_SBRMI");
 MODULE_AUTHOR("Akshay Gupta <[email protected]>");
 MODULE_AUTHOR("Naveen Krishna Chatradhi <[email protected]>");
 MODULE_DESCRIPTION("Hwmon driver for AMD SB-RMI emulated sensor");
Signature · 1 line
2.25.1
#1 lore raw

PATCH 2/5 misc: amd-sbi: Add support for SB-RMI over I3C

AMD EPYC platforms with zen5 and later support APML(SB-RMI) connection to the BMC over I3C bus for improved efficiency. Add the same functionality supported by rmi-i2c.c over I3C bus.

---
 drivers/misc/amd-sbi/Kconfig   |  15 +++-
 drivers/misc/amd-sbi/Makefile  |   2 +
 drivers/misc/amd-sbi/rmi-i3c.c | 133 +++++++++++++++++++++++++++++++++
 3 files changed, 148 insertions(+), 2 deletions(-)
 create mode 100644 drivers/misc/amd-sbi/rmi-i3c.c
drivers/misc/amd-sbi/Kconfig +13 -2
index 9b1abeb6ab1a..838cf98805d9 100644
@@ -15,10 +15,21 @@ config AMD_SBRMI_I2C
 	  This driver can also be built as a module. If so, the module will
 	  be called sbrmi-i2c.
 
+config AMD_SBRMI_I3C
+	tristate "AMD side band RMI support over I3C"
+	depends on I3C
+	select AMD_SBRMI
+	select REGMAP_I3C
+	help
+	  Side band RMI over I3C support for AMD out of band management.
+
+	  This driver can also be built as a module. If so, the module will
+	  be called sbrmi-i3c.
+
 config AMD_SBRMI_HWMON
 	bool "SBRMI hardware monitoring"
-	depends on AMD_SBRMI_I2C && HWMON
-	depends on !(AMD_SBRMI_I2C=y && HWMON=m)
+	depends on (AMD_SBRMI_I2C || AMD_SBRMI_I3C) && HWMON
+	depends on !(AMD_SBRMI_I2C=y && HWMON=m) || !(AMD_SBRMI_I3C=y && HWMON=m)
 	help
 	  This provides support for RMI device hardware monitoring. If enabled,
 	  a hardware monitoring device will be created for each socket in
drivers/misc/amd-sbi/Makefile +2 -0
index 6f3090fb9ff3..e43d4058a0f0 100644
@@ -4,3 +4,5 @@ sbrmi_core-y			:= rmi-core.o
 obj-$(CONFIG_AMD_SBRMI_HWMON)	+= rmi-hwmon.o
 sbrmi-i2c-y			:= rmi-i2c.o
 obj-$(CONFIG_AMD_SBRMI_I2C)	+= sbrmi-i2c.o
+sbrmi-i3c-y  			:= rmi-i3c.o
+obj-$(CONFIG_AMD_SBRMI_I3C)	+= sbrmi-i3c.o
drivers/misc/amd-sbi/rmi-i3c.c new file +133 -0

133 lines not on this page · raw message

Signature · 1 line
2.25.1
#2 lore raw

Re: [PATCH v1 2/5] misc: amd-sbi: Add support for SB-RMI over I3C

On 2025-07-28 06:10:30+0000, Akshay Gupta wrote:
(...)

Quoted 6 lines
drivers/misc/amd-sbi/rmi-i3c.c new file +0 -0
new file mode 100644
index 000000000000..b960743afad1

drivers/misc/amd-sbi/rmi-i3c.c line 9

Quoted 9 lines
drivers/misc/amd-sbi/rmi-i3c.c new file +9 -0
@@ -0,0 +1,133 @@
+// SPDX-License-Identifier: GPL-2.0-or-later
+/*
+ * rmi-i3c.c - Side band RMI over I3C support for AMD out
+ *             of band management
+ *
+ * Copyright (C) 2025 Advanced Micro Devices, Inc.
+ */
+
+#include <linux/delay.h>

Unnecessary include.

drivers/misc/amd-sbi/rmi-i3c.c line 16

Quoted 7 lines
drivers/misc/amd-sbi/rmi-i3c.c new file +7 -0
+#include <linux/err.h>
+#include <linux/i3c/device.h>
+#include <linux/i3c/master.h>
+#include <linux/init.h>
+#include <linux/module.h>
+#include <linux/mutex.h>
+#include <linux/of.h>

Ditto.

Quoted 6 lines
drivers/misc/amd-sbi/rmi-i3c.c new file +6 -0
+#include <linux/regmap.h>
+#include "rmi-core.h"
+
+static int sbrmi_enable_alert(struct sbrmi_data *data)
+{
+	int ctrl, ret;

drivers/misc/amd-sbi/rmi-i3c.c line 32

Quoted 10 lines
drivers/misc/amd-sbi/rmi-i3c.c new file +10 -0
+
+	/*
+	 * Enable the SB-RMI Software alert status
+	 * by writing 0 to bit 4 of Control register(0x1)
+	 */
+	ret = regmap_read(data->regmap, SBRMI_CTRL, &ctrl);
+	if (ret < 0)
+		return ret;
+
+	if (ctrl & 0x10) {

Magic value? Use a define.

Quoted 14 lines
drivers/misc/amd-sbi/rmi-i3c.c new file +14 -0
+		ctrl &= ~0x10;
+		return regmap_write(data->regmap, SBRMI_CTRL, ctrl);
+	}
+
+	return 0;
+}
+
+static int sbrmi_get_max_pwr_limit(struct sbrmi_data *data)
+{
+	struct apml_mbox_msg msg = { 0 };
+	int ret;
+
+	msg.cmd = SBRMI_READ_PKG_MAX_PWR_LIMIT;
+	ret = rmi_mailbox_xfer(data, &msg);

drivers/misc/amd-sbi/rmi-i3c.c line 56

Quoted 10 lines
drivers/misc/amd-sbi/rmi-i3c.c new file +10 -0
+	if (ret < 0)
+		return ret;
+	data->pwr_limit_max = msg.mb_in_out;
+
+	return ret;
+}
+
+static int sbrmi_i3c_probe(struct i3c_device *i3cdev)
+{
+	struct device *dev = &i3cdev->dev;

i3cdev_to_dev();

drivers/misc/amd-sbi/rmi-i3c.c line 68

Quoted 12 lines
drivers/misc/amd-sbi/rmi-i3c.c new file +12 -0
+	struct sbrmi_data *data;
+	struct regmap_config sbrmi_i3c_regmap_config = {
+		.reg_bits = 8,
+		.val_bits = 8,
+	};
+	int ret;
+
+	data = devm_kzalloc(dev, sizeof(struct sbrmi_data), GFP_KERNEL);
+	if (!data)
+		return -ENOMEM;
+
+	mutex_init(&data->lock);

devm_mutex_init().

Quoted 14 lines
drivers/misc/amd-sbi/rmi-i3c.c new file +14 -0
+
+	data->regmap = devm_regmap_init_i3c(i3cdev, &sbrmi_i3c_regmap_config);
+	if (IS_ERR(data->regmap))
+		return PTR_ERR(data->regmap);
+
+	/* Enable alert for SB-RMI sequence */
+	ret = sbrmi_enable_alert(data);
+	if (ret < 0)
+		return ret;
+
+	/* Cache maximum power limit */
+	ret = sbrmi_get_max_pwr_limit(data);
+	if (ret < 0)
+		return ret;

drivers/misc/amd-sbi/rmi-i3c.c line 92

Quoted 10 lines
drivers/misc/amd-sbi/rmi-i3c.c new file +10 -0
+
+	/*
+	 * AMD APML I3C devices support static address
+	 */
+	if (i3cdev->desc->info.static_addr)
+		data->dev_static_addr = i3cdev->desc->info.static_addr;
+	else
+		data->dev_static_addr = i3cdev->desc->info.dyn_addr;
+
+	dev_set_drvdata(dev, data);

If you get rid of _remove(), then this can go away.

drivers/misc/amd-sbi/rmi-i3c.c line 94

Quoted 2 lines
drivers/misc/amd-sbi/rmi-i3c.c new file +2 -0
+
+	ret = create_hwmon_sensor_device(dev, data);

That's a very generic name to have exported.

drivers/misc/amd-sbi/rmi-i3c.c line 104

Quoted 10 lines
drivers/misc/amd-sbi/rmi-i3c.c new file +10 -0
+	if (ret < 0)
+		return ret;
+	return create_misc_rmi_device(data, dev);
+}
+
+static void sbrmi_i3c_remove(struct i3c_device *i3cdev)
+{
+	struct sbrmi_data *data = dev_get_drvdata(&i3cdev->dev);
+
+	misc_deregister(&data->sbrmi_misc_dev);

create_misc_rmi_device() could use devm_add_action_or_reset() for the misc deregister, simplifying the drivers code.

drivers/misc/amd-sbi/rmi-i3c.c line 107

Quoted 3 lines
drivers/misc/amd-sbi/rmi-i3c.c new file +3 -0
+	/* Assign fops and parent of misc dev to NULL */
+	data->sbrmi_misc_dev.fops = NULL;
+	data->sbrmi_misc_dev.parent = NULL;

Why are these two needed? The data is freed anyways right after.

drivers/misc/amd-sbi/rmi-i3c.c line 108

Quoted 1 line
drivers/misc/amd-sbi/rmi-i3c.c new file +1 -0
+	dev_info(&i3cdev->dev, "Removed sbrmi-i3c driver\n");

Unnecessary.

Quoted 9 lines
drivers/misc/amd-sbi/rmi-i3c.c new file +9 -0
+}
+
+static const struct i3c_device_id sbrmi_i3c_id[] = {
+	/* PID for AMD SBRMI device */
+	I3C_DEVICE_EXTRA_INFO(0x112, 0x0, 0x2, NULL),
+	{}
+};
+MODULE_DEVICE_TABLE(i3c, sbrmi_i3c_id);
+

drivers/misc/amd-sbi/rmi-i3c.c line 127

Quoted 10 lines
drivers/misc/amd-sbi/rmi-i3c.c new file +10 -0
+static struct i3c_driver sbrmi_i3c_driver = {
+	.driver = {
+		.name = "sbrmi-i3c",
+	},
+	.probe = sbrmi_i3c_probe,
+	.remove = sbrmi_i3c_remove,
+	.id_table = sbrmi_i3c_id,
+};
+
+module_i3c_driver(sbrmi_i3c_driver);

You could have the i2c and i3c drivers in the same module using module_i3c_i2c_driver().

Quoted 9 lines
drivers/misc/amd-sbi/rmi-i3c.c new file +6 -0
+
+MODULE_IMPORT_NS("AMD_SBRMI");
+MODULE_AUTHOR("Akshay Gupta <[email protected]>");
+MODULE_AUTHOR("Naveen Krishna Chatradhi <[email protected]>");
+MODULE_DESCRIPTION("AMD SB-RMI driver over I3C");
+MODULE_LICENSE("GPL");
Signature · 1 line
2.25.1
#3 lore raw

Re: [PATCH v1 2/5] misc: amd-sbi: Add support for SB-RMI over I3C

Quoted 6 lines · Thomas Weißschuh

Caution: This message originated from an External Source. Use proper caution when opening attachments, clicking links, or responding.

On 2025-07-28 06:10:30+0000, Akshay Gupta wrote:
(...)

Quoted 16 lines
Quoted 6 lines
drivers/misc/amd-sbi/rmi-i3c.c new file +0 -0
new file mode 100644
index 000000000000..b960743afad1

drivers/misc/amd-sbi/rmi-i3c.c line 9

Quoted 9 lines
drivers/misc/amd-sbi/rmi-i3c.c new file +9 -0
@@ -0,0 +1,133 @@
+// SPDX-License-Identifier: GPL-2.0-or-later
+/*
+ * rmi-i3c.c - Side band RMI over I3C support for AMD out
+ *             of band management
+ *
+ * Copyright (C) 2025 Advanced Micro Devices, Inc.
+ */
+
+#include <linux/delay.h>

Unnecessary include.

Ack, will remove. Thank you.

Quoted 8 lines

drivers/misc/amd-sbi/rmi-i3c.c line 16

Quoted 7 lines
drivers/misc/amd-sbi/rmi-i3c.c new file +7 -0
+#include <linux/err.h>
+#include <linux/i3c/device.h>
+#include <linux/i3c/master.h>
+#include <linux/init.h>
+#include <linux/module.h>
+#include <linux/mutex.h>
+#include <linux/of.h>

Ditto.

Ack, will remove.

Quoted 10 lines
Quoted 10 lines
drivers/misc/amd-sbi/rmi-i3c.c new file +9 -0
+#include <linux/regmap.h>
+#include "rmi-core.h"
+
+static int sbrmi_enable_alert(struct sbrmi_data *data)
+{
+     int ctrl, ret;
+
+     /*
+      * Enable the SB-RMI Software alert status
Quoted 8 lines

drivers/misc/amd-sbi/rmi-i3c.c line 32

Quoted 7 lines
drivers/misc/amd-sbi/rmi-i3c.c new file +7 -0
+      * by writing 0 to bit 4 of Control register(0x1)
+      */
+     ret = regmap_read(data->regmap, SBRMI_CTRL, &ctrl);
+     if (ret < 0)
+             return ret;
+
+     if (ctrl & 0x10) {

Magic value? Use a define.

Ack, will create #define

Quoted 17 lines
Quoted 17 lines
drivers/misc/amd-sbi/rmi-i3c.c new file +17 -0
+             ctrl &= ~0x10;
+             return regmap_write(data->regmap, SBRMI_CTRL, ctrl);
+     }
+
+     return 0;
+}
+
+static int sbrmi_get_max_pwr_limit(struct sbrmi_data *data)
+{
+     struct apml_mbox_msg msg = { 0 };
+     int ret;
+
+     msg.cmd = SBRMI_READ_PKG_MAX_PWR_LIMIT;
+     ret = rmi_mailbox_xfer(data, &msg);
+     if (ret < 0)
+             return ret;
+     data->pwr_limit_max = msg.mb_in_out;
Quoted 8 lines

drivers/misc/amd-sbi/rmi-i3c.c line 56

Quoted 7 lines
drivers/misc/amd-sbi/rmi-i3c.c new file +7 -0
+
+     return ret;
+}
+
+static int sbrmi_i3c_probe(struct i3c_device *i3cdev)
+{
+     struct device *dev = &i3cdev->dev;

i3cdev_to_dev();

Ack, will update.

Quoted 14 lines

drivers/misc/amd-sbi/rmi-i3c.c line 68

Quoted 13 lines
drivers/misc/amd-sbi/rmi-i3c.c new file +12 -0
+     struct sbrmi_data *data;
+     struct regmap_config sbrmi_i3c_regmap_config = {
+             .reg_bits = 8,
+             .val_bits = 8,
+     };
+     int ret;
+
+     data = devm_kzalloc(dev, sizeof(struct sbrmi_data), GFP_KERNEL);
+     if (!data)
+             return -ENOMEM;
+
+     mutex_init(&data->lock);

devm_mutex_init().

Will address with new patch to use guard(mutex)

Quoted 26 lines
Quoted 14 lines
drivers/misc/amd-sbi/rmi-i3c.c new file +14 -0
+
+     data->regmap = devm_regmap_init_i3c(i3cdev, &sbrmi_i3c_regmap_config);
+     if (IS_ERR(data->regmap))
+             return PTR_ERR(data->regmap);
+
+     /* Enable alert for SB-RMI sequence */
+     ret = sbrmi_enable_alert(data);
+     if (ret < 0)
+             return ret;
+
+     /* Cache maximum power limit */
+     ret = sbrmi_get_max_pwr_limit(data);
+     if (ret < 0)
+             return ret;

drivers/misc/amd-sbi/rmi-i3c.c line 92

Quoted 10 lines
drivers/misc/amd-sbi/rmi-i3c.c new file +10 -0
+
+     /*
+      * AMD APML I3C devices support static address
+      */
+     if (i3cdev->desc->info.static_addr)
+             data->dev_static_addr = i3cdev->desc->info.static_addr;
+     else
+             data->dev_static_addr = i3cdev->desc->info.dyn_addr;
+
+     dev_set_drvdata(dev, data);

If you get rid of _remove(), then this can go away.

Quoted 3 lines

drivers/misc/amd-sbi/rmi-i3c.c line 94

Quoted 2 lines
drivers/misc/amd-sbi/rmi-i3c.c new file +2 -0
+
+     ret = create_hwmon_sensor_device(dev, data);

That's a very generic name to have exported.

Will create separate patch to address this as this is used by i2c driver.

Quoted 13 lines

drivers/misc/amd-sbi/rmi-i3c.c line 104

Quoted 11 lines
drivers/misc/amd-sbi/rmi-i3c.c new file +10 -0
+     if (ret < 0)
+             return ret;
+     return create_misc_rmi_device(data, dev);
+}
+
+static void sbrmi_i3c_remove(struct i3c_device *i3cdev)
+{
+     struct sbrmi_data *data = dev_get_drvdata(&i3cdev->dev);
+
+     misc_deregister(&data->sbrmi_misc_dev);

create_misc_rmi_device() could use devm_add_action_or_reset() for the misc deregister, simplifying the drivers code.

Ack , will update.

Quoted 5 lines

drivers/misc/amd-sbi/rmi-i3c.c line 107

Quoted 4 lines
drivers/misc/amd-sbi/rmi-i3c.c new file +3 -0
+     /* Assign fops and parent of misc dev to NULL */
+     data->sbrmi_misc_dev.fops = NULL;
+     data->sbrmi_misc_dev.parent = NULL;

Why are these two needed? The data is freed anyways right after.

Ack, will update.

Quoted 3 lines

drivers/misc/amd-sbi/rmi-i3c.c line 108

Quoted 2 lines
drivers/misc/amd-sbi/rmi-i3c.c new file +1 -0
+     dev_info(&i3cdev->dev, "Removed sbrmi-i3c driver\n");

Unnecessary.

Ack.

Quoted 14 lines
Quoted 14 lines
drivers/misc/amd-sbi/rmi-i3c.c new file +13 -0
+}
+
+static const struct i3c_device_id sbrmi_i3c_id[] = {
+     /* PID for AMD SBRMI device */
+     I3C_DEVICE_EXTRA_INFO(0x112, 0x0, 0x2, NULL),
+     {}
+};
+MODULE_DEVICE_TABLE(i3c, sbrmi_i3c_id);
+
+static struct i3c_driver sbrmi_i3c_driver = {
+     .driver = {
+             .name = "sbrmi-i3c",
+     },
Quoted 8 lines

drivers/misc/amd-sbi/rmi-i3c.c line 127

Quoted 6 lines
drivers/misc/amd-sbi/rmi-i3c.c new file +6 -0
+     .probe = sbrmi_i3c_probe,
+     .remove = sbrmi_i3c_remove,
+     .id_table = sbrmi_i3c_id,
+};
+
+module_i3c_driver(sbrmi_i3c_driver);

You could have the i2c and i3c drivers in the same module using module_i3c_i2c_driver().

Idea was to keep I2C and I3C separate as the drivers will become complex with

new platform specific changes related to register address size.

I will update the existing i2c driver for now.

Quoted 9 lines
Quoted 9 lines
drivers/misc/amd-sbi/rmi-i3c.c new file +6 -1
+
+MODULE_IMPORT_NS("AMD_SBRMI");
+MODULE_AUTHOR("Akshay Gupta <[email protected]>");
+MODULE_AUTHOR("Naveen Krishna Chatradhi <[email protected]>");
+MODULE_DESCRIPTION("AMD SB-RMI driver over I3C");
+MODULE_LICENSE("GPL");
--

2.25.1

#4 lore raw

Re: [PATCH v1 2/5] misc: amd-sbi: Add support for SB-RMI over I3C

In reply to Akshay Gupta
Quoted 63 lines · Akshay Gupta

AMD EPYC platforms with zen5 and later support APML(SB-RMI) connection to the BMC over I3C bus for improved efficiency. Add the same functionality supported by rmi-i2c.c over I3C bus.

---
 drivers/misc/amd-sbi/Kconfig   |  15 +++-
 drivers/misc/amd-sbi/Makefile  |   2 +
 drivers/misc/amd-sbi/rmi-i3c.c | 133 +++++++++++++++++++++++++++++++++
 3 files changed, 148 insertions(+), 2 deletions(-)
 create mode 100644 drivers/misc/amd-sbi/rmi-i3c.c
drivers/misc/amd-sbi/Kconfig +13 -2
index 9b1abeb6ab1a..838cf98805d9 100644
@@ -15,10 +15,21 @@ config AMD_SBRMI_I2C
 	  This driver can also be built as a module. If so, the module will
 	  be called sbrmi-i2c.
 
+config AMD_SBRMI_I3C
+	tristate "AMD side band RMI support over I3C"
+	depends on I3C
+	select AMD_SBRMI
+	select REGMAP_I3C
+	help
+	  Side band RMI over I3C support for AMD out of band management.
+
+	  This driver can also be built as a module. If so, the module will
+	  be called sbrmi-i3c.
+
 config AMD_SBRMI_HWMON
 	bool "SBRMI hardware monitoring"
-	depends on AMD_SBRMI_I2C && HWMON
-	depends on !(AMD_SBRMI_I2C=y && HWMON=m)
+	depends on (AMD_SBRMI_I2C || AMD_SBRMI_I3C) && HWMON
+	depends on !(AMD_SBRMI_I2C=y && HWMON=m) || !(AMD_SBRMI_I3C=y && HWMON=m)
 	help
 	  This provides support for RMI device hardware monitoring. If enabled,
 	  a hardware monitoring device will be created for each socket in
drivers/misc/amd-sbi/Makefile +2 -0
index 6f3090fb9ff3..e43d4058a0f0 100644
@@ -4,3 +4,5 @@ sbrmi_core-y			:= rmi-core.o
 obj-$(CONFIG_AMD_SBRMI_HWMON)	+= rmi-hwmon.o
 sbrmi-i2c-y			:= rmi-i2c.o
 obj-$(CONFIG_AMD_SBRMI_I2C)	+= sbrmi-i2c.o
+sbrmi-i3c-y  			:= rmi-i3c.o
+obj-$(CONFIG_AMD_SBRMI_I3C)	+= sbrmi-i3c.o
drivers/misc/amd-sbi/rmi-i3c.c new file +6 -0
new file mode 100644
index 000000000000..b960743afad1
@@ -0,0 +1,133 @@
+// SPDX-License-Identifier: GPL-2.0-or-later
+/*
+ * rmi-i3c.c - Side band RMI over I3C support for AMD out
+ *             of band management
+ *
+ * Copyright (C) 2025 Advanced Micro Devices, Inc.

drivers/misc/amd-sbi/rmi-i3c.c line 16

Quoted 10 lines
drivers/misc/amd-sbi/rmi-i3c.c new file +10 -0
+ */
+
+#include <linux/delay.h>
+#include <linux/err.h>
+#include <linux/i3c/device.h>
+#include <linux/i3c/master.h>
+#include <linux/init.h>
+#include <linux/module.h>
+#include <linux/mutex.h>
+#include <linux/of.h>

Where do you use it?

Quoted 2 lines
drivers/misc/amd-sbi/rmi-i3c.c new file +2 -0
+#include <linux/regmap.h>
+#include "rmi-core.h"

...

drivers/misc/amd-sbi/rmi-i3c.c line 64

Quoted 11 lines
drivers/misc/amd-sbi/rmi-i3c.c new file +11 -0
+static int sbrmi_i3c_probe(struct i3c_device *i3cdev)
+{
+	struct device *dev = &i3cdev->dev;
+	struct sbrmi_data *data;
+	struct regmap_config sbrmi_i3c_regmap_config = {
+		.reg_bits = 8,
+		.val_bits = 8,
+	};
+	int ret;
+
+	data = devm_kzalloc(dev, sizeof(struct sbrmi_data), GFP_KERNEL);

sizeof(*). Use recent coding style, not some old, downstream code.

Quoted 34 lines
drivers/misc/amd-sbi/rmi-i3c.c new file +34 -0
+	if (!data)
+		return -ENOMEM;
+
+	mutex_init(&data->lock);
+
+	data->regmap = devm_regmap_init_i3c(i3cdev, &sbrmi_i3c_regmap_config);
+	if (IS_ERR(data->regmap))
+		return PTR_ERR(data->regmap);
+
+	/* Enable alert for SB-RMI sequence */
+	ret = sbrmi_enable_alert(data);
+	if (ret < 0)
+		return ret;
+
+	/* Cache maximum power limit */
+	ret = sbrmi_get_max_pwr_limit(data);
+	if (ret < 0)
+		return ret;
+
+	/*
+	 * AMD APML I3C devices support static address
+	 */
+	if (i3cdev->desc->info.static_addr)
+		data->dev_static_addr = i3cdev->desc->info.static_addr;
+	else
+		data->dev_static_addr = i3cdev->desc->info.dyn_addr;
+
+	dev_set_drvdata(dev, data);
+
+	ret = create_hwmon_sensor_device(dev, data);
+	if (ret < 0)
+		return ret;
+	return create_misc_rmi_device(data, dev);
+}

drivers/misc/amd-sbi/rmi-i3c.c line 108

Quoted 10 lines
drivers/misc/amd-sbi/rmi-i3c.c new file +10 -0
+
+static void sbrmi_i3c_remove(struct i3c_device *i3cdev)
+{
+	struct sbrmi_data *data = dev_get_drvdata(&i3cdev->dev);
+
+	misc_deregister(&data->sbrmi_misc_dev);
+	/* Assign fops and parent of misc dev to NULL */
+	data->sbrmi_misc_dev.fops = NULL;
+	data->sbrmi_misc_dev.parent = NULL;
+	dev_info(&i3cdev->dev, "Removed sbrmi-i3c driver\n");

No, drop. This is useless.

Best regards,
Krzysztof

#5 lore raw

Re: [PATCH v1 2/5] misc: amd-sbi: Add support for SB-RMI over I3C

Quoted 70 lines · Krzysztof Kozlowski

Caution: This message originated from an External Source. Use proper caution when opening attachments, clicking links, or responding.

Quoted 66 lines · Akshay Gupta

AMD EPYC platforms with zen5 and later support APML(SB-RMI) connection to the BMC over I3C bus for improved efficiency. Add the same functionality supported by rmi-i2c.c over I3C bus.

---
  drivers/misc/amd-sbi/Kconfig   |  15 +++-
  drivers/misc/amd-sbi/Makefile  |   2 +
  drivers/misc/amd-sbi/rmi-i3c.c | 133 +++++++++++++++++++++++++++++++++
  3 files changed, 148 insertions(+), 2 deletions(-)

create mode 100644 drivers/misc/amd-sbi/rmi-i3c.c

drivers/misc/amd-sbi/Kconfig +13 -2
index 9b1abeb6ab1a..838cf98805d9 100644
@@ -15,10 +15,21 @@ config AMD_SBRMI_I2C
         This driver can also be built as a module. If so, the module will
         be called sbrmi-i2c.
 
+config AMD_SBRMI_I3C
+     tristate "AMD side band RMI support over I3C"
+     depends on I3C
+     select AMD_SBRMI
+     select REGMAP_I3C
+     help
+       Side band RMI over I3C support for AMD out of band management.
+
+       This driver can also be built as a module. If so, the module will
+       be called sbrmi-i3c.
+
  config AMD_SBRMI_HWMON
       bool "SBRMI hardware monitoring"
-     depends on AMD_SBRMI_I2C && HWMON
-     depends on !(AMD_SBRMI_I2C=y && HWMON=m)
+     depends on (AMD_SBRMI_I2C || AMD_SBRMI_I3C) && HWMON
+     depends on !(AMD_SBRMI_I2C=y && HWMON=m) || !(AMD_SBRMI_I3C=y && HWMON=m)
       help
         This provides support for RMI device hardware monitoring. If enabled,
         a hardware monitoring device will be created for each socket in
drivers/misc/amd-sbi/Makefile +2 -0
index 6f3090fb9ff3..e43d4058a0f0 100644
@@ -4,3 +4,5 @@ sbrmi_core-y                  := rmi-core.o
  obj-$(CONFIG_AMD_SBRMI_HWMON)        += rmi-hwmon.o
  sbrmi-i2c-y                  := rmi-i2c.o
  obj-$(CONFIG_AMD_SBRMI_I2C)  += sbrmi-i2c.o
+sbrmi-i3c-y                          := rmi-i3c.o
+obj-$(CONFIG_AMD_SBRMI_I3C)  += sbrmi-i3c.o
drivers/misc/amd-sbi/rmi-i3c.c new file +9 -0
new file mode 100644
index 000000000000..b960743afad1
@@ -0,0 +1,133 @@
+// SPDX-License-Identifier: GPL-2.0-or-later
+/*
+ * rmi-i3c.c - Side band RMI over I3C support for AMD out
+ *             of band management
+ *
+ * Copyright (C) 2025 Advanced Micro Devices, Inc.
+ */
+
+#include <linux/delay.h>
Quoted 8 lines

drivers/misc/amd-sbi/rmi-i3c.c line 16

Quoted 7 lines
drivers/misc/amd-sbi/rmi-i3c.c new file +7 -0
+#include <linux/err.h>
+#include <linux/i3c/device.h>
+#include <linux/i3c/master.h>
+#include <linux/init.h>
+#include <linux/module.h>
+#include <linux/mutex.h>
+#include <linux/of.h>

Where do you use it?

Ack, will remove.

Quoted 6 lines
Quoted 3 lines
drivers/misc/amd-sbi/rmi-i3c.c new file +2 -0
+#include <linux/regmap.h>
+#include "rmi-core.h"

...

Quoted 12 lines

drivers/misc/amd-sbi/rmi-i3c.c line 64

Quoted 11 lines
drivers/misc/amd-sbi/rmi-i3c.c new file +11 -0
+static int sbrmi_i3c_probe(struct i3c_device *i3cdev)
+{
+     struct device *dev = &i3cdev->dev;
+     struct sbrmi_data *data;
+     struct regmap_config sbrmi_i3c_regmap_config = {
+             .reg_bits = 8,
+             .val_bits = 8,
+     };
+     int ret;
+
+     data = devm_kzalloc(dev, sizeof(struct sbrmi_data), GFP_KERNEL);

sizeof(*). Use recent coding style, not some old, downstream code.

Ack, will update.

Quoted 38 lines
Quoted 38 lines
drivers/misc/amd-sbi/rmi-i3c.c new file +37 -0
+     if (!data)
+             return -ENOMEM;
+
+     mutex_init(&data->lock);
+
+     data->regmap = devm_regmap_init_i3c(i3cdev, &sbrmi_i3c_regmap_config);
+     if (IS_ERR(data->regmap))
+             return PTR_ERR(data->regmap);
+
+     /* Enable alert for SB-RMI sequence */
+     ret = sbrmi_enable_alert(data);
+     if (ret < 0)
+             return ret;
+
+     /* Cache maximum power limit */
+     ret = sbrmi_get_max_pwr_limit(data);
+     if (ret < 0)
+             return ret;
+
+     /*
+      * AMD APML I3C devices support static address
+      */
+     if (i3cdev->desc->info.static_addr)
+             data->dev_static_addr = i3cdev->desc->info.static_addr;
+     else
+             data->dev_static_addr = i3cdev->desc->info.dyn_addr;
+
+     dev_set_drvdata(dev, data);
+
+     ret = create_hwmon_sensor_device(dev, data);
+     if (ret < 0)
+             return ret;
+     return create_misc_rmi_device(data, dev);
+}
+
+static void sbrmi_i3c_remove(struct i3c_device *i3cdev)
+{
Quoted 8 lines

drivers/misc/amd-sbi/rmi-i3c.c line 108

Quoted 7 lines
drivers/misc/amd-sbi/rmi-i3c.c new file +7 -0
+     struct sbrmi_data *data = dev_get_drvdata(&i3cdev->dev);
+
+     misc_deregister(&data->sbrmi_misc_dev);
+     /* Assign fops and parent of misc dev to NULL */
+     data->sbrmi_misc_dev.fops = NULL;
+     data->sbrmi_misc_dev.parent = NULL;
+     dev_info(&i3cdev->dev, "Removed sbrmi-i3c driver\n");

No, drop. This is useless.

Ack, will update.

Quoted 5 lines

Best regards,
Krzysztof

#6 lore raw

PATCH 3/5 dt-bindings: misc: Move amd,sbrmi.yaml from hwmon to misc

In reply to Akshay Gupta

- AMD SB-RMI patches are moved from drivers/hwmon to drivers/misc to support additional functionality. Move the related bindings documentation files to misc.

---
 Documentation/devicetree/bindings/{hwmon => misc}/amd,sbrmi.yaml | 0
 1 file changed, 0 insertions(+), 0 deletions(-)
 rename Documentation/devicetree/bindings/{hwmon => misc}/amd,sbrmi.yaml (100%)
Documentation/devicetree/bindings/misc/amd,sbrmi.yaml renamed from Documentation/devicetree/bindings/hwmon/amd,sbrmi.yaml +0 -0
similarity index 100%
rename from Documentation/devicetree/bindings/hwmon/amd,sbrmi.yaml
rename to Documentation/devicetree/bindings/misc/amd,sbrmi.yaml
Signature · 1 line
2.25.1
#7 lore raw

Re: [PATCH v1 3/5] dt-bindings: misc: Move amd,sbrmi.yaml from hwmon to misc

Quoted 5 lines · Akshay Gupta

- AMD SB-RMI patches are moved from drivers/hwmon to drivers/misc to support additional functionality. Move the related bindings documentation files to misc.

Really? What was reviewed here exactly? Poor style of commit msg or that rename actually does rename?

Quoted 3 lines
---
 Documentation/devicetree/bindings/{hwmon => misc}/amd,sbrmi.yaml | 0

We don't put bindings into MISC.

<form letter>
Please use scripts/get_maintainers.pl to get a list of necessary people and lists to CC. It might happen, that command when run on an older kernel, gives you outdated entries. Therefore please be sure you base your patches on recent Linux kernel.

Tools like b4 or scripts/get_maintainer.pl provide you proper list of people, so fix your workflow. Tools might also fail if you work on some ancient tree (don't, instead use mainline) or work on fork of kernel (don't, instead use mainline). Just use b4 and everything should be fine, although remember about b4 prep --auto-to-cc if you added new patches to the patchset.

You missed at least devicetree list (maybe more), so this won't be tested by automated tooling. Performing review on untested code might be a waste of time.

Please kindly resend and include all necessary To/Cc entries. </form letter>

Best regards,
Krzysztof

#8 lore raw

Re: [PATCH v1 3/5] dt-bindings: misc: Move amd,sbrmi.yaml from hwmon to misc

Quoted 8 lines · Krzysztof Kozlowski

Caution: This message originated from an External Source. Use proper caution when opening attachments, clicking links, or responding.

Quoted 4 lines · Akshay Gupta

- AMD SB-RMI patches are moved from drivers/hwmon to drivers/misc to support additional functionality. Move the related bindings documentation files to misc.

Quoted 8 lines
Quoted 1 line

Really? What was reviewed here exactly? Poor style of commit msg or that rename actually does rename?

Quoted 3 lines
---
  Documentation/devicetree/bindings/{hwmon => misc}/amd,sbrmi.yaml | 0

We don't put bindings into MISC.

We moved the SB-RMI driver from hwmon to misc, and hence moved the binding documentation.

Referred the newly added yaml file, ti,fpc202.yaml through commit in the misc bindings.

If Documentation/devicetree/bindings/misc is not right path, can you please suggest the correct path for bindings for drivers in misc?

thank you.

Quoted 18 lines

<form letter>
Please use scripts/get_maintainers.pl to get a list of necessary people and lists to CC. It might happen, that command when run on an older kernel, gives you outdated entries. Therefore please be sure you base your patches on recent Linux kernel.

Tools like b4 or scripts/get_maintainer.pl provide you proper list of people, so fix your workflow. Tools might also fail if you work on some ancient tree (don't, instead use mainline) or work on fork of kernel (don't, instead use mainline). Just use b4 and everything should be fine, although remember about b4 prep --auto-to-cc if you added new patches to the patchset.

You missed at least devicetree list (maybe more), so this won't be tested by automated tooling. Performing review on untested code might be a waste of time.

Quoted 8 lines

Please kindly resend and include all necessary To/Cc entries. </form letter>

Best regards,
Krzysztof

Sorry, will take care of this.

#9 lore raw

Re: [PATCH v1 3/5] dt-bindings: misc: Move amd,sbrmi.yaml from hwmon to misc

Quoted 19 lines · Akshay
Quoted 8 lines · Krzysztof Kozlowski

Caution: This message originated from an External Source. Use proper caution when opening attachments, clicking links, or responding.

Quoted 4 lines · Akshay Gupta

- AMD SB-RMI patches are moved from drivers/hwmon to drivers/misc to support additional functionality. Move the related bindings documentation files to misc.

Quoted 8 lines
Quoted 1 line

Really? What was reviewed here exactly? Poor style of commit msg or that rename actually does rename?

Quoted 3 lines
---
  Documentation/devicetree/bindings/{hwmon => misc}/amd,sbrmi.yaml | 0

We don't put bindings into MISC.

Quoted 8 lines

We moved the SB-RMI driver from hwmon to misc, and hence moved the binding documentation.

Referred the newly added yaml file, ti,fpc202.yaml through commit in the misc bindings.

If Documentation/devicetree/bindings/misc is not right path, can you please suggest the correct path for bindings for drivers in misc?

I don't know what this hardware is, but "misc" does not sound like class of hardware devices... Don't just dump stuff there.

Best regards,
Krzysztof

#10 lore raw

PATCH 4/5 dt-bindings: misc: Update the "$id:" to misc path

In reply to Akshay Gupta

- Modify the "$id" path as file moves from hwmon to misc

---
 Documentation/devicetree/bindings/misc/amd,sbrmi.yaml | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
Documentation/devicetree/bindings/misc/amd,sbrmi.yaml +1 -1
index 353d81d89bf5..5fd221200e37 100644
@@ -1,7 +1,7 @@
 # SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
 %YAML 1.2
 ---
-$id: http://devicetree.org/schemas/hwmon/amd,sbrmi.yaml#
+$id: http://devicetree.org/schemas/misc/amd,sbrmi.yaml#
 $schema: http://devicetree.org/meta-schemas/core.yaml#
 
 title: >
Signature · 1 line
2.25.1
#12 lore raw

PATCH 5/5 dt-bindings: misc: Add binding document for SB-RMI I3C

In reply to Akshay Gupta

- Document the dt-binding for AMD SB-RMI

---
 .../bindings/misc/amd,sbrmi-i3c.yaml          | 56 +++++++++++++++++++
 1 file changed, 56 insertions(+)
 create mode 100644 Documentation/devicetree/bindings/misc/amd,sbrmi-i3c.yaml
Documentation/devicetree/bindings/misc/amd,sbrmi-i3c.yaml new file +56 -0
new file mode 100644
index 000000000000..1d19571c2095
@@ -0,0 +1,56 @@
+# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
+%YAML 1.2
+---
+$id: http://devicetree.org/schemas/misc/amd,sbrmi-i3c.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: >
+  Sideband Remote Management Interface (SB-RMI) compliant
+  AMD SoC.
+
+maintainers:
+  - Akshay Gupta <[email protected]>
+
+description: |
+  SB Remote Management Interface (SB-RMI) is an SMBus compatible
+  interface that reports AMD SoC's Power (normalized Power) using,
+  Mailbox Service Request over I3C interface to BMC.
+  The power attributes in hwmon reports power in microwatts.
+
+properties:
+  reg:
+    - description: |
+        Encodes the static I2C address.
+      Socket 0: 0x3c
+      Socket 1: 0x38
+    - description: |
+        First half of the Provisioned ID (following the PID
+        definition provided by the I3C specification).
+        Contains the manufacturer ID left-shifted by 1 (0x224).
+    - description: |
+        Second half of the Provisioned ID (following the PID
+        definition provided by the I3C specification).
+        Contains the ORing of the part ID left-shifted by 16,
+        the instance ID left-shifted by 12 and extra information (0x00000002).
+
+  assigned-address:
+    - description: |
+	Dynamic address to be assigned to this device. As static address is
+	present, this address is assigned using SETDASA.
+
+required:
+  - reg
+  - assigned-address
+
+additionalProperties: false
+
+examples:
+  - |
+    i3c {
+        /* I3C device with a static I2C address and assigned address. */
+	sbrmi_p0_1: sbrmi@3c,22400000002 {
+		reg = <0x3c 0x224 0x00000002>;
+		assigned-address = <0x3c>;
+	};
+    };
+...
Signature · 1 line
2.25.1
#13 lore raw

Re: [PATCH v1 5/5] dt-bindings: misc: Add binding document for SB-RMI I3C

Quoted 1 line · Akshay Gupta

- Document the dt-binding for AMD SB-RMI

Why every commit is a one-item list?

Quoted 2 lines

I don't believe these reviews. Code was obviously buggy, but still reviewed.

Quoted 5 lines
---
 .../bindings/misc/amd,sbrmi-i3c.yaml          | 56 +++++++++++++++++++
 1 file changed, 56 insertions(+)
 create mode 100644 Documentation/devicetree/bindings/misc/amd,sbrmi-i3c.yaml

Your previous patches make no sense with this...

Quoted 7 lines
Documentation/devicetree/bindings/misc/amd,sbrmi-i3c.yaml new file +0 -0
new file mode 100644
index 000000000000..1d19571c2095

Documentation/devicetree/bindings/misc/amd,sbrmi-i3c.yaml line 7

Quoted 7 lines
Documentation/devicetree/bindings/misc/amd,sbrmi-i3c.yaml new file +7 -0
@@ -0,0 +1,56 @@
+# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
+%YAML 1.2
+---
+$id: http://devicetree.org/schemas/misc/amd,sbrmi-i3c.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: >

From where did you take such syntax of title?

Quoted 18 lines
Documentation/devicetree/bindings/misc/amd,sbrmi-i3c.yaml new file +18 -0
+  Sideband Remote Management Interface (SB-RMI) compliant
+  AMD SoC.
+
+maintainers:
+  - Akshay Gupta <[email protected]>
+
+description: |
+  SB Remote Management Interface (SB-RMI) is an SMBus compatible
+  interface that reports AMD SoC's Power (normalized Power) using,
+  Mailbox Service Request over I3C interface to BMC.
+  The power attributes in hwmon reports power in microwatts.
+
+properties:
+  reg:
+    - description: |
+        Encodes the static I2C address.
+      Socket 0: 0x3c
+      Socket 1: 0x38

Documentation/devicetree/bindings/misc/amd,sbrmi-i3c.yaml line 35

Quoted 10 lines
Documentation/devicetree/bindings/misc/amd,sbrmi-i3c.yaml new file +10 -0
+    - description: |
+        First half of the Provisioned ID (following the PID
+        definition provided by the I3C specification).
+        Contains the manufacturer ID left-shifted by 1 (0x224).
+    - description: |
+        Second half of the Provisioned ID (following the PID
+        definition provided by the I3C specification).
+        Contains the ORing of the part ID left-shifted by 16,
+        the instance ID left-shifted by 12 and extra information (0x00000002).
+

And this entire patch is just noop. Makes no difference, makes no impact.

Drop it and write proper bindings with proper description of problem you are solving.

<form letter>
Please use scripts/get_maintainers.pl to get a list of necessary people and lists to CC. It might happen, that command when run on an older kernel, gives you outdated entries. Therefore please be sure you base your patches on recent Linux kernel.

Tools like b4 or scripts/get_maintainer.pl provide you proper list of people, so fix your workflow. Tools might also fail if you work on some ancient tree (don't, instead use mainline) or work on fork of kernel (don't, instead use mainline). Just use b4 and everything should be fine, although remember about b4 prep --auto-to-cc if you added new patches to the patchset.

You missed at least devicetree list (maybe more), so this won't be tested by automated tooling. Performing review on untested code might be a waste of time.

Please kindly resend and include all necessary To/Cc entries. </form letter>

Best regards,
Krzysztof

#14 lore raw

Re: [PATCH v1 5/5] dt-bindings: misc: Add binding document for SB-RMI I3C

Quoted 6 lines · Krzysztof Kozlowski

Caution: This message originated from an External Source. Use proper caution when opening attachments, clicking links, or responding.

Quoted 1 line · Akshay Gupta

- Document the dt-binding for AMD SB-RMI

Why every commit is a one-item list?

Ack, will add more information related to changes

Quoted 10 lines
Quoted 2 lines

I don't believe these reviews. Code was obviously buggy, but still reviewed.

Quoted 5 lines
---
  .../bindings/misc/amd,sbrmi-i3c.yaml          | 56 +++++++++++++++++++
  1 file changed, 56 insertions(+)

create mode 100644 Documentation/devicetree/bindings/misc/amd,sbrmi-i3c.yaml

Your previous patches make no sense with this...

This will push with I3C driver changes

Quoted 15 lines
Quoted 7 lines
Documentation/devicetree/bindings/misc/amd,sbrmi-i3c.yaml new file +0 -0
new file mode 100644
index 000000000000..1d19571c2095

Documentation/devicetree/bindings/misc/amd,sbrmi-i3c.yaml line 7

Quoted 7 lines
Documentation/devicetree/bindings/misc/amd,sbrmi-i3c.yaml new file +7 -0
@@ -0,0 +1,56 @@
+# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
+%YAML 1.2
+---
+$id: http://devicetree.org/schemas/misc/amd,sbrmi-i3c.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: >

From where did you take such syntax of title?

Ack, will update.

Quoted 31 lines
Quoted 19 lines
Documentation/devicetree/bindings/misc/amd,sbrmi-i3c.yaml new file +18 -0
+  Sideband Remote Management Interface (SB-RMI) compliant
+  AMD SoC.
+
+maintainers:
+  - Akshay Gupta <[email protected]>
+
+description: |
+  SB Remote Management Interface (SB-RMI) is an SMBus compatible
+  interface that reports AMD SoC's Power (normalized Power) using,
+  Mailbox Service Request over I3C interface to BMC.
+  The power attributes in hwmon reports power in microwatts.
+
+properties:
+  reg:
+    - description: |
+        Encodes the static I2C address.
+      Socket 0: 0x3c
+      Socket 1: 0x38

Documentation/devicetree/bindings/misc/amd,sbrmi-i3c.yaml line 35

Quoted 10 lines
Documentation/devicetree/bindings/misc/amd,sbrmi-i3c.yaml new file +10 -0
+    - description: |
+        First half of the Provisioned ID (following the PID
+        definition provided by the I3C specification).
+        Contains the manufacturer ID left-shifted by 1 (0x224).
+    - description: |
+        Second half of the Provisioned ID (following the PID
+        definition provided by the I3C specification).
+        Contains the ORing of the part ID left-shifted by 16,
+        the instance ID left-shifted by 12 and extra information (0x00000002).
+

And this entire patch is just noop. Makes no difference, makes no impact.

Quoted 2 lines

Drop it and write proper bindings with proper description of problem you are solving.

Ack, will modify the content as mentioned.

Quoted 23 lines

<form letter>
Please use scripts/get_maintainers.pl to get a list of necessary people and lists to CC. It might happen, that command when run on an older kernel, gives you outdated entries. Therefore please be sure you base your patches on recent Linux kernel.

Tools like b4 or scripts/get_maintainer.pl provide you proper list of people, so fix your workflow. Tools might also fail if you work on some ancient tree (don't, instead use mainline) or work on fork of kernel (don't, instead use mainline). Just use b4 and everything should be fine, although remember about b4 prep --auto-to-cc if you added new patches to the patchset.

You missed at least devicetree list (maybe more), so this won't be tested by automated tooling. Performing review on untested code might be a waste of time.

Please kindly resend and include all necessary To/Cc entries. </form letter>

Best regards,
Krzysztof