linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Jeremy Kerr <jk@codeconstruct.com.au>
To: YH Chung <yh_chung@aspeedtech.com>,
	"matt@codeconstruct.com.au" <matt@codeconstruct.com.au>,
	"andrew+netdev@lunn.ch" <andrew+netdev@lunn.ch>,
	 "davem@davemloft.net" <davem@davemloft.net>,
	"edumazet@google.com" <edumazet@google.com>,
	 "kuba@kernel.org" <kuba@kernel.org>,
	"pabeni@redhat.com" <pabeni@redhat.com>,
	 "linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
	"netdev@vger.kernel.org" <netdev@vger.kernel.org>,
	BMC-SW <BMC-SW@aspeedtech.com>
Cc: Khang D Nguyen <khangng@amperemail.onmicrosoft.com>
Subject: Re: [PATCH] net: mctp: Add MCTP PCIe VDM transport driver
Date: Thu, 17 Jul 2025 15:31:02 +0800	[thread overview]
Message-ID: <2fbeb73a21dc9d9f7cffdb956c712ad28ecf1a7f.camel@codeconstruct.com.au> (raw)
In-Reply-To: <SEZPR06MB5763125EBCAAA4F0C14C939E9051A@SEZPR06MB5763.apcprd06.prod.outlook.com>

Hi YH,

> From my perspective, the other MCTP transport drivers do make use of
> abstraction layers that already exist in the kernel tree. For example,
> mctp-i3c uses i3c_device_do_priv_xfers(), which ultimately invokes
> operations registered by the underlying I3C driver. This is
> effectively an abstraction layer handling the hardware-specific
> details of TX packet transmission.
> 
> In our case, there is no standard interface—like those for
> I2C/I3C—that serves PCIe VDM.

But that's not what you're proposing here - your abstraction layer
serves one type of PCIe VDM messaging (MCTP), for only one PCIe VDM MCTP
driver.

If you were proposing adding a *generic* PCIe VDM interface, that is
suitable for all messaging types (not just MCTP), and all PCIe VDM
hardware (not just ASPEED's) that would make more sense. But I think
that would be a much larger task than what you're intending here.

Start small. If we have other use-cases for an abstraction layer, we can
introduce it at that point - where we have real-world design inputs for
it.

Regardless, we have worked out that there is nothing to actually abstract
*anyway*.

> > The direct approach would definitely be preferable, if possible.
> > 
> Got it. Then we'll remove the kernel thread and do TX directly.

Super!

> > Excellent question! I suspect we would want a four-byte representation,
> > being:
> > 
> > [0]: routing type (bits 0:2, others reserved)
> > [1]: segment (or 0 for non-flit mode)
> > [2]: bus
> > [3]: device / function
> > 
> > which assumes there is some value in combining formats between flit- and
> > non-flit modes. I am happy to adjust if there are better ideas.
> > 
> This looks good to me—thanks for sharing!

No problem! We'll still want a bit of wider consensus on this, because
we cannot change it once upstreamed.

Cheers,


Jeremy

  reply	other threads:[~2025-07-17  7:31 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-07-14  6:25 [PATCH] net: mctp: Add MCTP PCIe VDM transport driver aspeedyh
2025-07-14  8:54 ` Jeremy Kerr
2025-07-14 12:37   ` YH Chung
2025-07-15  1:08     ` Jeremy Kerr
2025-07-17  3:07       ` YH Chung
2025-07-17  5:37         ` Jeremy Kerr
2025-07-17  7:17           ` YH Chung
2025-07-17  7:31             ` Jeremy Kerr [this message]
2025-07-17  8:21               ` YH Chung
2025-07-17 21:40                 ` Adam Young
2025-07-18  3:24                 ` Jeremy Kerr
2025-07-17 21:43             ` Adam Young
2025-07-18  5:48           ` Khang D Nguyen
2025-07-18  6:03             ` Jeremy Kerr
2025-07-18 11:05               ` YH Chung
2025-07-15  2:26 ` kernel test robot
2025-07-17 10:39 ` kernel test robot

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=2fbeb73a21dc9d9f7cffdb956c712ad28ecf1a7f.camel@codeconstruct.com.au \
    --to=jk@codeconstruct.com.au \
    --cc=BMC-SW@aspeedtech.com \
    --cc=andrew+netdev@lunn.ch \
    --cc=davem@davemloft.net \
    --cc=edumazet@google.com \
    --cc=khangng@amperemail.onmicrosoft.com \
    --cc=kuba@kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=matt@codeconstruct.com.au \
    --cc=netdev@vger.kernel.org \
    --cc=pabeni@redhat.com \
    --cc=yh_chung@aspeedtech.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;
as well as URLs for NNTP newsgroup(s).