Skip to content

Commit a35bcd5

Browse files
author
Wu Zhigang
committed
ssp:replace the constant value with macro
replace the constant value with macro to be more generic. Signed-off-by: Wu Zhigang <zhigang.wu@linux.intel.com>
1 parent fad18ec commit a35bcd5

1 file changed

Lines changed: 4 additions & 2 deletions

File tree

src/drivers/apl-ssp.c

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -588,8 +588,10 @@ static inline int ssp_set_config(struct dai *dai,
588588
goto out;
589589
}
590590

591-
tft = MIN(8, sample_width * active_tx_slots);
592-
rft = MIN(8, sample_width * active_rx_slots);
591+
tft = MIN(SSP_FIFO_DEPTH - SSP_FIFO_WATERMARK,
592+
sample_width * active_tx_slots);
593+
rft = MIN(SSP_FIFO_DEPTH - SSP_FIFO_WATERMARK,
594+
sample_width * active_rx_slots);
593595

594596
sscr3 |= SSCR3_TX(tft) | SSCR3_RX(rft);
595597

0 commit comments

Comments
 (0)