The pm8xxx read/write wrappers are no longer necessary now that
all the sub-device drivers are using the regmap API. Remove it.
Signed-off-by: Stephen Boyd <[email protected]>
Signed-off-by: Lee Jones <[email protected]>
platform_get_irq() returns a negative error code when an IRQ is invalid
or unspecified. Make 'irq' signed to properly handle this.
Reviewed-by: Stephen Boyd <[email protected]>
Signed-off-by: Josh Cartwright <[email protected]>
Signed-off-by: Lee Jones <[email protected]>
We don't need to implement a dummy irq_set_wake op if we just set
IRQCHIP_SKIP_SET_WAKE.
Suggested-by: Josh Cartwright <[email protected]>
Signed-off-by: Stephen Boyd <[email protected]>
Signed-off-by: Lee Jones <[email protected]>
This isn't necessary as we aren't setting the summary interrupt
to wake up the system in the irq_wake() callback.
Signed-off-by: Stephen Boyd <[email protected]>
Signed-off-by: Lee Jones <[email protected]>
Use a regmap so that the pm8xxx read/write APIs can be removed
once all consumer drivers are converted.
Reviewed-by: Mark Brown <[email protected]>
Signed-off-by: Stephen Boyd <[email protected]>
Signed-off-by: Lee Jones <[email protected]>
Convert this driver to use irqdomains so that the PMIC's child
devices can be converted to devicetree.
Acked-by: Lee Jones <[email protected]>
Signed-off-by: Stephen Boyd <[email protected]>
Since this code has been marked broken for some time a few genirq
tree wide changes weren't made. set_irq_wake() was renamed to
irq_set_irq_wake() in commit a0cd9ca2b (genirq: Namespace
cleanup, 2011-02-10) and commit 10a8c383 (irq: introduce entry
and exit functions for chained handlers) introduced the chained
irq functions but this driver wasn't updated to use them. Fix
these problems and remove the BROKEN marking on this driver.
Signed-off-by: Stephen Boyd <[email protected]>
Signed-off-by: Lee Jones <[email protected]>
The pm8xxx-irq.c code is practically mandatory given that the
pm8921-core driver will WARN about it missing and the Kconfig
marks it as default y when a PM8xxx chips is enabled. The only
reason the file was split out was because we planned to support
other pm8xxx chips with different pm8xxx-core.c files. Now that
we have DT on ARM this isn't necessary because we should be able
to support all the ssbi based PM8xxx chips in one driver and one
file with no data bloat. Let's move this code into the only
driver that uses it right now (pm8921) so that it's always compiled when
needed. In the future we can rename pm8921-core.c to something
more generic.
Signed-off-by: Stephen Boyd <[email protected]>
Signed-off-by: Lee Jones <[email protected]>
We assume that "pmic" could be NULL and then dereference it two lines
later. I fix this by moving the dereference inside the NULL check.
Fixes: c013f0a56c ('mfd: Add pm8xxx irq support')
Signed-off-by: Dan Carpenter <[email protected]>
Signed-off-by: Lee Jones <[email protected]>
The driver core clears the driver data to NULL after device_release
or on probe failure, since commit 0998d06310
(device-core: Ensure drvdata = NULL when no driver is bound).
Thus, it is not needed to manually clear the device driver data to NULL.
Signed-off-by: Jingoo Han <[email protected]>
Signed-off-by: Lee Jones <[email protected]>
Include <linux/module.h> in order to fix the following errors.
drivers/mfd/pm8921-core.c:209:16: error: expected declaration specifiers or '...' before string constant
drivers/mfd/pm8921-core.c:210:20: error: expected declaration specifiers or '...' before string constant
drivers/mfd/pm8921-core.c:211:16: error: expected declaration specifiers or '...' before string constant
drivers/mfd/pm8921-core.c:212:14: error: expected declaration specifiers or '...' before string constant
Signed-off-by: Jingoo Han <[email protected]>
Signed-off-by: Lee Jones <[email protected]>
Use the wrapper function for retrieving the platform data instead of
accessing dev->platform_data directly.
Signed-off-by: Jingoo Han <[email protected]>
Signed-off-by: Lee Jones <[email protected]>
Although the SSBI sub is currently only used on MSM SoCs, it is still
a bus in its own right. Remove this msm_ prefix from the driver and
it's symbols. Clients can now refer directly to ssbi_write() and
ssbi_read().
Signed-off-by: David Brown <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
Add support for the irq controller in Qualcomm 8xxx pmic. The 8xxx
interrupt controller provides control for gpio and mpp configured as
interrupts in addition to other subdevice interrupts. The interrupt
controller also provides a way to read the real time status of an
interrupt. This real time status is the only way one can get the
input values of gpio and mpp lines.
Signed-off-by: Abhijeet Dharmapurikar <[email protected]>
Signed-off-by: Samuel Ortiz <[email protected]>
Add support for the Qualcomm PM8921 PMIC chip. The core driver
will communicate with the PMIC chip via the MSM SSBI bus.
Signed-off-by: Abhijeet Dharmapurikar <[email protected]>
Signed-off-by: Samuel Ortiz <[email protected]>