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/AM3352: Kernel boot issue

Part Number: AM3352


Tool/software: Linux

Hi!

I have some trouble in our custom board based on AM335x-EVMSK.

We use SD card for booting (without wp, cd pins).

U-Boot works fine, but Kernel is hanging on these line: "Waiting for root device PARTUUID=partuuid-02..."

I was trying more variants of device tree files and mux.c in many combinations, but no one worked. Also i was trying use "stub" pin for CD pin (connected to Ground).

I read other topics about this issue, but Im still cant fix it.

MMC node:

&mmc1 {				                    // SD Card
	vmmc-supply = <&vmmc_reg>;
	bus-width = <4>;
	pinctrl-names = "default";
	pinctrl-0 = <&mmc1_pins>;
	broken-cd;
	status = "okay";
};

mmc1_pins node: 

mmc1_pins: pinmux_mmc1_pins {
	pinctrl-single,pins = <
		AM33XX_IOPAD(PIN_MMC0_DAT3, (PIN_INPUT_PULLUP | MUX_MODE0))
		AM33XX_IOPAD(PIN_MMC0_DAT2, (PIN_INPUT_PULLUP | MUX_MODE0))
		AM33XX_IOPAD(PIN_MMC0_DAT1, (PIN_INPUT_PULLUP | MUX_MODE0))
		AM33XX_IOPAD(PIN_MMC0_DAT0, (PIN_INPUT_PULLUP | MUX_MODE0))
		AM33XX_IOPAD(PIN_MMC0_CMD, (PIN_INPUT_PULLUP | MUX_MODE0))
		AM33XX_IOPAD(PIN_MMC0_CLK, (PIN_INPUT_PULLUP | MUX_MODE0))
	>;
};

This is my full kernel-side dts file: 

/dts-v1/;

#include "am33xx.dtsi"
#include <dt-bindings/pwm/pwm.h>
#include <dt-bindings/interrupt-controller/irq.h>
#include <dt-bindings/arm/myboard_am335x_pinmux.h>

/ {
	model = "myboard";
	compatible = "ti,am33xx", "mycompany,myboard";

	chosen {
		stdout-path = &uart1;
		tick-timer = &timer2;
		};

	cpus {
		cpu@0 {
			cpu0-supply = <&vdd1_reg>;
		};
	};

	memory@80000000 {
		device_type = "memory";
		reg = <0x80000000 0x10000000>; /* 256 MB */
	};

	vbat: fixedregulator0 {
		compatible = "regulator-fixed";
		regulator-name = "vbat";
		regulator-min-microvolt = <15000000>;
		regulator-max-microvolt = <24000000>;
		regulator-boot-on;
	};

	leds {
		pinctrl-names = "default";
		pinctrl-0 = <&user_leds_s0>;

		compatible = "gpio-leds";

		led1 {
			label = "evmsk:green:heartbeat";
			gpios = <&gpio0 27 GPIO_ACTIVE_HIGH>;
			linux,default-trigger = "heartbeat";
			default-state = "off";
		};

		led2 {
			label = "evmsk:green:mmc0";
			gpios = <&gpio0 26 GPIO_ACTIVE_HIGH>;
			linux,default-trigger = "mmc0";
			default-state = "off";
		};
	};

	gpio_buttons: gpio_buttons0 {
		compatible = "gpio-keys";
		#address-cells = <1>;
		#size-cells = <0>;

		switch1 {
			label = "button0";			// S3 GPIO_KEY1
			linux,code = <0x100>;
			gpios = <&gpio0 30 GPIO_ACTIVE_HIGH>;
		};

		switch2 {
			label = "button1";
			linux,code = <0x101>;		// S2 GPIO_KEY2
			gpios = <&gpio2 3 GPIO_ACTIVE_HIGH>;
		};

		switch3 {
			label = "button2";			// S4 GPIO_CASE_OPEN_CLOSE
			linux,code = <0x102>;
			gpios = <&gpio1 28 GPIO_ACTIVE_HIGH>;
		};
	};
};

