static int at91sam9x5ek_console_init(void) { at91_register_uart(0, 0); at91_register_uart(1, 0); at91_register_uart(2, 0); return 0; }
static void __init ek_board_init(void) { /* Serial */ /* DBGU on ttyS0. (Rx & Tx only) */ at91_register_uart(0, 0, 0); /* USART0 on ttyS1. (Rx, Tx, CTS, RTS, DTR, DSR, DCD, RI) */ at91_register_uart(AT91SAM9260_ID_US0, 1, ATMEL_UART_CTS | ATMEL_UART_RTS | ATMEL_UART_DTR | ATMEL_UART_DSR | ATMEL_UART_DCD | ATMEL_UART_RI); /* USART1 on ttyS2. (Rx, Tx, CTS, RTS) */ at91_register_uart(AT91SAM9260_ID_US1, 2, ATMEL_UART_CTS | ATMEL_UART_RTS); at91_add_device_serial(); /* USB Host */ at91_add_device_usbh(&ek_usbh_data); /* USB Device */ at91_add_device_udc(&ek_udc_data); /* SPI */ at91_add_device_spi(ek_spi_devices, ARRAY_SIZE(ek_spi_devices)); /* NAND */ ek_add_device_nand(); /* Ethernet */ at91_add_device_eth(&ek_macb_data); /* MMC */ at91_add_device_mci(0, &ek_mci0_data); /* I2C */ at91_add_device_i2c(NULL, 0); /* LEDs */ at91_gpio_leds(ek_leds, ARRAY_SIZE(ek_leds)); }
static void __init pcontrol_g20_board_init(void) { /* USART0 on ttyS1. (Rx, Tx, CTS, RTS) piggyback A2 */ at91_register_uart(AT91SAM9260_ID_US0, 1, ATMEL_UART_CTS | ATMEL_UART_RTS); /* USART1 on ttyS2. (Rx, Tx, CTS, RTS) isolated RS485 X5 */ at91_register_uart(AT91SAM9260_ID_US1, 2, ATMEL_UART_CTS | ATMEL_UART_RTS); /* USART2 on ttyS3. (Rx, Tx) 9bit-Bus Multidrop-mode X4 */ at91_register_uart(AT91SAM9260_ID_US4, 3, 0); stamp9g20_board_init(); at91_add_device_usbh(&usbh_data); at91_add_device_eth(&macb_data); at91_add_device_i2c(pcontrol_g20_i2c_devices, ARRAY_SIZE(pcontrol_g20_i2c_devices)); add_device_pcontrol(); at91_add_device_spi(pcontrol_g20_spi_devices, ARRAY_SIZE(pcontrol_g20_spi_devices)); at91_add_device_udc(&pcontrol_g20_udc_data); at91_gpio_leds(pcontrol_g20_leds, ARRAY_SIZE(pcontrol_g20_leds)); /* piggyback A2 */ at91_set_gpio_output(AT91_PIN_PB31, 1); }
static void __init ek_board_init(void) { /* Serial */ /* DBGU on ttyS0. (Rx & Tx only) */ at91_register_uart(0, 0, 0); /* USART0 on ttyS1. (Rx, Tx, CTS, RTS) */ at91_register_uart(AT91SAM9RL_ID_US0, 1, ATMEL_UART_CTS | ATMEL_UART_RTS); at91_add_device_serial(); /* USB HS */ at91_add_device_usba(&ek_usba_udc_data); /* I2C */ at91_add_device_i2c(NULL, 0); /* NAND */ ek_add_device_nand(); /* SPI */ at91_add_device_spi(ek_spi_devices, ARRAY_SIZE(ek_spi_devices)); /* MMC (AT91_MCI Legacy Driver */ at91_add_device_mmc(0, &at91_mci0_data); /* MMC */ at91_add_device_mci(0, &mci0_data); /* LCD Controller */ at91_add_device_lcdc(&ek_lcdc_data); /* AC97 */ at91_add_device_ac97(&ek_ac97_data); /* Touch Screen Controller */ at91_add_device_tsadcc(&ek_tsadcc_data); /* LEDs */ at91_gpio_leds(ek_leds, ARRAY_SIZE(ek_leds)); /* Push Buttons */ ek_add_device_buttons(); }
static void __init yl9200_init_early(void) { /* Set cpu type: PQFP */ at91rm9200_set_type(ARCH_REVISON_9200_PQFP); /* Initialize processor: 18.432 MHz crystal */ at91_initialize(18432000); /* Setup the LEDs D2=PB17 (timer), D3=PB16 (cpu) */ at91_init_leds(AT91_PIN_PB16, AT91_PIN_PB17); /* DBGU on ttyS0. (Rx & Tx only) */ at91_register_uart(0, 0, 0); /* USART1 on ttyS1. (Rx, Tx, CTS, RTS, DTR, DSR, DCD, RI) */ at91_register_uart(AT91RM9200_ID_US1, 1, ATMEL_UART_CTS | ATMEL_UART_RTS | ATMEL_UART_DTR | ATMEL_UART_DSR | ATMEL_UART_DCD | ATMEL_UART_RI); /* USART0 on ttyS2. (Rx & Tx only to JP3) */ at91_register_uart(AT91RM9200_ID_US0, 2, 0); /* USART3 on ttyS3. (Rx, Tx, RTS - RS485 interface) */ at91_register_uart(AT91RM9200_ID_US3, 3, ATMEL_UART_RTS); /* set serial console to ttyS0 (ie, DBGU) */ at91_set_serial_console(0); }
static void __init cpuat91_map_io(void) { at91rm9200_initialize(18432000, AT91RM9200_PQFP); at91_register_uart(0, 0, 0); at91_register_uart(AT91RM9200_ID_US0, 1, ATMEL_UART_CTS | ATMEL_UART_RTS); at91_register_uart(AT91RM9200_ID_US1, 2, ATMEL_UART_CTS | ATMEL_UART_RTS | ATMEL_UART_DTR | ATMEL_UART_DSR | ATMEL_UART_DCD | ATMEL_UART_RI); at91_register_uart(AT91RM9200_ID_US2, 3, 0); at91_register_uart(AT91RM9200_ID_US3, 4, ATMEL_UART_CTS | ATMEL_UART_RTS); at91_set_serial_console(0); }
static void __init cpuat91_init_early(void) { /* Set cpu type: PQFP */ at91rm9200_set_type(ARCH_REVISON_9200_PQFP); /* Initialize processor: 18.432 MHz crystal */ at91_initialize(18432000); /* DBGU on ttyS0. (Rx & Tx only) */ at91_register_uart(0, 0, 0); /* USART0 on ttyS1. (Rx, Tx, CTS, RTS) */ at91_register_uart(AT91RM9200_ID_US0, 1, ATMEL_UART_CTS | ATMEL_UART_RTS); /* USART1 on ttyS2. (Rx, Tx, CTS, RTS, DTR, DSR, DCD, RI) */ at91_register_uart(AT91RM9200_ID_US1, 2, ATMEL_UART_CTS | ATMEL_UART_RTS | ATMEL_UART_DTR | ATMEL_UART_DSR | ATMEL_UART_DCD | ATMEL_UART_RI); /* USART2 on ttyS3 (Rx, Tx) */ at91_register_uart(AT91RM9200_ID_US2, 3, 0); /* USART3 on ttyS4 (Rx, Tx, CTS, RTS) */ at91_register_uart(AT91RM9200_ID_US3, 4, ATMEL_UART_CTS | ATMEL_UART_RTS); /* set serial console to ttyS0 (ie, DBGU) */ at91_set_serial_console(0); }
static void __init carmeva_board_init(void) { /* Serial */ /* DBGU on ttyS0. (Rx & Tx only) */ at91_register_uart(0, 0, 0); /* USART1 on ttyS1. (Rx, Tx, CTS, RTS, DTR, DSR, DCD, RI) */ at91_register_uart(AT91RM9200_ID_US1, 1, ATMEL_UART_CTS | ATMEL_UART_RTS | ATMEL_UART_DTR | ATMEL_UART_DSR | ATMEL_UART_DCD | ATMEL_UART_RI); at91_add_device_serial(); /* Ethernet */ at91_add_device_eth(&carmeva_eth_data); /* USB Host */ at91_add_device_usbh(&carmeva_usbh_data); /* USB Device */ at91_add_device_udc(&carmeva_udc_data); /* I2C */ at91_add_device_i2c(NULL, 0); /* SPI */ at91_add_device_spi(carmeva_spi_devices, ARRAY_SIZE(carmeva_spi_devices)); /* Compact Flash */ // at91_add_device_cf(&carmeva_cf_data); /* MMC */ at91_add_device_mmc(0, &carmeva_mmc_data); /* LEDs */ at91_gpio_leds(carmeva_leds, ARRAY_SIZE(carmeva_leds)); }
static void __init kb9202_init_early(void) { at91rm9200_set_type(ARCH_REVISON_9200_PQFP); at91_initialize(10000000); at91_init_leds(AT91_PIN_PC19, AT91_PIN_PC18); at91_register_uart(0, 0, 0); at91_register_uart(AT91RM9200_ID_US0, 1, 0); at91_register_uart(AT91RM9200_ID_US1, 2, 0); at91_register_uart(AT91RM9200_ID_US3, 3, ATMEL_UART_CTS | ATMEL_UART_RTS); at91_set_serial_console(0); }
static void __init ecb_at91board_init(void) { /* Serial */ /* DBGU on ttyS0. (Rx & Tx only) */ at91_register_uart(0, 0, 0); /* USART0 on ttyS1. (Rx & Tx only) */ at91_register_uart(AT91RM9200_ID_US0, 1, 0); at91_add_device_serial(); /* Ethernet */ at91_add_device_eth(&ecb_at91eth_data); /* USB Host */ at91_add_device_usbh(&ecb_at91usbh_data); /* I2C */ at91_add_device_i2c(NULL, 0); /* MMC */ at91_add_device_mci(0, &ecbat91_mci0_data); /* SPI */ at91_add_device_spi(ecb_at91spi_devices, ARRAY_SIZE(ecb_at91spi_devices)); /* LEDs */ at91_gpio_leds(ecb_leds, ARRAY_SIZE(ecb_leds)); }
static void __init ek_map_io(void) { /* Initialize processor: 18.432 MHz crystal */ at91sam9260_initialize(18432000); /* DGBU on ttyS0. (Rx & Tx only) */ at91_register_uart(0, 0, 0); #if defined(CONFIG_NETUS_SERIALS) || defined(CONFIG_NETUS_FOXGM) /* USART0 on ttyS1. (Rx, Tx, CTS, RTS, DTR, DSR, DCD, RI) */ at91_register_uart(AT91SAM9260_ID_US0, 1, ATMEL_UART_CTS | ATMEL_UART_RTS | ATMEL_UART_DTR | ATMEL_UART_DSR | ATMEL_UART_DCD | ATMEL_UART_RI); /* USART1 on ttyS2. (Rx, Tx, RTS, CTS) */ at91_register_uart(AT91SAM9260_ID_US1, 2, ATMEL_UART_CTS | ATMEL_UART_RTS); #endif #if defined(CONFIG_NETUS_SERIALS) /* USART2 on ttyS3. (Rx, Tx) */ at91_register_uart(AT91SAM9260_ID_US2, 3, 0); #endif /* set serial console to ttyS0 (ie, DBGU) */ at91_set_serial_console(0); }
static void __init kb9202_board_init(void) { /* Serial */ /* DBGU on ttyS0. (Rx & Tx only) */ at91_register_uart(0, 0, 0); /* USART0 on ttyS1 (Rx & Tx only) */ at91_register_uart(AT91RM9200_ID_US0, 1, 0); /* USART1 on ttyS2 (Rx & Tx only) - IRDA (optional) */ at91_register_uart(AT91RM9200_ID_US1, 2, 0); /* USART3 on ttyS3 (Rx, Tx, CTS, RTS) - RS485 (optional) */ at91_register_uart(AT91RM9200_ID_US3, 3, ATMEL_UART_CTS | ATMEL_UART_RTS); at91_add_device_serial(); /* Ethernet */ at91_add_device_eth(&kb9202_eth_data); /* USB Host */ at91_add_device_usbh(&kb9202_usbh_data); /* USB Device */ at91_add_device_udc(&kb9202_udc_data); /* MMC */ at91_add_device_mci(0, &kb9202_mci0_data); /* I2C */ at91_add_device_i2c(NULL, 0); /* SPI */ at91_add_device_spi(NULL, 0); /* NAND */ at91_add_device_nand(&kb9202_nand_data); /* LEDs */ at91_gpio_leds(kb9202_leds, ARRAY_SIZE(kb9202_leds)); }
static int usb_a9260_console_init(void) { struct device_d *dev; if (machine_is_usb_a9260()) { barebox_set_model("Calao USB-A9260"); barebox_set_hostname("usb-a9260"); } else if (machine_is_usb_a9g20()) { barebox_set_model("Calao USB-A9G20"); barebox_set_hostname("usb-a9g20"); } else { barebox_set_model("Calao USB-A9263"); barebox_set_hostname("usb-a9263"); } at91_register_uart(0, 0); if (IS_ENABLED(CONFIG_CALAO_DAB_MMX)) { at91_register_uart(2, 0); dev = at91_register_uart(4, 0); dev_set_param(dev, "active", ""); } return 0; }
static void __init rsi_ews_init_early(void) { /* */ at91_initialize(18432000); /* */ at91_init_leds(AT91_PIN_PB6, AT91_PIN_PB9); /* */ /* */ at91_register_uart(0, 0, 0); /* */ /* */ at91_register_uart(AT91RM9200_ID_US1, 2, ATMEL_UART_CTS | ATMEL_UART_RTS | ATMEL_UART_DTR | ATMEL_UART_DSR | ATMEL_UART_DCD | ATMEL_UART_RI); /* */ /* */ at91_register_uart(AT91RM9200_ID_US3, 4, ATMEL_UART_RTS); /* */ at91_set_serial_console(0); }
static void __init rsi_ews_init_early(void) { /* Initialize processor: 18.432 MHz crystal */ at91_initialize(18432000); /* Setup the LEDs */ at91_init_leds(AT91_PIN_PB6, AT91_PIN_PB9); /* DBGU on ttyS0. (Rx & Tx only) */ /* This one is for debugging */ at91_register_uart(0, 0, 0); /* USART1 on ttyS2. (Rx, Tx, CTS, RTS, DTR, DSR, DCD, RI) */ /* Dialin/-out modem interface */ at91_register_uart(AT91RM9200_ID_US1, 2, ATMEL_UART_CTS | ATMEL_UART_RTS | ATMEL_UART_DTR | ATMEL_UART_DSR | ATMEL_UART_DCD | ATMEL_UART_RI); /* USART3 on ttyS4. (Rx, Tx, RTS) */ /* RS485 communication */ at91_register_uart(AT91RM9200_ID_US3, 4, ATMEL_UART_RTS); /* set serial console to ttyS0 (ie, DBGU) */ at91_set_serial_console(0); }
static int tny_a9260_console_init(void) { at91_register_uart(0, 0); if (IS_ENABLED(CONFIG_CALAO_MOB_TNY_MD2)) at91_register_uart(2, ATMEL_UART_CTS | ATMEL_UART_RTS); return 0; }
static int at91sam9x5ek_console_init(void) { barebox_set_model("Atmel at91sam9x5-ek"); barebox_set_hostname("at91sam9x5-ek"); at91_register_uart(0, 0); at91_register_uart(1, 0); return 0; }
static void __init ek_init_early(void) { at91_initialize(16367660); at91_register_uart(0, 0, 0); at91_register_uart(AT91SAM9263_ID_US0, 1, ATMEL_UART_CTS | ATMEL_UART_RTS); at91_set_serial_console(0); }
static void __init neocore926_map_io(void) { /* Initialize processor: 20 MHz crystal */ at91sam9263_initialize(20000000); /* DBGU on ttyS0. (Rx & Tx only) */ at91_register_uart(0, 0, 0); /* USART0 on ttyS1. (Rx, Tx, RTS, CTS) */ at91_register_uart(AT91SAM9263_ID_US0, 1, ATMEL_UART_CTS | ATMEL_UART_RTS); /* set serial console to ttyS0 (ie, DBGU) */ at91_set_serial_console(0); }
static void __init ek_init_early(void) { /* Initialize processor: 16.367 MHz crystal */ at91_initialize(16367660); /* DBGU on ttyS0. (Rx & Tx only) */ at91_register_uart(0, 0, 0); /* USART0 on ttyS1. (Rx, Tx, RTS, CTS) */ at91_register_uart(AT91SAM9263_ID_US0, 1, ATMEL_UART_CTS | ATMEL_UART_RTS); /* set serial console to ttyS0 (ie, DBGU) */ at91_set_serial_console(0); }
static void __init ek_map_io(void) { /* Initialize processor: 12.000 MHz crystal */ at91sam9rl_initialize(12000000); /* DGBU on ttyS0. (Rx & Tx only) */ at91_register_uart(0, 0, 0); /* USART0 on ttyS1. (Rx, Tx, CTS, RTS) */ at91_register_uart(AT91SAM9RL_ID_US0, 1, ATMEL_UART_CTS | ATMEL_UART_RTS); /* set serial console to ttyS0 (ie, DBGU) */ at91_set_serial_console(0); }
static void __init snapper9260_init_early(void) { at91_initialize(18432000); /* Debug on ttyS0 */ at91_register_uart(0, 0, 0); at91_set_serial_console(0); at91_register_uart(AT91SAM9260_ID_US0, 1, ATMEL_UART_CTS | ATMEL_UART_RTS); at91_register_uart(AT91SAM9260_ID_US1, 2, ATMEL_UART_CTS | ATMEL_UART_RTS); at91_register_uart(AT91SAM9260_ID_US2, 3, 0); }
static int usb_a9260_console_init(void) { struct device_d *dev; at91_register_uart(0, 0); if (IS_ENABLED(CONFIG_CALAO_DAB_MMX)) { at91_register_uart(2, 0); dev = at91_register_uart(4, 0); dev_set_param(dev, "active", ""); } return 0; }
static void __init ek_map_io(void) { /* Initialize processor: 12.000 MHz crystal */ at91sam9g45_initialize(12000000); /* DGBU on ttyS0. (Rx & Tx only) */ at91_register_uart(0, 0, 0); /* USART0 not connected on the -EK board */ /* USART1 on ttyS2. (Rx, Tx, RTS, CTS) */ at91_register_uart(AT91SAM9G45_ID_US1, 2, ATMEL_UART_CTS | ATMEL_UART_RTS); /* set serial console to ttyS0 (ie, DBGU) */ at91_set_serial_console(0); }
static void __init ek_init_early(void) { /* */ at91_initialize(12000000); /* */ at91_register_uart(0, 0, 0); /* */ /* */ at91_register_uart(AT91SAM9G45_ID_US1, 2, ATMEL_UART_CTS | ATMEL_UART_RTS); /* */ at91_set_serial_console(0); }
static void __init pcontrol_g20_init_early(void) { stamp9g20_init_early(); /* USART0 on ttyS1. (Rx, Tx, CTS, RTS) piggyback A2 */ at91_register_uart(AT91SAM9260_ID_US0, 1, ATMEL_UART_CTS | ATMEL_UART_RTS); /* USART1 on ttyS2. (Rx, Tx, CTS, RTS) isolated RS485 X5 */ at91_register_uart(AT91SAM9260_ID_US1, 2, ATMEL_UART_CTS | ATMEL_UART_RTS); /* USART2 on ttyS3. (Rx, Tx) 9bit-Bus Multidrop-mode X4 */ at91_register_uart(AT91SAM9260_ID_US4, 3, 0); }
static void __init carmeva_init_early(void) { /* */ at91_initialize(20000000); /* */ at91_register_uart(0, 0, 0); /* */ at91_register_uart(AT91RM9200_ID_US1, 1, ATMEL_UART_CTS | ATMEL_UART_RTS | ATMEL_UART_DTR | ATMEL_UART_DSR | ATMEL_UART_DCD | ATMEL_UART_RI); /* */ at91_set_serial_console(0); }
static void __init ek_board_init(void) { /* Serial */ /* DBGU on ttyS0. (Rx & Tx only) */ at91_register_uart(0, 0, 0); at91_add_device_serial(); /* USB Host */ at91_add_device_usbh(&ek_usbh_data); /* USB Device */ ek_add_device_udc(); /* SPI */ ek_add_device_spi(); /* Ethernet */ ek_add_device_eth(); /* NAND */ ek_add_device_nand(); /* Push Buttons */ ek_add_device_buttons(); /* LEDs */ ek_add_device_leds(); if (machine_is_usb_a9g20()) { /* I2C */ at91_add_device_i2c(ek_i2c_devices, ARRAY_SIZE(ek_i2c_devices)); } else { /* I2C */ at91_add_device_i2c(NULL, 0); /* shutdown controller, wakeup button (5 msec low) */ at91_shdwc_write(AT91_SHDW_MR, AT91_SHDW_CPTWK0_(10) | AT91_SHDW_WKMODE0_LOW | AT91_SHDW_RTTWKEN); } }
static void __init carmeva_init_early(void) { /* Initialize processor: 20.000 MHz crystal */ at91_initialize(20000000); /* DBGU on ttyS0. (Rx & Tx only) */ at91_register_uart(0, 0, 0); /* USART1 on ttyS1. (Rx, Tx, CTS, RTS, DTR, DSR, DCD, RI) */ at91_register_uart(AT91RM9200_ID_US1, 1, ATMEL_UART_CTS | ATMEL_UART_RTS | ATMEL_UART_DTR | ATMEL_UART_DSR | ATMEL_UART_DCD | ATMEL_UART_RI); /* set serial console to ttyS0 (ie, DBGU) */ at91_set_serial_console(0); }
static void __init csb337_board_init(void) { /* Serial */ /* DBGU on ttyS0 */ at91_register_uart(0, 0, 0); at91_add_device_serial(); /* Ethernet */ at91_add_device_eth(&csb337_eth_data); /* USB Host */ at91_add_device_usbh(&csb337_usbh_data); /* USB Device */ at91_add_device_udc(&csb337_udc_data); /* I2C */ at91_add_device_i2c(csb337_i2c_devices, ARRAY_SIZE(csb337_i2c_devices)); /* Compact Flash */ at91_set_gpio_input(AT91_PIN_PB22, 1); /* IOIS16 */ at91_add_device_cf(&csb337_cf_data); /* SPI */ at91_add_device_spi(csb337_spi_devices, ARRAY_SIZE(csb337_spi_devices)); /* MMC */ at91_add_device_mci(0, &csb337_mci0_data); /* NOR flash */ platform_device_register(&csb_flash); /* LEDs */ at91_gpio_leds(csb_leds, ARRAY_SIZE(csb_leds)); /* Switches on CSB300 */ csb300_add_device_buttons(); }