NC-SI Asynchronous Event Notification (AEN) Implementation

Milton Miller II miltonm at us.ibm.com
Tue Dec 8 05:00:30 AEDT 2020


On Dec 7, 2020 around 11:36 in some timezone, P. Priyatharshan wrote:
> Hello Milton, > 
>  
> Thanks for the reply. 
> 
> I am also expecting the link state  to be reflected to userspace and>was planning to capture the same in journalctl logs. 
> 

The link state and network port changes are printed in the logs.

The reason the link state is not reflected to userspace is an 
architectural one.  In order for the network stack to recieve or 
send any packets including NCSI packets the interface has to be 
marked fully link up with carrier.  

Its possible for userspace to open a raw ethernet protocol 
socket and listen in to the NCSI response traffic recieved in
response to  kernel stack but be aware that the AEN packets 
alone will not relect the changes in connectivity to the 
network as they are not always sent and also the kernel can 
timeout and restart the NCSI stack at any point.

There are several abstractions in the kernel for various 
virtural network topologies but not really match what NCSI
provides.  Most of the virtural interfaces follow the carrier 
state of one or more underlying ports.  The closest might be 
a virtual switch but NCSI just provides a common bus wire 
that doesn't differentiate the source port on rx and requires 
a single mac on tx.

I think the way forward is to expose each port as a virtural 
interface but that will provide backwards compatibility issues 
because that can not support the automatic interface fallover 
that is coded today.  Again, this is pie in the sky planning with
no time alotted by me currently.

milton 

> Thanks, > Priyatharshan P    
> 
>>> Is NC-SI Asynchronous Event Notification (AEN) handler is already
> >>implemented in OpenBMC?.If yes kindly let me know which daemon is
> >>handling that.
> >
> >The NC-SI Asynchronous Event Notification is processed.
> >
> >The whole NCSI stack is inside the linux kernel.
> >The code is in the net/ncsi directory.
> >
> >What action are you expecting on an AEN notification?
> >
> >There current NC-SI stack tries to handle switching the network
> >to the host that is up, and there are netlink messages to control
> >which packages and ports are considered for traffic.
> >
> >Unfornately the current model does not allow link state to be
> >reflected to userspace.
> >
> >I have been studing the stack recently and am looking at making
> >changes,but have other work that leaves me little time to work on
> >this.
> >
> >milton




More information about the openbmc mailing list