Fixup the default pinctrl configuration for uart4-rts-gpio:
rockchip-pinctrl pinctrl: unable to find group for node uart4-rts-gpio
Change-Id: Ic25375aeba924ba0314ad5660b3ee4f18ea8c0cc
Signed-off-by: Ziyuan Xu <xzy.xu@rock-chips.com>
DWC_mipi_dsi_host can be configured to send the low-power (LP)
commands during the HS video mode transmission. To enable this
feature, set the lp_cmd_en bit of the VID_MODE_CFG register to 1.
In this case, it is necessary to calculate the time available,
in bytes, to transmit a command in LP mode to Horizontal Front Porch (HFP),
Vertical Sync Active (VSA), Vertical Back Porch (VBP), and
Vertical Front Porch (VFP) regions.
Bits 8 to 13 of the VID_MODE_CFG register indicates if DWC_mipi_dsi_host
can go to LP when in idle. If the lp_cmd_en bit is set (1'b1) and
non-video packets are in queue, DWC_mipi_dsi_host ignores the LP
configuration and transmits LP commands, even if it is not allowed
to enter LP in a specific region. After the LP commands transmission,
DWC_mipi_dsi_host remains in LP until a sync event occurs.
If the lp_cmd_en bit of the VID_MODE_CFG register is 0, the commands
are sent in high-speed in Video Mode. In this case, the DWC_mipi_dsi_host
automatically determines the area where each command can be sent and no
programming or calculation is required.
Change-Id: Id47982c2c7605be17c4d295707fd5496f32f79fe
Signed-off-by: Wyon Bi <bivvy.bi@rock-chips.com>
The function mipi_dsi_device_transfer() returns the number of transmitted
or received bytes on success or a negative error code on failure.
The functions mipi_dsi_shutdown_peripheral(), mipi_dsi_turn_on_peripheral() &
mipi_dsi_set_maximum_return_packet_size() use improperly this returned
value in case of success: 0 should be returned instead of the number of
transmitted bytes.
Signed-off-by: Philippe Cornu <philippe.cornu@st.com>
Reviewed-by: Andrzej Hajda <a.hajda@samsung.com>
Signed-off-by: Sean Paul <seanpaul@chromium.org>
Link: https://patchwork.freedesktop.org/patch/msgid/20180112144847.18810-1-philippe.cornu@st.com
Change-Id: I7709da898423e6149d3d95088ad795a20b867a7b
Signed-off-by: Wyon Bi <bivvy.bi@rock-chips.com>
(cherry picked from commit 6ac6929028)
Most of these helpers had been introduced in the correct order, but some
were simply appended, which wasn't detected when they were applied.
Signed-off-by: Thierry Reding <treding@nvidia.com>
Change-Id: Ic540fb4d541b32c21f9f2348aba3f4cae5c99fa6
Signed-off-by: Wyon Bi <bivvy.bi@rock-chips.com>
(cherry picked from commit bbdcf516a6)
Implement a uevent callback for devices on the MIPI DSI bus. This
callback will append MODALIAS information to the uevent and allow
modules to be loaded when devices are added to the bus.
Reviewed-by: Archit Taneja <architt@codeaurora.org>
Signed-off-by: Thierry Reding <treding@nvidia.com>
Change-Id: I580c1fb721330a5088f8ddf233a635c607277729
Signed-off-by: Wyon Bi <bivvy.bi@rock-chips.com>
(cherry picked from commit babb24fec1)
MIPI DSI devices are inherently aware of their host because they share a
parent-child hierarchy in the device tree.
Non-DSI drivers that create DSI device don't have this data. In order to
get this information, they require to a phandle to the DSI host in the
device tree.
Maintain a list of all the DSI hosts that are currently registered. This
list will be used to find the struct mipi_dsi_host corresponding to the
device tree node passed to of_find_mipi_dsi_host_by_node().
Reviewed-by: Andrzej Hajda <a.hajda@samsung.com>
Signed-off-by: Archit Taneja <architt@codeaurora.org>
Signed-off-by: Thierry Reding <treding@nvidia.com>
Change-Id: I9d1a42c45707ec4b22e67e6b4aad058b3a5254df
Signed-off-by: Wyon Bi <bivvy.bi@rock-chips.com>
(cherry picked from commit 97b6ae50e0)
A driver calling mipi_dsi_device_register_full() might want to remove
the device once it's done. It might also require it in an error handling
path in case something went wrong.
Create mipi_dsi_device_unregister() for this purpose and use it within
mipi_dsi_remove_device_fn() as it does the same thing.
Reviewed-by: Andrzej Hajda <a.hajda@samsung.com>
Signed-off-by: Archit Taneja <architt@codeaurora.org>
Signed-off-by: Thierry Reding <treding@nvidia.com>
Change-Id: I538bd028851bb27dbf7c93d459b8276d7271dae8
Signed-off-by: Wyon Bi <bivvy.bi@rock-chips.com>
(cherry picked from commit 509e42ce04)
Add a device name field in struct mipi_dsi_device. This name is not the
same as the device name (which is of the format "hostname.reg"). When
the device is created via DT, this name is set to the modalias string.
In the non-DT case, the driver creating the DSI device provides the
name by populating a field in struct mipi_dsi_device_info.
Matching for DT case would be as it was before. For the non-DT case, we
compare the device and driver names. Other buses (like I2C/SPI) perform
a non-DT match by comparing the device name and entries in the driver's
id_table. Such a mechanism isn't used for the DSI bus.
Reviewed-by: Andrzej Hajda <a.hajda@samsung.com>
Signed-off-by: Archit Taneja <architt@codeaurora.org>
Signed-off-by: Thierry Reding <treding@nvidia.com>
Change-Id: I68d4e46fb82ccce4e578256c031d6ee329d5eb1b
Signed-off-by: Wyon Bi <bivvy.bi@rock-chips.com>
(cherry picked from commit bf4363ce3a)
Use mipi_dsi_device_register_full() for device creation. This takes in
a struct mipi_dsi_device_info as a template to populate the DSI device
information.
The reason to introduce this is to have a way to create DSI devices not
available via DT. Drivers that want to create a DSI device can populate
a struct mipi_dsi_device_info and call this function. For DSI devices
available via DT, of_mipi_dsi_device_add() is used as before, but this
now calls mipi_dsi_device_register_full() internally.
Signed-off-by: Archit Taneja <architt@codeaurora.org>
Signed-off-by: Thierry Reding <treding@nvidia.com>
Change-Id: I0fc26d2bbffd9368ceb50c1660ff74c4ab808b6b
Signed-off-by: Wyon Bi <bivvy.bi@rock-chips.com>
(cherry picked from commit c63ae8a968)
of_mipi_dsi_device_add() is used only when CONFIG_OF is enabled. It
currently works if OF support is disabled, but this will change when we
add more functionality to it.
Define the original function if CONFIG_OF is enabled and a dummy
function otherwise.
Signed-off-by: Archit Taneja <architt@codeaurora.org>
Signed-off-by: Thierry Reding <treding@nvidia.com>
Change-Id: I5815c8fe403b65989bfbaf33aba208d83634fa4a
Signed-off-by: Wyon Bi <bivvy.bi@rock-chips.com>
(cherry picked from commit fc903ebd50)
1. support spectek L84C/L84D/L05B NAND FLASH
2. support SKhynix 16nm 4GB NAND FLASH
3. support upgrade loader by write idb data to lba 64
Change-Id: Ie0296622d8ad13f2f4282b1b7726a5c699164e67
Signed-off-by: Yifeng Zhao <zyf@rock-chips.com>
buildroot use rkwifibt to install wifi driver, and it request wifi
driver build as module.
Change-Id: Iad26078abe4b02f55def46f4c9f84b3d7f2d7724
Signed-off-by: Lin Huang <hl@rock-chips.com>
with these fixs, AP6212 can work on rk1808-evb board.
Change-Id: Icfdb6dedfcb139debad299852e87586ce0d31de6
Signed-off-by: Lin Huang <hl@rock-chips.com>
fix up the pd_pcie clks.
add power-domains = <&power RK1808_PD_PCIE> for usb host.
enable power status.
Change-Id: I040c3c24ab542add96f87ca7b2453b60703b2a4d
Signed-off-by: Elaine Zhang <zhangqing@rock-chips.com>
It's not need to power on all pd when add pm domain.
Use pd's real status for pm_genpd_init().
Change-Id: I9a976f01c1b0ff192e09494dcfa236d786495e96
Signed-off-by: Elaine Zhang <zhangqing@rock-chips.com>
irq trigger level flags only support HIGH for GIC.
Fix this warning:
genirq: Setting trigger mode 8 for irq 188 failed (gic_set_type+0x0/0x74)
Change-Id: I3ef2bb7d26003595b8c6dafb932512a0f5eae450
Signed-off-by: Tao Huang <huangtao@rock-chips.com>