On Mon, Jul 24, 2017 at 04:39:14PM +0200, Martin Pieuchot wrote:
> Here's a simpler diff.  I'd like to move forward with this since it's
> the first but blocking step to split the NET_LOCK() and socket locks.

OK bluhm@

> 
> Index: sys/systm.h
> ===================================================================
> RCS file: /cvs/src/sys/sys/systm.h,v
> retrieving revision 1.131
> diff -u -p -r1.131 systm.h
> --- sys/systm.h       29 May 2017 12:12:35 -0000      1.131
> +++ sys/systm.h       24 Jul 2017 13:22:37 -0000
> @@ -299,12 +299,12 @@ extern struct rwlock netlock;
>  #define      NET_LOCK(s)                                                     
> \
>  do {                                                                 \
>       rw_enter_write(&netlock);                                       \
> -     s = splsoftnet();                                               \
> +     s = IPL_SOFTNET;                                                \
>  } while (0)
>  
>  #define      NET_UNLOCK(s)                                                   
> \
>  do {                                                                 \
> -     splx(s);                                                        \
> +     (void)s;                                                        \
>       rw_exit_write(&netlock);                                        \
>  } while (0)
>  
> @@ -312,7 +312,6 @@ do {                                                      
>                 \
>  do {                                                                 \
>       if (rw_status(&netlock) != RW_WRITE)                            \
>               splassert_fail(RW_WRITE, rw_status(&netlock), __func__);\
> -     splsoftassert(IPL_SOFTNET);                                     \
>  } while (0)
>  
>  #define      NET_ASSERT_UNLOCKED()                                           
> \

Reply via email to