wifi: ieee80211: correctly mark FTM frames non-bufferable
[carl9170fw.git] / config / symbol.c
index b101ef3c377a6b98d76e8d93a3c5be1c45d8fb7f..fe38e6fd2c2a4555adfcd78a135e977c78aa4ac4 100644 (file)
@@ -3,11 +3,11 @@
  * Copyright (C) 2002 Roman Zippel <zippel@linux-m68k.org>
  */
 
+#include <sys/types.h>
 #include <ctype.h>
 #include <stdlib.h>
 #include <string.h>
 #include <regex.h>
-#include <sys/utsname.h>
 
 #include "lkc.h"
 
@@ -15,15 +15,21 @@ struct symbol symbol_yes = {
        .name = "y",
        .curr = { "y", yes },
        .flags = SYMBOL_CONST|SYMBOL_VALID,
-}, symbol_mod = {
+};
+
+struct symbol symbol_mod = {
        .name = "m",
        .curr = { "m", mod },
        .flags = SYMBOL_CONST|SYMBOL_VALID,
-}, symbol_no = {
+};
+
+struct symbol symbol_no = {
        .name = "n",
        .curr = { "n", no },
        .flags = SYMBOL_CONST|SYMBOL_VALID,
-}, symbol_empty = {
+};
+
+static struct symbol symbol_empty = {
        .name = "",
        .curr = { "", no },
        .flags = SYMBOL_VALID,
@@ -31,7 +37,7 @@ struct symbol symbol_yes = {
 
 struct symbol *sym_defconfig_list;
 struct symbol *modules_sym;
-tristate modules_val;
+static tristate modules_val;
 
 enum symbol_type sym_get_type(struct symbol *sym)
 {
@@ -221,7 +227,7 @@ static void sym_calc_visibility(struct symbol *sym)
                sym_set_changed(sym);
        }
        tri = no;
-       if (sym->implied.expr && sym->dir_dep.tri != no)
+       if (sym->implied.expr)
                tri = expr_calc_value(sym->implied.expr);
        if (tri == mod && sym_get_type(sym) == S_BOOLEAN)
                tri = yes;
@@ -394,6 +400,8 @@ void sym_calc_value(struct symbol *sym)
                                if (sym->implied.tri != no) {
                                        sym->flags |= SYMBOL_WRITE;
                                        newval.tri = EXPR_OR(newval.tri, sym->implied.tri);
+                                       newval.tri = EXPR_AND(newval.tri,
+                                                             sym->dir_dep.tri);
                                }
                        }
                calc_newval:
@@ -829,7 +837,7 @@ struct symbol *sym_lookup(const char *name, int flags)
        memset(symbol, 0, sizeof(*symbol));
        symbol->name = new_name;
        symbol->type = S_UNKNOWN;
-       symbol->flags |= flags;
+       symbol->flags = flags;
 
        symbol->next = symbol_hash[hash];
        symbol_hash[hash] = symbol;