> On 20 Nov 2022, at 14:20, [email protected] wrote: > > > From: Klemens Nanni <[email protected]> > Subject: CVS: cvs.openbsd.org: src > Date: 19 November 2022 at 17:26:40 GMT+3 > To: [email protected] > > > CVSROOT: /cvs > Module name: src > Changes by: [email protected] 2022/11/19 07:26:40 > > Modified files: > sys/kern : sys_socket.c > sys/netinet : in.c > sys/netinet6 : in6.c > > Log message: > Push kernel lock into pru_control() aka. in6_control() / in_control() > > so->so_state is already read without kernel lock inside soo_ioctl() > which calls pru_control() aka in6_control() and in_control(). > > OK mvs >
This descriptions is totally incorrect. We don’t “read without kernel lock” so->so_state! We do unlocked check ok SS_PRIV flag because this flag is immutable, not because "we did unlocked access to so_state somewhere else"! This difference is significant.
