Lines Matching refs:prot

1081 int proto_register(struct proto *prot, int alloc_slab);
1082 void proto_unregister(struct proto *prot);
1180 struct proto *prot = sk->sk_prot;
1182 for (; cg_proto; cg_proto = parent_cg_proto(prot, cg_proto))
1195 struct proto *prot = sk->sk_prot;
1197 for (; cg_proto; cg_proto = parent_cg_proto(prot, cg_proto))
1206 long *prot = sk->sk_prot->sysctl_mem;
1208 prot = sk->sk_cgrp->sysctl_mem;
1209 return prot[index];
1212 static inline void memcg_memory_allocated_add(struct cg_proto *prot,
1219 ret = res_counter_charge_nofail(&prot->memory_allocated,
1225 static inline void memcg_memory_allocated_sub(struct cg_proto *prot,
1228 res_counter_uncharge(&prot->memory_allocated, amt << PAGE_SHIFT);
1231 static inline u64 memcg_memory_allocated_read(struct cg_proto *prot)
1234 ret = res_counter_read_u64(&prot->memory_allocated, RES_USAGE);
1241 struct proto *prot = sk->sk_prot;
1245 return atomic_long_read(prot->memory_allocated);
1251 struct proto *prot = sk->sk_prot;
1256 atomic_long_add_return(amt, prot->memory_allocated);
1260 return atomic_long_add_return(amt, prot->memory_allocated);
1266 struct proto *prot = sk->sk_prot;
1271 atomic_long_sub(amt, prot->memory_allocated);
1276 struct proto *prot = sk->sk_prot;
1281 for (; cg_proto; cg_proto = parent_cg_proto(prot, cg_proto))
1285 percpu_counter_dec(prot->sockets_allocated);
1290 struct proto *prot = sk->sk_prot;
1295 for (; cg_proto; cg_proto = parent_cg_proto(prot, cg_proto))
1299 percpu_counter_inc(prot->sockets_allocated);
1305 struct proto *prot = sk->sk_prot;
1310 return percpu_counter_read_positive(prot->sockets_allocated);
1314 proto_sockets_allocated_sum_positive(struct proto *prot)
1316 return percpu_counter_sum_positive(prot->sockets_allocated);
1320 proto_memory_allocated(struct proto *prot)
1322 return atomic_long_read(prot->memory_allocated);
1326 proto_memory_pressure(struct proto *prot)
1328 if (!prot->memory_pressure)
1330 return !!*prot->memory_pressure;
1336 void sock_prot_inuse_add(struct net *net, struct proto *prot, int inc);
1339 static inline void sock_prot_inuse_add(struct net *net, struct proto *prot,
1562 struct proto *prot);