Skip to content
Snippets Groups Projects
  1. May 25, 2018
  2. May 24, 2018
  3. May 23, 2018
  4. May 22, 2018
  5. May 21, 2018
  6. May 18, 2018
  7. May 17, 2018
  8. May 14, 2018
    • Marian Buschsieweke's avatar
      gnrc/netif/hdr.h: Optimized structure layout · 4b8881ab
      Marian Buschsieweke authored
      Reordered struct members to not waste memory due to padding.
      
      Before:
      ``` C
      typedef struct {
          uint8_t src_l2addr_len;
          uint8_t dst_l2addr_len;
          kernel_pid_t if_pid;    // <-- 16 bit, is aligned to 16 bit
          uint8_t flags;
          uint8_t __padding_byte; // <-- Inserted to fulfill padding requirements
          int16_t rssi;           // <-- 16 bit, is NOT aligned to 16 bit
          uint8_t lqi;
          uint8_t __padding_byte2;// <-- Inserted to fulfill padding requirements
      } gnrc_netif_hdr_t;
      ```
      
      Now:
      ``` C
      typedef struct {
          uint8_t src_l2addr_len;
          uint8_t dst_l2addr_len;
          kernel_pid_t if_pid;    // <-- 16 bit, is aligned to 16 bit
          uint8_t flags;
          uint8_t lqi;
          int16_t rssi;           // <-- 16 bit, is aligned to 16 bit
      } gnrc_netif_hdr_t;
      ```
      
      When build for the `bluepill` board, the new layout reduces the size by 2 bytes.
      4b8881ab
  9. May 13, 2018
  10. May 11, 2018
  11. May 07, 2018
    • Gaëtan Harter's avatar
      crypto/ccm: fix _fits_in_nbytes function · fa33eacd
      Gaëtan Harter authored
      Function is broken with num_bytes >= 4.
      
      Could happen when storing input_len with len_encoding >= 4.
      It can take values from 2 to 8, so make it work for cases it would overflow.
      fa33eacd
    • Gaëtan Harter's avatar
      crypto/ccm: refactor input_len check in a function · ee311a33
      Gaëtan Harter authored
      Refactorg checking that length can be stored in a number of bytes to a
      subfunction.
      ee311a33
    • Wentao Shang's avatar
      crypto/ccm: fix input_len check · 89023b34
      Wentao Shang authored
      Maximum input_len depends only on length_encoding and not auth_data_len.
      The current length_max value was also wrong.
      
      RFC3610 page 2
      
         3. The message m, consisting of a string of l(m) octets where 0 <=
            l(m) < 2^(8L).  The length restriction ensures that l(m) can be
            encoded in a field of L octets.
      89023b34
  12. May 06, 2018
  13. May 04, 2018
  14. May 01, 2018
  15. Apr 28, 2018
  16. Apr 26, 2018
  17. Apr 25, 2018
  18. Apr 22, 2018
  19. Apr 20, 2018
  20. Apr 19, 2018
  21. Apr 16, 2018
Loading