Re: [PATCH net-next v2 2/6] net: Introduce read_sock_rectype proto_ops for control record delivery
Sabrina Dubroca <[email protected]> Fri, 31 Jul 2026 01:40:41 +0200
| Newsgroups | dev.linux.lists.kernel-tls-handshake,org.kernel.vger.linux-kselftest,org.kernel.vger.linux-nfs,org.kernel.vger.netdev |
|---|---|
| Message-ID | <amvg-dZzDB6GzzSH@krikkit> |
2026-07-30, 16:34:57 -0700, Jakub Kicinski wrote: > On Fri, 31 Jul 2026 01:09:33 +0200 Sabrina Dubroca wrote: > > To avoid that, you'd have to run recvmsg-nocmsg/read_sock to get all > > the DATA out, then once you know the next chunk of payload is a > > control record (and hopefully nothing else is reading from your > > socket), one recvmsg+cmsg into a separate buffer. > > I guess the difference in perspective stems from a fact that > I'd look at a socket as a stream one reads and dispatches work > based on the input. Not an abstraction layer that by itself > dispatches different handlers for different message types. I agree. But TCP is a magical world where users don't have to worry about message types, and TLS isn't. It seems the users of the existing (TCP-oriented) API are unhappy with the mismatch, but I'm not convinced we can (and maybe "should") make that work. -- Sabrina