firmware-utils: replace GPL 2.0 boilerplate/reference with SPDX
[openwrt/staging/mkresin.git] / tools / firmware-utils / src / buffalo-lib.h
index ba8a508129473ab457d8a76d418dd664852c2321..030f7cd1d6d4aa1fb00a5d91081e65f3bdd2f6ca 100644 (file)
@@ -1,10 +1,6 @@
+// SPDX-License-Identifier: GPL-2.0-only
 /*
  *  Copyright (C) 2009-2011 Gabor Juhos <juhosg@openwrt.org>
- *
- *  This program is free software; you can redistribute it and/or modify it
- *  under the terms of the GNU General Public License version 2 as published
- *  by the Free Software Foundation.
- *
  */
 
 #ifndef _BUFFALO_LIB_H
@@ -69,6 +65,26 @@ struct buffalo_tag2 {
        uint8_t         unknown2[3];
 } __attribute ((packed));
 
+struct buffalo_tag3 {
+       unsigned char   product[TAG_PRODUCT_LEN];
+       unsigned char   brand[TAG_BRAND_LEN];
+       unsigned char   ver_major[TAG_VERSION_LEN];
+       unsigned char   ver_minor[TAG_VERSION_LEN];
+       unsigned char   region_code[2];
+       uint32_t        region_mask;
+       unsigned char   unknown0[2];
+       unsigned char   language[TAG_LANGUAGE_LEN];
+       unsigned char   platform[TAG_PLATFORM_LEN];
+       unsigned char   hwv[TAG_HWVER_LEN];
+       unsigned char   hwv_val[TAG_HWVER_VAL_LEN];
+       uint8_t         unknown1[24];
+
+       uint32_t        total_len;
+       uint32_t        crc;
+       uint32_t        len1;
+       uint32_t        base2;
+} __attribute ((packed));
+
 #define ENC_PRODUCT_LEN                32
 #define ENC_VERSION_LEN                8
 #define ENC_MAGIC_LEN          6