The name of property "dongwoon,vcm-freq" doesn't match its purpose.
Change the name of the property to "dongwoon,vcm-prescale" to better
describe its purpose and deprecate the old one.
Signed-off-by: André Apitzsch <git@apitzsch.eu>
Signed-off-by: Sakari Ailus <sakari.ailus@linux.intel.com>
Signed-off-by: Hans Verkuil <hverkuil+cisco@kernel.org>
{
u64 val;
int ret;
+ int err;
ret = regulator_enable(dw9719->regulator);
if (ret)
&dw9719->sac_mode);
/* Optional indication of VCM frequency */
- device_property_read_u32(dw9719->dev, "dongwoon,vcm-freq",
+ err = device_property_read_u32(dw9719->dev, "dongwoon,vcm-freq",
+ &dw9719->vcm_freq);
+ if (err == 0)
+ dev_warn(dw9719->dev, "dongwoon,vcm-freq property is deprecated, please use dongwoon,vcm-prescale\n");
+
+ /* Optional indication of VCM prescale */
+ device_property_read_u32(dw9719->dev, "dongwoon,vcm-prescale",
&dw9719->vcm_freq);
}