diff options
Diffstat (limited to 'net')
-rw-r--r-- | net/core/flow.c | 1 | ||||
-rw-r--r-- | net/dccp/proto.c | 1 | ||||
-rw-r--r-- | net/ipv4/ipcomp.c | 1 | ||||
-rw-r--r-- | net/ipv6/ipcomp6.c | 1 | ||||
-rw-r--r-- | net/sunrpc/svc.c | 16 | ||||
-rw-r--r-- | net/unix/af_unix.c | 4 |
6 files changed, 15 insertions, 9 deletions
diff --git a/net/core/flow.c b/net/core/flow.c index a77531c..1999117 100644 --- a/net/core/flow.c +++ b/net/core/flow.c @@ -23,7 +23,6 @@ #include <linux/mutex.h> #include <net/flow.h> #include <asm/atomic.h> -#include <asm/semaphore.h> #include <linux/security.h> struct flow_cache_entry { diff --git a/net/dccp/proto.c b/net/dccp/proto.c index a4c1b36..9dfe247 100644 --- a/net/dccp/proto.c +++ b/net/dccp/proto.c @@ -27,7 +27,6 @@ #include <net/xfrm.h> #include <asm/ioctls.h> -#include <asm/semaphore.h> #include <linux/spinlock.h> #include <linux/timer.h> #include <linux/delay.h> diff --git a/net/ipv4/ipcomp.c b/net/ipv4/ipcomp.c index fb53ddf..a75807b 100644 --- a/net/ipv4/ipcomp.c +++ b/net/ipv4/ipcomp.c @@ -14,7 +14,6 @@ * - Adaptive compression. */ #include <linux/module.h> -#include <asm/semaphore.h> #include <linux/crypto.h> #include <linux/err.h> #include <linux/pfkeyv2.h> diff --git a/net/ipv6/ipcomp6.c b/net/ipv6/ipcomp6.c index e3dcfa2..ee6de42 100644 --- a/net/ipv6/ipcomp6.c +++ b/net/ipv6/ipcomp6.c @@ -34,7 +34,6 @@ #include <net/ip.h> #include <net/xfrm.h> #include <net/ipcomp.h> -#include <asm/semaphore.h> #include <linux/crypto.h> #include <linux/err.h> #include <linux/pfkeyv2.h> diff --git a/net/sunrpc/svc.c b/net/sunrpc/svc.c index a290e15..090af78 100644 --- a/net/sunrpc/svc.c +++ b/net/sunrpc/svc.c @@ -301,7 +301,6 @@ static inline int svc_pool_map_set_cpumask(unsigned int pidx, cpumask_t *oldmask) { struct svc_pool_map *m = &svc_pool_map; - unsigned int node; /* or cpu */ /* * The caller checks for sv_nrpools > 1, which @@ -314,16 +313,23 @@ svc_pool_map_set_cpumask(unsigned int pidx, cpumask_t *oldmask) default: return 0; case SVC_POOL_PERCPU: - node = m->pool_to[pidx]; + { + unsigned int cpu = m->pool_to[pidx]; + *oldmask = current->cpus_allowed; - set_cpus_allowed(current, cpumask_of_cpu(node)); + set_cpus_allowed_ptr(current, &cpumask_of_cpu(cpu)); return 1; + } case SVC_POOL_PERNODE: - node = m->pool_to[pidx]; + { + unsigned int node = m->pool_to[pidx]; + node_to_cpumask_ptr(nodecpumask, node); + *oldmask = current->cpus_allowed; - set_cpus_allowed(current, node_to_cpumask(node)); + set_cpus_allowed_ptr(current, nodecpumask); return 1; } + } } /* diff --git a/net/unix/af_unix.c b/net/unix/af_unix.c index 2851d0d..1454afc 100644 --- a/net/unix/af_unix.c +++ b/net/unix/af_unix.c @@ -819,7 +819,11 @@ static int unix_bind(struct socket *sock, struct sockaddr *uaddr, int addr_len) */ mode = S_IFSOCK | (SOCK_INODE(sock)->i_mode & ~current->fs->umask); + err = mnt_want_write(nd.path.mnt); + if (err) + goto out_mknod_dput; err = vfs_mknod(nd.path.dentry->d_inode, dentry, mode, 0); + mnt_drop_write(nd.path.mnt); if (err) goto out_mknod_dput; mutex_unlock(&nd.path.dentry->d_inode->i_mutex); |