diff options
author | Jagan Teki <jagan@amarulasolutions.com> | 2018-08-06 18:55:06 +0530 |
---|---|---|
committer | Jagan Teki <jagan@amarulasolutions.com> | 2019-01-18 22:19:09 +0530 |
commit | 652ee2788fa8310f4a38798d974b116609f9ddbf (patch) | |
tree | af7c8ef0fca1050991a9837ea12cf2073777c38e /include/reset.h | |
parent | 089ffd0aedb76f1408c651090b3bbfeb1449d582 (diff) |
reset: Add reset valid
Add reset_valid to check whether given reset is valid
or not.
Cc: Simon Glass <sjg@chromium.org>
Signed-off-by: Jagan Teki <jagan@amarulasolutions.com>
Diffstat (limited to 'include/reset.h')
-rw-r--r-- | include/reset.h | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/include/reset.h b/include/reset.h index bc495a90c2..65aa7a4ce5 100644 --- a/include/reset.h +++ b/include/reset.h @@ -306,4 +306,15 @@ static inline int reset_release_bulk(struct reset_ctl_bulk *bulk) } #endif +/** + * reset_valid() - check if reset is valid + * + * @reset_ctl: the reset to check + * @return TRUE if valid, or FALSE + */ +static inline bool reset_valid(struct reset_ctl *reset_ctl) +{ + return !!reset_ctl->dev; +} + #endif |