ANDROID: add pwm_apply_state() function back

pwm_apply_state() was renamed to pwm_apply_might_sleep() in commit
a10c3d5ff9 ("pwm: Rename pwm_apply_state() to
pwm_apply_might_sleep()") but many external modules were already
expecting to use this function.  So put it back as a wrapper so that
things continue to build properly.

Bug: 161946584
Fixes: a10c3d5ff9 ("pwm: Rename pwm_apply_state() to pwm_apply_might_sleep()")
Change-Id: I79901fc07206b1a3c65593b6d5e5e7d6924aa197
Signed-off-by: Greg Kroah-Hartman <gregkh@google.com>
This commit is contained in:
Greg Kroah-Hartman 2024-06-14 07:17:59 +00:00
parent 40c3aca0d2
commit cfa231a1fa
2 changed files with 22 additions and 0 deletions

View File

@ -537,6 +537,19 @@ int pwm_apply_might_sleep(struct pwm_device *pwm, const struct pwm_state *state)
}
EXPORT_SYMBOL_GPL(pwm_apply_might_sleep);
/*
* ANDROID ONLY:
* pwm_apply_state() was renamed to pwm_apply_might_sleep() in commit
* a10c3d5ff9a3 ("pwm: Rename pwm_apply_state() to pwm_apply_might_sleep()")
* but many external modules were already expecting to use this function. So
* put it back as a wrapper so that things continue to build properly.
*/
int pwm_apply_state(struct pwm_device *pwm, const struct pwm_state *state)
{
return pwm_apply_might_sleep(pwm, state);
}
EXPORT_SYMBOL_GPL(pwm_apply_state);
/**
* pwm_capture() - capture and report a PWM signal
* @pwm: PWM device

View File

@ -318,6 +318,15 @@ struct pwm_chip {
int pwm_apply_might_sleep(struct pwm_device *pwm, const struct pwm_state *state);
int pwm_adjust_config(struct pwm_device *pwm);
/*
* ANDROID ONLY:
* pwm_apply_state() was renamed to pwm_apply_might_sleep() in commit
* a10c3d5ff9a3 ("pwm: Rename pwm_apply_state() to pwm_apply_might_sleep()")
* but many external modules were already expecting to use this function. So
* put it back as a wrapper so that things continue to build properly.
*/
int pwm_apply_state(struct pwm_device *pwm, const struct pwm_state *state);
/**
* pwm_config() - change a PWM device configuration
* @pwm: PWM device