mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-28 02:32:09 -04:00
LED updates for 4.10 merge cycle.
-----BEGIN PGP SIGNATURE----- Version: GnuPG v2 iQIcBAABCAAGBQJYToOYAAoJEL1qUBy3i3wmKL8QAKKJo17+3X+dWdmyqJ3sNa7r YiWvaOUv6OBnOwc2ETfzprk0YsKsvuHEUAehjoUBwqNBDs/lnEnfwv4EfiISmv6R sKQP38Q92RgfSnYfDGy/U8VgPgAMintA1/PRrxZTYpMiqX3QZa9HLRO2LmyC/Nuk Td0lVvAS/PpGCFqk4xwGfn/pVfgBjmdyCoQTVpJoh2fn64V3Jd56YzVekOQd6Koc 7eIyy64Bmh3gNWxOExqPFhzSotysPKvfAz6BHcv0IpI6Wio+Rek7E3OY//VlntaH Wnn086QcGzcAAT6irJ7AMLsU03j2Dr4zhPvVdiHTqsm+7YOfP7ugT+OCdCkbh3Y9 HYQoCFXL1uPt68Vcc+72ijEytUhNm1p3ri1+jKl8hlg93+0eZ2g/zNxgQZ6kLuQw 2s4P4FGC8TnaG213k6or/UaAocIfOhHWpf0ymMT7Hu6JSQJQTGjS29dqfY17YMCN UxvXyT/j+QHskJnvDBhmblrnXe516MpQiMxookuVUh1gDHTGdB+A23Hj4W57mA95 WpQm36MmDuD6ri4hywLv+fEVTc1FrbjZOdi8AoAsWDJEOY5K4QLfzreHk3QnCpDg S1HGIr9QcC4aMtXyE5o1ahKX0e2A3kgu22hQtk6w7eAnvwdS7PaB2F0eVEOoI85C Epxp4ni5Jgb7013Hoq2e =4k30 -----END PGP SIGNATURE----- Merge tag 'leds_for_4.10' of git://git.kernel.org/pub/scm/linux/kernel/git/j.anaszewski/linux-leds Pull LED updates from Jacek Anaszewski: - userspace LED class driver - it can be useful for testing triggers and can also be used to implement virtual LEDs - LED class driver for NIC78bx device - LED core fixes for preventing potential races while setting brightness when software blinking is enabled - improvements in LED documentation to mention semantics on changing brightness while trigger is active * tag 'leds_for_4.10' of git://git.kernel.org/pub/scm/linux/kernel/git/j.anaszewski/linux-leds: leds: pca955x: Add ACPI support leds: netxbig: fix module autoload for OF registration leds: pca963x: Add ACPI support leds: leds-cobalt-raq: use builtin_platform_driver led: core: Fix blink_brightness setting race led: core: Use atomic bit-field for the blink-flags leds: Add user LED driver for NIC78bx device leds: verify vendor and change license in mlxcpld driver leds: pca963x: enable low-power state leds: pca9532: Use default trigger value from platform data leds: pca963x: workaround group blink scaling issue cleanup LED documentation and make it match reality leds: lp3952: Export I2C module alias information for module autoload leds: mc13783: Fix MC13892 keypad led access ledtrig-cpu.c: fix english leds/leds-lp5523.txt: make documentation match reality tools/leds: Add uledmon program for monitoring userspace LEDs leds: Use macro for max device node name size leds: Introduce userspace LED class driver mfd: qcom-pm8xxx: Clean up PM8XXX namespace
This commit is contained in:
commit
1f0a53f623
32 changed files with 807 additions and 107 deletions
|
|
@ -756,24 +756,20 @@ config UCB1400_CORE
|
|||
module will be called ucb1400_core.
|
||||
|
||||
config MFD_PM8XXX
|
||||
tristate
|
||||
|
||||
config MFD_PM8921_CORE
|
||||
tristate "Qualcomm PM8921 PMIC chip"
|
||||
tristate "Qualcomm PM8xxx PMIC chips driver"
|
||||
depends on (ARM || HEXAGON)
|
||||
select IRQ_DOMAIN
|
||||
select MFD_CORE
|
||||
select MFD_PM8XXX
|
||||
select REGMAP
|
||||
help
|
||||
If you say yes to this option, support will be included for the
|
||||
built-in PM8921 PMIC chip.
|
||||
built-in PM8xxx PMIC chips.
|
||||
|
||||
This is required if your board has a PM8921 and uses its features,
|
||||
This is required if your board has a PM8xxx and uses its features,
|
||||
such as: MPPs, GPIOs, regulators, interrupts, and PWM.
|
||||
|
||||
Say M here if you want to include support for PM8921 chip as a module.
|
||||
This will build a module called "pm8921-core".
|
||||
Say M here if you want to include support for PM8xxx chips as a
|
||||
module. This will build a module called "pm8xxx-core".
|
||||
|
||||
config MFD_QCOM_RPM
|
||||
tristate "Qualcomm Resource Power Manager (RPM)"
|
||||
|
|
|
|||
|
|
@ -172,7 +172,7 @@ obj-$(CONFIG_MFD_SI476X_CORE) += si476x-core.o
|
|||
|
||||
obj-$(CONFIG_MFD_CS5535) += cs5535-mfd.o
|
||||
obj-$(CONFIG_MFD_OMAP_USB_HOST) += omap-usb-host.o omap-usb-tll.o
|
||||
obj-$(CONFIG_MFD_PM8921_CORE) += pm8921-core.o ssbi.o
|
||||
obj-$(CONFIG_MFD_PM8XXX) += qcom-pm8xxx.o ssbi.o
|
||||
obj-$(CONFIG_MFD_QCOM_RPM) += qcom_rpm.o
|
||||
obj-$(CONFIG_MFD_SPMI_PMIC) += qcom-spmi-pmic.o
|
||||
obj-$(CONFIG_TPS65911_COMPARATOR) += tps65911-comparator.o
|
||||
|
|
|
|||
|
|
@ -53,7 +53,7 @@
|
|||
#define REG_HWREV 0x002 /* PMIC4 revision */
|
||||
#define REG_HWREV_2 0x0E8 /* PMIC4 revision 2 */
|
||||
|
||||
#define PM8921_NR_IRQS 256
|
||||
#define PM8XXX_NR_IRQS 256
|
||||
|
||||
struct pm_irq_chip {
|
||||
struct regmap *regmap;
|
||||
|
|
@ -308,22 +308,22 @@ static const struct regmap_config ssbi_regmap_config = {
|
|||
.reg_write = ssbi_reg_write
|
||||
};
|
||||
|
||||
static const struct of_device_id pm8921_id_table[] = {
|
||||
static const struct of_device_id pm8xxx_id_table[] = {
|
||||
{ .compatible = "qcom,pm8018", },
|
||||
{ .compatible = "qcom,pm8058", },
|
||||
{ .compatible = "qcom,pm8921", },
|
||||
{ }
|
||||
};
|
||||
MODULE_DEVICE_TABLE(of, pm8921_id_table);
|
||||
MODULE_DEVICE_TABLE(of, pm8xxx_id_table);
|
||||
|
||||
static int pm8921_probe(struct platform_device *pdev)
|
||||
static int pm8xxx_probe(struct platform_device *pdev)
|
||||
{
|
||||
struct regmap *regmap;
|
||||
int irq, rc;
|
||||
unsigned int val;
|
||||
u32 rev;
|
||||
struct pm_irq_chip *chip;
|
||||
unsigned int nirqs = PM8921_NR_IRQS;
|
||||
unsigned int nirqs = PM8XXX_NR_IRQS;
|
||||
|
||||
irq = platform_get_irq(pdev, 0);
|
||||
if (irq < 0)
|
||||
|
|
@ -384,46 +384,46 @@ static int pm8921_probe(struct platform_device *pdev)
|
|||
return rc;
|
||||
}
|
||||
|
||||
static int pm8921_remove_child(struct device *dev, void *unused)
|
||||
static int pm8xxx_remove_child(struct device *dev, void *unused)
|
||||
{
|
||||
platform_device_unregister(to_platform_device(dev));
|
||||
return 0;
|
||||
}
|
||||
|
||||
static int pm8921_remove(struct platform_device *pdev)
|
||||
static int pm8xxx_remove(struct platform_device *pdev)
|
||||
{
|
||||
int irq = platform_get_irq(pdev, 0);
|
||||
struct pm_irq_chip *chip = platform_get_drvdata(pdev);
|
||||
|
||||
device_for_each_child(&pdev->dev, NULL, pm8921_remove_child);
|
||||
device_for_each_child(&pdev->dev, NULL, pm8xxx_remove_child);
|
||||
irq_set_chained_handler_and_data(irq, NULL, NULL);
|
||||
irq_domain_remove(chip->irqdomain);
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
static struct platform_driver pm8921_driver = {
|
||||
.probe = pm8921_probe,
|
||||
.remove = pm8921_remove,
|
||||
static struct platform_driver pm8xxx_driver = {
|
||||
.probe = pm8xxx_probe,
|
||||
.remove = pm8xxx_remove,
|
||||
.driver = {
|
||||
.name = "pm8921-core",
|
||||
.of_match_table = pm8921_id_table,
|
||||
.name = "pm8xxx-core",
|
||||
.of_match_table = pm8xxx_id_table,
|
||||
},
|
||||
};
|
||||
|
||||
static int __init pm8921_init(void)
|
||||
static int __init pm8xxx_init(void)
|
||||
{
|
||||
return platform_driver_register(&pm8921_driver);
|
||||
return platform_driver_register(&pm8xxx_driver);
|
||||
}
|
||||
subsys_initcall(pm8921_init);
|
||||
subsys_initcall(pm8xxx_init);
|
||||
|
||||
static void __exit pm8921_exit(void)
|
||||
static void __exit pm8xxx_exit(void)
|
||||
{
|
||||
platform_driver_unregister(&pm8921_driver);
|
||||
platform_driver_unregister(&pm8xxx_driver);
|
||||
}
|
||||
module_exit(pm8921_exit);
|
||||
module_exit(pm8xxx_exit);
|
||||
|
||||
MODULE_LICENSE("GPL v2");
|
||||
MODULE_DESCRIPTION("PMIC 8921 core driver");
|
||||
MODULE_DESCRIPTION("PMIC 8xxx core driver");
|
||||
MODULE_VERSION("1.0");
|
||||
MODULE_ALIAS("platform:pm8921-core");
|
||||
MODULE_ALIAS("platform:pm8xxx-core");
|
||||
Loading…
Reference in a new issue