blob: ef6eb9e9c83c0a24ec1aabbc7450c48e2551b774 [file] [log] [blame]
Bryan Huntsman3f2bc4d2011-08-16 17:27:22 -07001/* Copyright (c) 2010-2011, Code Aurora Forum. All rights reserved.
2 *
3 * This program is free software; you can redistribute it and/or modify
4 * it under the terms of the GNU General Public License version 2 and
5 * only version 2 as published by the Free Software Foundation.
6 *
7 * This program is distributed in the hope that it will be useful,
8 * but WITHOUT ANY WARRANTY; without even the implied warranty of
9 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
10 * GNU General Public License for more details.
11 */
12#ifndef __Q6_ADM_H__
13#define __Q6_ADM_H__
14#include <sound/q6afe.h>
15
16#define ADM_PATH_PLAYBACK 0x1
17#define ADM_PATH_LIVE_REC 0x2
18#define ADM_PATH_NONLIVE_REC 0x3
19
20/* multiple copp per stream. */
21struct route_payload {
22 unsigned int copp_ids[AFE_MAX_PORTS];
23 unsigned short num_copps;
24 unsigned int session_id;
25};
26
27int adm_open_mixer(int port_id, int path, int rate, int channel_mode,
28 int topology);
29
30int adm_route_session(int port_id, uint session_id, int set);
31
32int adm_open(int port, int path, int rate, int mode, int topology);
33
34int adm_memory_map_regions(uint32_t *buf_add, uint32_t mempool_id,
35 uint32_t *bufsz, uint32_t bufcnt);
36
37int adm_memory_unmap_regions(uint32_t *buf_add, uint32_t *bufsz,
38 uint32_t bufcnt);
39
40int adm_close(int port);
41
42int adm_matrix_map(int session_id, int path, int num_copps,
43 unsigned int *port_id, int copp_id);
44
Ben Romberger45b351c2011-07-20 22:37:27 -070045#ifdef CONFIG_RTAC
Bryan Huntsman3f2bc4d2011-08-16 17:27:22 -070046int adm_get_copp_id(int port_id);
47#endif
48
49#endif /* __Q6_ADM_H__ */