Lines Matching defs:table

51 	/* called when table is needed in the given netns */
195 struct ebt_table *table = priv;
211 read_lock_bh(&table->lock);
212 private = table->private;
233 read_unlock_bh(&table->lock);
254 read_unlock_bh(&table->lock);
258 read_unlock_bh(&table->lock);
282 read_unlock_bh(&table->lock);
294 read_unlock_bh(&table->lock);
312 read_unlock_bh(&table->lock);
315 read_unlock_bh(&table->lock);
326 struct ebt_table *table;
329 list_for_each_entry(table, &ebt_net->tables, list) {
330 if (strcmp(table->name, name) == 0)
331 return table;
355 list_for_each_entry(table, &ebt_net->tables, list) {
356 if (strcmp(table->name, name) == 0)
357 return table;
735 mtpar.table = tgpar.table = name;
866 /* do the parsing of the table/chains/entries/matches/watchers/targets, heh */
1014 struct ebt_table_info *table;
1054 table = t->private;
1055 /* make sure the table can only be rmmod'ed if it contains no rules */
1056 if (!table->nentries && newinfo->nentries && !try_module_get(t->me)) {
1059 } else if (table->nentries && !newinfo->nentries)
1078 /* Silent error, can't fail, new table is already in place */
1079 net_warn_ratelimited("ebtables: counters copy to user failed while replacing table\n");
1083 EBT_ENTRY_ITERATE(table->entries, table->entries_size,
1086 vfree(table->entries);
1087 ebt_free_table_info(table);
1088 vfree(table);
1107 /* replace the table */
1163 static void __ebt_unregister_table(struct net *net, struct ebt_table *table)
1166 list_del(&table->list);
1168 audit_log_nfcfg(table->name, AF_BRIDGE, table->private->nentries,
1170 EBT_ENTRY_ITERATE(table->private->entries, table->private->entries_size,
1172 if (table->private->nentries)
1173 module_put(table->me);
1174 vfree(table->private->entries);
1175 ebt_free_table_info(table->private);
1176 vfree(table->private);
1177 kfree(table->ops);
1178 kfree(table);
1186 struct ebt_table *t, *table;
1193 if (input_table == NULL || (repl = input_table->table) == NULL ||
1198 /* Don't add one table to multiple lists. */
1199 table = kmemdup(input_table, sizeof(struct ebt_table), GFP_KERNEL);
1200 if (!table) {
1237 table->private = newinfo;
1238 rwlock_init(&table->lock);
1241 if (strcmp(t->name, table->name) == 0) {
1248 if (newinfo->nentries && !try_module_get(table->me)) {
1253 num_ops = hweight32(table->valid_hooks);
1263 module_put(table->me);
1268 ops[i].priv = table;
1270 list_add(&table->list, &ebt_net->tables);
1273 table->ops = ops;
1276 __ebt_unregister_table(net, table);
1289 kfree(table);
1362 struct ebt_table *table = __ebt_find_table(net, name);
1364 if (table)
1365 nf_unregister_net_hooks(net, table->ops, hweight32(table->valid_hooks));
1371 struct ebt_table *table = __ebt_find_table(net, name);
1373 if (table)
1374 __ebt_unregister_table(net, table);
1560 entries_size = t->table->entries_size;
1561 nentries = t->table->nentries;
1562 entries = t->table->entries;
1563 oldcounters = t->table->counters;
1868 tinfo.entries_size = t->table->entries_size;
1869 tinfo.nentries = t->table->nentries;
1870 tinfo.entries = t->table->entries;
1871 oldcounters = t->table->counters;
2409 tmp.nentries = t->table->nentries;
2410 tmp.entries_size = t->table->entries_size;
2411 tmp.valid_hooks = t->table->valid_hooks;
2485 tmp.nentries = t->table->nentries;
2486 tmp.entries_size = t->table->entries_size;
2487 tmp.valid_hooks = t->table->valid_hooks;