&am33xx_pinmux {
	pinctrl-names = "default";

	ddr3_vtt_toggle: ddr3_vtt_toggle {
		pinctrl-single,pins = <
			AM33XX_IOPAD(PIN_USB0_DRVVBUS, (PIN_OUTPUT | MUX_MODE7))	/* AM33XX_IOPAD.gpio0_18 */
		>;
	};

	user_leds_s0: user_leds_s0 {
		pinctrl-single,pins = <
			AM33XX_IOPAD(PIN_GPMC_AD11, PIN_OUTPUT_PULLDOWN | MUX_MODE7)	/* gpmc_ad11, AVR220_LED0 */
			AM33XX_IOPAD(PIN_GPMC_AD10, PIN_OUTPUT_PULLDOWN | MUX_MODE7)	/* gpmc_ad10, AVR220_LED1 */
		>;
	};

	i2c0_pins: pinmux_i2c0_pins {
		pinctrl-single,pins = <
			AM33XX_IOPAD(PIN_I2C0_SDA, PIN_INPUT_PULLUP | MUX_MODE0)	/* i2c0_sda.i2c0_sda */
			AM33XX_IOPAD(PIN_I2C0_SCL, PIN_INPUT_PULLUP | MUX_MODE0)	/* i2c0_scl.i2c0_scl */
		>;
	};

	uart1_pins: pinmux_uart1_pins {
		pinctrl-single,pins = <
			AM33XX_IOPAD(PIN_UART1_RXD, PIN_INPUT_PULLUP | MUX_MODE0)	/* uart1_rxd.uart1_rxd */
			AM33XX_IOPAD(PIN_UART1_TXD, PIN_OUTPUT_PULLDOWN | MUX_MODE0)	/* uart1_txd.uart1_txd */
		>;
	};

	mmc1_pins: pinmux_mmc1_pins {
		pinctrl-single,pins = <
			AM33XX_IOPAD(PIN_MMC0_DAT3, (PIN_INPUT_PULLUP | MUX_MODE0))
			AM33XX_IOPAD(PIN_MMC0_DAT2, (PIN_INPUT_PULLUP | MUX_MODE0))
			AM33XX_IOPAD(PIN_MMC0_DAT1, (PIN_INPUT_PULLUP | MUX_MODE0))
			AM33XX_IOPAD(PIN_MMC0_DAT0, (PIN_INPUT_PULLUP | MUX_MODE0))
			AM33XX_IOPAD(PIN_MMC0_CMD, (PIN_INPUT_PULLUP | MUX_MODE0))
			AM33XX_IOPAD(PIN_MMC0_CLK, (PIN_INPUT_PULLUP | MUX_MODE0))
		>;
	};

	mmc2_pins: pinmux_mmc2_pins {
		pinctrl-single,pins = <
			AM33XX_IOPAD(PIN_GPMC_CSN1, (PIN_INPUT_PULLUP | MUX_MODE2)) /* gpmc_csn1.mmc1_clk */
			AM33XX_IOPAD(PIN_GPMC_CSN2, (PIN_INPUT_PULLUP | MUX_MODE2)) /* gpmc_csn2.mmc1_cmd */
			AM33XX_IOPAD(PIN_GPMC_AD0, (PIN_INPUT_PULLUP | MUX_MODE1)) /* gpmc_ad0.mmc1_dat0 */
			AM33XX_IOPAD(PIN_GPMC_AD1, (PIN_INPUT_PULLUP | MUX_MODE1)) /* gpmc_ad1.mmc1_dat1 */
			AM33XX_IOPAD(PIN_GPMC_AD2, (PIN_INPUT_PULLUP | MUX_MODE1)) /* gpmc_ad2.mmc1_dat2 */
			AM33XX_IOPAD(PIN_GPMC_AD3, (PIN_INPUT_PULLUP | MUX_MODE1)) /* gpmc_ad3.mmc1_dat3 */
			AM33XX_IOPAD(PIN_GPMC_AD4, (PIN_INPUT_PULLUP | MUX_MODE1)) /* gpmc_ad4.mmc1_dat4 */
			AM33XX_IOPAD(PIN_GPMC_AD5, (PIN_INPUT_PULLUP | MUX_MODE1)) /* gpmc_ad5.mmc1_dat5 */
			AM33XX_IOPAD(PIN_GPMC_AD6, (PIN_INPUT_PULLUP | MUX_MODE1)) /* gpmc_ad6.mmc1_dat6 */
			AM33XX_IOPAD(PIN_GPMC_AD7, (PIN_INPUT_PULLUP | MUX_MODE1)) /* gpmc_ad7.mmc1_dat7 */
		>;
	};
};


&uart1 {
	pinctrl-names = "default";
	pinctrl-0 = <&uart1_pins>;

	status = "okay";
};

&mmc1 {												// SD Card
	vmmc-supply = <&vmmc_reg>;
	bus-width = <4>;
	pinctrl-names = "default";
	pinctrl-0 = <&mmc1_pins>;
	broken-cd;
	status = "okay";
};

&mmc2 {												// MMC FLASH NAND
	vmmc-supply = <&vmmc_reg>;
	ti,non-removable;
	broken-cd;
	pinctrl-names = "default";
	pinctrl-0 = <&mmc2_pins>;
	bus-width = <8>;
	min-frequency = <26000000>;
	max-frequency = <52000000>;
	status = "okay";
};

