ctimap.h 1006 B

123456789101112131415161718192021222324252627282930313233343536
  1. /* SPDX-License-Identifier: GPL-2.0-only */
  2. /*
  3. * Copyright (C) 2008, Creative Technology Ltd. All Rights Reserved.
  4. *
  5. * @File ctimap.h
  6. *
  7. * @Brief
  8. * This file contains the definition of generic input mapper operations
  9. * for input mapper management.
  10. *
  11. * @Author Liu Chun
  12. * @Date May 23 2008
  13. */
  14. #ifndef CTIMAP_H
  15. #define CTIMAP_H
  16. #include <linux/list.h>
  17. struct imapper {
  18. unsigned short slot; /* the id of the slot containing input data */
  19. unsigned short user; /* the id of the user resource consuming data */
  20. unsigned short addr; /* the input mapper ram id */
  21. unsigned short next; /* the next input mapper ram id */
  22. struct list_head list;
  23. };
  24. int input_mapper_add(struct list_head *mappers, struct imapper *entry,
  25. int (*map_op)(void *, struct imapper *), void *data);
  26. int input_mapper_delete(struct list_head *mappers, struct imapper *entry,
  27. int (*map_op)(void *, struct imapper *), void *data);
  28. void free_input_mapper_list(struct list_head *mappers);
  29. #endif /* CTIMAP_H */