LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware
User Name
Password
Slackware This Forum is for the discussion of Slackware Linux.

Notices


Reply
  Search this Thread
Old 08-08-2014, 01:32 PM   #1
TheWormKill
LQ Newbie
 
Registered: Aug 2014
Distribution: Slackware64 14.1
Posts: 3

Rep: Reputation: Disabled
Slackware64 on Lenovo g50-70: no sound


Hello everyone!
I hope that my post belongs here, since it's an issue thats (probably) hardware-specific. I installed Slackware64 14.1 on my new Lenovo IdeaPad g50-70, and most things run fine (more on that in a different post). Problem is, I don't get any sound output, when I try using Audacious I get this error:
Code:
ALSA error: No suitable mixer element found.

ALSA error: snd_mixer_find_selem failed.

ALSA error: snd_pcm_open failed: No such file or directory.
I tried following the guide at http://docs.slackware.com/howtos:har..._snd-hda-intel
but no luck.

lsmod | grep snd:
Code:
snd_hda_codec_conexant    35276  1 
snd_hda_codec_hdmi     29622  1 
snd_hda_intel          34861  0 
snd_hda_codec         143196  3 snd_hda_codec_hdmi,snd_hda_codec_conexant,snd_hda_intel
snd_hwdep               6388  1 snd_hda_codec
snd_pcm                76009  3 snd_hda_codec_hdmi,snd_hda_codec,snd_hda_intel
snd_page_alloc          7098  2 snd_pcm,snd_hda_intel
snd_timer              18614  1 snd_pcm
snd                    58630  7 snd_hwdep,snd_timer,snd_hda_codec_hdmi,snd_hda_codec_conexant,snd_pcm,snd_hda_codec,snd_hda_intel
soundcore               5354  1 snd
Code:
echo "options snd-hda-intel model=auto" > /etc/modprobe.d/snd-hda-intel.conf
and rebooting didn't help.

Code:
cat /proc/asound/card*/codec* | grep Codec:
Codec: Intel Haswell HDMI
Codec: Conexant CX20751/2
In /usr/src/linux/Documentation/sound/alsa/HD-Audio-Models.txt
I couldn't find anything.

I checked alsamixer, it's not muted. For the record: I use fluxbox.
I hope I provided enough information so we can find a solution.
thanks,
TheWormKill

Last edited by TheWormKill; 08-09-2014 at 12:34 PM.
 
Old 08-08-2014, 09:21 PM   #2
allend
LQ 5k Club
 
Registered: Oct 2003
Location: Melbourne
Distribution: Slackware64-15.0
Posts: 6,371

Rep: Reputation: 2749Reputation: 2749Reputation: 2749Reputation: 2749Reputation: 2749Reputation: 2749Reputation: 2749Reputation: 2749Reputation: 2749Reputation: 2749Reputation: 2749
Welcome to LQ!

Your Lenovo g50-70 has HDMI and analog sound devices. It is likely that the HDMI device is being selected as the default, which is not what you want.
Perhaps this will help.
http://docs.slackware.com/howtos:har...s_on_slackware
An alternative to creating a /etc/asound.conf file is to provide options to the snd-hda-intel kernel module using the id reported by 'aplay -l' for the two devices in conjunction with the index values you want. e.g.
http://www.linuxquestions.org/questi...2/#post5172943

Last edited by allend; 08-08-2014 at 09:53 PM.
 
2 members found this post helpful.
Old 08-09-2014, 04:51 AM   #3
TheWormKill
LQ Newbie
 
Registered: Aug 2014
Distribution: Slackware64 14.1
Posts: 3

