summaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2018-01-30apalis-imx8qm: adopt device tree for Apalis iMX8QMStefan Agner
Initial changes for Apalis iMX8QM. LVDS dual-channel full-HD panel seems to work, HDMI seems to output signals but display are not able to sync on the signal (or only after a long time, displaying everything in a weired binned mode). Signed-off-by: Stefan Agner <stefan.agner@toradex.com>
2018-01-30apalis-imx8qm: add initial device treeStefan Agner
Currently a copy of fsl-imx8qm-lpddr4-arm2.dts to set boot UART to LPUART1 and make Ethernet and SDHC work. Signed-off-by: Stefan Agner <stefan.agner@toradex.com>
2018-01-24MLK-17453 arm64: dts: increase i2c pad drive strengthGao Pan
Too many i2c slaves are conencted to imx8qm i2c0 and imx8qxp lpi2c1. So i2c pad drive strength should be increased. Otherwise, there will be i2c probe error. Reported-by: Andy Tian <yang.tian@nxp.com> Tested-by: Andy Tian <yang.tian@nxp.com> Signed-off-by: Gao Pan <pandy.gao@nxp.com> Acked-by: Fugang Duan <fugang.duan@nxp.com> (cherry picked from commit d2189329b9b97bf339e8b8889ca603fa8b74838f)
2018-01-15MLK-17371 gpu: imx: dpu: framegen: Use better timeout value to wait for ENSTSLiu Ying
The DPU spec tells us that we need to wait for all pending frames to be completed when a display stream is disabled. It turns out that the hardcoded 60-microsecond timeout value is not enough for some low refresh rate video modes, e.g., 1920x1080@24, which makes the display stream be disabled incorrectly(leave the hardware an incorrect machine status). The SoC design indicates that there are two pending frames to complete in the worst case. This patch waits for at most three frame duration(which is enough for sure) so that the hardware may flush out all the pending frames. In case the clock subsystem provides us a pixel clock with wrong rate and causes the timeout value be unreasonably long, we truncate it to wait for at most three seconds. Signed-off-by: Liu Ying <victor.liu@nxp.com> (cherry picked from commit 2c3a75e38a58add5e781ae41ce447b24c2ddc238)
2018-01-12MLK-17369: soc:imx8qm/qxp: Add controls for display controller resetsOliver Brown
" commit cfdb9821531da523fd1f01536eb67c8b8451477f Author: Oliver Brown <oliver.brown@nxp.com> Date: Tue Jan 2 07:46:06 2018 -0600 dc: Add controls for display controller resets. " Signed-off-by: Oliver Brown <oliver.brown@nxp.com>
2018-01-12MLK-17367 imx8: pm-domains: fix restore parent for clk_stat_may_lost caseDong Aisheng
imx8_rsrc_clk->parent may be cleared during last probe failure. So we need explicitly call CLK APIs clk_get_parent to get the cached parent for the later restore. Otherwise, it may reparent to NULL parent which results in 0 clk rate. Fixes: 05caa1390f88cb (" MLK-17363-1 imx8: pm-domain: fix clock parent restore issue after suspend/resume") Reviewed-by: Anson Huang <anson.huang@nxp.com> Signed-off-by: Dong Aisheng <aisheng.dong@nxp.com> (cherry picked from commit 66a5d4f35dd43bd7c14779b7dbcf368667c2b241)
2018-01-11MLK-17363-2 imx8: pm-domain: clocks list should be initialized only once.Ranjani Vaidyanathan
The clocks list associated with a PD is the same across all devices attached to the same PD. Re-initializing it each time a new device is attached results in missing some clocks. [ Aisheng: "Improve commit message" ] Reviewed-by: Anson Huang <anson.huang@nxp.com> Signed-off-by: Dong Aisheng <aisheng.dong@nxp.com> Signed-off-by: Ranjani Vaidyanathan <Ranjani.Vaidyanathan@nxp.com> (cherry picked from commit 1944f7ec5714345aeb4735cdeb3c9adf74b61fbe)
2018-01-11MLK-17363-1 imx8: pm-domain: fix clock parent restore issue after suspend/resumeRanjani Vaidyanathan
Currently the clock parent actually is failed to be restored in power domain driver due to the set_parent will bail out early as the clk core already cached the same old parent. Implement a CLK_SET_PARENT_NOCACHE flag in clk core and register all SC mux clocks with this flag to make sure the clk core won't bypass the SC clock parent setting. [ Aisheng: "Add commit message" ] Reviewed-by: Anson Huang <anson.huang@nxp.com> Signed-off-by: Dong Aisheng <aisheng.dong@nxp.com> Signed-off-by: Ranjani Vaidyanathan <Ranjani.Vaidyanathan@nxp.com> (cherry picked from commit 459b9d4dfb898b0df1614f5021fdeb3b7154fc06)
2018-01-11MGS-3565 [#ccc] fix coverity issue 1477294Yuchou Gan
unmap_attachment to free the sg_table when failed to call _DmabufAttach Date: Jan 10, 2018 Signed-off-by: Yuchou Gan<yuchou.gan@nxp.com>
2018-01-08MLK-17341-6: dts: update mipi csi i2c power domain nameSandor Yu
Update mipi csi i2c power domain name. Acked-by: Fugang Duan <fugang.duan@nxp.com> Signed-off-by: Sandor Yu <Sandor.yu@nxp.com> (cherry picked from commit 4fcda6c5394b47aa75a68e2cc7a910b93274cee3)
2018-01-08MLK-17341-5: imx8x: Rename imx8 mipi csi i2c power domainSandor Yu
Rename imx8x mipi csi i2c power domain. Acked-by: Fugang Duan <fugang.duan@nxp.com> Signed-off-by: Sandor Yu <Sandor.yu@nxp.com> (cherry picked from commit 39a0b3822eae9f59e221d472c97374849e67ed45)
2018-01-08MLK-17341-4: clk: Rename mipi csi i2c power domain nameSandor Yu
rename mipi csi i2c power domain name Acked-by: Fugang Duan <fugang.duan@nxp.com> Signed-off-by: Sandor Yu <Sandor.yu@nxp.com> (cherry picked from commit 0ca19e1af2ed25a7ae463bc96b340565913804d4)
2018-01-08MLK-17341-3: dts: Add power up pin for imx8qxpSandor Yu
Add gpio0_mipi_csi0 propriety. Add power up pin for max9286. Acked-by: Fugang Duan <fugang.duan@nxp.com> Signed-off-by: Sandor Yu <Sandor.yu@nxp.com> (cherry picked from commit 958a57ee24c59e7ddcd5b7c5590008ab4c318be1)
2018-01-08MLK-17341-2: dts: Add mipi csi gpio proprietySandor Yu
Add mipi csi0/csi1 GPIO propriety. Add pinctrl setting for mipi_csi0/1 GPIO. Add power up pin for max9286. Acked-by: Fugang Duan <fugang.duan@nxp.com> Signed-off-by: Sandor Yu <Sandor.yu@nxp.com> (cherry picked from commit 81b66e6955fe602fb18ff5f879163d5a12593a43)
2018-01-08MLK-17341-1: max9286: Add power up pin settingSandor Yu
Add power up pin setting for max9286 driver. Acked-by: Fugang Duan <fugang.duan@nxp.com> Signed-off-by: Sandor Yu <Sandor.yu@nxp.com> (cherry picked from commit 3e1fee31a6fc31783c1ab68db1e1aed5ef3db994)
2018-01-08MLK-17290-06 arm64: dts: gpio: add mipi csi SS gpio clock and power domainFugang Duan
GPIO in MIPI CSI SS also has its related ipg clock and power domain, add them. Signed-off-by: Fugang Duan <fugang.duan@nxp.com> Tested-by: Guoniu.Zhou <guoniu.zhou@nxp.com> Reviewed-by: Frank Li <Frank.Li@nxp.com> (cherry picked from commit: d920f718832fad5090ed08d2aeef7db6fe968f1c)
2018-01-08MLK-17290-05 gpio: mxc: save and restore gpio controller registers when ↵Fugang Duan
power off Save gpio controller registers before power off, and then restore these registers after power on. There have two cases need to save/restore regs: a. If sub_irqs/sub_gpios are not free/released, device suspend() force runtime suspend and power domain off in suspended stage, it needs to keep the previous registers value after device resume back. b. If some sub_irqs set irq type just one time, then irqchip should restore the registers for correct irq type. Signed-off-by: Fugang Duan <fugang.duan@nxp.com> Tested-by: Guoniu.Zhou <guoniu.zhou@nxp.com> Reviewed-by: Frank Li <Frank.Li@nxp.com> (cherry picked from commit: 764ebc90db18fe6f98bd77921050529ca6dd183e)
2018-01-08MLK-17290-04 gpio: mxc: add runtime pm supportFugang Duan
Add runtime pm support to automatically enable the ipg clock and power domain if present. To save power, suggest all sub-devices of the gpiochip/irq domain should dynamically manage gpio/irq resouces like: gpio: gpiod_request() ... //set gpio direction gpiod_free() irq: devm_request_irq() //=> module active devm_free_irq() //=>module is non-active or runtime idle Since the driver support irqchip and gpiochip, any irq/gpio resouce requested by other modules the gpio controller clock and power domain should be enabled. And the irqchip's parent's clock and power also should be enabled if irq resouce requested. Signed-off-by: Fugang Duan <fugang.duan@nxp.com> Tested-by: Guoniu.Zhou <guoniu.zhou@nxp.com> Reviewed-by: Frank Li <Frank.Li@nxp.com> (cherry picked from commit: 89d5032d5bb34c343147be1d88a0bd2c5901fe10)
2018-01-08MLK-17290-03 drm/bridge: request/free irq in dynamicalFugang Duan
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> (cherry picked from commit: 1ddd124d5e3c361a567e3da4f22d041cade28d92)
2018-01-08MLK-17290-02 i2c: imx-lpi2c: manage irq resource request/release in runtime pmFugang Duan
Manage irq resource request/release in runtime pm to save irq domain's power. Signed-off-by: Frank Li <Frank.Li@nxp.com> Signed-off-by: Fugang Duan <fugang.duan@nxp.com> Tested-by: Guoniu.Zhou <guoniu.zhou@nxp.com> Reviewed-by: Frank Li <Frank.Li@nxp.com> (cherry picked from commit: 8ddf940f9073ee8503fda3395527de82ee1247cb)
2018-01-08MLK-17290-01 irqchip: imx-irqsteer: add runtime pm supportFugang Duan
Add runtime pm to manage irqsteer clock and its power domain in system idle and suspend status to save power. Signed-off-by: Fugang Duan <fugang.duan@nxp.com> Signed-off-by: Frank Li <Frank.Li@nxp.com> Tested-by: Guoniu.Zhou <guoniu.zhou@nxp.com> Reviewed-by: Frank Li <Frank.Li@nxp.com> (cherry picked from commit: 63440c6888863eee207e8475ee98b61ed3b3a4ee)
2018-01-05MLK-17344-2: ARM64: dts: add constraint-rate for hdmi of imx8qmShengjiu Wang
In imx8qm the hdmi audio sound is breaking from time to time, the reason is that the DPLL jitter issue cause that HDMI can't lock this clock internally, that some audio data is dropped. It is hardware issue, here we add software workaround. We tried two method: 1. Changed Audio PLL setting to use non-fractional multiplier (768MHz=24MHz*32). This setting is significantly improving HDMI Audio but audio is still breaking from time to time. 2. Generated HDMI TX audio clock from external audio codec (24MHz clock => SLSlice[0] => MCLKOUT => External CODEC ref clock to PLL => ESAI Audio clock => loopback to HDMI TX SAI => HDMI TX). HDMI TX audio is clear. The second method depends on external codec, for we want to keep the independence of driver, so we use the method 1. For method 1, we need to set a dedicate rate for HDMI, we use the AUDIO_PLL1, but which is conflict with AMIX, so we disable AMIX in hdmi dts and only support 48kHz for HDMI audio Signed-off-by: Shengjiu Wang <shengjiu.wang@nxp.com>
2018-01-05MLK-17344-1: ASoC: imx-cdnhdmi: get constraint rate from dtsShengjiu Wang
Constraint rate depends on the clock rata of cpu dai, which is defined in dts, so we add constraint-rate property in dts, then driver can get it. Signed-off-by: Shengjiu Wang <shengjiu.wang@nxp.com>
2018-01-05MLK-17309-4: ASoC: fsl_hifi: fix crash issue when destination not alignWeiguang Kong
When loading the codec libs in driver, if the destination is not 4-bytes alignment when doing memset_hifi(), the driver will print a warning message and the driver may crash in some cases. So by changing the memset() function and aligning the virtual address based on the physical address to fix this issue. Signed-off-by: Weiguang Kong <weiguang.kong@nxp.com> (cherry picked from commit 13823532730ae6e1a0c098d97df98a0cfece8cff)
2018-01-05MLK-17309-3: ASoC: fsl_hifi: get free memory from hifi frameworkWeiguang Kong
In order to manage the memory simply, all the memory which is shared between hifi driver and hifi framework are managed by hifi framework. So when the driver wants to get free memory, it can send "ICM_PI_LIB_MEM_ALLOC" command to hifi framework, then hifi framework will return the address of available memory to driver. When the driver wants to release the memory, it can send "ICM_PI_LIB_MEM_FREE" command to hifi framework, the hifi framework will mark this memory available. Signed-off-by: Weiguang Kong <weiguang.kong@nxp.com> (cherry picked from commit 57f63a615cc95399df25cef11382845a3037c37e)
2018-01-05MLK-17309-2: ASoC: fsl_hifi: use new way to realize multi-codecWeiguang Kong
In current hifi driver, some resources are shared when multi codec decodes together. When switching between multi-codec, the hifi driver and framework need to save and restore the shared resources,this will waster time and complicate the hifi driver. So by distributing private resources for each codec to avoid this problem. When the user space wants to enable a new codec, it can send "HIFI4_CLIENT_REGISTER" command to hifi driver to apply an available resource, the driver will send a client id to user space. When the user space wants to release the resource, it can send "HIFI4_CLIENT_UNREGISTER" command to hifi driver, then the driver will mark this resource available. Signed-off-by: Weiguang Kong <weiguang.kong@nxp.com> (cherry picked from commit b6cf72cb084389d953e1bc0b22ba735b7f973673)
2018-01-05MLK-17309-1: uapi: mxc_hifi4: provide new interface for user spaceWeiguang Kong
In order to avoid license problem of Cadence header files, these license files has been wrappered into a library and new interface has been abstracted to replace the interface of Cadence header files. So update the mxc_hifi4.h file to provide new interface for user space to use. Signed-off-by: Weiguang Kong <weiguang.kong@nxp.com> (cherry picked from commit 3e2339222795581905bf9a376a61b7b1482ca318)
2018-01-04MLK-17258 ARM64: dts: add off-on-delay for usdhc vmmc-supply regulatorHaibo Chen
For the slot support SD3.0 card, during system suspend, if plug out the sd card, and insert another SD3.0 card, after system resume back, SD3.0 card can't be recognized as SD3.0 card, just SD2.0 card. This is because the time delay between vmmc regulator off and on is too small. SD spec require the Card Vdd shall be lowered to less than 0.5v for a minimum period for 1ms. And the hardware regulator also need some time to drop the Card Vdd from 3.3v to 0.5v. This patch add the off-on-delay in vmmc-supply regulator adding the upper two limitation into consideration. This patch relay on the commit 878bff7648f5 ("MLK-14638-1 regulator: fixed: add off_on_delay support"). Signed-off-by: Haibo Chen <haibo.chen@nxp.com> (cherry picked from commit b67c9ddc377918e493a4e67348e5c8c978ef34a9)
2018-01-04MLK-17334: imx8: pm-domains: fix array overflow issueShengjiu Wang
When the resource id is larger than 512, the wakeup_rsrc_id array will overflow, then the resource may always power on. So align the IRQ with resource number to fix the issue. Signed-off-by: Shengjiu Wang <shengjiu.wang@nxp.com> Reviewed-by: Anson Huang <Anson.Huang@nxp.com> (cherry picked from commit 06338d83d7becbc537aece291558bba18a3fdd87)
2018-01-03drm/drm_lease: Prevent deadlock in case drm_lease_create() failsMarius Vlad
This case can been seen when creating the lease with the same objects passed. [ 605.515097] 2 locks held by testapp/3337: [ 605.519027] #0: (&dev->mode_config.idr_mutex){......}, at: [<ffff0000085f1664>] drm_mode_create_lease_ioctl+0x384/0x858 [ 605.530045] #1: (&dev->mode_config.idr_mutex){......}, at: [<ffff0000085f11bc>] drm_lease_destroy+0x2c/0x110 Which was causing the process to hang: [ 605.398827] [<ffff0000080856cc>] __switch_to+0x94/0xa8 [ 605.404030] [<ffff000008c05d00>] __schedule+0x1b0/0x698 [ 605.409322] [<ffff000008c06224>] schedule+0x3c/0xa8 [ 605.414260] [<ffff000008c06628>] schedule_preempt_disabled+0x20/0x38 [ 605.420677] [<ffff000008c07370>] mutex_lock_nested+0x158/0x340 [ 605.426572] [<ffff0000085f11bc>] drm_lease_destroy+0x2c/0x110 [ 605.432389] [<ffff0000085cecf0>] drm_master_put+0xc0/0xc8 [ 605.437845] [<ffff0000085f175c>] drm_mode_create_lease_ioctl+0x47c/0x858 [ 605.444612] [<ffff0000085d4460>] drm_ioctl+0x198/0x448 [ 605.449811] [<ffff000008201134>] do_vfs_ioctl+0xa4/0x748 [ 605.455192] [<ffff000008201864>] SyS_ioctl+0x8c/0xa0 [ 605.460216] [<ffff000008082f4c>] __sys_trace_return+0x0/0x4 drm_mode_create_lease_ioctl() calls drm_lease_create() which acquires a lock on dev->mode_config.idr_mutex. In case of failure, drm_lease_create() calls drm_master_put() which in turn tries to acquire the same lock when calling drm_lease_destroy(). v2: - Reverse the order at exit in case of fail, so that unlocking takes place before dropping the reference. - Include detail information about deadlock (Daniel Vetter) Signed-off-by: Marius Vlad <marius-cristian.vlad@nxp.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: https://patchwork.freedesktop.org/patch/msgid/20171213181048.32719-1-marius-cristian.vlad@nxp.com (cherry-picked from 63f1a8ab58f8c85c48b7cec74fb84b7190a)
2018-01-03MLK-17243 drm/imx: dpu: plane: Add format modifiersLiu Ying
This patch adds format modifiers for DPU DRM planes. Signed-off-by: Liu Ying <victor.liu@nxp.com> (cherry picked from commit a3a342a8e856821e468e9b87cb1345c4123ad977)
2018-01-03drm: Shift wrap bug in create_in_format_blob()Dan Carpenter
"plane->format_count" can go up to 64. (It's capped in drm_universal_plane_init().) So we should be using ULL type instead of int here to prevent shift wrapping. Fixes: db1689aa61bd ("drm: Create a format/modifier blob") Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Signed-off-by: Sean Paul <seanpaul@chromium.org> Link: https://patchwork.freedesktop.org/patch/msgid/20170809111906.4rv3hzritctfktv3@mwanda (cherry picked from commit aadd41485bb227a16f964833a4fd55c091f4a729) (cherry picked from commit c725195e791e2b8411e8d5d202f8fd208c8f330e)
2018-01-03drm: Create a format/modifier blobBen Widawsky
Updated blob layout (Rob, Daniel, Kristian, xerpi) v2: * Removed __packed, and alignment (.+) * Fix indent in drm_format_modifier fields (Liviu) * Remove duplicated modifier > 64 check (Liviu) * Change comment about modifier (Liviu) * Remove arguments to blob creation, use plane instead (Liviu) * Fix data types (Ben) * Make the blob part of uapi (Daniel) v3: Remove unused ret field. Change i, and j to unsigned int (Emil) v4: Use plane->modifier_count instead of recounting (Daniel) v5: Rename modifiers to modifiers_property (Ville) Use sizeof(__u32) instead to reflect UAPI nature (Ville) Make BUILD_BUG_ON for blob header size Cc: Rob Clark <robdclark@gmail.com> Cc: Kristian H. Kristensen <hoegsberg@gmail.com> Signed-off-by: Ben Widawsky <ben@bwidawsk.net> Reviewed-by: Daniel Stone <daniels@collabora.com> (v2) Reviewed-by: Liviu Dudau <liviu@dudau.co.uk> (v2) Reviewed-by: Emil Velikov <emil.l.velikov@gmail.com> (v3) Signed-off-by: Daniel Stone <daniels@collabora.com> Link: http://patchwork.freedesktop.org/patch/msgid/20170724034641.13369-2-ben@bwidawsk.net (cherry picked from commit db1689aa61bd1efb5ce9b896e7aa860a85b7f1b6) Conflicts: drivers/gpu/drm/drm_crtc.c drivers/gpu/drm/drm_mode_config.c include/drm/drm_crtc.h include/drm/drm_mode_config.h (cherry picked from commit 1f049ba9f8fad22d7fe0d1a895c1ffe9e73dc3f4)
2018-01-03drm: Plumb modifiers through plane initBen Widawsky
This is the plumbing for supporting fb modifiers on planes. Modifiers have already been introduced to some extent, but this series will extend this to allow querying modifiers per plane. Based on this, the client to enable optimal modifications for framebuffers. This patch simply allows the DRM drivers to initialize their list of supported modifiers upon initializing the plane. v2: A minor addition from Daniel v3: * Updated commit message * s/INVALID/DRM_FORMAT_MOD_INVALID (Liviu) * Remove some excess newlines (Liviu) * Update comment for > 64 modifiers (Liviu) v4: Minor comment adjustments (Liviu) v5: Some new platforms added due to rebase v6: Add some missed plane inits (or maybe they're new - who knows at this point) (Daniel) Signed-off-by: Ben Widawsky <ben@bwidawsk.net> Reviewed-by: Daniel Stone <daniels@collabora.com> (v2) Reviewed-by: Liviu Dudau <Liviu.Dudau@arm.com> Signed-off-by: Daniel Stone <daniels@collabora.com> (cherry picked from commit e6fc3b68558e4c6d8d160b5daf2511b99afa8814) Conflicts: drivers/gpu/drm/hisilicon/hibmc/hibmc_drm_de.c drivers/gpu/drm/imx/dcss/dcss-plane.c drivers/gpu/drm/imx/dpu/dpu-plane.c drivers/gpu/drm/imx/ipuv3-plane.c drivers/gpu/drm/imx/ipuv3/ipuv3-plane.c drivers/gpu/drm/meson/meson_plane.c drivers/gpu/drm/msm/mdp/mdp5/mdp5_plane.c drivers/gpu/drm/mxsfb/mxsfb_drv.c drivers/gpu/drm/nouveau/nv50_display.c drivers/gpu/drm/omapdrm/omap_plane.c drivers/gpu/drm/pl111/pl111_display.c drivers/gpu/drm/qxl/qxl_display.c drivers/gpu/drm/stm/ltdc.c drivers/gpu/drm/sun4i/sun8i_layer.c drivers/gpu/drm/tinydrm/core/tinydrm-pipe.c drivers/gpu/drm/vmwgfx/vmwgfx_ldu.c drivers/gpu/drm/vmwgfx/vmwgfx_scrn.c drivers/gpu/drm/vmwgfx/vmwgfx_stdu.c drivers/gpu/drm/zte/zx_plane.c include/drm/drm_plane.h (cherry picked from commit b2f03f6dc168e37b7ea8a99fceb3f4ac2bd37f4e)
2018-01-03drm: fix possible_crtc's typeTomi Valkeinen
drm_universal_plane_init() and drm_plane_init() take "unsigned long possible_crtcs" parameter, but then stuff it into uint32_t. Change the parameter to uint32_t. Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com> Cc: Ville Syrjälä <ville.syrjala@linux.intel.com> Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Reviewed-by: Ville Syrjälä <ville.syrjala@linux.intel.com> (cherry picked from commit 5cd57a46e3e3dc088b50bbfcdc85d9e0d9c22159) (cherry picked from commit a932f61ce6cf9951809e3faf05f2b006eb8cd99e)
2018-01-03drm_fourcc: Fix DRM_FORMAT_MOD_LINEAR #defineKristian H. Kristensen
We need to define DRM_FORMAT_MOD_VENDOR_NONE for the fourcc_mod_code() macro to work correctly. Signed-off-by: Kristian H. Kristensen <hoegsberg@google.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1481657272-25975-1-git-send-email-hoegsberg@google.com (cherry picked from commit af913418261d6d3e7a29f06cf35f04610ead667c) (cherry picked from commit dcfeb43c820109fbe438d406e089383803af1af1)
2018-01-03drm_fourcc: Document linear modifierDaniel Vetter
Not setting the fb modifiers flag is something different from setting the fb modifiers to 0 (which means explicitly linear). We kinda failed to document that properly. Spotted by Kristian. Cc: hoegsberg@google.com Reviewed-by: Kristian H. Kristensen <hoegsberg@google.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1478694996-4200-1-git-send-email-daniel.vetter@ffwll.ch (cherry picked from commit b9fb2a21ac8058965a6b3fcae736cfa7f411d6eb) (cherry picked from commit f9c59801c36c0c887a9d76704f0028afa7c01273)
2018-01-02net: fec: unmap the xmit buffer that are not transferred by DMAFugang Duan
The enet IP only support 32 bit, it will use swiotlb buffer to do dma mapping when xmit buffer DMA memory address is bigger than 4G in i.MX platform. After stress suspend/resume test, it will print out: log: [12826.352864] fec 5b040000.ethernet: swiotlb buffer is full (sz: 191 bytes) [12826.359676] DMA: Out of SW-IOMMU space for 191 bytes at device 5b040000.ethernet [12826.367110] fec 5b040000.ethernet eth0: Tx DMA memory map failed The issue is that the ready xmit buffers that are dma mapped but DMA still don't copy them into fifo, once MAC restart, these DMA buffers are not unmapped. So it should check the dma mapping buffer and unmap them. Signed-off-by: Fugang Duan <fugang.duan@nxp.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2017-12-30MA-10617 [#imx-836] Fix CtsMediaTestCases module test uncompleted issueRichard Liu
CtsMediaTestCases module CTS test can't uncompleted due to native crash, the crash is due to memory leak in drm gralloc, when total leak reach to 4GB it will report mmap fail and cause CTS thread crash. Crash log: 12-02 08:14:51.982 1156 25401 E gralloc-viv: gralloc_vivante_lock#573: failed to mmap 12-02 08:14:51.982 1156 25401 E gralloc-viv: gralloc_lock#136: err=-25 12-02 08:14:51.982 1156 25401 E gralloc : gralloc_lock lock memory failed 12-02 08:14:51.982 1156 25401 W GraphicBufferMapper: lock(0xed4c2740, ...) failed: 5 12-02 08:14:51.982 1156 25401 F SoftwareRenderer: frameworks/av/media/libstagefright/ colorconversion/SoftwareRenderer.cpp:230 CHECK_EQ( 0,mapper.lock( buf->handle, GRALLOC_USAGE_SW_WRITE_OFTEN, bounds, &dst)) failed: 0 vs. 5 Dec. 20, 2017 Signed-off-by: Richard Liu <xuegang.liu@nxp.com> (cherry picked from commit d9fc48e209ae3df97fb2570fbaf49cc40677f74b)
2017-12-28drm: Pass CRTC ID in userspace vblank eventsAnder Conselvan de Oliveira
With the atomic API, it is possible that a single commit affects multiple crtcs. If the user requests an event with that commit, one event will be sent for each CRTC, but it is not possible to distinguish which crtc an event is for in user space. To solve this, the reserved field in struct drm_vblank_event is repurposed to include the crtc_id which the event is for. The DRM_CAP_CRTC_IN_VBLANK_EVENT is added to allow userspace to query if the crtc field will be set properly. [daniels: Rebased, using Maarten's forward-port.] Signed-off-by: Ander Conselvan de Oliveira <ander.conselvan.de.oliveira@intel.com> Signed-off-by: Daniel Stone <daniels@collabora.com> Cc: Maarten Lankhorst <maarten.lankhorst@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/20170404165221.28240-2-daniels@collabora.com
2017-12-27MGS-3536 [#imx-858] [8QM/qxp] fix the gles cts fail issue.Yuchou Gan
This issue is introduced by MGS-2914. Temporarily enable the depth compression so that wouldn't block the release. And find the root cause and fix the issue later. Date: Dec 26, 2017 Signed-off-by Yuchou Gan yuchou.gan@nxp.com
2017-12-26MGS-3531 [#imx-865] fix gpu kernel panic issueXianzhong
it is reproduced easily with multiple es11 cts tests, gpu kernel panic in function _ConvertLogical2Physical. need remove mdl from global list before destroy map list, this can prevent the wrong access on the freed map data. Date: Dec 22, 2017 Signed-off-by: Xianzhong <xianzhong.li@nxp.com> (cherry picked from commit df426f1f2b662bfd3615356d831c9da3004d15b6)
2017-12-26MLK-17204-3 gpu: imx: dpu: Free command buffer when deinitMeng Mingming
Free command buffer when deinit. Signed-off-by: Meng Mingming <mingming.meng@nxp.com> (cherry picked from commit f3c7d7b02d29b1bb6c8a47a742605548783fc7d6)
2017-12-21MLK-17261-2 usb: chipidea: imx: do not call hsic callback for non-hsic ↵Peter Chen
controller With this judgement, the non-hsic controller will access wrong registers, and below error message will be showed: "usbmisc_imx 2184800.usbmisc: index is error for usbmisc" Fixes: 113be1516160 ("MLK-16715-6 usb: chipidea: imx: add HSIC support for controllers from imx7d") Reported-by: Peng Fan <peng.fan@nxp.com> Acked-by: Jun Li <jun.li@nxp.com> Signed-off-by: Peter Chen <peter.chen@nxp.com>
2017-12-21MLK-17261-1 usb: cdns3: gadget: fix the spinlock recursion problem when ↵Peter Chen
detach cable The __cdns3_gadget_stop holds spinlock before calling usb_ss->gadget_driver->disconnect which calls ep_disable, and ep_disable tries to hold spinlock too. To fix it, let spinlock only protect the variable and register access. Acked-by: Jun Li <jun.li@nxp.com> Signed-off-by: Peter Chen <peter.chen@nxp.com>
2017-12-20MLK-17204-2 drm/imx: dpu: Set driver data as null when to unbind deviceMeng Mingming
Set driver data as null when to unbind device. Signed-off-by: Meng Mingming <mingming.meng@nxp.com> (cherry picked from commit 70f70fad106200b55f3a417c7c76130711690b4f)
2017-12-20MA-10829-2: add compat ioctl for malone vpuZhou Peng-B04994
Fix the ioctl issue of VPU_IOC_WAIT4INT Signed-off-by: Zhou Peng-B04994 <eagle.zhou@nxp.com> (cherry picked from commit 94cfc1f46c55d3d4e092d22f7eb5db15e25aa270)
2017-12-20MA-10829: add compat ioctl for malone vpuZhou Peng-B04994
Define 32bit ioctl for Android platform Signed-off-by: Zhou Peng-B04994 <eagle.zhou@nxp.com> (cherry picked from commit a6d8406328554533cfc156d154ec179ffe60bdd7)
2017-12-19MLK-17088: mipi_csi: improve the compatiblility of S_FMTGuoniu.Zhou
1) When app call S_FMT ioctl, they may only set width, height and format of image. So driver can't determine whether it support the specified format by checking the format fourcc value and the plane number. 2) Driver should also fill plane and sizeimage member in S_FMT ioctl, because some apps use this information after they call S_FMT ioctl, such as gstreamer. Reviewed-by: Sandor.Yu <sandor.yu@nxp.com> Signed-off-by: Guoniu.Zhou <guoniu.zhou@nxp.com> (cherry picked from commit 876bcc402f0192b6540d1503cd31aa90401c3ff4)
2017-12-18MLK-17206 hdp: Disable firmware hdp loadingOliver Brown
Disabling HDP firmware loading except for debug. Added simple checks to test HDP firmware status. Signed-off-by: Oliver Brown <oliver.brown@nxp.com>