Linux - HardwareThis forum is for Hardware issues.
Having trouble installing a piece of hardware? Want to know if that peripheral is compatible with Linux?
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
I need to update a codec for an old kernel; specifically, updating the WM8753 to the WM8750 on kernel-2.6.35.14. The CODEC itself exists in the kernel. Other than adding the new codec into the .config file s/t:
CONFIG_SND_SOC_IMX_CCWMX51_WM8750=y
and
CONFIG_SND_SOC_WM8750=y
what does it take?
The documentation found in the kernel/documentation/sound/alsa/soc directory mentions a: codec, platform and machine driver. However, a simple grep search for "wm8753" reveals that there is more than just 3 .c files referencing the codec. Granted, many of these files will be for different boards mine is an imx51 so I can eliminate most of them. I believe I have found the machine driver: sound/soc/imx/imx-ccwmx51-wm8753.c the rest of the files referencing "wm8753" are located @ arch/arm/mach-mx5 and so I am assuming these are the platform drivers?
What I was hoping was that I could simply change any reference of the wm8753 to wm8750 but most of my experience with hardware was in college on DOS systems using programs like Quartus and languages like VHDL. Actually writing drivers is something I have never done before and I am new to the Linux world as well.
That being said if anyone has any experience with this sort of thing I am all ears and I would be interested to know what you have to say or any advice you might be able to give me!
Distribution: Debian testing/sid; OpenSuSE; Fedora; Mint
Posts: 5,524
Rep:
Where is the new module coming from? Do you simply want to reconfigure the kernel? Do you have the kernel sources installed? This might help, depending on what exactly you're trying to accomplish. https://kerneltweaks.wordpress.com/2...l-source-code/
If you just want to reconfigure the existing kernel to include different parts, switch to the kernel source directory and run 'make menuconfig' as root.
Last edited by AwesomeMachine; 10-10-2018 at 11:32 AM.
If you just want to reconfigure the existing kernel to include different parts, switch to the kernel source directory and run 'make menuconfig' as root.
This is how I went about getting the new codec to show up in the .config file in the main kernel directory. What I am attempting to do now is make all the necessary changes in the drivers so that this codec can be used.
Maybe I should have mentioned. There was an update in the actual physical codec on the board, along with a new amplifier. I am attempting to get that new hardware working.
EDIT: Essentially, I believe what this boils down to is being able to adapt the old machine driver for the wm8753 to work with the wm8750 but there is no documentation on how to right machine drivers for specific codecs that i can find. So if anyone has ever written a machine driver for a codec then feel free to comment.
Here is the error I am receiving when I boot the kernel:
Unknown hardware: "WM8750" "" "" "" ""
Hardware is initialized using a guess method
alsactl: set_control:1255: failed to obtain info for control #2 (No such file or directory)
alsactl: set_control:1255: failed to obtain info for control #6 (No such file or directory)
alsactl: set_control:1255: failed to obtain info for control #7 (No such file or directory)
alsactl: set_control:1255: failed to obtain info for control #8 (No such file or directory)...
Anyone have an idea of how I am supposed to initialize this hardware? I figure that is the machine drivers job but I think I have that built correctly so maybe not?
After versioning my kernel I could tell it was actually using my altered kernel. So I feel like my machine driver is correct and should work. However, I am getting an error in the boot process:
Unknown hardware: "WM8750" "" "" "" ""
Hardware is initialized using a guess method
alsactl: set_control:1255: failed to obtain info for control #2 (No such file or directory)
alsactl: set_control:1255: failed to obtain info for control #6 (No such file or directory)
alsactl: set_control:1255: failed to obtain info for control #7 (No such file or directory)
I have looked online and have gotten mixed information on how to deal with this error. It was sugjested that I turn off debugging in alsa config:
I am not sure what the significance of missing the "HiFi-0" is.
Code:
# aplay -L
null
Discard all samples (playback) or generate zero samples (capture)
default:CARD=ccwmx51js
ccwmx51js,
Default Audio Device
# alsactl restore
alsactl: load_state:1571: Cannot open /etc/asound.state for reading: no such file or directory
Unknown hardware "WM8750" "" "" "" ""
Hardware is initialized using a guess method
If I run this same command with an older codec (working hardware) I get the same error:
Code:
# alsactl restore
alsactl: load_state:1571: Cannot open /etc/asound.state for reading: no such file or directory
Unknown hardware "WM8753" "" "" "" ""
Hardware is initialized using a guess method
The old kernel was customized by Digi for their SOM which was built on top of the i.MX51 board. The old codec is no longer being produced (EOL) so the new codec is replacing that hardware.
I have managed to get the error to change (somewhat). I changed the naming convention in the mach-mx5 directory and the sound/soc/imx directory. Now instead of saying:
Code:
Unknown hardware: "WM8750" "" "" "" ""
Hardware is initialized using a guess method
alsactl: set_control:1255: failed to obtain info for control #2 (No such file or directory)
alsactl: set_control:1255: failed to obtain info for control #6 (No such file or directory)
alsactl: set_control:1255: failed to obtain info for control #7 (No such file or directory)
alsactl: set_control:1255: failed to obtain info for control #8 (No such file or directory)... (repeats a few more times)
it simply says:
Code:
No state is present for card ccwmx51p51
Unknown hardware: "WM8750" "" "" "" ""
Hardware is initialized using a guess method
No state is present for card ccwmx51p51
# aplay -L
null
Discard all samples (playback) or generate zero samples (capture)
default:CARD=ccwmx51p51
ccwmx51p51,
Default Audio Device
Code:
# speaker-test
speaker-test 1.0.23
Playback device is default
Stream parameters are 48000Hz, S16_LE, 1 channels
Using 16 octaves of pink noise
Playback open error: -16,Device or resource busy
Playback open error: -16,Device or resource busy
Playback open error: -16,Device or resource busy
Playback open error: -16,Device or resource busy
Playback open error: -16,Device or resource busy
Playback open error: -16,Device or resource busy
Playback open error: -16,Device or resource busy..(will continue if not stopped)
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.