&i2c0 {
	pinctrl-names = "default";
	pinctrl-0 = <&i2c0_pins>;

	status = "okay";
	clock-frequency = <400000>;

	tps: tps@2d {
		reg = <0x2d>;
	};
};

#include "tps65910.dtsi"

&tps {
	vcc1-supply = <&vbat>;
	vcc2-supply = <&vbat>;
	vcc3-supply = <&vbat>;
	vcc4-supply = <&vbat>;
	vcc5-supply = <&vbat>;
	vcc6-supply = <&vbat>;
	vcc7-supply = <&vbat>;
	vccio-supply = <&vbat>;

	regulators {
		vrtc_reg: regulator@0 {
			regulator-always-on;
		};

		vio_reg: regulator@1 {
			regulator-always-on;
		};

		vdd1_reg: regulator@2 {
			/* VDD_MPU voltage limits 0.95V - 1.26V with +/-4% tolerance */
			regulator-name = "vdd_mpu";
			regulator-min-microvolt = <912500>;
			regulator-max-microvolt = <1351500>;
			regulator-boot-on;
			regulator-always-on;
		};

		vdd2_reg: regulator@3 {
			/* VDD_CORE voltage limits 0.95V - 1.1V with +/-4% tolerance */
			regulator-name = "vdd_core";
			regulator-min-microvolt = <912500>;
			regulator-max-microvolt = <1150000>;
			regulator-boot-on;
			regulator-always-on;
		};

		vdd3_reg: regulator@4 {
			regulator-always-on;
		};

		vdig1_reg: regulator@5 {
			regulator-always-on;
		};

		vdig2_reg: regulator@6 {
			regulator-always-on;
		};

		vpll_reg: regulator@7 {
			regulator-always-on;
		};

		vdac_reg: regulator@8 {
			regulator-always-on;
		};

		vaux1_reg: regulator@9 {
			regulator-always-on;
		};

		vaux2_reg: regulator@10 {
			regulator-always-on;
		};

		vaux33_reg: regulator@11 {
			regulator-always-on;
		};

		vmmc_reg: regulator@12 {
			regulator-min-microvolt = <1800000>;
			regulator-max-microvolt = <3300000>;
			regulator-always-on;
		};
	};
};

/*

&gpio0 {
	ti,no-reset-on-init;
};

&gpio1 {
	ti,no-reset-on-init;
};

&gpio2 {
	ti,no-reset-on-init;
};

&gpio3 {
	ti,no-reset-on-init;
};


&sham {
	status = "okay";
};

&aes {
	status = "okay";
};

&sgx {
	status = "okay";
};

&usb {
	status = "okay";
};

&usb_ctrl_mod {
	status = "okay";
};

&usb1_phy {
	status = "okay";
};

&usb1 {
	status = "okay";
	dr_mode = "host";
};

&cppi41dma  {
	status = "okay";
};

&wkup_m3_ipc {
	ti,needs-vtt-toggle;
	ti,vtt-gpio-pin = <7>;
	ti,scale-data-fw = "am335x-evm-scale-data.bin";
};

&pruss_soc_bus {
	status = "okay";

	pruss: pruss@4a300000 {
		status = "okay";

		pru0: pru@4a334000 {
			status = "okay";
		};

		pru1: pru@4a338000 {
			status = "okay";
		};
	};
};
*/

This is my full u-boot side dts file: 

/dts-v1/;

#include "am33xx.dtsi"
#include <dt-bindings/pwm/pwm.h>
#include <dt-bindings/interrupt-controller/irq.h>
#include <xx_xx_am335x_pinmux.h>

