summaryrefslogtreecommitdiffstats
path: root/drivers/media/platform/tegra-cec
Commit message (Collapse)AuthorAgeFilesLines
* treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 201Thomas Gleixner2019-05-302-24/+2Star
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | Based on 1 normalized pattern(s): this program is free software you can redistribute it and or modify it under the terms and conditions of the gnu general public license version 2 as published by the free software foundation this program is distributed in the hope it will be useful but without any warranty without even the implied warranty of merchantability or fitness for a particular purpose see the gnu general public license for more details you should have received a copy of the gnu general public license along with this program if not see http www gnu org licenses extracted by the scancode license scanner the SPDX license identifier GPL-2.0-only has been chosen to replace the boilerplate/reference in 228 file(s). Signed-off-by: Thomas Gleixner <tglx@linutronix.de> Reviewed-by: Allison Randal <allison@lohutok.net> Reviewed-by: Steve Winslow <swinslow@gmail.com> Reviewed-by: Richard Fontana <rfontana@redhat.com> Reviewed-by: Alexios Zavras <alexios.zavras@intel.com> Cc: linux-spdx@vger.kernel.org Link: https://lkml.kernel.org/r/20190528171438.107155473@linutronix.de Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* treewide: Add SPDX license identifier - Makefile/KconfigThomas Gleixner2019-05-211-0/+1
| | | | | | | | | | | | | | Add SPDX license identifiers to all Make/Kconfig files which: - Have no license information of any form These files fall under the project license, GPL v2 only. The resulting SPDX license identifier is: GPL-2.0-only Signed-off-by: Thomas Gleixner <tglx@linutronix.de> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* media: tegra-cec: fix cec_notifier_parse_hdmi_phandle return checkHans Verkuil2019-05-081-2/+2
| | | | | | | | | | | cec_notifier_parse_hdmi_phandle returns an error pointer, not a NULL pointer on error. Fixes: 4d34c9267db7: ("media: tegra_cec: use new cec_notifier_parse_hdmi_phandle helper") Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl> Reported-by: Dan Carpenter <dan.carpenter@oracle.com> Signed-off-by: Mauro Carvalho Chehab <mchehab+samsung@kernel.org>
* media: tegra_cec: use new cec_notifier_parse_hdmi_phandle helperHans Verkuil2019-04-221-10/+4Star
| | | | | | | | | The Tegra CEC driver increased the HDMI device refcount when it shouldn't. Use the new helper function to ensure that that doesn't happen and to simplify the driver code. Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl> Signed-off-by: Mauro Carvalho Chehab <mchehab+samsung@kernel.org>
* media: tegra-cec: reset rx_buf_cnt when start bit detectedHans Verkuil2018-03-051-10/+7Star
| | | | | | | | | | | | | | | | If a start bit is detected, then reset the receive buffer counter to 0. This ensures that no stale data is in the buffer if a message is broken off midstream due to e.g. a Low Drive condition and then retransmitted. The only Rx interrupts we need to listen to are RX_REGISTER_FULL (i.e. a valid byte was received) and RX_START_BIT_DETECTED (i.e. a new message starts and we need to reset the counter). Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Cc: <stable@vger.kernel.org> # for v4.15 and up Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
* media: tegra-cec: add missing MODULE_DESCRIPTION/AUTHOR/LICENSEJesse Chan2017-12-081-0/+5
| | | | | | | | | | | | | | | | This change resolves a new compile-time warning when built as a loadable module: WARNING: modpost: missing MODULE_LICENSE() in drivers/media/platform/tegra-cec/tegra_cec.o see include/linux/module.h for more information This adds the license as "GPL v2", which matches the header of the file. MODULE_DESCRIPTION and MODULE_AUTHOR are also added. Signed-off-by: Jesse Chan <jc@linux.com> Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
* media: tegra-cec: fix messy probe() cleanupHans Verkuil2017-10-311-16/+10Star
| | | | | | | | | | | | | | The probe() cleanup code ('goto foo_error') was very messy. It appears that this code wasn't updated when I switched to the devm_ functions in an earlier version. Update the code to use 'return error' where it can and do proper cleanup where it needs to. Note that the original code wasn't buggy, it was just messy. Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
* media: tegra-cec: add Tegra HDMI CEC driverHans Verkuil2017-10-273-0/+629
This driver adds support for the Tegra CEC IP. It is based on the NVIDIA drivers/misc/tegra-cec driver in their 3.10 kernel. This has been converted to the CEC framework and cleaned up. Tested with my Jetson TK1 board. It has also been tested with the Tegra X1 in an embedded product. Note of warning for the Tegra X2: this SoC supports two HDMI outputs, but only one CEC adapter and the CEC bus is shared between the two outputs. This is a design mistake and the CEC adapter can control only one HDMI output. Never hook up both HDMI outputs to the CEC bus in a hardware design: this is illegal as per the CEC specification. The CEC bus can be shared between multiple inputs and zero or one outputs, but not between multiple outputs. Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Acked-by: Thierry Reding <treding@nvidia.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>