Robert Chiras [Thu, 12 Apr 2018 13:29:21 +0000 (16:29 +0300)]
MLK-18177-1: drm/panel: Move the DSI init into enable stage
Currently, the DSI panel init sequence is made in the prepare function,
right after the reset pin is asserted. This implies that at this moment,
the DSI host needs to be enabled. If the DSI host is enabled during
panel prepare, there will be DSI signal on the DSI lanes during the
panel reset, which is wrong.
In order to not to have any signal on the DSI data lanes during reset,
the reset sequence must be separated from the init sequence, so move the
init into enable function and leave the reset into the prepare function.
Also:
- removed the calls to panel_disable and panel_unprepare from
panel_remove, since the panel should be already disabled when this call
is made
- fixed the call ordering to panel_disable and panel_unprepare from
rad_panel_shutdown function
Signed-off-by: Robert Chiras <robert.chiras@nxp.com>
Mirela Rabulea [Wed, 7 Mar 2018 08:41:31 +0000 (10:41 +0200)]
MLK-17684-1: drm/panel: rm67191: Add support for new bus formats
Do not hardcode pixel_format to 0x77 but calculate it from dsi->format.
Report all the supported bus formats in get_modes:
MEDIA_BUS_FMT_RGB888_1X24
MEDIA_BUS_FMT_RGB666_1X18
MEDIA_BUS_FMT_RGB565_1X16
Change pixelclock from 120 to 132 MHz, or 16 bpp formats will not work.
Signed-off-by: Mirela Rabulea <mirela.rabulea@nxp.com>
Robert Chiras [Mon, 22 Jan 2018 08:16:03 +0000 (10:16 +0200)]
MLK-17389: drm/panel: rm67191: Fix power on/off logic
On remove, the panel driver was only calling rad_panel_disable, which
only updates the brightness. During a reboot, the panel may remain
powered which will cause the whole screen to be bright white (sometimes
flashing).
This patch also calls the rad_panel_unprepare, which puts the panel to
sleep and also sets the DSI_EN gpio to LOW (which is the proper power
off sequence).
While powering on the sleeps are too high, so reduce them according to
the sample driver received from vendor.
Also, fixed the reading of display-timings property: this property is
optional, but will dump some error messages into the console log by
directly calling of_get_videomode() when this property is missing. To
avoid the error messages, first check if we really have this property
first.
Signed-off-by: Robert Chiras <robert.chiras@nxp.com>
Robert Chiras [Fri, 5 Jan 2018 11:41:44 +0000 (13:41 +0200)]
MLK-17280-1: drm: panel: rm67191: Fix power on sequence
According to the vendor driver sample there is a sleep after the exit
sleep and display on commands, but it seems that these sleeps are only
causing stability issues when the display signal is sent to the panel,
so remove them.
Signed-off-by: Robert Chiras <robert.chiras@nxp.com>
Reviewed-by: Laurentiu Palcu <laurentiu.palcu@nxp.com>
Robert Chiras [Thu, 16 Nov 2017 11:28:55 +0000 (13:28 +0200)]
MLK-16926-2: drm/panel Update Raydium panel
If a GPIO pin is present, set it to LOW, so that the initial
configuration comes from a LOW value on that pin.
This patch was needed, since the panel driver had issues on MX8MQ.
Also, use the bus specific flags from display timings flags in order to
set them as display_info bus_flags.
Signed-off-by: Robert Chiras <robert.chiras@nxp.com>
Reviewed-by: Laurentiu Palcu <laurentiu.palcu@nxp.com>
Robert Chiras [Mon, 16 Oct 2017 13:24:59 +0000 (16:24 +0300)]
MLK-16698-1: drm/panel: Add panel driver for Raydium RM67191
Add support for the OLED display based on MIPI-DSI protocol from Raydium:
RM67191.
Signed-off-by: Robert Chiras <robert.chiras@nxp.com>
Robert Chiras [Mon, 26 Nov 2018 11:46:14 +0000 (13:46 +0200)]
MLK-17537-1: drm/bridge: Correct the ADV7533 init
According to the Analog Devices configuration script, there are some
steps that need to be made when configuring the ADV for a specific mode.
Some of those steps were missing from driver, so this patch takes care
of this.
Also, in mode_fixup, the driver is trying to reconfigure the DSI lanes
from 4 to 3, when pixel clock is lower than 80MHz, which is not
necessary. the lanes property represents the maximum available lanes on
that devices and should not differ from a mode to another.
The DSI host is the one who should predict how many lanes it could use
to drive a display mode, so remove this from ADV driver.
Signed-off-by: Robert Chiras <robert.chiras@nxp.com>
Reviewed-by: Laurentiu Palcu <laurentiu.palcu@nxp.com>
Robert Chiras [Thu, 12 Jul 2018 08:49:00 +0000 (11:49 +0300)]
MLK-18877-1: drm/bridge: adv7511: Add debug info for HPD event
Add debug information for the HDP event catched with i2c interrupt.
Also, simplify the code in adv7511_hpd_work.
Signed-off-by: Robert Chiras <robert.chiras@nxp.com>
Robert Chiras [Fri, 2 Mar 2018 09:31:50 +0000 (11:31 +0200)]
MLK-17650-1: drm/bridge: adv7511: Add support for programmable i2c addresses
The DSI-HDMI converter, ADV7535, driver uses four i2c memory maps: MAIN,
DSI-CEC, EDID and PACKET.
While the MAIN address is hard-coded in the ROM chip, the other three
can be programmed into the MAIN memory map.
Currently, the three memory maps addresses, that can be programmed, are
hard-coded into the code.
In order to avoid conflicts with other i2c clients on the bus, update
the driver to use configurable addresses specified in DTS file.
Signed-off-by: Robert Chiras <robert.chiras@nxp.com>
Robert Chiras [Thu, 21 Dec 2017 12:10:42 +0000 (14:10 +0200)]
MLK-17275-7: drm/bridge: adv7511: Add dsi-channel property
Add a new property "adi,dsi-channel" to allow the user specify the DSI
channel to be used when communicating with DSI peripheral.
Signed-off-by: Robert Chiras <robert.chiras@nxp.com>
Reviewed-by: Laurentiu Palcu <laurentiu.palcu@nxp.com>
Robert Chiras [Thu, 21 Dec 2017 08:59:20 +0000 (10:59 +0200)]
MLK-17275-1: drm/bridge: adv7511: Add support for OF_DYNAMIC
When CONFIG_OF_DYNAMIC is used, and this driver is enabled in
devicetree, but fails to probe a physical i2c client, it should disable
it's remote endpoint, so that the DRM master device won't fail to bind
the other available devices.
Usually, the remote endpoint of this device is a DRM encoder. If a DRM
encoder fails to bind, the DRM master device will also fail to bind.
This is why, we should disable the encoder node dynamically in
devicetree.
Signed-off-by: Robert Chiras <robert.chiras@nxp.com>
Reviewed-by: Laurentiu Palcu <laurentiu.palcu@nxp.com>
Oliver Brown [Wed, 13 Mar 2019 19:11:13 +0000 (14:11 -0500)]
MLK-21142-1: drm/imx: nwl_dsi-imx: Assert DPI and MIPI resets in poweron
The resets need to be set in poweron to handle the warm reset case.
Signed-off-by: Oliver Brown <oliver.brown@nxp.com>
Robert Chiras [Fri, 1 Mar 2019 08:40:10 +0000 (10:40 +0200)]
MLK-20718-5: drm/imx: nwl_dsi-imx: Correct clk usage
For QM and QXP, the PHY_REF clock was default ON on SCFW so it was not
handled by driver. Since now this clock is OFF in SCFW, it can be
correctly handled by kernel driver.
Now, the PHY_REF clock rate is set by the nwl-dsi bridge driver,
depending on the display mode used.
In this driver, the PIXEL and BYPASS clocks rates were set to the same
rate as the PHY_REF, but their rates need to be set to current display
mode clock.
Also, the order of the clocks matters, so make sure the BYPASS is
enabled before the PIXEL clock.
Signed-off-by: Robert Chiras <robert.chiras@nxp.com>
Reviewed-by: Laurentiu Palcu <laurentiu.palcu@nxp.com>
Robert Chiras [Mon, 4 Feb 2019 13:03:09 +0000 (15:03 +0200)]
MLK-17537-6: drm/bridge: nwl-dsi: force valid clocks
Some pixel clocks are not working with DSI. Until a better solution is
found, just filter-out the display modes by their clocks.
Signed-off-by: Robert Chiras <robert.chiras@nxp.com>
Reviewed-by: Laurentiu Palcu <laurentiu.palcu@nxp.com>
Robert Chiras [Mon, 4 Feb 2019 12:57:36 +0000 (14:57 +0200)]
MLK-17537-5: drm/bridge: nwl-dsi: correct crtc_clock when panel used
Panels can request a higher clock than the one that can actually be
driven by the CRTC, in order to have more time for DSI commands.
If this is the case, make sure that the crtc_clock used is one that can
actually be driven for current chosen phy_ref rate.
Signed-off-by: Robert Chiras <robert.chiras@nxp.com>
Reviewed-by: Laurentiu Palcu <laurentiu.palcu@nxp.com>
Robert Chiras [Mon, 4 Feb 2019 12:53:45 +0000 (14:53 +0200)]
MLK-17537-4: drm/bridge: nwl-dsi: implement mode_valid()
This patch removes the exported function nwl_dsi_get_bit_clock that was
used by nwl_dsi-imx driver in order to configure the phy driver speed
and move this configuration directly into the nwl-dsi driver.
This function is now used directly by nwl-dsi to verify which mode can or
cannot be supported by the DSI PHY.
Also, in nwl-dsi, add support for mode_valid and add each supported mode
into a list kept internally so that it can apply the needed
configuration (phyref rate, dsi lanes, bit-clock) later when the mode is
used.
Signed-off-by: Robert Chiras <robert.chiras@nxp.com>
Reviewed-by: Laurentiu Palcu <laurentiu.palcu@nxp.com>
Robert Chiras [Mon, 4 Feb 2019 12:31:31 +0000 (14:31 +0200)]
MLK-17537-3: drm/bridge: nwl-dsi: Remove some vars
Remove the variables 'format', 'vc' and 'dsi_mode_flags' since we can
use the directly from the dsi_device object.
Also, fix the VACTIVE value (currently, -1 is subtracted from it but it
wasn't necessary).
Signed-off-by: Robert Chiras <robert.chiras@nxp.com>
Reviewed-by: Laurentiu Palcu <laurentiu.palcu@nxp.com>
Robert Chiras [Mon, 4 Feb 2019 11:55:41 +0000 (13:55 +0200)]
MLK-17537-2: drm/imx: nwl_dsi-imx: Move sync_polarity code
Move the imx_nwl_update_sync_polarity function content into
imx_nwl_dsi_mode_fixup function.
Signed-off-by: Robert Chiras <robert.chiras@nxp.com>
Reviewed-by: Laurentiu Palcu <laurentiu.palcu@nxp.com>
Robert Chiras [Mon, 28 Jan 2019 12:54:36 +0000 (14:54 +0200)]
MLK-20697: drm/bridge: nwl-dsi: Fix EOTP handling
Currently, the DSI controller is configured for AUTOINSERT_EOTP
depending on the CONTINUOUS or NON_CONTINUOUS clock mode, causing
problems to devices that actually need EOTP (End of Transmission
packet).
Fix this by taking into consideration the special flag created in
drm_mipi_dsi API.
Signed-off-by: Robert Chiras <robert.chiras@nxp.com>
Robert Chiras [Thu, 23 Aug 2018 06:29:32 +0000 (09:29 +0300)]
MLK-19010: drm/bridge: nwl-dsi: Fix DSI long read
On the long read routine, there was a bug when the driver was parsing
the value from RX_PAYLOAD register.
Signed-off-by: Robert Chiras <robert.chiras@nxp.com>
Robert Chiras [Wed, 11 Jul 2018 13:41:42 +0000 (16:41 +0300)]
MLK-18850: drm/bridge: nwl-dsi: Fix bridge handling
When the drm_bridge object, representing the next bridge in chain,
connected to nwl-dsi brigde was attached to encoder, the
"previous_bridge" was wrongly passed, this way the next bridge was not
actually added to the encoder bridge chain.
Signed-off-by: Robert Chiras <robert.chiras@nxp.com>
Robert Chiras [Tue, 12 Jun 2018 11:25:48 +0000 (14:25 +0300)]
MLK-18543-1: drm/bridge: nwl-dsi: Add pm_runtime support
Add support for pm_runtime, so that the assigned power domain state will be
changed accordingly.
Signed-off-by: Robert Chiras <robert.chiras@nxp.com>
Robert Chiras [Tue, 12 Jun 2018 11:20:52 +0000 (14:20 +0300)]
MLK-18447: drm: imx: Fix nwl_dsi init sequence
The init sequence for i.MX8QXP had some flaws, making MIPI1 not working
when MIPI0 was not started.
Also, re-arrange the SC calls for a better stability during power on.
Also, change the poweroff return signature to void, since the disable
return is also void.
Signed-off-by: Robert Chiras <robert.chiras@nxp.com>
Robert Chiras [Mon, 21 May 2018 12:07:06 +0000 (15:07 +0300)]
MLK-18357-2: drm/bridge: nwl-dsi: Add no_clk_reset property
On some platforms, like the i.MX8M, the Display Controller is not
completely powered off during suspend, just stopped. Since there are
problems if we stop the clocks in DSI sub-system, while the Display
Controller is still powered on, the display clocks will get out of sync.
Adding this new property to specify, on such platforms, not to reset the
clocks.
Signed-off-by: Robert Chiras <robert.chiras@nxp.com>
Robert Chiras [Mon, 21 May 2018 12:02:07 +0000 (15:02 +0300)]
MLK-18357-1: drm/imx: Add no_clk_reset property
Remove the NO_CLK_RESET define and add a property for this.
On some platforms, like the i.MX8M, the Display Controller is not
completely powered off during suspend, just stopped. Since there are
problems if we stop the clocks in DSI sub-system, while the Display
Controller is still powered on, the display clocks will get out of sync.
Adding this new property to specify, on such platforms, not to reset the
clocks.
Signed-off-by: Robert Chiras <robert.chiras@nxp.com>
Robert Chiras [Tue, 17 Apr 2018 07:56:41 +0000 (10:56 +0300)]
MLK-17589: gpu/imx: Fix DCSS+DSI suspend/resume
Since the DCSS is not fully powered off when a suspend/blank occurs, the
next time we resume/unblank, the DCSS->DSI pipeline cannot be fully
re-initialized. In order to fix this issue, we should also not
completely power off the DSI too. Just configure it to stop
transmitting, by powering off the PHY.
Signed-off-by: Robert Chiras <robert.chiras@nxp.com>
Robert Chiras [Thu, 12 Apr 2018 13:30:28 +0000 (16:30 +0300)]
MLK-18177-2: drm/bridge: nwl-dsi: Change init sequence for panel
Currently, the DSI panel init sequence is made in the prepare function,
right after the reset pin is asserted. This implies that at this moment,
the DSI host needs to be enabled. If the DSI host is enabled during
panel prepare, there will be DSI signal on the DSI lanes during the
panel reset, which is wrong.
In order to fix this, the init sequence was moved from prepare to
enable, while the reset sequence is made in prepare. Also, the DSI host
intialization has to be updated in such a way that the host won't send
DSI signals on the lanes between the prepare and enable of the panel.
Signed-off-by: Robert Chiras <robert.chiras@nxp.com>
Robert Chiras [Thu, 19 Apr 2018 08:25:41 +0000 (11:25 +0300)]
MLK-18106: drm/bridge: Fix nwl-dsi bridge handling
Since the drm_bridge_attach function now supports chained bridges, there
is no need for nwl_dsi_add_bridge and nwl_dsi_del_bridge functions, so
remove them.
Now, we can pass the existent bridge to drm_bridge_attach.
This fixes a bug created during kernel 4.14 rebase process.
Signed-off-by: Robert Chiras <robert.chiras@nxp.com>
Robert Chiras [Thu, 19 Apr 2018 08:22:08 +0000 (11:22 +0300)]
MLK-18106: drm/imx: Fix nwl_dsi-imx bridge handling
The nwl_dsi-imx which is the platform driver for the NortWest Logic DSI
host controller found on IMX platforms handles the DSI host as a bridge.
Since the drm_bridge_attach function now supports chained bridges, there
is no need for nwl_dsi_add_bridge and nwl_dsi_del_bridge functions.
Just pass the existent bridge to drm_bridge_attach.
This fixes a bug created during kernel 4.14 rebase process.
Signed-off-by: Robert Chiras <robert.chiras@nxp.com>
Mirela Rabulea [Tue, 20 Mar 2018 11:01:25 +0000 (13:01 +0200)]
MLK-17684: drm/bridge: nwl-dsi: Propagate DSI format to the attached panel/bridge
Signed-off-by: Mirela Rabulea <mirela.rabulea@nxp.com>
Mirela Rabulea [Wed, 7 Mar 2018 08:45:29 +0000 (10:45 +0200)]
MLK-17684-2: drm/bridge: nwl-dsi: Let CRTC dictate the final bus format
Use the bus format that was established by CRTC in
crtc->mode.private_flags.
This will be available during enable phase.
The DSI host will be configured via interface_color_coding
and pixel_format (DPI-2 interface ports).
Previously the interface_color_coding was hardcoded to 24-bit.
Set the DSI pixel format before it is necessary in
nwl_dsi_get_bit_clock, during imx_nwl_dsi_enable.
Signed-off-by: Mirela Rabulea <mirela.rabulea@nxp.com>
Robert Chiras [Thu, 21 Dec 2017 09:14:16 +0000 (11:14 +0200)]
MLK-17275-4: drm/imx: nwl_dsi-imx: Update driver for reconfig
Initially, this driver was designed to work with NWL driver as a
drm_bridge and it is required for this to work, otherwise it will defer.
When CONFIG_OF_DYNAMIC is used, the NWL bridge can be disabled by it's
remote endpoint, it that endpoint is an i2c capable device and it fails
to find a physical device on the expected i2c address.
If the NWL drm_bridge is disabled, since this driver it is required by
the master DRM device, just do nothing, so the drm_encoder won't be
created. So, if the NWL drm_bridge is missing, this driver will just do
nothing, in order to not interfere with the other available devices
required by the DRM master.
Signed-off-by: Robert Chiras <robert.chiras@nxp.com>
Reviewed-by: Laurentiu Palcu <laurentiu.palcu@nxp.com>
Robert Chiras [Thu, 21 Dec 2017 09:06:44 +0000 (11:06 +0200)]
MLK-17275-3: drm/bridge: nwl-dsi: Fix remove/detach
Add a check in detach function, so that the mipi_dsi_host_unregister
will occur only if the host was registered.
Also, remove the unnecessary calls to host_unregister from probe and
remove functions.
Signed-off-by: Robert Chiras <robert.chiras@nxp.com>
Reviewed-by: Laurentiu Palcu <laurentiu.palcu@nxp.com>
Fugang Duan [Tue, 19 Dec 2017 05:36:00 +0000 (13:36 +0800)]
MLK-17290-03 drm/bridge: request/free irq in dynamical
Request/free irq in dynamical can runtime manage the irq domain's
clock and power if irq domain support runtime pm and manage its
clock in its pm callback.
Signed-off-by: Fugang Duan <fugang.duan@nxp.com>
Tested-by: Guoniu.Zhou <guoniu.zhou@nxp.com>
Acked-by: Robert Chiras <robert.chiras@nxp.com>
Robert Chiras [Fri, 8 Dec 2017 13:15:35 +0000 (15:15 +0200)]
MLK-17137-2: drm/bridge: Fix bridge_detach for nwl-dsi
When the bridge is detached from it's parent, we also need to unregister
the dsi_host. Also, in enable, check if we have a panel or a bridge
connected, otherwise enable is not needed.
Signed-off-by: Robert Chiras <robert.chiras@nxp.com>
Robert Chiras [Fri, 8 Dec 2017 14:21:33 +0000 (16:21 +0200)]
MLK-17047-2: drm/imx: Fix suspend/resume for nwl_dsi-imx
This patch addresses two issues:
1. Always request/release bus_freq, not just on suspend/resume routines
2. Check if the driver is running when doing a suspend, so that we won't
enable it by mistake on resume.
Signed-off-by: Robert Chiras <robert.chiras@nxp.com>
Oliver Brown [Wed, 13 Mar 2019 19:15:49 +0000 (14:15 -0500)]
MLK-21142-2: phy: mixel-mipi: Assert PHY reset in phy_init
The reset needs to be set in phy_init to handle the warm reset case.
Signed-off-by: Oliver Brown <oliver.brown@nxp.com>
Oliver Brown [Wed, 22 Aug 2018 19:20:16 +0000 (14:20 -0500)]
MLK-19295: phy: mixel-mipi: Improve MIPI PHY timing parameters
Improving the PHY timing parameters by using linear interpolation for the linear parameters.
For, the non-linear parameters, use more frequency steps to improve the accuracy.
Signed-off-by: Oliver Brown <oliver.brown@nxp.com>
Robert Chiras [Thu, 21 Jun 2018 07:00:48 +0000 (10:00 +0300)]
MLK-18651: phy: Update Mixel MIPI-DSI phy register addresses
Some of the Mixel phy (the MIPI DPHY found on 8QM, 8QXP and 8M), have
different addresses, depending on the platform.
Update the driver to have the correct address for a corresponding
platform.
Signed-off-by: Robert Chiras <robert.chiras@nxp.com>
Robert Chiras [Thu, 12 Apr 2018 13:32:39 +0000 (16:32 +0300)]
MLK-18178: phy: mixel-mipi: Update the PRG register settings
Update the register settings for PRG values to be more accurate,
depending on the timing used.
Also, update the init function to make sure the PHY is powered OFF in
this stage, and the power_on function to correctly power ON the PHY
according to the specification: assert PD_PLL, wait for LOCK, assert
PD_DPHY.
Signed-off-by: Robert Chiras <robert.chiras@nxp.com>
Robert Chiras [Fri, 24 Nov 2017 12:04:24 +0000 (14:04 +0200)]
MLK-16986-4: drm: bridge: adv7511: set bus_flags and bus_format
For a proper initialization of the crtc driving the connector for this
bridge, we need to set the bus_formats and bus_flags of the connector's
display_info.
Signed-off-by: Robert Chiras <robert.chiras@nxp.com>
Reviewed-by: Laurentiu Palcu <laurentiu.palcu@nxp.com>
Robert Chiras [Tue, 5 Dec 2017 16:36:02 +0000 (18:36 +0200)]
MLK-16986-3: drm/imx: Add a delay to enable function in nwl_dsi-imx
To allow the PLL to become stable before enabling the clocks, we may
need a delay. This patch adds a new property to specify this delay from
DTS file.
Reviewed-by: Laurentiu Palcu <laurentiu.palcu@nxp.com
Signed-off-by: Robert Chiras <robert.chiras@nxp.com>
Robert Chiras [Mon, 27 Nov 2017 14:49:27 +0000 (16:49 +0200)]
MLK-16926-3: drm/imx: Add sync-pol to nwl_dsi-imx
Add a new dt property to the nwl_dsi-imx driver: sync-pol.
This property represents the sync polarity of the input signal to it's
internal DPI-to-DSI block.
Signed-off-by: Robert Chiras <robert.chiras@nxp.com>
Reviewed-by: Laurentiu Palcu <laurentiu.palcu@nxp.com>
Robert Chiras [Tue, 5 Dec 2017 07:34:14 +0000 (09:34 +0200)]
MLK-16986-2: drm/imx: Fix nwl_dsi-imx driver
Since the ADV7535 can change the DSI lanes used in mode_set, we need to
set up the Mixel PHY speed again, in enable() function, so that we will
take into account the new DSI lanes.
Signed-off-by: Robert Chiras <robert.chiras@nxp.com>
Reviewed-by: Laurentiu Palcu <laurentiu.palcu@nxp.com
Robert Chiras [Tue, 5 Dec 2017 07:24:24 +0000 (09:24 +0200)]
MLK-16986-1: phy: Fix Mixel PHY driver best_match
When setting up the CM, CN and CO decimal values for DPHY PLL, these
values should only be rounded up when a "best_match" is requested. Some
DSI receivers requires the DSI clock to be exactly matched with the
pixel clock.
Signed-off-by: Robert Chiras <robert.chiras@nxp.com>
Reviewed-by: Laurentiu Palcu <laurentiu.palcu@nxp.com
Robert Chiras [Wed, 22 Nov 2017 09:47:48 +0000 (11:47 +0200)]
MLK-16918-17: drm/imx: Add support for suspend/resume in nwl_dsi-imx
Update the IMX_NWL_DSI DRM driver to support the PM Runtime and
System Sleep suspend/resume routines.
Signed-off-by: Robert Chiras <robert.chiras@nxp.com>
Robert Chiras [Fri, 17 Nov 2017 09:37:09 +0000 (11:37 +0200)]
MLK-16918-15: drm/bridge: Update adv7511 driver with some regs for adv7535
The low refresh rate register for ADV7535 is in 0x4A instead of 0xFB. In
order to correctly handle these differences, add the new type ADV7535.
Signed-off-by: Robert Chiras <robert.chiras@nxp.com>
Robert Chiras [Thu, 9 Nov 2017 09:33:31 +0000 (11:33 +0200)]
MLK-16918-6: phy: update Mixel mipi-dsi phy driver for MX8MQ
Added compatible string for i.MX8MQ platform.
Signed-off-by: Robert Chiras <robert.chiras@nxp.com>
Robert Chiras [Thu, 9 Nov 2017 12:01:35 +0000 (14:01 +0200)]
MLK-16918-5: drm: Implement NWL MIPI-DSI as a real drm_bridge
Currently, the Northwest Logic MIPI-DSI controller host specific code
resides under drm/bridge, but is not a real drm_bridge. It creates a
drm_bridge and adds itself to the drm_encoder that handles this file,
but this is wrong, since it does not implement the drm_bridge_funcs.
The correct way to implement a drm_bridge is to add the drm_bridge and
let other components (another bridge or a drm_encoder) to attach to this
bridge.
Since we are doing this, a new compatible strings can be used for this
driver: "nwl,mipi-dsi".
Since this was used by nwl_dsi-imx.c, update that driver to use this
bridge correctly.
This is needed in order to add support for MIPI-DSI on 8MQ. The IMX_NWL
driver will either add a DSI encoder to DRM, or a DSI bridge.
The encoder will be used by imx-drm-core driver, while the bridge
will be used by MXSFB driver (which creates a simple display pipe).
Signed-off-by: Robert Chiras <robert.chiras@nxp.com>
Robert Chiras [Thu, 19 Oct 2017 12:07:51 +0000 (15:07 +0300)]
MLK-16347-6: gpu: drm: bridge: adv7511: Add new compatible string
Added "adi,adv7535" to the adv7511 drm bridge and adi,adv7511.txt doc,
since the driver can also support the ADV7535 chipset (upgrade of ADV7533).
Signed-off-by: Robert Chiras <robert.chiras@nxp.com>
Robert Chiras [Fri, 14 Jul 2017 12:31:09 +0000 (15:31 +0300)]
MLK-16347-4: drm/imx: Add mipi-dsi driver for mx8
Add support for the NorthWest Logic MIPI-DSI controller found
in the following i.MX8 platforms: i.MX8qm, i.MX8qxp and i.MX8mq.
This is the MIPI-DSI encoder containing the platform specific changes
and it uses the NWL MIPI-DSI bridge.
Currently only qm and qxp are tested with this driver. The mq support
will be added later.
Signed-off-by: Robert Chiras <robert.chiras@nxp.com>
Robert Chiras [Wed, 27 Sep 2017 10:45:07 +0000 (13:45 +0300)]
MLK-16347-3: drm/bridge: Add Northwest Logic DSI transmitter support
Add support for the NorthWest Logit MIPI-DSI controller found in mx8
platforms: i.MX8qm, i.MX8qxp and i.MX8mq.
The NWL MIPI-DSI driver is implemented as a DRM bridge.
The MIPI-DSI encoder will contain the platform specific changes and will
use this bridge.
Signed-off-by: Robert Chiras <robert.chiras@nxp.com>
Robert Chiras [Fri, 14 Jul 2017 12:31:56 +0000 (15:31 +0300)]
MLK-16347-1: phy: add phy driver for mipi-dsi on mx8
Implement the DPHY from MIPI-DSI found on i.MX8 platforms (QM, QXP and MQ)
as a phy driver.
Signed-off-by: Robert Chiras <robert.chiras@nxp.com>
Richard Zhu [Fri, 22 Mar 2019 03:22:20 +0000 (11:22 +0800)]
MLK-21222 rpmsg: imx: fix kernel dump when initialize the vring memory
The fix had been contained in commit "
b7098fc4" MLK-16371-2 rpmsg: imx:
add the rpmsg for imx8qxp on imx_4.14.y branch.
But part of that patch is missed. Merge the solution back to imx_4.19.y
branch.
Use memset_io replace memset, because that the memory type of
rpvq->addr is strong order type. There would be kernel dump when memset
is used on imx8qxp.
Signed-off-by: Richard Zhu <hongxing.zhu@nxp.com>
Richard Zhu [Mon, 18 Mar 2019 05:10:09 +0000 (13:10 +0800)]
MLK-21167 rpmsg: imx: add the sync mechanism during partition reset
Remove the delay waiting, add the sync mechanism during partition reset.
In order to avoid the hang at master side during the rpmsg restore
procedure. Re-initialize the first_notify parameter, when rpmsg master
assumes remote processor is dead.
Otherwise, master side maybe hang during the rpmsg restore procedure
in some corner cases.
~14ms is required by M4 to process the MU message from the cold boot.
Set the max wait of MU_SendMessageTimeout to 20ms.
Signed-off-by: Richard Zhu <hongxing.zhu@nxp.com>
Reviewed-by: Robin Gong <yibin.gong@nxp.com>
(cherry picked from commit
6b5573a9c645b947688c171b2dbdb6b70b59356c)
Fugang Duan [Wed, 20 Mar 2019 07:06:58 +0000 (15:06 +0800)]
MLK-21194 rpmsg: imx_rpmsg: clear pending partition reboot irq status
Clear pending interrupt status of partition reboot during rpmsg
driver probe to avoid to unregister/register virtio device again.
Tested-by: Clark Wang <xiaoning.wang@nxp.com>
Reviewed-by: Richard Zhu <hongxing.zhu@nxp.com>
Signed-off-by: Fugang Duan <fugang.duan@nxp.com>
Clark Wang [Mon, 18 Feb 2019 08:58:32 +0000 (16:58 +0800)]
MLK-20940-2 rpmsg: adjust the order of rpmsg initialization
For the virtual i2c driver should be initialized in subsystem before the
other modules initialize. So, the imx_rpmsg and virtio_rpmsg_bus should
be initialized before virtual i2c driver. Now, use arch_initcall to
initialize these two modules.
Signed-off-by: Clark Wang <xiaoning.wang@nxp.com>
Robin Gong [Fri, 18 Jan 2019 09:58:49 +0000 (17:58 +0800)]
MLK-20790-2 rpmsg: imx_rpmsg: use unregister/register virtio device instead of rpmsg device
Currently, issue RPMSG_NS_DESTROY before kick off ready notification to
m4 to let m4 side go through all the stale message in vring buffer without
doing anything after m4 reset, that's not good enough. The better way is to
clear vring buffer after m4 reset, thus everything will be done as the
first time of kernel/m4 bootup. So unregister/register virtio device
instead of rpmsg device if m4 partition reset.
Signed-off-by: Robin Gong <yibin.gong@nxp.com>
Robin Gong [Fri, 18 Jan 2019 00:53:27 +0000 (08:53 +0800)]
MLK-20790-1: rpmsg: imx_rpmsg: dynamic allocate ivdev instead
Allocate ivdev dynamically instead of static, so that ivdev could
be re-initialized by kzalloc() such as 'struct virtio_device', otherwise,
the later patch that unregister/register virtio device instead of rpmsg
device will cause kernel complain such as 'kobject: tried to init an
initialized' and finally register virtio device failure after m4 partition
reset.
Signed-off-by: Robin Gong <yibin.gong@nxp.com>
Richard Zhu [Fri, 18 Jan 2019 07:51:46 +0000 (15:51 +0800)]
MLK-20776-2 RPMSG: imx: add the imx8mq rpmsg variant
Add the imx8mq/mm rpmsg variant in the driver.
No function changes.
Signed-off-by: Richard Zhu <hongxing.zhu@nxp.com>
Robin Gong [Thu, 10 Jan 2019 11:10:03 +0000 (19:10 +0800)]
MLK-20706 rpmsg: imx_rpmsg: fix building error on i.mx6/7 legancy chip
Fix building error caused by commit
c6cd4096c224f("MLK-20691-1:
rpmsg: imx_rpmsg: add new partition reset interrupt") because
of no scu functions on i.mx6sx/7d legancy chip.
Signed-off-by: Robin Gong <yibin.gong@nxp.com>
Acked-by: Richard Zhu <hongxing.zhu@nxp.com>
Robin Gong [Wed, 9 Jan 2019 14:59:01 +0000 (22:59 +0800)]
MLK-20691-3 rpmsg: imx_rpmsg: add partition reset support
unregister all rpmsg devices and kick off ready notifyication
again to restore back rpmsg communications after M4 partion
reset.
Signed-off-by: Robin Gong <yibin.gong@nxp.com>
Acked-by: Richard Zhu <hongxing.zhu@nxp.com>
Robin Gong [Tue, 8 Jan 2019 09:41:34 +0000 (17:41 +0800)]
MLK-20691-1: rpmsg: imx_rpmsg: add new partition reset interrupt
Add new partition reset interrupt group to know M4 reset and restore
back at rpmsg level later.
Signed-off-by: Robin Gong <yibin.gong@nxp.com>
Acked-by: Richard Zhu <hongxing.zhu@nxp.com>
Richard Zhu [Tue, 11 Dec 2018 01:44:31 +0000 (09:44 +0800)]
MLK-20637-2 rpmsg: imx: alloc share mem from per dev dma pool
- reserve one per dev dma pool, and alloc the share memory
from it.
Signed-off-by: Richard Zhu <hongxing.zhu@nxp.com>
Acked-by: Fugang Duan <fugang.duan@nxp.com>
Fugang Duan [Mon, 10 Dec 2018 11:34:24 +0000 (19:34 +0800)]
MLK-20653 rpmsg: virtio_rpmsg_bus: fix unexpected huge vmap mappings
If RPMSG dma memory allocate from per-device mem pool by calling .dma_alloc_coherent(),
the size is bigger than 2M bytes and alignment with 2M (PMD_SIZE), then kernel dump by
calling .vmalloc_to_page().
Since per-device dma pool do vmap mappings by __ioremap(), __ioremap() might use
the hugepage mapping, which in turn will cause the vmalloc_page failed to return
the correct page due to the PTE not setup.
For exp, when reserve 8M bytes per-device dma mem pool, __ioremap() will use hugepage
mapping:
__ioremap
ioremap_page_range
ioremap_pud_range
ioremap_pmd_range
pmd_set_huge(pmd, phys_addr + addr, prot)
Commit:
029c54b09599 ("mm/vmalloc.c: huge-vmap: fail gracefully on unexpected huge
vmap mapping") ensure that vmalloc_to_page() does not go off into the weeds trying
to dereference huge PUDs or PMDs as table entries:
rpmsg_sg_init ->
vmalloc_to_page->
WARN_ON_ONCE(pmd_bad(*pmd));
In generally, .dma_alloc_coherent() allocate memory from CMA pool/DMA pool/atomic_pool,
or swiotlb slabs pool, the virt address mapping to physical address should be lineal,
so for the rpmsg scatterlist initialization can use pfn to find the page to avoid to
call .vmalloc_to_page().
Kernel dump:
[ 0.881722] WARNING: CPU: 0 PID: 1 at mm/vmalloc.c:301 vmalloc_to_page+0xbc/0xc8
[ 0.889094] Modules linked in:
[ 0.892139] CPU: 0 PID: 1 Comm: swapper/0 Not tainted
4.14.78-05581-gc61a572 #206
[ 0.899604] Hardware name: Freescale i.MX8QM MEK (DT)
[ 0.904643] task:
ffff8008f6c98000 task.stack:
ffff000008068000
[ 0.910549] PC is at vmalloc_to_page+0xbc/0xc8
[ 0.914987] LR is at rpmsg_sg_init+0x70/0xcc
[ 0.919238] pc : [<
ffff0000081c80d4>] lr : [<
ffff000008ac471c>] pstate:
40000045
[ 0.926619] sp :
ffff00000806b8b0
[ 0.929923] x29:
ffff00000806b8b0 x28:
ffff00000961cdf0
[ 0.935220] x27:
ffff00000961cdf0 x26:
0000000000000000
[ 0.940519] x25:
0000000000040000 x24:
ffff00000961ce40
[ 0.945819] x23:
ffff00000f000000 x22:
ffff00000961ce30
[ 0.951118] x21:
0000000000000000 x20:
ffff00000806b950
[ 0.956417] x19:
0000000000000000 x18:
000000000000000e
[ 0.961717] x17:
0000000000000001 x16:
0000000000000019
[ 0.967016] x15:
0000000000000033 x14:
616d64202c303030
[ 0.972316] x13:
3030306630303030 x12:
3066666666206176
[ 0.977615] x11:
203a737265666675 x10:
62203334394c203a
[ 0.982914] x9 :
000000000000009f x8 :
ffff00000806b970
[ 0.988214] x7 :
0000000000000000 x6 :
ffff000009690712
[ 0.993513] x5 :
0000000000000000 x4 :
0000000080000000
[ 0.998812] x3 :
00e8000090800f0d x2 :
ffff8008ffffd3c0
[ 1.004112] x1 :
0000000000000000 x0 :
ffff00000f000000
[ 1.009416] Call trace:
[ 1.011849] Exception stack(0xffff00000806b770 to 0xffff00000806b8b0)
[ 1.018279] b760:
ffff00000f000000 0000000000000000
[ 1.026094] b780:
ffff8008ffffd3c0 00e8000090800f0d 0000000080000000 0000000000000000
[ 1.033915] b7a0:
ffff000009690712 0000000000000000 ffff00000806b970 000000000000009f
[ 1.041731] b7c0:
62203334394c203a 203a737265666675 3066666666206176 3030306630303030
[ 1.049550] b7e0:
616d64202c303030 0000000000000033 0000000000000019 0000000000000001
[ 1.057368] b800:
000000000000000e 0000000000000000 ffff00000806b950 0000000000000000
[ 1.065188] b820:
ffff00000961ce30 ffff00000f000000 ffff00000961ce40 0000000000040000
[ 1.073008] b840:
0000000000000000 ffff00000961cdf0 ffff00000961cdf0 ffff00000806b8b0
[ 1.080825] b860:
ffff000008ac471c ffff00000806b8b0 ffff0000081c80d4 0000000040000045
[ 1.088646] b880:
ffff0000092c8528 ffff00000806b890 ffffffffffffffff ffff000008ac4710
[ 1.096461] b8a0:
ffff00000806b8b0 ffff0000081c80d4
[ 1.101327] [<
ffff0000081c80d4>] vmalloc_to_page+0xbc/0xc8
[ 1.106800] [<
ffff000008ac4968>] rpmsg_probe+0x1f0/0x49c
[ 1.112107] [<
ffff00000859a9a0>] virtio_dev_probe+0x198/0x210
[ 1.117839] [<
ffff0000086a1c70>] driver_probe_device+0x220/0x2d4
[ 1.123829] [<
ffff0000086a1e90>] __device_attach_driver+0x98/0xc8
[ 1.129913] [<
ffff00000869fe7c>] bus_for_each_drv+0x54/0x94
[ 1.135470] [<
ffff0000086a1944>] __device_attach+0xc4/0x12c
[ 1.141029] [<
ffff0000086a1ed0>] device_initial_probe+0x10/0x18
[ 1.146937] [<
ffff0000086a0e48>] bus_probe_device+0x90/0x98
[ 1.152501] [<
ffff00000869ef88>] device_add+0x3f4/0x570
[ 1.157709] [<
ffff00000869f120>] device_register+0x1c/0x28
[ 1.163182] [<
ffff00000859a4f8>] register_virtio_device+0xb8/0x114
[ 1.169353] [<
ffff000008ac5e94>] imx_rpmsg_probe+0x3a0/0x5d0
[ 1.175003] [<
ffff0000086a3768>] platform_drv_probe+0x50/0xbc
[ 1.180730] [<
ffff0000086a1c70>] driver_probe_device+0x220/0x2d4
[ 1.186725] [<
ffff0000086a1dc8>] __driver_attach+0xa4/0xa8
[ 1.192199] [<
ffff00000869fdc4>] bus_for_each_dev+0x58/0x98
[ 1.197759] [<
ffff0000086a1598>] driver_attach+0x20/0x28
[ 1.203058] [<
ffff0000086a1114>] bus_add_driver+0x1c0/0x224
[ 1.208619] [<
ffff0000086a26ec>] driver_register+0x68/0x108
[ 1.214178] [<
ffff0000086a36ac>] __platform_driver_register+0x4c/0x54
[ 1.220614] [<
ffff0000093d14fc>] imx_rpmsg_init+0x1c/0x50
[ 1.225999] [<
ffff000008084144>] do_one_initcall+0x38/0x124
[ 1.231560] [<
ffff000009370d28>] kernel_init_freeable+0x18c/0x228
[ 1.237640] [<
ffff000008d51b60>] kernel_init+0x10/0x100
[ 1.242849] [<
ffff000008085348>] ret_from_fork+0x10/0x18
[ 1.248154] ---[ end trace
bcc95d4e07033434 ]---
Reviewed-by: Richard Zhu <hongxing.zhu@nxp.com>
Suggested-and-reviewed-by: Jason Liu <jason.hui.liu@nxp.com>
Signed-off-by: Fugang Duan <fugang.duan@nxp.com>
Robin Gong [Fri, 27 Oct 2017 02:04:23 +0000 (10:04 +0800)]
MLK-16704-3 ARM64: configs: defconfig: add imx8_wdt
Enable imx8_wdt driver by default.
Signed-off-by: Robin Gong <yibin.gong@nxp.com>
Reviewed-by: Anson Huang <Anson.Huang@nxp.com>
(cherry picked from commit
7d0c8ce50a9afd3a9319ee6449469953e0848927)
Robin Gong [Fri, 22 Feb 2019 10:43:35 +0000 (18:43 +0800)]
MLK-20965 watchdog: imx8_wdt: remove watchdog action set
The default watchdog action is partition reset now, so no need kernel
to take care. Besides, scfw full test case may set other watchdog
action but kernel may set it back later to default partition reset
which scfw wouldn't expect, so avoid touching watchdog action.
Please modify scfw code in case changing watchdog action to board
reset.
Signed-off-by: Robin Gong <yibin.gong@nxp.com>
Reviewed-by: Anson Huang <anson.huang@nxp.com>
(cherry picked from commit
d9189e251995cc91efcac62a8d1c59ff32cdb8dc)
(cherry picked from commit
13445b41c617042b309fb4cc5159a6d6ab9182fe)
Robin Gong [Mon, 14 Jan 2019 13:55:05 +0000 (21:55 +0800)]
MLK-20723 watchdog: imx8_wdt: enable partition reset for watchdog
Change to partiton reset instead of board reset since SCFW is ready
now.
Signed-off-by: Robin Gong <yibin.gong@nxp.com>
(cherry picked from commit
2a3fe06f582c85be1669a9231da5a8c51d2a37fe)
Robin Gong [Tue, 12 Dec 2017 06:33:14 +0000 (14:33 +0800)]
MLK-17154 watchdog: imx8_wdt: align timeout value with imx2_wdt
Align timeout value with imx2_wdt.
Signed-off-by: Robin Gong <yibin.gong@nxp.com>
(cherry picked from commit
6417e1a8039a16f7b1a76ea250237567ee3a72f5)
Robin Gong [Mon, 27 Nov 2017 03:12:42 +0000 (11:12 +0800)]
MLK-16988 watchdog: imx8_wdt: stop watchdog while suspend
Since watchdog on i.mx8 is a software watchdog in scfw side, it should be
stopped while kernel enter system suspend if watchdog fired. Otherwise,
unexpected watchdog reset will happen. Restore back if watchdog fired too.
Signed-off-by: Robin Gong <yibin.gong@nxp.com>
Reviewed-by: Anson Huang <Anson.Huang@nxp.com>
(cherry picked from commit
b77f789b470b61ab95a8c9fd0a01cebe1e342141)
Robin Gong [Tue, 14 Nov 2017 09:03:02 +0000 (17:03 +0800)]
MLK-16891 watchdog: imx8_wdt: add pre_timeout notification
Add pre_timeout set and notification for i.mx8qm/qxp.
BuildInfo:
- SCFW
36ff24f3, IMX-MKIMAGE
05d3d4a7, ATF
93dd1cc
- U-Boot
2017.03-00684-g28c5243
Signed-off-by: Robin Gong <yibin.gong@nxp.com>
Reviewed-by: Anson Huang <Anson.Huang@nxp.com>
(cherry picked from commit
28367d5317e0132483d93656731ab4b8ebf5a99a)
Robin Gong [Fri, 27 Oct 2017 01:40:30 +0000 (09:40 +0800)]
MLK-16704-1 watchdog: imx8_wdt: add watchdog driver for i.mx8QM/QXP
This watchdog driver is a virtual driver in Linux and call ATF interface
where call SCFW eventually. In SCFW, it's done by SCU timer tick instead
of hardware watchdog.This is why we have to call ATF because such system
resource owned by secure patition.Currently, booard reset happen if not
ping this software watchdog in time in linux side, may change to partition
reboot once SCFW support this feature in the future.
BuildInfo:
- SCFW
93c142a9, IMX-MKIMAGE
2522fd70, ATF
f2547fb
- U-Boot
2017.03-00097-gd7599cf
Signed-off-by: Robin Gong <yibin.gong@nxp.com>
Reviewed-by: Anson Huang <Anson.Huang@nxp.com>
(cherry picked from commit
3582decf35940566ed5eb43393c422315931f183)
Fugang Duan [Thu, 21 Mar 2019 06:28:36 +0000 (14:28 +0800)]
MLK-19580 net: fec: read MAC address from fuse
uboot fdt_fixup_ethernet() already add the "local-mac-address" property
for each net node when boot from net, the mac address read from fuse in
default. But for non-net boot or net is disabled in uboot, then kernel
also needs to read the MAC address from fuse. The patch add i.MX8MM platform
to read fuse from MAC in kernel in such case.
Reviewed-by: Richard Zhu <hongxing.zhu@nxp.com>
Signed-off-by: Fugang Duan <fugang.duan@nxp.com>
Fugang Duan [Thu, 21 Mar 2019 06:26:38 +0000 (14:26 +0800)]
MLK-16585 net: fec: fixup: correct i.MX8QXP MAC address fuse mapping
i.MX8QXP has different fuse address with i.MX8QM, correct i.MX8QXP
MAC fuse word address.
Signed-off-by: Fugang Duan <fugang.duan@nxp.com>
Fugang Duan [Thu, 21 Mar 2019 06:14:20 +0000 (14:14 +0800)]
MLK-21208 net: fec: add sleep mode support for i.MX8QM/QXP
commit
ae136b3cfe7c(MLK-18483-04 net: fec: close the mu ipc channel
when it is not used) merge part of code from commit
379ede4dfd95
(MLK-18483-02 net: fec: add sleep mode support for i.MX8QM/QXP),
but miss the commit.
So add the feature support for i.MX8QM/QXP by merge the commit
379ede4dfd95
(MLK-18483-02 net: fec: add sleep mode support for i.MX8QM/QXP)
Reviewed-by: Richard Zhu <hongxing.zhu@nxp.com>
Signed-off-by: Fugang Duan <fugang.duan@nxp.com>
Liu Ying [Thu, 21 Mar 2019 06:03:08 +0000 (14:03 +0800)]
MLK-21213-2 arm64: dts: fsl-imx8qm-lpddr4-arm2: Suppress DTC warnings related to LVDS
This patch suppresses DTC warnings which are related to LVDS as below:
Warning (graph_endpoint): /i2c@
57247000/lvds-to-hdmi-bridge@4c/port/endpoint:
graph connection to node '/ldb@
572410e0/lvds-channel@0/port@1/endpoint'
is not bidirectional
Signed-off-by: Liu Ying <victor.liu@nxp.com>
Liu Ying [Thu, 21 Mar 2019 06:01:11 +0000 (14:01 +0800)]
MLK-21213-1 arm64: dts: fsl-imx8qm/qxp-mek: Suppress DTC warnings related to LVDS
This patch suppresses DTC warnings which are related to LVDS like below:
Warning (graph_endpoint): /i2c@
57247000/lvds-to-hdmi-bridge@4c/port/endpoint:
graph connection to node '/ldb@
572410e0/lvds-channel@0/port@1/endpoint'
is not bidirectional
Signed-off-by: Liu Ying <victor.liu@nxp.com>
Liu Ying [Thu, 21 Mar 2019 05:52:00 +0000 (13:52 +0800)]
MLK-21123-2 arm64: fsl-imx8dx.dtsi: Correct DPU endpoint names
This patch corrects DPU endpoint names to suppress DTC warnings like below:
Warning (graph_endpoint): /dpu@
56180000/port@0/lvds0-endpoint: graph endpont node name should be 'endpoint'
Warning (graph_endpoint): /dpu@
56180000/port@0/lvds1-endpoint: graph endpont node name should be 'endpoint'
Warning (graph_endpoint): /dpu@
56180000/port@0/mipi-dsi-endpoint: graph endpont node name should be 'endpoint'
Warning (graph_endpoint): /dpu@
56180000/port@1/lvds0-endpoint: graph endpont node name should be 'endpoint'
Warning (graph_endpoint): /dpu@
56180000/port@1/lvds1-endpoint: graph endpont node name should be 'endpoint'
Warning (graph_endpoint): /dpu@
56180000/port@1/mipi-dsi-endpoint: graph endpont node name should be 'endpoint'
Signed-off-by: Liu Ying <victor.liu@nxp.com>
Liu Ying [Thu, 21 Mar 2019 05:43:15 +0000 (13:43 +0800)]
MLK-21123-1 arm64: fsl-imx8qm-device.dtsi: Correct DPU endpoint names
This patch corrects DPU endpoint names to suppress DTC warnings like below:
Warning (graph_endpoint): /dpu@
56180000/port@0/hdmi-endpoint: graph endpont node name should be 'endpoint'
Warning (graph_endpoint): /dpu@
56180000/port@0/mipi-dsi-endpoint: graph endpont node name should be 'endpoint'
Warning (graph_endpoint): /dpu@
56180000/port@1/lvds0-endpoint: graph endpont node name should be 'endpoint'
Warning (graph_endpoint): /dpu@
56180000/port@1/lvds1-endpoint: graph endpont node name should be 'endpoint'
Warning (graph_endpoint): /dpu@
57180000/port@0/mipi-dsi-endpoint: graph endpont node name should be 'endpoint'
Warning (graph_endpoint): /dpu@
57180000/port@1/lvds0-endpoint: graph endpont node name should be 'endpoint'
Warning (graph_endpoint): /dpu@
57180000/port@1/lvds1-endpoint: graph endpont node name should be 'endpoint'
Signed-off-by: Liu Ying <victor.liu@nxp.com>
Laurentiu Palcu [Tue, 19 Mar 2019 13:19:10 +0000 (15:19 +0200)]
MLK-21190 arm64: dts: imx8mq: fix DTS warnings
This patch fixes the folowing DTS warnings:
Warning (graph_endpoint): /dcss@0x32e00000/port@0/hdmi-endpoint: graph endpont node name should be 'endpoint'
Warning (graph_endpoint): /dcss@0x32e00000/port@0/mipi_dsi: graph endpont node name should be 'endpoint'
Warning (graph_endpoint): /lcdif@
30320000/port@0/mipi-dsi-endpoint: graph endpont node name should be 'endpoint'
Warning (graph_endpoint): /mipi_csi1@
30a70000/port/endpoint1: graph endpont node name should be 'endpoint'
Warning (graph_endpoint): /mipi_csi1@
30a70000/port/endpoint2: graph endpont node name should be 'endpoint'
Warning (graph_endpoint): /mipi_csi2@
30b60000/port/endpoint1: graph endpont node name should be 'endpoint'
Warning (graph_endpoint): /mipi_csi2@
30b60000/port/endpoint2: graph endpont node name should be 'endpoint'
Warning (interrupts_property): /dcss@0x32e00000:#interrupt-cells: size is (64), expected multiple of 12
Signed-off-by: Laurentiu Palcu <laurentiu.palcu@nxp.com>
Viorel Suman [Tue, 19 Mar 2019 09:37:28 +0000 (11:37 +0200)]
MLK-21113 ASoC: ak4458: replace codec API with component API
Replace codec API with recent component API.
Signed-off-by: Viorel Suman <viorel.suman@nxp.com>
Anson Huang [Fri, 4 May 2018 10:29:45 +0000 (18:29 +0800)]
MLK-18205-14 cpufreq: imx8mq: add pmic voltage scaling support
i.MX8MM shares same cpu-freq driver with i.MX8MQ, but
its EVK board has a PMIC which can scale VDD_ARM voltage
according to voltage defined in dtb, add support for it.
Signed-off-by: Anson Huang <Anson.Huang@nxp.com>
Reviewed-by: Bai Ping <ping.bai@nxp.com>
(cherry picked from commit
bb958ff65e9caeaddf180e66482c3013bb8fae67)
Anson Huang [Fri, 27 Oct 2017 15:40:15 +0000 (23:40 +0800)]
MLK-16710 cpufreq: imx8mq: avoid duplicated OPP table initialization
On i.MX8MQ, since the OPP table is initialized in cpu-freq platform
device register according to chip type, so no need to redo the OPP
table initialization in cpu-freq driver, this patch adds check for
OPP table initialization to avoid below warning during boot up:
[ 1.468378] cpu cpu0: _opp_add: duplicate OPPs detected. Existing: freq: 1501
[ 1.468388] cpu cpu0: _opp_add: duplicate OPPs detected. Existing: freq: 1301
[ 1.468417] cpu cpu0: _of_add_opp_table_v1: Failed to add OPP
1300000000
[ 1.468425] cpu cpu0: _opp_add: duplicate OPPs detected. Existing: freq: 1001
[ 1.468434] cpu cpu0: _opp_add: duplicate OPPs detected. Existing: freq: 8001
[ 1.468443] cpu cpu0: _of_add_opp_table_v1: Failed to add OPP
800000000
Signed-off-by: Anson Huang <Anson.Huang@nxp.com>
Reviewed-by: Bai Ping <ping.bai@nxp.com>
(cherry picked from commit
ae4cd299d229b8debe8223a1569ffef42b938f6a)
Anson Huang [Fri, 25 Aug 2017 05:06:24 +0000 (13:06 +0800)]
MLK-16165-2 cpufreq: imx8mq: remove non-necessary opp table initialization
For i.MX8MQ, suspend freq can use policy->max after cpu freq
table is validated, so no need to get OPP number and MAX
frequency for suspend freq now, also add necessary resource free
when probe failed.
Signed-off-by: Anson Huang <Anson.Huang@nxp.com>
(cherry picked from commit
5542b5a931eaac90ae38624700cdfca723a08073)
Anson Huang [Wed, 2 Aug 2017 06:39:18 +0000 (14:39 +0800)]
MLK-16121-1 cpufreq: imx8mq: add gpio regulator support
i.MX8MQ can run at over-drive mode which needs
increasing VDD_ARM voltage, add gpio regulator support
for over-drive mode.
Signed-off-by: Anson Huang <Anson.Huang@nxp.com>
(cherry picked from commit
86f48a3c4b9558454d82cea732d53348e37ef574)
Anson Huang [Mon, 18 Sep 2017 04:41:40 +0000 (12:41 +0800)]
MLK-16477 cpufreq: imx8: switch cpufreq governor to schedutil for multi-cluster
For multi-cluster platforms like i.MX8QM, the best cpufreq
governor is schedutil, as common cpufreq framework decides
default cpufreq governor in static compile, so this patch
adds dynamic switch of cpufreq governor according to cluster
number, changing it via sysfs interface, although it is
ugly, but it realizes dynamic cpufreq governor select for
users.
Signed-off-by: Anson Huang <Anson.Huang@nxp.com>
(cherry picked from commit
88c5933f17117451e7eb10242ca903624e86a9ff)
Anson Huang [Tue, 5 Sep 2017 09:31:43 +0000 (17:31 +0800)]
MLK-16372-2 cpufreq: imx8: add cpu-freq cooling support
Register cpu-freq cooling device if device tree
supports cooling-cells, different cluster can
have its own cooling device settings.
Signed-off-by: Anson Huang <Anson.Huang@nxp.com>
(cherry picked from commit
12fe2995aa5034d8119fd82be5247f655552d5df)
Anson Huang [Fri, 28 Jul 2017 02:30:35 +0000 (10:30 +0800)]
MLK-16093-3 cpufreq: imx8mq: add cooling device support
Add i.MX8MQ cooling device support, when temperature
exceeds passive threshold, cpu-freq will drop to lowest
set-point, and once temperature drops below passive
threshold, cpu-freq will restore.
Signed-off-by: Anson Huang <Anson.Huang@nxp.com>
(cherry picked from commit
463d125f15f111a364db1e2f1cf816a7fd1e9597)
Anson Huang [Wed, 5 Jul 2017 08:05:33 +0000 (16:05 +0800)]
MLK-15342-4 arm64: defconfig: enable i.mx8mq cpufreq support
Enable CONFIG_ARM_IMX8MQ_CPUFREQ by default.
Signed-off-by: Anson Huang <Anson.Huang@nxp.com>
(cherry picked from commit
207a30c915365d74ffdb0144df6be6600273ca14)
Anson Huang [Wed, 5 Jul 2017 08:00:22 +0000 (16:00 +0800)]
MLK-15342-3 cpufreq: add i.mx8mq support
Add i.MX8MQ cpufreq support, current version of
EVK board does NOT support voltage scale, but next
version will add this support, so this driver only
supports cpu frequency scale, voltage scale will
be added later once new board available.
A53 CPU clock normally is from ARM_PLL, but during
ARM_PLL relock window, it will be switched to
SYS1_PLL_800M to avoid clock missing, and after
arm pll relock done, it will be switched back.
Signed-off-by: Anson Huang <Anson.Huang@nxp.com>
(cherry picked from commit
83f79d713471aece5a08397f1917c90935da994a)
Anson Huang [Fri, 25 Aug 2017 05:03:23 +0000 (13:03 +0800)]
MLK-16165-1 cpufreq: imx8: remove non-necessary opp table initialization
For i.MX8QM/8QXP, suspend freq can use policy->max after cpu
freq table is validated, so no need to get OPP number and MAX
frequency for suspend freq now, also add necessary resource free
when probe failed.
Signed-off-by: Anson Huang <Anson.Huang@nxp.com>
(cherry picked from commit
d1096697124beb82bea739b66c3bff11c498868f)
Anson Huang [Wed, 23 Aug 2017 05:00:47 +0000 (13:00 +0800)]
MLK-16244-2 cpufreq: imx8: add SIP cpu-freq support
Add SIP cpu-freq support, the CPU hardware frequency
scale will be performed by ARM Trusted Firmware,
and add cpu-freq suspend support, MAX frequency will
be used during suspend.
Signed-off-by: Anson Huang <Anson.Huang@nxp.com>
(cherry picked from commit
665a985c8103ae2e1f6417cca3ae62e50a6681c7)
Conflicts:
include/soc/imx/fsl_sip.h
Anson Huang [Tue, 28 Mar 2017 16:10:50 +0000 (00:10 +0800)]
MLK-14534-3 arm64: defconfig: enable i.MX8 cpufreq
Enable i.MX8 cpu-freq by default for defconfig.
Signed-off-by: Anson Huang <Anson.Huang@nxp.com>
(cherry picked from commit
263d6fa34177707b03456c75556ba0ce30d600b0)
Anson Huang [Tue, 28 Mar 2017 16:07:57 +0000 (00:07 +0800)]
MLK-14534-1 cpufreq: imx8: add cpu-freq support
Add multi-clusters cpu-freq driver support for i.MX8,
only support cpu-freq get now.
Signed-off-by: Anson Huang <Anson.Huang@nxp.com>
(cherry picked from commit
636ede1c1443f20b2d664e7cdfcd617176f60a2d)
Jacky Bai [Thu, 28 Feb 2019 07:03:20 +0000 (15:03 +0800)]
MLK-21102 driver: thermal: fix the tmu out of range issue on imx8mm
Per design team's feadback, the 'V' bit is NOT very safe enough for
checking the validation of the temp value. So just check if the
temp value is in the sensor's valid measurment range.
Signed-off-by: Jacky Bai <ping.bai@nxp.com>
Reviewed-by: Anson Huang <Anson.Huang@nxp.com>
(cherry picked from commit
324525467aac8bdea6bb5e9ac83149b3a194369e)
Bai Ping [Thu, 21 Jun 2018 02:30:32 +0000 (10:30 +0800)]
MLK-18428-04 ARM64: config: enable imx8mm thermal driver by default.
enable the i.MX8MM thermal driver by default.
Signed-off-by: Bai Ping <ping.bai@nxp.com>
Reviewed-by: Anson Huang <Anson.Huang@nxp.com>
(cherry picked from commit
37ca0ee7ed59af640dec383e68ab66e4c4199ffd)
Bai Ping [Mon, 25 Jun 2018 05:50:12 +0000 (13:50 +0800)]
MLK-18428-02 doc: binding: Add binding doc for imx8mm tmu
Add dts binding doc for i.MX8MM TMU.
Signed-off-by: Bai Ping <ping.bai@nxp.com>
Reviewed-by: Anson Huang <Anson.Huang@nxp.com>
(cherry picked from commit
6fd7255a0e73a28dda83e0574b62a264449d04e5)
Bai Ping [Mon, 11 Jun 2018 08:45:50 +0000 (16:45 +0800)]
MLK-18428-01 driver: thermal: add tmu driver on imx8mm
add thermal driver on i.MX8MM
Signed-off-by: Bai Ping <ping.bai@nxp.com>
Reviewed-by: Anson Huang <Anson.Huang@nxp.com>
(cherry picked from commit
719cb8604dd253ec9484a39a40251f49e5300752)
Vipul Kumar [Wed, 20 Mar 2019 06:54:56 +0000 (12:24 +0530)]
ARM: dts: imx6ull: add gpio-ranges property to iMX GPIO controllers
As per 'commit
bb728d662bed ("ARM: dts: add gpio-ranges property to iMX
GPIO controllers")', added gpio-ranges property for imx6ULL board.
Signed-off-by: Vipul Kumar <vipul_kumar@mentor.com>
Vipul Kumar [Wed, 20 Mar 2019 06:51:10 +0000 (12:21 +0530)]
ARM: dts: imx6ull: add GPIO clocks
As per 'commit
bc36b2aac4f5 ("ARM: dts: imx6ul: add GPIO clocks")'
i.MX6ULL has GPIO clock gates in CCM CCGR, add
clock property for GPIO driver to make sure all
GPIO banks work as expected.
Signed-off-by: Vipul Kumar <vipul_kumar@mentor.com>