#include <linux/platform_device.h>
#include <linux/regmap.h>
#include <linux/mfd/intel_soc_pmic.h>
#include <linux/pwm.h>
#define PWM0_CLK_DIV …
#define PWM_OUTPUT_ENABLE …
#define PWM_DIV_CLK_0 …
#define PWM_DIV_CLK_100 …
#define PWM_DIV_CLK_128 …
#define PWM0_DUTY_CYCLE …
#define BACKLIGHT_EN …
#define PWM_MAX_LEVEL …
#define PWM_BASE_CLK_MHZ …
#define PWM_MAX_PERIOD_NS …
struct crystalcove_pwm { … };
static inline struct crystalcove_pwm *to_crc_pwm(struct pwm_chip *chip)
{ … }
static int crc_pwm_calc_clk_div(int period_ns)
{ … }
static int crc_pwm_apply(struct pwm_chip *chip, struct pwm_device *pwm,
const struct pwm_state *state)
{ … }
static int crc_pwm_get_state(struct pwm_chip *chip, struct pwm_device *pwm,
struct pwm_state *state)
{ … }
static const struct pwm_ops crc_pwm_ops = …;
static int crystalcove_pwm_probe(struct platform_device *pdev)
{ … }
static struct platform_driver crystalcove_pwm_driver = …;
module_platform_driver(…) …;
MODULE_ALIAS(…) …;
MODULE_DESCRIPTION(…) …;
MODULE_LICENSE(…) …;