]>
Commit | Line | Data |
---|---|---|
5fd6badb SG |
1 | /* |
2 | * Copyright (c) 2015 Google, Inc | |
3 | * | |
4 | * SPDX-License-Identifier: GPL-2.0+ | |
5 | */ | |
6 | ||
7 | #include <common.h> | |
8 | #include <dm.h> | |
9 | #include <pwrseq.h> | |
10 | ||
11 | int pwrseq_set_power(struct udevice *dev, bool enable) | |
12 | { | |
13 | struct pwrseq_ops *ops = pwrseq_get_ops(dev); | |
14 | ||
15 | if (!ops->set_power) | |
16 | return -ENOSYS; | |
17 | ||
18 | return ops->set_power(dev, enable); | |
19 | } | |
20 | ||
21 | UCLASS_DRIVER(pwrseq) = { | |
22 | .id = UCLASS_PWRSEQ, | |
23 | .name = "pwrseq", | |
24 | }; |