summaryrefslogtreecommitdiff
path: root/drivers
AgeCommit message (Collapse)Author
2016-07-14gc_hal_kernel_platform_imx6q14.c: silence compiler warningMax Krummenacher
drivers/mxc/gpu-viv/hal/os/linux/kernel/platform/freescale/gc_hal_kernel_platform_imx6q14.c:457:3: error: this 'if' clause does not guard... [-Werror=misleading-indentation] if(Args->physSize == 0) ^~ drivers/mxc/gpu-viv/hal/os/linux/kernel/platform/freescale/gc_hal_kernel_platform_imx6q14.c:460:5: note: ...this statement, but the latter is misleadingly indented as if it return gcvSTATUS_OK; ^~~~~~ Signed-off-by: Max Krummenacher <max.krummenacher@toradex.com> Acked-by: Stefan Agner <stefan.agner@toradex.com>
2016-07-14unused variables: silence compiler warningMax Krummenacher
drivers/media/platform/mxc/capture/ov5640_mipi.c:879:18: warning: 'sclk_rdiv_map' defined but not used [-Wunused-const-variable=] static const int sclk_rdiv_map[] = {1, 2, 4, 8}; ^~~~~~~~~~~~~ drivers/net/usb/usbnet.c:84:19: warning: 'driver_name' defined but not used [-Wunused-const-variable=] static const char driver_name [] = "usbnet"; ^~~~~~~~~~~ fs/cifs/netmisc.c:133:40: warning: 'mapping_table_ERRHRD' defined but not used [-Wunused-const-variable=] static const struct smb_to_posix_error mapping_table_ERRHRD[] = { ^~~~~~~~~~~~~~~~~~~~ kernel/cgroup.c:3839:36: warning: 'cgroup_pidlist_seq_operations' defined but not used [-Wunused-const-variable=] static const struct seq_operations cgroup_pidlist_seq_operations = { ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~ net/core/net-sysfs.c:30:19: warning: 'fmt_long_hex' defined but not used [-Wunused-const-variable=] static const char fmt_long_hex[] = "%#lx\n"; ^~~~~~~~~~~~ net/core/rtnetlink.c:1266:32: warning: 'ifla_vf_policy' defined but not used [-Wunused-const-variable=] static const struct nla_policy ifla_vf_policy[IFLA_VF_MAX+1] = { ^~~~~~~~~~~~~~ net/core/rtnetlink.c:1262:32: warning: 'ifla_vfinfo_policy' defined but not used [-Wunused-const-variable=] static const struct nla_policy ifla_vfinfo_policy[IFLA_VF_INFO_MAX+1] = { ^~~~~~~~~~~~~~~~~~ net/core/sysctl_net_core.c:26:12: warning: 'one' defined but not used [-Wunused-variable] static int one = 1; ^~~ net/ipv4/ping.c:1148:36: warning: 'ping_v4_seq_ops' defined but not used [-Wunused-const-variable=] static const struct seq_operations ping_v4_seq_ops = { ^~~~~~~~~~~~~~~ net/rfkill/rfkill-gpio.c:187:36: warning: 'rfkill_acpi_match' defined but not used [-Wunused-const-variable=] static const struct acpi_device_id rfkill_acpi_match[] = { drivers/net/wireless/rtlwifi/efuse.c:38:31: warning: 'RTL8712_SDIO_EFUSE_TABLE' defined but not used [-Wunused-const-variable=] static const struct efuse_map RTL8712_SDIO_EFUSE_TABLE[] = { ^~~~~~~~~~~~~~~~~~~~~~~~ drivers/net/wireless/rtlwifi/efuse.c:34:17: warning: 'MAX_PGPKT_SIZE' defined but not used [-Wunused-const-variable=] static const u8 MAX_PGPKT_SIZE = 9; ^~~~~~~~~~~~~~ Signed-off-by: Max Krummenacher <max.krummenacher@toradex.com> Acked-by: Stefan Agner <stefan.agner@toradex.com>
2016-07-14ipu_disp.c: silence compiler warningsMax Krummenacher
drivers/mxc/ipu3/ipu_disp.c:435:89: warning: initialization discards 'const' qualifier from pointer target type [-Wdiscarded-array-qualifiers] {{DP_COM_CONF_CSC_DEF_BOTH, &rgb2ycbcr_coeff}, {0, 0}, {0, 0}, {DP_COM_CONF_CSC_DEF_BG, &rgb2ycbcr_coeff}, {DP_COM_CONF_CSC_DEF_BG, &rgb2ycbcr_coeff} }, Signed-off-by: Max Krummenacher <max.krummenacher@toradex.com> Acked-by: Stefan Agner <stefan.agner@toradex.com>
2016-07-14of-thermal.c: fix code flaged by compiler warningMax Krummenacher
include/linux/of.h:803:2: warning: this 'for' clause does not guard... [-Wmisleading-indentation] for (child = of_get_next_child(parent, NULL); child != NULL; \ ^ drivers/thermal/of-thermal.c:715:2: note: in expansion of macro 'for_each_child_of_node' for_each_child_of_node(child, gchild) ^~~~~~~~~~~~~~~~~~~~~~ drivers/thermal/of-thermal.c:718:3: note: ...this statement, but the latter is misleadingly indented as if it is guarded by the 'for' if (ret) ^~ Signed-off-by: Max Krummenacher <max.krummenacher@toradex.com> Acked-by: Stefan Agner <stefan.agner@toradex.com>
2016-06-29can: mcp251x: fix resume when device is downColibri_iMX6_LinuxImageV2.6Beta2_20160701Apalis_iMX6_LinuxImageV2.6Beta2_20160701Stefan Agner
If a valid power regulator or a dummy regulator is used (which happens to be the case when no regulator is specified), restart_work is queued no matter whether the device was running or not at suspend time. Since work queues get initialized in the ndo_open callback, resuming leads to a NULL pointer exception. Reverse exactly the steps executed at suspend time: - Enable the power regulator in any case - Enable the transceiver regulator if the device was running, even in case we have a power regulator - Queue restart_work only in case the device was running Fixes: bf66f3736a94 ("can: mcp251x: Move to threaded interrupts instead of workqueues.") Signed-off-by: Stefan Agner <stefan@agner.ch> Cc: linux-stable <stable@vger.kernel.org> Signed-off-by: Marc Kleine-Budde <mkl@pengutronix.de> (cherry picked from commit 25b401c1816ae64bcc5dcb1d39ab41812522a0ce) Backport conflicts: driver has been moved to spi subdir upstream drivers/net/can/spi/mcp251x.c
2016-06-27video: mxc: ldb: Add support for LVDS configuration via kernel boot argumentsBhuvanchandra DV
Add support for LVDS frame buffer configuration via kernel boot arguments. Fix use of the device tree native-mode property. Signed-off-by: Bhuvanchandra DV <bhuvanchandra.dv@toradex.com> Acked-by: Max Krummenacher <max.krummenacher@toradex.com>
2016-06-24media: Add support for ADV7280 decoder driverSanchayan Maity
Add support for ADV7280 decoder found on Toradex Analogue Camera Adapter V2.0A Signed-off-by: Sanchayan Maity <sanchayan.maity@toradex.com> Acked-by: Marcel Ziswiler <marcel.ziswiler@toradex.com>
2016-06-24mxc_v4l2_capture: Change error message to print on debugSanchayan Maity
Change the "unsupported ioctrl" message to print only on debug. This otherwise results in an error message ERROR: v4l2 capture: unsupported ioctrl! which does not seem to effect the gstreamer pipeline or rendering of video. >From debugging, root@apalis-imx6:~# gst-launch-1.0 imxv4l2videosrc ! imxeglvivsink Setting pipeline to PAUSED ... [ 385.174543] ERROR: v4l2 capture: unsupported ioctrl 9a091b! Pipeline is live and does not need PREROLL ... Setting pipeline to PLAYING ... New clock: GstSystemClock >From v4l2-controls.h V4L2_CTRL_CLASS_CAMERA 0x009a0000 V4L2_CID_CAMERA_CLASS_BASE V4L2_CTRL_CLASS_CAMERA | 0x900 V4L2_CID_3A_LOCK V4L2_CID_CAMERA_CLASS_BASE + 27 So the ioctrl requested seems to be V4L2_CID_3A_LOCK. "The V4L2_CID_3A_LOCK bitmask control allows applications to pause or resume the automatic exposure, focus and wite balance adjustments. It can be used, for example, to lock the 3A adjustments right before a still image is captured, for pre-focus, etc. The applications can control each of the algorithms independently, through a corresponding control bit, if driver allows that." https://patchwork.linuxtv.org/patch/10719/ Since we have no such feature available we can safely disable the error message. Signed-off-by: Sanchayan Maity <sanchayan.maity@toradex.com> Acked-by: Marcel Ziswiler <marcel.ziswiler@toradex.com>
2016-06-24mxc_v4l2_capture: Allow clock setting for de-interlaced video inputSanchayan Maity
Make provision for a decoder driver to specify clock mode for progressive in case the decoder provides deinterlaced output. This is required for ADV7280 decoder where we can use the hardware deinterlace capabity of ADV7280. Without setting the clock mode to progressive but having hardware deinterlace on for ADV7280 results in a non working setup. Signed-off-by: Sanchayan Maity <sanchayan.maity@toradex.com> Acked-by: Marcel Ziswiler <marcel.ziswiler@toradex.com>
2016-03-18rn5t567: register ARM reset callbackStefan Agner
Use the PMIC repower capabilities to reboot the module. Register arm_pm_restart to trigger a cold reboot using the PMIC. Signed-off-by: Stefan Agner <stefan.agner@toradex.com>
2016-03-18rn5t567: do not register poweroffStefan Agner
The Colibri iMX7 uses the SNVS_PMIC_ON_REQ signal (connected to the PMIC's PMIC_ON_EXTIN GPIO) to power off the module. The SNVS RTC driver provides a poweroff callback which causes that signal to go low. However, the current PMIC driver registers a poweroff callback earlier and therefor the kernel uses the PMIC poweroff instead of the SNVS RTC poweroff callback. Signed-off-by: Stefan Agner <stefan.agner@toradex.com>
2016-03-09rn5txxx-regulator.c: allow GPIO 0 to be used for an enable signalMax Krummenacher
Follow commit 286098c029bda740822e68ba6ac2ba0b2fe7c5d3 GPIO number 0 *is* legal and must be accepted. Set .ena_gpio to -ENODEV on regulators having no GPIO in preparation of a code change to accept GPIO 0 in the config. Signed-off-by: Max Krummenacher <max.krummenacher@toradex.com> Signed-off-by: Stefan Agner <stefan.agner@toradex.com>
2016-03-09CONFIG_FB_MXS: allow build without configuring IPU alsoMax Krummenacher
Both drivers, FB_MXS and IPUv3 use functionality from mxc_dispdrv.c. Allow for a configuartion which builds only FB_MXS. Signed-off-by: Max Krummenacher <max.krummenacher@toradex.com> Signed-off-by: Stefan Agner <stefan.agner@toradex.com>
2016-03-09drivers/mtd/nand/Kconfig: allow MTD_NAND_GPMI_NAND for i.MX 7Max Krummenacher
Signed-off-by: Max Krummenacher <max.krummenacher@toradex.com> Signed-off-by: Stefan Agner <stefan.agner@toradex.com>
2016-03-09drivers/dma/Kconfig: allow MXS_DMA for i.MX 7Max Krummenacher
Signed-off-by: Max Krummenacher <max.krummenacher@toradex.com> Signed-off-by: Stefan Agner <stefan.agner@toradex.com>
2016-03-09video: fbdev: mxsfb: fix pixelclock polarityStefan Agner
The PIXDATA flags of the display_flags enum are controller centric, e.g. NEGEDGE means the controller shall drive the data signals on pixelclocks negative edge. However, the drivers flag is display centric: Sample the data on negative (falling) edge. Therefore, change the if statement to check for the POSEDGE flag (which is typically not set): Drive on positive edge => sample on negative edge Signed-off-by: Stefan Agner <stefan.agner@toradex.com> Acked-by: Max Krummenacher <max.krummenacher@toradex.com>
2016-03-09input: touchscreen: ad7879: add device tree supportStefan Agner
Add device tree support to the I2C variant of AD7879 (AD7879-1). This allows to specify the touchscreen controller as a I2C client node. Most of the options available as platform data are also available as device tree nodes. Signed-off-by: Stefan Agner <stefan.agner@toradex.com> Acked-by: Max Krummenacher <max.krummenacher@toradex.com>
2016-03-09input: touchscreen: ad7879: fix default x/y axis assignmentStefan Agner
The measurements read from the controller which are temporarly stored in conversion_data, are interpreted wrong. The first measurement X+ contains the Y position, and the second measurement Y+ the X position (see also Table 11 Register Table in the data sheet). The problem is already known, the change 6680884a4420 ("Input: ad7879 - add option to correct xy axis") introduced a swap option. However, the meaning of this boolean was inverted since the underlaying values were already swapped. With this change, swap_xy = true actually swaps the two axis. Signed-off-by: Stefan Agner <stefan.agner@toradex.com> Acked-by: Max Krummenacher <max.krummenacher@toradex.com>
2016-03-08chipidea: make usb charger optionalMax Krummenacher
The USB charger functionality depends on functions provided by CONFIG_POWER_SUPPLY but this dependency is not forced through Kconfig. Don't compile the functionality in when CONFIG_POWER_SUPPLY is not set. This fixes linker errors of not found symbols. power_supply_changed power_supply_register power_supply_unregister Signed-off-by: Max Krummenacher <max.krummenacher@toradex.com> Signed-off-by: Stefan Agner <stefan.agner@toradex.com>
2016-03-08mmc: sdhci-esdhc-imx: Fixup runtime PM conditions during ->probe()Ulf Hansson
By configure runtime PM prior we enable the use of it, we close the gap for strange and unhandled conditions. Moreover it makes us rely on the driver core, after finalized ->probe(), to request an inactive device to become runtime PM idle/suspended, which earlier potentially could happen already at pm_runtime_set_autosuspend_delay(). Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> (cherry picked from commit 77903c01d8c6c5d2544085ba074aceadc1191d21)
2016-03-08rn5t567: add PMIC driverMax Krummenacher
This adds support for Ricoh RN5T567 PMIC used on Colibri iMX7. The driver should get unified with rn5t618 driver. Signed-off-by: Max Krummenacher <max.krummenacher@toradex.com> Signed-off-by: Stefan Agner <stefan.agner@toradex.com>
2016-03-08watchdog: add driver for Ricoh RN5T618 watchdogBeniamino Galvani
This adds a driver for the watchdog timer available in Ricoh RN5T618 PMIC. The device supports a programmable expiration time of 1, 8, 32 or 128 seconds. Signed-off-by: Beniamino Galvani <b.galvani@gmail.com> Reviewed-by: Guenter Roeck <linux@roeck-us.net> Signed-off-by: Wim Van Sebroeck <wim@iguana.be> (cherry picked from commit 22b1c841e31510c3124c88a13b8a7ada14e2e2d1)
2016-03-08mfd: Add Ricoh RN5T618 PMIC core driverBeniamino Galvani
Ricoh RN5T618 is a power management IC which integrates 3 step-down DCDC converters, 7 low-dropout regulators, a Li-ion battery charger, fuel gauge, ADC, GPIOs and a watchdog timer. This commit adds a MFD core driver to support the I2C communication with the device. Signed-off-by: Beniamino Galvani <b.galvani@gmail.com> Signed-off-by: Lee Jones <lee.jones@linaro.org> (cherry picked from commit 9bb9e29c78f8d8ee310987fd58a2b908a4ce0c40)
2016-03-08regulator: rn5t618: add driver for Ricoh RN5T618 regulatorsBeniamino Galvani
This driver supports the 3 DCDC and 7 LDO regulators available on Ricoh RN5T618 PMIC. Signed-off-by: Beniamino Galvani <b.galvani@gmail.com> Signed-off-by: Mark Brown <broonie@kernel.org> (cherry picked from commit 811b700630ff328c52ddf17d653ffdcb0ba87d30) Conflicts: drivers/regulator/Kconfig drivers/regulator/Makefile
2016-03-08of: fill in new type field on node creationMax Krummenacher
The backport of the extcon subsystem also brought a new field in the of node structure. Set it correctly or code using it will think the node comes from ACPI, not from a device-tree. Fixes gpio-leds which otherwise would not find the gpios from the device tree. Signed-off-by: Max Krummenacher <max.krummenacher@toradex.com> Acked-by: Marcel Ziswiler <marcel.ziswiler@toradex.com>
2016-03-08tty: serial: imx: disable DCD and RI interruptsStefan Agner
If the UART is in DTE mode, the signals DCD and RI are inputs. In this case, the control bits in UCR3_DCD and UCR3_RI control the interrupt of those two inputs. The two bits are 1 on reset, hence leading to an interrupt if one of those signal changes... However, as of now the interrupt handler does not handle these interrupts, leading to a interrupt strom. Solve the issue by explicitly disabling the two interrupts during initialization. Signed-off-by: Stefan Agner <stefan.agner@toradex.com> Acked-by: Max Krummenacher <max.krummenacher@toradex.com>
2016-03-08PCI: Apalis GEN1 forcing quirkMarcel Ziswiler
The Apalis evaluation board needs to set the link speed to 2.5 GT/s (GEN1). The default link speed setting is 5 GT/s (GEN2). 0x98 is the Link Control 2 PCIe Capability Register of the PEX8605 PCIe switch. The switch supports link speed auto negotiation, but falsely sets the link speed to 5 GT/s. Signed-off-by: Marcel Ziswiler <marcel.ziswiler@toradex.com> Acked-by: Max Krummenacher <max.krummenacher@toradex.com>
2016-03-08PCI: imx6: fix PCIe EP device self-initialisationMarcel Ziswiler
This fixes PCIe EP device self-initialisation in case only a regular reset EP GPIO is used as PERST# which is e.g. the case on our Ixora carrier board by always waiting 20 milliseconds after releasing PERST#. Signed-off-by: Marcel Ziswiler <marcel.ziswiler@toradex.com> Acked-by: Max Krummenacher <max.krummenacher@toradex.com>
2015-12-26gpio: generic: clamp retured value to [0,1]Linus Walleij
The generic GPIO would return 0 for low generic GPIO, and something != 0 for high GPIO. Let's make this sane by clamping the returned value to [0,1]. Reported-by: Evgeny Boger <boger@contactless.ru> Reviewed-by: Alexandre Courbot <acourbot@nvidia.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
2015-12-26Input: sentelic - use "static inline" instead of "inline"Khem Raj
gcc-5 defaults to gnu11 which used c99 inline semantics in c99 'inline' is not externally visible unlike gnu89, therefore we use 'static inline' which has same semantics between gnu89 and c99 Signed-off-by: Khem Raj <raj.khem@gmail.com> Signed-off-by: Max Krummenacher <max.krummenacher@toradex.com>
2015-12-26Input: lifebook - use "static inline" instead of "inline" in lifebook.hChen Gang
For functions defined in header files we should use static inline rather than inline, which breaks under the latest upstream gcc (which is really gcc issue, but static inline is better suited regardless). The related error (with allmodconfig under tile): MODPOST 4002 modules ERROR: "lifebook_detect" [drivers/input/mouse/psmouse.ko] undefined! Signed-off-by: Chen Gang <gang.chen.5i5j@gmail.com> Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com> (cherry picked from commit bd447b61c49fc26f0299587db3e6d66da49dc529) Signed-off-by: Max Krummenacher <max.krummenacher@toradex.com>
2015-12-26input: touchscreen: fusion: implement multitouch with slot handlingStefan Agner
According to multi-touch-protocol.txt the kernel knows two type of devices: - Type A: devices which provide anonymous contacts - Type B: devices which are capable of tracking individual contacts The Fusion touch screen is a Type B device: The Touch ID field allows to differentiate between 2 different fingers. This updates the driver to properly allocate a slot for each identified contact and use the helper functions available from the input core system. (cherry picked from commit 7deb092bd1f3ff2111fbde52afd35e2ea2933740)
2015-12-26input: touchscreen: fusion: use level triggered interruptStefan Agner
Use level triggered interrupt which makes sure that even we miss a rising edge (due to latencies in the kernel), the interrupt still will be handled later, and doesn't freeze the input device. (cherry picked from commit ef25b8a9f9c0ca7cc0f0f955d89d112c3e19f75b)
2015-12-26mxc_v4l2_capture.c: make error messages uniqueMax Krummenacher
"ERROR: v4l2 capture: slave not found!" is used for many ioctl. Add the ioctl to the string to ease debugging.
2015-12-26ipu_csi_enc.c: fix debug printMax Krummenacher
2015-12-26max9526.c: move pinctrl after i2c detectMax Krummenacher
This removes a bunch of error messages during probe because both the adv7180 and the max9526 use try to reserve the same pins. While at it convert debug output to dev_dbg
2015-12-26adv7180.c: convert debug output to dev_dbgMax Krummenacher
2015-12-26mxc_v4l2_capture: match ipu/csi/mipi instead of only ipu/csiTroy Kisky
(cherry picked from commit f3ce4f51a39f0eb6727166cbdba3e92b37f237e8) Conflicts: drivers/media/platform/mxc/capture/mxc_v4l2_capture.c
2015-12-26max9526: add initial MXC camera sensor codeMax Krummenacher
Add initial support for Maxim Integrated MAX9526 video decoder for use with an Freescale i.MX 6. PAL works, NTSC does not lock on VSYNC. (cherry picked from commit 6763d5ab9496099ec2b74d3a7c2034e87a7cb70e) Conflicts: drivers/media/platform/mxc/capture/Makefile Conflicts with 3.14 headers: Change different location for include v4l2-int-device.h While at it remove unused auto variables which causes compile time warnings.
2015-12-26adv7180.c: initial working adv7180 settingsMax Krummenacher
The input channel is currently fixed to A_IN2_3 on the ACM's connector X5. (cherry picked from commit 568747f8c0984b027ca9feb1a3326fd96c4e4373)
2015-12-26mxc_v4l2_capture: let the camera driver set mipi/parallelMax Krummenacher
The camera driver knows if it uses mipi or parallel, and in case a camera can do both it makes sense that this is in the device tree node for the camera and not the generic mxc_v4l2_capture. (cherry picked from commit 09d5f1a3ad615b96d9f01bca0622d41f20c3011b)
2015-12-26pci-imx6: fix reboot bugTroy Kisky
2015-12-26mxc_hdmi.c: fix boot hangMax Krummenacher
Without this the kernel hangs during boot when HDMI is attached. It looks like we get an overflow IRQ storm. overflow is related to HDMI audio.
2015-12-26fbcon: logo: allow easy integration of a custom Linux boot logoMarcel Ziswiler
This patch allows for easy integration of a custom Linux boot logo to replace the Tux' being shown by default. Use gimp or the like to create a raw PPM in your desired resolution. Reduce the number of colours in the image to 224: user@host:~$ ppmquant 224 Toradex-640x480.ppm > \ Toradex-640x480-224.ppm ppmquant: making histogram... ppmquant: 370 colors found ppmquant: choosing 224 colors... ppmquant: mapping image to new colors... Convert it from raw PPM to ASCII format: user@host:~$ pnmnoraw Toradex-640x480-224.ppm > \ Toradex-640x480-ascii-224.ppm Copy it into the Linux sources: cp Toradex-640x480-ascii-224.ppm linux-toradex/drivers/video/logo/\ logo_custom_clut224.ppm Activate exclusively custom Linux logo in the kernel configuration: Device Drivers -> Graphics support -> Bootup logo -> Custom 224-color Linux logo And re-compile the kernel. (cherry picked from commit fa2371bff9ac03581881849d8f95678ef3992719) (cherry picked from commit 481ced9057f340a80bf23775a55a9b657c49201f)
2015-12-26extcon: usb-gpio: increase debounce timeMarcel Ziswiler
Testing on Colibri Evaluation board V3.x has shown even 50 ms not being enough to avoid unloading and immediately reloading the EHCI USB host controller driver upon OTG cable removal which is of course suboptimal. This patch increases it to 100 ms which should leave enough safety margin.
2015-12-26usb: chipidea: use extcon framework for ID and VBUS detectionMarcel Ziswiler
Rather than relying on special USB/PHY pins/registers use the generic extcon framework with its extcon-usb-gpio implementation to detect ID and VBUS changes. (cherry picked from commit a257098741b441e6e84ffe97b7793c580642d502)
2015-12-26extcon: usb-gpio: Introduce gpio usb extcon driverRoger Quadros
This driver observes the USB ID pin connected over a GPIO and updates the USB cable extcon states accordingly. The existing GPIO extcon driver is not suitable for this purpose as it needs to be taught to understand USB cable states and it can't handle more than one cable per instance. For the USB case we need to handle 2 cable states. 1) USB (attach/detach) 2) USB-HOST (attach/detach) This driver can be easily updated in the future to handle VBUS events in case it happens to be available on GPIO for any platform. Signed-off-by: Roger Quadros <rogerq@ti.com> Reviewed-by: Felipe Balbi <balbi@ti.com> Acked-by: Felipe Balbi <balbi@ti.com> Signed-off-by: Chanwoo Choi <cw00.choi@samsung.com> (cherry picked from commit e52817faae359ce95c93c2b6eb88b16d4b430181)
2015-12-26leds: leds-gpio: Pass on error codes unmodifiedSoren Brinkmann
Instead of overriding error codes, pass them on unmodified. This way a EPROBE_DEFER is correctly passed to the driver core. This results in the LED driver correctly requesting probe deferral in cases the GPIO controller is not yet available. Signed-off-by: Soren Brinkmann <soren.brinkmann@xilinx.com> Reported-and-tested-by: Andreas Färber <afaerber@suse.de> Signed-off-by: Bryan Wu <cooloney@gmail.com> (cherry picked from commit c6e71f813f7208d80bfe0f435d627fad1b204558)
2015-12-26gpio: add parameter to allow the use named gpiosOlliver Schinagl
The gpio binding document says that new code should always use named gpios. Patch 40b73183 added support to parse a list of gpios from child nodes, but does not make it possible to use named gpios. This patch adds the con_id property and implements it is done in gpiolib.c, where the old-style of using unnamed gpios still works. Signed-off-by: Olliver Schinagl <oliver@schinagl.nl> Acked-by: Bryan Wu <cooloney@gmail.com> Acked-by: Dmitry Torokhov <dmitry.torokhov@gmail.com> Reviewed-by: Alexandre Courbot <acourbot@nvidia.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> (cherry picked from commit 1feb57a245a4910b03202a814ffc51a900bd4aca)
2015-12-26leds: leds-gpio: Fix the "default-state" property checkFabio Estevam
Commit a43f2cbbb009f9 ("leds: leds-gpio: Make use of device property API") caused a regression by reading the incorrect string for the "default-state" property. Fix the property string check to restore the original behaviour. Fixes: a43f2cbbb009 (leds: leds-gpio: Make use of device property API) Reported-by: Jean-Michel Hautbois <jean-michel.hautbois@vodalys.com> Signed-off-by: Fabio Estevam <fabio.estevam@freescale.com> Acked-by: Bryan Wu <cooloney@gmail.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> (cherry picked from commit d735d25e60fffeffc256fa5d59551dc92dc07e36)