/ {
	model = "myboardmodel";
	compatible = "ti,am33xx", "mycompany,myboard";

	chosen {
		stdout-path = &uart1;
		tick-timer = &timer2;
	};

	cpus {
		cpu@0 {
			cpu0-supply = <&vdd1_reg>;
		};
	};

	memory {
		device_type = "memory";
		reg = <0x80000000 0x10000000>; /* 256 MB */
	};

	vbat: fixedregulator@0 {
		compatible = "regulator-fixed";
		regulator-name = "vbat";
		regulator-min-microvolt = <15000000>;
		regulator-max-microvolt = <24000000>;
		regulator-boot-on;
	};

	leds {
		pinctrl-names = "default";
		pinctrl-0 = <&user_leds_s0>;

		compatible = "gpio-leds";

		led@1 {
			label = "evmsk:green:heartbeat";
			gpios = <&gpio1 12 GPIO_ACTIVE_HIGH>;
			linux,default-trigger = "heartbeat";
			default-state = "off";
		};

		led@2 {
			label = "evmsk:green:mmc0";
			gpios = <&gpio0 26 GPIO_ACTIVE_HIGH>;
			linux,default-trigger = "mmc0";
			default-state = "off";
		};
	};

	gpio_buttons: gpio_buttons@0 {
		compatible = "gpio-keys";
		#address-cells = <1>;
		#size-cells = <0>;

		switch@1 {
			label = "button0";			// S3 GPIO_KEY1
			linux,code = <0x100>;
			gpios = <&gpio0 30 GPIO_ACTIVE_HIGH>;
		};

		switch@2 {
			label = "button1";
			linux,code = <0x101>;		// S2 GPIO_KEY2
			gpios = <&gpio2 3 GPIO_ACTIVE_HIGH>;
		};

		switch@3 {
			label = "button2";			// S4 GPIO_CASE_OPEN_CLOSE
			linux,code = <0x102>;
			gpios = <&gpio1 28 GPIO_ACTIVE_HIGH>;
			wakeup-source;
		};
	};

	user_leds_s0: user_leds_s0 {
		pinctrl-single,pins = <
			AM33XX_IOPAD(PIN_GPMC_AD11, PIN_OUTPUT_PULLDOWN | MUX_MODE7)	/* gpmc_ad11, AVR220_LED0 */
			AM33XX_IOPAD(PIN_GPMC_AD10, PIN_OUTPUT_PULLDOWN | MUX_MODE7)	/* gpmc_ad10, AVR220_LED1 */
		>;
	};

	i2c0_pins: pinmux_i2c0_pins {
		pinctrl-single,pins = <
			AM33XX_IOPAD(PIN_I2C0_SDA, PIN_INPUT_PULLUP | MUX_MODE0)	/* i2c0_sda.i2c0_sda */
			AM33XX_IOPAD(PIN_I2C0_SCL, PIN_INPUT_PULLUP | MUX_MODE0)	/* i2c0_scl.i2c0_scl */
		>;
	};

	uart1_pins: pinmux_uart1_pins {
		pinctrl-single,pins = <
			AM33XX_IOPAD(PIN_UART1_RXD, PIN_INPUT_PULLUP | MUX_MODE0)	/* uart1_rxd.uart1_rxd */
			AM33XX_IOPAD(PIN_UART1_TXD, PIN_OUTPUT_PULLDOWN | MUX_MODE0)	/* uart1_txd.uart1_txd */
		>;
	};

	mmc1_pins: pinmux_mmc1_pins {
		pinctrl-single,pins = <
			AM33XX_IOPAD(PIN_MMC0_DAT3, (PIN_INPUT_PULLUP | MUX_MODE0))
			AM33XX_IOPAD(PIN_MMC0_DAT2, (PIN_INPUT_PULLUP | MUX_MODE0))
			AM33XX_IOPAD(PIN_MMC0_DAT1, (PIN_INPUT_PULLUP | MUX_MODE0))
			AM33XX_IOPAD(PIN_MMC0_DAT0, (PIN_INPUT_PULLUP | MUX_MODE0))
			AM33XX_IOPAD(PIN_MMC0_CMD, (PIN_INPUT_PULLUP | MUX_MODE0))
			AM33XX_IOPAD(PIN_MMC0_CLK, (PIN_INPUT_PULLUP | MUX_MODE0))
		>;
	};

	mmc2_pins: pinmux_mmc2_pins {
		pinctrl-single,pins = <
			AM33XX_IOPAD(PIN_GPMC_CSN1, (PIN_INPUT_PULLUP | MUX_MODE2)) /* gpmc_csn1.mmc1_clk */
			AM33XX_IOPAD(PIN_GPMC_CSN2, (PIN_INPUT_PULLUP | MUX_MODE2)) /* gpmc_csn2.mmc1_cmd */
			AM33XX_IOPAD(PIN_GPMC_AD0, (PIN_INPUT_PULLUP | MUX_MODE1)) /* gpmc_ad0.mmc1_dat0 */
			AM33XX_IOPAD(PIN_GPMC_AD1, (PIN_INPUT_PULLUP | MUX_MODE1)) /* gpmc_ad1.mmc1_dat1 */
			AM33XX_IOPAD(PIN_GPMC_AD2, (PIN_INPUT_PULLUP | MUX_MODE1)) /* gpmc_ad2.mmc1_dat2 */
			AM33XX_IOPAD(PIN_GPMC_AD3, (PIN_INPUT_PULLUP | MUX_MODE1)) /* gpmc_ad3.mmc1_dat3 */
			AM33XX_IOPAD(PIN_GPMC_AD4, (PIN_INPUT_PULLUP | MUX_MODE1)) /* gpmc_ad4.mmc1_dat4 */
			AM33XX_IOPAD(PIN_GPMC_AD5, (PIN_INPUT_PULLUP | MUX_MODE1)) /* gpmc_ad5.mmc1_dat5 */
			AM33XX_IOPAD(PIN_GPMC_AD6, (PIN_INPUT_PULLUP | MUX_MODE1)) /* gpmc_ad6.mmc1_dat6 */
			AM33XX_IOPAD(PIN_GPMC_AD7, (PIN_INPUT_PULLUP | MUX_MODE1)) /* gpmc_ad7.mmc1_dat7 */
		>;
	};

};

