ASoC: msm: Remove usage of dev_set_name in audio drivers
Currently audio drivers use dev_set_name when the device's probe
function is invoked to change device name. However the device name
cannot be changed after the device is registered by the Kernel and
inside the probe functions. Using dev_set_name would cause random
memory corruption leading to kernel crashes.
dev_set_name is used in platform and cpu dai drivers to satisfy the
needs of the ALSA SoC framework. ASoC framework does make use of
platform and cpu dai names to check whether they are registered to
it or not for sound card instantiation. However, the framework has
an alternative way to compare the device's of_nodes against dai_link's
of_nodes to know whether the platform/cpu dai is registered or not.
Make changes in the driver to retrieve of_nodes and then assign to
dai_link's of_node so that we can get rid of using dev_set_name in
the drivers.
CRs-Fixed: 706768
Change-Id: I085cfbe4bc60e1b7ec3522508989e6536b1af126
Signed-off-by:
Phani Kumar Uppalapati <phaniu@codeaurora.org>
Loading
Please register or sign in to comment