Original Poster
Rep: Reputation: Disabled
So I tried following the HOWTO and
Code:
aplay -D plughw:1,0 test.wav
did result in a message that the file is playing (with no sound output). Every other device/index ombination throws an error.
Code:
aplay: main:722: audio open error: No such file or directory
If I open alsamixer afterwards, I get this error:
Code:
cannot open mixer: Invalid argument
so I start alsamixer by typing
Code:
alsamixer -c 1
my /etc/asound.conf is exactly the same as in the HOWTO.
It's not muted, all volumes are on mximum, still no sound.
Apart from that, I found a few valid device/index combinations: 0,3 0,7 and 0,8 (all of them are somehow marked as HDMI and throw an error:
Code:
aplay: pcm_write:1939: write error: Input/output error
Maybe because nothing is pugged into the HDMI-port? (I can't verify the results with some device)
The audacious-error has changed:
Code:
ALSA error: No suitable mixer element found.

ALSA error: snd_mixer_attach failed: Invalid argument.

ALSA error: snd_pcm_hw_params_set_rate failed: Invalid argument.
Sorry for the horrible structure, I wrote this as I tried different solutions.
Thanks for welcoming me, btw.

EDIT:
Oh god, I am such a dipshit: the master WAS muted, but I didn't realize it.
But if I plug in my headphones, the sound is still plaed from the speakers...

Last edited by TheWormKill; 08-09-2014 at 04:55 AM. Reason: I'm an idiot
 
Old 08-09-2014, 07:07 AM   #4
Drakeo
Senior Member
 
Registered: Jan 2008
Location: Urbana IL
Distribution: Slackware, Slacko,
Posts: 3,716
Blog Entries: 3

Rep: Reputation: 483Reputation: 483Reputation: 483Reputation: 483Reputation: 483
need to see aplay -l so we know which device is default then point your system to set it to default. computers when they boot they load the graphics chip first and many laptops have hdmi it is part of graphics and sound so it is loaded first. They want it that way laptops are mobile devices for many things. and the main one is presentations. Plug into the hdmi and extra vga port and it is all default. but unfortunately the analog sound you want is going to be placed some times as card to or slot 1 .

aplay -l this will show you the default one first. i did this to my /etc/modprobe.d/sound.conf
Code:
alias snd-card-0 snd-hda-intel
alias sound-slot-0 snd-hda-intel
options snd slots=snd-hda-intel,snd-usb-audio
this put it at slot 0 and system wide default then if I plugged in a usb mic or headset
it would put it at slot 1. then slot 2 becomes my hdmi.

Last edited by Drakeo; 08-09-2014 at 07:09 AM.
 
Old 08-09-2014, 07:18 AM   #5
Drakeo
Senior Member
 
Registered: Jan 2008
Location: Urbana IL
Distribution: Slackware, Slacko,
Posts: 3,716
Blog Entries: 3

Rep: Reputation: 483Reputation: 483Reputation: 483Reputation: 483Reputation: 483
Also if you want to do it locally here is a script that will help you slackware runs programs vanilla so sometimes it is better to go to ALSA for extra knowledge.
name this script asoundrc.sh and run it you can set it local. remember if in KDE you may have to restart kde. or run /etc/rc.d/rc.alsa restart
Code:
% cat /usr/bin/asoundrc
#!/bin/bash
# asoundrc v0.1.0 20090101 markc@renta.net GPLv3
# asoundrc v0.2.0 20090320 quatro_por_quatro@yahoo.es GPLv3
#
# A simple script to create a particular default audio device regardless
# of what cards are loaded or in what order. It could be used anytime or
# placed in a ~/.bashrc script for a persistent setup every login.
#
# Usage: asoundrc [DEFAULT_CARD] > ~/.asoundrc

# use the first parameter as the card name, or else
# look for the sound card, discarding those that are only microphones
# when there are multiple cards, use the first one
if default_card="${1:-$(cat "$(for f in $(ls -1 /proc/asound/card[0-9]*/{midi,codec}* 2>/dev/null); do echo "${f%/*}"; done \
| sed -e '\|^[\[:blank:]\]$|d' -e 'q')/id" 2>/dev/null)}"; then
   echo "Using sound card: ${default_card}" >&2 
   cat /proc/asound/card[0-9]*/id | \
   gawk --assign default_card="${default_card}" \
'{print "pcm."$1" { type hw; card "$1"; }\nctl."$1" { type hw; card "$1"; }" }
END {print "pcm.!default pcm."default_card"\nctl.!default ctl."default_card}'
else
   echo "Warning: No sound cards found." >&2
fi
you can run it like it is and it will print an output then you can use it to create an ~/.asoundrc note the dot.
or you may use it as the script info reads.

Last edited by Drakeo; 08-09-2014 at 07:21 AM.
 
Old 08-09-2014, 08:08 AM   #6
allend
LQ 5k Club
 
Registered: Oct 2003
Location: Melbourne
Distribution: Slackware64-15.0
Posts: 6,371

Rep: Reputation: 2749Reputation: 2749Reputation: 2749Reputation: 2749Reputation: 2749Reputation: 2749Reputation: 2749Reputation: 2749Reputation: 2749Reputation: 2749Reputation: 2749
If 'aplay -D plughw:1,0 test.wav' "did result in a message that the file is playing (with no sound output)" when "the master WAS muted" then you have identified that the sound device that you want to use was being assigned index=1.
If "/etc/asound.conf is exactly the same as in the HOWTO" then your sound setup should now be accessing the required sound device as the default.
Quote:
But if I plug in my headphones, the sound is still plaed from the speakers...
This should be resolved by providing an appropriate 'model=' option to the snd-hda-intel kernel module. Have you tried 'model=ideapad'?

PS
Quote:
Oh god, I am such a dipshit
You lose! I have probably been that since before you were born.

Last edited by allend; 08-09-2014 at 08:22 AM.
 
Old 08-09-2014, 08:23 AM   #7
TheWormKill
LQ Newbie
 
Registered: Aug 2014
Distribution: Slackware64 14.1
Posts: 3

Original Poster
Rep: Reputation: Disabled
Hm... interesting:
it works now, at least after setting model=ideapad I get output on the speakers and my headphones, so I just have to mute the speakers in alsamixer if I want to use the headphones, I'm able to live with that. Regarding the fact that device 0 is the HDMI:
I think I've mentioned the 3 devices on 0,3 0,7 and 0,8 that are labeled as HDMI. My /etc/asound.conf is the same as in the HOWTO, that's what I meant.
So the issue is resolved, many thanks to all who helped me!

@allend: yes, in Oct 2003 I was going to bed at 7

Last edited by TheWormKill; 08-09-2014 at 08:25 AM.
 
Old 08-09-2014, 08:33 AM   #8
allend
LQ 5k Club
 
Registered: Oct 2003
Location: Melbourne
Distribution: Slackware64-15.0
Posts: 6,371

Rep: Reputation: 2749Reputation: 2749Reputation: 2749Reputation: 2749Reputation: 2749Reputation: 2749Reputation: 2749Reputation: 2749Reputation: 2749Reputation: 2749Reputation: 2749
Thought so. In 2003 I was putting my daughter to bed at 7.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Lenovo W530 sound in Slackware 14 malloc Linux - Hardware 1 01-07-2013 05:37 PM
Asus G50 Hangs when installing Mrblurr Linux - Laptop and Netbook 2 03-15-2010 07:49 PM
lenovo N100 sound problem vishesh Linux - Laptop and Netbook 3 11-26-2008 08:44 AM
Ubuntu 8.04 no sound on my Lenovo R61i mrpc_cambodia Ubuntu 3 06-10-2008 11:22 PM
No sound in lenovo laptop with SUSE sajipkuttan Linux - Newbie 1 04-21-2008 05:22 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware

All times are GMT -5. The time now is 07:59 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration