public inbox for netdev@vger.kernel.org
 help / color / mirror / Atom feed
From: Heikki Krogerus <heikki.krogerus@linux.intel.com>
To: Wolfram Sang <wsa+renesas@sang-engineering.com>
Cc: Jeremy Kerr <jk@codeconstruct.com.au>,
	Matt Johnston <matt@codeconstruct.com.au>,
	linux-i2c@vger.kernel.org, netdev@vger.kernel.org,
	linux-kernel@vger.kernel.org
Subject: [PATCH v2 3/4] mctp i2c: Enable SMBus ARP discovery
Date: Wed, 21 Jan 2026 10:23:27 +0100	[thread overview]
Message-ID: <20260121092328.2308705-4-heikki.krogerus@linux.intel.com> (raw)
In-Reply-To: <20260121092328.2308705-1-heikki.krogerus@linux.intel.com>

Since the SMBus Address Resolution Protocol (ARP) is now
supported with all I2C host adapters, every ARP-capable MCTP
device will get automatically enumerated. Those devices just
need to be bind to this driver.

The SMBus ARP-capable MCTP devices are identified by
checking the interface (MCTP SMBus/I2C Transport Binding
Specification section 6.5). The interface must match the ASF
protocol, so all devices that use the ASF protocol as their
interface will be probed by this driver.

Link: https://www.dmtf.org/sites/default/files/standards/documents/DSP0237_1.2.0.pdf
Signed-off-by: Heikki Krogerus <heikki.krogerus@linux.intel.com>
---
 drivers/net/mctp/mctp-i2c.c | 8 ++++++++
 1 file changed, 8 insertions(+)

diff --git a/drivers/net/mctp/mctp-i2c.c b/drivers/net/mctp/mctp-i2c.c
index 8043b57bdf25..47d7f6b5212e 100644
--- a/drivers/net/mctp/mctp-i2c.c
+++ b/drivers/net/mctp/mctp-i2c.c
@@ -21,6 +21,7 @@
 #include <linux/netdevice.h>
 #include <linux/i2c.h>
 #include <linux/i2c-mux.h>
+#include <linux/i2c-smbus.h>
 #include <linux/if_arp.h>
 #include <net/mctp.h>
 #include <net/mctpdevice.h>
@@ -1105,6 +1106,12 @@ static const struct i2c_device_id mctp_i2c_id[] = {
 };
 MODULE_DEVICE_TABLE(i2c, mctp_i2c_id);
 
+static const struct smbus_device_id mctp_smbus_id[] = {
+	{ SMBUS_INTERFACE_ASF },
+	{}
+};
+MODULE_DEVICE_TABLE(smbus, mctp_smbus_id);
+
 static const struct of_device_id mctp_i2c_of_match[] = {
 	{ .compatible = "mctp-i2c-controller" },
 	{},
@@ -1119,6 +1126,7 @@ static struct i2c_driver mctp_i2c_driver = {
 	.probe = mctp_i2c_probe,
 	.remove = mctp_i2c_remove,
 	.id_table = mctp_i2c_id,
+	.smbus_id_table = mctp_smbus_id,
 };
 
 static __init int mctp_i2c_mod_init(void)
-- 
2.50.1


  parent reply	other threads:[~2026-01-21  9:23 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-01-21  9:23 [PATCH v2 0/4] i2c: SMBus ARP support Heikki Krogerus
2026-01-21  9:23 ` [PATCH v2 1/4] i2c: SMBus Address Resolution Protocol implementation for host side Heikki Krogerus
2026-01-21  9:23 ` [PATCH v2 2/4] i2c: Sysfs attribute files for the Unique Device Identifier fields Heikki Krogerus
2026-01-21  9:23 ` Heikki Krogerus [this message]
2026-01-22 14:36   ` [PATCH v2 3/4] mctp i2c: Enable SMBus ARP discovery Paolo Abeni
2026-01-22 16:05     ` Jakub Kicinski
2026-01-23  0:18       ` Jeremy Kerr
2026-01-23  8:46         ` Heikki Krogerus
2026-01-23 18:12           ` Jakub Kicinski
2026-01-21  9:23 ` [PATCH v2 4/4] i2c: Add SMBus ARP target mode test driver Heikki Krogerus
2026-01-24  5:32 ` [PATCH v2 0/4] i2c: SMBus ARP support Jeremy Kerr
2026-01-26 13:56   ` Heikki Krogerus
2026-01-27  0:32     ` Jeremy Kerr
2026-01-27 13:52       ` Heikki Krogerus
2026-01-28 10:28         ` Jeremy Kerr
2026-01-28 15:02           ` Heikki Krogerus
2026-01-29 13:43             ` Jeremy Kerr
2026-02-02 13:29               ` Heikki Krogerus

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20260121092328.2308705-4-heikki.krogerus@linux.intel.com \
    --to=heikki.krogerus@linux.intel.com \
    --cc=jk@codeconstruct.com.au \
    --cc=linux-i2c@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=matt@codeconstruct.com.au \
    --cc=netdev@vger.kernel.org \
    --cc=wsa+renesas@sang-engineering.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox