Merge branch 'master' of git://github.com/chunkeey/carl9170fw
authorChristian Lamparter <chunkeey@googlemail.com>
Sat, 23 Mar 2013 12:47:55 +0000 (13:47 +0100)
committerChristian Lamparter <chunkeey@googlemail.com>
Sat, 23 Mar 2013 12:47:55 +0000 (13:47 +0100)
16 files changed:
carlfw/CMakeLists.txt
carlfw/include/usb.h
carlfw/src/ashlsi3.S [deleted file]
carlfw/usb/main.c
carlfw/usb/usb.c
config/conf.c
config/expr.c
config/lkc.h
config/menu.c
config/symbol.c
config/util.c
config/zconf.l
include/linux/ieee80211.h
include/shared/version.h
toolchain/Makefile
toolchain/SHA256SUMS

index fe6857263a68d30f6a6ad10fb0d781e534a4c33f..124352e1986ccc3b88cc1d8b4154b317dc5049b1 100644 (file)
@@ -21,12 +21,12 @@ set(carl9170_main_src src/main.c src/wlan.c src/wlanrx.c src/wlantx.c
                      src/uart.c src/dma.c src/hostif.c src/reboot.S
                      src/printf.c src/rf.c src/cam.c src/wol.c)
 
-set(carl9170_lib_src src/ashlsi3.S src/memcpy.S src/memset.S src/udivsi3_i4i-Os.S)
+set(carl9170_lib_src src/memcpy.S src/memset.S src/udivsi3_i4i-Os.S)
 set(carl9170_usb_src usb/main.c usb/usb.c usb/fifo.c)
 
 set(carl9170_src ${carl9170_main_src} ${carl9170_lib_src} ${carl9170_usb_src})
 
-set_source_files_properties(src/ashlsi3.S PROPERTIES LANGUAGE C)
+#set_source_files_properties(src/ashlsi3.S PROPERTIES LANGUAGE C)
 set_source_files_properties(src/memcpy.S PROPERTIES LANGUAGE C)
 set_source_files_properties(src/memset.S PROPERTIES LANGUAGE C)
 set_source_files_properties(src/reboot.S PROPERTIES LANGUAGE C)
index fb258bf16bd37be843d3542f26fa771c921e76b4..1066fe023d008085ecb8c37496fe61e42c6c79eb 100644 (file)
@@ -184,6 +184,7 @@ void __noreturn jump_to_bootcode(void);
 void send_cmd_to_host(const uint8_t len, const uint8_t type,
                      const uint8_t ext, const uint8_t *body);
 
+void usb_reset_eps(void);
 void usb_init(void);
 void usb_ep0rx(void);
 void usb_ep0tx(void);
diff --git a/carlfw/src/ashlsi3.S b/carlfw/src/ashlsi3.S
deleted file mode 100644 (file)
index 593d902..0000000
+++ /dev/null
@@ -1,193 +0,0 @@
-/* Copyright (C) 1994, 1995, 1997, 1998, 1999, 2000, 2001, 2002, 2003,
-   2004, 2005, 2006
-   Free Software Foundation, Inc.
-
-This file is free software; you can redistribute it and/or modify it
-under the terms of the GNU General Public License as published by the
-Free Software Foundation; either version 2, or (at your option) any
-later version.
-
-In addition to the permissions in the GNU General Public License, the
-Free Software Foundation gives you unlimited permission to link the
-compiled version of this file into combinations with other programs,
-and to distribute those combinations without any restriction coming
-from the use of this file.  (The General Public License restrictions
-do apply in other respects; for example, they cover modification of
-the file, and distribution when not linked into a combine
-executable.)
-
-This file is distributed in the hope that it will be useful, but
-WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-General Public License for more details.
-
-You should have received a copy of the GNU General Public License
-along with this program; see the file COPYING.  If not, write to
-the Free Software Foundation, 51 Franklin Street, Fifth Floor,
-Boston, MA 02110-1301, USA.  */
-
-!! libgcc routines for the Renesas / SuperH SH CPUs.
-!! Contributed by Steve Chamberlain.
-!! sac@cygnus.com
-
-!! ashiftrt_r4_x, ___ashrsi3, ___ashlsi3, ___lshrsi3 routines
-!! recoded in assembly by Toshiyasu Morita
-!! tm@netcom.com
-
-/* SH2 optimizations for ___ashrsi3, ___ashlsi3, ___lshrsi3 and
-   ELF local label prefixes by J"orn Rennecke
-   amylaar@cygnus.com  */
-
-!
-! __ashlsi3
-!
-! Entry:
-!
-! r4: Value to shift
-! r5: Shifts
-!
-! Exit:
-!
-! r0: Result
-!
-! Destroys:
-!
-! (none)
-!
-       .global ___ashlsi3
-
-       .align  2
-___ashlsi3:
-       mov     #31,r0
-       and     r0,r5
-       mova    ashlsi3_table,r0
-       mov.b   @(r0,r5),r5
-#ifdef __sh1__
-       add     r5,r0
-       jmp     @r0
-#else
-       braf    r5
-#endif
-       mov     r4,r0
-
-       .align  2
-ashlsi3_table:
-       .byte           ashlsi3_0-ashlsi3_table
-       .byte           ashlsi3_1-ashlsi3_table
-       .byte           ashlsi3_2-ashlsi3_table
-       .byte           ashlsi3_3-ashlsi3_table
-       .byte           ashlsi3_4-ashlsi3_table
-       .byte           ashlsi3_5-ashlsi3_table
-       .byte           ashlsi3_6-ashlsi3_table
-       .byte           ashlsi3_7-ashlsi3_table
-       .byte           ashlsi3_8-ashlsi3_table
-       .byte           ashlsi3_9-ashlsi3_table
-       .byte           ashlsi3_10-ashlsi3_table
-       .byte           ashlsi3_11-ashlsi3_table
-       .byte           ashlsi3_12-ashlsi3_table
-       .byte           ashlsi3_13-ashlsi3_table
-       .byte           ashlsi3_14-ashlsi3_table
-       .byte           ashlsi3_15-ashlsi3_table
-       .byte           ashlsi3_16-ashlsi3_table
-       .byte           ashlsi3_17-ashlsi3_table
-       .byte           ashlsi3_18-ashlsi3_table
-       .byte           ashlsi3_19-ashlsi3_table
-       .byte           ashlsi3_20-ashlsi3_table
-       .byte           ashlsi3_21-ashlsi3_table
-       .byte           ashlsi3_22-ashlsi3_table
-       .byte           ashlsi3_23-ashlsi3_table
-       .byte           ashlsi3_24-ashlsi3_table
-       .byte           ashlsi3_25-ashlsi3_table
-       .byte           ashlsi3_26-ashlsi3_table
-       .byte           ashlsi3_27-ashlsi3_table
-       .byte           ashlsi3_28-ashlsi3_table
-       .byte           ashlsi3_29-ashlsi3_table
-       .byte           ashlsi3_30-ashlsi3_table
-       .byte           ashlsi3_31-ashlsi3_table
-
-ashlsi3_6:
-       shll2   r0
-ashlsi3_4:
-       shll2   r0
-ashlsi3_2:
-       rts
-       shll2   r0
-
-ashlsi3_7:
-       shll2   r0
-ashlsi3_5:
-       shll2   r0
-ashlsi3_3:
-       shll2   r0
-ashlsi3_1:
-       rts
-       shll    r0
-
-ashlsi3_14:
-       shll2   r0
-ashlsi3_12:
-       shll2   r0
-ashlsi3_10:
-       shll2   r0
-ashlsi3_8:
-       rts
-       shll8   r0
-
-ashlsi3_15:
-       shll2   r0
-ashlsi3_13:
-       shll2   r0
-ashlsi3_11:
-       shll2   r0
-ashlsi3_9:
-       shll8   r0
-       rts
-       shll    r0
-
-ashlsi3_22:
-       shll2   r0
-ashlsi3_20:
-       shll2   r0
-ashlsi3_18:
-       shll2   r0
-ashlsi3_16:
-       rts
-       shll16  r0
-
-ashlsi3_23:
-       shll2   r0
-ashlsi3_21:
-       shll2   r0
-ashlsi3_19:
-       shll2   r0
-ashlsi3_17:
-       shll16  r0
-       rts
-       shll    r0
-
-ashlsi3_30:
-       shll2   r0
-ashlsi3_28:
-       shll2   r0
-ashlsi3_26:
-       shll2   r0
-ashlsi3_24:
-       shll16  r0
-       rts
-       shll8   r0
-
-ashlsi3_31:
-       shll2   r0
-ashlsi3_29:
-       shll2   r0
-ashlsi3_27:
-       shll2   r0
-ashlsi3_25:
-       shll16  r0
-       shll8   r0
-       rts
-       shll    r0
-
-ashlsi3_0:
-       rts
-       nop
index 890970c24ab237a7cd596eb8eb1903ecc04cc7e1..1fb119e996f8933e70b16b4d24c77337203aa834 100644 (file)
@@ -377,6 +377,7 @@ static void usb_handler(uint8_t usb_interrupt_level1)
 
                if (usb_interrupt_level2 & AR9170_USB_INTR_SRC7_USB_RESET) {
                        usb_reset_ack();
+                       usb_reset_eps();
                        reboot();
                }
 
index 0c66b8275b636e91d0a0c94e4070c32777ed6e68..d7bc4329ba8bad27bbac17bc2202d2c999abc49e 100644 (file)
@@ -166,8 +166,7 @@ static struct ar9170_usb_config usb_config_fullspeed = {
        },
 };
 
-#ifdef CONFIG_CARL9170FW_USB_MODESWITCH
-static void usb_reset_eps(void)
+void usb_reset_eps(void)
 {
        unsigned int i;
 
@@ -188,8 +187,6 @@ static void usb_reset_eps(void)
                usb_clear_output_ep_stall(i);
        }
 }
-#endif /* CONFIG_CARL9170FW_USB_MODESWITCH */
-
 
 static void usb_pta_init(void)
 {
@@ -503,7 +500,7 @@ static int usb_get_configuration(const struct usb_ctrlrequest *ctrl)
        if (USB_CHECK_REQTYPE(ctrl, USB_RECIP_DEVICE, USB_DIR_IN))
                return -1;
 
-       return usb_ep0tx_data(&fw.usb.config, 1);
+       return usb_ep0tx_data(&fw.usb.config, fw.usb.config);
 }
 
 static int usb_set_configuration(const struct usb_ctrlrequest *ctrl)
@@ -519,10 +516,10 @@ static int usb_set_configuration(const struct usb_ctrlrequest *ctrl)
                /* Disable Device */
                andb(AR9170_USB_REG_DEVICE_ADDRESS,
                      (uint8_t) ~(AR9170_USB_DEVICE_ADDRESS_CONFIGURE));
-#ifdef CONFIG_CARL9170FW_USB_MODESWITCH
        case 1:
                fw.usb.config = config;
 
+#ifdef CONFIG_CARL9170FW_USB_MODESWITCH
                if (usb_detect_highspeed()) {
                        /* High Speed Configuration */
                        usb_init_highspeed_fifo_cfg();
@@ -530,25 +527,21 @@ static int usb_set_configuration(const struct usb_ctrlrequest *ctrl)
                        /* Full Speed Configuration */
                        usb_init_fullspeed_fifo_cfg();
                }
+               /* usb_pta_init() ? */
                break;
+#endif /* CONFIG_CARL9170FW_USB_MODESWITCH */
 
