~ubuntu-branches/ubuntu/precise/linux-ti-omap4/precise

« back to all changes in this revision

Viewing changes to net/netfilter/xt_osf.c

  • Committer: Bazaar Package Importer
  • Author(s): Paolo Pisati
  • Date: 2011-06-29 15:23:51 UTC
  • mfrom: (26.1.1 natty-proposed)
  • Revision ID: james.westby@ubuntu.com-20110629152351-xs96tm303d95rpbk
Tags: 3.0.0-1200.2
* Rebased against 3.0.0-6.7
* BSP from TI based on 3.0.0

Show diffs side-by-side

added added

removed removed

Lines of Context:
62
62
        [OSF_ATTR_FINGER]       = { .len = sizeof(struct xt_osf_user_finger) },
63
63
};
64
64
 
65
 
static void xt_osf_finger_free_rcu(struct rcu_head *rcu_head)
66
 
{
67
 
        struct xt_osf_finger *f = container_of(rcu_head, struct xt_osf_finger, rcu_head);
68
 
 
69
 
        kfree(f);
70
 
}
71
 
 
72
65
static int xt_osf_add_callback(struct sock *ctnl, struct sk_buff *skb,
73
66
                               const struct nlmsghdr *nlh,
74
67
                               const struct nlattr * const osf_attrs[])
133
126
                 * We are protected by nfnl mutex.
134
127
                 */
135
128
                list_del_rcu(&sf->finger_entry);
136
 
                call_rcu(&sf->rcu_head, xt_osf_finger_free_rcu);
 
129
                kfree_rcu(sf, rcu_head);
137
130
 
138
131
                err = 0;
139
132
                break;
414
407
 
415
408
                list_for_each_entry_rcu(f, &xt_osf_fingers[i], finger_entry) {
416
409
                        list_del_rcu(&f->finger_entry);
417
 
                        call_rcu(&f->rcu_head, xt_osf_finger_free_rcu);
 
410
                        kfree_rcu(f, rcu_head);
418
411
                }
419
412
        }
420
413
        rcu_read_unlock();