Skip to content
This repository has been archived by the owner on Oct 5, 2018. It is now read-only.

Commit

Permalink
Merge remote-tracking branch 'lt-hisi/hikey-tracking-misc-sysconfig' …
Browse files Browse the repository at this point in the history
…into 96b/releases/2016.03

* lt-hisi/hikey-tracking-misc-sysconfig:
  misc: hi6220: reset uart2, uart3, and uart4 upon kernel boots
  misc: hi6220: reset uart1 at booting for bluetooth
  misc: hi6220: Add driver to config chips at kernel boot, enable CK32B for wifi

Resolved merge conflict.

This fixes bug: https://bugs.96boards.org/show_bug.cgi?id=273 by resetting the
UART after boot

Signed-off-by: Amit Kucheria <amit.kucheria@linaro.org>
  • Loading branch information
idlethread committed Feb 29, 2016
2 parents 095065c + c493b3e commit 7516424
Show file tree
Hide file tree
Showing 3 changed files with 21 additions and 0 deletions.
8 changes: 8 additions & 0 deletions drivers/misc/Kconfig
Expand Up @@ -466,6 +466,14 @@ config BMP085_SPI
To compile this driver as a module, choose M here: the
module will be called bmp085-spi.

config HI6220_SYSCFG
bool "Hisilicon HI6220 System Configuration driver"
depends on ARCH_HISI
default y
help
Hisilicon HI6220 uses some registers to configure some chip hosts to
work or not, e.g. disable the UART hosts reset and let's them work.

config PCH_PHUB
tristate "Intel EG20T PCH/LAPIS Semicon IOH(ML7213/ML7223/ML7831) PHUB"
select GENERIC_NET_UTILS
Expand Down
1 change: 1 addition & 0 deletions drivers/misc/Makefile
Expand Up @@ -12,6 +12,7 @@ obj-$(CONFIG_ATMEL_TCLIB) += atmel_tclib.o
obj-$(CONFIG_BMP085) += bmp085.o
obj-$(CONFIG_BMP085_I2C) += bmp085-i2c.o
obj-$(CONFIG_BMP085_SPI) += bmp085-spi.o
obj-$(CONFIG_HI6220_SYSCFG) += hi6220-sysconfig.o
obj-$(CONFIG_DUMMY_IRQ) += dummy-irq.o
obj-$(CONFIG_ICS932S401) += ics932s401.o
obj-$(CONFIG_LKDTM) += lkdtm.o
Expand Down
12 changes: 12 additions & 0 deletions drivers/misc/hi6220-sysconfig.c
Expand Up @@ -37,6 +37,18 @@ static int __init hi6220_sysconf(void)
writel(BIT(5), base + reset_offset);
writel(BIT(5), base + pclk_offset);

/*Disable UART2 reset and set pclk*/
writel(BIT(6), base + reset_offset);
writel(BIT(6), base + pclk_offset);

/*Disable UART3 reset and set pclk*/
writel(BIT(7), base + reset_offset);
writel(BIT(7), base + pclk_offset);

/*Disable UART4 reset and set pclk*/
writel(BIT(8), base + reset_offset);
writel(BIT(8), base + pclk_offset);

iounmap(base);

node1 = of_find_compatible_node(NULL, NULL, "hisilicon,hi655x-pmic");
Expand Down

0 comments on commit 7516424

Please sign in to comment.