mirror of
https://github.com/apache/nuttx.git
synced 2026-08-10 23:15:15 +00:00
Fix errors in KL25Z SPI driver reported by Alan Carvalho de Assis
This commit is contained in:
parent
f3781d1eec
commit
bdc68f73ad
1 changed files with 4 additions and 4 deletions
|
|
@ -676,17 +676,17 @@ FAR struct spi_dev_s *kl_spiinitialize(int port)
|
|||
/* Enable clocking */
|
||||
|
||||
regval = getreg32(KL_SIM_SCGC4);
|
||||
regval |= SIM_SCGC4_SPI1;
|
||||
regval |= SIM_SCGC4_SPI0;
|
||||
putreg32(regval, KL_SIM_SCGC4);
|
||||
}
|
||||
else
|
||||
#endif
|
||||
#ifdef CONFIG_KL_SPI0
|
||||
if (port == 0)
|
||||
#ifdef CONFIG_KL_SPI1
|
||||
if (port == 1)
|
||||
{
|
||||
priv = &g_spi1dev;
|
||||
|
||||
/* Configure pins for SPI0 */
|
||||
/* Configure pins for SPI1 */
|
||||
|
||||
kl_configgpio(PIN_SPI1_SCK);
|
||||
kl_configgpio(PIN_SPI1_MISO);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue