Lines Matching refs:prot

1083 int proto_register(struct proto *prot, int alloc_slab);
1084 void proto_unregister(struct proto *prot);
1177 struct proto *prot = sk->sk_prot; in sk_leave_memory_pressure() local
1179 for (; cg_proto; cg_proto = parent_cg_proto(prot, cg_proto)) in sk_leave_memory_pressure()
1192 struct proto *prot = sk->sk_prot; in sk_enter_memory_pressure() local
1194 for (; cg_proto; cg_proto = parent_cg_proto(prot, cg_proto)) in sk_enter_memory_pressure()
1203 long *prot = sk->sk_prot->sysctl_mem; in sk_prot_mem_limits() local
1205 prot = sk->sk_cgrp->sysctl_mem; in sk_prot_mem_limits()
1206 return prot[index]; in sk_prot_mem_limits()
1209 static inline void memcg_memory_allocated_add(struct cg_proto *prot, in memcg_memory_allocated_add() argument
1213 page_counter_charge(&prot->memory_allocated, amt); in memcg_memory_allocated_add()
1215 if (page_counter_read(&prot->memory_allocated) > in memcg_memory_allocated_add()
1216 prot->memory_allocated.limit) in memcg_memory_allocated_add()
1220 static inline void memcg_memory_allocated_sub(struct cg_proto *prot, in memcg_memory_allocated_sub() argument
1223 page_counter_uncharge(&prot->memory_allocated, amt); in memcg_memory_allocated_sub()
1229 struct proto *prot = sk->sk_prot; in sk_memory_allocated() local
1234 return atomic_long_read(prot->memory_allocated); in sk_memory_allocated()
1240 struct proto *prot = sk->sk_prot; in sk_memory_allocated_add() local
1245 atomic_long_add_return(amt, prot->memory_allocated); in sk_memory_allocated_add()
1249 return atomic_long_add_return(amt, prot->memory_allocated); in sk_memory_allocated_add()
1255 struct proto *prot = sk->sk_prot; in sk_memory_allocated_sub() local
1260 atomic_long_sub(amt, prot->memory_allocated); in sk_memory_allocated_sub()
1265 struct proto *prot = sk->sk_prot; in sk_sockets_allocated_dec() local
1270 for (; cg_proto; cg_proto = parent_cg_proto(prot, cg_proto)) in sk_sockets_allocated_dec()
1274 percpu_counter_dec(prot->sockets_allocated); in sk_sockets_allocated_dec()
1279 struct proto *prot = sk->sk_prot; in sk_sockets_allocated_inc() local
1284 for (; cg_proto; cg_proto = parent_cg_proto(prot, cg_proto)) in sk_sockets_allocated_inc()
1288 percpu_counter_inc(prot->sockets_allocated); in sk_sockets_allocated_inc()
1294 struct proto *prot = sk->sk_prot; in sk_sockets_allocated_read_positive() local
1299 return percpu_counter_read_positive(prot->sockets_allocated); in sk_sockets_allocated_read_positive()
1303 proto_sockets_allocated_sum_positive(struct proto *prot) in proto_sockets_allocated_sum_positive() argument
1305 return percpu_counter_sum_positive(prot->sockets_allocated); in proto_sockets_allocated_sum_positive()
1309 proto_memory_allocated(struct proto *prot) in proto_memory_allocated() argument
1311 return atomic_long_read(prot->memory_allocated); in proto_memory_allocated()
1315 proto_memory_pressure(struct proto *prot) in proto_memory_pressure() argument
1317 if (!prot->memory_pressure) in proto_memory_pressure()
1319 return !!*prot->memory_pressure; in proto_memory_pressure()
1325 void sock_prot_inuse_add(struct net *net, struct proto *prot, int inc);
1328 static inline void sock_prot_inuse_add(struct net *net, struct proto *prot, in sock_prot_inuse_add() argument
1528 struct proto *prot);