Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 327208
b: refs/heads/master
c: 51e4e7f
h: refs/heads/master
v: v3
  • Loading branch information
Daniel Wagner authored and Tejun Heo committed Sep 14, 2012
1 parent a0b79f2 commit 0eb9617
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 8 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 8fb974c937570be38f944986456467b39a2dc252
refs/heads/master: 51e4e7faba786d33e5e33f8776c5027a1c8d6fb7
12 changes: 5 additions & 7 deletions trunk/include/net/netprio_cgroup.h
Original file line number Diff line number Diff line change
Expand Up @@ -18,14 +18,13 @@
#include <linux/rcupdate.h>


#if IS_ENABLED(CONFIG_NETPRIO_CGROUP)
struct netprio_map {
struct rcu_head rcu;
u32 priomap_len;
u32 priomap[];
};

#ifdef CONFIG_CGROUPS

struct cgroup_netprio_state {
struct cgroup_subsys_state css;
u32 prioidx;
Expand Down Expand Up @@ -71,18 +70,17 @@ static inline u32 task_netprioidx(struct task_struct *p)
rcu_read_unlock();
return idx;
}
#endif

#else
#else /* !CONFIG_NETPRIO_CGROUP */

static inline u32 task_netprioidx(struct task_struct *p)
{
return 0;
}

#endif /* CONFIG_NETPRIO_CGROUP */

#else
#define sock_update_netprioidx(sk, task)
#endif

#endif /* CONFIG_NETPRIO_CGROUP */

#endif /* _NET_CLS_CGROUP_H */
2 changes: 2 additions & 0 deletions trunk/net/core/sock.c
Original file line number Diff line number Diff line change
Expand Up @@ -1237,6 +1237,7 @@ void sock_update_classid(struct sock *sk)
EXPORT_SYMBOL(sock_update_classid);
#endif

#if IS_ENABLED(CONFIG_NETPRIO_CGROUP)
void sock_update_netprioidx(struct sock *sk, struct task_struct *task)
{
if (in_interrupt())
Expand All @@ -1246,6 +1247,7 @@ void sock_update_netprioidx(struct sock *sk, struct task_struct *task)
}
EXPORT_SYMBOL_GPL(sock_update_netprioidx);
#endif
#endif

/**
* sk_alloc - All socket objects are allocated here
Expand Down

0 comments on commit 0eb9617

Please sign in to comment.