-       default:
-               return -1;
-       }
-       /* usb_pta_init() ? */
+               usb_reset_eps();
+               orb(AR9170_USB_REG_DEVICE_ADDRESS,
+                   (AR9170_USB_DEVICE_ADDRESS_CONFIGURE));
 
-       usb_reset_eps();
-       orb(AR9170_USB_REG_DEVICE_ADDRESS,
-           (AR9170_USB_DEVICE_ADDRESS_CONFIGURE));
+               usb_enable_global_int();
+               usb_trigger_out();
+               return 1;
 
-       usb_enable_global_int();
-       usb_trigger_out();
-       return 1;
-#else
        default:
                return -1;
        }
-#endif /* CONFIG_CARL9170FW_USB_MODESWITCH */
 }
 
 static int usb_set_address(const struct usb_ctrlrequest *ctrl)
index 649ea82772335ebf8e159fc4bede8ef8cf8a39c4..cdbdb1129eeb3067b26451c0851d014d709a4ad2 100644 (file)
@@ -35,6 +35,7 @@ enum input_mode {
 } input_mode = oldaskconfig;
 
 static int indent = 1;
+static int tty_stdio;
 static int valid_stdin = 1;
 static int conf_cnt;
 static char line[128];
@@ -105,6 +106,8 @@ static int conf_askvalue(struct symbol *sym, const char *def)
        case oldaskconfig:
                fflush(stdout);
                xfgets(line, 128, stdin);
+               if (!tty_stdio)
+                       printf("\n");
                return 1;
        default:
                break;
@@ -482,6 +485,8 @@ int main(int ac, char **av)
        bindtextdomain(PACKAGE, LOCALEDIR);
        textdomain(PACKAGE);
 
