mirror of
https://github.com/adulau/aha.git
synced 2024-12-28 03:36:19 +00:00
ALSA: usb-audio: fix combine_word problem
Fix combine_word problem where first octet is not read properly. The only affected place seems to be the INPUT_TERMINAL type. Before now, sound controls can be created with the output terminal's name which is a fallback mechanism used only for unknown input terminal types. For example, Line can wrongly appear as Speaker. After the change it should appear as Line. The side effect of this change can be that users can expect the wrong control name in their scripts or programs while now we return the correct one. Probably, these defines should use get_unaligned_le16 and friends. Signed-off-by: Julian Anastasov <ja@ssi.bg> Cc: <stable@kernel.org> Signed-off-by: Takashi Iwai <tiwai@suse.de>
This commit is contained in:
parent
70edc800a3
commit
f495088210
1 changed files with 1 additions and 1 deletions
|
@ -210,7 +210,7 @@ struct snd_usb_midi_endpoint_info {
|
|||
/*
|
||||
*/
|
||||
|
||||
#define combine_word(s) ((*s) | ((unsigned int)(s)[1] << 8))
|
||||
#define combine_word(s) ((*(s)) | ((unsigned int)(s)[1] << 8))
|
||||
#define combine_triple(s) (combine_word(s) | ((unsigned int)(s)[2] << 16))
|
||||
#define combine_quad(s) (combine_triple(s) | ((unsigned int)(s)[3] << 24))
|
||||
|
||||
|
|
Loading…
Reference in a new issue