[bsp]Mini optimized the drv_sound.c
1. "tx_fifo = rt_calloc(1, TX_FIFO_SIZE); " , so deleted the line "rt_memset(tx_fifo, 0, TX_FIFO_SIZE);" 2. " rx_fifo = rt_calloc(1, TX_FIFO_SIZE); " , so deleted the line "rt_memset(rx_fifo, 0, TX_FIFO_SIZE);"
This commit is contained in:
parent
21ebf93e20
commit
79267212ef
|
@ -453,7 +453,6 @@ static int rt_hw_sound_init(void)
|
||||||
return -RT_ENOMEM;
|
return -RT_ENOMEM;
|
||||||
}
|
}
|
||||||
|
|
||||||
rt_memset(tx_fifo, 0, TX_FIFO_SIZE);
|
|
||||||
snd_dev.tx_fifo = tx_fifo;
|
snd_dev.tx_fifo = tx_fifo;
|
||||||
|
|
||||||
/* 分配 DMA 搬运 buffer */
|
/* 分配 DMA 搬运 buffer */
|
||||||
|
@ -463,7 +462,6 @@ static int rt_hw_sound_init(void)
|
||||||
return -RT_ENOMEM;
|
return -RT_ENOMEM;
|
||||||
}
|
}
|
||||||
|
|
||||||
rt_memset(rx_fifo, 0, TX_FIFO_SIZE);
|
|
||||||
snd_dev.rx_fifo = rx_fifo;
|
snd_dev.rx_fifo = rx_fifo;
|
||||||
|
|
||||||
/* init default configuration */
|
/* init default configuration */
|
||||||
|
|
Loading…
Reference in New Issue