Implement requested PR changes

Removes CFG_TUSB_ALT_BIT_PACKING_ALIGNMENT, and makes the manual padding
behavior standard.  Replaced unused variable name with TU_RESERVED.
This commit is contained in:
Jeremiah McCarthy
2021-02-18 13:26:03 -05:00
parent f8fbc0930b
commit 21f1cd4ec7
6 changed files with 10 additions and 59 deletions

View File

@@ -231,11 +231,6 @@ typedef struct TU_ATTR_ALIGNED(32)
uint32_t : 1; ///< reserved
uint32_t port_number : 7; ///< This field is the port number of the recipient transaction translator.
uint32_t direction : 1; ///< 0 = OUT; 1 = IN. This field encodes whether the full-speed transaction should be an IN or OUT.
#if CFG_TUSB_ALT_BIT_PACKING_ALIGNMENT
///< All 32 bits are used
#else
uint32_t : 0; // padding to the end of current storage unit
#endif /* CFG_TUSB_ALT_BIT_PACKING_ALIGNMENT */
// Word 2: Micro-frame Schedule Control
uint8_t int_smask ; ///< This field (along with the Activeand SplitX-statefields in the Statusbyte) are used to determine during which micro-frames the host controller should execute complete-split transactions
@@ -427,11 +422,7 @@ typedef volatile struct
uint32_t nxp_port_force_fullspeed : 1; ///< NXP customized: Writing this bit to a 1 will force the port to only connect at Full Speed. It disables the chirp sequence that allowsthe port to identify itself as High Speed. This is useful for testing FS configurations with a HS host, hub or device.
uint32_t : 1;
uint32_t nxp_port_speed : 2; ///< NXP customized: This register field indicates the speed atwhich the port is operating. For HS mode operation in the host controllerand HS/FS operation in the device controller the port routing steers data to the Protocol engine. For FS and LS mode operation in the host controller, the port routing steers data to the Protocol Engine w/ Embedded Transaction Translator. 0x0: Fullspeed, 0x1: Lowspeed, 0x2: Highspeed
#if CFG_TUSB_ALT_BIT_PACKING_ALIGNMENT
uint32_t unused : 4; ///< padding
#else
uint32_t : 0; // padding to the boundary of storage unit
#endif /* CFG_TUSB_ALT_BIT_PACKING_ALIGNMENT */
uint32_t TU_RESERVED : 4;
}portsc_bm;
};
}ehci_registers_t;

View File

@@ -163,11 +163,7 @@ typedef struct {
uint16_t high_speed : 1;
uint16_t port_test_mode : 1;
uint16_t port_indicator_control : 1;
#if CFG_TUSB_ALT_BIT_PACKING_ALIGNMENT
uint16_t unused : 3;
#else
uint16_t : 0;
#endif /* CFG_TUSB_ALT_BIT_PACKING_ALIGNMENT */
uint16_t TU_RESERVED : 3;
};
uint16_t value;

View File

@@ -208,11 +208,7 @@ typedef volatile struct
uint32_t interrupt_routing : 1;
uint32_t remote_wakeup_connected : 1;
uint32_t remote_wakeup_enale : 1;
#if CFG_TUSB_ALT_BIT_PACKING_ALIGNMENT
uint32_t unused : 21;
#else
uint32_t : 0;
#endif /* CFG_TUSB_ALT_BIT_PACKING_ALIGNMENT */
uint32_t TU_RESERVED : 21;
}control_bit;
};
@@ -280,11 +276,7 @@ typedef volatile struct
uint32_t port_suspend_status_change : 1;
uint32_t port_over_current_indicator_change : 1;
uint32_t port_reset_status_change : 1;
#if CFG_TUSB_ALT_BIT_PACKING_ALIGNMENT
uint32_t unused : 11;
#else
uint32_t : 0;
#endif /* CFG_TUSB_ALT_BIT_PACKING_ALIGNMENT */
uint32_t TU_RESERVED : 11;
}rhport_status_bit[2];
};
}ohci_registers_t;