This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

AM335x UART0 debug problem

Other Parts Discussed in Thread: TPS65217

Our board could work fine with kernel linux 3.2 and linux 3.12.

After when porting driver to kernel linux 4.1. The board could boot up and mount the file system.

But, could access to the file system, and could not type or input character to debug port (uart0).

log:

Thu Jan  1 01:21:00 UTC 1970
INIT: Entering runlevel: 5
Starting system message bus: [    8.116494] random: dbus-daemon urandom read with 46 bits of entropy available
Failed to start message bus: Failed to read directory "/etc/dbus-1/system.d": No such file or directory
Starting telnet daemon.
Starting syslogd/klogd: done
Stopping Bootlog daemon: bootlogd.

Then it's like the debug port dead.

  • I will forward this to the software team.
  • After replace rootfs from tisdk-rootfs-image-am335x-evm.tar.gz, could not access to command line (could not type any character include "Enter", but could insert any character or key before the last log displayed bellow.


    [ 0.000000] Booting Linux on physical CPU 0x0
    [ 0.000000] Initializing cgroup subsys cpu
    [ 0.000000] Initializing cgroup subsys cpuacct
    [ 0.000000] Linux version 4.1.18-gbbe8cfc (linux64@linux64) (gcc version 4.9.3 20150413 (prerelease) (Linaro GCC 4.9-2015.05) ) #46
    [ 0.000000] CPU: ARMv7 Processor [413fc082] revision 2 (ARMv7), cr=10c5387d
    [ 0.000000] CPU: PIPT / VIPT nonaliasing data cache, VIPT aliasing instruction cache
    [ 0.000000] Machine model: TI AM335x EVM
    [ 0.000000] cma: Reserved 24 MiB at 0x9d800000
    [ 0.000000] Memory policy: Data cache writeback
    [ 0.000000] CPU: All CPU(s) started in SVC mode.
    [ 0.000000] AM335X ES2.1 (sgx neon )
    [ 0.000000] Built 1 zonelists in Zone order, mobility grouping on. Total pages: 129920
    [ 0.000000] Kernel command line: console=ttyS0,115200n8 root=/dev/mmcblk0p2 ro rootfstype=ext4 rootwait
    [ 0.000000] PID hash table entries: 2048 (order: 1, 8192 bytes)
    [ 0.000000] Dentry cache hash table entries: 65536 (order: 6, 262144 bytes)
    [ 0.000000] Inode-cache hash table entries: 32768 (order: 5, 131072 bytes)
    [ 0.000000] Memory: 484564K/524288K available (6771K kernel code, 278K rwdata, 2272K rodata, 272K init, 235K bss, 15148K reserved,)
    [ 0.000000] Virtual kernel memory layout:
    [ 0.000000] vector : 0xffff0000 - 0xffff1000 ( 4 kB)
    [ 0.000000] fixmap : 0xffc00000 - 0xfff00000 (3072 kB)
    [ 0.000000] vmalloc : 0xe0800000 - 0xff000000 ( 488 MB)
    [ 0.000000] lowmem : 0xc0000000 - 0xe0000000 ( 512 MB)
    [ 0.000000] pkmap : 0xbfe00000 - 0xc0000000 ( 2 MB)
    [ 0.000000] modules : 0xbf000000 - 0xbfe00000 ( 14 MB)
    [ 0.000000] .text : 0xc0008000 - 0xc08dd05c (9045 kB)
    [ 0.000000] .init : 0xc08de000 - 0xc0922000 ( 272 kB)
    [ 0.000000] .data : 0xc0922000 - 0xc09679c0 ( 279 kB)
    [ 0.000000] .bss : 0xc096a000 - 0xc09a4fc8 ( 236 kB)
    [ 0.000000] SLUB: HWalign=64, Order=0-3, MinObjects=0, CPUs=1, Nodes=1
    [ 0.000000] Preemptible hierarchical RCU implementation.
    [ 0.000000] Additional per-CPU info printed with stalls.
    [ 0.000000] NR_IRQS:16 nr_irqs:16 16
    [ 0.000000] IRQ: Found an INTC at 0xfa200000 (revision 5.0) with 128 interrupts
    [ 0.000000] OMAP clockevent source: timer2 at 24000000 Hz
    [ 0.000030] sched_clock: 32 bits at 24MHz, resolution 41ns, wraps every 89478484971ns
    [ 0.000078] clocksource timer1: mask: 0xffffffff max_cycles: 0xffffffff, max_idle_ns: 79635851949 ns
    [ 0.000103] OMAP clocksource: timer1 at 24000000 Hz
    [ 0.000480] Console: colour dummy device 80x30
    [ 0.000549] Calibrating delay loop... 298.59 BogoMIPS (lpj=1492992)
    [ 0.067580] pid_max: default: 32768 minimum: 301
    [ 0.067835] Security Framework initialized
    [ 0.067951] Mount-cache hash table entries: 1024 (order: 0, 4096 bytes)
    [ 0.067979] Mountpoint-cache hash table entries: 1024 (order: 0, 4096 bytes)
    [ 0.069512] Initializing cgroup subsys blkio
    [ 0.069565] Initializing cgroup subsys memory
    [ 0.069657] Initializing cgroup subsys devices
    [ 0.069694] Initializing cgroup subsys freezer
    [ 0.069728] Initializing cgroup subsys perf_event
    [ 0.069792] CPU: Testing write buffer coherency: ok
    [ 0.070559] Setting up static identity map for 0x80008200 - 0x80008270
    [ 0.074173] devtmpfs: initialized
    [ 0.106249] VFP support v0.3: implementor 41 architecture 3 part 30 variant c rev 3
    [ 0.141043] omap_hwmod: debugss: _wait_target_disable failed
    [ 0.210932] clocksource jiffies: mask: 0xffffffff max_cycles: 0xffffffff, max_idle_ns: 19112604462750000 ns
    [ 0.215622] pinctrl core: initialized pinctrl subsystem
    [ 0.218803] NET: Registered protocol family 16
    [ 0.224287] DMA: preallocated 256 KiB pool for atomic coherent allocations
    [ 0.247660] cpuidle: using governor ladder
    [ 0.277646] cpuidle: using governor menu
    [ 0.288932] OMAP GPIO hardware version 0.1
    [ 0.311758] omap-gpmc 50000000.gpmc: could not find pctldev for node /ocp/l4_wkup@44c00000/scm@210000/pinmux@800/nandflash_pins_dee
    [ 0.319908] No ATAGs?
    [ 0.319969] hw-breakpoint: debug architecture 0x4 unsupported.
    [ 0.393302] edma 49000000.edma: TI EDMA DMA engine driver
    [ 0.404275] vgaarb: loaded
    [ 0.406128] SCSI subsystem initialized
    [ 0.406941] usbcore: registered new interface driver usbfs
    [ 0.407130] usbcore: registered new interface driver hub
    [ 0.407411] usbcore: registered new device driver usb
    [ 0.408551] omap_i2c 44e0b000.i2c: could not find pctldev for node /ocp/l4_wkup@44c00000/scm@210000/pinmux@800/pinmux_i2c0_pins, de
    [ 0.408674] omap_i2c 4802a000.i2c: could not find pctldev for node /ocp/l4_wkup@44c00000/scm@210000/pinmux@800/pinmux_i2c1_pins, de
    [ 0.409025] media: Linux media interface: v0.10
    [ 0.409198] Linux video capture interface: v2.00
    [ 0.409344] pps_core: LinuxPPS API ver. 1 registered
    [ 0.409365] pps_core: Software ver. 5.3.6 - Copyright 2005-2007 Rodolfo Giometti <giometti@linux.it>
    [ 0.409443] PTP clock support registered
    [ 0.411550] omap-mailbox 480c8000.mailbox: omap mailbox rev 0x400
    [ 0.412137] Advanced Linux Sound Architecture Driver Initialized.
    [ 0.414254] Switched to clocksource timer1
    [ 0.442183] NET: Registered protocol family 2
    [ 0.444119] TCP established hash table entries: 4096 (order: 2, 16384 bytes)
    [ 0.444408] TCP bind hash table entries: 4096 (order: 2, 16384 bytes)
    [ 0.444534] TCP: Hash tables configured (established 4096 bind 4096)
    [ 0.444714] UDP hash table entries: 256 (order: 0, 4096 bytes)
    [ 0.444766] UDP-Lite hash table entries: 256 (order: 0, 4096 bytes)
    [ 0.445158] NET: Registered protocol family 1
    [ 0.445936] RPC: Registered named UNIX socket transport module.
    [ 0.445971] RPC: Registered udp transport module.
    [ 0.445989] RPC: Registered tcp transport module.
    [ 0.446007] RPC: Registered tcp NFSv4.1 backchannel transport module.
    [ 0.448011] CPU PMU: Failed to parse /pmu/interrupt-affinity[0]
    [ 0.448125] hw perfevents: enabled with armv7_cortex_a8 PMU driver, 5 counters available
    [ 0.453256] futex hash table entries: 256 (order: -1, 3072 bytes)
    [ 0.453483] audit: initializing netlink subsys (disabled)
    [ 0.453624] audit: type=2000 audit(0.440:1): initialized
    [ 0.473283] VFS: Disk quotas dquot_6.6.0
    [ 0.473779] VFS: Dquot-cache hash table entries: 1024 (order 0, 4096 bytes)
    [ 0.479444] NFS: Registering the id_resolver key type
    [ 0.479587] Key type id_resolver registered
    [ 0.479609] Key type id_legacy registered
    [ 0.479796] jffs2: version 2.2. (NAND) (SUMMARY) �© 2001-2006 Red Hat, Inc.
    [ 0.488464] NET: Registered protocol family 38
    [ 0.488616] io scheduler noop registered
    [ 0.488649] io scheduler deadline registered
    [ 0.488788] io scheduler cfq registered (default)
    [ 0.491496] pinctrl-single 44e10800.pinmux: 142 pins at pa f9e10800 size 568
    [ 0.497869] backlight supply power not found, using dummy regulator
    [ 0.501986] wkup_m3_ipc 44e11324.wkup_m3_ipc: could not get rproc handle
    [ 0.504940] Serial: 8250/16550 driver, 10 ports, IRQ sharing enabled
    [ 0.514209] console [ttyS0] disabled
    [ 0.514873] 44e09000.serial: ttyS0 at MMIO 0x44e09000 (irq = 158, base_baud = 3000000) is a 8250
    [ 1.173453] console [ttyS0] enabled
    [ 1.179301] 48022000.serial: ttyS1 at MMIO 0x48022000 (irq = 159, base_baud = 3000000) is a 8250
    [ 1.190418] 48024000.serial: ttyS2 at MMIO 0x48024000 (irq = 160, base_baud = 3000000) is a 8250
    [ 1.201430] 481a6000.serial: ttyS3 at MMIO 0x481a6000 (irq = 161, base_baud = 3000000) is a 8250
    [ 1.212391] 481a8000.serial: ttyS4 at MMIO 0x481a8000 (irq = 162, base_baud = 3000000) is a 8250
    [ 1.225469] omap_rng 48310000.rng: OMAP Random Number Generator ver. 20
    [ 1.232535] [drm] Initialized drm 1.1.0 20060810
    [ 1.238463] panel panel: pins are not configured
    [ 1.246316] [drm] Supports vblank timestamp caching Rev 2 (21.10.2013).
    [ 1.252994] [drm] No driver support for vblank timestamp query.
    [ 1.278014] Console: switching to colour frame buffer device 30x40
    [ 1.287412] tilcdc 4830e000.lcdc: fb0: frame buffer device
    [ 1.293369] tilcdc 4830e000.lcdc: registered panic notifier
    [ 1.324331] [drm] Initialized tilcdc 1.0.0 20121205 on minor 0
    [ 1.357138] brd: module loaded
    [ 1.373473] loop: module loaded
    [ 1.380128] mtdoops: mtd device (mtddev=name/number) must be supplied
    [ 1.394867] ehci_hcd: USB 2.0 'Enhanced' Host Controller (EHCI) Driver
    [ 1.401478] ehci-pci: EHCI PCI platform driver
    [ 1.406312] ehci-platform: EHCI generic platform driver
    [ 1.412149] ohci_hcd: USB 1.1 'Open' Host Controller (OHCI) Driver
    [ 1.418508] ohci-pci: OHCI PCI platform driver
    [ 1.423528] usbcore: registered new interface driver cdc_wdm
    [ 1.429441] usbcore: registered new interface driver uas
    [ 1.435109] usbcore: registered new interface driver usb-storage
    [ 1.441292] usbcore: registered new interface driver ums_eneub6250
    [ 1.447690] usbcore: registered new interface driver ums-freecom
    [ 1.453917] usbcore: registered new interface driver ums-sddr55
    [ 1.461150] mousedev: PS/2 mouse device common for all mice
    [ 1.466996] i2c /dev entries driver
    [ 1.472276] sdhci: Secure Digital Host Controller Interface driver
    [ 1.478721] sdhci: Copyright(c) Pierre Ossman
    [ 1.485071] omap_hsmmc 48060000.mmc: Got CD GPIO
    [ 1.639168] usbcore: registered new interface driver ushc
    [ 1.645099] ledtrig-cpu: registered to indicate activity on CPUs
    [ 1.653053] remoteproc0: wkup_m3 is available
    [ 1.657905] remoteproc0: Note: remoteproc is still under development and considered experimental.
    [ 1.668132] remoteproc0: THE BINARY FORMAT IS NOT YET FINALIZED, and backward compatibility isn't yet guaranteed.
    [ 1.678951] remoteproc0: Direct firmware load for am335x-pm-firmware.elf failed with error -2
    [ 1.691605] pinctrl-single 44e10800.pinmux: pin 44e1090c.0 already requested by 48024000.serial; cannot claim for 4803c000.mcasp
    [ 1.703575] remoteproc0: Falling back to user helper
    [ 1.709155] pinctrl-single 44e10800.pinmux: pin-67 (4803c000.mcasp) status -22
    [ 1.716598] pinctrl-single 44e10800.pinmux: could not request pin 67 (44e1090c.0) from group am335x_evm_audio_pins on device pince
    [ 1.729376] davinci-mcasp 4803c000.mcasp: Error applying setting, reverse things back
    [ 1.739765] oprofile: using arm/armv7
    [ 1.744479] Initializing XFRM netlink socket
    [ 1.748884] NET: Registered protocol family 17
    [ 1.753450] NET: Registered protocol family 15
    [ 1.758348] Key type dns_resolver registered
    [ 1.763405] omap_voltage_late_init: Voltage driver support not added
    [ 1.770922] cpu cpu0: of_pm_voltdm_notifier_register: Failed to get cpu0 regulator/voltdm: -517
    [ 1.779890] cpu cpu0: cpu0 clock notifier not ready, retry
    [ 1.786403] ThumbEE CPU extension supported.
    [ 1.790772] Registering SWP/SWPB emulation handler
    [ 1.801466] omap-gpmc 50000000.gpmc: GPMC revision 6.0
    [ 1.806978] gpmc_mem_init: disabling cs 0 mapped at 0x0-0x1000000
    [ 1.816449] nand: device found, Manufacturer ID: 0x2c, Chip ID: 0xda
    [ 1.822855] nand: Micron MT29F2G08ABAEAWP
    [ 1.827108] nand: 256 MiB, SLC, erase size: 128 KiB, page size: 2048, OOB size: 64
    [ 1.834919] nand: using OMAP_ECC_BCH8_CODE_HW ECC scheme
    [ 1.840506] 10 ofpart partitions found on MTD device 8000000.nand
    [ 1.846766] Creating 10 MTD partitions on "8000000.nand":
    [ 1.852226] 0x000000000000-0x000000020000 : "NAND.SPL"
    [ 1.860387] 0x000000020000-0x000000040000 : "NAND.SPL.backup1"
    [ 1.868829] 0x000000040000-0x000000060000 : "NAND.SPL.backup2"
    [ 1.877309] 0x000000060000-0x000000080000 : "NAND.SPL.backup3"
    [ 1.885729] 0x000000080000-0x0000000c0000 : "NAND.u-boot-spl-os"
    [ 1.894125] 0x0000000c0000-0x0000001c0000 : "NAND.u-boot"
    [ 1.902413] 0x0000001c0000-0x0000001e0000 : "NAND.u-boot-env"
    [ 1.910595] 0x0000001e0000-0x000000200000 : "NAND.u-boot-env.backup1"
    [ 1.919585] 0x000000200000-0x000000a00000 : "NAND.kernel"
    [ 1.930777] 0x000000a00000-0x000010000000 : "NAND.file-system"
    [ 2.067360] tps65217 0-0024: TPS65217 ID 0xe version 1.2
    [ 2.072814] omap_i2c 44e0b000.i2c: bus 0 rev0.11 at 400 kHz
    [ 2.082292] omap_i2c 4802a000.i2c: bus 1 rev0.11 at 100 kHz
    [ 2.090721] omap_hsmmc 48060000.mmc: Got CD GPIO
    [ 2.139144] cpu cpu0: of_pm_voltdm_notifier_register: Fail calculating voltage latency[950000<->1260000]:-22
    [ 2.150229] cpu cpu0: of_pm_voltdm_notifier_register: Fail calculating voltage latency[950000<->1260000]:-22
    [ 2.167304] hctosys: unable to open rtc device (rtc0)
    [ 2.176742] wlan-en-regulator: disabling
    [ 2.180715] lis3_reg: disabling
    [ 2.183965] vbat: disabling
    [ 2.187009] ALSA device list:
    [ 2.190035] No soundcards found.
    [ 2.194889] Waiting for root device /dev/mmcblk0p2...
    [ 2.213128] mmc1: host does not support reading read-only switch, assuming write-enable
    [ 2.224476] mmc1: new high speed SDHC card at address aaaa
    [ 2.230726] mmcblk0: mmc1:aaaa SL08G 7.40 GiB
    [ 2.236976] mmcblk0: p1 p2
    [ 2.319471] EXT4-fs (mmcblk0p2): mounted filesystem with ordered data mode. Opts: (null)
    [ 2.327890] VFS: Mounted root (ext4 filesystem) readonly on device 179:2.
    [ 2.338291] devtmpfs: mounted
    [ 2.341815] Freeing unused kernel memory: 272K (c08de000 - c0922000)
    INIT: version 2.88 booting
    Starting udev
    cmp: EOF on /etc/udev/cache.data
    udev: Not using udev cache because of changes detected in the following files:
    udev: /proc/version /proc/cmdline /proc/devices
    udev: lib/udev/rules.d/* etc/udev/rules.d/*
    udev: The udev cache will be regenerated. To identify the detected changes,
    udev: compare the cached sysconf at /etc/udev/cache.data
    udev: against the current sysconf at /dev/shm/udev.cache
    [ 3.167928] udevd[94]: starting version 182
    [ 4.813885] remoteproc0: powering up wkup_m3
    [ 4.852694] remoteproc0: Booting fw image am335x-pm-firmware.elf, size 219803
    [ 4.972170] remoteproc0: remote processor wkup_m3 is now up
    [ 4.977921] wkup_m3_ipc 44e11324.wkup_m3_ipc: CM3 Firmware Version = 0x191
    [ 7.645527] FAT-fs (mmcblk0p1): Volume was not properly unmounted. Some data may be corrupt. Please run fsck.
    [ 8.003643] EXT4-fs (mmcblk0p2): warning: mounting fs with errors, running e2fsck is recommended
    [ 8.015885] EXT4-fs (mmcblk0p2): re-mounted. Opts: data=ordered
    bootlogd: cannot allocate pseudo tty: No such file or directory
    [ 8.153443] random: dd urandom read with 54 bits of entropy available
    Populating dev cache
    ALSA: Restoring mixer settings...
    /usr/sbin/alsactl: load_state:1729: No soundcards found...
    hwclock: can't open '/dev/misc/rtc': No such file or directory
    Fri Jan 8 23:20:04 UTC 2016
    hwclock: can't open '/dev/misc/rtc': No such file or directory
    INIT: Entering runlevel: 5
    Configuring network interfaces... ifconfig: SIOCGIFFLAGS: No such device
    done.
    Starting system message bus: dbus.
    Starting telnet daemon.
    Starting rpcbind daemon...rpcbind: cannot create socket for udp6
    rpcbind: cannot create socket for tcp6
    done.
    starting statd: done
    hwclock: can't open '/dev/misc/rtc': No such file or directory
    Starting syslogd/klogd: done
    Starting thttpd.
    Enabling thermal zones...
    /etc/rc5.d/S98thermal-zone-init: line 7: /sys/class/thermal/thermal_zone*/mode: No such file or directory

    _____ _____ _ _
    | _ |___ ___ ___ ___ | _ |___ ___ |_|___ ___| |_
    | | _| .'| . | . | | __| _| . | | | -_| _| _|
    |__|__|_| |__,|_ |___| |__| |_| |___|_| |___|___|_|
    |___| |___|

    Arago Project http://arago-project.org am335x-evm /dev/ttyS0

    Arago 2015.12 am335x-evm /dev/ttyS0

    am335x-evm login:
  • After fixed the rtc problem,  the debug port issue still exists.

  • In kernel , I try to print info with printk in timer callback function, in a simple driver I added.
    It could display info. before the last kernel log. After that, the debug port display nothing.
  • Hello Lield,

    If the sysvinit is present in your rootfs, check whether changing the line O0:12345:respawn:/sbin/getty -L 115200 ttyO0 in etc/inittab to S0:12345:respawn:/sbin/getty -L 115200 ttyS0 will have an effect, else your system should use systemd and you can check whether getty is started on ttyS0 by this message [ OK ] Started Serial Getty on ttyS0 on the boot log.

    Best regards,
    Kemal

  • Hi, Kemal,

    Thanks for your reply.

    For debug port, I modified the inittab refer to .  The root file system could boot up with other version kernel linux 3.2.0 and 3.12.0, which I got from TI's SDK.

    Best Regards

    Lield

  • Hi, Kemal

          How about this loopback?

    Thanks