1 /* SPDX-License-Identifier: (GPL-2.0+ OR MIT) */ 2 /* 3 * Copyright (c) 2023 Rockchip Electronics Co., Ltd. 4 */ 5 6 #ifndef _PWM_ROCKCHIP_H_ 7 #define _PWM_ROCKCHIP_H_ 8 9 #include <linux/pwm.h> 10 rockchip_pwm_oneshot_callback(struct pwm_device * pwm,struct pwm_state * state)11static void rockchip_pwm_oneshot_callback(struct pwm_device *pwm, struct pwm_state *state) 12 { 13 /* 14 * If you want to enable oneshot mode again, config and call 15 * pwm_apply_state(). 16 * 17 * struct pwm_state new_state; 18 * 19 * pwm_get_state(pwm, &new_state); 20 * new_state.enabled = true; 21 * ...... 22 * pwm_apply_state(pwm, &new_state); 23 * 24 */ 25 } 26 27 #endif 28