1SND_CARD_NEW(9) Management of Cards and Device SND_CARD_NEW(9)
2
3
4
6 snd_card_new - create and initialize a soundcard structure
7
9 int snd_card_new(struct device * parent, int idx, const char * xid,
10 struct module * module, int extra_size,
11 struct snd_card ** card_ret);
12
14 parent
15 the parent device object
16
17 idx
18 card index (address) [0 ... (SNDRV_CARDS-1)]
19
20 xid
21 card identification (ASCII string)
22
23 module
24 top level module for locking
25
26 extra_size
27 allocate this extra size after the main soundcard structure
28
29 card_ret
30 the pointer to store the created card instance
31
33 Creates and initializes a soundcard structure.
34
35 The function allocates snd_card instance via kzalloc with the given
36 space for the driver to use freely. The allocated struct is stored in
37 the given card_ret pointer.
38
40 Zero if successful or a negative error code.
41
43Kernel Hackers Manual 3.10 June 2019 SND_CARD_NEW(9)