Re: [PATCH net] ipvs: fix crash if scheduler is changed

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Mon, Jun 29, 2015 at 09:50:25PM +0300, Julian Anastasov wrote:
> 
> 	Hello,
> 
> On Mon, 29 Jun 2015, Simon Horman wrote:
> 
> > On Sat, Jun 27, 2015 at 02:37:42PM +0300, Julian Anastasov wrote:
> > > I overlooked the svc->sched_data usage from schedulers
> > > when the services were converted to RCU in 3.10. Now
> > > the rare ipvsadm -E command can change the scheduler
> > > but due to the reverse order of ip_vs_bind_scheduler
> > > and ip_vs_unbind_scheduler we provide new sched_data
> > > to the old scheduler resulting in a crash.
> > > 
> > > To fix it without changing the scheduler methods we
> > > have to use synchronize_rcu() only for the editing case.
> > > It means all svc->scheduler readers should expect a
> > > NULL value. To avoid breakage for the service listing
> > > and ipvsadm -R we can use the "none" name to indicate
> > > that scheduler is not assigned, a state when we drop
> > > new connections.
> > > 
> > > Reported-by: Alexander Vasiliev <a.vasylev@xxxxxxxxxxxxx>
> > > Fixes: ceec4c381681 ("ipvs: convert services to rcu")
> > > Signed-off-by: Julian Anastasov <ja@xxxxxx>
> > 
> > Thanks, I have applied this to the ipvs tree.
> 
> 	Simon, I'm sending v2 due to the build error...
> which was somehow missed by my compiler...

Thanks, I will update the ipvs tree accordingly.
--
To unsubscribe from this list: send the line "unsubscribe lvs-devel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html



[Index of Archives]     [Linux Filesystem Devel]     [Linux NFS]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux SCSI]     [X.Org]

  Powered by Linux