mirror of
https://github.com/Fishwaldo/u-boot.git
synced 2025-03-21 14:41:31 +00:00
Merge branch 'master' of http://git.denx.de/u-boot-sunxi
This commit is contained in:
commit
37f4d0ec34
9 changed files with 183 additions and 7 deletions
|
@ -45,11 +45,11 @@ static int gpio_init(void)
|
||||||
sunxi_gpio_set_cfgpin(SUNXI_GPB(23), SUNXI_GPIO_INPUT);
|
sunxi_gpio_set_cfgpin(SUNXI_GPB(23), SUNXI_GPIO_INPUT);
|
||||||
#endif
|
#endif
|
||||||
#if defined(CONFIG_MACH_SUN8I)
|
#if defined(CONFIG_MACH_SUN8I)
|
||||||
sunxi_gpio_set_cfgpin(SUNXI_GPF(2), SUN8I_GPF_UART0_TX);
|
sunxi_gpio_set_cfgpin(SUNXI_GPF(2), SUN8I_GPF_UART0);
|
||||||
sunxi_gpio_set_cfgpin(SUNXI_GPF(4), SUN8I_GPF_UART0_RX);
|
sunxi_gpio_set_cfgpin(SUNXI_GPF(4), SUN8I_GPF_UART0);
|
||||||
#else
|
#else
|
||||||
sunxi_gpio_set_cfgpin(SUNXI_GPF(2), SUNXI_GPF_UART0_TX);
|
sunxi_gpio_set_cfgpin(SUNXI_GPF(2), SUNXI_GPF_UART0);
|
||||||
sunxi_gpio_set_cfgpin(SUNXI_GPF(4), SUNXI_GPF_UART0_RX);
|
sunxi_gpio_set_cfgpin(SUNXI_GPF(4), SUNXI_GPF_UART0);
|
||||||
#endif
|
#endif
|
||||||
sunxi_gpio_set_pull(SUNXI_GPF(4), 1);
|
sunxi_gpio_set_pull(SUNXI_GPF(4), 1);
|
||||||
#elif CONFIG_CONS_INDEX == 1 && (defined(CONFIG_MACH_SUN4I) || defined(CONFIG_MACH_SUN7I))
|
#elif CONFIG_CONS_INDEX == 1 && (defined(CONFIG_MACH_SUN4I) || defined(CONFIG_MACH_SUN7I))
|
||||||
|
@ -64,6 +64,10 @@ static int gpio_init(void)
|
||||||
sunxi_gpio_set_cfgpin(SUNXI_GPH(20), SUN6I_GPH_UART0);
|
sunxi_gpio_set_cfgpin(SUNXI_GPH(20), SUN6I_GPH_UART0);
|
||||||
sunxi_gpio_set_cfgpin(SUNXI_GPH(21), SUN6I_GPH_UART0);
|
sunxi_gpio_set_cfgpin(SUNXI_GPH(21), SUN6I_GPH_UART0);
|
||||||
sunxi_gpio_set_pull(SUNXI_GPH(21), SUNXI_GPIO_PULL_UP);
|
sunxi_gpio_set_pull(SUNXI_GPH(21), SUNXI_GPIO_PULL_UP);
|
||||||
|
#elif CONFIG_CONS_INDEX == 1 && defined(CONFIG_MACH_SUN8I_A33)
|
||||||
|
sunxi_gpio_set_cfgpin(SUNXI_GPB(0), SUN8I_A33_GPB_UART0);
|
||||||
|
sunxi_gpio_set_cfgpin(SUNXI_GPB(1), SUN8I_A33_GPB_UART0);
|
||||||
|
sunxi_gpio_set_pull(SUNXI_GPB(1), SUNXI_GPIO_PULL_UP);
|
||||||
#elif CONFIG_CONS_INDEX == 1 && defined(CONFIG_MACH_SUN9I)
|
#elif CONFIG_CONS_INDEX == 1 && defined(CONFIG_MACH_SUN9I)
|
||||||
sunxi_gpio_set_cfgpin(SUNXI_GPH(12), SUN9I_GPH_UART0);
|
sunxi_gpio_set_cfgpin(SUNXI_GPH(12), SUN9I_GPH_UART0);
|
||||||
sunxi_gpio_set_cfgpin(SUNXI_GPH(13), SUN9I_GPH_UART0);
|
sunxi_gpio_set_cfgpin(SUNXI_GPH(13), SUN9I_GPH_UART0);
|
||||||
|
|
|
@ -60,11 +60,12 @@ int rsb_init(void)
|
||||||
struct sunxi_rsb_reg * const rsb =
|
struct sunxi_rsb_reg * const rsb =
|
||||||
(struct sunxi_rsb_reg *)SUNXI_RSB_BASE;
|
(struct sunxi_rsb_reg *)SUNXI_RSB_BASE;
|
||||||
|
|
||||||
rsb_cfg_io();
|
|
||||||
|
|
||||||
/* Enable RSB and PIO clk, and de-assert their resets */
|
/* Enable RSB and PIO clk, and de-assert their resets */
|
||||||
prcm_apb0_enable(PRCM_APB0_GATE_PIO | PRCM_APB0_GATE_RSB);
|
prcm_apb0_enable(PRCM_APB0_GATE_PIO | PRCM_APB0_GATE_RSB);
|
||||||
|
|
||||||
|
/* Setup external pins */
|
||||||
|
rsb_cfg_io();
|
||||||
|
|
||||||
writel(RSB_CTRL_SOFT_RST, &rsb->ctrl);
|
writel(RSB_CTRL_SOFT_RST, &rsb->ctrl);
|
||||||
rsb_set_clk();
|
rsb_set_clk();
|
||||||
|
|
||||||
|
|
|
@ -128,7 +128,8 @@ dtb-$(CONFIG_MACH_SUN8I_A23) += \
|
||||||
dtb-$(CONFIG_MACH_SUN8I_A33) += \
|
dtb-$(CONFIG_MACH_SUN8I_A33) += \
|
||||||
sun8i-a33-et-q8-v1.6.dtb \
|
sun8i-a33-et-q8-v1.6.dtb \
|
||||||
sun8i-a33-ga10h-v1.1.dtb \
|
sun8i-a33-ga10h-v1.1.dtb \
|
||||||
sun8i-a33-ippo-q8h-v1.2-lcd1024x600.dtb
|
sun8i-a33-ippo-q8h-v1.2-lcd1024x600.dtb \
|
||||||
|
sun8i-a33-sinlinx-sina33.dtb
|
||||||
dtb-$(CONFIG_MACH_SUN9I) += \
|
dtb-$(CONFIG_MACH_SUN9I) += \
|
||||||
sun9i-a80-optimus.dtb \
|
sun9i-a80-optimus.dtb \
|
||||||
sun9i-a80-cubieboard4.dtb
|
sun9i-a80-cubieboard4.dtb
|
||||||
|
|
|
@ -366,6 +366,16 @@
|
||||||
allwinner,pull = <SUN4I_PINCTRL_NO_PULL>;
|
allwinner,pull = <SUN4I_PINCTRL_NO_PULL>;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
mmc2_8bit_pins: mmc2_8bit {
|
||||||
|
allwinner,pins = "PC5", "PC6", "PC8",
|
||||||
|
"PC9", "PC10", "PC11",
|
||||||
|
"PC12", "PC13", "PC14",
|
||||||
|
"PC15";
|
||||||
|
allwinner,function = "mmc2";
|
||||||
|
allwinner,drive = <SUN4I_PINCTRL_30_MA>;
|
||||||
|
allwinner,pull = <SUN4I_PINCTRL_NO_PULL>;
|
||||||
|
};
|
||||||
|
|
||||||
i2c0_pins_a: i2c0@0 {
|
i2c0_pins_a: i2c0@0 {
|
||||||
allwinner,pins = "PH2", "PH3";
|
allwinner,pins = "PH2", "PH3";
|
||||||
allwinner,function = "i2c0";
|
allwinner,function = "i2c0";
|
||||||
|
|
129
arch/arm/dts/sun8i-a33-sinlinx-sina33.dts
Normal file
129
arch/arm/dts/sun8i-a33-sinlinx-sina33.dts
Normal file
|
@ -0,0 +1,129 @@
|
||||||
|
/*
|
||||||
|
* Copyright 2015 Chen-Yu Tsai
|
||||||
|
*
|
||||||
|
* Chen-Yu Tsai <wens@csie.org>
|
||||||
|
*
|
||||||
|
* This file is dual-licensed: you can use it either under the terms
|
||||||
|
* of the GPL or the X11 license, at your option. Note that this dual
|
||||||
|
* licensing only applies to this file, and not this project as a
|
||||||
|
* whole.
|
||||||
|
*
|
||||||
|
* a) This file is free software; you can redistribute it and/or
|
||||||
|
* modify it under the terms of the GNU General Public License as
|
||||||
|
* published by the Free Software Foundation; either version 2 of the
|
||||||
|
* License, or (at your option) any later version.
|
||||||
|
*
|
||||||
|
* This file is distributed in the hope that it will be useful,
|
||||||
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
|
* GNU General Public License for more details.
|
||||||
|
*
|
||||||
|
* Or, alternatively,
|
||||||
|
*
|
||||||
|
* b) Permission is hereby granted, free of charge, to any person
|
||||||
|
* obtaining a copy of this software and associated documentation
|
||||||
|
* files (the "Software"), to deal in the Software without
|
||||||
|
* restriction, including without limitation the rights to use,
|
||||||
|
* copy, modify, merge, publish, distribute, sublicense, and/or
|
||||||
|
* sell copies of the Software, and to permit persons to whom the
|
||||||
|
* Software is furnished to do so, subject to the following
|
||||||
|
* conditions:
|
||||||
|
*
|
||||||
|
* The above copyright notice and this permission notice shall be
|
||||||
|
* included in all copies or substantial portions of the Software.
|
||||||
|
*
|
||||||
|
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
|
||||||
|
* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
|
||||||
|
* OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
|
||||||
|
* NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
|
||||||
|
* HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
|
||||||
|
* WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
|
||||||
|
* FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
|
||||||
|
* OTHER DEALINGS IN THE SOFTWARE.
|
||||||
|
*/
|
||||||
|
|
||||||
|
/dts-v1/;
|
||||||
|
#include "sun8i-a33.dtsi"
|
||||||
|
#include "sunxi-common-regulators.dtsi"
|
||||||
|
|
||||||
|
#include <dt-bindings/gpio/gpio.h>
|
||||||
|
#include <dt-bindings/input/input.h>
|
||||||
|
#include <dt-bindings/pinctrl/sun4i-a10.h>
|
||||||
|
|
||||||
|
/ {
|
||||||
|
model = "Sinlinx SinA33";
|
||||||
|
compatible = "sinlinx,sina33", "allwinner,sun8i-a33";
|
||||||
|
|
||||||
|
aliases {
|
||||||
|
serial0 = &uart0;
|
||||||
|
};
|
||||||
|
|
||||||
|
chosen {
|
||||||
|
stdout-path = "serial0:115200n8";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
&lradc {
|
||||||
|
vref-supply = <®_vcc3v0>;
|
||||||
|
status = "okay";
|
||||||
|
|
||||||
|
button@200 {
|
||||||
|
label = "Volume Up";
|
||||||
|
linux,code = <KEY_VOLUMEUP>;
|
||||||
|
channel = <0>;
|
||||||
|
voltage = <191011>;
|
||||||
|
};
|
||||||
|
|
||||||
|
button@400 {
|
||||||
|
label = "Volume Down";
|
||||||
|
linux,code = <KEY_VOLUMEDOWN>;
|
||||||
|
channel = <0>;
|
||||||
|
voltage = <391304>;
|
||||||
|
};
|
||||||
|
|
||||||
|
button@600 {
|
||||||
|
label = "Home";
|
||||||
|
linux,code = <KEY_HOME>;
|
||||||
|
channel = <0>;
|
||||||
|
voltage = <600000>;
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
&mmc0 {
|
||||||
|
pinctrl-names = "default";
|
||||||
|
pinctrl-0 = <&mmc0_pins_a>, <&mmc0_cd_pin_sina33>;
|
||||||
|
vmmc-supply = <®_vcc3v0>;
|
||||||
|
bus-width = <4>;
|
||||||
|
cd-gpios = <&pio 1 4 GPIO_ACTIVE_HIGH>; /* PB4 */
|
||||||
|
cd-inverted;
|
||||||
|
status = "okay";
|
||||||
|
};
|
||||||
|
|
||||||
|
&mmc2 {
|
||||||
|
pinctrl-names = "default";
|
||||||
|
pinctrl-0 = <&mmc2_8bit_pins>;
|
||||||
|
vmmc-supply = <®_vcc3v0>;
|
||||||
|
bus-width = <8>;
|
||||||
|
non-removable;
|
||||||
|
status = "okay";
|
||||||
|
};
|
||||||
|
|
||||||
|
&mmc2_8bit_pins {
|
||||||
|
/* eMMC is missing pull-ups */
|
||||||
|
allwinner,pull = <SUN4I_PINCTRL_PULL_UP>;
|
||||||
|
};
|
||||||
|
|
||||||
|
&pio {
|
||||||
|
mmc0_cd_pin_sina33: mmc0_cd_pin@0 {
|
||||||
|
allwinner,pins = "PB4";
|
||||||
|
allwinner,function = "gpio_in";
|
||||||
|
allwinner,drive = <SUN4I_PINCTRL_10_MA>;
|
||||||
|
allwinner,pull = <SUN4I_PINCTRL_PULL_UP>;
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
&uart0 {
|
||||||
|
pinctrl-names = "default";
|
||||||
|
pinctrl-0 = <&uart0_pins_b>;
|
||||||
|
status = "okay";
|
||||||
|
};
|
|
@ -86,4 +86,12 @@
|
||||||
compatible = "allwinner,sun8i-a33-pinctrl";
|
compatible = "allwinner,sun8i-a33-pinctrl";
|
||||||
interrupts = <GIC_SPI 15 IRQ_TYPE_LEVEL_HIGH>,
|
interrupts = <GIC_SPI 15 IRQ_TYPE_LEVEL_HIGH>,
|
||||||
<GIC_SPI 17 IRQ_TYPE_LEVEL_HIGH>;
|
<GIC_SPI 17 IRQ_TYPE_LEVEL_HIGH>;
|
||||||
|
|
||||||
|
uart0_pins_b: uart0@1 {
|
||||||
|
allwinner,pins = "PB0", "PB1";
|
||||||
|
allwinner,function = "uart0";
|
||||||
|
allwinner,drive = <SUN4I_PINCTRL_10_MA>;
|
||||||
|
allwinner,pull = <SUN4I_PINCTRL_NO_PULL>;
|
||||||
|
};
|
||||||
|
|
||||||
};
|
};
|
||||||
|
|
|
@ -156,6 +156,7 @@ enum sunxi_gpio_number {
|
||||||
#define SUN4I_GPB_UART0 2
|
#define SUN4I_GPB_UART0 2
|
||||||
#define SUN5I_GPB_UART0 2
|
#define SUN5I_GPB_UART0 2
|
||||||
#define SUN8I_GPB_UART2 2
|
#define SUN8I_GPB_UART2 2
|
||||||
|
#define SUN8I_A33_GPB_UART0 3
|
||||||
|
|
||||||
#define SUNXI_GPC_SDC2 3
|
#define SUNXI_GPC_SDC2 3
|
||||||
#define SUN6I_GPC_SDC3 4
|
#define SUN6I_GPC_SDC3 4
|
||||||
|
|
|
@ -162,6 +162,12 @@ M: Siarhei Siamashka <siarhei.siamashka@gmail.com>
|
||||||
S: Maintained
|
S: Maintained
|
||||||
F: configs/MSI_Primo81_defconfig
|
F: configs/MSI_Primo81_defconfig
|
||||||
|
|
||||||
|
SINLINX SINA33 BOARD
|
||||||
|
M: Chen-Yu Tsai <wens@csie.org>
|
||||||
|
S: Maintained
|
||||||
|
F: configs/Sinlinx_SinA33_defconfig
|
||||||
|
W: http://linux-sunxi.org/Sinlinx_SinA33
|
||||||
|
|
||||||
TZX-Q8-713B7 BOARD
|
TZX-Q8-713B7 BOARD
|
||||||
M: Paul Kocialkowski <contact@paulk.fr>
|
M: Paul Kocialkowski <contact@paulk.fr>
|
||||||
S: Maintained
|
S: Maintained
|
||||||
|
|
16
configs/Sinlinx_SinA33_defconfig
Normal file
16
configs/Sinlinx_SinA33_defconfig
Normal file
|
@ -0,0 +1,16 @@
|
||||||
|
CONFIG_ARM=y
|
||||||
|
CONFIG_ARCH_SUNXI=y
|
||||||
|
CONFIG_MACH_SUN8I_A33=y
|
||||||
|
CONFIG_DRAM_CLK=552
|
||||||
|
CONFIG_DRAM_ZQ=15291
|
||||||
|
CONFIG_DEFAULT_DEVICE_TREE="sun8i-a33-sinlinx-sina33"
|
||||||
|
# CONFIG_SYS_MALLOC_CLEAR_ON_INIT is not set
|
||||||
|
CONFIG_SPL=y
|
||||||
|
# CONFIG_CMD_IMLS is not set
|
||||||
|
# CONFIG_CMD_FLASH is not set
|
||||||
|
# CONFIG_CMD_FPGA is not set
|
||||||
|
CONFIG_DM_ETH=y
|
||||||
|
CONFIG_DM_SERIAL=y
|
||||||
|
CONFIG_AXP221_ALDO1_VOLT=3000
|
||||||
|
CONFIG_USB=y
|
||||||
|
CONFIG_DM_USB=y
|
Loading…
Add table
Reference in a new issue