<html><head>
<style><!--
/* Font Definitions */
@font-face
{font-family:"Cambria Math";
panose-1:2 4 5 3 5 4 6 3 2 4;}
@font-face
{font-family:Aptos;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
{margin:0in;
font-size:12.0pt;
font-family:"Aptos",sans-serif;
mso-ligatures:standardcontextual;}
a:link, span.MsoHyperlink
{mso-style-priority:99;
color:#467886;
text-decoration:underline;}
span.EmailStyle17
{mso-style-type:personal-compose;
font-family:"Aptos",sans-serif;
color:windowtext;}
.MsoChpDefault
{mso-style-type:export-only;}
@page WordSection1
{size:8.5in 11.0in;
margin:1.0in 1.0in 1.0in 1.0in;}
div.WordSection1
{page:WordSection1;}
--></style>
<style>pre,code,address {
margin: 0px;
}
h1,h2,h3,h4,h5,h6 {
margin-top: 0.2em;
margin-bottom: 0.2em;
}
ol,ul {
margin-top: 0em;
margin-bottom: 0em;
}
blockquote {
margin-top: 0em;
margin-bottom: 0em;
}
</style></head>
<body lang="EN-US" link="#467886" vlink="#96607D" style="word-wrap:break-word"><div>Hi Gary,</div><div><br></div><div>On Wed, 2026-04-01 at 21:35 +0000, Gary Beihl wrote:</div><blockquote type="cite" style="margin:0 0 0 .8ex; border-left:2px #729fcf solid;padding-left:1ex">
<div class="WordSection1">
<p class="MsoNormal"><span style="font-size: 11pt;">(c) Shared AF_MCTP socket (affects 80311: mctp_helper.hpp)</span></p><p class="MsoNormal"><span style="font-size:11.0pt"><o:p> </o:p></span></p><p class="MsoNormal"><span style="font-size:11.0pt">Only one socket can bind to (MCTP_ADDR_ANY, MCTP_TYPE_SPDM). When spdmd attests multiple endpoints sequentially, the second MctpIoClass::createSocket() fails with EADDRINUSE. The fix is a process-lifetime shared socket (singleton pattern), draining stale responses between endpoint attestations with recv(MSG_DONTWAIT).<o:p></o:p></span></p><p class="MsoNormal"></p></div></blockquote><div><br></div><div>Since Linux 6.17 it is possible to restrict a bind() to only receive from a single remote endpoint [1]. Call connect() with the remote address before the bind().</div><div><br></div><div>Is the SPDM implementation using asynchronous messages sent by the responder? (KEY_UPDATE, HEARTBEAT, END_SESSION)</div><div>If not, I think the bind() could be removed altogether.</div><div>bind() isn't needed in the case where the Linux host is performing a plain send() then receiving a response. A similar situation was fixed in pldmtool [2].</div><div><br></div><div>[1] <a href="https://lore.kernel.org/all/20250710-mctp-bind-v4-6-8ec2f6460c56@codeconstruct.com.au/">https://lore.kernel.org/all/20250710-mctp-bind-v4-6-8ec2f6460c56@codeconstruct.com.au/</a></div><div>[2] <a href="https://gerrit.openbmc.org/c/openbmc/pldm/+/83626">https://gerrit.openbmc.org/c/openbmc/pldm/+/83626</a> </div><div><br></div><div>Cheers,</div><div>Matt</div><blockquote type="cite" style="margin:0 0 0 .8ex; border-left:2px #729fcf solid;padding-left:1ex"><div class="WordSection1"><p class="MsoNormal"><span style="font-size:11.0pt"><o:p></o:p></span></p></div></blockquote><div><br></div><div><span></span></div></body></html>