]>
git.ipfire.org Git - people/ms/u-boot.git/blob - drivers/pwm/pwm-uclass.c
2 * Copyright (c) 2016 Google, Inc
3 * Written by Simon Glass <sjg@chromium.org>
5 * SPDX-License-Identifier: GPL-2.0+
12 int pwm_set_config(struct udevice
*dev
, uint channel
, uint period_ns
,
15 struct pwm_ops
*ops
= pwm_get_ops(dev
);
20 return ops
->set_config(dev
, channel
, period_ns
, duty_ns
);
23 int pwm_set_enable(struct udevice
*dev
, uint channel
, bool enable
)
25 struct pwm_ops
*ops
= pwm_get_ops(dev
);
30 return ops
->set_enable(dev
, channel
, enable
);
33 UCLASS_DRIVER(pwm
) = {