diff options
Diffstat (limited to 'net/bridge')
-rw-r--r-- | net/bridge/netfilter/ebtables.c | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/net/bridge/netfilter/ebtables.c b/net/bridge/netfilter/ebtables.c index 01eae97c53d9..66bd93252c4e 100644 --- a/net/bridge/netfilter/ebtables.c +++ b/net/bridge/netfilter/ebtables.c | |||
@@ -829,7 +829,7 @@ static int translate_table(struct ebt_replace *repl, | |||
829 | * sizeof(struct ebt_chainstack)); | 829 | * sizeof(struct ebt_chainstack)); |
830 | if (!newinfo->chainstack) | 830 | if (!newinfo->chainstack) |
831 | return -ENOMEM; | 831 | return -ENOMEM; |
832 | for_each_cpu(i) { | 832 | for_each_possible_cpu(i) { |
833 | newinfo->chainstack[i] = | 833 | newinfo->chainstack[i] = |
834 | vmalloc(udc_cnt * sizeof(struct ebt_chainstack)); | 834 | vmalloc(udc_cnt * sizeof(struct ebt_chainstack)); |
835 | if (!newinfo->chainstack[i]) { | 835 | if (!newinfo->chainstack[i]) { |
@@ -901,7 +901,7 @@ static void get_counters(struct ebt_counter *oldcounters, | |||
901 | sizeof(struct ebt_counter) * nentries); | 901 | sizeof(struct ebt_counter) * nentries); |
902 | 902 | ||
903 | /* add other counters to those of cpu 0 */ | 903 | /* add other counters to those of cpu 0 */ |
904 | for_each_cpu(cpu) { | 904 | for_each_possible_cpu(cpu) { |
905 | if (cpu == 0) | 905 | if (cpu == 0) |
906 | continue; | 906 | continue; |
907 | counter_base = COUNTER_BASE(oldcounters, nentries, cpu); | 907 | counter_base = COUNTER_BASE(oldcounters, nentries, cpu); |
@@ -1036,7 +1036,7 @@ static int do_replace(void __user *user, unsigned int len) | |||
1036 | 1036 | ||
1037 | vfree(table->entries); | 1037 | vfree(table->entries); |
1038 | if (table->chainstack) { | 1038 | if (table->chainstack) { |
1039 | for_each_cpu(i) | 1039 | for_each_possible_cpu(i) |
1040 | vfree(table->chainstack[i]); | 1040 | vfree(table->chainstack[i]); |
1041 | vfree(table->chainstack); | 1041 | vfree(table->chainstack); |
1042 | } | 1042 | } |
@@ -1054,7 +1054,7 @@ free_counterstmp: | |||
1054 | vfree(counterstmp); | 1054 | vfree(counterstmp); |
1055 | /* can be initialized in translate_table() */ | 1055 | /* can be initialized in translate_table() */ |
1056 | if (newinfo->chainstack) { | 1056 | if (newinfo->chainstack) { |
1057 | for_each_cpu(i) | 1057 | for_each_possible_cpu(i) |
1058 | vfree(newinfo->chainstack[i]); | 1058 | vfree(newinfo->chainstack[i]); |
1059 | vfree(newinfo->chainstack); | 1059 | vfree(newinfo->chainstack); |
1060 | } | 1060 | } |
@@ -1201,7 +1201,7 @@ free_unlock: | |||
1201 | mutex_unlock(&ebt_mutex); | 1201 | mutex_unlock(&ebt_mutex); |
1202 | free_chainstack: | 1202 | free_chainstack: |
1203 | if (newinfo->chainstack) { | 1203 | if (newinfo->chainstack) { |
1204 | for_each_cpu(i) | 1204 | for_each_possible_cpu(i) |
1205 | vfree(newinfo->chainstack[i]); | 1205 | vfree(newinfo->chainstack[i]); |
1206 | vfree(newinfo->chainstack); | 1206 | vfree(newinfo->chainstack); |
1207 | } | 1207 | } |
@@ -1224,7 +1224,7 @@ void ebt_unregister_table(struct ebt_table *table) | |||
1224 | mutex_unlock(&ebt_mutex); | 1224 | mutex_unlock(&ebt_mutex); |
1225 | vfree(table->private->entries); | 1225 | vfree(table->private->entries); |
1226 | if (table->private->chainstack) { | 1226 | if (table->private->chainstack) { |
1227 | for_each_cpu(i) | 1227 | for_each_possible_cpu(i) |
1228 | vfree(table->private->chainstack[i]); | 1228 | vfree(table->private->chainstack[i]); |
1229 | vfree(table->private->chainstack); | 1229 | vfree(table->private->chainstack); |
1230 | } | 1230 | } |