inet_fragment.c (4ba24fef3eb3b142197135223b90ced2f319cd53) | inet_fragment.c (51456b2914a34d16b1255b7c55d5cbf6a681d306) |
---|---|
1/* 2 * inet fragments management 3 * 4 * This program is free software; you can redistribute it and/or 5 * modify it under the terms of the GNU General Public License 6 * as published by the Free Software Foundation; either version 7 * 2 of the License, or (at your option) any later version. 8 * --- 371 unchanged lines hidden (view full) --- 380 struct inet_frag_queue *q; 381 382 if (frag_mem_limit(nf) > nf->high_thresh) { 383 inet_frag_schedule_worker(f); 384 return NULL; 385 } 386 387 q = kmem_cache_zalloc(f->frags_cachep, GFP_ATOMIC); | 1/* 2 * inet fragments management 3 * 4 * This program is free software; you can redistribute it and/or 5 * modify it under the terms of the GNU General Public License 6 * as published by the Free Software Foundation; either version 7 * 2 of the License, or (at your option) any later version. 8 * --- 371 unchanged lines hidden (view full) --- 380 struct inet_frag_queue *q; 381 382 if (frag_mem_limit(nf) > nf->high_thresh) { 383 inet_frag_schedule_worker(f); 384 return NULL; 385 } 386 387 q = kmem_cache_zalloc(f->frags_cachep, GFP_ATOMIC); |
388 if (q == NULL) | 388 if (!q) |
389 return NULL; 390 391 q->net = nf; 392 f->constructor(q, arg); 393 add_frag_mem_limit(q, f->qsize); 394 395 setup_timer(&q->timer, f->frag_expire, (unsigned long)q); 396 spin_lock_init(&q->lock); --- 4 unchanged lines hidden (view full) --- 401 402static struct inet_frag_queue *inet_frag_create(struct netns_frags *nf, 403 struct inet_frags *f, 404 void *arg) 405{ 406 struct inet_frag_queue *q; 407 408 q = inet_frag_alloc(nf, f, arg); | 389 return NULL; 390 391 q->net = nf; 392 f->constructor(q, arg); 393 add_frag_mem_limit(q, f->qsize); 394 395 setup_timer(&q->timer, f->frag_expire, (unsigned long)q); 396 spin_lock_init(&q->lock); --- 4 unchanged lines hidden (view full) --- 401 402static struct inet_frag_queue *inet_frag_create(struct netns_frags *nf, 403 struct inet_frags *f, 404 void *arg) 405{ 406 struct inet_frag_queue *q; 407 408 q = inet_frag_alloc(nf, f, arg); |
409 if (q == NULL) | 409 if (!q) |
410 return NULL; 411 412 return inet_frag_intern(nf, q, f, arg); 413} 414 415struct inet_frag_queue *inet_frag_find(struct netns_frags *nf, 416 struct inet_frags *f, void *key, 417 unsigned int hash) --- 46 unchanged lines hidden --- | 410 return NULL; 411 412 return inet_frag_intern(nf, q, f, arg); 413} 414 415struct inet_frag_queue *inet_frag_find(struct netns_frags *nf, 416 struct inet_frags *f, void *key, 417 unsigned int hash) --- 46 unchanged lines hidden --- |