Changeset 426 for GPL/trunk/alsa-kernel/include
- Timestamp:
- May 9, 2009, 11:45:26 AM (16 years ago)
- Location:
- GPL/trunk/alsa-kernel/include/sound
- Files:
-
- 17 edited
Legend:
- Unmodified
- Added
- Removed
-
GPL/trunk/alsa-kernel/include/sound/ad1816a.h
r398 r426 170 170 extern int snd_ad1816a_pcm(struct snd_ad1816a *chip, int device, struct snd_pcm **rpcm); 171 171 extern int snd_ad1816a_mixer(struct snd_ad1816a *chip); 172 extern int snd_ad1816a_timer(struct snd_ad1816a *chip, int device, 173 struct snd_timer **rtimer); 172 174 173 175 #endif /* __SOUND_AD1816A_H */ -
GPL/trunk/alsa-kernel/include/sound/asound.h
r402 r426 24 24 #define __SOUND_ASOUND_H 25 25 26 #include <linux/types.h> 27 26 28 #ifdef __KERNEL__ 27 29 #include <linux/ioctl.h> 28 #include <linux/types.h>29 30 #include <linux/time.h> 30 31 #include <asm/byteorder.h> … … 150 151 }; 151 152 152 enum { 153 SNDRV_HWDEP_IOCTL_PVERSION = _IOR ('H', 0x00, int), 154 SNDRV_HWDEP_IOCTL_INFO = _IOR ('H', 0x01, struct snd_hwdep_info), 155 SNDRV_HWDEP_IOCTL_DSP_STATUS = _IOR('H', 0x02, struct snd_hwdep_dsp_status), 156 SNDRV_HWDEP_IOCTL_DSP_LOAD = _IOW('H', 0x03, struct snd_hwdep_dsp_image) 157 }; 153 #define SNDRV_HWDEP_IOCTL_PVERSION _IOR ('H', 0x00, int) 154 #define SNDRV_HWDEP_IOCTL_INFO _IOR ('H', 0x01, struct snd_hwdep_info) 155 #define SNDRV_HWDEP_IOCTL_DSP_STATUS _IOR('H', 0x02, struct snd_hwdep_dsp_status) 156 #define SNDRV_HWDEP_IOCTL_DSP_LOAD _IOW('H', 0x03, struct snd_hwdep_dsp_image) 158 157 159 158 /***************************************************************************** … … 369 368 370 369 struct snd_mask { 371 u_int32_tbits[(SNDRV_MASK_MAX+31)/32];370 __u32 bits[(SNDRV_MASK_MAX+31)/32]; 372 371 }; 373 372 … … 412 411 struct snd_pcm_channel_info { 413 412 unsigned int channel; 414 off_t offset;/* mmap offset */413 __kernel_off_t offset; /* mmap offset */ 415 414 unsigned int first; /* offset to first sample in bits */ 416 415 unsigned int step; /* samples distance in bits */ … … 478 477 }; 479 478 480 enum { 481 SNDRV_PCM_IOCTL_PVERSION = _IOR('A', 0x00, int), 482 SNDRV_PCM_IOCTL_INFO = _IOR('A', 0x01, struct snd_pcm_info), 483 SNDRV_PCM_IOCTL_TSTAMP = _IOW('A', 0x02, int), 484 SNDRV_PCM_IOCTL_TTSTAMP = _IOW('A', 0x03, int), 485 SNDRV_PCM_IOCTL_HW_REFINE = _IOWR('A', 0x10, struct snd_pcm_hw_params), 486 SNDRV_PCM_IOCTL_HW_PARAMS = _IOWR('A', 0x11, struct snd_pcm_hw_params), 487 SNDRV_PCM_IOCTL_HW_FREE = _IO('A', 0x12), 488 SNDRV_PCM_IOCTL_SW_PARAMS = _IOWR('A', 0x13, struct snd_pcm_sw_params), 489 SNDRV_PCM_IOCTL_STATUS = _IOR('A', 0x20, struct snd_pcm_status), 490 SNDRV_PCM_IOCTL_DELAY = _IOR('A', 0x21, snd_pcm_sframes_t), 491 SNDRV_PCM_IOCTL_HWSYNC = _IO('A', 0x22), 492 SNDRV_PCM_IOCTL_SYNC_PTR = _IOWR('A', 0x23, struct snd_pcm_sync_ptr), 493 SNDRV_PCM_IOCTL_CHANNEL_INFO = _IOR('A', 0x32, struct snd_pcm_channel_info), 494 SNDRV_PCM_IOCTL_PREPARE = _IO('A', 0x40), 495 SNDRV_PCM_IOCTL_RESET = _IO('A', 0x41), 496 SNDRV_PCM_IOCTL_START = _IO('A', 0x42), 497 SNDRV_PCM_IOCTL_DROP = _IO('A', 0x43), 498 SNDRV_PCM_IOCTL_DRAIN = _IO('A', 0x44), 499 SNDRV_PCM_IOCTL_PAUSE = _IOW('A', 0x45, int), 500 SNDRV_PCM_IOCTL_REWIND = _IOW('A', 0x46, snd_pcm_uframes_t), 501 SNDRV_PCM_IOCTL_RESUME = _IO('A', 0x47), 502 SNDRV_PCM_IOCTL_XRUN = _IO('A', 0x48), 503 SNDRV_PCM_IOCTL_FORWARD = _IOW('A', 0x49, snd_pcm_uframes_t), 504 SNDRV_PCM_IOCTL_WRITEI_FRAMES = _IOW('A', 0x50, struct snd_xferi), 505 SNDRV_PCM_IOCTL_READI_FRAMES = _IOR('A', 0x51, struct snd_xferi), 506 SNDRV_PCM_IOCTL_WRITEN_FRAMES = _IOW('A', 0x52, struct snd_xfern), 507 SNDRV_PCM_IOCTL_READN_FRAMES = _IOR('A', 0x53, struct snd_xfern), 508 SNDRV_PCM_IOCTL_LINK = _IOW('A', 0x60, int), 509 SNDRV_PCM_IOCTL_UNLINK = _IO('A', 0x61), 510 }; 511 512 /* Trick to make alsa-lib/acinclude.m4 happy */ 513 #define SNDRV_PCM_IOCTL_REWIND SNDRV_PCM_IOCTL_REWIND 479 #define SNDRV_PCM_IOCTL_PVERSION _IOR('A', 0x00, int) 480 #define SNDRV_PCM_IOCTL_INFO _IOR('A', 0x01, struct snd_pcm_info) 481 #define SNDRV_PCM_IOCTL_TSTAMP _IOW('A', 0x02, int) 482 #define SNDRV_PCM_IOCTL_TTSTAMP _IOW('A', 0x03, int) 483 #define SNDRV_PCM_IOCTL_HW_REFINE _IOWR('A', 0x10, struct snd_pcm_hw_params) 484 #define SNDRV_PCM_IOCTL_HW_PARAMS _IOWR('A', 0x11, struct snd_pcm_hw_params) 485 #define SNDRV_PCM_IOCTL_HW_FREE _IO('A', 0x12) 486 #define SNDRV_PCM_IOCTL_SW_PARAMS _IOWR('A', 0x13, struct snd_pcm_sw_params) 487 #define SNDRV_PCM_IOCTL_STATUS _IOR('A', 0x20, struct snd_pcm_status) 488 #define SNDRV_PCM_IOCTL_DELAY _IOR('A', 0x21, snd_pcm_sframes_t) 489 #define SNDRV_PCM_IOCTL_HWSYNC _IO('A', 0x22) 490 #define SNDRV_PCM_IOCTL_SYNC_PTR _IOWR('A', 0x23, struct snd_pcm_sync_ptr) 491 #define SNDRV_PCM_IOCTL_CHANNEL_INFO _IOR('A', 0x32, struct snd_pcm_channel_info) 492 #define SNDRV_PCM_IOCTL_PREPARE _IO('A', 0x40) 493 #define SNDRV_PCM_IOCTL_RESET _IO('A', 0x41) 494 #define SNDRV_PCM_IOCTL_START _IO('A', 0x42) 495 #define SNDRV_PCM_IOCTL_DROP _IO('A', 0x43) 496 #define SNDRV_PCM_IOCTL_DRAIN _IO('A', 0x44) 497 #define SNDRV_PCM_IOCTL_PAUSE _IOW('A', 0x45, int) 498 #define SNDRV_PCM_IOCTL_REWIND _IOW('A', 0x46, snd_pcm_uframes_t) 499 #define SNDRV_PCM_IOCTL_RESUME _IO('A', 0x47) 500 #define SNDRV_PCM_IOCTL_XRUN _IO('A', 0x48) 501 #define SNDRV_PCM_IOCTL_FORWARD _IOW('A', 0x49, snd_pcm_uframes_t) 502 #define SNDRV_PCM_IOCTL_WRITEI_FRAMES _IOW('A', 0x50, struct snd_xferi) 503 #define SNDRV_PCM_IOCTL_READI_FRAMES _IOR('A', 0x51, struct snd_xferi) 504 #define SNDRV_PCM_IOCTL_WRITEN_FRAMES _IOW('A', 0x52, struct snd_xfern) 505 #define SNDRV_PCM_IOCTL_READN_FRAMES _IOR('A', 0x53, struct snd_xfern) 506 #define SNDRV_PCM_IOCTL_LINK _IOW('A', 0x60, int) 507 #define SNDRV_PCM_IOCTL_UNLINK _IO('A', 0x61) 514 508 515 509 /***************************************************************************** … … 565 559 }; 566 560 567 enum { 568 SNDRV_RAWMIDI_IOCTL_PVERSION = _IOR('W', 0x00, int), 569 SNDRV_RAWMIDI_IOCTL_INFO = _IOR('W', 0x01, struct snd_rawmidi_info), 570 SNDRV_RAWMIDI_IOCTL_PARAMS = _IOWR('W', 0x10, struct snd_rawmidi_params), 571 SNDRV_RAWMIDI_IOCTL_STATUS = _IOWR('W', 0x20, struct snd_rawmidi_status), 572 SNDRV_RAWMIDI_IOCTL_DROP = _IOW('W', 0x30, int), 573 SNDRV_RAWMIDI_IOCTL_DRAIN = _IOW('W', 0x31, int), 574 }; 561 #define SNDRV_RAWMIDI_IOCTL_PVERSION _IOR('W', 0x00, int) 562 #define SNDRV_RAWMIDI_IOCTL_INFO _IOR('W', 0x01, struct snd_rawmidi_info) 563 #define SNDRV_RAWMIDI_IOCTL_PARAMS _IOWR('W', 0x10, struct snd_rawmidi_params) 564 #define SNDRV_RAWMIDI_IOCTL_STATUS _IOWR('W', 0x20, struct snd_rawmidi_status) 565 #define SNDRV_RAWMIDI_IOCTL_DROP _IOW('W', 0x30, int) 566 #define SNDRV_RAWMIDI_IOCTL_DRAIN _IOW('W', 0x31, int) 575 567 576 568 /* … … 681 673 }; 682 674 683 enum { 684 SNDRV_TIMER_IOCTL_PVERSION = _IOR('T', 0x00, int), 685 SNDRV_TIMER_IOCTL_NEXT_DEVICE = _IOWR('T', 0x01, struct snd_timer_id), 686 SNDRV_TIMER_IOCTL_TREAD = _IOW('T', 0x02, int), 687 SNDRV_TIMER_IOCTL_GINFO = _IOWR('T', 0x03, struct snd_timer_ginfo), 688 SNDRV_TIMER_IOCTL_GPARAMS = _IOW('T', 0x04, struct snd_timer_gparams), 689 SNDRV_TIMER_IOCTL_GSTATUS = _IOWR('T', 0x05, struct snd_timer_gstatus), 690 SNDRV_TIMER_IOCTL_SELECT = _IOW('T', 0x10, struct snd_timer_select), 691 SNDRV_TIMER_IOCTL_INFO = _IOR('T', 0x11, struct snd_timer_info), 692 SNDRV_TIMER_IOCTL_PARAMS = _IOW('T', 0x12, struct snd_timer_params), 693 SNDRV_TIMER_IOCTL_STATUS = _IOR('T', 0x14, struct snd_timer_status), 694 /* The following four ioctls are changed since 1.0.9 due to confliction */ 695 SNDRV_TIMER_IOCTL_START = _IO('T', 0xa0), 696 SNDRV_TIMER_IOCTL_STOP = _IO('T', 0xa1), 697 SNDRV_TIMER_IOCTL_CONTINUE = _IO('T', 0xa2), 698 SNDRV_TIMER_IOCTL_PAUSE = _IO('T', 0xa3), 699 }; 675 #define SNDRV_TIMER_IOCTL_PVERSION _IOR('T', 0x00, int) 676 #define SNDRV_TIMER_IOCTL_NEXT_DEVICE _IOWR('T', 0x01, struct snd_timer_id) 677 #define SNDRV_TIMER_IOCTL_TREAD _IOW('T', 0x02, int) 678 #define SNDRV_TIMER_IOCTL_GINFO _IOWR('T', 0x03, struct snd_timer_ginfo) 679 #define SNDRV_TIMER_IOCTL_GPARAMS _IOW('T', 0x04, struct snd_timer_gparams) 680 #define SNDRV_TIMER_IOCTL_GSTATUS _IOWR('T', 0x05, struct snd_timer_gstatus) 681 #define SNDRV_TIMER_IOCTL_SELECT _IOW('T', 0x10, struct snd_timer_select) 682 #define SNDRV_TIMER_IOCTL_INFO _IOR('T', 0x11, struct snd_timer_info) 683 #define SNDRV_TIMER_IOCTL_PARAMS _IOW('T', 0x12, struct snd_timer_params) 684 #define SNDRV_TIMER_IOCTL_STATUS _IOR('T', 0x14, struct snd_timer_status) 685 /* The following four ioctls are changed since 1.0.9 due to confliction */ 686 #define SNDRV_TIMER_IOCTL_START _IO('T', 0xa0) 687 #define SNDRV_TIMER_IOCTL_STOP _IO('T', 0xa1) 688 #define SNDRV_TIMER_IOCTL_CONTINUE _IO('T', 0xa2) 689 #define SNDRV_TIMER_IOCTL_PAUSE _IO('T', 0xa3) 700 690 701 691 struct snd_timer_read { … … 816 806 unsigned int access; /* R: value access (bitmask) - SNDRV_CTL_ELEM_ACCESS_* */ 817 807 unsigned int count; /* count of values */ 818 pid_t owner;/* owner's PID of this control */808 __kernel_pid_t owner; /* owner's PID of this control */ 819 809 union { 820 810 struct { … … 878 868 }; 879 869 880 enum { 881 SNDRV_CTL_IOCTL_PVERSION = _IOR('U', 0x00, int), 882 SNDRV_CTL_IOCTL_CARD_INFO = _IOR('U', 0x01, struct snd_ctl_card_info), 883 SNDRV_CTL_IOCTL_ELEM_LIST = _IOWR('U', 0x10, struct snd_ctl_elem_list), 884 SNDRV_CTL_IOCTL_ELEM_INFO = _IOWR('U', 0x11, struct snd_ctl_elem_info), 885 SNDRV_CTL_IOCTL_ELEM_READ = _IOWR('U', 0x12, struct snd_ctl_elem_value), 886 SNDRV_CTL_IOCTL_ELEM_WRITE = _IOWR('U', 0x13, struct snd_ctl_elem_value), 887 SNDRV_CTL_IOCTL_ELEM_LOCK = _IOW('U', 0x14, struct snd_ctl_elem_id), 888 SNDRV_CTL_IOCTL_ELEM_UNLOCK = _IOW('U', 0x15, struct snd_ctl_elem_id), 889 SNDRV_CTL_IOCTL_SUBSCRIBE_EVENTS = _IOWR('U', 0x16, int), 890 SNDRV_CTL_IOCTL_ELEM_ADD = _IOWR('U', 0x17, struct snd_ctl_elem_info), 891 SNDRV_CTL_IOCTL_ELEM_REPLACE = _IOWR('U', 0x18, struct snd_ctl_elem_info), 892 SNDRV_CTL_IOCTL_ELEM_REMOVE = _IOWR('U', 0x19, struct snd_ctl_elem_id), 893 SNDRV_CTL_IOCTL_TLV_READ = _IOWR('U', 0x1a, struct snd_ctl_tlv), 894 SNDRV_CTL_IOCTL_TLV_WRITE = _IOWR('U', 0x1b, struct snd_ctl_tlv), 895 SNDRV_CTL_IOCTL_TLV_COMMAND = _IOWR('U', 0x1c, struct snd_ctl_tlv), 896 SNDRV_CTL_IOCTL_HWDEP_NEXT_DEVICE = _IOWR('U', 0x20, int), 897 SNDRV_CTL_IOCTL_HWDEP_INFO = _IOR('U', 0x21, struct snd_hwdep_info), 898 SNDRV_CTL_IOCTL_PCM_NEXT_DEVICE = _IOR('U', 0x30, int), 899 SNDRV_CTL_IOCTL_PCM_INFO = _IOWR('U', 0x31, struct snd_pcm_info), 900 SNDRV_CTL_IOCTL_PCM_PREFER_SUBDEVICE = _IOW('U', 0x32, int), 901 SNDRV_CTL_IOCTL_RAWMIDI_NEXT_DEVICE = _IOWR('U', 0x40, int), 902 SNDRV_CTL_IOCTL_RAWMIDI_INFO = _IOWR('U', 0x41, struct snd_rawmidi_info), 903 SNDRV_CTL_IOCTL_RAWMIDI_PREFER_SUBDEVICE = _IOW('U', 0x42, int), 904 SNDRV_CTL_IOCTL_POWER = _IOWR('U', 0xd0, int), 905 SNDRV_CTL_IOCTL_POWER_STATE = _IOR('U', 0xd1, int), 870 #define SNDRV_CTL_IOCTL_PVERSION _IOR('U', 0x00, int) 871 #define SNDRV_CTL_IOCTL_CARD_INFO _IOR('U', 0x01, struct snd_ctl_card_info) 872 #define SNDRV_CTL_IOCTL_ELEM_LIST _IOWR('U', 0x10, struct snd_ctl_elem_list) 873 #define SNDRV_CTL_IOCTL_ELEM_INFO _IOWR('U', 0x11, struct snd_ctl_elem_info) 874 #define SNDRV_CTL_IOCTL_ELEM_READ _IOWR('U', 0x12, struct snd_ctl_elem_value) 875 #define SNDRV_CTL_IOCTL_ELEM_WRITE _IOWR('U', 0x13, struct snd_ctl_elem_value) 876 #define SNDRV_CTL_IOCTL_ELEM_LOCK _IOW('U', 0x14, struct snd_ctl_elem_id) 877 #define SNDRV_CTL_IOCTL_ELEM_UNLOCK _IOW('U', 0x15, struct snd_ctl_elem_id) 878 #define SNDRV_CTL_IOCTL_SUBSCRIBE_EVENTS _IOWR('U', 0x16, int) 879 #define SNDRV_CTL_IOCTL_ELEM_ADD _IOWR('U', 0x17, struct snd_ctl_elem_info) 880 #define SNDRV_CTL_IOCTL_ELEM_REPLACE _IOWR('U', 0x18, struct snd_ctl_elem_info) 881 #define SNDRV_CTL_IOCTL_ELEM_REMOVE _IOWR('U', 0x19, struct snd_ctl_elem_id) 882 #define SNDRV_CTL_IOCTL_TLV_READ _IOWR('U', 0x1a, struct snd_ctl_tlv) 883 #define SNDRV_CTL_IOCTL_TLV_WRITE _IOWR('U', 0x1b, struct snd_ctl_tlv) 884 #define SNDRV_CTL_IOCTL_TLV_COMMAND _IOWR('U', 0x1c, struct snd_ctl_tlv) 885 #define SNDRV_CTL_IOCTL_HWDEP_NEXT_DEVICE _IOWR('U', 0x20, int) 886 #define SNDRV_CTL_IOCTL_HWDEP_INFO _IOR('U', 0x21, struct snd_hwdep_info) 887 #define SNDRV_CTL_IOCTL_PCM_NEXT_DEVICE _IOR('U', 0x30, int) 888 #define SNDRV_CTL_IOCTL_PCM_INFO _IOWR('U', 0x31, struct snd_pcm_info) 889 #define SNDRV_CTL_IOCTL_PCM_PREFER_SUBDEVICE _IOW('U', 0x32, int) 890 #define SNDRV_CTL_IOCTL_RAWMIDI_NEXT_DEVICE _IOWR('U', 0x40, int) 891 #define SNDRV_CTL_IOCTL_RAWMIDI_INFO _IOWR('U', 0x41, struct snd_rawmidi_info) 892 #define SNDRV_CTL_IOCTL_RAWMIDI_PREFER_SUBDEVICE _IOW('U', 0x42, int) 893 #define SNDRV_CTL_IOCTL_POWER _IOWR('U', 0xd0, int) 894 #define SNDRV_CTL_IOCTL_POWER_STATE _IOR('U', 0xd1, int) 906 895 #ifdef TARGET_OS2 907 SNDRV_PCM_IOCTL_SETVOLUME = _IOW('A', 0x62, struct snd_pcm_volume), 908 SNDRV_PCM_IOCTL_GETVOLUME = _IOR('A', 0x63, struct snd_pcm_volume), 896 #define SNDRV_PCM_IOCTL_SETVOLUME _IOW('A', 0x62, struct snd_pcm_volume) 897 #define SNDRV_PCM_IOCTL_GETVOLUME _IOR('A', 0x63, struct snd_pcm_volume) 909 898 #endif 910 };911 899 912 900 /* … … 954 942 #define SNDRV_CTL_NAME_IEC958(expl,direction,what) "IEC958 " expl SNDRV_CTL_NAME_##direction SNDRV_CTL_NAME_IEC958_##what 955 943 956 /*957 *958 */959 960 struct snd_xferv {961 const struct iovec *vector;962 unsigned long count;963 };964 965 enum {966 SNDRV_IOCTL_READV = _IOW('K', 0x00, struct snd_xferv),967 SNDRV_IOCTL_WRITEV = _IOW('K', 0x01, struct snd_xferv),968 };969 970 944 #endif /* __SOUND_ASOUND_H */ -
GPL/trunk/alsa-kernel/include/sound/config.h
r410 r426 422 422 #endif 423 423 424 typedef unsigned __nocast gfp_t; 425 424 426 #ifndef CONFIG_HAVE_KZALLOC 425 void *snd_compat_kzalloc(size_t n, unsigned int __nocast gfp_flags);427 void *snd_compat_kzalloc(size_t n, gfp_t gfp_flags); 426 428 #define kzalloc(s,f) snd_compat_kzalloc(s,f) 429 427 430 #endif 428 431 … … 655 658 #endif 656 659 660 #ifndef DMA_BIT_MASK 661 #define DMA_BIT_MASK(n) (((n) == 64) ? ~0ULL : ((1ULL<<(n))-1)) 662 #endif 663 664 /* memdup_user() wrapper */ 665 #if LINUX_VERSION_CODE < KERNEL_VERSION(2, 6, 30) 666 #include <linux/err.h> 667 #include <asm/uaccess.h> 668 static inline void *memdup_user(void __user *src, size_t len) 669 { 670 void *p = kmalloc(len, GFP_KERNEL); 671 if (!p) 672 return ERR_PTR(-ENOMEM); 673 if (copy_from_user(p, src, len)) { 674 kfree(p); 675 return ERR_PTR(-EFAULT); 676 } 677 return p; 678 } 679 #endif 680 681 #if LINUX_VERSION_CODE < KERNEL_VERSION(2, 6, 6) 682 #include <linux/workqueue.h> 683 #ifndef create_singlethread_workqueue 684 #define create_singlethread_workqueue(name) create_workqueue(name) 685 #endif 686 #endif 687 657 688 #endif //__ALSA_CONFIG_H__ -
GPL/trunk/alsa-kernel/include/sound/control.h
r410 r426 184 184 #define SND_CTL_SLAVE_NEED_UPDATE (1 << 0) 185 185 186 /** 187 * snd_ctl_add_slave - Add a virtual slave control 188 * @master: vmaster element 189 * @slave: slave element to add 190 * 191 * Add a virtual slave control to the given master element created via 192 * snd_ctl_create_virtual_master() beforehand. 193 * Returns zero if successful or a negative error code. 194 * 195 * All slaves must be the same type (returning the same information 196 * via info callback). The fucntion doesn't check it, so it's your 197 * responsibility. 198 * 199 * Also, some additional limitations: 200 * at most two channels, 201 * logarithmic volume control (dB level) thus no linear volume, 202 * master can only attenuate the volume without gain 203 */ 186 204 static inline int 187 205 snd_ctl_add_slave(struct snd_kcontrol *master, struct snd_kcontrol *slave) … … 190 208 } 191 209 210 /** 211 * snd_ctl_add_slave_uncached - Add a virtual slave control 212 * @master: vmaster element 213 * @slave: slave element to add 214 * 215 * Add a virtual slave control to the given master. 216 * Unlike snd_ctl_add_slave(), the element added via this function 217 * is supposed to have volatile values, and get callback is called 218 * at each time quried from the master. 219 * 220 * When the control peeks the hardware values directly and the value 221 * can be changed by other means than the put callback of the element, 222 * this function should be used to keep the value always up-to-date. 223 */ 192 224 static inline int 193 225 snd_ctl_add_slave_uncached(struct snd_kcontrol *master, -
GPL/trunk/alsa-kernel/include/sound/core.h
r410 r426 101 101 struct snd_monitor_file { 102 102 struct file *file; 103 struct snd_monitor_file *next;104 103 #ifndef TARGET_OS2 105 104 const struct file_operations *disconnected_f_op; … … 107 106 struct file_operations *disconnected_f_op; 108 107 #endif 109 struct list_head shutdown_list; 108 struct list_head shutdown_list; /* still need to shutdown */ 109 struct list_head list; /* link of monitor files */ 110 110 }; 111 111 … … 142 142 struct proc_dir_entry *proc_root_link; /* number link to real id */ 143 143 144 struct snd_monitor_file *files;/* all files associated to this card */144 struct list_head files_list; /* all files associated to this card */ 145 145 struct snd_shutdown_f_ops *s_f_ops; /* file operations in the shutdown 146 146 state */ … … 506 506 unsigned short subvendor; /* PCI subvendor ID */ 507 507 unsigned short subdevice; /* PCI subdevice ID */ 508 unsigned short subdevice_mask; /* bitmask to match */ 508 509 int value; /* value */ 509 510 #ifdef CONFIG_SND_DEBUG_VERBOSE … … 512 513 }; 513 514 514 #define _SND_PCI_QUIRK_ID(vend,dev) \ 515 .subvendor = (vend), .subdevice = (dev) 515 #define _SND_PCI_QUIRK_ID_MASK(vend, mask, dev) \ 516 .subvendor = (vend), .subdevice = (dev), .subdevice_mask = (mask) 517 #define _SND_PCI_QUIRK_ID(vend, dev) \ 518 _SND_PCI_QUIRK_ID_MASK(vend, 0xffff, dev) 516 519 #define SND_PCI_QUIRK_ID(vend,dev) {_SND_PCI_QUIRK_ID(vend, dev)} 517 520 #ifdef CONFIG_SND_DEBUG_VERBOSE 518 521 #define SND_PCI_QUIRK(vend,dev,xname,val) \ 519 522 {_SND_PCI_QUIRK_ID(vend, dev), .value = (val), .name = (xname)} 523 #define SND_PCI_QUIRK_VENDOR(vend, xname, val) \ 524 {_SND_PCI_QUIRK_ID_MASK(vend, 0, 0), .value = (val), .name = (xname)} 525 #define SND_PCI_QUIRK_MASK(vend, mask, dev, xname, val) \ 526 {_SND_PCI_QUIRK_ID_MASK(vend, mask, dev), \ 527 .value = (val), .name = (xname)} 520 528 #else 521 529 #define SND_PCI_QUIRK(vend,dev,xname,val) \ 522 530 {_SND_PCI_QUIRK_ID(vend, dev), .value = (val)} 531 #define SND_PCI_QUIRK_MASK(vend, mask, dev, xname, val) \ 532 {_SND_PCI_QUIRK_ID_MASK(vend, mask, dev), .value = (val)} 533 #define SND_PCI_QUIRK_VENDOR(vend, xname, val) \ 534 {_SND_PCI_QUIRK_ID_MASK(vend, 0, 0), .value = (val)} 523 535 #endif 524 536 -
GPL/trunk/alsa-kernel/include/sound/emu10k1.h
r399 r426 1 1 #ifndef __SOUND_EMU10K1_H 2 2 #define __SOUND_EMU10K1_H 3 4 #include <linux/types.h> 3 5 4 6 /* … … 35 37 #include <linux/interrupt.h> 36 38 #include <linux/mutex.h> 39 37 40 #include <asm/io.h> 38 41 … … 2172 2175 2173 2176 DECLARE_BITMAP(gpr_valid, 0x200); /* bitmask of valid initializers */ 2174 u_int32_t __user *gpr_map;/* initializers */2177 __u32 __user *gpr_map; /* initializers */ 2175 2178 2176 2179 unsigned int gpr_add_control_count; /* count of GPR controls to add/replace */ … … 2185 2188 2186 2189 DECLARE_BITMAP(tram_valid, 0x100); /* bitmask of valid initializers */ 2187 u_int32_t __user *tram_data_map;/* data initializers */2188 u_int32_t __user *tram_addr_map;/* map initializers */2190 __u32 __user *tram_data_map; /* data initializers */ 2191 __u32 __user *tram_addr_map; /* map initializers */ 2189 2192 2190 2193 DECLARE_BITMAP(code_valid, 1024); /* bitmask of valid instructions */ 2191 u_int32_t__user *code; /* one instruction - 64 bits */2194 __u32 __user *code; /* one instruction - 64 bits */ 2192 2195 }; 2193 2196 -
GPL/trunk/alsa-kernel/include/sound/hdsp.h
r305 r426 19 19 * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. 20 20 */ 21 22 #include <linux/types.h> 21 23 22 24 #define HDSP_MATRIX_MIXER_SIZE 2048 -
GPL/trunk/alsa-kernel/include/sound/hwdep.h
r305 r426 28 28 struct snd_hwdep; 29 29 30 /* hwdep file ops; all ops can be NULL */ 30 31 struct snd_hwdep_ops { 31 long long (*llseek) (struct snd_hwdep *hw, struct file * file, long long offset, int orig); 32 long (*read) (struct snd_hwdep *hw, char __user *buf, long count, loff_t *offset); 33 long (*write) (struct snd_hwdep *hw, const char __user *buf, long count, loff_t *offset); 34 int (*open) (struct snd_hwdep * hw, struct file * file); 35 int (*release) (struct snd_hwdep *hw, struct file * file); 36 unsigned int (*poll) (struct snd_hwdep *hw, struct file * file, poll_table * wait); 37 int (*ioctl) (struct snd_hwdep *hw, struct file * file, unsigned int cmd, unsigned long arg); 38 int (*ioctl_compat) (struct snd_hwdep *hw, struct file * file, unsigned int cmd, unsigned long arg); 39 int (*mmap) (struct snd_hwdep *hw, struct file * file, struct vm_area_struct * vma); 40 int (*dsp_status) (struct snd_hwdep *hw, struct snd_hwdep_dsp_status *status); 41 int (*dsp_load) (struct snd_hwdep *hw, struct snd_hwdep_dsp_image *image); 32 long long (*llseek)(struct snd_hwdep *hw, struct file *file, 33 long long offset, int orig); 34 long (*read)(struct snd_hwdep *hw, char __user *buf, 35 long count, loff_t *offset); 36 long (*write)(struct snd_hwdep *hw, const char __user *buf, 37 long count, loff_t *offset); 38 int (*open)(struct snd_hwdep *hw, struct file * file); 39 int (*release)(struct snd_hwdep *hw, struct file * file); 40 unsigned int (*poll)(struct snd_hwdep *hw, struct file *file, 41 poll_table *wait); 42 int (*ioctl)(struct snd_hwdep *hw, struct file *file, 43 unsigned int cmd, unsigned long arg); 44 int (*ioctl_compat)(struct snd_hwdep *hw, struct file *file, 45 unsigned int cmd, unsigned long arg); 46 int (*mmap)(struct snd_hwdep *hw, struct file *file, 47 struct vm_area_struct *vma); 48 int (*dsp_status)(struct snd_hwdep *hw, 49 struct snd_hwdep_dsp_status *status); 50 int (*dsp_load)(struct snd_hwdep *hw, 51 struct snd_hwdep_dsp_image *image); 42 52 }; 43 53 … … 62 72 63 73 struct mutex open_mutex; 64 int used; 65 unsigned int dsp_loaded; 66 unsigned int exclusive: 1;74 int used; /* reference counter */ 75 unsigned int dsp_loaded; /* bit fields of loaded dsp indices */ 76 unsigned int exclusive:1; /* exclusive access mode */ 67 77 }; 68 78 -
GPL/trunk/alsa-kernel/include/sound/jack.h
r410 r426 51 51 const char *id; 52 52 char name[100]; 53 void *private_data; 54 void (*private_free)(struct snd_jack *); 53 55 }; 54 56 -
GPL/trunk/alsa-kernel/include/sound/pcm.h
r399 r426 269 269 snd_pcm_uframes_t avail_max; 270 270 snd_pcm_uframes_t hw_ptr_base; /* Position at buffer restart */ 271 snd_pcm_uframes_t hw_ptr_interrupt; /* Position at interrupt time*/ 271 snd_pcm_uframes_t hw_ptr_interrupt; /* Position at interrupt time */ 272 unsigned long hw_ptr_jiffies; /* Time when hw_ptr is updated */ 272 273 273 274 /* -- HW params -- */ … … 365 366 struct snd_timer *timer; /* timer */ 366 367 unsigned timer_running: 1; /* time is running */ 367 spinlock_t timer_lock;368 368 /* -- next substream -- */ 369 369 struct snd_pcm_substream *next; … … 456 456 #endif 457 457 458 int snd_pcm_new(struct snd_card *card, c har *id, int device,458 int snd_pcm_new(struct snd_card *card, const char *id, int device, 459 459 int playback_count, int capture_count, 460 460 struct snd_pcm **rpcm); -
GPL/trunk/alsa-kernel/include/sound/rawmidi.h
r398 r426 43 43 #define SNDRV_RAWMIDI_LFLG_OPEN (3<<0) 44 44 #define SNDRV_RAWMIDI_LFLG_APPEND (1<<2) 45 #define SNDRV_RAWMIDI_LFLG_NOOPENLOCK (1<<3)46 45 47 46 struct snd_rawmidi; -
GPL/trunk/alsa-kernel/include/sound/sb.h
r399 r426 250 250 #define SB_ALS4000_ANALOG_BLOCK_CTRL 0x53 251 251 #define SB_ALS4000_3D_DELAYLINE_PATTERN 0x54 252 #define SB_ALS4000_CR3_CONFIGURATION 0xc3 /* bit 7 is Digital Loop Enable */ 252 253 #define SB_ALS4000_QSOUND 0xdb 253 254 … … 331 332 SB_MIX_INPUT_SW, 332 333 SB_MIX_CAPTURE_PRO, 333 SB_MIX_CAPTURE_DT019X 334 SB_MIX_CAPTURE_DT019X, 335 SB_MIX_MONO_CAPTURE_ALS4K 334 336 }; 335 337 -
GPL/trunk/alsa-kernel/include/sound/sfnt_info.h
r305 r426 203 203 }; 204 204 205 enum { 206 SNDRV_EMUX_IOCTL_VERSION = _IOR('H', 0x80, unsigned int), 207 SNDRV_EMUX_IOCTL_LOAD_PATCH = _IOWR('H', 0x81, struct soundfont_patch_info), 208 SNDRV_EMUX_IOCTL_RESET_SAMPLES = _IO('H', 0x82), 209 SNDRV_EMUX_IOCTL_REMOVE_LAST_SAMPLES = _IO('H', 0x83), 210 SNDRV_EMUX_IOCTL_MEM_AVAIL = _IOW('H', 0x84, int), 211 SNDRV_EMUX_IOCTL_MISC_MODE = _IOWR('H', 0x84, struct snd_emux_misc_mode), 212 }; 205 #define SNDRV_EMUX_IOCTL_VERSION _IOR('H', 0x80, unsigned int) 206 #define SNDRV_EMUX_IOCTL_LOAD_PATCH _IOWR('H', 0x81, struct soundfont_patch_info) 207 #define SNDRV_EMUX_IOCTL_RESET_SAMPLES _IO('H', 0x82) 208 #define SNDRV_EMUX_IOCTL_REMOVE_LAST_SAMPLES _IO('H', 0x83) 209 #define SNDRV_EMUX_IOCTL_MEM_AVAIL _IOW('H', 0x84, int) 210 #define SNDRV_EMUX_IOCTL_MISC_MODE _IOWR('H', 0x84, struct snd_emux_misc_mode) 213 211 214 212 #endif /* __SOUND_SFNT_INFO_H */ -
GPL/trunk/alsa-kernel/include/sound/soc-dapm.h
r410 r426 119 119 wevent, wflags) \ 120 120 { .id = snd_soc_dapm_switch, .name = wname, .reg = wreg, .shift = wshift, \ 121 .invert = winvert, .kcontrols = wcontrols, .num_kcontrols = 1 \121 .invert = winvert, .kcontrols = wcontrols, .num_kcontrols = 1, \ 122 122 .event = wevent, .event_flags = wflags} 123 123 #define SND_SOC_DAPM_MUX_E(wname, wreg, wshift, winvert, wcontrols, \ … … 193 193 .put = snd_soc_dapm_put_value_enum_double, \ 194 194 .private_value = (unsigned long)&xenum } 195 #define SOC_DAPM_PIN_SWITCH(xname) \ 196 { .iface = SNDRV_CTL_ELEM_IFACE_MIXER, .name = xname " Switch", \ 197 .info = snd_soc_dapm_info_pin_switch, \ 198 .get = snd_soc_dapm_get_pin_switch, \ 199 .put = snd_soc_dapm_put_pin_switch, \ 200 .private_value = (unsigned long)xname } 195 201 196 202 /* dapm stream operations */ … … 239 245 int snd_soc_dapm_put_value_enum_double(struct snd_kcontrol *kcontrol, 240 246 struct snd_ctl_elem_value *ucontrol); 247 int snd_soc_dapm_info_pin_switch(struct snd_kcontrol *kcontrol, 248 struct snd_ctl_elem_info *uinfo); 249 int snd_soc_dapm_get_pin_switch(struct snd_kcontrol *kcontrol, 250 struct snd_ctl_elem_value *uncontrol); 251 int snd_soc_dapm_put_pin_switch(struct snd_kcontrol *kcontrol, 252 struct snd_ctl_elem_value *uncontrol); 241 253 int snd_soc_dapm_new_control(struct snd_soc_codec *codec, 242 254 const struct snd_soc_dapm_widget *widget); -
GPL/trunk/alsa-kernel/include/sound/soc.h
r410 r426 17 17 #include <linux/types.h> 18 18 #include <linux/workqueue.h> 19 #include <linux/interrupt.h> 20 #include <linux/kernel.h> 19 21 #include <sound/core.h> 20 22 #include <sound/pcm.h> … … 169 171 struct snd_soc_jack; 170 172 struct snd_soc_jack_pin; 173 #ifdef CONFIG_GPIOLIB 174 struct snd_soc_jack_gpio; 175 #endif 171 176 172 177 typedef int (*hw_write_t)(void *,const char* ,int); … … 195 200 int snd_soc_jack_add_pins(struct snd_soc_jack *jack, int count, 196 201 struct snd_soc_jack_pin *pins); 202 #ifdef CONFIG_GPIOLIB 203 int snd_soc_jack_add_gpios(struct snd_soc_jack *jack, int count, 204 struct snd_soc_jack_gpio *gpios); 205 void snd_soc_jack_free_gpios(struct snd_soc_jack *jack, int count, 206 struct snd_soc_jack_gpio *gpios); 207 #endif 197 208 198 209 /* codec IO */ … … 264 275 bool invert; 265 276 }; 277 278 /** 279 * struct snd_soc_jack_gpio - Describes a gpio pin for jack detection 280 * 281 * @gpio: gpio number 282 * @name: gpio name 283 * @report: value to report when jack detected 284 * @invert: report presence in low state 285 * @debouce_time: debouce time in ms 286 */ 287 #ifdef CONFIG_GPIOLIB 288 struct snd_soc_jack_gpio { 289 unsigned int gpio; 290 const char *name; 291 int report; 292 int invert; 293 int debounce_time; 294 struct snd_soc_jack *jack; 295 struct work_struct work; 296 }; 297 #endif 266 298 267 299 struct snd_soc_jack { … … 419 451 struct snd_soc_device *socdev; 420 452 453 struct snd_soc_codec *codec; 454 421 455 struct snd_soc_platform *platform; 422 456 struct delayed_work delayed_work; … … 428 462 struct device *dev; 429 463 struct snd_soc_card *card; 430 struct snd_soc_codec *codec;431 464 struct snd_soc_codec_device *codec_dev; 432 465 void *codec_data; -
GPL/trunk/alsa-kernel/include/sound/tea575x-tuner.h
r410 r426 23 23 */ 24 24 25 #include <linux/videodev .h>25 #include <linux/videodev2.h> 26 26 #include <media/v4l2-dev.h> 27 #include <media/v4l2-ioctl.h> 27 28 28 29 struct snd_tea575x; … … 36 37 struct snd_tea575x { 37 38 struct snd_card *card; 38 struct video_device vd; /* video device */ 39 struct v4l2_file_operations fops; 39 struct video_device *vd; /* video device */ 40 40 int dev_nr; /* requested device number + 1 */ 41 int vd_registered; /* video device is registered */42 41 int tea5759; /* 5759 chip is present */ 42 int mute; /* Device is muted? */ 43 43 unsigned int freq_fixup; /* crystal onboard */ 44 44 unsigned int val; /* hw value */ -
GPL/trunk/alsa-kernel/include/sound/version.h
r410 r426 1 1 /* include/version.h */ 2 #define CONFIG_SND_VERSION "1.0. 19"2 #define CONFIG_SND_VERSION "1.0.20" 3 3 #define CONFIG_SND_DATE ""
Note:
See TracChangeset
for help on using the changeset viewer.