Skip to content

Commit bbb8e71

Browse files
Sarah Granttiwai
authored andcommitted
ALSA: usb-audio: Add Pioneer DJM-450 mixer controls
These values mirror those of the Pioneer DJM-250MK2 as the channel layout appears identical based on my observations. This duplication could be removed in later contributions if desired. Signed-off-by: Sarah Grant <[email protected]> Cc: <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Takashi Iwai <[email protected]>
1 parent c5c325b commit bbb8e71

File tree

1 file changed

+30
-0
lines changed

1 file changed

+30
-0
lines changed

sound/usb/mixer_quirks.c

Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2978,6 +2978,7 @@ static int snd_bbfpro_controls_create(struct usb_mixer_interface *mixer)
29782978
#define SND_DJM_850_IDX 0x2
29792979
#define SND_DJM_900NXS2_IDX 0x3
29802980
#define SND_DJM_750MK2_IDX 0x4
2981+
#define SND_DJM_450_IDX 0x5
29812982

29822983

29832984
#define SND_DJM_CTL(_name, suffix, _default_value, _windex) { \
@@ -3108,6 +3109,31 @@ static const struct snd_djm_ctl snd_djm_ctls_250mk2[] = {
31083109
};
31093110

31103111

3112+
// DJM-450
3113+
static const u16 snd_djm_opts_450_cap1[] = {
3114+
0x0103, 0x0100, 0x0106, 0x0107, 0x0108, 0x0109, 0x010d, 0x010a };
3115+
3116+
static const u16 snd_djm_opts_450_cap2[] = {
3117+
0x0203, 0x0200, 0x0206, 0x0207, 0x0208, 0x0209, 0x020d, 0x020a };
3118+
3119+
static const u16 snd_djm_opts_450_cap3[] = {
3120+
0x030a, 0x0311, 0x0312, 0x0307, 0x0308, 0x0309, 0x030d };
3121+
3122+
static const u16 snd_djm_opts_450_pb1[] = { 0x0100, 0x0101, 0x0104 };
3123+
static const u16 snd_djm_opts_450_pb2[] = { 0x0200, 0x0201, 0x0204 };
3124+
static const u16 snd_djm_opts_450_pb3[] = { 0x0300, 0x0301, 0x0304 };
3125+
3126+
static const struct snd_djm_ctl snd_djm_ctls_450[] = {
3127+
SND_DJM_CTL("Capture Level", cap_level, 0, SND_DJM_WINDEX_CAPLVL),
3128+
SND_DJM_CTL("Ch1 Input", 450_cap1, 2, SND_DJM_WINDEX_CAP),
3129+
SND_DJM_CTL("Ch2 Input", 450_cap2, 2, SND_DJM_WINDEX_CAP),
3130+
SND_DJM_CTL("Ch3 Input", 450_cap3, 0, SND_DJM_WINDEX_CAP),
3131+
SND_DJM_CTL("Ch1 Output", 450_pb1, 0, SND_DJM_WINDEX_PB),
3132+
SND_DJM_CTL("Ch2 Output", 450_pb2, 1, SND_DJM_WINDEX_PB),
3133+
SND_DJM_CTL("Ch3 Output", 450_pb3, 2, SND_DJM_WINDEX_PB)
3134+
};
3135+
3136+
31113137
// DJM-750
31123138
static const u16 snd_djm_opts_750_cap1[] = {
31133139
0x0101, 0x0103, 0x0106, 0x0107, 0x0108, 0x0109, 0x010a, 0x010f };
@@ -3203,6 +3229,7 @@ static const struct snd_djm_device snd_djm_devices[] = {
32033229
[SND_DJM_850_IDX] = SND_DJM_DEVICE(850),
32043230
[SND_DJM_900NXS2_IDX] = SND_DJM_DEVICE(900nxs2),
32053231
[SND_DJM_750MK2_IDX] = SND_DJM_DEVICE(750mk2),
3232+
[SND_DJM_450_IDX] = SND_DJM_DEVICE(450),
32063233
};
32073234

32083235

@@ -3454,6 +3481,9 @@ int snd_usb_mixer_apply_create_quirk(struct usb_mixer_interface *mixer)
34543481
case USB_ID(0x2b73, 0x0017): /* Pioneer DJ DJM-250MK2 */
34553482
err = snd_djm_controls_create(mixer, SND_DJM_250MK2_IDX);
34563483
break;
3484+
case USB_ID(0x2b73, 0x0013): /* Pioneer DJ DJM-450 */
3485+
err = snd_djm_controls_create(mixer, SND_DJM_450_IDX);
3486+
break;
34573487
case USB_ID(0x08e4, 0x017f): /* Pioneer DJ DJM-750 */
34583488
err = snd_djm_controls_create(mixer, SND_DJM_750_IDX);
34593489
break;

0 commit comments

Comments
 (0)