Skip to content

Commit 14b9e4a

Browse files
committed
Merge branch 'for-next' into for-linus
Prep for 6.9 merge. Signed-off-by: Takashi Iwai <tiwai@suse.de>
2 parents 21e59fe + 6fa9ba2 commit 14b9e4a

File tree

132 files changed

+3373
-3025
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

132 files changed

+3373
-3025
lines changed

Documentation/sound/kernel-api/writing-an-alsa-driver.rst

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3864,14 +3864,16 @@ corresponding destructor.
38643864

38653865
And next, set suspend/resume callbacks to the pci_driver::
38663866

3867-
static SIMPLE_DEV_PM_OPS(snd_my_pm_ops, mychip_suspend, mychip_resume);
3867+
static DEFINE_SIMPLE_DEV_PM_OPS(snd_my_pm_ops, mychip_suspend, mychip_resume);
38683868

38693869
static struct pci_driver driver = {
38703870
.name = KBUILD_MODNAME,
38713871
.id_table = snd_my_ids,
38723872
.probe = snd_my_probe,
38733873
.remove = snd_my_remove,
3874-
.driver.pm = &snd_my_pm_ops,
3874+
.driver = {
3875+
.pm = &snd_my_pm_ops,
3876+
},
38753877
};
38763878

38773879
Module Parameters

MAINTAINERS

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5014,6 +5014,7 @@ F: include/linux/mfd/cs42l43*
50145014
F: include/sound/cs*
50155015
F: sound/pci/hda/cirrus*
50165016
F: sound/pci/hda/cs*
5017+
F: sound/pci/hda/hda_component*
50175018
F: sound/pci/hda/hda_cs_dsp_ctl.*
50185019
F: sound/soc/codecs/cs*
50195020

@@ -20485,6 +20486,12 @@ F: include/uapi/sound/compress_*
2048520486
F: sound/core/compress_offload.c
2048620487
F: sound/soc/soc-compress.c
2048720488

20489+
SOUND - CORE KUNIT TEST
20490+
M: Ivan Orlov <ivan.orlov0322@gmail.com>
20491+
L: linux-sound@vger.kernel.org
20492+
S: Supported
20493+
F: sound/core/sound_kunit.c
20494+
2048820495
SOUND - DMAENGINE HELPERS
2048920496
M: Lars-Peter Clausen <lars@metafoo.de>
2049020497
S: Supported

drivers/acpi/scan.c

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1725,7 +1725,9 @@ static bool acpi_device_enumeration_by_parent(struct acpi_device *device)
17251725
{"BSG1160", },
17261726
{"BSG2150", },
17271727
{"CSC3551", },
1728+
{"CSC3554", },
17281729
{"CSC3556", },
1730+
{"CSC3557", },
17291731
{"INT33FE", },
17301732
{"INT3515", },
17311733
/* Non-conforming _HID for Cirrus Logic already released */

drivers/platform/x86/serial-multi-instantiate.c

Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -329,6 +329,19 @@ static const struct smi_node cs35l41_hda = {
329329
.bus_type = SMI_AUTO_DETECT,
330330
};
331331

