Remove spl's from netatalk in preparation to merge locking.

This commit is contained in:
Robert Watson 2004-07-12 04:33:58 +00:00
parent f58b94cba4
commit effb15c0c5
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=132009
2 changed files with 1 additions and 30 deletions

View File

@ -355,7 +355,7 @@ at_ifinit(ifp, aa, sat)
{
struct netrange nr, onr;
struct sockaddr_at oldaddr;
int s = splimp(), error = 0, i, j;
int error = 0, i, j;
int netinc, nodeinc, nnets;
u_short net;
@ -442,7 +442,6 @@ at_ifinit(ifp, aa, sat)
aa->aa_addr = oldaddr;
aa->aa_firstnet = onr.nr_firstnet;
aa->aa_lastnet = onr.nr_lastnet;
splx(s);
return (EINVAL);
}
/*
@ -511,7 +510,6 @@ at_ifinit(ifp, aa, sat)
aa->aa_addr = oldaddr;
aa->aa_firstnet = onr.nr_firstnet;
aa->aa_lastnet = onr.nr_lastnet;
splx(s);
return (EINTR);
}
@ -545,7 +543,6 @@ at_ifinit(ifp, aa, sat)
aa->aa_addr = oldaddr;
aa->aa_firstnet = onr.nr_firstnet;
aa->aa_lastnet = onr.nr_lastnet;
splx(s);
return (EADDRINUSE);
}
}
@ -563,7 +560,6 @@ at_ifinit(ifp, aa, sat)
aa->aa_addr = oldaddr;
aa->aa_firstnet = onr.nr_firstnet;
aa->aa_lastnet = onr.nr_lastnet;
splx(s);
return (error);
}
@ -631,7 +627,6 @@ at_ifinit(ifp, aa, sat)
aa->aa_addr = oldaddr;
aa->aa_firstnet = onr.nr_firstnet;
aa->aa_lastnet = onr.nr_lastnet;
splx(s);
return (error);
}
@ -640,7 +635,6 @@ at_ifinit(ifp, aa, sat)
*/
aa->aa_ifa.ifa_flags |= IFA_ROUTE;
aa->aa_flags |= AFA_ROUTE;
splx(s);
return (0);
}

View File

@ -32,7 +32,6 @@ ddp_attach(struct socket *so, int proto, struct thread *td)
{
struct ddpcb *ddp;
int error = 0;
int s;
ddp = sotoddpcb(so);
@ -40,9 +39,7 @@ ddp_attach(struct socket *so, int proto, struct thread *td)
return (EINVAL);
}
s = splnet();
error = at_pcballoc(so);
splx(s);
if (error) {
return (error);
}
@ -53,15 +50,12 @@ static int
ddp_detach(struct socket *so)
{
struct ddpcb *ddp;
int s;
ddp = sotoddpcb(so);
if (ddp == NULL) {
return (EINVAL);
}
s = splnet();
at_pcbdetach(so, ddp);
splx(s);
return (0);
}
@ -70,15 +64,12 @@ ddp_bind(struct socket *so, struct sockaddr *nam, struct thread *td)
{
struct ddpcb *ddp;
int error = 0;
int s;
ddp = sotoddpcb(so);
if (ddp == NULL) {
return (EINVAL);
}
s = splnet();
error = at_pcbsetaddr(ddp, nam, td);
splx(s);
return (error);
}
@ -87,7 +78,6 @@ ddp_connect(struct socket *so, struct sockaddr *nam, struct thread *td)
{
struct ddpcb *ddp;
int error = 0;
int s;
ddp = sotoddpcb(so);
if (ddp == NULL) {
@ -98,9 +88,7 @@ ddp_connect(struct socket *so, struct sockaddr *nam, struct thread *td)
return (EISCONN);
}
s = splnet();
error = at_pcbconnect(ddp, nam, td);
splx(s);
if (error == 0)
soisconnected(so);
return (error);
@ -111,7 +99,6 @@ ddp_disconnect(struct socket *so)
{
struct ddpcb *ddp;
int s;
ddp = sotoddpcb(so);
if (ddp == NULL) {
@ -121,10 +108,8 @@ ddp_disconnect(struct socket *so)
return (ENOTCONN);
}
s = splnet();
at_pcbdisconnect(ddp);
ddp->ddp_fsat.sat_addr.s_node = ATADDR_ANYNODE;
splx(s);
soisdisconnected(so);
return (0);
}
@ -148,7 +133,6 @@ ddp_send(struct socket *so, int flags, struct mbuf *m, struct sockaddr *addr,
{
struct ddpcb *ddp;
int error = 0;
int s;
ddp = sotoddpcb(so);
if (ddp == NULL) {
@ -164,9 +148,7 @@ ddp_send(struct socket *so, int flags, struct mbuf *m, struct sockaddr *addr,
return (EISCONN);
}
s = splnet();
error = at_pcbconnect(ddp, addr, td);
splx(s);
if (error) {
return (error);
}
@ -176,12 +158,10 @@ ddp_send(struct socket *so, int flags, struct mbuf *m, struct sockaddr *addr,
}
}
s = splnet();
error = ddp_output(m, so);
if (addr != NULL) {
at_pcbdisconnect(ddp);
}
splx(s);
return (error);
}
@ -189,15 +169,12 @@ static int
ddp_abort(struct socket *so)
{
struct ddpcb *ddp;
int s;
ddp = sotoddpcb(so);
if (ddp == NULL) {
return (EINVAL);
}
s = splnet();
at_pcbdetach(so, ddp);
splx(s);
return (0);
}