Commit Graph

6 Commits

Author SHA1 Message Date
Linus Torvalds 06e23d5115 - Core Frameworks
- New API to call bespoke pre/post IRQ handlers; Regmap
  - New Device Support
    - Add support for RN5T567 to rn5t618
    - Add support for COMe-cSL6 and COMe-mAL10 to kempld-core
  - New Functionality
    - Add support for USB Power Supply to axp20x
    - Add support for Power Key to hi655x-pmic
  - Fix-ups
    - Update MAINTAINERS; Dialog, Altera
    - Remove module support; max77843, max77620, max8998, max8997, max8925-i2c
    - Add module support; max14577
    - Constifying; max77620
    - Allow bespoke IRQ masking/unmasking; max77620
    - Remove superfluous code; arizona, qcom_rpm, smsc-ece1099
    - Power Management fixups; arizona-core
    - Error-path improvement; twl-core, dm355evm_msp, smsc-ece1099, hi655x
    - Clocking fixups; twl6040
    - Trivial (spelling, headers, coding-style, whitespace, (re)naming);
        si476x-i2c, omap-usb-tll, ti_am335x_tscadc, tps6507, hi655x-pmic
 - Bug Fixes
    - Fix offset error for MSM8660; qcom_rpm
    - Fix possible spurious IRQs; arizona, hi655x-pmic
 -----BEGIN PGP SIGNATURE-----
 Version: GnuPG v2
 
 iQIcBAABCAAGBQJXnxUiAAoJEFGvii+H/HdhjY4P/i9EeGo4rSKyMNYvSIV+FwpB
 W63eOeEf08EzLfaTyDTnJ9FO53UvcJEXvVE7jO5oYWI8g5y5zBinbwk041uUIeuN
 5gv/3quW0kiOozd+6VBghaLYbj37ZZLqBFXc0sYpHNwcIrfVboTaiUrFkl9wUXKQ
 Gbi7mAw0JhgzigQX2oPmylsdJ2u+MuwxLOcL43HoYLQ6E9b5ZmMqHqz0X7zwjh2c
 og+WYSl2VOe001fRoLZIPPkE6r61IWZ85oojuZKeQnIiadZWXGwY3XMcYDcheVuz
 6BC/f5Vt9PacDPjuInfI4Mv8ROmhnvoNgB9xgoUDROAn5m5FgqdHGZPK40hE+uVy
 cWRQjdI9CiTTcogGepJGY57OlB7T7q+Peue00knjQiiYdtS2jU4E0xNOWPO/8ILD
 EV8yeYbD9yghhA1vFc5pzOEQnBD9q9zX40N36vJp4cgl6jO25R/PkLeTg5KufFoi
 6+H9VAgqevg4/D8R63Yj8ANdEAvTVupLcpzwORgz89jKF4x5fDU782L5nGifx6dt
 hNlan00bLrSL6sWtAqCvezSNlF2Aqb6qHhdnvIV93VGeteVMU6N1wRB3JH08HFQI
 C5t+qFqlxJn3R5E8ur/6ZhtkiPnC4qCVR+r9uyH6Aix9bR1W18o0jgypuZMu7E+h
 czIJMLv97drOVtzYsosz
 =KB2d
 -----END PGP SIGNATURE-----

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

Pull MFD updates from Lee Jones:
 "Core Framework:
   - New API to call bespoke pre/post IRQ handlers; Regmap

  New Device Support:
   - Add support for RN5T567 to rn5t618
   - Add support for COMe-cSL6 and COMe-mAL10 to kempld-core

  New Functionality:
   - Add support for USB Power Supply to axp20x
   - Add support for Power Key to hi655x-pmic

  Fix-ups:
   - Update MAINTAINERS; Dialog, Altera
   - Remove module support; max77843, max77620, max8998, max8997, max8925-i2c
   - Add module support; max14577
   - Constifying; max77620
   - Allow bespoke IRQ masking/unmasking; max77620
   - Remove superfluous code; arizona, qcom_rpm, smsc-ece1099
   - Power Management fixups; arizona-core
   - Error-path improvement; twl-core, dm355evm_msp, smsc-ece1099, hi655x
   - Clocking fixups; twl6040
   - Trivial (spelling, headers, coding-style, whitespace, (re)naming);
       si476x-i2c, omap-usb-tll, ti_am335x_tscadc, tps6507, hi655x-pmic

  Bug Fixes:
   - Fix offset error for MSM8660; qcom_rpm
   - Fix possible spurious IRQs; arizona, hi655x-pmic"

* tag 'mfd-for-linus-4.8' of git://git.kernel.org/pub/scm/linux/kernel/git/lee/mfd: (42 commits)
  mfd: qcom_rpm: Parametrize also ack selector size
  mfd: twl6040: Handle mclk used for HPPLL and optional internal clock source
  mfd: Add support for COMe-cSL6 and COMe-mAL10 to Kontron PLD driver
  mfd: hi655x: Fix return value check in hi655x_pmic_probe()
  mfd: smsc-ece1099: Return directly after a function failure in smsc_i2c_probe()
  mfd: smsc-ece1099: Delete an unnecessary variable initialisation in smsc_i2c_probe()
  mfd: dm355evm_msp: Return directly after a failed platform_device_alloc() in add_child()
  mfd: twl-core: Refactoring for add_numbered_child()
  mfd: twl-core: Return directly after a failed platform_device_alloc() in add_numbered_child()
  mfd: arizona: Add missing disable of PM runtime on probe error path
  mfd: stmpe: Move platform data into MFD driver
  mfd: max14577: Allow driver to be built as a module
  mfd: max14577: Use module_init() instead of subsys_initcall()
  mfd: arizona: Remove some duplicate defines
  mfd: qcom_rpm: Remove unused define
  mfd: hi655x-pmic: Add powerkey device to hi655x PMIC driver
  mfd: hi655x-pmic: Rename some interrupt macro names
  mfd: hi655x-pmic: Fixup issue with un-acked interrupts
  mfd: arizona: Check if AOD interrupts are pending before dispatching
  mfd: qcom_rpm: Fix offset error for msm8660
  ...
2016-08-01 07:28:14 -04:00
Rhyland Klein 82d8eb40ba mfd: max77620: Fix FPS switch statements
When configuring FPS during probe, assuming a DT node is present for
FPS, the code can run into a problem with the switch statements in
max77620_config_fps() and max77620_get_fps_period_reg_value(). Namely,
in the case of chip->chip_id == MAX77620, it will set
fps_[mix|max]_period but then fall through to the default switch case
and return -EINVAL. Returning this from max77620_config_fps() will
cause probe to fail.

Signed-off-by: Rhyland Klein <rklein@nvidia.com>
Reviewed-by: Laxman Dewangan <ldewangan@nvidia.com>
Reviewed-by: Thierry Reding <treding@nvidia.com>
Tested-by: Thierry Reding <treding@nvidia.com>
Tested-by: Alexandre Courbot <acourbot@nvidia.com>
Signed-off-by: Lee Jones <lee.jones@linaro.org>
2016-06-30 07:44:23 +01:00
Laxman Dewangan 3df140d11c mfd: max77620: Mask/unmask interrupt before/after servicing it
The programming guidelines of the MAX77620 for servicing interrupt is:
1. When interrupt occurs from PMIC, mask the PMIC interrupt by
   setting GLBLM.
2. Read IRQTOP and service the interrupt.
3. Once all interrupts has been checked and serviced, the interrupt
   service routine un-masks the hardware interrupt line by clearing
   GLBLM.

Add the pre and post interrupt service handler for mask and unmask the
global interrupt mask bit (for step 1 and 3) as callback from regmap-irq.

Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com>
Signed-off-by: Lee Jones <lee.jones@linaro.org>
2016-06-29 10:14:38 +01:00
Axel Lin 2be59755e6 mfd: max77620: Constify resources tables
These tables are never modified, so declare them as const.

Signed-off-by: Axel Lin <axel.lin@ingics.com>
Signed-off-by: Lee Jones <lee.jones@linaro.org>
2016-06-29 10:14:32 +01:00
Paul Gortmaker c1fe7c4526 mfd: max77620: Make it explicitly non-modular
The Kconfig currently controlling compilation of this code is:

drivers/mfd/Kconfig:config MFD_MAX77620
drivers/mfd/Kconfig:    bool "Maxim Semiconductor MAX77620 and MAX20024 PMIC Support"

...meaning that it currently is not being built as a module by anyone.

Lets remove the modular code that is essentially orphaned, so that
when reading the driver there is no doubt it is builtin-only.

Since module_i2c_driver() uses the same init level priority as
builtin_i2c_driver() the init ordering remains unchanged with
this commit.

Also note that MODULE_DEVICE_TABLE is a no-op for non-modular code.

We also delete the MODULE_LICENSE tag etc. since all that information
was (or is now) contained at the top of the file in the comments.

Signed-off-by: Paul Gortmaker <paul.gortmaker@windriver.com>
Signed-off-by: Lee Jones <lee.jones@linaro.org>
2016-06-29 10:14:29 +01:00
Laxman Dewangan 327156c593 mfd: max77620: Add core driver for MAX77620/MAX20024
MAX77620/MAX20024 are Power Management IC from the MAXIM.
It supports RTC, multiple GPIOs, multiple DCDC and LDOs,
watchdog, clock etc.

Add MFD drier to provides common support for accessing the
device; additional drivers is developed on respected subsystem
in order to use the functionality of the device.

Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com>
Signed-off-by: Mallikarjun Kasoju <mkasoju@nvidia.com>
Reviewed-by: Krzysztof Kozlowski <k.kozlowski@samsung.com>
Signed-off-by: Lee Jones <lee.jones@linaro.org>
2016-05-09 15:42:00 +01:00