2 * Support for Intel Camera Imaging ISP subsystem.
3 * Copyright (c) 2015, Intel Corporation.
5 * This program is free software; you can redistribute it and/or modify it
6 * under the terms and conditions of the GNU General Public License,
7 * version 2, as published by the Free Software Foundation.
9 * This program is distributed in the hope it will be useful, but WITHOUT
10 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
11 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for
15 #ifndef __ISYS_STREAM2MMIO_PUBLIC_H_INCLUDED__
16 #define __ISYS_STREAM2MMIO_PUBLIC_H_INCLUDED__
18 /*****************************************************
20 * Native command interface (NCI).
22 *****************************************************/
24 * @brief Get the stream2mmio-controller state.
25 * Get the state of the stream2mmio-controller regiester-set.
27 * @param[in] id The global unique ID of the steeam2mmio controller.
28 * @param[out] state Point to the register-state.
30 STORAGE_CLASS_STREAM2MMIO_H void stream2mmio_get_state(
31 const stream2mmio_ID_t ID,
32 stream2mmio_state_t *state);
35 * @brief Get the state of the stream2mmio-controller sidess.
36 * Get the state of the register set per buf-controller sidess.
38 * @param[in] id The global unique ID of the steeam2mmio controller.
39 * @param[in] sid_id The sid ID.
40 * @param[out] state Point to the sid state.
42 STORAGE_CLASS_STREAM2MMIO_H void stream2mmio_get_sid_state(
43 const stream2mmio_ID_t ID,
44 const stream2mmio_sid_ID_t sid_id,
45 stream2mmio_sid_state_t *state);
48 /*****************************************************
50 * Device level interface (DLI).
52 *****************************************************/
54 * @brief Load the register value.
55 * Load the value of the register of the stream2mmio-controller.
57 * @param[in] ID The global unique ID for the stream2mmio-controller instance.
58 * @param[in] sid_id The SID in question.
59 * @param[in] reg_idx The offet address of the register.
61 * @return the value of the register.
63 STORAGE_CLASS_STREAM2MMIO_H hrt_data stream2mmio_reg_load(
64 const stream2mmio_ID_t ID,
65 const stream2mmio_sid_ID_t sid_id,
66 const uint32_t reg_idx);
69 * @brief Dump the SID processor state.
70 * Dump the state of the sid regiester-set.
72 * @param[in] state Pointer to the register-state.
74 STORAGE_CLASS_STREAM2MMIO_H void stream2mmio_print_sid_state(
75 stream2mmio_sid_state_t *state);
77 * @brief Dump the stream2mmio state.
78 * Dump the state of the ibuf-controller regiester-set.
80 * @param[in] id The global unique ID of the st2mmio
81 * @param[in] state Pointer to the register-state.
83 STORAGE_CLASS_STREAM2MMIO_H void stream2mmio_dump_state(
84 const stream2mmio_ID_t ID,
85 stream2mmio_state_t *state);
87 * @brief Store a value to the register.
88 * Store a value to the registe of the stream2mmio-controller.
90 * @param[in] ID The global unique ID for the stream2mmio-controller instance.
91 * @param[in] reg The offet address of the register.
92 * @param[in] value The value to be stored.
95 STORAGE_CLASS_STREAM2MMIO_H void stream2mmio_reg_store(
96 const stream2mmio_ID_t ID,
97 const hrt_address reg,
98 const hrt_data value);
101 #endif /* __ISYS_STREAM2MMIO_PUBLIC_H_INCLUDED__ */