Re: [RFC PATCH 2/5] mfd: drivers: Add TI TPS65219 PMIC support

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Jerome NEANNE <jneanne@xxxxxxxxxxxx> writes:

> The TPS65219 is a power management IC PMIC designed
> to supply a wide range of SoCs
> in both portable and stationary applications.
> Any SoC can control TPS65219 over a standard I2C interface.
>
> It contains the following components:
> - Regulators.
> - Over Temperature warning and Shut down.
> - GPIOs
> - Multi Function Pins (MFP)
>
> This patch adds support for tps65219 mfd device. At this time only
> the functionalities listed below are made available:
>
> - Regulators probe and functionalities
> - warm and cold reset support
> - SW shutdown support
>
> Signed-off-by: Jerome NEANNE <jneanne@xxxxxxxxxxxx>

[...]

> +/**
> + * pmic_rst_restart: trig tps65219 reset to SOC.
> + *
> + * Trigged via notifier
> + */
> +static int pmic_rst_restart(struct notifier_block *this,
> +			  unsigned long mode, void *cmd)
> +{
> +	struct tps65219 *tps;
> +
> +	tps = container_of(this, struct tps65219, nb);
> +	if (tps != NULL) {
> +		if (WARMNCOLD)

This value is hard-coded to 1 in the header, so war reset will always be
done.  

> +			tps65219_warm_reset(tps);
> +		else
> +			tps65219_cold_reset(tps);

Doesn't the reboot_notifier get a value like REBOOT_WARM,
REBOOT_COLD etc (c.f. enum in linux/reboot.h)  so you could properly select?

Kevin



[Index of Archives]     [Device Tree Compilter]     [Device Tree Spec]     [Linux Driver Backports]     [Video for Linux]     [Linux USB Devel]     [Linux PCI Devel]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [XFree86]     [Yosemite Backpacking]


  Powered by Linux