Skip to content

Commit

Permalink
sam3x: spi: missing macro
Browse files Browse the repository at this point in the history
Add missing SPI_CSR_BITS macro for sam3x variants

Signed-off-by: Eve Redero <[email protected]>
  • Loading branch information
everedero authored and nandojve committed Feb 28, 2025
1 parent da76744 commit cd0ddbb
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 0 deletions.
1 change: 1 addition & 0 deletions asf/sam/include/sam3x/README
Original file line number Diff line number Diff line change
Expand Up @@ -43,3 +43,4 @@ Patch Lst:
* Fix RSTC registers macros
* Fix PWM registers macros
* Fix SSC registers macros
* Fix missing SPI_CSR_BITS macro
1 change: 1 addition & 0 deletions asf/sam/include/sam3x/component/spi.h
Original file line number Diff line number Diff line change
Expand Up @@ -125,6 +125,7 @@ typedef struct {
#define SPI_CSR_CSAAT (0x1u << 3) /**< \brief (SPI_CSR[4]) Chip Select Active After Transfer */
#define SPI_CSR_BITS_Pos 4
#define SPI_CSR_BITS_Msk (0xfu << SPI_CSR_BITS_Pos) /**< \brief (SPI_CSR[4]) Bits Per Transfer */
#define SPI_CSR_BITS(value) (SPI_CSR_BITS_Msk & ((value) << SPI_CSR_BITS_Pos))
#define SPI_CSR_BITS_8_BIT (0x0u << 4) /**< \brief (SPI_CSR[4]) 8 bits for transfer */
#define SPI_CSR_BITS_9_BIT (0x1u << 4) /**< \brief (SPI_CSR[4]) 9 bits for transfer */
#define SPI_CSR_BITS_10_BIT (0x2u << 4) /**< \brief (SPI_CSR[4]) 10 bits for transfer */
Expand Down

0 comments on commit cd0ddbb

Please sign in to comment.