Re: [PATCH v12 2/5] regulator: Add support for MediaTek MT6373 SPMI PMIC Regulators
From: Mark Brown
Date: Mon May 11 2026 - 22:04:48 EST
On Mon, May 11, 2026 at 12:13:52PM +0200, AngeloGioacchino Del Regno wrote:
> +static int mt6373_buck_unlock(struct regmap *map, bool unlock)
> +{
> + u16 buf = unlock ? MT6373_BUCK_TOP_UNLOCK_VALUE : 0;
> +
> + return regmap_bulk_write(map, MT6373_BUCK_TOP_KEY_PROT_LO, &buf, sizeof(buf));
regmap_bulk_write() takes a number of registers.
> +static irqreturn_t mt6373_oc_isr(int irq, void *data)
> +{
> + struct regulator_dev *rdev = (struct regulator_dev *)data;
> + struct mt6373_regulator_info *info = rdev_get_drvdata(rdev);
> +
> + disable_irq_nosync(info->virq);
> +
> + if (regulator_is_enabled_regmap(rdev))
> + regulator_notifier_call_chain(rdev, REGULATOR_EVENT_OVER_CURRENT, NULL);
If the hardware is reporting an error we should report an error.
> + INIT_DELAYED_WORK(&info->oc_work, mt6373_oc_irq_enable_work);
What stops this work on driver removal/unbind?
Attachment:
signature.asc
Description: PGP signature