linux/drivers/usb/gadget/function/u_uac2.h
<<
>>
Prefs
   1/* SPDX-License-Identifier: GPL-2.0 */
   2/*
   3 * u_uac2.h
   4 *
   5 * Utility definitions for UAC2 function
   6 *
   7 * Copyright (c) 2014 Samsung Electronics Co., Ltd.
   8 *              http://www.samsung.com
   9 *
  10 * Author: Andrzej Pietrasiewicz <andrzejtp2010@gmail.com>
  11 */
  12
  13#ifndef U_UAC2_H
  14#define U_UAC2_H
  15
  16#include <linux/usb/composite.h>
  17
  18#define UAC2_DEF_PCHMASK 0x3
  19#define UAC2_DEF_PSRATE 48000
  20#define UAC2_DEF_PSSIZE 2
  21#define UAC2_DEF_CCHMASK 0x3
  22#define UAC2_DEF_CSRATE 64000
  23#define UAC2_DEF_CSSIZE 2
  24#define UAC2_DEF_REQ_NUM 2
  25
  26struct f_uac2_opts {
  27        struct usb_function_instance    func_inst;
  28        int                             p_chmask;
  29        int                             p_srate;
  30        int                             p_ssize;
  31        int                             c_chmask;
  32        int                             c_srate;
  33        int                             c_ssize;
  34        int                             req_number;
  35        bool                            bound;
  36
  37        struct mutex                    lock;
  38        int                             refcnt;
  39};
  40
  41#endif
  42