aboutsummaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorRohit kumar <rohitkr@codeaurora.org>2020-08-19 15:19:33 +0530
committerRohit kumar <rohitkr@codeaurora.org>2020-09-03 11:29:44 +0530
commitf29b8df6261e72d9a426d6d8c175a896931654e2 (patch)
tree41736e3bae1b2dd1f3ad6aa126b8889833ece97f /include
parent1ef2d458f56d6583de5d35da6d8ca0dc8ec2a146 (diff)
tinyalsa: add plugin support for mmap/poll ops
Diffstat (limited to 'include')
-rw-r--r--include/tinyalsa/plugin.h6
1 files changed, 6 insertions, 0 deletions
diff --git a/include/tinyalsa/plugin.h b/include/tinyalsa/plugin.h
index a140754..b2f97b9 100644
--- a/include/tinyalsa/plugin.h
+++ b/include/tinyalsa/plugin.h
@@ -30,6 +30,7 @@
#ifndef TINYALSA_PLUGIN_H
#define TINYALSA_PLUGIN_H
+#include <poll.h>
#include <stdint.h>
#include <stdlib.h>
#include <sys/types.h>
@@ -128,6 +129,11 @@ struct pcm_plugin_ops {
/** Any custom or alsa specific ioctl implementation */
int (*ioctl) (struct pcm_plugin *plugin,
int cmd, void *arg);
+ void *(*mmap) (struct pcm_plugin *plugin, void *addr, size_t length,
+ int prot, int flags, off_t offset);
+ int (*munmap) (struct pcm_plugin *plugin, void *addr, size_t length);
+ int (*poll) (struct pcm_plugin *plugin, struct pollfd *pfd, nfds_t nfds,
+ int timeout);
};
/** Minimum and maximum values for hardware parameter constraints.