]> git.ipfire.org Git - thirdparty/kernel/stable-queue.git/blob - releases/4.9.164/alsa-bebob-use-more-identical-mod_alias-for-saffire-pro-10-i-o-against-liquid-saffire-56.patch
4.9-stable patches
[thirdparty/kernel/stable-queue.git] / releases / 4.9.164 / alsa-bebob-use-more-identical-mod_alias-for-saffire-pro-10-i-o-against-liquid-saffire-56.patch
1 From 7dc661bd8d3261053b69e4e2d0050cd1ee540fc1 Mon Sep 17 00:00:00 2001
2 From: Takashi Sakamoto <o-takashi@sakamocchi.jp>
3 Date: Tue, 26 Feb 2019 13:38:16 +0900
4 Subject: ALSA: bebob: use more identical mod_alias for Saffire Pro 10 I/O against Liquid Saffire 56
5
6 From: Takashi Sakamoto <o-takashi@sakamocchi.jp>
7
8 commit 7dc661bd8d3261053b69e4e2d0050cd1ee540fc1 upstream.
9
10 ALSA bebob driver has an entry for Focusrite Saffire Pro 10 I/O. The
11 entry matches vendor_id in root directory and model_id in unit
12 directory of configuration ROM for IEEE 1394 bus.
13
14 On the other hand, configuration ROM of Focusrite Liquid Saffire 56
15 has the same vendor_id and model_id. This device is an application of
16 TCAT Dice (TCD2220 a.k.a Dice Jr.) however ALSA bebob driver can be
17 bound to it randomly instead of ALSA dice driver. At present, drivers
18 in ALSA firewire stack can not handle this situation appropriately.
19
20 This commit uses more identical mod_alias for Focusrite Saffire Pro 10
21 I/O in ALSA bebob driver.
22
23 $ python2 crpp < /sys/bus/firewire/devices/fw1/config_rom
24 ROM header and bus information block
25 -----------------------------------------------------------------
26 400 042a829d bus_info_length 4, crc_length 42, crc 33437
27 404 31333934 bus_name "1394"
28 408 f0649222 irmc 1, cmc 1, isc 1, bmc 1, pmc 0, cyc_clk_acc 100,
29 max_rec 9 (1024), max_rom 2, gen 2, spd 2 (S400)
30 40c 00130e01 company_id 00130e |
31 410 000606e0 device_id 01000606e0 | EUI-64 00130e01000606e0
32
33 root directory
34 -----------------------------------------------------------------
35 414 0009d31c directory_length 9, crc 54044
36 418 04000014 hardware version
37 41c 0c0083c0 node capabilities per IEEE 1394
38 420 0300130e vendor
39 424 81000012 --> descriptor leaf at 46c
40 428 17000006 model
41 42c 81000016 --> descriptor leaf at 484
42 430 130120c2 version
43 434 d1000002 --> unit directory at 43c
44 438 d4000006 --> dependent info directory at 450
45
46 unit directory at 43c
47 -----------------------------------------------------------------
48 43c 0004707c directory_length 4, crc 28796
49 440 1200a02d specifier id: 1394 TA
50 444 13010001 version: AV/C
51 448 17000006 model
52 44c 81000013 --> descriptor leaf at 498
53
54 dependent info directory at 450
55 -----------------------------------------------------------------
56 450 000637c7 directory_length 6, crc 14279
57 454 120007f5 specifier id
58 458 13000001 version
59 45c 3affffc7 (immediate value)
60 460 3b100000 (immediate value)
61 464 3cffffc7 (immediate value)
62 468 3d600000 (immediate value)
63
64 descriptor leaf at 46c
65 -----------------------------------------------------------------
66 46c 00056f3b leaf_length 5, crc 28475
67 470 00000000 textual descriptor
68 474 00000000 minimal ASCII
69 478 466f6375 "Focu"
70 47c 73726974 "srit"
71 480 65000000 "e"
72
73 descriptor leaf at 484
74 -----------------------------------------------------------------
75 484 0004a165 leaf_length 4, crc 41317
76 488 00000000 textual descriptor
77 48c 00000000 minimal ASCII
78 490 50726f31 "Pro1"
79 494 30494f00 "0IO"
80
81 descriptor leaf at 498
82 -----------------------------------------------------------------
83 498 0004a165 leaf_length 4, crc 41317
84 49c 00000000 textual descriptor
85 4a0 00000000 minimal ASCII
86 4a4 50726f31 "Pro1"
87 4a8 30494f00 "0IO"
88
89 $ python2 crpp < /sys/bus/firewire/devices/fw1/config_rom
90 ROM header and bus information block
91 -----------------------------------------------------------------
92 400 040442e4 bus_info_length 4, crc_length 4, crc 17124
93 404 31333934 bus_name "1394"
94 408 e0ff8112 irmc 1, cmc 1, isc 1, bmc 0, pmc 0, cyc_clk_acc 255,
95 max_rec 8 (512), max_rom 1, gen 1, spd 2 (S400)
96 40c 00130e04 company_id 00130e |
97 410 018001e9 device_id 04018001e9 | EUI-64 00130e04018001e9
98
99 root directory
100 -----------------------------------------------------------------
101 414 00065612 directory_length 6, crc 22034
102 418 0300130e vendor
103 41c 8100000a --> descriptor leaf at 444
104 420 17000006 model
105 424 8100000e --> descriptor leaf at 45c
106 428 0c0087c0 node capabilities per IEEE 1394
107 42c d1000001 --> unit directory at 430
108
109 unit directory at 430
110 -----------------------------------------------------------------
111 430 000418a0 directory_length 4, crc 6304
112 434 1200130e specifier id
113 438 13000001 version
114 43c 17000006 model
115 440 8100000f --> descriptor leaf at 47c
116
117 descriptor leaf at 444
118 -----------------------------------------------------------------
119 444 00056f3b leaf_length 5, crc 28475
120 448 00000000 textual descriptor
121 44c 00000000 minimal ASCII
122 450 466f6375 "Focu"
123 454 73726974 "srit"
124 458 65000000 "e"
125
126 descriptor leaf at 45c
127 -----------------------------------------------------------------
128 45c 000762c6 leaf_length 7, crc 25286
129 460 00000000 textual descriptor
130 464 00000000 minimal ASCII
131 468 4c495155 "LIQU"
132 46c 49445f53 "ID_S"
133 470 41464649 "AFFI"
134 474 52455f35 "RE_5"
135 478 36000000 "6"
136
137 descriptor leaf at 47c
138 -----------------------------------------------------------------
139 47c 000762c6 leaf_length 7, crc 25286
140 480 00000000 textual descriptor
141 484 00000000 minimal ASCII
142 488 4c495155 "LIQU"
143 48c 49445f53 "ID_S"
144 490 41464649 "AFFI"
145 494 52455f35 "RE_5"
146 498 36000000 "6"
147
148 Cc: <stable@vger.kernel.org> # v3.16+
149 Fixes: 25784ec2d034 ("ALSA: bebob: Add support for Focusrite Saffire/SaffirePro series")
150 Signed-off-by: Takashi Sakamoto <o-takashi@sakamocchi.jp>
151 Signed-off-by: Takashi Iwai <tiwai@suse.de>
152 Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
153
154 ---
155 sound/firewire/bebob/bebob.c | 14 +++++++++++++-
156 1 file changed, 13 insertions(+), 1 deletion(-)
157
158 --- a/sound/firewire/bebob/bebob.c
159 +++ b/sound/firewire/bebob/bebob.c
160 @@ -474,7 +474,19 @@ static const struct ieee1394_device_id b
161 /* Focusrite, SaffirePro 26 I/O */
162 SND_BEBOB_DEV_ENTRY(VEN_FOCUSRITE, 0x00000003, &saffirepro_26_spec),
163 /* Focusrite, SaffirePro 10 I/O */
164 - SND_BEBOB_DEV_ENTRY(VEN_FOCUSRITE, 0x00000006, &saffirepro_10_spec),
165 + {
166 + // The combination of vendor_id and model_id is the same as the
167 + // same as the one of Liquid Saffire 56.
168 + .match_flags = IEEE1394_MATCH_VENDOR_ID |
169 + IEEE1394_MATCH_MODEL_ID |
170 + IEEE1394_MATCH_SPECIFIER_ID |
171 + IEEE1394_MATCH_VERSION,
172 + .vendor_id = VEN_FOCUSRITE,
173 + .model_id = 0x000006,
174 + .specifier_id = 0x00a02d,
175 + .version = 0x010001,
176 + .driver_data = (kernel_ulong_t)&saffirepro_10_spec,
177 + },
178 /* Focusrite, Saffire(no label and LE) */
179 SND_BEBOB_DEV_ENTRY(VEN_FOCUSRITE, MODEL_FOCUSRITE_SAFFIRE_BOTH,
180 &saffire_spec),