Commit graph

15 commits

Author SHA1 Message Date
Dmitry Torokhov 03b22057e8 Linux 4.11-rc5
-----BEGIN PGP SIGNATURE-----
 
 iQEcBAABAgAGBQJY4ZYkAAoJEHm+PkMAQRiGsq4H/R4PMXDoe2XhSSk7IoT97pXV
 /A8np/scAPjzEgYUidbb54OSqWwsPRuPGWONTFeSrE2u0L4wln/REI91jg7QetLq
 IisncExlYeJ/XQ+iO0ZZh9fLbqwIlEJFdSXmyIFr3m/TBxe8a61C8j93oNgM1tHT
 yuwzlq7c3sLq2hsmUG2HyL2kJsEfRasv4Rk0yhFuti12zVsBoTW4qmZuMauq+gdf
 f7cSYgiHhPTdb2o+azg5O7uYNHaQQBxdUMlIuhhYtVOUq+pFDO23SLHSFIW2NwOm
 Zn5R6CFSrLsCw0Bx0v8Xlc151QUbaRK4h9lhUhkBr6d3uNShU1NQ9JojpSvYwBo=
 =vP6E
 -----END PGP SIGNATURE-----

Merge tag 'v4.11-rc5' into next

Sync up with mainline to bring in changes to input subsystem merged
through other trees.
2017-04-03 12:01:20 -07:00
Rajat Jain e6eba3fac9 Input: cros_ec_keyb - add an EC event for sysrq
Some form factors (detachables/tablets) may not have a keyboard and
thus user may have to resort to using a defined EC UI to send sysrq(s)
to the kernel in order to collect crash info etc. This UI typically
is in the form of user pressing volume / power buttons in some specific
sequence and for some specific time. Add a new EC event that allows EC
to communicate the sysrq to the AP.

(We're skipping event number 5 because it has been reserved for
something else)

