Message ID | 20240124165558.1876407-5-ckeepax@opensource.cirrus.com (mailing list archive) |
---|---|
State | Superseded |
Headers | show |
Series | [1/7] ASoC: cs42l43: Tidy up header includes | expand |
On Wed, Jan 24, 2024 at 6:56 PM Charles Keepax <ckeepax@opensource.cirrus.com> wrote: Commit message? > Suggested-by: Andy Shevchenko <andy.shevchenko@gmail.com> > Signed-off-by: Charles Keepax <ckeepax@opensource.cirrus.com> Otherwise, LGTM, Reviewed-by: Andy Shevchenko <andy.shevchenko@gmail.com>
diff --git a/sound/soc/codecs/cs42l43-jack.c b/sound/soc/codecs/cs42l43-jack.c index 147c7017fd8b6..4bcf66cff566a 100644 --- a/sound/soc/codecs/cs42l43-jack.c +++ b/sound/soc/codecs/cs42l43-jack.c @@ -17,6 +17,7 @@ #include <linux/pm_runtime.h> #include <linux/property.h> #include <linux/regmap.h> +#include <linux/time.h> #include <linux/workqueue.h> #include <sound/control.h> #include <sound/jack.h> @@ -647,7 +648,7 @@ static int cs42l43_run_load_detect(struct cs42l43_codec *priv, bool mic) static int cs42l43_run_type_detect(struct cs42l43_codec *priv) { struct cs42l43 *cs42l43 = priv->core; - int timeout_ms = ((2 * priv->detect_us) / 1000) + 200; + int timeout_ms = ((2 * priv->detect_us) / USEC_PER_MSEC) + 200; unsigned int type = 0xff; unsigned long time_left;
Suggested-by: Andy Shevchenko <andy.shevchenko@gmail.com> Signed-off-by: Charles Keepax <ckeepax@opensource.cirrus.com> --- sound/soc/codecs/cs42l43-jack.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-)