Skip to content
Commit 62f134ab authored by Greg Kroah-Hartman's avatar Greg Kroah-Hartman Committed by Takashi Iwai
Browse files

ALSA: core: fix up bus match const issues.



In commit d69d8048 ("driver core: have match() callback in struct
bus_type take a const *"), the match bus callback was changed to have
the driver be a const pointer.  Unfortunately that const attribute was
thrown away when container_of() is called, which is not correct and was
not caught by the compiler due to how container_of() is implemented.
Fix this up by correctly preserving the const attribute of the driver
passed to the bus match function which requires the hdac_driver match
function to also take a const pointer for the driver structure.

Cc: Jaroslav Kysela <perex@perex.cz>
Cc: Takashi Iwai <tiwai@suse.com>
Fixes: d69d8048 ("driver core: have match() callback in struct bus_type take a const *")
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Link: https://patch.msgid.link/2025052204-hyphen-thermal-3e72@gregkh


Signed-off-by: default avatarTakashi Iwai <tiwai@suse.de>
parent 462e244f
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment