Skip to content

Commit

Permalink
fix: add big endian comments
Browse files Browse the repository at this point in the history
  • Loading branch information
jean-roland committed Nov 30, 2023
1 parent 9ed1002 commit 9283187
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
2 changes: 1 addition & 1 deletion include/zenoh-pico/transport/raweth/config.h
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@

typedef struct {
_z_keyexpr_t _keyexpr;
uint16_t _vlan; // vlan tag (pcp + dei + id)
uint16_t _vlan; // vlan tag (pcp + dei + id), big endian
uint8_t _dmac[_ZP_MAC_ADDR_LENGTH];
_Bool _has_vlan;
} _zp_raweth_cfg_entry;
Expand Down
8 changes: 4 additions & 4 deletions src/transport/raweth/config.c
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@

#if Z_FEATURE_RAWETH_TRANSPORT == 1

// Should be generated
// Should be generated (big endian format)
const uint16_t _ZP_RAWETH_CFG_ETHTYPE = 0x72e0;

// Should be generated
Expand All @@ -27,9 +27,9 @@ const uint8_t _ZP_RAWETH_CFG_SMAC[_ZP_MAC_ADDR_LENGTH] = {0x30, 0x03, 0xc8, 0x37

// Should be generated
const _zp_raweth_cfg_entry _ZP_RAWETH_CFG_ARRAY[] = {
{{0, {0}, ""}, 0x00, {0xaa, 0xbb, 0xcc, 0xdd, 0xee, 0xff}, false}, // Default mac addr
{{0, {0}, "some/key/expr"}, 0x8c, {0x00, 0x11, 0x22, 0x33, 0x44, 0x55}, true}, // entry1
{{0, {0}, "another/keyexpr"}, 0x43, {0x01, 0x23, 0x45, 0x67, 0x89, 0xab}, true}, // entry2
{{0, {0}, ""}, 0x0000, {0xaa, 0xbb, 0xcc, 0xdd, 0xee, 0xff}, false}, // Default mac addr
{{0, {0}, "some/key/expr"}, 0x8c00, {0x00, 0x11, 0x22, 0x33, 0x44, 0x55}, true}, // entry1
{{0, {0}, "another/keyexpr"}, 0x4300, {0x01, 0x23, 0x45, 0x67, 0x89, 0xab}, true}, // entry2
};

// Should be generated
Expand Down

0 comments on commit 9283187

Please sign in to comment.