summaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2018-03-28apalis-tk1: handle backlight in the device treeApalis-TK1_LXDE-Image_2.8b2.97-20180331toradex_tk1_l4t_r21.6Dominik Sliwa
Signed-off-by: Dominik Sliwa <dominik.sliwa@toradex.com> Acked-by: Marcel Ziswiler <marcel.ziswiler@toradex.com>
2018-03-28pwm-backlight: Add optional enable GPIOThierry Reding
To support a wider variety of backlight setups, introduce an optional enable GPIO. Legacy users of the platform data already have a means of supporting GPIOs by using the .init(), .exit() and .notify() hooks. DT users however cannot use those, so an alternative method is required. In order to ease the introduction of the optional enable GPIO, make it available in the platform data first, so that existing users can be converted. Once that has happened a second patch will add code to make use of it in the driver. Signed-off-by: Thierry Reding <treding@nvidia.com> (cherry picked from commit 2b9b1620349e325f184c68cddf3b484499c163c0)
2018-03-28pwm-backlight: Disable backlight on shutdownThierry Reding
When a device is shut down, make sure to disable the backlight. If it stays lit, it gives the impression that the device hasn't turned off. Furthermore keeping the backlight on may consume power, which is not what users expect when they shut down a device. Tested-by: Stephen Warren <swarren@nvidia.com> Signed-off-by: Thierry Reding <treding@nvidia.com> (cherry picked from commit 5f33b896246a2d9bdf01352de11d4dab96ba2fc9)
2018-03-28backlight: pwm_bl: Remove error message upon devm_kzalloc() failureFabio Estevam
No need to have a specific OOM message, since there is generic MM out of memory message in place. Signed-off-by: Fabio Estevam <fabio.estevam@freescale.com> Signed-off-by: Thierry Reding <thierry.reding@gmail.com> (cherry picked from commit ca7a97add4d4a7b0602b3bd1eff5c89da8636713)
2018-03-28pwm-backlight: Remove unused variableThierry Reding
I forgot to remove this during earlier cleanup patches and only checked various builds for errors, not warnings. Reported-by: kbuild test robot <fengguang.wu@intel.com> Signed-off-by: Thierry Reding <thierry.reding@gmail.com> (cherry picked from commit 73d4e2b82b4bb1571b1a7f97012c0db8a0faef42)
2018-03-28pwm_backlight: avoid short blank screen while doing hibernationHuayi Li
Use SIMPLE_DEV_PM_OPS macro will initialize the member "freeze" and "thaw" of pwm_backlight_pm_ops as below, .freeze = suspend_fn, .thaw = resume_fn, then during the process of making hibernation snapshot, screen will be blank at the moment of freezing, and then light at the moment of thawing. this is not the right user experience for suspending to disk. so this patch drops freeze and thaw callback, make the LCD is always lighting before the final shutdown. Signed-off-by: Huayi Li <huayi.li@csr.com> Signed-off-by: Barry Song <Baohua.Song@csr.com> Signed-off-by: Thierry Reding <thierry.reding@gmail.com> (cherry picked from commit 1dea1fd09246ada581a99d0669108eea94b7bfee)
2018-03-28pwm-backlight: Fix brightness adjustmentThierry Reding
Split adjustment of the brightness (by changing the PWM duty cycle) from the power on sequence. This fixes an issue where the brightness can no longer be updated once the backlight has been enabled. Reported-by: Marc Dietrich <marvin24@gmx.de> Signed-off-by: Thierry Reding <treding@nvidia.com> (cherry picked from commit e4bfeda96872bfe6015cd360008b77cd3b981b2b)
2018-03-28pwm-backlight: Allow for non-increasing brightness levelsMike Dunn
Currently the driver assumes that the values specified in the brightness-levels device tree property increase as they are parsed from left to right. But boards that invert the signal between the PWM output and the backlight will need to specify decreasing brightness-levels. This patch removes the assumption that the last element of the array is the maximum value, and instead searches the array for the maximum value and uses that in the duty cycle calculation. Signed-off-by: Mike Dunn <mikedunn@newsguy.com> Signed-off-by: Thierry Reding <treding@nvidia.com> (cherry picked from commit 8f43e18e2769b3b28383903d501b4da29e388aad)
2018-03-28pwm-backlight: Add power supply supportThierry Reding
Backlights require a power supply to work properly. This commit adds a regulator to power up and power down the backlight. Signed-off-by: Thierry Reding <treding@nvidia.com> (cherry picked from commit 22ceeee16eb8f0d04de3ef43a5174fb30ec18af9)
2018-03-28pwm-backlight: Use new enable_gpio fieldThierry Reding
Make use of the new enable_gpio field and allow it to be set from DT as well. Now that all legacy users of platform data have been converted to initialize this field to an invalid value, it is safe to use the field from the driver. Signed-off-by: Thierry Reding <treding@nvidia.com> (cherry picked from commit 8265b2e4e62632b01f998095d1bbda4d281629fe)
2018-03-28pwm-backlight: Track enable stateThierry Reding
Follow up patches will add support for more complex means of powering the backlight on and off such as using a regulator. To prevent calls to the regulator API from becoming unbalanced, keep track of the enabled state internally. Signed-off-by: Thierry Reding <treding@nvidia.com> (cherry picked from commit 97c38437115aa0c3fb2d50c488814b503ba529e0)
2018-03-28pwm-backlight: Refactor backlight power on/offThierry Reding
In preparation for adding an optional regulator and enable GPIO to the driver, split the power on and power off sequences into separate functions to reduce code duplication at the multiple call sites. Signed-off-by: Thierry Reding <treding@nvidia.com> (cherry picked from commit 62b744a87c1170b339f993aa3cfb22465974816a)
2018-03-28pwm-backlight: Improve readabilityThierry Reding
Add more blank lines to increase readability. While at it, remove a trailing blank line at the end of the file. Signed-off-by: Thierry Reding <treding@nvidia.com> (cherry picked from commit 668e63c6701d486c68b49ffffc0e5b7de1a2e95c)
2018-03-28backlight: use dev_get_platdata()Jingoo Han
Use the wrapper function for retrieving the platform data instead of accessing dev->platform_data directly. This is a cosmetic change to make the code simpler and enhance the readability. Signed-off-by: Jingoo Han <jg1.han@samsung.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> (cherry picked from commit c512794cada491e008eeca822af7e4ad5db72a56)
2018-03-28Revert "video: backlight: pwm_bl: add pwm_gpio"Dominik Sliwa
This reverts commit 95730406a0e3bbd7f862718782924a3c367845a1.
2018-03-28Revert "video: backlight: EDP client for backlight"Dominik Sliwa
This reverts commit 74df06fb565b7250bc86d79727b66bb02259d54c.
2018-03-28Revert "EDP: remove old system EDP framework (pwm backlight driver)"Dominik Sliwa
This reverts commit 08a13bacb43f206239ae0f1ccbe37325993e2b1b.
2018-03-28Revert "backlight: pwm: Converting benign message to info"Dominik Sliwa
This reverts commit 153a5d54d1a10c5a35f6923e0c6423430d2c7c89.
2018-03-28mfd: apalis-tk1-k20: separate common header fileDominik Sliwa
Both firmware and kernel are using the same set of constants in a header file, this patch separates them in to a single file. That way it will be easier to track changes to FW or kernel. Signed-off-by: Dominik Sliwa <dominik.sliwa@toradex.com> Acked-by: Marcel Ziswiler <marcel.ziswiler@toradex.com>
2018-03-28apalis-tk1: add atmel mxt-ts to device-treesDominik Sliwa
Signed-off-by: Dominik Sliwa <dominik.sliwa@toradex.com> Acked-by: Marcel Ziswiler <marcel.ziswiler@toradex.com>
2018-03-28input: atmel_mxt_ts: support reset gpio lineDominik Sliwa
Signed-off-by: Dominik Sliwa <dominik.sliwa@toradex.com> Acked-by: Marcel Ziswiler <marcel.ziswiler@toradex.com>
2018-03-28apalis-tk1: add atmel mxt to defconfigDominik Sliwa
Signed-off-by: Dominik Sliwa <dominik.sliwa@toradex.com> Acked-by: Marcel Ziswiler <marcel.ziswiler@toradex.com>
2018-03-28input: touchscreen: atmel_mxt_ts: backport from kernel 4.9Dominik Sliwa
Signed-off-by: Dominik Sliwa <dominik.sliwa@toradex.com> Acked-by: Marcel Ziswiler <marcel.ziswiler@toradex.com>
2018-03-28apalis-tk1: remove platform dc initializationDominik Sliwa
DC initialization now relays only on device-tree entry. Signed-off-by: Dominik Sliwa <dominik.sliwa@toradex.com> Acked-by: Marcel Ziswiler <marcel.ziswiler@toradex.com>
2018-03-28apalis-tk1:lvds: add option to select 24-bit lvds modeDominik Sliwa
Add ability to switch between 24.1 and 24.0 lvds modes. Mode description can be found in "Using 24-bpp LVDS Panels with IntelĀ® Mobile Chipsets for Embedded Applications". Signed-off-by: Dominik Sliwa <dominik.sliwa@toradex.com> Acked-by: Marcel Ziswiler <marcel.ziswiler@toradex.com>
2018-03-28apalis-tk1: move display configuration to device-treeDominik Sliwa
Signed-off-by: Dominik Sliwa <dominik.sliwa@toradex.com> Acked-by: Marcel Ziswiler <marcel.ziswiler@toradex.com>
2018-03-28can: mfd: apalis-tk1: v1.1 frequency adjustments and various fixesDominik Sliwa
Signed-off-by: Dominik Sliwa <dominik.sliwa@toradex.com> Acked-by: Marcel Ziswiler <marcel.ziswiler@toradex.com>
2018-03-28mfd: apalis-tk1-k20: single transaction register readDominik Sliwa
This change also modifies SPI clock for ezPort mode. Signed-off-by: Dominik Sliwa <dominik.sliwa@toradex.com> Acked-by: Marcel Ziswiler <marcel.ziswiler@toradex.com>
2018-03-28can: mfd: apalis-tk1-k20:increased clock speed, zero copyDominik Sliwa
Increased SPI speed for transfers and peripheral speed. Switch to cleaning IRQ flags on read, instead of separate write. Switched to zero-copy on SPI reads. Signed-off-by: Dominik Sliwa <dominik.sliwa@toradex.com> Acked-by: Marcel Ziswiler <marcel.ziswiler@toradex.com>
2017-12-22apalis-tk1: fix wake on lan functionalityApalis-TK1_LXDE-Image_2.8b1.64-20171229Dominik Sliwa
GPIO used for WOL is briefly used in i210 reset procedure. This patch makes sure it's freed and can be used for a wakeup source. Signed-off-by: Dominik Sliwa <dominik.sliwa@toradex.com> Acked-by: Marcel Ziswiler <marcel.ziswiler@toradex.com>
2017-12-21perf tools: define _DEFAULT_SOURCE for glibc_2.20Chanho Park
_BSD_SOURCE was deprecated in favour of _DEFAULT_SOURCE since glibc 2.20[1]. To avoid build warning on glibc2.20, _DEFAULT_SOURCE should also be defined. [1]: https://sourceware.org/glibc/wiki/Release/2.20 Signed-off-by: Chanho Park <chanho61.park@samsung.com> Cc: Ingo Molnar <mingo@kernel.org> Cc: Paul Mackerras <paulus@samba.org> Cc: Peter Zijlstra <a.p.zijlstra@chello.nl> Link: http://lkml.kernel.org/r/1410487817-13403-1-git-send-email-chanho61.park@samsung.com Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> (cherry picked from commit 512fe365373b9c95a70b4b6357503ee74d27214f)
2017-12-21apalis-tk1_defconfig: enable user debugStefan Agner
Let the kernel print some debug messages when a user program crashes due to an exception. Signed-off-by: Stefan Agner <stefan.agner@toradex.com> Acked-by: Marcel Ziswiler <marcel.ziswiler@toradex.com>
2017-11-29tegra: align graphics drivers with android binariesApalis-TK1_LXDE-Image_2.7b5-20171201Dominik Sliwa
Some functionality used by android binary drivers were missing. Signed-off-by: Dominik Sliwa <dominik.sliwa@toradex.com> Acked-by: Marcel Ziswiler <marcel.ziswiler@toradex.com>
2017-11-29mfd: apalis-tk1: 0.11 fw supportDominik Sliwa
Signed-off-by: Dominik Sliwa <dominik.sliwa@toradex.com> Acked-by: Marcel Ziswiler <marcel.ziswiler@toradex.com>
2017-11-29mmc: Allow forward compatibility for eMMCRomain Izard
As stated by the eMMC 5.0 specification, a chip should not be rejected only because of the revision stated in the EXT_CSD_REV field of the EXT_CSD register. Remove the control on this value, the control of the CSD_STRUCTURE field should be sufficient to reject future incompatible changes. Signed-off-by: Romain Izard <romain.izard.pro@gmail.com> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> (cherry picked from commit 03a59437ef6b6ad7fb0165cb9b96c08d6bf057fc)
2017-11-29Merge tag 'tegra-l4t-r21.6' into toradex_tk1_l4t_r21.6Marcel Ziswiler
Merge NVIDIA's latest Linux for Tegra aka L4T R21.6 Linux kernel changes from git://nv-tegra.nvidia.com/linux-3.10.git commit: b271e8fa67a6d9c4600274a25636cfe00fdd1b68 Signed-off-by: Marcel Ziswiler <marcel.ziswiler@toradex.com> Acked-by: Dominik Sliwa <dominik.sliwa@toradex.com>
2017-11-29Revert "spi-tegra114: Warning when clock rate switch fails"Marcel Ziswiler
This reverts commit 8fdf8dc5afdb02625084356ebd7c0d1c7494a00e. Signed-off-by: Marcel Ziswiler <marcel.ziswiler@toradex.com> Acked-by: Dominik Sliwa <dominik.sliwa@toradex.com>
2017-11-29Revert "mmc: Allow forward compatibility for eMMC"Marcel Ziswiler
This reverts commit 0293e897d740cc7991c82567aab5dee0e66294fd. Signed-off-by: Marcel Ziswiler <marcel.ziswiler@toradex.com> Acked-by: Dominik Sliwa <dominik.sliwa@toradex.com>
2017-11-29media: ov5640: major driver cleanuptoradex_tk1_l4t_r21.5Peter Gielda
Signed-off-by: Peter Gielda <pgielda@antmicro.com> Acked-by: Marcel Ziswiler <marcel.ziswiler@toradex.com>
2017-10-17ARM: tegra: apalis-tk1: use high vil/vih receivers for ddcDominik Sliwa
DDC/EDID detection was failing on Apalis TK1 V1.2A on Ixora. Signed-off-by: Dominik Sliwa <dominik.sliwa@toradex.com> Acked-by: Marcel Ziswiler <marcel.ziswiler@toradex.com>
2017-10-06mfd: apalis-tk1-k20: clean-up and fix support for 0.10 k20 fwApalis-TK1_LXDE-Image_2.7b4-20171007Dominik Sliwa
Signed-off-by: Dominik Sliwa <dominik.sliwa@toradex.com> Acked-by: Marcel Ziswiler <marcel.ziswiler@toradex.com>
2017-10-05ARM: tegra: apalis-tk1: annotate and fix gpio configurationMarcel Ziswiler
Signed-off-by: Marcel Ziswiler <marcel.ziswiler@toradex.com> Acked-by: Dominik Sliwa <dominik.sliwa@toradex.com>
2017-10-05mfd: apalis-tk1-k20: support for 0.10 k20 fwDominik Sliwa
Signed-off-by: Dominik Sliwa <dominik.sliwa@toradex.com> Acked-by: Marcel Ziswiler <marcel.ziswiler@toradex.com>
2017-10-05ARM: tegra: apalis-tk1: move hdmi ddc config to dtDominik Sliwa
We moved HDMI DDC configuration to the device-tree. If DDC config is missing from the device-tree we default to v1.2 config. Signed-off-by: Dominik Sliwa <dominik.sliwa@toradex.com> Acked-by: Marcel Ziswiler <marcel.ziswiler@toradex.com>
2017-10-03ARM: tegra: apalis-tk1: support v1.2 hardware revisionMarcel Ziswiler
Support the V1.2 hardware revision with the following pin muxing changes: Ddc_scl_pv4 and ddc_sda_pv5 previously used as Apalis GPIO3 and GPIO4 are now used as DDC pins. Gen2_i2c_scl_pt5 and gen2_i2c_sda_pt6 previously used as DDC pins are now used as USB power enable signals. Usb_vbus_en0_pn4 and usb_vbus_en1_pn5 previously used as USB power enable signals are now used as GPIO3 and GPIO4. Signed-off-by: Marcel Ziswiler <marcel.ziswiler@toradex.com> Acked-by: Dominik Sliwa <dominik.sliwa@toradex.com>
2017-10-03ARM: dts: tegra124: update model and compatibility nodesMarcel Ziswiler
Update model and compatibility nodes to be more in-line with mainline. Signed-off-by: Marcel Ziswiler <marcel.ziswiler@toradex.com> Acked-by: Dominik Sliwa <dominik.sliwa@toradex.com>
2017-10-03pinctrl: tegra: clean-upMarcel Ziswiler
Cosmetic clean-up to bring it more in-line with mainline driver in order to be able to easily assess whether it is all kosher. Signed-off-by: Marcel Ziswiler <marcel.ziswiler@toradex.com> Acked-by: Dominik Sliwa <dominik.sliwa@toradex.com>
2017-10-03Bluetooth: Properly check L2CAP config option output buffer lengthtegra-l4t-r21.6Ben Seri
Validate the output buffer length for L2CAP config requests and responses to avoid overflowing the stack buffer used for building the option blocks. Bug 1989825 Change-Id: Id158ece2176c4ac339a7232dfde8c47ce2241122 Cc: stable@vger.kernel.org Signed-off-by: Ben Seri <ben@armis.com> Signed-off-by: Marcel Holtmann <marcel@holtmann.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> Signed-off-by: Bibek Basu <bbasu@nvidia.com> Reviewed-on: https://git-master.nvidia.com/r/1558952 (cherry picked from commit c005032a3ffe77437f6ebc704af377fc9bc46279) Reviewed-on: https://git-master.nvidia.com/r/1570529 Reviewed-by: Matthew Pedro <mapedro@nvidia.com> Reviewed-by: Winnie Hsu <whsu@nvidia.com> Tested-by: Winnie Hsu <whsu@nvidia.com>
2017-09-27ARM: tegra: Select appropriate DMA options for LPAEPaul Kocialkowski
This automatically selects options for zone DMA and 64 bit DMA addresses when LPAE is enabled on ARM Tegra platforms. These options are required for proper operation with LPAE enabled. The ZONE_DMA option is required to ensure that drivers that allocate DMA memory get buffers from the first 4 GiB. This is necessary because a lot of the controllers only support addressing 32 bits. As for ARCH_DMA_ADDR_T_64BIT, there are situations where devices that do support addresses of more than 32 bits (such as the display controller or the GPU) can run without translating addresses through an IOMMU on a device with more than 4 GiB of system memory. Note that both of these options are stop-gap solutions required only until the IOMMU can be properly integrated with the DMA mapping API and drivers use that properly and consistently. Signed-off-by: Paul Kocialkowski <contact@paulk.fr> [treding@nvidia.com: specify rationale for options] Signed-off-by: Thierry Reding <treding@nvidia.com> (backported from commit 6aa26c5d66595494e810c791602d87a572c78808)
2017-09-20dp.c: fix compilation with gcc 7Max Krummenacher
With gcc 7 the following compile time error occurs: | drivers/video/tegra/dc/dp.c:1178:12: error: the omitted middle operand in ?: will always be 'true', suggest explicit middle operand [-Werror=parentheses] | cr_done ? : ({ret = -EINVAL; goto fail; }); | ^ | drivers/video/tegra/dc/dp.c:1186:12: error: the omitted middle operand in ?: will always be 'true', suggest explicit middle operand [-Werror=parentheses] | lt_done ? : ({ret = -EINVAL; goto fail; }); | ^ Signed-off-by: Max Krummenacher <max.krummenacher@toradex.com> Acked-by: Marcel Ziswiler <marcel.ziswiler@toradex.com>