aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/media/platform/seco-cec
AgeCommit message (Collapse)Author
2019-05-21treewide: Add SPDX license identifier - Makefile/KconfigThomas Gleixner
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>
2019-04-22media: seco-cec: decrement HDMI device refcountHans Verkuil
The SECO CEC driver never decremented the HDMI device refcount. CEC drivers only need the HDMI device pointer as a key in the notifier list, it never accesses the device, so there is no need to keep a reference. Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl> Signed-off-by: Mauro Carvalho Chehab <mchehab+samsung@kernel.org>
2019-01-16media: secocec: fix ir address shiftEttore Chimenti
The actual value of the RC5 System Number (address) is stored in the IR_READ_DATA common register masked with 0x1F00 so it have to be shifted by 8 bits. Signed-off-by: Ettore Chimenti <ek5.chimenti@gmail.com> Signed-off-by: Sean Young <sean@mess.org> Signed-off-by: Mauro Carvalho Chehab <mchehab+samsung@kernel.org>
2018-12-03media: seco-cec: add missing header file to fix buildRandy Dunlap
Fix build errors due to missing <linux/module.h> header file. The header file is inserted first because module-related errors begin showing up in <linux/acpi.h> (when CONFIG_ACPI is not set). Sample of build errors: In file included from ../include/linux/acpi.h:27:0, from ../drivers/media/platform/seco-cec/seco-cec.c:10: ../include/linux/device.h:1620:1: warning: data definition has no type or storage class [enabled by default] module_exit(__driver##_exit); ^ ../include/linux/platform_device.h:229:2: note: in expansion of macro 'module_driver' module_driver(__platform_driver, platform_driver_register, \ ^ ../drivers/media/platform/seco-cec/seco-cec.c:791:1: note: in expansion of macro 'module_platform_driver' module_platform_driver(secocec_driver); ^ ../include/linux/device.h:1620:1: error: type defaults to 'int' in declaration of 'module_exit' [-Werror=implicit-int] module_exit(__driver##_exit); ^ ../include/linux/platform_device.h:229:2: note: in expansion of macro 'module_driver' module_driver(__platform_driver, platform_driver_register, \ ^ ../drivers/media/platform/seco-cec/seco-cec.c:791:1: note: in expansion of macro 'module_platform_driver' module_platform_driver(secocec_driver); ^ In file included from ../include/linux/linkage.h:7:0, from ../include/linux/kernel.h:7, from ../include/linux/list.h:9, from ../include/linux/resource_ext.h:17, from ../include/linux/acpi.h:26, from ../drivers/media/platform/seco-cec/seco-cec.c:10: ../include/linux/export.h:18:30: warning: parameter names (without types) in function declaration [enabled by default] #define THIS_MODULE ((struct module *)0) ^ ../include/linux/platform_device.h:199:34: note: in expansion of macro 'THIS_MODULE' __platform_driver_register(drv, THIS_MODULE) ^ ../include/linux/device.h:1613:9: note: in expansion of macro 'platform_driver_register' return __register(&(__driver) , ##__VA_ARGS__); \ ^ ../include/linux/platform_device.h:229:2: note: in expansion of macro 'module_driver' module_driver(__platform_driver, platform_driver_register, \ ^ ../drivers/media/platform/seco-cec/seco-cec.c:791:1: note: in expansion of macro 'module_platform_driver' module_platform_driver(secocec_driver); ^ ../drivers/media/platform/seco-cec/seco-cec.c:793:20: error: expected declaration specifiers or '...' before string constant MODULE_DESCRIPTION("SECO CEC X86 Driver"); ^ ../drivers/media/platform/seco-cec/seco-cec.c:794:15: error: expected declaration specifiers or '...' before string constant MODULE_AUTHOR("Ettore Chimenti <ek5.chimenti@gmail.com>"); ^ ../drivers/media/platform/seco-cec/seco-cec.c:795:16: error: expected declaration specifiers or '...' before string constant MODULE_LICENSE("Dual BSD/GPL"); ^ In file included from ../include/linux/acpi.h:27:0, from ../drivers/media/platform/seco-cec/seco-cec.c:10: ../drivers/media/platform/seco-cec/seco-cec.c:791:24: warning: 'secocec_driver_init' defined but not used [-Wunused-function] module_platform_driver(secocec_driver); ^ ../include/linux/device.h:1611:19: note: in definition of macro 'module_driver' static int __init __driver##_init(void) \ ^ ../drivers/media/platform/seco-cec/seco-cec.c:791:1: note: in expansion of macro 'module_platform_driver' module_platform_driver(secocec_driver); Signed-off-by: Randy Dunlap <rdunlap@infradead.org> Cc: Ettore Chimenti <ek5.chimenti@gmail.com> Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl> Signed-off-by: Mauro Carvalho Chehab <mchehab+samsung@kernel.org>
2018-11-23media: seco-cec: declare ops as static constMauro Carvalho Chehab
As warned by smatch: drivers/media/platform/seco-cec/seco-cec.c:338:21: warning: symbol 'secocec_cec_adap_ops' was not declared. Should it be static? This struct should be static. Also, it is const, so declare it as such. Signed-off-by: Mauro Carvalho Chehab <mchehab+samsung@kernel.org>
2018-11-23media: seco-cec: fix MakefileHans Verkuil
Fix the incorrect obj-y. Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl> Signed-off-by: Mauro Carvalho Chehab <mchehab+samsung@kernel.org>
2018-11-22media: seco-cec: add Consumer-IR supportEttore Chimenti
Introduce support for Consumer-IR into seco-cec driver, as it shares the same interrupt for receiving messages. The device decodes RC5 signals only, defaults to hauppauge mapping. It will spawn an input interface using the RC framework (like CEC device). Signed-off-by: Ettore Chimenti <ek5.chimenti@gmail.com> Reviewed-by: Sean Young <sean@mess.org> Signed-off-by: Hans Verkuil <hansverk@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab+samsung@kernel.org>
2018-11-22media: add SECO cec driverEttore Chimenti
This patch adds support to the CEC device implemented with a STM32 microcontroller in X86 SECO Boards, including UDOO X86. The communication is achieved via Braswell integrated SMBus (i2c-i801). The driver use direct access to the PCI addresses, due to the limitations of the specific driver in presence of ACPI calls. The basic functionalities are tested with success with cec-ctl and cec-compliance. Inspired by cros-ec-cec implementation, attaches to i915 driver cec-notifier. Signed-off-by: Ettore Chimenti <ek5.chimenti@gmail.com> Reviewed-by: Jacopo Mondi <jacopo@jmondi.org> Signed-off-by: Hans Verkuil <hansverk@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab+samsung@kernel.org>