&uart1 {
	pinctrl-names = "default";
	pinctrl-0 = <&uart1_pins>;

	status = "okay";
};

&i2c0 {
	pinctrl-names = "default";
	pinctrl-0 = <&i2c0_pins>;

	status = "okay";
	clock-frequency = <400000>;

	tps: tps@2d {
		reg = <0x2d>;
	};
};

&usb {
	status = "okay";
};

&usb_ctrl_mod {
	status = "okay";
};

&usb1_phy {
	status = "okay";
};

&usb1 {
	status = "okay";
	dr_mode = "host";
};

&cppi41dma  {
	status = "okay";
};

&mmc1 {												// SD Card
	vmmc-supply = <&vmmc_reg>;
	bus-width = <4>;
	pinctrl-names = "default";
	pinctrl-0 = <&mmc1_pins>;
	broken-cd;
	status = "okay";
};

&mmc2 {												// MMC FLASH NAND
	vmmc-supply = <&vmmc_reg>;
	ti,non-removable;
	broken-cd;
	pinctrl-names = "default";
	pinctrl-0 = <&mmc2_pins>;
	bus-width = <8>;
	min-frequency = <26000000>;
	max-frequency = <52000000>;
	status = "okay";
};

/*
&sham {
	status = "okay";
};

&aes {
	status = "okay";
};

&gpio0 {
	ti,no-reset-on-init;
};

&gpio1 {
	ti,no-reset-on-init;
};

&gpio2 {
	ti,no-reset-on-init;
};
*/

#include "tps65910.dtsi"

&tps {
	vcc1-supply = <&vbat>;
	vcc2-supply = <&vbat>;
	vcc3-supply = <&vbat>;
	vcc4-supply = <&vbat>;
	vcc5-supply = <&vbat>;
	vcc6-supply = <&vbat>;
	vcc7-supply = <&vbat>;
	vccio-supply = <&vbat>;

	regulators {
		vrtc_reg: regulator@0 {
			regulator-always-on;
		};

		vio_reg: regulator@1 {
			regulator-always-on;
		};

		vdd1_reg: regulator@2 {
			/* VDD_MPU voltage limits 0.95V - 1.26V with +/-4% tolerance */
			regulator-name = "vdd_mpu";
			regulator-min-microvolt = <912500>;
			regulator-max-microvolt = <1312500>;
			regulator-boot-on;
			regulator-always-on;
		};

		vdd2_reg: regulator@3 {
			/* VDD_CORE voltage limits 0.95V - 1.1V with +/-4% tolerance */
			regulator-name = "vdd_core";
			regulator-min-microvolt = <912500>;
			regulator-max-microvolt = <1150000>;
			regulator-boot-on;
			regulator-always-on;
		};

		vdd3_reg: regulator@4 {
			regulator-always-on;
		};

		vdig2_reg: regulator@6 {
			regulator-always-on;
		};

		vpll_reg: regulator@7 {
			regulator-always-on;
		};

		vdac_reg: regulator@8 {
			regulator-always-on;
		};

		vaux1_reg: regulator@9 {
			regulator-always-on;
		};

		vaux2_reg: regulator@10 {
			regulator-always-on;
		};

		vaux33_reg: regulator@11 {
			regulator-always-on;
		};

		vmmc_reg: regulator@12 {
			regulator-always-on;
		};
	};
};


This is my mux.c (u-boot side) file (I reduced it) : 
#include <common.h>
#include <asm/arch/sys_proto.h>
#include <asm/arch/hardware.h>
#include <asm/arch/mux.h>
#include <asm/io.h>
#include <i2c.h>
#include "../common/board_detect.h"
#include "board.h"

