|
|
@@ -531,9 +531,9 @@ static void ip_vs_sync_conn_v0(struct net *net, struct ip_vs_conn *cp,
|
|
|
if (!ip_vs_sync_conn_needed(ipvs, cp, pkts))
|
|
|
return;
|
|
|
|
|
|
- spin_lock(&ipvs->sync_buff_lock);
|
|
|
+ spin_lock_bh(&ipvs->sync_buff_lock);
|
|
|
if (!(ipvs->sync_state & IP_VS_STATE_MASTER)) {
|
|
|
- spin_unlock(&ipvs->sync_buff_lock);
|
|
|
+ spin_unlock_bh(&ipvs->sync_buff_lock);
|
|
|
return;
|
|
|
}
|
|
|
|
|
|
@@ -552,7 +552,7 @@ static void ip_vs_sync_conn_v0(struct net *net, struct ip_vs_conn *cp,
|
|
|
if (!buff) {
|
|
|
buff = ip_vs_sync_buff_create_v0(ipvs);
|
|
|
if (!buff) {
|
|
|
- spin_unlock(&ipvs->sync_buff_lock);
|
|
|
+ spin_unlock_bh(&ipvs->sync_buff_lock);
|
|
|
pr_err("ip_vs_sync_buff_create failed.\n");
|
|
|
return;
|
|
|
}
|
|
|
@@ -590,7 +590,7 @@ static void ip_vs_sync_conn_v0(struct net *net, struct ip_vs_conn *cp,
|
|
|
sb_queue_tail(ipvs, ms);
|
|
|
ms->sync_buff = NULL;
|
|
|
}
|
|
|
- spin_unlock(&ipvs->sync_buff_lock);
|
|
|
+ spin_unlock_bh(&ipvs->sync_buff_lock);
|
|
|
|
|
|
/* synchronize its controller if it has */
|
|
|
cp = cp->control;
|
|
|
@@ -641,9 +641,9 @@ void ip_vs_sync_conn(struct net *net, struct ip_vs_conn *cp, int pkts)
|
|
|
pe_name_len = strnlen(cp->pe->name, IP_VS_PENAME_MAXLEN);
|
|
|
}
|
|
|
|
|
|
- spin_lock(&ipvs->sync_buff_lock);
|
|
|
+ spin_lock_bh(&ipvs->sync_buff_lock);
|
|
|
if (!(ipvs->sync_state & IP_VS_STATE_MASTER)) {
|
|
|
- spin_unlock(&ipvs->sync_buff_lock);
|
|
|
+ spin_unlock_bh(&ipvs->sync_buff_lock);
|
|
|
return;
|
|
|
}
|
|
|
|
|
|
@@ -683,7 +683,7 @@ void ip_vs_sync_conn(struct net *net, struct ip_vs_conn *cp, int pkts)
|
|
|
if (!buff) {
|
|
|
buff = ip_vs_sync_buff_create(ipvs);
|
|
|
if (!buff) {
|
|
|
- spin_unlock(&ipvs->sync_buff_lock);
|
|
|
+ spin_unlock_bh(&ipvs->sync_buff_lock);
|
|
|
pr_err("ip_vs_sync_buff_create failed.\n");
|
|
|
return;
|
|
|
}
|
|
|
@@ -750,7 +750,7 @@ void ip_vs_sync_conn(struct net *net, struct ip_vs_conn *cp, int pkts)
|
|
|
}
|
|
|
}
|
|
|
|
|
|
- spin_unlock(&ipvs->sync_buff_lock);
|
|
|
+ spin_unlock_bh(&ipvs->sync_buff_lock);
|
|
|
|
|
|
control:
|
|
|
/* synchronize its controller if it has */
|
|
|
@@ -843,7 +843,7 @@ static void ip_vs_proc_conn(struct net *net, struct ip_vs_conn_param *param,
|
|
|
kfree(param->pe_data);
|
|
|
|
|
|
dest = cp->dest;
|
|
|
- spin_lock(&cp->lock);
|
|
|
+ spin_lock_bh(&cp->lock);
|
|
|
if ((cp->flags ^ flags) & IP_VS_CONN_F_INACTIVE &&
|
|
|
!(flags & IP_VS_CONN_F_TEMPLATE) && dest) {
|
|
|
if (flags & IP_VS_CONN_F_INACTIVE) {
|
|
|
@@ -857,7 +857,7 @@ static void ip_vs_proc_conn(struct net *net, struct ip_vs_conn_param *param,
|
|
|
flags &= IP_VS_CONN_F_BACKUP_UPD_MASK;
|
|
|
flags |= cp->flags & ~IP_VS_CONN_F_BACKUP_UPD_MASK;
|
|
|
cp->flags = flags;
|
|
|
- spin_unlock(&cp->lock);
|
|
|
+ spin_unlock_bh(&cp->lock);
|
|
|
if (!dest)
|
|
|
ip_vs_try_bind_dest(cp);
|
|
|
} else {
|
|
|
@@ -1689,11 +1689,7 @@ static int sync_thread_backup(void *data)
|
|
|
break;
|
|
|
}
|
|
|
|
|
|
- /* disable bottom half, because it accesses the data
|
|
|
- shared by softirq while getting/creating conns */
|
|
|
- local_bh_disable();
|
|
|
ip_vs_process_message(tinfo->net, tinfo->buf, len);
|
|
|
- local_bh_enable();
|
|
|
}
|
|
|
}
|
|
|
|