Zephyr API Documentation 4.4.99
A Scalable Open Source RTOS
Loading...
Searching...
No Matches
devmux.h
Go to the documentation of this file.
1/*
2 * Copyright (c) 2023, Meta
3 *
4 * SPDX-License-Identifier: Apache-2.0
5 */
6
12
13#ifndef ZEPHYR_INCLUDE_DRIVERS_MISC_DEVMUX_DEVMUX_H_
14#define ZEPHYR_INCLUDE_DRIVERS_MISC_DEVMUX_DEVMUX_H_
15
16#include <stdint.h>
17
18#include <zephyr/device.h>
19#include <zephyr/kernel.h>
20
21#ifdef __cplusplus
22extern "C" {
23#endif
24
56
60__subsystem struct devmux_driver_api {
64 int (*select_get)(const struct device *dev);
68 int (*select_set)(struct device *dev, size_t index);
69};
70
80__syscall int devmux_select_get(const struct device *dev);
81
93__syscall int devmux_select_set(struct device *dev, size_t index);
94
98
99#ifdef __cplusplus
100}
101#endif
102
103#include <zephyr/syscalls/devmux.h>
104
105#endif /* ZEPHYR_INCLUDE_DRIVERS_MISC_DEVMUX_DEVMUX_H_ */
int devmux_select_set(struct device *dev, size_t index)
Set the selection of a devmux device.
int devmux_select_get(const struct device *dev)
Get the current selection of a devmux device.
Public kernel APIs.
Runtime device structure (in ROM) per driver instance.
Definition device.h:513
<span class="mlabel">Driver Operations</span> DEVMUX driver operations
Definition devmux.h:60
int(* select_get)(const struct device *dev)
<span class="op-badge op-req" title="This operation MUST be implemented by the driver....
Definition devmux.h:64
int(* select_set)(struct device *dev, size_t index)
<span class="op-badge op-req" title="This operation MUST be implemented by the driver....
Definition devmux.h:68