2010-08-11 12:51:48 BF527, UARTs and SPORT Bus
Cameron Barfield (UNITED STATES)
Message: 92330
Howdy, everyone --
I'm running a BF-527 EZ-KIT Lite 2.2, BOM Revision 3.3. I'm running the latest checkout of 2009R1 for the kernel the distro, and u-boot.
I'm running the "internal" SSM2602 over I2S and SPORT0.
My boot args passed from u-boot are:
root=/dev/mtdblock0 rw clkin_hz=25000000 earlyprintk=serial,uart1,57600 console=tty0 console=ttyBF0,57600
My kernel config is attached (one_uart.config).
With this set up I can boot fine and the serial console and SSM2602 work fine. Here are some snippets from boot up process:
bootconsole [early_shadow0] enabled
bootconsole [early_BFuart0] enabled
early printk enabled on early_BFuart0
...
Kernel command line: root=/dev/mtdblock0 rw clkin_hz=25000000 earlyprintk=serial,uart1,57600 console=tty0 console=ttyBF0,57600
Configuring Blackfin Priority Driven Interrupts
PID hash table entries: 256 (order: 8, 1024 bytes)
Console: colour dummy device 80x25
console [tty0] enabled console [ttyBF0] enabled, bootconsole disabled console [ttyBF0] enabled, bootconsole disabled
Dentry cache hash table entries: 8192 (order: 3, 32768 bytes)
...
Advanced Linux Sound Architecture Driver Version 1.0.18rc3.
ASoC version 0.13.2
dma rx:3 tx:4, err irq:15, regs:ffc00800
ssm2602 Audio Codec 0.1<6>dma_alloc_init: dma_page @ 0x03aa5000 - 256 pages at 0x03f00000
asoc: SSM2602 <-> bf5xx-i2s mapping ok
ALSA device list:
#0: bf5xx_ssm2602 (SSM2602)
TCP cubic registered
I'm not sure where the kernel gets the idea that the bootconsole is disabled. It is enabled in the kernel config and u-boot is passing the console options to the kernel. Either way, everything boots up to the console and I get a prompt.
If I enable both UARTs (see attached two_uart.config) the console gets disabled at this point:
Console: colour dummy device 80x25
console [tty0] enabled
console [ttyBF0] enabled, bootconsole disabled
On top of that, it looks like there's a resource conflict between the SSM2602 and UART0. I telnet to the board and:
root:~> dmesg
<snip>
Advanced Linux Sound Architecture Driver Version 1.0.18rc3.
ASoC version 0.13.2
Hardware Trace:
0 Target : <0x00004b58> { _dump_stack + 0x0 }
Source : <0x00006478> { _peripheral_request + 0x104 } CALL pcrel
<snip>
Stack info:
SP: [0x03ee9cac] <0x03ee9cac> /* kernel dynamic memory */
FP: (0x03ee9cf8)
Memory from 0x03ee9ca0 to 03eea000
<snip>
Return addresses in stack:
address : <0x0000647c> { _peripheral_request + 0x108 }
<snip>
peripheral_request: Peripheral 24 function 1 is already reserved by bfin-uart !
Requesting Peripherals failed
soc-audio: probe of soc-audio failed with error -14
ALSA device list:
No soundcards found.
See attached messages.txt for full log from /var/log/messages
According to the datasheet for the 527 (rev. b, page 24) the only sharing that goes on between SPART0 and UART0 is:
GPIO/Timer3/Sport 0 Alternate Receive Data Primary/UART0 Transmit
I'm not sure what to make of "alternate receive data primary."
Please tell me I've messed up somewhere and it is possible to run both UARTs and the SPORT0 interface on a 527.
one_uart.config
two_uart.config
messages.txt
QuoteReplyEditDelete
2010-08-11 13:30:59 Re: BF527, UARTs and SPORT Bus
Mike Frysinger (UNITED STATES)
Message: 92331
bootconsoles are the earlyprintk ones, not your "console=" ones. that is correct output.
look at the kernel configuration menu for alternative portmux settings.
Blackfin Processor Options ->
BF527 Specific Configuration ->
*** Alternative Multiplexing Scheme ***
QuoteReplyEditDelete
2010-08-11 13:59:43 Re: BF527, UARTs and SPORT Bus
Cameron Barfield (UNITED STATES)
Message: 92332
Thanks, Mike.
I'll take a look at playing with the portmux settings. I imagine this means I'll need to much around with the dipswitches on the board, too.
I still don't get why enabling both serial ports kills my serial console, though.
QuoteReplyEditDelete
2010-08-11 14:52:09 Re: BF527, UARTs and SPORT Bus
Mike Frysinger (UNITED STATES)
Message: 92334
i dont know about the switches off the top of my head. i'd have to consult the manual on analog.com for the board.
i'm pretty sure 2009R1 counts UART's logically, not by the actual value. this has been fixed in trunk (2010R1). in other words, ttyBF0 is the first UART registered, it isnt always UART0.