static struct module_pin_mux mmc0_no_cd_pin_mux_myboard[] = {
	{OFFSET(mmc0_dat3), (MODE(0) | RXACTIVE | PULLUP_EN)},	/* MMC0_DAT3 */
	{OFFSET(mmc0_dat2), (MODE(0) | RXACTIVE | PULLUP_EN)},	/* MMC0_DAT2 */
	{OFFSET(mmc0_dat1), (MODE(0) | RXACTIVE | PULLUP_EN)},	/* MMC0_DAT1 */
	{OFFSET(mmc0_dat0), (MODE(0) | RXACTIVE | PULLUP_EN)},	/* MMC0_DAT0 */
	{OFFSET(mmc0_clk), (MODE(0) | RXACTIVE | PULLUP_EN)},	/* MMC0_CLK */
	{OFFSET(mmc0_cmd), (MODE(0) | RXACTIVE | PULLUP_EN)},	/* MMC0_CMD */
	{-1},
};

static struct module_pin_mux mmc0_pin_mux_sk_evm[] = {
	{OFFSET(mmc0_dat3), (MODE(0) | RXACTIVE | PULLUP_EN)},	/* MMC0_DAT3 */
	{OFFSET(mmc0_dat2), (MODE(0) | RXACTIVE | PULLUP_EN)},	/* MMC0_DAT2 */
	{OFFSET(mmc0_dat1), (MODE(0) | RXACTIVE | PULLUP_EN)},	/* MMC0_DAT1 */
	{OFFSET(mmc0_dat0), (MODE(0) | RXACTIVE | PULLUP_EN)},	/* MMC0_DAT0 */
	{OFFSET(mmc0_clk), (MODE(0) | RXACTIVE | PULLUP_EN)},	/* MMC0_CLK */
	{OFFSET(mmc0_cmd), (MODE(0) | RXACTIVE | PULLUP_EN)},	/* MMC0_CMD */
	{OFFSET(spi0_cs1), (MODE(5) | RXACTIVE | PULLUP_EN)},	/* MMC0_CD */
	{-1},
};

/*
 * The AM335x GP EVM, if daughter card(s) are connected, can have 8
 * different profiles.  These profiles determine what peripherals are
 * valid and need pinmux to be configured.
 */
#define PROFILE_NONE	0x0
#define PROFILE_0	(1 << 0)
#define PROFILE_1	(1 << 1)
#define PROFILE_2	(1 << 2)
#define PROFILE_3	(1 << 3)
#define PROFILE_4	(1 << 4)
#define PROFILE_5	(1 << 5)
#define PROFILE_6	(1 << 6)
#define PROFILE_7	(1 << 7)
#define PROFILE_MASK	0x7
#define PROFILE_ALL	0xFF

/* CPLD registers */
#define I2C_CPLD_ADDR	0x35
#define CFG_REG		0x10

static unsigned short detect_daughter_board_profile(void)
{
	unsigned short val;

	if (i2c_probe(I2C_CPLD_ADDR))
		return PROFILE_NONE;

	if (i2c_read(I2C_CPLD_ADDR, CFG_REG, 1, (unsigned char *)(&val), 2))
		return PROFILE_NONE;

	return (1 << (val & PROFILE_MASK));
}

void enable_board_pin_mux(void)
{
	/* Do board-specific muxes. */
	if (board_is_bone()) {
		/* Beaglebone pinmux */
		configure_module_pin_mux(mii1_pin_mux);
		configure_module_pin_mux(mmc0_pin_mux);
#if defined(CONFIG_NAND)
		configure_module_pin_mux(nand_pin_mux);
#elif defined(CONFIG_NOR)
		configure_module_pin_mux(bone_norcape_pin_mux);
#else
		configure_module_pin_mux(mmc1_pin_mux);
#endif
	} else if (board_is_evm_sk()) {
		/* Starter Kit EVM */
		configure_module_pin_mux(i2c1_pin_mux);
		configure_module_pin_mux(gpio0_7_pin_mux);
		configure_module_pin_mux(rgmii1_pin_mux);
		configure_module_pin_mux(mmc0_pin_mux_sk_evm);
	} else if (board_is_myboard()) {
		/* Myboard */
		configure_module_pin_mux(i2c1_pin_mux);
		configure_module_pin_mux(rgmii1_pin_mux);
		configure_module_pin_mux(mmc0_no_cd_pin_mux_myboard);
	} else {
		/* Unknown board. We might still be able to boot. */
		puts("Bad EEPROM or unknown board, cannot configure pinmux.");
	}
}

And this is kernel log: 

U-Boot 2017.01-gc3ca2d1a40 (Oct 11 2017 - 17:36:48 +0700)

CPU  : AM335X-GP rev 2.1
Model: MyBoardModel
DRAM:  256 MiB
NAND:  0 MiB
MMC:   OMAP SD/MMC: 0, OMAP SD/MMC: 1
reading uboot.env

** Unable to read "uboot.env" from mmc0:1 **
Using default environment

<ethaddr> not set. Validating first E-fuse MAC
Net:   Could not get PHY for cpsw: addr 0
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
Scanning mmc 0:1...
switch to partitions #0, OK
mmc0 is current device
SD/MMC found on device 0
3508576 bytes read in 472 ms (7.1 MiB/s)
35177 bytes read in 45 ms (762.7 KiB/s)
## Flattened Device Tree blob at 88000000
   Booting using the fdt blob at 0x88000000
   Loading Device Tree to 8df1c000, end 8df27968 ... OK

Starting kernel ...

[    0.000000] Booting Linux on physical CPU 0x0
[    0.000000] Linux version 4.9.49-gc2eed4ada2 (ildar@irsu) (gcc version 6.2.0 (GCC) ) #3 PREEMPT Wed Oct 11 18:02:11 +07 2017
[    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] OF: fdt:Machine model: MyBoardModel
[    0.000000] efi: Getting EFI parameters from FDT:
[    0.000000] efi: UEFI not found.
[    0.000000] cma: Reserved 48 MiB at 0x8a800000
[    0.000000] Memory policy: Data cache writeback
[    0.000000] CPU: All CPU(s) started in SVC mode.
[    0.000000] AM335X ES2.1 (neon)
[    0.000000] Built 1 zonelists in Zone order, mobility grouping on.  Total pages: 64960
[    0.000000] Kernel command line: console=ttyS1,115200n8 root=PARTUUID=571e4a82-02 rw rootfstype=ext4 rootwait
[    0.000000] PID hash table entries: 1024 (order: 0, 4096 bytes)
[    0.000000] Dentry cache hash table entries: 32768 (order: 5, 131072 bytes)
[    0.000000] Inode-cache hash table entries: 16384 (order: 4, 65536 bytes)
[    0.000000] Memory: 198344K/262144K available (7168K kernel code, 277K rwdata, 2340K rodata, 1024K init, 278K bss, 14648K reserved, 49152K cma-reserved, 0K highmem)
[    0.000000] Virtual kernel memory layout:
[    0.000000]     vector  : 0xffff0000 - 0xffff1000   (   4 kB)
[    0.000000]     fixmap  : 0xffc00000 - 0xfff00000   (3072 kB)
[    0.000000]     vmalloc : 0xd0800000 - 0xff800000   ( 752 MB)
[    0.000000]     lowmem  : 0xc0000000 - 0xd0000000   ( 256 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 - 0xc0c45570   ( 278 kB)
[    0.000000]        .bss : 0xc0c45570 - 0xc0c8b034   ( 279 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] IRQ: Found an INTC at 0xfa200000 (revision 5.0) with 128 interrupts
[    0.000000] OMAP clockevent source: timer2 at 24000000 Hz
[    0.000019] sched_clock: 32 bits at 24MHz, resolution 41ns, wraps every 89478484971ns
[    0.000044] clocksource: timer1: mask: 0xffffffff max_cycles: 0xffffffff, max_idle_ns: 79635851949 ns
[    0.000057] OMAP clocksource: timer1 at 24000000 Hz
[    0.000264] clocksource_probe: no matching clocksources found
[    0.000480] Console: colour dummy device 80x30
[    0.000530] Calibrating delay loop... 597.60 BogoMIPS (lpj=2988032)
[    0.118855] pid_max: default: 32768 minimum: 301
[    0.119022] Mount-cache hash table entries: 1024 (order: 0, 4096 bytes)
[    0.119038] Mountpoint-cache hash table entries: 1024 (order: 0, 4096 bytes)
[    0.120052] CPU: Testing write buffer coherency: ok
[    0.120505] Setting up static identity map for 0x80100000 - 0x80100060
[    0.121567] EFI services will not be available.
[    0.123356] devtmpfs: initialized
[    0.137744] VFP support v0.3: implementor 41 architecture 3 part 30 variant c rev 3
[    0.138230] clocksource: jiffies: mask: 0xffffffff max_cycles: 0xffffffff, max_idle_ns: 19112604462750000 ns
[    0.138263] futex hash table entries: 256 (order: -1, 3072 bytes)
[    0.142943] pinctrl core: initialized pinctrl subsystem
[    0.144584] NET: Registered protocol family 16
[    0.147104] DMA: preallocated 256 KiB pool for atomic coherent allocations
[    0.165814] omap_hwmod: debugss: _wait_target_disable failed
[    0.248864] cpuidle: using governor ladder
[    0.278849] cpuidle: using governor menu
[    0.286917] OMAP GPIO hardware version 0.1
[    0.304880] No ATAGs?
[    0.304912] hw-breakpoint: debug architecture 0x4 unsupported.
[    0.349821] edma 49000000.edma: TI EDMA DMA engine driver
[    0.350220] reg-fixed-voltage fixedregulator0: Fixed regulator specified with variable voltages
[    0.350266] reg-fixed-voltage: probe of fixedregulator0 failed with error -22
[    0.353641] omap_i2c 44e0b000.i2c: could not find pctldev for node /ocp/l4_wkup@44c00000/scm@210000/pinmux@800/pinmux_i2c0_pins, deferring probe
[    0.353790] media: Linux media interface: v0.10
[    0.353863] Linux video capture interface: v2.00
[    0.353916] pps_core: LinuxPPS API ver. 1 registered
[    0.353927] pps_core: Software ver. 5.3.6 - Copyright 2005-2007 Rodolfo Giometti <giometti@linux.it>
[    0.353966] PTP clock support registered
[    0.354019] EDAC MC: Ver: 3.0.0
[    0.355409] omap-mailbox 480c8000.mailbox: omap mailbox rev 0x400
[    0.357274] clocksource: Switched to clocksource timer1
[    0.371175] NET: Registered protocol family 2
[    0.372182] TCP established hash table entries: 2048 (order: 1, 8192 bytes)
[    0.372227] TCP bind hash table entries: 2048 (order: 1, 8192 bytes)
[    0.372264] TCP: Hash tables configured (established 2048 bind 2048)
[    0.372350] UDP hash table entries: 256 (order: 0, 4096 bytes)
[    0.372376] UDP-Lite hash table entries: 256 (order: 0, 4096 bytes)
[    0.372548] NET: Registered protocol family 1
[    0.373089] RPC: Registered named UNIX socket transport module.
[    0.373107] RPC: Registered udp transport module.
[    0.373116] RPC: Registered tcp transport module.
[    0.373124] RPC: Registered tcp NFSv4.1 backchannel transport module.
[    0.374235] hw perfevents: enabled with armv7_cortex_a8 PMU driver, 5 counters available
[    0.377240] workingset: timestamp_bits=14 max_order=16 bucket_order=2
[    0.388074] squashfs: version 4.0 (2009/01/31) Phillip Lougher
[    0.389277] NFS: Registering the id_resolver key type
[    0.389328] Key type id_resolver registered
[    0.389339] Key type id_legacy registered
[    0.389400] ntfs: driver 2.1.32 [Flags: R/O].
[    0.391805] Block layer SCSI generic (bsg) driver version 0.4 loaded (major 246)
[    0.391828] io scheduler noop registered
[    0.391838] io scheduler deadline registered
[    0.392031] io scheduler cfq registered (default)
[    0.393542] pinctrl-single 44e10800.pinmux: 142 pins at pa f9e10800 size 568
[    0.477810] Serial: 8250/16550 driver, 10 ports, IRQ sharing disabled
[    0.482685] console [ttyS1] disabled
[    0.482802] 48022000.serial: ttyS1 at MMIO 0x48022000 (irq = 158, base_baud = 3000000) is a 8250
[    1.055985] console [ttyS1] enabled
[    1.061607] omap_rng 48310000.rng: OMAP Random Number Generator ver. 20
[    1.068485] [drm] Initialized
[    1.089262] brd: module loaded
[    1.100973] loop: module loaded
[    1.106835] libphy: Fixed MDIO Bus: probed
[    1.113934] mousedev: PS/2 mouse device common for all mice
[    1.120261] i2c /dev entries driver
[    1.125907] cpuidle: enable-method property 'ti,am3352' found operations
[    1.136726] ledtrig-cpu: registered to indicate activity on CPUs
[    1.144352] NET: Registered protocol family 10
[    1.150451] sit: IPv6, IPv4 and MPLS over IPv4 tunneling driver
[    1.157630] NET: Registered protocol family 17
[    1.162437] Key type dns_resolver registered
[    1.166934] omap_voltage_late_init: Voltage driver support not added
[    1.207555] tps65910 0-002d: No interrupt support, no core IRQ
[    1.228662] random: fast init done
[    1.245017] omap_i2c 44e0b000.i2c: bus 0 rev0.11 at 400 kHz
[    1.255187] input: gpio_buttons0 as /devices/platform/gpio_buttons0/input/input0
[    1.266170] hctosys: unable to open rtc device (rtc0)
[    1.273082] Waiting for root device PARTUUID=571e4a82-02...

Connection of SD card:


I will be appreciate with any help!

Thank you!

 

UPD:

Also attach kernel config file:myboard-kernel-configs-fragments.cfg

And my pinmux file (in it I put only defines): myboard_am335x_pinmux.h