+       tty_stdio = isatty(0) && isatty(1) && isatty(2);
+
        while ((opt = getopt_long(ac, av, "", long_opts, NULL)) != -1) {
                input_mode = (enum input_mode)opt;
                switch (opt) {
@@ -583,7 +588,7 @@ int main(int ac, char **av)
                break;
        }
 
-       valid_stdin = isatty(0) && isatty(1) && isatty(2);
+       valid_stdin = tty_stdio;
 
        switch (input_mode) {
        case allnoconfig:
index 290ce41f8ba46fcee2d61b6d7f3bd157593f4b66..d6626521f9b9ab9d166fcb9e916a6ea5bc8a7eba 100644 (file)
@@ -13,7 +13,7 @@
 
 struct expr *expr_alloc_symbol(struct symbol *sym)
 {
-       struct expr *e = calloc(1, sizeof(*e));
+       struct expr *e = xcalloc(1, sizeof(*e));
        e->type = E_SYMBOL;
        e->left.sym = sym;
        return e;
@@ -21,7 +21,7 @@ struct expr *expr_alloc_symbol(struct symbol *sym)
 
 struct expr *expr_alloc_one(enum expr_type type, struct expr *ce)
 {
-       struct expr *e = calloc(1, sizeof(*e));
+       struct expr *e = xcalloc(1, sizeof(*e));
        e->type = type;
        e->left.expr = ce;
        return e;
@@ -29,7 +29,7 @@ struct expr *expr_alloc_one(enum expr_type type, struct expr *ce)
 
 struct expr *expr_alloc_two(enum expr_type type, struct expr *e1, struct expr *e2)
 {
-       struct expr *e = calloc(1, sizeof(*e));
+       struct expr *e = xcalloc(1, sizeof(*e));
        e->type = type;
        e->left.expr = e1;
        e->right.expr = e2;
@@ -38,7 +38,7 @@ struct expr *expr_alloc_two(enum expr_type type, struct expr *e1, struct expr *e
 
 struct expr *expr_alloc_comp(enum expr_type type, struct symbol *s1, struct symbol *s2)
 {
-       struct expr *e = calloc(1, sizeof(*e));
+       struct expr *e = xcalloc(1, sizeof(*e));
        e->type = type;
        e->left.sym = s1;
        e->right.sym = s2;
@@ -66,7 +66,7 @@ struct expr *expr_copy(const struct expr *org)
        if (!org)
                return NULL;
 
-       e = malloc(sizeof(*org));
+       e = xmalloc(sizeof(*org));
        memcpy(e, org, sizeof(*org));
        switch (org->type) {
        case E_SYMBOL:
index c18f2bd9c095510d1d5e58575b265bd67ae9e781..f8aee5fc6d5e607625fc9e7f93bcbcf7f2e9f13b 100644 (file)
@@ -39,6 +39,12 @@ extern "C" {
 #ifndef CONFIG_
 #define CONFIG_ "CONFIG_"
 #endif
+static inline const char *CONFIG_prefix(void)
+{
+       return getenv( "CONFIG_" ) ?: CONFIG_;
+}
+#undef CONFIG_
+#define CONFIG_ CONFIG_prefix()
 
 #define TF_COMMAND     0x0001
 #define TF_PARAM       0x0002
@@ -116,6 +122,8 @@ void menu_set_type(int type);
 /* util.c */
 struct file *file_lookup(const char *name);
 int file_write_dep(const char *name);
+void *xmalloc(size_t size);
+void *xcalloc(size_t nmemb, size_t size);
 
 struct gstr {
        size_t len;
index e98a05c8e50882d3b2833a2f4d05761dcffd22d3..f3bffa309333061ed5d852e7c00132107017add5 100644 (file)
@@ -48,7 +48,7 @@ void menu_add_entry(struct symbol *sym)
 {
        struct menu *menu;
 
-       menu = malloc(sizeof(*menu));
+       menu = xmalloc(sizeof(*menu));
        memset(menu, 0, sizeof(*menu));
        menu->sym = sym;
        menu->parent = current_menu;
@@ -531,7 +531,7 @@ static void get_prompt_str(struct gstr *r, struct property *prop,
                        location = menu;
        }
        if (head && location) {
-               jump = malloc(sizeof(struct jump_key));
+               jump = xmalloc(sizeof(struct jump_key));
 
                if (menu_is_visible(prop->menu)) {
                        /*
index 22a3c400fc41119c8c8f4197c3dfcdde87b0a882..ecc5aa5f865db7d253facefc10cc77fc2404e41d 100644 (file)
@@ -656,11 +656,11 @@ bool sym_set_string_value(struct symbol *sym, const char *newval)
        size = strlen(newval) + 1;
        if (sym->type == S_HEX && (newval[0] != '0' || (newval[1] != 'x' && newval[1] != 'X'))) {
                size += 2;
-               sym->def[S_DEF_USER].val = val = malloc(size);
+               sym->def[S_DEF_USER].val = val = xmalloc(size);
                *val++ = '0';
                *val++ = 'x';
        } else if (!oldval || strcmp(oldval, newval))
-               sym->def[S_DEF_USER].val = val = malloc(size);
+               sym->def[S_DEF_USER].val = val = xmalloc(size);
        else
                return true;
 
@@ -812,7 +812,7 @@ struct symbol *sym_lookup(const char *name, int flags)
                hash = 0;
        }
 
-       symbol = malloc(sizeof(*symbol));
+       symbol = xmalloc(sizeof(*symbol));
        memset(symbol, 0, sizeof(*symbol));
        symbol->name = new_name;
        symbol->type = S_UNKNOWN;
@@ -863,7 +863,7 @@ const char *sym_expand_string_value(const char *in)
        size_t reslen;
 
        reslen = strlen(in) + 1;
-       res = malloc(reslen);
+       res = xmalloc(reslen);
        res[0] = '\0';
 
        while ((src = strchr(in, '$'))) {
@@ -921,7 +921,7 @@ const char *sym_escape_string_value(const char *in)
                p++;
        }
 
-       res = malloc(reslen);
+       res = xmalloc(reslen);
        res[0] = '\0';
 
        strcat(res, "\"");
@@ -1228,7 +1228,7 @@ struct property *prop_alloc(enum prop_type type, struct symbol *sym)
        struct property *prop;
        struct property **propp;
 
-       prop = malloc(sizeof(*prop));
+       prop = xmalloc(sizeof(*prop));
        memset(prop, 0, sizeof(*prop));
        prop->type = type;
        prop->sym = sym;
index d0b8b2318e489577fd82713fd79b1759c3ff170b..6e7fbf1968090463f37ec1af70d65fb0af28a391 100644 (file)
@@ -23,7 +23,7 @@ struct file *file_lookup(const char *name)
                }
        }
 
-       file = malloc(sizeof(*file));
+       file = xmalloc(sizeof(*file));
        memset(file, 0, sizeof(*file));
        file->name = file_name;
        file->next = file_list;
@@ -81,7 +81,7 @@ int file_write_dep(const char *name)
 struct gstr str_new(void)
 {
        struct gstr gs;
-       gs.s = malloc(sizeof(char) * 64);
+       gs.s = xmalloc(sizeof(char) * 64);
        gs.len = 64;
        gs.max_width = 0;
        strcpy(gs.s, "\0");
@@ -138,3 +138,22 @@ const char *str_get(struct gstr *gs)
        return gs->s;
 }
 
+void *xmalloc(size_t size)
+{
+       void *p = malloc(size);
+       if (p)
+               return p;
+       fprintf(stderr, "Out of memory.\n");
+       exit(1);
+}
+
+void *xcalloc(size_t nmemb, size_t size)
+{
+       void *p = calloc(nmemb, size);
+       if (p)
+               return p;
+       fprintf(stderr, "Out of memory.\n");
+       exit(1);
+}
+
+
index a2b289519df6139ca2f029e50dba256d2f3b57b3..04ee4431c3fe9d7868b0cdc104eb04bf38cad77d 100644 (file)
@@ -40,7 +40,7 @@ static void zconf_endfile(void);
 
 static void new_string(void)
 {
-       text = malloc(START_STRSIZE);
+       text = xmalloc(START_STRSIZE);
        text_asize = START_STRSIZE;
        text_size = 0;
        *text = 0;
@@ -62,7 +62,7 @@ static void append_string(const char *str, int size)
 
 static void alloc_string(const char *str, int size)
 {
-       text = malloc(size + 1);
+       text = xmalloc(size + 1);
        memcpy(text, str, size);
        text[size] = 0;
 }
@@ -288,7 +288,7 @@ void zconf_initscan(const char *name)
                exit(1);
        }
 
-       current_buf = malloc(sizeof(*current_buf));
+       current_buf = xmalloc(sizeof(*current_buf));
        memset(current_buf, 0, sizeof(*current_buf));
 
        current_file = file_lookup(name);
@@ -299,7 +299,7 @@ void zconf_nextfile(const char *name)
 {
        struct file *iter;
        struct file *file = file_lookup(name);
-       struct buffer *buf = malloc(sizeof(*buf));
+       struct buffer *buf = xmalloc(sizeof(*buf));
        memset(buf, 0, sizeof(*buf));
 
        current_buf->state = YY_CURRENT_BUFFER;
index 1b41d5d9f38eeaabc631fa7493eb78cd4cab93fe..5567dc173fde920675aa7ffd86e9702ad0251337 100644 (file)
 #define IEEE80211_CTL_EXT_SSW_FBACK    0x9000
 #define IEEE80211_CTL_EXT_SSW_ACK      0xa000
 
+
+#define IEEE80211_SN_MASK              ((IEEE80211_SCTL_SEQ) >> 4)
+#define IEEE80211_MAX_SN               IEEE80211_SN_MASK
+#define IEEE80211_SN_MODULO            (IEEE80211_MAX_SN + 1)
+
+static inline int ieee80211_sn_less(u16 sn1, u16 sn2)
+{
+       return ((sn1 - sn2) & IEEE80211_SN_MASK) > (IEEE80211_SN_MODULO >> 1);
+}
+
+static inline u16 ieee80211_sn_add(u16 sn1, u16 sn2)
+{
+       return (sn1 + sn2) & IEEE80211_SN_MASK;
+}
+
+static inline u16 ieee80211_sn_inc(u16 sn)
+{
+       return ieee80211_sn_add(sn, 1);
+}
+
+static inline u16 ieee80211_sn_sub(u16 sn1, u16 sn2)
+{
+       return (sn1 - sn2) & IEEE80211_SN_MASK;
+}
+
+#define IEEE80211_SEQ_TO_SN(seq)       (((seq) & IEEE80211_SCTL_SEQ) >> 4)
+#define IEEE80211_SN_TO_SEQ(ssn)       (((ssn) << 4) & IEEE80211_SCTL_SEQ)
+
 /* miscellaneous IEEE 802.11 constants */
 #define IEEE80211_MAX_FRAG_THRESHOLD   2352
 #define IEEE80211_MAX_RTS_THRESHOLD    2353
@@ -177,7 +205,7 @@ struct ieee80211_hdr {
        u8 addr3[6];
        __le16 seq_ctrl;
        u8 addr4[6];
-} __packed;
+} __packed __aligned(2);
 
 struct ieee80211_hdr_3addr {
        __le16 frame_control;
@@ -186,7 +214,7 @@ struct ieee80211_hdr_3addr {
        u8 addr2[6];
        u8 addr3[6];
        __le16 seq_ctrl;
-} __packed;
+} __packed __aligned(2);
 
 struct ieee80211_qos_hdr {
        __le16 frame_control;
@@ -196,7 +224,7 @@ struct ieee80211_qos_hdr {
        u8 addr3[6];
        __le16 seq_ctrl;
        __le16 qos_ctrl;
-} __packed;
+} __packed __aligned(2);
 
 /**
  * ieee80211_has_tods - check if IEEE80211_FCTL_TODS is set
@@ -589,7 +617,7 @@ struct ieee80211s_hdr {
        __le32 seqnum;
        u8 eaddr1[6];
        u8 eaddr2[6];
-} __packed;
+} __packed __aligned(2);
 
 /* Mesh flags */
 #define MESH_FLAGS_AE_A4       0x1
@@ -852,7 +880,7 @@ struct ieee80211_mgmt {
                        } u;
                } __packed action;
        } u;
-} __packed;
+} __packed __aligned(2);
 
 /* Supported Rates value encodings in 802.11n-2009 7.3.2.2 */
 #define BSS_MEMBERSHIP_SELECTOR_HT_PHY 127
@@ -883,20 +911,20 @@ struct ieee80211_rts {
        __le16 duration;
        u8 ra[6];
        u8 ta[6];
-} __packed;
+} __packed __aligned(2);
 
 struct ieee80211_cts {
        __le16 frame_control;
        __le16 duration;
        u8 ra[6];
-} __packed;
+} __packed __aligned(2);
 
 struct ieee80211_pspoll {
        __le16 frame_control;
        __le16 aid;
        u8 bssid[6];
        u8 ta[6];
-} __packed;
+} __packed __aligned(2);
 
 /* TDLS */
 
@@ -1284,11 +1312,6 @@ struct ieee80211_vht_operation {
 } __packed;
 
 
-#define IEEE80211_VHT_MCS_ZERO_TO_SEVEN_SUPPORT 0
-#define IEEE80211_VHT_MCS_ZERO_TO_EIGHT_SUPPORT 1
-#define IEEE80211_VHT_MCS_ZERO_TO_NINE_SUPPORT  2
-#define IEEE80211_VHT_MCS_NOT_SUPPORTED 3
-
 /* 802.11ac VHT Capabilities */
 #define IEEE80211_VHT_CAP_MAX_MPDU_LENGTH_3895                 0x00000000
 #define IEEE80211_VHT_CAP_MAX_MPDU_LENGTH_7991                 0x00000001
@@ -1303,10 +1326,11 @@ struct ieee80211_vht_operation {
 #define IEEE80211_VHT_CAP_RXSTBC_2                             0x00000200
 #define IEEE80211_VHT_CAP_RXSTBC_3                             0x00000300
 #define IEEE80211_VHT_CAP_RXSTBC_4                             0x00000400
+#define IEEE80211_VHT_CAP_RXSTBC_MASK                          0x00000700
 #define IEEE80211_VHT_CAP_SU_BEAMFORMER_CAPABLE                        0x00000800
 #define IEEE80211_VHT_CAP_SU_BEAMFORMEE_CAPABLE                        0x00001000
 #define IEEE80211_VHT_CAP_BEAMFORMER_ANTENNAS_MAX              0x00006000
-#define IEEE80211_VHT_CAP_SOUNDING_DIMENTION_MAX               0x00030000
+#define IEEE80211_VHT_CAP_SOUNDING_DIMENSIONS_MAX              0x00030000
 #define IEEE80211_VHT_CAP_MU_BEAMFORMER_CAPABLE                        0x00080000
 #define IEEE80211_VHT_CAP_MU_BEAMFORMEE_CAPABLE                        0x00100000
 #define IEEE80211_VHT_CAP_VHT_TXOP_PS                          0x00200000
index 2282847d4bb898fa2f09f858f9530b9ae6191300..019a1cce36beddc4a3af3769198724ef5dfd7825 100644 (file)
@@ -1,7 +1,7 @@
 #ifndef __CARL9170_SHARED_VERSION_H
 #define __CARL9170_SHARED_VERSION_H
-#define CARL9170FW_VERSION_YEAR 12
-#define CARL9170FW_VERSION_MONTH 12
-#define CARL9170FW_VERSION_DAY 15
-#define CARL9170FW_VERSION_GIT "1.9.7"
+#define CARL9170FW_VERSION_YEAR 13
+#define CARL9170FW_VERSION_MONTH 3
+#define CARL9170FW_VERSION_DAY 23
+#define CARL9170FW_VERSION_GIT "1.9.8"
 #endif /* __CARL9170_SHARED_VERSION_H */
index b01276088177be35cbcbd10888fad2a1265db71c..ed3dcae53d37632a6e3c89acfe281d1abe5de8f4 100644 (file)
@@ -6,7 +6,7 @@ NEWLIB_VER=2.0.0
 NEWLIB_TAR=newlib-$(NEWLIB_VER).tar.gz
 NEWLIB_URL="ftp://sourceware.org/pub/newlib/$(NEWLIB_TAR)"
 
-GCC_VER=4.7.2
+GCC_VER=4.8.0
 GCC_TAR=gcc-$(GCC_VER).tar.bz2
 GCC_URL="http://mirrors.kernel.org/gnu/gcc/gcc-$(GCC_VER)/$(GCC_TAR)"
 
index d1b78968ca5afa0f886cc26db82e7ae8fbe2caf0..c8439d9fb21af2d5496b28ba73efbaa0300e6ee1 100644 (file)
@@ -4,4 +4,5 @@ c644b2847244278c57bec2ddda69d8fab5a7c767f3b9af69aa7aa3da823ff692  src/newlib-1.2
 2ab2e5b03e086d12c6295f831adad46b3e1410a3a234933a2e8fac66cb2e7a19  src/binutils-2.23.1.tar.bz2
 8a9283d7010fb9fe5ece3ca507e0af5c19412626384f8a5e9434251ae100b084  src/gcc-4.7.2.tar.bz2
 49c29e9129325e7c3b221aa829743ddcd796d024440e47c80fc0d6769af72d8a  src/newlib-2.0.0.tar.gz
+b037fe5132b71ecad2ea7141ec92292b5d32427bf90fd90cde432b1d5abacc2c  src/gcc-4.8.0.tar.bz2