332+
static const struct smi_node cs35l54_hda = {
333+
.instances = {
334+
{ "cs35l54-hda", IRQ_RESOURCE_AUTO, 0 },
335+
{ "cs35l54-hda", IRQ_RESOURCE_AUTO, 0 },
336+
{ "cs35l54-hda", IRQ_RESOURCE_AUTO, 0 },
337+
{ "cs35l54-hda", IRQ_RESOURCE_AUTO, 0 },
338+
/* a 5th entry is an alias address, not a real device */
339+
{ "cs35l54-hda_dummy_dev" },
340+
{}
341+
},
342+
.bus_type = SMI_AUTO_DETECT,
343+
};
344+
332345
static const struct smi_node cs35l56_hda = {
333346
.instances = {
334347
{ "cs35l56-hda", IRQ_RESOURCE_AUTO, 0 },
@@ -342,6 +355,19 @@ static const struct smi_node cs35l56_hda = {
342355
.bus_type = SMI_AUTO_DETECT,
343356
};
344357

358+
static const struct smi_node cs35l57_hda = {
359+
.instances = {
360+
{ "cs35l57-hda", IRQ_RESOURCE_AUTO, 0 },
361+
{ "cs35l57-hda", IRQ_RESOURCE_AUTO, 0 },
362+
{ "cs35l57-hda", IRQ_RESOURCE_AUTO, 0 },
363+
{ "cs35l57-hda", IRQ_RESOURCE_AUTO, 0 },
364+
/* a 5th entry is an alias address, not a real device */
365+
{ "cs35l57-hda_dummy_dev" },
366+
{}
367+
},
368+
.bus_type = SMI_AUTO_DETECT,
369+
};
370+
345371
/*
346372
* Note new device-ids must also be added to ignore_serial_bus_ids in
347373
* drivers/acpi/scan.c: acpi_device_enumeration_by_parent().
@@ -350,7 +376,9 @@ static const struct acpi_device_id smi_acpi_ids[] = {
350376
{ "BSG1160", (unsigned long)&bsg1160_data },
351377
{ "BSG2150", (unsigned long)&bsg2150_data },
352378
{ "CSC3551", (unsigned long)&cs35l41_hda },
379+
{ "CSC3554", (unsigned long)&cs35l54_hda },
353380
{ "CSC3556", (unsigned long)&cs35l56_hda },
381+
{ "CSC3557", (unsigned long)&cs35l57_hda },
354382
{ "INT3515", (unsigned long)&int3515_data },
355383
/* Non-conforming _HID for Cirrus Logic already released */
356384
{ "CLSA0100", (unsigned long)&cs35l41_hda },

include/sound/ak4531_codec.h

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -65,6 +65,9 @@ int snd_ak4531_mixer(struct snd_card *card, struct snd_ak4531 *_ak4531,
6565
#ifdef CONFIG_PM
6666
void snd_ak4531_suspend(struct snd_ak4531 *ak4531);
6767
void snd_ak4531_resume(struct snd_ak4531 *ak4531);
68+
#else
69+
static inline void snd_ak4531_suspend(struct snd_ak4531 *ak4531) {}
70+
static inline void snd_ak4531_resume(struct snd_ak4531 *ak4531) {}
6871
#endif
6972

7073
#endif /* __SOUND_AK4531_CODEC_H */

include/sound/cs35l56.h

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -257,6 +257,7 @@ struct cs35l56_base {
257257
struct regmap *regmap;
258258
int irq;
259259
struct mutex irq_lock;
260+
u8 type;
260261
u8 rev;
261262
bool init_done;
262263
bool fw_patched;

include/sound/emux_synth.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -103,7 +103,7 @@ struct snd_emux {
103103
int ports[SNDRV_EMUX_MAX_PORTS]; /* The ports for this device */
104104
struct snd_emux_port *portptrs[SNDRV_EMUX_MAX_PORTS];
105105
int used; /* use counter */
106-
char *name; /* name of the device (internal) */
106+
const char *name; /* name of the device (internal) */
107107
struct snd_rawmidi **vmidi;
108108
struct timer_list tlist; /* for pending note-offs */
109109
int timer_active;

include/sound/pcm.h

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -659,6 +659,18 @@ void snd_pcm_stream_unlock_irqrestore(struct snd_pcm_substream *substream,
659659
flags = _snd_pcm_stream_lock_irqsave_nested(substream); \
660660
} while (0)
661661

662+
/* definitions for guard(); use like guard(pcm_stream_lock) */
663+
DEFINE_LOCK_GUARD_1(pcm_stream_lock, struct snd_pcm_substream,
664+
snd_pcm_stream_lock(_T->lock),
665+
snd_pcm_stream_unlock(_T->lock))
666+
DEFINE_LOCK_GUARD_1(pcm_stream_lock_irq, struct snd_pcm_substream,
667+
snd_pcm_stream_lock_irq(_T->lock),
668+
snd_pcm_stream_unlock_irq(_T->lock))
669+
DEFINE_LOCK_GUARD_1(pcm_stream_lock_irqsave, struct snd_pcm_substream,
670+
snd_pcm_stream_lock_irqsave(_T->lock, _T->flags),
671+
snd_pcm_stream_unlock_irqrestore(_T->lock, _T->flags),
672+
unsigned long flags)
673+
662674
/**
663675
* snd_pcm_group_for_each_entry - iterate over the linked substreams
664676
* @s: the iterator

include/sound/sb.h

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -290,6 +290,9 @@ int snd_sbmixer_new(struct snd_sb *chip);
290290
#ifdef CONFIG_PM
291291
void snd_sbmixer_suspend(struct snd_sb *chip);
292292
void snd_sbmixer_resume(struct snd_sb *chip);
293+
#else
294+
static inline void snd_sbmixer_suspend(struct snd_sb *chip) {}
295+
static inline void snd_sbmixer_resume(struct snd_sb *chip) {}
293296
#endif
294297

295298
/* sb8_init.c */

include/uapi/linux/virtio_snd.h

Lines changed: 154 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,14 @@
77

88
#include <linux/virtio_types.h>
99

10+
/*******************************************************************************
11+
* FEATURE BITS
12+
*/
13+
enum {
14+
/* device supports control elements */
15+
VIRTIO_SND_F_CTLS = 0
16+
};
17+
1018
/*******************************************************************************
1119
* CONFIGURATION SPACE
1220
*/
@@ -17,6 +25,8 @@ struct virtio_snd_config {
1725
__le32 streams;
1826
/* # of available channel maps */
1927
__le32 chmaps;
28+
/* # of available control elements */
29+
__le32 controls;
2030
};
2131

2232
enum {
@@ -55,6 +65,15 @@ enum {
5565
/* channel map control request types */
5666
VIRTIO_SND_R_CHMAP_INFO = 0x0200,
5767

68+
/* control element request types */
69+
VIRTIO_SND_R_CTL_INFO = 0x0300,
70+
VIRTIO_SND_R_CTL_ENUM_ITEMS,
71+
VIRTIO_SND_R_CTL_READ,
72+
VIRTIO_SND_R_CTL_WRITE,
73+
VIRTIO_SND_R_CTL_TLV_READ,
74+
VIRTIO_SND_R_CTL_TLV_WRITE,
75+
VIRTIO_SND_R_CTL_TLV_COMMAND,
76+
5877
/* jack event types */
5978
VIRTIO_SND_EVT_JACK_CONNECTED = 0x1000,
6079
VIRTIO_SND_EVT_JACK_DISCONNECTED,
@@ -63,6 +82,9 @@ enum {
6382
VIRTIO_SND_EVT_PCM_PERIOD_ELAPSED = 0x1100,
6483
VIRTIO_SND_EVT_PCM_XRUN,
6584

85+
/* control element event types */
86+
VIRTIO_SND_EVT_CTL_NOTIFY = 0x1200,
87+
6688
/* common status codes */
6789
VIRTIO_SND_S_OK = 0x8000,
6890
VIRTIO_SND_S_BAD_MSG,
@@ -331,4 +353,136 @@ struct virtio_snd_chmap_info {
331353
__u8 positions[VIRTIO_SND_CHMAP_MAX_SIZE];
332354
};
333355

356+
/*******************************************************************************
357+
* CONTROL ELEMENTS MESSAGES
358+
*/
359+
struct virtio_snd_ctl_hdr {
360+
/* VIRTIO_SND_R_CTL_XXX */
361+
struct virtio_snd_hdr hdr;
362+
/* 0 ... virtio_snd_config::controls - 1 */
363+
__le32 control_id;
364+
};
365+
366+
/* supported roles for control elements */
367+
enum {
368+
VIRTIO_SND_CTL_ROLE_UNDEFINED = 0,
369+
VIRTIO_SND_CTL_ROLE_VOLUME,
370+
VIRTIO_SND_CTL_ROLE_MUTE,
371+
VIRTIO_SND_CTL_ROLE_GAIN
372+
};
373+
374+
/* supported value types for control elements */
375+
enum {
376+
VIRTIO_SND_CTL_TYPE_BOOLEAN = 0,
377+
VIRTIO_SND_CTL_TYPE_INTEGER,
378+
VIRTIO_SND_CTL_TYPE_INTEGER64,
379+
VIRTIO_SND_CTL_TYPE_ENUMERATED,
380+
VIRTIO_SND_CTL_TYPE_BYTES,
381+
VIRTIO_SND_CTL_TYPE_IEC958
382+
};
383+
384+
/* supported access rights for control elements */
385+
enum {
386+
VIRTIO_SND_CTL_ACCESS_READ = 0,
387+
VIRTIO_SND_CTL_ACCESS_WRITE,
388+
VIRTIO_SND_CTL_ACCESS_VOLATILE,
389+
VIRTIO_SND_CTL_ACCESS_INACTIVE,
390+
VIRTIO_SND_CTL_ACCESS_TLV_READ,
391+
VIRTIO_SND_CTL_ACCESS_TLV_WRITE,
392+
VIRTIO_SND_CTL_ACCESS_TLV_COMMAND
393+
};
394+
395+
struct virtio_snd_ctl_info {
396+
/* common header */
397+
struct virtio_snd_info hdr;
398+
/* element role (VIRTIO_SND_CTL_ROLE_XXX) */
399+
__le32 role;
400+
/* element value type (VIRTIO_SND_CTL_TYPE_XXX) */
401+
__le32 type;
402+
/* element access right bit map (1 << VIRTIO_SND_CTL_ACCESS_XXX) */
403+
__le32 access;
404+
/* # of members in the element value */
405+
__le32 count;
406+
/* index for an element with a non-unique name */
407+
__le32 index;
408+
/* name identifier string for the element */
409+
__u8 name[44];
410+
/* additional information about the element's value */
411+
union {
412+
/* VIRTIO_SND_CTL_TYPE_INTEGER */
413+
struct {
414+
/* minimum supported value */
415+
__le32 min;
416+
/* maximum supported value */
417+
__le32 max;
418+
/* fixed step size for value (0 = variable size) */
419+
__le32 step;
420+
} integer;
421+
/* VIRTIO_SND_CTL_TYPE_INTEGER64 */
422+
struct {
423+
/* minimum supported value */
424+
__le64 min;
425+
/* maximum supported value */
426+
__le64 max;
427+
/* fixed step size for value (0 = variable size) */
428+
__le64 step;
429+
} integer64;
430+
/* VIRTIO_SND_CTL_TYPE_ENUMERATED */
431+
struct {
432+
/* # of options supported for value */
433+
__le32 items;
434+
} enumerated;
435+
} value;
436+
};
437+
438+
struct virtio_snd_ctl_enum_item {
439+
/* option name */
440+
__u8 item[64];
441+
};
442+
443+
struct virtio_snd_ctl_iec958 {
444+
/* AES/IEC958 channel status bits */
445+
__u8 status[24];
446+
/* AES/IEC958 subcode bits */
447+
__u8 subcode[147];
448+
/* nothing */
449+
__u8 pad;
450+
/* AES/IEC958 subframe bits */
451+
__u8 dig_subframe[4];
452+
};
453+
454+
struct virtio_snd_ctl_value {
455+
union {
456+
/* VIRTIO_SND_CTL_TYPE_BOOLEAN|INTEGER value */
457+
__le32 integer[128];
458+
/* VIRTIO_SND_CTL_TYPE_INTEGER64 value */
459+
__le64 integer64[64];
460+
/* VIRTIO_SND_CTL_TYPE_ENUMERATED value (option indexes) */
461+
__le32 enumerated[128];
462+
/* VIRTIO_SND_CTL_TYPE_BYTES value */
463+
__u8 bytes[512];
464+
/* VIRTIO_SND_CTL_TYPE_IEC958 value */
465+
struct virtio_snd_ctl_iec958 iec958;
466+
} value;
467+
};
468+
469+
/* supported event reason types */
470+
enum {
471+
/* element's value has changed */
472+
VIRTIO_SND_CTL_EVT_MASK_VALUE = 0,
473+
/* element's information has changed */
474+
VIRTIO_SND_CTL_EVT_MASK_INFO,
475+
/* element's metadata has changed */
476+
VIRTIO_SND_CTL_EVT_MASK_TLV
477+
};
478+
479+
struct virtio_snd_ctl_event {
480+
/* VIRTIO_SND_EVT_CTL_NOTIFY */
481+
struct virtio_snd_hdr hdr;
482+
/* 0 ... virtio_snd_config::controls - 1 */
483+
__le16 control_id;
484+
/* event reason bit map (1 << VIRTIO_SND_CTL_EVT_MASK_XXX) */
485+
__le16 mask;
486+
};
487+
334488
#endif /* VIRTIO_SND_IF_H */

0 commit comments

Comments
 (0)