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.

Linux/PROCESSOR-SDK-AM437X: trouble accessing sst25vf016 flash

Part Number: PROCESSOR-SDK-AM437X
Other Parts Discussed in Thread: AM4372

Tool/software: Linux

I assume I am making some naive mistake, I expect that if i  have the right driver and the correct dts I should see a /dev/mtdx entry.  Am i missing somthing?  I see no spi2 or flash messages in dmesg.

Here is my setup.

1. no changes in u-boot.  (don't need to access part there).

2. part is connected to spi2  

3.  added stt flash drive in  Device Drivers > Memory Technology Device (MTD) support > Self-contained MTD device drivers turned on Support SST25L

4. pin set up.  Note I have tried PIN_ all INPUT as one forum article suggested.

spi2_pins: spi2_pins {
pinctrl-single,pins = <
AM4372_IOPAD(0xa60, PIN_INPUT_PULLUP | MUX_MODE3) /* (AC18) cam0_field.spi2_sclk */
AM4372_IOPAD(0xa64, PIN_INPUT_PULLUP | MUX_MODE3) /* (AD17) cam0_wen.spi2_d0 */
AM4372_IOPAD(0xa68, PIN_OUTPUT_PULLUP | MUX_MODE3) /* (AD18) cam0_vd.spi2_d1 */
AM4372_IOPAD(0xa6c, PIN_OUTPUT_PULLUP | MUX_MODE3) /* (AC20) cam0_pclk.spi2_cs0 */
>;
};

4, bus entry:  (added dma after i noticed warning in dmesg, needed?)

&spi2 {
status = "okay";
pinctrl-names = "default";
pinctrl-0=<&spi2_pins>;

// needed? correct dma channel?
dmas = <&edma 16 0 &edma 17 0>;
dma-names = "tx0", "rx0";

flash:flash@1 {
//compatible = "sst, sst25vf016b", "jedec,spi-nor";
compatible = "sst, sst25vf016b";
spi-max-frequency = <20000000>;
reg = <0>;
};
};

  • Hi James,

    Per mine understanding, you are using AM437x custom board.

    Which version of the AM437x TI PSDK Linux you are using? The latest version is 5.02 (kernel 4.14.79).

    It seems to me that you are missing "partition" entries in your DTS file. You can refer to the below DTS files for example of McSPI Flash partitions entries:

    linux-kernel/arch/arm/boot/dts/am437x-cm-t43.dts

    &spi0 {
    status = "okay";
    pinctrl-names = "default";
    pinctrl-0 = <&spi0_pins>;
    dmas = <&edma 16 0 &edma 17 0>;
    dma-names = "tx0", "rx0";

    flash: w25q64cvzpig@0 {
    #address-cells = <1>;
    #size-cells = <1>;
    compatible = "jedec,spi-nor";
    reg = <0>;
    spi-max-frequency = <20000000>;
    partition@0 {
    label = "uboot";
    reg = <0x0 0xc0000>;
    };

    partition@c0000 {
    label = "uboot environment";
    reg = <0xc0000 0x40000>;
    };

    partition@100000 {
    label = "reserved";
    reg = <0x100000 0x100000>;
    };
    };
    };

    You can get more McSPI flash examples also in below DTS files:

    linux-kernel/arch/arm/boot/dts/am335x-icev2-common.dtsi
    linux-kernel/arch/arm/boot/dts/am335x-moxa-uc-8100-me-t.dts

    You can also check how QSPI flash is partitioned in AM437x StarterKit board:

    linux-kernel/arch/arm/boot/dts/am437x-sk-evm.dts


    Regards,
    Pavel
  • I am currently developing against /ti-processor-sdk-linux-am437x-evm-04.03.00.05  perhaps I should update...

    I seem to recall seeing some sort of versions/release schedule slide is that around?

    I added partitions, but so far no luck.  I assume partition@NNN that NNN is just a label?  what are the values in the register for ?  I thought originally start address len for the partion in memory?

  • James,

    Yes, NNN is just a label. You need to fill the partition's offset and size within the flash in the reg property. Check below file for more info:

    linux-kernel/Documentation/devicetree/bindings/mtd/partition.txt

    Please attach below files for review:

    1) .config
    2) DTS
    3) full boot up log
    4) the output of this userspace command: "$cat /proc/mtd"

    Regards,
    Pavel
  • U-Boot SPL 2017.01-00458-gccd1c34-dirty (Jan 25 2019 - 15:47:08)
    Trying to boot from MMC1
    SPL: Please implement spl_start_uboot() for your board
    SPL: Direct Linux boot not active!
    reading u-boot.img
    reading u-boot.img
    reading u-boot.img
    reading u-boot.img
    
    
    U-Boot 2017.01-00458-gccd1c34-dirty (Jan 25 2019 - 15:47:08 -0500)
    
    CPU  : AM437X-GP rev 1.2
    Model: TI AM437x SK EVM
    DRAM:  1 GiB
    PMIC:  TPS65218
    NAND:  0 MiB
    MMC:   OMAP SD/MMC: 0
    reading uboot.env
    
    ** Unable to read "uboot.env" from mmc0:1 **
    Using default environment
    
    Net:   <ethaddr> not set. Validating first E-fuse MAC
    Could not get PHY for cpsw: addr 4
    cpsw, usb_ether
    Hit any key to stop autoboot:  0
    switch to partitions #0, OK
    mmc0 is current device
    SD/MMC found on device 0
    reading boot.scr
    ** Unable to read file boot.scr **
    reading uEnv.txt
    ** Unable to read file uEnv.txt **
    switch to partitions #0, OK
    mmc0 is current device
    SD/MMC found on device 0
    3640880 bytes read in 771 ms (4.5 MiB/s)
    48801 bytes read in 27 ms (1.7 MiB/s)
    ## Flattened Device Tree blob at 88000000
       Booting using the fdt blob at 0x88000000
       Loading Device Tree to 8fff1000, end 8ffffea0 ... OK
    
    Starting kernel ...
    
    [    0.000000] Booting Linux on physical CPU 0x0
    [    0.000000] Linux version 4.9.69-g9ce43c71ae (jsp@rover) (gcc version 6.2.1 20161016 (Linaro GCC 6.2-2016.11) ) #1 PREEMPT Fri Jan 25 15:44:06 EST 2019
    [    0.000000] CPU: ARMv7 Processor [412fc09a] revision 10 (ARMv7), cr=10c53c7d
    [    0.000000] CPU: PIPT / VIPT nonaliasing data cache, VIPT aliasing instruction cache
    [    0.000000] OF: fdt:Machine model: TI AM437x SK EVM
    [    0.000000] efi: Getting EFI parameters from FDT:
    [    0.000000] efi: UEFI not found.
    [    0.000000] cma: Reserved 48 MiB at 0xbd000000
    [    0.000000] Memory policy: Data cache writeback
    [    0.000000] CPU: All CPU(s) started in SVC mode.
    [    0.000000] AM437x ES1.2 (sgx neon)
    [    0.000000] Built 1 zonelists in Zone order, mobility grouping on.  Total pages: 260416
    [    0.000000] Kernel command line: console=ttyO0,115200n8 root=PARTUUID=2cd78e77-02 rw rootfstype=ext4 rootwait
    [    0.000000] PID hash table entries: 4096 (order: 2, 16384 bytes)
    [    0.000000] Dentry cache hash table entries: 131072 (order: 7, 524288 bytes)
    [    0.000000] Inode-cache hash table entries: 65536 (order: 6, 262144 bytes)
    [    0.000000] Memory: 977300K/1048576K available (7168K kernel code, 292K rwdata, 2384K rodata, 1024K init, 281K bss, 22124K reserved, 49152K cma-reserved, 212992K highmem)
    [    0.000000] Virtual kernel memory layout:
    [    0.000000]     vector  : 0xffff0000 - 0xffff1000   (   4 kB)
    [    0.000000]     fixmap  : 0xffc00000 - 0xfff00000   (3072 kB)
    [    0.000000]     vmalloc : 0xf0800000 - 0xff800000   ( 240 MB)
    [    0.000000]     lowmem  : 0xc0000000 - 0xf0000000   ( 768 MB)
    [    0.000000]     pkmap   : 0xbfe00000 - 0xc0000000   (   2 MB)
    [    0.000000]     modules : 0xbf000000 - 0xbfe00000   (  14 MB)
    [    0.000000]       .text : 0xc0008000 - 0xc0800000   (8160 kB)
    [    0.000000]       .init : 0xc0b00000 - 0xc0c00000   (1024 kB)
    [    0.000000]       .data : 0xc0c00000 - 0xc0c490c8   ( 293 kB)
    [    0.000000]        .bss : 0xc0c490c8 - 0xc0c8f7f4   ( 282 kB)
    [    0.000000] SLUB: HWalign=64, Order=0-3, MinObjects=0, CPUs=1, Nodes=1
    [    0.000000] Preemptible hierarchical RCU implementation.
    [    0.000000]  Build-time adjustment of leaf fanout to 32.
    [    0.000000] NR_IRQS:16 nr_irqs:16 16
    [    0.000000] L2C: platform modifies aux control register: 0x0e030000 -> 0x3e430000
    [    0.000000] L2C: DT/platform modifies aux control register: 0x0e030000 -> 0x3e430000
    [    0.000000] L2C-310 enabling early BRESP for Cortex-A9
    [    0.000000] OMAP L2C310: ROM does not support power control setting
    [    0.000000] L2C-310 dynamic clock gating disabled, standby mode disabled
    [    0.000000] L2C-310 cache controller enabled, 16 ways, 256 kB
    [    0.000000] L2C-310: CACHE_ID 0x410000c9, AUX_CTRL 0x4e430000
    [    0.000000] OMAP clockevent source: timer2 at 24000000 Hz
    [    0.000012] sched_clock: 32 bits at 24MHz, resolution 41ns, wraps every 89478484971ns
    [    0.000029] clocksource: timer1: mask: 0xffffffff max_cycles: 0xffffffff, max_idle_ns: 79635851949 ns
    [    0.000037] OMAP clocksource: timer1 at 24000000 Hz
    [    0.000382] clocksource: 32k_counter: mask: 0xffffffff max_cycles: 0xffffffff, max_idle_ns: 58327039986419 ns
    [    0.000393] OMAP clocksource: 32k_counter at 32768 Hz
    [    0.000731] Console: colour dummy device 80x30
    [    0.000756] WARNING: Your 'console=ttyO0' has been replaced by 'ttyS0'
    [    0.000762] This ensures that you still see kernel messages. Please
    [    0.000767] update your kernel commandline.
    [    0.000785] Calibrating delay loop... 1987.37 BogoMIPS (lpj=9936896)
    [    0.060166] pid_max: default: 32768 minimum: 301
    [    0.060286] Mount-cache hash table entries: 2048 (order: 1, 8192 bytes)
    [    0.060297] Mountpoint-cache hash table entries: 2048 (order: 1, 8192 bytes)
    [    0.061046] CPU: Testing write buffer coherency: ok
    [    0.061388] Setting up static identity map for 0x80100000 - 0x80100060
    [    0.062145] EFI services will not be available.
    [    0.062941] devtmpfs: initialized
    [    0.073367] VFP support v0.3: implementor 41 architecture 3 part 30 variant 9 rev 4
    [    0.073664] clocksource: jiffies: mask: 0xffffffff max_cycles: 0xffffffff, max_idle_ns: 19112604462750000 ns
    [    0.073685] futex hash table entries: 256 (order: -1, 3072 bytes)
    [    0.076901] pinctrl core: initialized pinctrl subsystem
    [    0.077985] NET: Registered protocol family 16
    [    0.079243] DMA: preallocated 256 KiB pool for atomic coherent allocations
    [    0.180176] cpuidle: using governor ladder
    [    0.210165] cpuidle: using governor menu
    [    0.216952] OMAP GPIO hardware version 0.1
    [    0.231770] omap_gpio gpios: could not find pctldev for node /ocp@44000000/l4_wkup@44c00000/scm@210000/pinmux@800/gpio_pins, deferring probe
    [    0.233111] No ATAGs?
    [    0.233136] hw-breakpoint: found 5 (+1 reserved) breakpoint and 1 watchpoint registers.
    [    0.233146] hw-breakpoint: maximum watchpoint size is 4 bytes.
    [    0.266699] edma 49000000.edma: TI EDMA DMA engine driver
    [    0.269758] omap_i2c 44e0b000.i2c: could not find pctldev for node /ocp@44000000/l4_wkup@44c00000/scm@210000/pinmux@800/i2c0_pins, deferring probe
    [    0.269815] omap_i2c 4802a000.i2c: could not find pctldev for node /ocp@44000000/l4_wkup@44c00000/scm@210000/pinmux@800/i2c1_pins, deferring probe
    [    0.269933] media: Linux media interface: v0.10
    [    0.269975] Linux video capture interface: v2.00
    [    0.270022] pps_core: LinuxPPS API ver. 1 registered
    [    0.270029] pps_core: Software ver. 5.3.6 - Copyright 2005-2007 Rodolfo Giometti <giometti@linux.it>
    [    0.270050] PTP clock support registered
    [    0.270082] EDAC MC: Ver: 3.0.0
    [    0.271026] omap-mailbox 480c8000.mailbox: omap mailbox rev 0x400
    [    0.271380] Advanced Linux Sound Architecture Driver Initialized.
    [    0.272363] clocksource: Switched to clocksource timer1
    [    0.280465] NET: Registered protocol family 2
    [    0.281113] TCP established hash table entries: 8192 (order: 3, 32768 bytes)
    [    0.281180] TCP bind hash table entries: 8192 (order: 3, 32768 bytes)
    [    0.281255] TCP: Hash tables configured (established 8192 bind 8192)
    [    0.281394] UDP hash table entries: 512 (order: 1, 8192 bytes)
    [    0.281416] UDP-Lite hash table entries: 512 (order: 1, 8192 bytes)
    [    0.281562] NET: Registered protocol family 1
    [    0.281937] RPC: Registered named UNIX socket transport module.
    [    0.281950] RPC: Registered udp transport module.
    [    0.281955] RPC: Registered tcp transport module.
    [    0.281961] RPC: Registered tcp NFSv4.1 backchannel transport module.
    [    0.284293] workingset: timestamp_bits=14 max_order=18 bucket_order=4
    [    0.289488] squashfs: version 4.0 (2009/01/31) Phillip Lougher
    [    0.290234] NFS: Registering the id_resolver key type
    [    0.290271] Key type id_resolver registered
    [    0.290277] Key type id_legacy registered
    [    0.290319] ntfs: driver 2.1.32 [Flags: R/O].
    [    0.291787] bounce: pool size: 64 pages
    [    0.291972] Block layer SCSI generic (bsg) driver version 0.4 loaded (major 246)
    [    0.291985] io scheduler noop registered
    [    0.291991] io scheduler deadline registered
    [    0.292109] io scheduler cfq registered (default)
    [    0.294946] pinctrl-single 44e10800.pinmux: 199 pins at pa f9e10800 size 796
    [    0.297642] backlight supply power not found, using dummy regulator
    [    0.344032] Serial: 8250/16550 driver, 10 ports, IRQ sharing disabled
    [    0.346421] omap8250 44e09000.serial: No clock speed specified: using default: 48000000
    [    0.347150] 44e09000.serial: ttyS0 at MMIO 0x44e09000 (irq = 30, base_baud = 3000000) is a 8250
    [    1.013442] console [ttyS0] enabled
    [    1.018571] omap_rng 48310000.rng: OMAP Random Number Generator ver. 20
    [    1.025411] [drm] Initialized
    [    1.028767] pinctrl-single 44e10800.pinmux: mux offset out of range: 0xfffff8e0 (0x31c)
    [    1.036849] pinctrl-single 44e10800.pinmux: could not add functions for dss_pins 4294965472x
    [    1.046195] 4832a000.dss supply vdda_video not found, using dummy regulator
    [    1.053321] OMAP DSS rev 2.0
    [    1.056364] omapdss_dss 4832a000.dss: bound 4832a400.dispc (ops dispc_component_ops)
    [    1.065568] display supply vcc not found, using dummy regulator
    [    1.084409] brd: module loaded
    [    1.093419] loop: module loaded
    [    1.099803] libphy: Fixed MDIO Bus: probed
    [    1.172427] davinci_mdio 4a101000.mdio: davinci mdio revision 1.6
    [    1.178564] libphy: 4a101000.mdio: probed
    [    1.183434] davinci_mdio 4a101000.mdio: phy[0]: device 4a101000.mdio:00, driver TI DP83867
    [    1.192526] cpsw 4a100000.ethernet: No slave[1] phy_id, phy-handle, or fixed-link property
    [    1.200838] cpsw 4a100000.ethernet: Detected MACID = c4:f3:12:b4:94:c4
    [    1.207534] cpsw 4a100000.ethernet: device node lookup for pps timer failed
    [    1.214626] cpsw 4a100000.ethernet: cpts: overflow check period 500 (jiffies)
    [    1.223311] mousedev: PS/2 mouse device common for all mice
    [    1.229209] i2c /dev entries driver
    [    1.234545] cpuidle: enable-method property 'ti,am4372' found operations
    [    1.242209] omap_hsmmc 48060000.mmc: Got CD GPIO
    [    1.249011] ledtrig-cpu: registered to indicate activity on CPUs
    [    1.257433] NET: Registered protocol family 10
    [    1.263154] sit: IPv6, IPv4 and MPLS over IPv4 tunneling driver
    [    1.269703] NET: Registered protocol family 17
    [    1.274555] Key type dns_resolver registered
    [    1.279047] omap_voltage_late_init: Voltage driver support not added
    [    1.291105] omapdrm omapdrm.0: DMM not available, disable DMM support
    [    1.298101] [drm] Supports vblank timestamp caching Rev 2 (21.10.2013).
    [    1.304820] [drm] No driver support for vblank timestamp query.
    [    1.372888] Console: switching to colour frame buffer device 100x30
    [    1.395933] omapdrm omapdrm.0: fb0: omapdrm frame buffer device
    [    1.423376] pinctrl-single 44e10800.pinmux: pin PIN7 already requested by display; cannot claim for gpios
    [    1.433100] pinctrl-single 44e10800.pinmux: pin-7 (gpios) status -22
    [    1.439508] pinctrl-single 44e10800.pinmux: could not request pin 7 (PIN7) from group gpio_pins  on device pinctrl-single
    [    1.450559] omap_gpio gpios: Error applying setting, reverse things back
    [    1.457349] omap_gpio: probe of gpios failed with error -22
    [    1.510847] at24 0-0050: 32768 byte 24c256 EEPROM, writable, 64 bytes/write
    [    1.518110] omap_i2c 44e0b000.i2c: bus 0 rev0.12 at 100 kHz
    [    1.524964] omap_i2c 4802a000.i2c: bus 1 rev0.12 at 100 kHz
    [    1.532295] omap_hsmmc 48060000.mmc: Got CD GPIO
    [    1.593355] hctosys: unable to open rtc device (rtc0)
    [    1.599137] ALSA device list:
    [    1.602129]   No soundcards found.
    [    1.609706] Waiting for root device PARTUUID=2cd78e77-02...
    [    1.712422] mmc0: host does not support reading read-only switch, assuming write-enable
    [    1.725268] mmc0: new high speed SDHC card at address aaaa
    [    1.731526] mmcblk0: mmc0:aaaa SC32G 29.7 GiB
    [    1.740639]  mmcblk0: p1 p2
    [    1.863364] random: fast init done
    [    2.628046] EXT4-fs (mmcblk0p2): recovery complete
    [    2.638592] EXT4-fs (mmcblk0p2): mounted filesystem with ordered data mode. Opts: (null)
    [    2.646922] VFS: Mounted root (ext4 filesystem) on device 179:2.
    [    2.663968] devtmpfs: mounted
    [    2.669608] Freeing unused kernel memory: 1024K
    [    2.906580] systemd[1]: System time before build time, advancing clock.
    [    2.951946] systemd[1]: systemd 230 running in system mode. (+PAM -AUDIT -SELINUX +IMA -APPARMOR +SMACK +SYSVINIT +UTMP -LIBCRYPTSETUP -GCRYPT -GNUTLS +ACL +XZ -LZ4 -SECCOMP +BLKID -ELFUTILS +KMOD -IDN)
    [    2.970950] systemd[1]: Detected architecture arm.
    
    Welcome to Arago 2017.12!
    
    [    3.015721] systemd[1]: Set hostname to <am437x-evm>.
    [    3.562682] systemd[1]: Started Dispatch Password Requests to Console Directory Watch.
    [  OK  ] Started Dispatch Password Requests to Console Directory Watch.
    [    3.602664] systemd[1]: Reached target Remote File Systems.
    [  OK  ] Reached target Remote File Systems.
    [    3.632763] systemd[1]: Listening on udev Kernel Socket.
    [  OK  ] Listening on udev Kernel Socket.
    [    3.662810] systemd[1]: Listening on Syslog Socket.
    [  OK  ] Listening on Syslog Socket.
    [    3.694628] systemd[1]: Created slice User and Session Slice.
    [  OK  ] Created slice User and Session Slice.
    [    3.722669] systemd[1]: Reached target Swap.
    [  OK  ] Reached target Swap.
    [    3.760679] systemd[1]: Listening on Process Core Dump Socket.
    [  OK  ] Listening on Process Core Dump Socket.
    [  OK  ] Started Forward Password Requests to Wall Directory Watch.
    [  OK  ] Reached target Paths.
    [  OK  ] Listening on Journal Socket (/dev/log).
    [  OK  ] Listening on /dev/initctl Compatibility Named Pipe.
    [  OK  ] Listening on udev Control Socket.
    [  OK  ] Listening on Journal Socket.
    [  OK  ] Listening on Network Service Netlink Socket.
    [  OK  ] Created slice System Slice.
             Starting Load Kernel Modules...
             Mounting POSIX Message Queue File System...
             Starting Journal Service...
    [  OK  ] Reached target Slices.
    [    4.181758] cmemk: loading out-of-tree module taints kernel.
             Starting Remount Root and Kernel File Systems...
    [    4.227111] CMEMK module: reference Linux version 4.9.69
    [  OK  ] Created slice system-serial\x2dgetty.slice.
    [    4.262839] no physical memory specified
    [    4.266854] cmemk initialized
             Starting Setup Virtual Console...
             [    4.343350] cryptodev: driver 1.8 loaded.
    Starting Create list of required st... nodes for the current kernel...
    [    4.355017] EXT4-fs (mmcblk0p2): re-mounted. Opts: (null)
             Mounting Temporary Directory...
    [  OK  ] Created slice system-getty.slice.
    [    4.450585] usbcore: registered new interface driver usbfs
             [    4.487929] usbcore: registered new interface driver hub
    Starting alignment.service...
    [    4.502114] usbcore: registered new device driver usb
             Mounting Debug File System...
    [    4.543004] usbcore: registered new interface driver usbserial
    [  OK  ] Mounted POSIX Message Queue File System.
    [    4.596722] usbcore: registered new interface driver ftdi_sio
    [  OK  ] Mounted Temporary Directory.
    [    4.618925] usbserial: USB Serial support registered for FTDI USB Serial Device
    [  OK  ] Mounted Debug File System.
    [  OK  ] Started Journal Service.
    [  OK  ] Started Load Kernel Modules.
    [  OK  ] Started Remount Root and Kernel File Systems.
    [  OK  ] Started Setup Virtual Console.
    [  OK  ] Started Create list of required sta...ce nodes for the current kernel.
    [  OK  ] Started alignment.service.
             Starting Create Static Device Nodes in /dev...
             Starting udev Coldplug all Devices...
             Starting Apply Kernel Variables...
             Mounting Configuration File System...
             Starting Flush Journal to Persistent Storage...
    [  OK  ] Mounted Configuration File System.
    [  OK  ] Started Create Static Device Nodes in /dev.
    [  OK  ] Started Apply Kernel Variables.
    [    5.208576] systemd-journald[85]: Received request to flush runtime journal from PID 1
    [  OK  ] Reached target Local File Systems (Pre).
             Mounting /media/ram...
             Mounting /var/volatile...
             Starting udev Kernel Device Manager...
    [  OK  ] Mounted /var/volatile.
    [  OK  ] Mounted /media/ram.
    [  OK  ] Started Flush Journal to Persistent Storage.
    [  OK  ] Started udev Kernel Device Manager.
             Starting Load/Save Random Seed...
    [  OK  ] Reached target Local File Systems.
             Starting Create Volatile Files and Directories...
    [  OK  ] Started Load/Save Random Seed.
    [  OK  ] Started Create Volatile Files and Directories.
             Starting Update UTMP about System Boot/Shutdown...
             Starting Network Time Synchronization...
    [  OK  ] Started Update UTMP about System Boot/Shutdown.
    [  OK  ] Started Network Time Synchronization.
    [  OK  ] Reached target System Time Synchronized.
    [    6.871245] remoteproc remoteproc0: wkup_m3 is available
    [    6.885637] omap_wdt: OMAP Watchdog Timer Rev 0x01: initial timeout 60 sec
    [    6.889777] omap_rtc 44e3e000.rtc: rtc core: registered 44e3e000.rtc as rtc0
    [    7.070816] wkup_m3_ipc 44e11324.wkup_m3_ipc: could not get rproc handle
    [  OK  ] Found device /dev/ttyS0.
    [    7.182792] remoteproc remoteproc0: powering up wkup_m3
    [  OK  ] Started udev Coldplug all Devices.
    [  OK  ] Reached target System Initialization.
    [    7.237382] remoteproc remoteproc0: Booting fw image am335x-pm-firmware.elf, size 224268
    [  OK  ] Listening on RPCbind Server Activation Socket[    7.379385] remoteproc remoteproc0: remote processor wkup_m3 is now up
    .
    [    7.390735] wkup_m3_ipc 44e11324.wkup_m3_ipc: CM3 Firmware Version = 0x192
    [    7.394711] input: pixcir_tangoc as /devices/platform/44000000.ocp/4802a000.i2c/i2c-1/1-005c/input/input0
    [    7.459294] CAN device driver interface
    [    7.514745] c_can_platform 481cc000.can: c_can_platform device registered (regs=fa1cc000, irq=248)
    [    7.524002] c_can_platform 481d0000.can: c_can_platform device registered (regs=fa1d0000, irq=249)
    [    7.574443] vpfe 48326000.vpfe: Remote device at /ocp@44000000/vpfe@48326000/port/endpoint not found
    [    7.574449] vpfe 48326000.vpfe: No platform data
    [    7.574484] vpfe: probe of 48326000.vpfe failed with error -22
    [    8.015471] omap-sham 53100000.sham: hw accel on OMAP rev 0.0
    [    8.101370] omap-aes 53501000.aes: OMAP AES hw accel rev: 0.1
    [    8.112549] omap-aes 53501000.aes: will run requests pump with realtime priority
    [    8.169918] [drm] Initialized pvr 1.14.3699939 20110701 on minor 1
    [    8.171258] omap-des 53701000.des: OMAP DES hw accel rev: 0.33
    [    8.172725] omap-des 53701000.des: will run requests pump with realtime priority
    [    8.453727] PM: Cannot get wkup_m3_ipc handle
    [  OK  ] Started Daily Cleanup of Temporary Directories.
    [  OK  ] Reached target Timers.
    [  OK  ] Listening on dropbear.socket.
    [  OK  ] Listening on Avahi mDNS/DNS-SD Stack Activation Socket.
    [  OK  ] Listening on D-Bus System Message Bus Socket.
    [  OK  ] Reached target Sockets.
    [  OK  ] Reached target Basic System.
    [  OK  ] Started Periodic Command Scheduler.
             Starting uim-sysfs.service...
    [  OK  ] Started D-Bus System Message Bus.
             Starting Network Service...
             Starting Avahi mDNS/DNS-SD Stack...
             Starting Telephony service...
    [  OK  ] Started Job spooling tools.
             Starting Login Service...
             Starting Print notice about GPLv3 packages...
    [   10.636325] FAT-fs (mmcblk0p1): Volume was not properly unmounted. Some data may be corrupt. Please run fsck.
    [  OK  ] Started System Logging Service.
    [  OK  ] Started Kernel Logging Service.
    [  OK  ] Started Network Service.
    [   11.079051] Bluetooth: Core ver 2.22
    [   11.101295] net eth0: initializing cpsw version 1.15 (0)
    [   11.101306] cpsw 4a100000.ethernet: initialized cpsw ale version 1.4
    [   11.101311] cpsw 4a100000.ethernet: ALE Table size 1024
    [   11.107704] TI DP83867 4a101000.mdio:00: attached PHY driver [TI DP83867] (mii_bus:phy_addr=4a101000.mdio:00, irq=-1)
    [   11.178519] libphy: PHY  not found
    [   11.178535] net eth0: phy "" not found on slave 1, err -19
    [   11.203538] cpts ptp bc clkid 0
    [   11.272176] IPv6: ADDRCONF(NETDEV_UP): eth0: link is not ready
    [   11.763885] NET: Registered protocol family 31
    [   11.768365] Bluetooth: HCI device and connection manager initialized
    [   11.885201] Bluetooth: HCI socket layer initialized
    [   11.890126] Bluetooth: L2CAP socket layer initialized
    [   11.981800] Bluetooth: SCO socket layer initialized
    [  OK  ] Started Avahi mDNS/DNS-SD Stack.
    [  OK  ] Started Telephony service.
    [  OK  ] Started Login Service.
    [  OK  ] Listening on Load/Save RF Kill Switch Status /dev/rfkill Watch.
    [  OK  ] Created slice system-systemd\x2dbacklight.slice.
             Starting Load/Save Screen Backlight...htness of backlight:backlight...
             Starting Wait for Network to be Configured...
    [  OK  ] Reached target Network.
             Starting Simple Network Management Protocol (SNMP) Daemon....
             Starting Permit User Sessions...
             Starting Network Name Resolution...
             Starting Lightning Fast Webserver With Light System Requirements...
    [  OK  ] Started strongSwan IPsec IKEv1/IKEv2 daemon using ipsec.conf.
             Starting Enable and configure wl18xx bluetooth stack...
    [  OK  ] Started Load/Save Screen Backlight Brightness of backlight:backlight.
    [  OK  ] Started Permit User Sessions.
    [  OK  ] Started Lightning Fast Webserver With Light System Requirements.
    [  OK  ] Started Network Name Resolution.
    [   13.865089] NET: Registered protocol family 15
    [  OK  ] Started Simple Network Management Protocol (SNMP) Daemon..
    [   14.778561] Initializing XFRM netlink socket
    [  OK  ] Started uim-sysfs.service.
    [  OK  ] Started Enable and configure wl18xx bluetooth stack.
    [   15.575537] ti-pruss 54400000.pruss: creating PRU cores and other child platform devices
    [   15.596156] PM: bootloader does not support rtc-only!
    [   15.790388] irq: no irq domain found for /ocp@44000000/pruss_soc_bus@54426000/pruss@54400000/intc@54420000 !
    [   15.957717] irq: no irq domain found for /ocp@44000000/pruss_soc_bus@54426000/pruss@54400000/intc@54420000 !
    [   16.000629] xhci-hcd xhci-hcd.3.auto: xHCI Host Controller
    [   16.000668] xhci-hcd xhci-hcd.3.auto: new USB bus registered, assigned bus number 1
    [   16.005508] xhci-hcd xhci-hcd.3.auto: hcc params 0x0238f06d hci version 0x100 quirks 0x02010010
    [   16.005567] xhci-hcd xhci-hcd.3.auto: irq 288, io mem 0x483d0000
    [   16.013562] hub 1-0:1.0: USB hub found
    [   16.013623] hub 1-0:1.0: 1 port detected
    [   16.014013] xhci-hcd xhci-hcd.3.auto: xHCI Host Controller
    [   16.014034] xhci-hcd xhci-hcd.3.auto: new USB bus registered, assigned bus number 2
    [   16.014126] usb usb2: We don't know the algorithms for LPM for this host, disabling LPM.
    [   16.024325] hub 2-0:1.0: USB hub found
    [   16.024379] hub 2-0:1.0: 1 port detected
    [   16.372630] random: crng init done
    [   16.636030] ti-pruss 54440000.pruss: creating PRU cores and other child platform devices
    [   16.714241] irq: no irq domain found for /ocp@44000000/pruss_soc_bus@54426000/pruss@54440000/intc@54460000 !
    [   16.800206] irq: no irq domain found for /ocp@44000000/pruss_soc_bus@54426000/pruss@54440000/intc@54460000 !
    [   16.997483] remoteproc remoteproc1: 54434000.pru0 is available
    [   17.059578] pru-rproc 54434000.pru0: PRU rproc node /ocp@44000000/pruss_soc_bus@54426000/pruss@54400000/pru@54434000 probed successfully
    [   17.150162] remoteproc remoteproc2: 54438000.pru1 is available
    [   17.178861] pru-rproc 54438000.pru1: PRU rproc node /ocp@44000000/pruss_soc_bus@54426000/pruss@54400000/pru@54438000 probed successfully
    [   17.244803] remoteproc remoteproc3: 54474000.pru0 is available
    [   17.275326] pru-rproc 54474000.pru0: PRU rproc node /ocp@44000000/pruss_soc_bus@54426000/pruss@54440000/pru@54474000 probed successfully
    [   17.339110] remoteproc remoteproc4: 54478000.pru1 is available
    [   17.375301] pru-rproc 54478000.pru1: PRU rproc node /ocp@44000000/pruss_soc_bus@54426000/pruss@54440000/pru@54478000 probed successfully
             Starting rc.pvr.service...
    [  OK  ] Started Serial Getty on ttyS0.
    [  OK  ] Started Getty on tty1.
    [  OK  ] Reached target Login Prompts.
             Starting Synchronize System and HW clocks...
    [  OK  ] Started Synchronize System and HW clocks.
    [   18.656713] PVR_K: UM DDK-(3699939) and KM DDK-(3699939) match. [ OK ]
    [  OK  ] Started rc.pvr.service.
             Starting weston.service...
    ***************************************************************
    ***************************************************************
    NOTICE: This file system contains the following GPLv3 packages:
            autoconf
            binutils
            cifs-utils
            cpio
            cpp-symlinks
            cpp
            dosfstools
            findutils
            g++-symlinks
            g++
            gawk-dev
            gawk
            gcc-symlinks
            gcc
            gdb
            gdbserver
            glmark2
            gstreamer1.0-libav
            gzip
            hidapi
            libcairo-perf-utils
            libgmp10
            libidn11
            libmavconn
            libmpc3
            libmpfr4
            libreadline-dev
            libreadline6
            m4-dev
            m4
            make
            mavlink
            mavros-extras
            mavros-msgs
            mavros
            nettle
            socketcan-interface
            swig-dev
            swig
            which
    
    If you do not wish to distribute GPLv3 components please remove
    the above packages prior to distribution.  This can be done using
    the opkg remove command.  i.e.:
        opkg remove <package>
    Where <package> is the name printed in the list above
    
    NOTE: If the package is a dependency of another package you
          will be notified of the dependent packages.  You should
          use the --force-removal-of-dependent-packages option to
          also remove the dependent packages as well
    ***************************************************************
    ***************************************************************
    [  OK  ] Started Print notice about GPLv3 packages.
    
    /*
     * Copyright (C) 2014 Texas Instruments Incorporated - http://www.ti.com/
     *
     * This program is free software; you can redistribute it and/or modify
     * it under the terms of the GNU General Public License version 2 as
     * published by the Free Software Foundation.
     */
    
    /*
    *  This is the kernel dts file!
    *  This is a highly modified version of the AM437 SK EVM dts file
    *    intended for the ASCO AHMI v0 board.  
    *    Authors Robert Schicke, James Pawlyk ASCO POWER 2018
    */
    
    /* ASCO LX HMI 000 */
    
    /dts-v1/;
    
    #include "am4372.dtsi"
    #include <dt-bindings/pinctrl/am43xx.h>
    #include <dt-bindings/pwm/pwm.h>
    #include <dt-bindings/gpio/gpio.h>
    #include <dt-bindings/input/input.h>
    #include <dt-bindings/net/ti-dp83867.h>
    
    / {
    	model = "TI AM437x SK EVM";
    	compatible = "ti,am437x-sk-evm","ti,am4372","ti,am43";
    
    	aliases {
    		display0 = &lcd0;
    	};
    
    	chosen {
    		stdout-path = &uart0;
    	};
    
    	/* fixed 32k external oscillator clock */
    	clk_32k_rtc: clk_32k_rtc {
    		#clock-cells = <0>;
    		compatible = "fixed-clock";
    		clock-frequency = <32768>;
    	};
    
    	lcd_bl: backlight {
    		compatible = "pwm-backlight";
    		pwms = <&ecap0 0 50000 PWM_POLARITY_INVERTED>;
    		brightness-levels = <0 51 53 56 62 75 101 152 255>;
    		default-brightness-level = <8>;
    	};
    
    	//sound {
    		//compatible = "simple-audio-card";
    		//simple-audio-card,name = "AM437x-SK-EVM";
    		//simple-audio-card,widgets =
    			//"Headphone", "Headphone Jack",
    			//"Line", "Line In";
    		//simple-audio-card,routing =
    			//"Headphone Jack",	"HPLOUT",
    			//"Headphone Jack",	"HPROUT",
    			//"LINE1L",		"Line In",
    			//"LINE1R",		"Line In";
    		//simple-audio-card,format = "dsp_b";
    		//simple-audio-card,bitclock-master = <&sound_master>;
    		//simple-audio-card,frame-master = <&sound_master>;
    		//simple-audio-card,bitclock-inversion;
            //
    		//simple-audio-card,cpu {
    			//sound-dai = <&mcasp1>;
    		//};
    
    		//sound_master: simple-audio-card,codec {
    			//sound-dai = <&tlv320aic3106>;
    			//system-clock-frequency = <24000000>;
    		//};
    	//};
    
       //beeper: beeper {
    	//	compatible = "gpio-beeper";
    	//	pinctrl-names = "default";
    	//	pinctrl-0 = <&beeper_pins_default>;
    	//	pinctrl-1 = <&beeper_pins_sleep>;
    	//	gpios = <&gpio2 1 GPIO_ACTIVE_HIGH>;
    	//}; 
     
        /*
            leds
        */
        /*
            these status leds available on hader j903
        */
    	leds {
    		compatible = "gpio-leds";
    
    		pinctrl-names = "default";
    		pinctrl-0 = <&leds_pins>;
    
    		led0 {
    			label = "am437x-sk:red:heartbeat";
    			gpios = <&gpio3 14 GPIO_ACTIVE_HIGH>;	/* Bank 3, pin 14 (N24) */
    			linux,default-trigger = "heartbeat";
    			default-state = "off";
    		};
    
    		led1 {
    			label = "am437x-sk::usr1";
    			gpios = <&gpio3 15 GPIO_ACTIVE_HIGH>;	/* Bank 3, pin 1 15 (N22)*/
    			//linux,default-trigger = "mmc0";
    			default-state = "off";
    		};
    
    		led2 {
    			label = "am437x-sk:blue:usr2";
    			gpios = <&gpio3 16 GPIO_ACTIVE_HIGH>;	/* Bank 3, pin 2 16 (H23)*/
    			//linux,default-trigger = "cpu0";
    			default-state = "off";
    		};
    
    		led3 {
    			label = "am437x-sk:blue:usr3";
    			gpios = <&gpio3 17 GPIO_ACTIVE_HIGH>;	/* Bank 3, pin 3 17 (M24)*/
    			default-state = "off";
    		};
    
    		led4 {
    			label = "am437x-sk:blue:usr4";
    			gpios = <&gpio1 0 GPIO_ACTIVE_HIGH>;	/* Bank 1, pin 0 17 (B5)*/
    			default-state = "off";
    		};
    
    		led5 {
    			label = "am437x-sk:blue:usr5";
    			gpios = <&gpio1 1 GPIO_ACTIVE_HIGH>;	/* Bank 1, pin 1 17 (A5)*/
    			default-state = "off";
    		};
    	};
    
    
        /*
            dip switches not sure if /  how these should work
        */
    	gpios {
            compatible = "ti,am4372-gpio","ti,omap4-gpio";
    
    		pinctrl-names = "default";
    		pinctrl-0 = <&gpio_pins>;
        };
    
    	lcd0: display {
            compatible = "osddisplays,osd057T0559-34ts", "panel-dpi";
    		label = "lcd";
    
    		pinctrl-names = "default";
    		pinctrl-0 = <&lcd_pins>;
    
    		enable-gpios = <&gpio5 8 GPIO_ACTIVE_HIGH>; /* GPIO5.8 (D25) */
    
    		panel-timing {
    			clock-frequency = <33000000>;
    			hactive = <800>;
    			vactive = <480>;
    			hfront-porch = <210>;
    			hback-porch = <16>;
    			hsync-len = <30>;
    			vback-porch = <10>;
    			vfront-porch = <22>;
    			vsync-len = <13>;
    			hsync-active = <0>;
    			vsync-active = <0>;
    			de-active = <1>;
    			pixelclk-active = <1>;
    		};
    
    		port {
    			lcd_in: endpoint {
    				remote-endpoint = <&dpi_out>;
    			};
    		};
    	};
    };
    
    &am43xx_pinmux {
    	//matrix_keypad_pins: matrix_keypad_pins {
    	//	pinctrl-single,pins = <
    	//		AM4372_IOPAD(0xa4c, PIN_OUTPUT | MUX_MODE7)	/* gpio5_13.gpio5_13 */
    	//		AM4372_IOPAD(0xa50, PIN_OUTPUT | MUX_MODE7)	/* spi4_sclk.gpio5_4 */
    	//		AM4372_IOPAD(0xa54, PIN_INPUT | MUX_MODE7)	/* spi4_d0.gpio5_5 */
    	//		AM4372_IOPAD(0xa58, PIN_INPUT | MUX_MODE7)	/* spi4_d1.gpio5_5 */
    	//	>;
    	//};
    
        /*
            parellel dip interface:
        */
        gpio_pins: gpio_pins {
    	    pinctrl-single,pins = <
                // gpio 0 0-31
    
                // gpio 1 32-63
                AM4372_IOPAD(0x808, PIN_OUTPUT | MUX_MODE7)         /* (B6) gpmc_ad2.gpio1[2]           relay0      34*/
                AM4372_IOPAD(0x80c, PIN_OUTPUT | MUX_MODE7)         /* (A6) gpmc_ad3.gpio1[3]           relay1      35*/
    		    AM4372_IOPAD(0x818, PIN_OUTPUT | MUX_MODE7)         /* (C8) gpmc_ad6.gpio1[6]           TP903       38*/
    		    AM4372_IOPAD(0x81c, PIN_OUTPUT | MUX_MODE7)         /* (B8) gpmc_ad7.gpio1[7]           TP904       39*/
            
                // gpio 2 64-95
               	AM4372_IOPAD(0x88c,  PIN_OUTPUT| MUX_MODE7)	        /* (A12) gpmc_clk.gpio2[1]          buzzer      65 */
    
                // gpio 3 96-127
                AM4372_IOPAD(0x9a0, PIN_OUTPUT | MUX_MODE7)         /* (L23) mcasp0_aclkr.gpio3[18]     j901-11     101*/
    		    AM4372_IOPAD(0x9a4, PIN_OUTPUT | MUX_MODE7)         /* (K23) mcasp0_fsr.gpio3[19]       j901-13     102*/
    		    AM4372_IOPAD(0x9a8, PIN_OUTPUT | MUX_MODE7)         /* (M25) mcasp0_axr1.gpio3[20]      j901-15     103*/
    		    AM4372_IOPAD(0x9ac, PIN_OUTPUT | MUX_MODE7)         /* (L24) mcasp0_ahclkx.gpio3[21]    j901-17     104*/
    
                // gpio 4 128-159
                AM4372_IOPAD(0x9b8, PIN_OUTPUT | MUX_MODE7)         /* (AC18) cam0_field.gpio4[2]       TP902       130*/
    		    AM4372_IOPAD(0x9bc, PIN_OUTPUT | MUX_MODE7)         /* (AD17) cam0_wen.gpio4[3]         TP901       131*/
    		    AM4372_IOPAD(0x9c8, PIN_OUTPUT | MUX_MODE7)         /* (AA19) cam0_data9.gpio4[6]       TP5         134*/
    		    AM4372_IOPAD(0x9dc, PIN_OUTPUT | MUX_MODE7)         /* (AE21) cam1_pclk.gpio4[11]       TP6         139*/
    
                // gpio 5 160-191
                AM4372_IOPAD(0xa5c,  PIN_OUTPUT| MUX_MODE7)          /* (N25) spi4_cs0.gpio5[7]         j901-19     167*/
    	    	AM4372_IOPAD(0xa3c,  PIN_INPUT | MUX_MODE7 )        /* (F24) gpio5_9.gpio5[9]           dipA        169*/
    	    	AM4372_IOPAD(0xa40,  PIN_INPUT | MUX_MODE7 )        /* (G20) gpio5_10.gpio5[10]         dipB        170*/
    	    	AM4372_IOPAD(0xa44,  PIN_INPUT | MUX_MODE7 )        /* (F23) gpio5_11.gpio5[11]         dipC        171*/
    	    	AM4372_IOPAD(0xa48,  PIN_INPUT | MUX_MODE7 )        /* (E25) gpio2_1.gpio5[12]          dipD        172*/
    
    
    	    >;
        };
    
    
    	leds_pins: leds_pins {
    		pinctrl-single,pins = <
                AM4372_IOPAD(0x990, PIN_OUTPUT | MUX_MODE7)	/* gpio3.14 */
    			AM4372_IOPAD(0x994, PIN_OUTPUT | MUX_MODE7)	/* gpio3.15 */
    			AM4372_IOPAD(0x998, PIN_OUTPUT | MUX_MODE7)	/* gpio3.16 */
    			AM4372_IOPAD(0x99c, PIN_OUTPUT | MUX_MODE7)	/* gpio3.17 */
    			AM4372_IOPAD(0x800,   PIN_OUTPUT | MUX_MODE7)	/* gpio1.0 */
    			AM4372_IOPAD(0x804,   PIN_OUTPUT | MUX_MODE7)	/* gpio1.1 */
    		>;
    	};
    
    	i2c0_pins: i2c0_pins {
    		pinctrl-single,pins = <
    			AM4372_IOPAD(0x988, PIN_INPUT_PULLUP | SLEWCTRL_FAST | MUX_MODE0)  /* i2c0_sda.i2c0_sda (AB24)*/
    			AM4372_IOPAD(0x98c, PIN_INPUT_PULLUP | SLEWCTRL_FAST | MUX_MODE0)  /* i2c0_scl.i2c0_scl (Y22)*/
    		>;
    	};
    
        /* I2C1 - Includes: Capacative Touch, Audio, Expansion Header */
    
    	i2c1_pins: i2c1_pins {
    		pinctrl-single,pins = <
    			AM4372_IOPAD(0x95c, PIN_INPUT_PULLUP | SLEWCTRL_FAST | MUX_MODE2)  /* spi0_cs0.i2c1_scl */
    			AM4372_IOPAD(0x958, PIN_INPUT_PULLUP | SLEWCTRL_FAST | MUX_MODE2)  /* spi0_d1.i2c1_sda  */
    		>;
    	};
    
       spi2_pins: spi2_pins {
    	    pinctrl-single,pins = <
    		    AM4372_IOPAD(0xa60, PIN_INPUT_PULLUP  | MUX_MODE0) /* (AC18) cam0_field.spi2_sclk */
    		    AM4372_IOPAD(0xa64, PIN_INPUT_PULLUP  | MUX_MODE0)  /* (AD17) cam0_wen.spi2_d0 */
    		    AM4372_IOPAD(0xa68, PIN_INPUT_PULLUP  | MUX_MODE0) /* (AD18) cam0_vd.spi2_d1 */
    		    AM4372_IOPAD(0xa6c, PIN_INPUT_PULLUP  | MUX_MODE0) /* (AC20) cam0_pclk.spi2_cs0 */
    	    >;
        };
    
        /* SD Card Pins - Uses name of MMC1, but pins are mapped to MMC0*/
    	mmc1_pins: pinmux_mmc1_pins {
    		pinctrl-single,pins = <
    			AM4372_IOPAD(0x8f0, PIN_INPUT | MUX_MODE0) /* mmc0_dat3.mmc0_dat3 */
    			AM4372_IOPAD(0x8f4, PIN_INPUT | MUX_MODE0) /* mmc0_dat2.mmc0_dat2 */
    			AM4372_IOPAD(0x8f8, PIN_INPUT | MUX_MODE0) /* mmc0_dat1.mmc0_dat1 */
    			AM4372_IOPAD(0x8fc, PIN_INPUT | MUX_MODE0) /* mmc0_dat0.mmc0_dat0 */
    			AM4372_IOPAD(0x900, PIN_INPUT | MUX_MODE0) /* mmc0_clk.mmc0_clk */
    			AM4372_IOPAD(0x904, PIN_INPUT | MUX_MODE0) /* mmc0_cmd.mmc0_cmd */
    			AM4372_IOPAD(0x960, PIN_INPUT | MUX_MODE7) /* spi0_cs1.gpio0_6 */
    		>;
    	};
    
    	ecap0_pins: backlight_pins {
    		pinctrl-single,pins = <
    			AM4372_IOPAD(0x964, PIN_OUTPUT | MUX_MODE0) /* eCAP0_in_PWM0_out.eCAP0_in_PWM0_out */
    		>;
    	};
    
        /* LCD Wake and Interrupt Pins */
    	pixcir_ts_pins: pixcir_ts_pins {
    		pinctrl-single,pins = <
    			AM4372_IOPAD(0x874, PIN_INPUT_PULLUP | MUX_MODE7) /* gpmc_wpn.gpio0_31 (B3) */
    		>;
    	};
    
        
    	/* Touch Screen Interrupt Pin */
    	pixcir_ts_pins: pixcir_ts_pins {
    		pinctrl-single,pins = <
    			AM4372_IOPAD(0x874, PIN_INPUT | MUX_MODE7)     /* gpmc_wpn.gpio0_31 (B3) */
    				>;
    	};
    
    
        /* Camera Interface */
    	vpfe0_pins_default: vpfe0_pins_default {
    		pinctrl-single,pins = <
    			AM4372_IOPAD(0x9b0, PIN_INPUT_PULLUP | MUX_MODE0)  /* cam0_hd mode 0*/
    			AM4372_IOPAD(0x9b4, PIN_INPUT_PULLUP | MUX_MODE0)  /* cam0_vd mode 0*/
    			AM4372_IOPAD(0x9b8, PIN_INPUT_PULLUP | MUX_MODE0)  /* cam0_field mode 0*/
    			AM4372_IOPAD(0x9bc, PIN_INPUT_PULLUP | MUX_MODE0)  /* cam0_wen mode 0*/
    			AM4372_IOPAD(0x9c0, PIN_INPUT_PULLUP | MUX_MODE0)  /* cam0_pclk mode 0*/
    			AM4372_IOPAD(0x9c4, PIN_INPUT_PULLUP | MUX_MODE0)  /* cam0_data8 mode 0*/
    			AM4372_IOPAD(0x9c8, PIN_INPUT_PULLUP | MUX_MODE0)  /* cam0_data9 mode 0*/
    			AM4372_IOPAD(0xa08, PIN_INPUT_PULLUP | MUX_MODE0)  /* cam0_data0 mode 0*/
    			AM4372_IOPAD(0xa0c, PIN_INPUT_PULLUP | MUX_MODE0)  /* cam0_data1 mode 0*/
    			AM4372_IOPAD(0xa10, PIN_INPUT_PULLUP | MUX_MODE0)  /* cam0_data2 mode 0*/
    			AM4372_IOPAD(0xa14, PIN_INPUT_PULLUP | MUX_MODE0)  /* cam0_data3 mode 0*/
    			AM4372_IOPAD(0xa18, PIN_INPUT_PULLUP | MUX_MODE0)  /* cam0_data4 mode 0*/
    			AM4372_IOPAD(0xa1c, PIN_INPUT_PULLUP | MUX_MODE0)  /* cam0_data5 mode 0*/
    			AM4372_IOPAD(0xa20, PIN_INPUT_PULLUP | MUX_MODE0)  /* cam0_data6 mode 0*/
    			AM4372_IOPAD(0xa24, PIN_INPUT_PULLUP | MUX_MODE0)  /* cam0_data7 mode 0*/
    		>;
    	};
    
        /* Camera Interface */
    	vpfe0_pins_sleep: vpfe0_pins_sleep {
    		pinctrl-single,pins = <
    			AM4372_IOPAD(0x9b0, DS0_PULL_UP_DOWN_EN | INPUT_EN | MUX_MODE7)
    			AM4372_IOPAD(0x9b4, DS0_PULL_UP_DOWN_EN | INPUT_EN | MUX_MODE7)
    			AM4372_IOPAD(0x9b8, DS0_PULL_UP_DOWN_EN | INPUT_EN | MUX_MODE7)
    			AM4372_IOPAD(0x9bc, DS0_PULL_UP_DOWN_EN | INPUT_EN | MUX_MODE7)
    			AM4372_IOPAD(0x9c0, DS0_PULL_UP_DOWN_EN | INPUT_EN | MUX_MODE7)
    			AM4372_IOPAD(0x9c4, DS0_PULL_UP_DOWN_EN | INPUT_EN | MUX_MODE7)
    			AM4372_IOPAD(0x9c8, DS0_PULL_UP_DOWN_EN | INPUT_EN | MUX_MODE7)
    			AM4372_IOPAD(0xa08, DS0_PULL_UP_DOWN_EN | INPUT_EN | MUX_MODE7)
    			AM4372_IOPAD(0xa0c, DS0_PULL_UP_DOWN_EN | INPUT_EN | MUX_MODE7)
    			AM4372_IOPAD(0xa10, DS0_PULL_UP_DOWN_EN | INPUT_EN | MUX_MODE7)
    			AM4372_IOPAD(0xa14, DS0_PULL_UP_DOWN_EN | INPUT_EN | MUX_MODE7)
    			AM4372_IOPAD(0xa18, DS0_PULL_UP_DOWN_EN | INPUT_EN | MUX_MODE7)
    			AM4372_IOPAD(0xa1c, DS0_PULL_UP_DOWN_EN | INPUT_EN | MUX_MODE7)
    			AM4372_IOPAD(0xa20, DS0_PULL_UP_DOWN_EN | INPUT_EN | MUX_MODE7)
    			AM4372_IOPAD(0xa24, DS0_PULL_UP_DOWN_EN | INPUT_EN | MUX_MODE7)
    		>;
    	};
    
        // jsp: this one not in boot dts?
    	//clkout1_pin: pinmux_clkout1_pin {
    		//pinctrl-single,pins = <
    			//0x270 (PIN_OUTPUT_PULLDOWN | MUX_MODE3)	/* XDMA_EVENT_INTR0/CLKOUT1 */
    		//>;
    	//};
    
        /* Ethernet */
    	cpsw_default: cpsw_default {
    		pinctrl-single,pins = <
    			/* Slave 1 */
    			AM4372_IOPAD(0x92c, PIN_OUTPUT | MUX_MODE2)	/* mii1_txclk.rmii1_tclk */
    			AM4372_IOPAD(0x914, PIN_OUTPUT | MUX_MODE2)	/* mii1_txen.rgmii1_tctl */
    			AM4372_IOPAD(0x928, PIN_OUTPUT | MUX_MODE2)	/* mii1_txd0.rgmii1_td0 */
    			AM4372_IOPAD(0x924, PIN_OUTPUT | MUX_MODE2)	/* mii1_txd1.rgmii1_td1 */
    			AM4372_IOPAD(0x920, PIN_OUTPUT | MUX_MODE2)	/* mii1_txd0.rgmii1_td2 */
    			AM4372_IOPAD(0x91c, PIN_OUTPUT | MUX_MODE2)	/* mii1_txd1.rgmii1_td3 */
    			AM4372_IOPAD(0x930, PIN_INPUT | MUX_MODE2)	/* mii1_rxclk.rmii1_rclk */
    			AM4372_IOPAD(0x918, PIN_INPUT | MUX_MODE2)	/* mii1_rxdv.rgmii1_rctl */
    			AM4372_IOPAD(0x940, PIN_INPUT | MUX_MODE2)	/* mii1_rxd0.rgmii1_rd0 */
    			AM4372_IOPAD(0x93c, PIN_INPUT | MUX_MODE2)	/* mii1_rxd1.rgmii1_rd1 */
    			AM4372_IOPAD(0x938, PIN_INPUT | MUX_MODE2)	/* mii1_rxd0.rgmii1_rd2 */
    			AM4372_IOPAD(0x934, PIN_INPUT | MUX_MODE2)	/* mii1_rxd1.rgmii1_rd3 */
    
    			/* Slave 2 unused ahmi */
    			AM4372_IOPAD(0x858, PIN_OUTPUT | MUX_MODE2)	/* gpmc_a6.rgmii2_tclk */
    			AM4372_IOPAD(0x840, PIN_OUTPUT | MUX_MODE2)	/* gpmc_a0.rgmii2_tctl */
    			AM4372_IOPAD(0x854, PIN_OUTPUT | MUX_MODE2)	/* gpmc_a5.rgmii2_td0 */
    			AM4372_IOPAD(0x850, PIN_OUTPUT | MUX_MODE2)	/* gpmc_a4.rgmii2_td1 */
    			AM4372_IOPAD(0x84c, PIN_OUTPUT | MUX_MODE2)	/* gpmc_a3.rgmii2_td2 */
    			AM4372_IOPAD(0x848, PIN_OUTPUT | MUX_MODE2)	/* gpmc_a2.rgmii2_td3 */
    			AM4372_IOPAD(0x85c, PIN_INPUT | MUX_MODE2)	/* gpmc_a7.rgmii2_rclk */
    			AM4372_IOPAD(0x844, PIN_INPUT | MUX_MODE2)	/* gpmc_a1.rgmii2_rtcl */
    			AM4372_IOPAD(0x86c, PIN_INPUT | MUX_MODE2)	/* gpmc_a11.rgmii2_rd0 */
    			AM4372_IOPAD(0x868, PIN_INPUT | MUX_MODE2)	/* gpmc_a10.rgmii2_rd1 */
    			AM4372_IOPAD(0x864, PIN_INPUT | MUX_MODE2)	/* gpmc_a9.rgmii2_rd2 */
    			AM4372_IOPAD(0x860, PIN_INPUT | MUX_MODE2)	/* gpmc_a8.rgmii2_rd3 */
    		>;
    	};
    
        /* Ethernet */
    	cpsw_sleep: cpsw_sleep {
    		pinctrl-single,pins = <
    			/* Slave 1 reset value */
    			AM4372_IOPAD(0x92c, PIN_INPUT_PULLDOWN | MUX_MODE7)
    			AM4372_IOPAD(0x914, PIN_INPUT_PULLDOWN | MUX_MODE7)
    			AM4372_IOPAD(0x928, PIN_INPUT_PULLDOWN | MUX_MODE7)
    			AM4372_IOPAD(0x924, PIN_INPUT_PULLDOWN | MUX_MODE7)
    			AM4372_IOPAD(0x920, PIN_INPUT_PULLDOWN | MUX_MODE7)
    			AM4372_IOPAD(0x91c, PIN_INPUT_PULLDOWN | MUX_MODE7)
    			AM4372_IOPAD(0x930, PIN_INPUT_PULLDOWN | MUX_MODE7)
    			AM4372_IOPAD(0x918, PIN_INPUT_PULLDOWN | MUX_MODE7)
    			AM4372_IOPAD(0x940, PIN_INPUT_PULLDOWN | MUX_MODE7)
    			AM4372_IOPAD(0x93c, PIN_INPUT_PULLDOWN | MUX_MODE7)
    			AM4372_IOPAD(0x938, PIN_INPUT_PULLDOWN | MUX_MODE7)
    			AM4372_IOPAD(0x934, PIN_INPUT_PULLDOWN | MUX_MODE7)
    
    			/* Slave 2 reset value */
    			AM4372_IOPAD(0x858, PIN_INPUT_PULLDOWN | MUX_MODE7)
    			AM4372_IOPAD(0x840, PIN_INPUT_PULLDOWN | MUX_MODE7)
    			AM4372_IOPAD(0x854, PIN_INPUT_PULLDOWN | MUX_MODE7)
    			AM4372_IOPAD(0x850, PIN_INPUT_PULLDOWN | MUX_MODE7)
    			AM4372_IOPAD(0x84c, PIN_INPUT_PULLDOWN | MUX_MODE7)
    			AM4372_IOPAD(0x848, PIN_INPUT_PULLDOWN | MUX_MODE7)
    			AM4372_IOPAD(0x85c, PIN_INPUT_PULLDOWN | MUX_MODE7)
    			AM4372_IOPAD(0x844, PIN_INPUT_PULLDOWN | MUX_MODE7)
    			AM4372_IOPAD(0x86c, PIN_INPUT_PULLDOWN | MUX_MODE7)
    			AM4372_IOPAD(0x868, PIN_INPUT_PULLDOWN | MUX_MODE7)
    			AM4372_IOPAD(0x864, PIN_INPUT_PULLDOWN | MUX_MODE7)
    			AM4372_IOPAD(0x860, PIN_INPUT_PULLDOWN | MUX_MODE7)
    		>;
    	};
    
        /* Ethernet */
    	davinci_mdio_default: davinci_mdio_default {
    		pinctrl-single,pins = <
    			/* MDIO */
    			AM4372_IOPAD(0x948, PIN_INPUT | SLEWCTRL_FAST | MUX_MODE0)	/* mdio_data.mdio_data */
    			AM4372_IOPAD(0x94c, PIN_OUTPUT | MUX_MODE0)			/* mdio_clk.mdio_clk */
    		>;
    	};
    
        /* Ethernet */
    	davinci_mdio_sleep: davinci_mdio_sleep {
    		pinctrl-single,pins = <
    			/* MDIO reset value */
    			AM4372_IOPAD(0x948, PIN_INPUT_PULLDOWN | MUX_MODE7)
    			AM4372_IOPAD(0x94c, PIN_INPUT_PULLDOWN | MUX_MODE7)
    		>;
    	};
    
        /* LCD */
    	dss_pins: dss_pins {
    		pinctrl-single,pins = <
    			//AM4372_IOPAD(0x820, PIN_OUTPUT | MUX_MODE1)	/* gpmc ad 8 -> DSS DATA 23 */
    			//AM4372_IOPAD(0x824, PIN_OUTPUT | MUX_MODE1)
    			//AM4372_IOPAD(0x828, PIN_OUTPUT | MUX_MODE1)
    			//AM4372_IOPAD(0x82c, PIN_OUTPUT | MUX_MODE1)
    			//AM4372_IOPAD(0x830, PIN_OUTPUT | MUX_MODE1)
    			//AM4372_IOPAD(0x834, PIN_OUTPUT | MUX_MODE1)
    			//AM4372_IOPAD(0x838, PIN_OUTPUT | MUX_MODE1)
    			//AM4372_IOPAD(0x83c, PIN_OUTPUT | MUX_MODE1)	/* gpmc ad 15 -> DSS DATA 16 */
    			//AM4372_IOPAD(0x8a0, PIN_OUTPUT | MUX_MODE0)	/* DSS DATA 0 */
    			//AM4372_IOPAD(0x8a4, PIN_OUTPUT | MUX_MODE0)
    			//AM4372_IOPAD(0x8a8, PIN_OUTPUT | MUX_MODE0)
    			//AM4372_IOPAD(0x8ac, PIN_OUTPUT | MUX_MODE0)
    			//AM4372_IOPAD(0x8b0, PIN_OUTPUT | MUX_MODE0)
    			//AM4372_IOPAD(0x8b4, PIN_OUTPUT | MUX_MODE0)
    			//AM4372_IOPAD(0x8b8, PIN_OUTPUT | MUX_MODE0)
    			//AM4372_IOPAD(0x8bc, PIN_OUTPUT | MUX_MODE0)
    			//AM4372_IOPAD(0x8c0, PIN_OUTPUT | MUX_MODE0)
    			//AM4372_IOPAD(0x8c4, PIN_OUTPUT | MUX_MODE0)
    			//AM4372_IOPAD(0x8c8, PIN_OUTPUT | MUX_MODE0)
    			//AM4372_IOPAD(0x8cc, PIN_OUTPUT | MUX_MODE0)
    			//AM4372_IOPAD(0x8d0, PIN_OUTPUT | MUX_MODE0)
    			//AM4372_IOPAD(0x8d4, PIN_OUTPUT | MUX_MODE0)
    			//AM4372_IOPAD(0x8d8, PIN_OUTPUT | MUX_MODE0)
    			//AM4372_IOPAD(0x8dc, PIN_OUTPUT | MUX_MODE0)	/* DSS DATA 15 */
    			//AM4372_IOPAD(0x8e0, PIN_OUTPUT | MUX_MODE0)	/* DSS VSYNC */
    			//AM4372_IOPAD(0x8e4, PIN_OUTPUT | MUX_MODE0)	/* DSS HSYNC */
    			//AM4372_IOPAD(0x8e8, PIN_OUTPUT | MUX_MODE0)	/* DSS PCLK */
    			//AM4372_IOPAD(0x8ec, PIN_OUTPUT | MUX_MODE0)	/* DSS AC BIAS EN */
                // reordered as bootloader version:
                AM4372_IOPAD(0xe0, PIN_OUTPUT | MUX_MODE0 ) /* (B23) dss_vsync.dss_vsync */
    			AM4372_IOPAD(0xe4, PIN_OUTPUT | MUX_MODE0 ) /* (A23) dss_hsync.dss_hsync */
    			AM4372_IOPAD(0xe8, PIN_OUTPUT | MUX_MODE0 ) /* (A22) dss_pclk.dss_pclk */
    			AM4372_IOPAD(0xec, PIN_OUTPUT | MUX_MODE0 ) /* (A24) dss_ac_bias_en.dss_ac_bias_en */
    			AM4372_IOPAD(0xa0, PIN_OUTPUT | MUX_MODE0 ) /* (B22) dss_data0.dss_data0 */
    			AM4372_IOPAD(0xa4, PIN_OUTPUT | MUX_MODE0 ) /* (A21) dss_data1.dss_data1 */
    			AM4372_IOPAD(0xa8, PIN_OUTPUT | MUX_MODE0 ) /* (B21) dss_data2.dss_data2 */
    			AM4372_IOPAD(0xac, PIN_OUTPUT | MUX_MODE0 ) /* (C21) dss_data3.dss_data3 */
    			AM4372_IOPAD(0xb0, PIN_OUTPUT | MUX_MODE0 ) /* (A20) dss_data4.dss_data4 */
    			AM4372_IOPAD(0xb4, PIN_OUTPUT | MUX_MODE0 ) /* (B20) dss_data5.dss_data5 */
    			AM4372_IOPAD(0xb8, PIN_OUTPUT | MUX_MODE0 ) /* (C20) dss_data6.dss_data6 */
    			AM4372_IOPAD(0xbc, PIN_OUTPUT | MUX_MODE0 ) /* (E19) dss_data7.dss_data7 */
    			AM4372_IOPAD(0xc0, PIN_OUTPUT | MUX_MODE0 ) /* (A19) dss_data8.dss_data8 */
    			AM4372_IOPAD(0xc4, PIN_OUTPUT | MUX_MODE0 ) /* (B19) dss_data9.dss_data9 */
    			AM4372_IOPAD(0xc8, PIN_OUTPUT | MUX_MODE0 ) /* (A18) dss_data10.dss_data10 */
    			AM4372_IOPAD(0xcc, PIN_OUTPUT | MUX_MODE0 ) /* (B18) dss_data11.dss_data11 */
    			AM4372_IOPAD(0xd0, PIN_OUTPUT | MUX_MODE0 ) /* (C19) dss_data12.dss_data12 */
    			AM4372_IOPAD(0xd4, PIN_OUTPUT | MUX_MODE0 ) /* (D19) dss_data13.dss_data13 */
    			AM4372_IOPAD(0xd8, PIN_OUTPUT | MUX_MODE0 ) /* (C17) dss_data14.dss_data14 */
    			AM4372_IOPAD(0xdc, PIN_OUTPUT | MUX_MODE0 ) /* (D17) dss_data15.dss_data15 */
    			AM4372_IOPAD(0x3c, PIN_OUTPUT | MUX_MODE1 ) /* (A11) gpmc_ad15.dss_data16 */
    			AM4372_IOPAD(0x38, PIN_OUTPUT | MUX_MODE1 ) /* (B11) gpmc_ad14.dss_data17 */
    			AM4372_IOPAD(0x34, PIN_OUTPUT | MUX_MODE1 ) /* (C11) gpmc_ad13.dss_data18 */
    			AM4372_IOPAD(0x30, PIN_OUTPUT | MUX_MODE1 ) /* (E11) gpmc_ad12.dss_data19 */
    			AM4372_IOPAD(0x2c, PIN_OUTPUT | MUX_MODE1 ) /* (D11) gpmc_ad11.dss_data20 */
    			AM4372_IOPAD(0x28, PIN_OUTPUT | MUX_MODE1 ) /* (F11) gpmc_ad10.dss_data21 */
    			AM4372_IOPAD(0x24, PIN_OUTPUT | MUX_MODE1 ) /* (A10) gpmc_ad9.dss_data22 */
    			AM4372_IOPAD(0x20, PIN_OUTPUT | MUX_MODE1 ) /* (B10) gpmc_ad8.dss_data23 */
    		>;
    	};
    
    
        /* Serial Flash Not used on AHMI */
    	//qspi_pins: qspi_pins {
    		//pinctrl-single,pins = <
    			//AM4372_IOPAD(0x87c, PIN_OUTPUT | MUX_MODE3)	/* gpmc_csn0.qspi_csn */
    			//AM4372_IOPAD(0x888, PIN_OUTPUT | MUX_MODE2)	/* gpmc_csn3.qspi_clk */
    			//AM4372_IOPAD(0x890, PIN_INPUT | MUX_MODE3)	/* gpmc_advn_ale.qspi_d0 */
    			//AM4372_IOPAD(0x894, PIN_INPUT | MUX_MODE3)	/* gpmc_oen_ren.qspi_d1 */
    			//AM4372_IOPAD(0x898, PIN_INPUT | MUX_MODE3)	/* gpmc_wen.qspi_d2 */
    			//AM4372_IOPAD(0x89c, PIN_INPUT | MUX_MODE3)	/* gpmc_be0n_cle.qspi_d3 */
    		//>;
    	//};
    
    
        /* audio */
    	mcasp1_pins: mcasp1_pins {
    		pinctrl-single,pins = <
    			AM4372_IOPAD(0x90c, PIN_INPUT_PULLDOWN | MUX_MODE4)	/* mii1_crs.mcasp1_aclkx */
    			AM4372_IOPAD(0x910, PIN_INPUT_PULLDOWN | MUX_MODE4)	/* mii1_rxerr.mcasp1_fsx */
    			AM4372_IOPAD(0x908, PIN_OUTPUT_PULLDOWN | MUX_MODE4)	/* mii1_col.mcasp1_axr2 */
    			AM4372_IOPAD(0x944, PIN_INPUT_PULLDOWN | MUX_MODE4)	/* rmii1_ref_clk.mcasp1_axr3 */
    		>;
    	};
    
        /* audio */
    	mcasp1_pins_sleep: mcasp1_pins_sleep {
    		pinctrl-single,pins = <
    			AM4372_IOPAD(0x90c, PIN_INPUT_PULLDOWN | MUX_MODE7)
    			AM4372_IOPAD(0x910, PIN_INPUT_PULLDOWN | MUX_MODE7)
    			AM4372_IOPAD(0x908, PIN_INPUT_PULLDOWN | MUX_MODE7)
    			AM4372_IOPAD(0x944, PIN_INPUT_PULLDOWN | MUX_MODE7)
    		>;
    	};
    
    	lcd_pins: lcd_pins {
    		pinctrl-single,pins = <
    			AM4372_IOPAD(0x81c, PIN_OUTPUT_PULLDOWN | MUX_MODE7) /* gpcm_ad7.gpio1_7 */
    		>;
    	};
    
        /* CAN0 */
    	dcan0_default: dcan0_default_pins {
    		pinctrl-single,pins = <
    			AM4372_IOPAD(0x978, PIN_OUTPUT | MUX_MODE2)		/* (K22) uart1_ctsn.d_can0_tx */
    			AM4372_IOPAD(0x97c, PIN_INPUT_PULLUP | MUX_MODE2)	/* (L22) uart1_rtsn.d_can0_rx */
    		>;
    	};
    
    	/* CAN1 */
    	dcan1_default: dcan1_default_pins {
    		pinctrl-single,pins = <
    			AM4372_IOPAD(0x968,  PIN_OUTPUT | MUX_MODE2 ) /* (L25) uart0_ctsn.dcan1_tx */
    			AM4372_IOPAD(0x96c,  PIN_INPUT_PULLUP | MUX_MODE2 ) /* (J25) uart0_rtsn.dcan1_rx */
    		>;
    	};
    
        /* UART2 - Expansion Header */
    	uart2_pins: uart2_pins {
    		pinctrl-single,pins = <
    			AM4372_IOPAD(0x950,  PIN_INPUT | MUX_MODE1 ) /* (P23) spi0_sclk.uart2_rxd */
    			AM4372_IOPAD(0x954,  PIN_OUTPUT | MUX_MODE1 ) /* (T22) spi0_d0.uart2_txd */
    		>;
    	};
    
    
        /* USB1 uses usb0 pins?  jsp this came from RS*/
    	usb1_pins: usb1_pins {
    		pinctrl-single,pins = <
    			AM4372_IOPAD(0xac0, PIN_OUTPUT | MUX_MODE0) /* usb0_drvvbus.usb0_drvvbus */
    		>;
    	};
    
        /* USB1 uses usb0 pins?  jsp this came from RS*/
    	usb2_pins: usb2_pins {
    		pinctrl-single,pins = <
    			AM4372_IOPAD(0xac4, PIN_OUTPUT | MUX_MODE0) /* usb0_drvvbus.usb0_drvvbus */
    		>;
    	};
    };
    
    &i2c0 {
    	status = "okay";
    	pinctrl-names = "default";
    	pinctrl-0 = <&i2c0_pins>;
    	clock-frequency = <100000>;
    
    	tps@24 {
    		compatible = "ti,tps65218";
    		reg = <0x24>;
    		interrupts = <GIC_SPI 7 IRQ_TYPE_LEVEL_HIGH>;
    		interrupt-controller;
    		#interrupt-cells = <2>;
    
    		dcdc1: regulator-dcdc1 {
    			/* VDD_CORE limits min of OPP50 and max of OPP100 */
    			regulator-name = "vdd_core";
    			regulator-min-microvolt = <912000>;
    			regulator-max-microvolt = <1144000>;
    			regulator-boot-on;
    			regulator-always-on;
    		};
    
    		dcdc2: regulator-dcdc2 {
    			/* VDD_MPU limits min of OPP50 and max of OPP_NITRO */
    			regulator-name = "vdd_mpu";
    			regulator-min-microvolt = <912000>;
    			regulator-max-microvolt = <1378000>;
    			regulator-boot-on;
    			regulator-always-on;
    		};
    
    		dcdc3: regulator-dcdc3 {
    			regulator-name = "vdds_ddr";
    			regulator-boot-on;
    			regulator-always-on;
    			regulator-state-mem {
    				regulator-on-in-suspend;
    			};
    			regulator-state-disk {
    				regulator-off-in-suspend;
    			};
    		};
    
    		dcdc4: regulator-dcdc4 {
    			regulator-name = "v3_3d";
    			regulator-min-microvolt = <3300000>;
    			regulator-max-microvolt = <3300000>;
    			regulator-boot-on;
    			regulator-always-on;
    		};
    
    		dcdc5: regulator-dcdc5 {
    			compatible = "ti,tps65218-dcdc5";
    			regulator-name = "v1_0bat";
    			regulator-min-microvolt = <1000000>;
    			regulator-max-microvolt = <1000000>;
    			regulator-boot-on;
    			regulator-always-on;
    			regulator-state-mem {
    				regulator-on-in-suspend;
    			};
    		};
    
    		dcdc6: regulator-dcdc6 {
    			compatible = "ti,tps65218-dcdc6";
    			regulator-name = "v1_8bat";
    			regulator-min-microvolt = <1800000>;
    			regulator-max-microvolt = <1800000>;
    			regulator-boot-on;
    			regulator-always-on;
    			regulator-state-mem {
    				regulator-on-in-suspend;
    			};
    		};
    
    		ldo1: regulator-ldo1 {
    			regulator-name = "v1_8d";
    			regulator-min-microvolt = <1800000>;
    			regulator-max-microvolt = <1800000>;
    			regulator-boot-on;
    			regulator-always-on;
    		};
    
    		power-button {
    			compatible = "ti,tps65218-pwrbutton";
    			status = "okay";
    			interrupts = <3 IRQ_TYPE_EDGE_BOTH>;
    		};
    	};
    
        /* EEPROM */
    	at24@50 {
    		compatible = "at24,24c256";
    		pagesize = <64>;
    		reg = <0x50>;
    	};
    
        /* Temperature and Humidity Sensor - HDC1080 */
    	hdc100x@40 {
    		compatible = "ti,hdc1080";
    		reg = <0x40>;
    	};
    
    };
    
    &i2c1 {
    	status = "okay";
    	pinctrl-names = "default";
    	pinctrl-0 = <&i2c1_pins>;
        /* 7" Touchscreen From GP EVM - Modified */
    	pixcir_ts@5c {
    		compatible = "pixcir,pixcir_tangoc";
    		pinctrl-names = "default";
    		pinctrl-0 = <&pixcir_ts_pins>;
    		reg = <0x5c>;
    
            attb-gpio = <&gpio0 31 GPIO_ACTIVE_HIGH>;  /* P0.31 (B3) Touch_IntN */
    
            /*
    		 * 0x264 represents the offset of padconf register of
    		 * gpio3_22 from am43xx_pinmux base.
    		 */
    		interrupts-extended = <&gpio0 31 IRQ_TYPE_EDGE_FALLING>,
    				      <&am43xx_pinmux 0x074>;
    		interrupt-names = "tsc", "wakeup";
    
    
    		touchscreen-size-x = <1024>;
    		touchscreen-size-y = <600>;
            wakeup-source;
    
    	};
    
    
        /* audio codec */
    	//tlv320aic3106: tlv320aic3106@1b {
    		//#sound-dai-cells = <0>;
    		//compatible = "ti,tlv320aic3106";
    		//reg = <0x1b>;
    		///*status = "okay";*/
    		//status = "disabled";
    
    		///* Regulators */
    		//AVDD-supply = <&dcdc4>;
    		//IOVDD-supply = <&dcdc4>;
    		//DRVDD-supply = <&dcdc4>;
    		//DVDD-supply = <&ldo1>;
    	//};
    
        /*accelerometer?*/
    	//lis331dlh@18 {
    		//compatible = "st,lis331dlh";
    		//reg = <0x18>;
    		//status = "okay";
    
    		//Vdd-supply = <&dcdc4>;
    		//Vdd_IO-supply = <&dcdc4>;
    		//interrupts-extended = <&gpio1 6 0>, <&gpio2 1 0>;
    	//};
    };
    
    &epwmss0 {
    	status = "okay";
    };
    
    /* backllight*/
    &ecap0 {
    	status = "okay";
    	pinctrl-names = "default";
    	pinctrl-0 = <&ecap0_pins>;
    };
    
    &gpio0 {
    	status = "okay";
    };
    
    &gpio1 {
    	status = "okay";
    };
    
    &gpio2 {
    	status = "okay";
    };
    
    &gpio3 {
    	status = "okay";
    };
    
    &gpio4 {
    	status = "okay";
    };
    
    &gpio5 {
    	status = "okay";
    };
    
    &mmc1 {
    	status = "okay";
    	pinctrl-names = "default";
    	pinctrl-0 = <&mmc1_pins>;
    
    	vmmc-supply = <&dcdc4>;
    	bus-width = <4>;
    	cd-gpios = <&gpio0 6 GPIO_ACTIVE_LOW>;
    };
    
    &usb2_phy1 {
    	status = "okay";
    };
    
    &usb1 {
    	dr_mode = "otg";
    	status = "okay";
    	pinctrl-names = "default";
    	pinctrl-0 = <&usb1_pins>;
    };
    
    &usb2_phy2 {
    	status = "okay";
    };
    
    &usb2 {
    	dr_mode = "host";
    	status = "okay";
    	pinctrl-names = "default";
    	pinctrl-0 = <&usb2_pins>;
    };
    
    //jsp added
    &spi2 {
        status = "okay";
        pinctrl-names = "default";
        pinctrl-0=<&spi2_pins>;
    
        // needed? correct dma channel?
        dmas = <&edma 16 0 &edma 17 0>;
        dma-names = "tx0", "rx0";
    
        flash:flash@1 {
            //compatible = "sst, sst25vf016b", "jedec,spi-nor";
            compatible = "sst, sst25vf016b";
            spi-max-frequency = <20000000>;
            reg = <0>;
    
            #address-cells = <1>;
            #size-cells = <1>;
    
           	partition@0 {
                label = "jsp1";
                reg = <0x0 0x80000>;
    		};
    
           	partition@1 {
                label = "jsp2";
                reg = <0x100000 0x80000>;
    		};
    
        };
    };
    
    /* serial flash not used on ahmi */
    //&qspi {
    	///*status = "okay";*/
    	//status = "disabled";
    	//pinctrl-names = "default";
    	//pinctrl-0 = <&qspi_pins>;
    //
    	//spi-max-frequency = <48000000>;
    	//m25p80@0 {
    		//compatible = "mx66l51235l";
    		//spi-max-frequency = <48000000>;
    		//reg = <0>;
    		//spi-cpol;
    		//spi-cpha;
    		//spi-tx-bus-width = <1>;
    		//spi-rx-bus-width = <4>;
    		//#address-cells = <1>;
    		//#size-cells = <1>;
    
    		/* MTD partition table.
    		 * The ROM checks the first 512KiB
    		 * for a valid file to boot(XIP).
    		 */
    		//partition@0 {
    			//label = "QSPI.U_BOOT";
    			//reg = <0x00000000 0x000080000>;
    		//};
    		//partition@1 {
    			//label = "QSPI.U_BOOT.backup";
    			//reg = <0x00080000 0x00080000>;
    		//};
    		//partition@2 {
    			//label = "QSPI.U-BOOT-SPL_OS";
    			//reg = <0x00100000 0x00010000>;
    		//};
    		//partition@3 {
    			//label = "QSPI.U_BOOT_ENV";
    			//reg = <0x00110000 0x00010000>;
    		//};
    		//partition@4 {
    			//label = "QSPI.U-BOOT-ENV.backup";
    			//reg = <0x00120000 0x00010000>;
    		//};
    		//partition@5 {
    			//label = "QSPI.KERNEL";
    			//reg = <0x00130000 0x0800000>;
    		//};
    		//partition@6 {
    			//label = "QSPI.FILESYSTEM";
    			//reg = <0x00930000 0x36D0000>;
    		//};
    	//};
    //};
    
    &mac {
    	pinctrl-names = "default", "sleep";
    	pinctrl-0 = <&cpsw_default>;
    	pinctrl-1 = <&cpsw_sleep>;
    	//dual_emac = <1>;
    	status = "okay";
    };
    
    &davinci_mdio {
    	pinctrl-names = "default", "sleep";
        compatable = "ti, cpsw-mdio","ti,davinci_mdio";
    	pinctrl-0 = <&davinci_mdio_default>;
    	pinctrl-1 = <&davinci_mdio_sleep>;
    	status = "okay";
    
        dp83867_0: ethernet-phy@0{
            reg = <0>; //jsp
            ti,rx-internal-delay = <DP83867_RGMIIDCTL_1_75_NS>; //jsp
    	    ti,tx-internal-delay = <DP83867_RGMIIDCTL_1_75_NS>; //jsp
    	    ti,fifo-depth = <DP83867_PHYCR_FIFO_DEPTH_4_B_NIB>;
            ti,min-output-impedence;
            ti,dp83867-rxctrl-strap-quirk;
        };
    };
    
    &cpsw_emac0 {
    	phy_id = <&davinci_mdio>, <0>;
    	phy-mode = "rgmii-txid";
    	dual_emac_res_vlan = <1>;
    };
    
    //&cpsw_emac1 {
    	//phy_id = <&davinci_mdio>, <5>;
    	//phy-mode = "rgmii";
    	//dual_emac_res_vlan = <2>;
    //};
    
    &elm {
    	status = "okay";
    };
    
    &mcasp1 {
    	#sound-dai-cells = <0>;
    	pinctrl-names = "default", "sleep";
    	pinctrl-0 = <&mcasp1_pins>;
    	pinctrl-1 = <&mcasp1_pins_sleep>;
    
    	status = "okay";
    
    	op-mode = <0>;
    	tdm-slots = <2>;
    	serial-dir = <
    		0 0 1 2
    	>;
    
    	tx-num-evt = <1>;
    	rx-num-evt = <1>;
    };
    
    &dss {
    	status = "okay";
    
    	pinctrl-names = "default";
    	pinctrl-0 = <&dss_pins>;
    
    	port {
    		dpi_out: endpoint@0 {
    			remote-endpoint = <&lcd_in>;
    			data-lines = <24>;
    		};
    	};
    };
    
    /* CAN0 */
    &dcan0 {
    	pinctrl-names = "default";
    	pinctrl-0 = <&dcan0_default>;
    	status = "okay";
    };
    
    /* CAN1 */
    &dcan1 {
    	pinctrl-names = "default";
    	pinctrl-0 = <&dcan1_default>;
    	status = "okay";
    };
    
    
    &rtc {
    	clocks = <&clk_32k_rtc>, <&clk_32768_ck>;
    	clock-names = "ext-clk", "int-clk";
    	status = "okay";
    };
    
    &wdt {
    	status = "okay";
    };
    
    &cpu {
    	cpu0-supply = <&dcdc2>;
    };
    
    &vpfe0 {
    	status = "okay";
    	pinctrl-names = "default", "sleep";
    	pinctrl-0 = <&vpfe0_pins_default>;
    	pinctrl-1 = <&vpfe0_pins_sleep>;
    
    	/* Camera port */
    	port {
    		vpfe0_ep: endpoint {
    			/* remote-endpoint = <&ov2659_1>; jsp */
    			ti,am437x-vpfe-interface = <0>;
    			bus-width = <8>;
    			hsync-active = <0>;
    			vsync-active = <0>;
    		};
    	};
    };
    
    &wkup_m3_ipc {
    	ti,scale-data-fw = "am43x-evm-scale-data.bin";
    };
    
    &pruss_soc_bus {
    	status = "okay";
    
    	pruss1: pruss@54400000 {
    		status = "okay";
    
    		pru1_0: pru@54434000 {
    			status = "okay";
    		};
    
    		pru1_1: pru@54438000 {
    			status = "okay";
    		};
    	};
    
    	pruss0: pruss@54440000 {
    		status = "okay";
    
    		pru0_0: pru@54474000 {
    			status = "okay";
    		};
    
    		pru0_1: pru@54478000 {
    			status = "okay";
    		};
    	};
    };
    
    &sgx {
    	status = "okay";
    };
    
    1780.config.txtSorry I took so long getting back to you, I took a little time off and then got sidelined by some other issues.  Here are the requested files.  When I cat proc/mtd I only get column headings, no entries.

  • James,

    I have checked your config file, and I see you are missing CONFIG_SPI_DAVINCI=y

    Please make your config file with below sequence and try again:

    1. use tisdk_am437x-evm_defconfig, see below user guide:
    software-dl.ti.com/.../Foundational_Components_Kernel_Users_Guide.html

    2. modify the default configuration according to the instructions in below user guide:
    software-dl.ti.com/.../Foundational_Components_Kernel_Drivers.html

    Regards,
    Pavel
  • James,

    I have also checked your dts file, and I see some need for updates there:

    - flash:flash@1 {
    + flash: m25p80@0 { // you are using CS0, thus @0 is needed

    - compatible = "sst, sst25vf016b";
    + compatible = "sst,sst25vf016b", "jedec,spi-nor";

    "sst,sst25vf016b" points to nowhere, you need "jedec,spi-nor" which is using below two files:

    linux-kernel/drivers/mtd/devices/m25p80.c
    linux-kernel/drivers/mtd/spi-nor/spi-nor.c

    Regards,
    Pavel
  • Pavel-

    I am slowly going through your suggestions, thanks.  One question .  I do not see CONFIG_SPI_DAVINCI  in any version of tisdk_am437x-evm_defconfig which was the starting place for my config.  doing a grep I see in SDK 05:02:

    davinci_all_defconfig:CONFIG_SPI_DAVINCI=m
    keystone_defconfig:CONFIG_SPI_DAVINCI=y
    multi_v7_defconfig:CONFIG_SPI_DAVINCI=y

    and in 04:03

    davinci_all_defconfig:CONFIG_SPI_DAVINCI=m
    keystone_defconfig:CONFIG_SPI_DAVINCI=y
    lsk_defconfig:CONFIG_SPI_DAVINCI=y
    multi_v7_defconfig:CONFIG_SPI_DAVINCI=y
    ti_sdk_am4x_release_defconfig:CONFIG_SPI_DAVINCI=y

    It needs to be there to see in menuconfig, right?

    Did you misspeak? or am I missing something? 

    james

  • James,

    I agree, you do not need CONFIG_SPI_DAVINCI. AM437x is using CONFIG_SPI_OMAP24XX instead.

    Regards,
    Pavel
  • So I still have not gotten this to work. I guess I have some assumptions and some questions.
    1. I think if the drivers are enabled in .config (and I think we have verified that) and the device tree is set up correctly I should see /dev/mtd partitions. Is there anything else that has to be done? The flash is just empty at this point.
    2. I tried to use debugging in u-boot and got no-where. Digging around a bit, I found a post talking about enabling omap3 in u-boot. Is that required for just debugging? Or is that required to make this work.
    3. I have seen some confusing stuff about what direction the pins should be set for, I have tried a bunch of ways with no change, advice?

    here is my current dts entries. (same in u-boot and kernel)

    &spi2 {
    status = "okay";
    pinctrl-names = "default";
    pinctrl-0 = <&spi2_pins>;

    /* Flash - SST25VF016B (manditory fields "compatible", "spi-max-frequency", "reg") */
    //flash: sst25vf016b@0 {
    flash: m25p80@0 { // you are using CS0, thus @0 is needed
    #address-cells = <1>; // saw this in an example
    #size-cells = <1>; // saw this in an example
    compatible = "sst,sst25vf016b", "jedec,spi-nor";
    spi-max-frequency = <20000000>;
    reg = <0>;

    partition@0 {
    label = "jsp1";
    reg = <0x0 0x2000000>;
    };

    //partition@1 {
    //label = "jsp2";
    //reg = <0x100000 0x80000>;
    //};

    };
    };

    spi2_pins: spi2_pins {
    pinctrl-single,pins = <
    0x260 ( PIN_INPUT_PULLUP | MUX_MODE0 ) /* (N20) spi2_sclk.spi2_sclk */
    0x264 ( PIN_INPUT_PULLUP | MUX_MODE0 ) /* (P22) spi2_d0.spi2_d0 */
    0x268 ( PIN_INPUT_PULLUP | MUX_MODE0 ) /* (P20) spi2_d1.spi2_d1 */
    0x26c ( PIN_INPUT_PULLUP | MUX_MODE0 ) /* (T23) spi2_cs0.spi2_cs0 */

    //0x260 ( PIN_INPUT | MUX_MODE0 ) /* (N20) spi2_sclk.spi2_sclk */
    //0x264 ( PIN_INPUT | MUX_MODE0 ) /* (P22) spi2_d0.spi2_d0 */
    //0x268 ( PIN_INPUT | MUX_MODE0 ) /* (P20) spi2_d1.spi2_d1 */
    //0x26c ( PIN_INPUT | MUX_MODE0 ) /* (T23) spi2_cs0.spi2_cs0 */
    >;
    };
  • James Pawlyk said:
    1. I think if the drivers are enabled in .config (and I think we have verified that) and the device tree is set up correctly I should see /dev/mtd partitions. Is there anything else that has to be done? The flash is just empty at this point.

    I do not think there is something more. We need to setup DTS correctly. You might have HW issue also.

    James Pawlyk said:
    2. I tried to use debugging in u-boot and got no-where. Digging around a bit, I found a post talking about enabling omap3 in u-boot. Is that required for just debugging? Or is that required to make this work.

    Why u-boot? We configure linux kernel, make sure you are updating linux kernel DTS file, not u-boot DTS file.

    You can debug McSPI linux driver (enable dev_vdbg messages)

    linux-kernel/drivers/spi/spi-omap2-mcspi.c

    James Pawlyk said:
    3. I have seen some confusing stuff about what direction the pins should be set for, I have tried a bunch of ways with no change, advice?

    James Pawlyk said:
    0x26c ( PIN_INPUT_PULLUP | MUX_MODE0 ) /* (T23) spi2_cs0.spi2_cs0 */

    Can you try to set spi2_cs0 as output? Note that AM437x McSPI driver can work on master mode only. You can also probe the SPI2 pins with scope and check if you will see the expected activity there.

    Also can you verify your pinmux is correct at user space? You can dump the pinmux registers (i.e. CTRL_CONF_SPI2_CS0/0x44E10A6C) with devmem2 or omapconf tool.

    James Pawlyk said:
    partition@0 {
    label = "jsp1";
    reg = <0x0 0x2000000>;

    Can you try if below update will make any difference?

    - reg = <0x0 0x2000000>;

    + reg = <0x0 0x100000>

    Regards,
    Pavel

  • Changed direction for chip select and changed the reg value. Haven't figured out how to enable vdbg messages yet. I did notice this in dmesg (not in start up output): does that look correct? Looks to me like481a2000 is correct not sure why its spi1.0. I may be pulled into something else for a day or so.

    1.068791] omap2_mcspi 481a2000.spi: registered master spi1
    [ 1.069039] spi spi1.0: setup: speed 1000000, sample leading edge, clk normal
    [ 1.069053] spi spi1.0: setup mode 0, 8 bits/w, 1000000 Hz max --> 0
    [ 1.069242] omap2_mcspi 481a2000.spi: registered child spi1.0
    [ 1.070087] libphy: Fixed MDIO Bus: probed
    [ 1.142366] davinci_mdio 4a101000.mdio: davinci mdio revision 1.6
    [ 1.148505] libphy: 4a101000.mdio: probed
    [ 1.153365] davinci_mdio 4a101000.mdio: phy[0]: device 4a101000.mdio:00, driver TI DP83867
    [ 1.162450] cpsw 4a100000.ethernet: No slave[1] phy_id, phy-handle, or fixed-link property
    [ 1.170765] cpsw 4a100000.ethernet: Detected MACID = c4:f3:12:b4:94:c4
    [ 1.177460] cpsw 4a100000.ethernet: device node lookup for pps timer failed
    [ 1.184554] cpsw 4a100000.ethernet: cpts: overflow check period 500 (jiffies)
    [ 1.193218] mousedev: PS/2 mouse device common for all mice
    [ 1.199142] i2c /dev entries driver
  • James,

    James Pawlyk said:
    I did notice this in dmesg (not in start up output): does that look correct? Looks to me like481a2000 is correct not sure why its spi1.0.

    James Pawlyk said:
    1.068791] omap2_mcspi 481a2000.spi: registered master spi1

    This seems correct to me.

    Regards,
    Pavel

  • If you have no more questions related to the subject of the e2e thread, please close/verify/resolve this thread.

    Regards,
    Pavel
  • will do, just getting back to this today.