Commit a1cba0e2 authored by Muhammad Usama Anjum's avatar Muhammad Usama Anjum Committed by Jonathan Cameron
Browse files

iio: frequency: admv1013: remove the always true condition



unsigned int variable is always greater than or equal to zero. Make the
if condition simple.

Signed-off-by: default avatarMuhammad Usama Anjum <usama.anjum@collabora.com>
Fixes: da35a7b5 ("iio: frequency: admv1013: add support for ADMV1013")
Link: https://lore.kernel.org/r/YdS3gJYtECMaDDjA@debian-BULLSEYE-live-builder-AMD64


Signed-off-by: default avatarJonathan Cameron <Jonathan.Cameron@huawei.com>
parent ccbed9d8
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -348,7 +348,7 @@ static int admv1013_update_mixer_vgate(struct admv1013_state *st)

	vcm = regulator_get_voltage(st->reg);

	if (vcm >= 0 && vcm < 1800000)
	if (vcm < 1800000)
		mixer_vgate = (2389 * vcm / 1000000 + 8100) / 100;
	else if (vcm > 1800000 && vcm < 2600000)
		mixer_vgate = (2375 * vcm / 1000000 + 125) / 100;