static inline int has_expired(const struct net_bridge *br,
                                  const struct net_bridge_fdb_entry *fdb)
 {
-       return !fdb->is_static && !fdb->added_by_external_learn &&
-               time_before_eq(fdb->updated + hold_time(br), jiffies);
+       return !test_bit(BR_FDB_STATIC, &fdb->flags) &&
+              !fdb->added_by_external_learn &&
+              time_before_eq(fdb->updated + hold_time(br), jiffies);
 }
 
 static void fdb_rcu_free(struct rcu_head *head)
 {
        trace_fdb_delete(br, f);
 
-       if (f->is_static)
+       if (test_bit(BR_FDB_STATIC, &f->flags))
                fdb_del_hw_addr(br, f->key.addr.addr);
 
        hlist_del_init_rcu(&f->fdb_node);
        hlist_for_each_entry_rcu(f, &br->fdb_list, fdb_node) {
                unsigned long this_timer;
 
-               if (f->is_static || f->added_by_external_learn)
+               if (test_bit(BR_FDB_STATIC, &f->flags) ||
+                   f->added_by_external_learn)
                        continue;
                this_timer = f->updated + delay;
                if (time_after(this_timer, now)) {
 
        spin_lock_bh(&br->hash_lock);
        hlist_for_each_entry_safe(f, tmp, &br->fdb_list, fdb_node) {
-               if (!f->is_static)
+               if (!test_bit(BR_FDB_STATIC, &f->flags))
                        fdb_delete(br, f, true);
        }
        spin_unlock_bh(&br->hash_lock);
                        continue;
 
                if (!do_all)
-                       if (f->is_static || (vid && f->key.vlan_id != vid))
+                       if (test_bit(BR_FDB_STATIC, &f->flags) ||
+                           (vid && f->key.vlan_id != vid))
                                continue;
 
                if (test_bit(BR_FDB_LOCAL, &f->flags))
                fe->port_hi = f->dst->port_no >> 8;
 
                fe->is_local = test_bit(BR_FDB_LOCAL, &f->flags);
-               if (!f->is_static)
+               if (!test_bit(BR_FDB_STATIC, &f->flags))
                        fe->ageing_timer_value = jiffies_delta_to_clock_t(jiffies - f->updated);
                ++fe;
                ++num;
                fdb->flags = 0;
                if (is_local)
                        set_bit(BR_FDB_LOCAL, &fdb->flags);
-               fdb->is_static = is_static;
+               if (is_static)
+                       set_bit(BR_FDB_STATIC, &fdb->flags);
                fdb->added_by_user = 0;
                fdb->added_by_external_learn = 0;
                fdb->offloaded = 0;
 {
        if (test_bit(BR_FDB_LOCAL, &fdb->flags))
                return NUD_PERMANENT;
-       else if (fdb->is_static)
+       else if (test_bit(BR_FDB_STATIC, &fdb->flags))
                return NUD_NOARP;
        else if (has_expired(br, fdb))
                return NUD_STALE;
        if (fdb_to_nud(br, fdb) != state) {
                if (state & NUD_PERMANENT) {
                        set_bit(BR_FDB_LOCAL, &fdb->flags);
-                       if (!fdb->is_static) {
-                               fdb->is_static = 1;
+                       if (!test_and_set_bit(BR_FDB_STATIC, &fdb->flags))
                                fdb_add_hw_addr(br, addr);
-                       }
                } else if (state & NUD_NOARP) {
                        clear_bit(BR_FDB_LOCAL, &fdb->flags);
-                       if (!fdb->is_static) {
-                               fdb->is_static = 1;
+                       if (!test_and_set_bit(BR_FDB_STATIC, &fdb->flags))
                                fdb_add_hw_addr(br, addr);
-                       }
                } else {
                        clear_bit(BR_FDB_LOCAL, &fdb->flags);
-                       if (fdb->is_static) {
-                               fdb->is_static = 0;
+                       if (test_and_clear_bit(BR_FDB_STATIC, &fdb->flags))
                                fdb_del_hw_addr(br, addr);
-                       }
                }
 
                modified = true;
        rcu_read_lock();
        hlist_for_each_entry_rcu(f, &br->fdb_list, fdb_node) {
                /* We only care for static entries */
-               if (!f->is_static)
+               if (!test_bit(BR_FDB_STATIC, &f->flags))
                        continue;
                err = dev_uc_add(p->dev, f->key.addr.addr);
                if (err)
 rollback:
        hlist_for_each_entry_rcu(tmp, &br->fdb_list, fdb_node) {
                /* We only care for static entries */
-               if (!tmp->is_static)
+               if (!test_bit(BR_FDB_STATIC, &tmp->flags))
                        continue;
                if (tmp == f)
                        break;
        rcu_read_lock();
        hlist_for_each_entry_rcu(f, &br->fdb_list, fdb_node) {
                /* We only care for static entries */
-               if (!f->is_static)
+               if (!test_bit(BR_FDB_STATIC, &f->flags))
                        continue;
 
                dev_uc_del(p->dev, f->key.addr.addr);