Signed-off-by: Rajat Jain <rajatja@google.com>
Acked-by: Lee Jones <lee.jones@linaro.org>
Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
2017-04-03 11:59:57 -07:00
Linus Torvalds df9cdc1727 - Core Frameworks
- Add new !TOUCHSCREEN_SUN4I dependency for SUN4I_GPADC
    - List include/dt-bindings/mfd/* to files supported in MAINTAINERS
 
  - New Drivers
    - Intel Apollo Lake SPI NOR
    - ST STM32 Timers (Advanced, Basic and PWM)
    - Motorola 6556002 CPCAP (PMIC)
 
  - New Device Support
    - Add support for AXP221 to axp20x
    - Add support for Intel Gemini Lake to intel-lpss-pci
    - Add support for MT6323 LED to mt6397-core
    - Add support for COMe-bBD#, COMe-bSL6, COMe-bKL6,
                      COMe-cAL6 and COMe-cKL6 to kempld-core
 
  - New Functionality
    - Add support for Analog CODAC to sun6i-prcm
    - Add support for Watchdog to lpc_ich
 
  - Fix-ups
    - Error handling improvements; axp288_charger, axp20x, ab8500-sysctrl
    - Adapt platform data handling; axp20x
    - IRQ handling improvements; arizona, axp20x
    - Remove superfluous code; arizona, axp20x, lpc_ich
    - Trivial coding style/spelling fixes; axp20x, abx500, mfd.txt
    - Regmap fix-ups; axp20x
    - DT changes; mfd.txt, aspeed-lpc, aspeed-gfx, ab8500-core, tps65912, mt6397
    - Use new I2C probing mechanism; max77686
    - Constification; rk808
 
  - Bug Fixes
    - Stop data transfer whilst suspended; cros_ec
 -----BEGIN PGP SIGNATURE-----
 
 iQIcBAABCAAGBQJYrYwQAAoJEFGvii+H/HdhVMMP/3Y5/S1y7bCRhsta3PQVHT/2
 +nxu833451qTTUKNqR5rTQrjdjVLr6+rfhMmMxIDhHMrn3EvwT0bQDQmncLLYgc2
 u5n2j93Y/nfyJvy76W3aTlisBaKfxhFBuLBEkewXNwPaZk97tbgf9IbyNq6eirHo
 afv5Z54q9RN+OlT5ZfM8mJcOQAdyE6CXzq/GKZI6LjSqPb5vQhasqoD/yb9pMMga
 jYseI47KlIVLhUnnAjxRdxt16rjtee2JHZmGCGJaeo+nWiTwDOZ5l5eZDHKwD6ng
 3CW4xWDPbzeLD22oi6Uzvhx+8Eqt9S/K1AY+kn3W6WLk/CTi5yamMHw0DjBUcS9a
 hqdqGZrCSveRQrSCt/9N5uzSMkiUHFMGdj5LtX3yB4fDp0R42WJGMxkvidKb7otB
 wJIT0i5T5M5G3IT3xPkdEtfEAK3xoAus+IF0faFNaD7GqsEs97KD+740nTgulSKz
 g28Lo6NLpZhl+uQ74fx76Wll+Onj1voWABZW8Z//kjRWkAwKU8OhbXrX8kccGY6m
 C980wWtj0979jYFstwUuSXspjuvk9L1nfSuLBmtawm9S58TUIS/WLe2A8kU9/XEY
 e3PLpO4AxvCJvBBa80yVFG15JoaTX5TOg/F3NqKYaHqA2cusOVOEFAeOAdwav2rL
 SR2Y8s8ceIL4n9ccmr0b
 =P5Dp
 -----END PGP SIGNATURE-----

Merge tag 'mfd-for-linus-4.11' of git://git.kernel.org/pub/scm/linux/kernel/git/lee/mfd

Pull MFD updates from Lee Jones:
 "Core Frameworks:
   - Add new !TOUCHSCREEN_SUN4I dependency for SUN4I_GPADC
   - List include/dt-bindings/mfd/* to files supported in MAINTAINERS

  New Drivers:
   - Intel Apollo Lake SPI NOR
   - ST STM32 Timers (Advanced, Basic and PWM)
   - Motorola 6556002 CPCAP (PMIC)

  New Device Support:
   - Add support for AXP221 to axp20x
   - Add support for Intel Gemini Lake to intel-lpss-pci
   - Add support for MT6323 LED to mt6397-core
   - Add support for COMe-bBD#, COMe-bSL6, COMe-bKL6, COMe-cAL6 and
     COMe-cKL6 to kempld-core

  New Functionality:
   - Add support for Analog CODAC to sun6i-prcm
   - Add support for Watchdog to lpc_ich

  Fix-ups:
   - Error handling improvements; axp288_charger, axp20x, ab8500-sysctrl
   - Adapt platform data handling; axp20x
   - IRQ handling improvements; arizona, axp20x
   - Remove superfluous code; arizona, axp20x, lpc_ich
   - Trivial coding style/spelling fixes; axp20x, abx500, mfd.txt
   - Regmap fix-ups; axp20x
   - DT changes; mfd.txt, aspeed-lpc, aspeed-gfx, ab8500-core, tps65912,
     mt6397
   - Use new I2C probing mechanism; max77686
   - Constification; rk808

  Bug Fixes:
   - Stop data transfer whilst suspended; cros_ec"

* tag 'mfd-for-linus-4.11' of git://git.kernel.org/pub/scm/linux/kernel/git/lee/mfd: (43 commits)
  mfd: lpc_ich: Enable watchdog on Intel Apollo Lake PCH
  mfd: lpc_ich: Remove useless comments in core part
  mfd: Add support for several boards to Kontron PLD driver
  mfd: constify regmap_irq_chip structures
  MAINTAINERS: Add include/dt-bindings/mfd to MFD entry
  mfd: cpcap: Add minimal support
  mfd: mt6397: Add MT6323 LED support into MT6397 driver
  Documentation: devicetree: Add LED subnode binding for MT6323 PMIC
  mfd: tps65912: Export OF device ID table as module aliases
  mfd: ab8500-core: Rename clock device and compatible
  mfd: cros_ec: Send correct suspend/resume event to EC
  mfd: max77686: Remove I2C device ID table
  mfd: max77686: Use the struct i2c_driver .probe_new instead of .probe
  mfd: max77686: Use of_device_get_match_data() helper
  mfd: max77686: Don't attempt to get i2c_device_id .data
  mfd: ab8500-sysctrl: Handle probe deferral
  mfd: intel-lpss: Add Intel Gemini Lake PCI IDs
  mfd: axp20x: Fix AXP806 access errors on cold boot
  mfd: cros_ec: Send suspend state notification to EC
  mfd: cros_ec: Prevent data transfer while device is suspended
  ...
2017-02-23 08:18:01 -08:00
Shawn Nematbakhsh f00c06fd98 mfd: cros_ec: Send suspend state notification to EC
Notify EC when going to or returning from suspend so that proper actions
related to wake events can be taken.

Signed-off-by: Shawn Nematbakhsh <shawnn@chromium.org>
Signed-off-by: Thierry Escande <thierry.escande@collabora.com>
Signed-off-by: Lee Jones <lee.jones@linaro.org>
2017-02-13 09:29:42 +00:00
Gwendal Grignou 6ccc3a3381 input: cros_ec_keyb: Add Tablet Mode switch
Add switch to report tablet mode.

Signed-off-by: Gwendal Grignou <gwendal@chromium.org>
Signed-off-by: Enric Balletbo Serra <enric.balletbo@collabora.com>
Signed-off-by: Lee Jones <lee.jones@linaro.org>
2017-02-13 09:25:19 +00:00
Douglas Anderson b44c4d3f1e mfd: cros-ec: Update cros_ec_commands.h for buttons and switches
Add the defines for the new buttons and switches connected to the CrosEC.

Signed-off-by: Douglas Anderson <dianders@chromium.org>
Signed-off-by: Enric Balletbo i Serra <enric.balletbo@collabora.com>
Signed-off-by: Lee Jones <lee.jones@linaro.org>
2017-02-08 11:15:50 +00:00
Gwendal Grignou d732248fdb iio: cros_ec: Add cros_ec barometer driver
Handle the barometer sensor presented by the ChromeOS EC Sensor hub.

Signed-off-by: Gwendal Grignou <gwendal@chromium.org>
Signed-off-by: Enric Balletbo Serra <enric.balletbo@collabora.com>
Signed-off-by: Jonathan Cameron <jic23@kernel.org>
2017-01-28 15:07:46 +00:00
Vincent Palatin e4244ebdda platform/chrome: Introduce a new function to check EC features.
Use the EC_CMD_GET_FEATURES message to check the supported features for
each MCU.

Signed-off-by: Vincent Palatin <vpalatin@chromium.org>
[tomeu: adapted to changes in mainline]
Signed-off-by: Tomeu Vizoso <tomeu.vizoso@collabora.com>
[enric: remove references to USB PD feature and do it more generic]
Signed-off-by: Enric Balletbo i Serra <enric.balletbo@collabora.com>
Reviewed-by: Guenter Roeck <groeck@chromium.org>
For the MFD changes:
  Acked-by: Lee Jones <lee.jones@linaro.org>
Signed-off-by: Jonathan Cameron <jic23@kernel.org>
2016-10-25 18:20:29 +01:00
Enric Balletbo i Serra 974e6f02e2 iio: cros_ec_sensors_core: Add common functions for the ChromeOS EC Sensor Hub.
Add the core functions to be able to support the sensors attached behind
the ChromeOS Embedded Controller and used by other IIO cros-ec sensor
drivers.

The cros_ec_sensor_core driver matches with current driver in ChromeOS
4.4 tree, so it includes all the fixes at the moment. The support for
this driver was made by Gwendal Grignou. The original patch and all the
fixes has been squashed and rebased on top of mainline.

Signed-off-by: Gwendal Grignou <gwendal@chromium.org>
Signed-off-by: Guenter Roeck <groeck@chromium.org>
[eballetbo: split, squash and rebase on top of mainline the patches
found in ChromeOS tree]
Signed-off-by: Enric Balletbo i Serra <enric.balletbo@collabora.com>
Signed-off-by: Jonathan Cameron <jic23@kernel.org>
2016-10-25 18:20:05 +01:00
Vic Yang 6f1d912b68 mfd: cros_ec: Add MKBP event support
Newer revisions of the ChromeOS EC add more events besides the keyboard
ones. So handle interrupts in the MFD driver and let consumers register
for notifications for the events they might care.

To keep backward compatibility, if the EC doesn't support MKBP event, we
fall back to the old MKBP key matrix host command.

Cc: Randall Spangler <rspangler@chromium.org>
Cc: Vincent Palatin <vpalatin@chromium.org>
Cc: Benson Leung <bleung@chromium.org>
Signed-off-by: Vic Yang <victoryang@google.com>
Signed-off-by: Tomeu Vizoso <tomeu.vizoso@collabora.com>
Tested-by: Enric Balletbo i Serra <enric.balletbo@collabora.com>
Acked-by: Olof Johansson <olof@lixom.net>
Signed-off-by: Lee Jones <lee.jones@linaro.org>
2016-08-31 10:50:59 +01:00
Brian Norris 2b66bd692c mfd: cros_ec: Add EC_PWM function definitions
The EC_CMD_PWM_{GET,SET}_DUTY commands allow us to control a PWM that is
attached to the EC, rather than the main host SoC. The API provides
functionality-based (e.g., keyboard light, backlight) or index-based
addressing of the PWM(s). Duty cycles are represented by a 16-bit value,
where 0 maps to 0% duty cycle and U16_MAX maps to 100%. The period
cannot be controlled.

This command set is more generic than, e.g.,
EC_CMD_PWM_{GET,SET}_KEYBOARD_BACKLIGHT and could possibly used to
replace it on future products.

Let's update the command header to include the definitions.

Signed-off-by: Brian Norris <briannorris@chromium.org>
Acked-by: Lee Jones <lee.jones@linaro.org>
Signed-off-by: Thierry Reding <thierry.reding@gmail.com>
2016-07-25 10:33:03 +02:00
Stephen Barber 256ab950bd mfd: cros_ec: rev cros_ec_commands.h
Update cros_ec_commands.h to the latest version in the EC
firmware sources and add power domain and passthru commands.

Also, update lightbar to use new command names.

Signed-off-by: Stephen Barber <smbarber@chromium.org>
Reviewed-by: Randall Spangler <rspangler@chromium.org>
Signed-off-by: Javier Martinez Canillas <javier.martinez@collabora.co.uk>
Tested-by: Heiko Stuebner <heiko@sntech.de>
Reviewed-by: Gwendal Grignou <gwendal@chromium.org>
Tested-by: Gwendal Grignou <gwendal@chromium.org>
Acked-by: Lee Jones <lee.jones@linaro.org>
Acked-by: Olof Johansson <olof@lixom.net>
Signed-off-by: Lee Jones <lee.jones@linaro.org>
2015-06-15 13:18:20 +01:00
Doug Anderson d8e0a86f97 i2c: cros_ec: Remove EC_I2C_FLAG_10BIT
In <https://lkml.org/lkml/2014/6/10/265> pointed out that the 10-bit
flag in the cros_ec_tunnel was useless.  It went into a 16-bit flags
field but was defined at (1 << 16).

Since we have no 10-bit i2c devices on the other side of the tunnel on
any known devices this was never a problem.  Until we do it makes
sense to remove this code.  On the EC side the code to handle this
flag was removed in <https://chromium-review.googlesource.com/204162>.

Reported-by: Dave Jones <davej@redhat.com>
Signed-off-by: Doug Anderson <dianders@chromium.org>
Reviewed-by: Simon Glass <sjg@chromium.org>
Signed-off-by: Wolfram Sang <wsa@the-dreams.de>
2014-09-30 08:06:02 +02:00
Bill Richardson 5271db29d7 mfd: cros_ec: Sync to the latest cros_ec_commands.h from EC sources
This just updates include/linux/mfd/cros_ec_commands.h to match the
latest EC version (which is the One True Source for such things).  See
<https://chromium.googlesource.com/chromiumos/platform/ec>

[dianders: took today's ToT version from the Chromium OS EC; deleted
references to cros_ec_dev and cros_ec_lpc since those aren't upstream
yet]

Signed-off-by: Bill Richardson <wfrichar@chromium.org>
Signed-off-by: Doug Anderson <dianders@chromium.org>
Reviewed-by: Simon Glass <sjg@chromium.org>
Tested-by: Andrew Bresticker <abrestic@chromium.org>
Tested-by: Stephen Warren <swarren@nvidia.com>
Signed-off-by: Lee Jones <lee.jones@linaro.org>
2014-06-03 08:11:48 +01:00
Simon Glass deaf39efbc mfd: Add ChromeOS EC messages header
This file is included verbatim from the ChromeOS EC respository.
Ideally we would prefer to avoid changing it, to make it easier
to track this rapidly-changing file.

Signed-off-by: Simon Glass <sjg@chromium.org>
Signed-off-by: Che-Liang Chiou <clchiou@chromium.org>
Signed-off-by: Vincent Palatin <vpalatin@chromium.org>
Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
2013-04-05 11:20:13 +02:00