Back to home page

OSCL-LXR

 
 

    


0001 #!/bin/sh
0002 # SPDX-License-Identifier: LGPL-2.1
0003 
0004 [ $# -eq 1 ] && header_dir=$1 || header_dir=tools/include/uapi/sound/
0005 
0006 printf "static const char *sndrv_ctl_ioctl_cmds[] = {\n"
0007 grep "^#define[\t ]\+SNDRV_CTL_IOCTL_" $header_dir/asound.h | \
0008         sed -r 's/^#define +SNDRV_CTL_IOCTL_([A-Z0-9_]+)[\t ]+_IO[RW]*\( *.U., *(0x[[:xdigit:]]+),?.*/\t[\2] = \"\1\",/g'
0009 printf "};\n"