Skip to content

Instantly share code, notes, and snippets.

@agilous
Last active January 20, 2023 16:56
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save agilous/c9e32dd1c13cdd02a5509d1e312ccc45 to your computer and use it in GitHub Desktop.
Save agilous/c9e32dd1c13cdd02a5509d1e312ccc45 to your computer and use it in GitHub Desktop.
Troubleshooting "No Sound" issue on MacBook Pro 13,2 running Ubuntu 22.04.1 LTS

Ubuntu 22.04.1 LTS running on MacBook Pro 13,2

Troubleshooting "no sound" issue.

Resources

  1. Ubuntu Forums: "Audio device detection doesnt work properly"

Next Steps:

Config: /etc/modprobe.d/alsa-base.conf

# autoloader aliases
install sound-slot-0 /sbin/modprobe snd-card-0
install sound-slot-1 /sbin/modprobe snd-card-1
install sound-slot-2 /sbin/modprobe snd-card-2
install sound-slot-3 /sbin/modprobe snd-card-3
install sound-slot-4 /sbin/modprobe snd-card-4
install sound-slot-5 /sbin/modprobe snd-card-5
install sound-slot-6 /sbin/modprobe snd-card-6
install sound-slot-7 /sbin/modprobe snd-card-7

# Cause optional modules to be loaded above generic modules
install snd /sbin/modprobe --ignore-install snd $CMDLINE_OPTS && { /sbin/modprobe --quiet --use-blacklist snd-ioctl32 ; /sbin/modprobe --quiet --use-blacklist snd-seq ; }
#
# Workaround at bug #499695 (reverted in Ubuntu see LP #319505)
install snd-pcm /sbin/modprobe --ignore-install snd-pcm $CMDLINE_OPTS && { /sbin/modprobe --quiet --use-blacklist snd-pcm-oss ; : ; }
install snd-mixer /sbin/modprobe --ignore-install snd-mixer $CMDLINE_OPTS && { /sbin/modprobe --quiet --use-blacklist snd-mixer-oss ; : ; }
install snd-seq /sbin/modprobe --ignore-install snd-seq $CMDLINE_OPTS && { /sbin/modprobe --quiet --use-blacklist snd-seq-midi ; /sbin/modprobe --quiet --use-blacklist snd-seq-oss ; : ; }
#
install snd-rawmidi /sbin/modprobe --ignore-install snd-rawmidi $CMDLINE_OPTS && { /sbin/modprobe --quiet --use-blacklist snd-seq-midi ; : ; }
# Cause optional modules to be loaded above sound card driver modules
install snd-emu10k1 /sbin/modprobe --ignore-install snd-emu10k1 $CMDLINE_OPTS && { /sbin/modprobe --quiet --use-blacklist snd-emu10k1-synth ; }
install snd-via82xx /sbin/modprobe --ignore-install snd-via82xx $CMDLINE_OPTS && { /sbin/modprobe --quiet --use-blacklist snd-seq ; }

# Load saa7134-alsa instead of saa7134 (which gets dragged in by it anyway)
install saa7134 /sbin/modprobe --ignore-install saa7134 $CMDLINE_OPTS && { /sbin/modprobe --quiet --use-blacklist saa7134-alsa ; : ; }
# Prevent abnormal drivers from grabbing index 0
options bt87x index=-2
options cx88_alsa index=-2
options saa7134-alsa index=-2
options snd-atiixp-modem index=-2
options snd-intel8x0m index=-2
options snd-via82xx-modem index=-2
options snd-usb-audio index=-2
options snd-usb-caiaq index=-2
options snd-usb-ua101 index=-2
options snd-usb-us122l index=-2
options snd-usb-usx2y index=-2
# Ubuntu #62691, enable MPU for snd-cmipci
options snd-cmipci mpu_port=0x330 fm_port=0x388
# Keep snd-pcsp from being loaded as first soundcard
options snd-pcsp index=-2
# Keep snd-usb-audio from beeing loaded as first soundcard
options snd-usb-audio index=-2

############## EVERYTHING ABOVE THIS COMMENT IS A DEFAULT SETTING ##############
options snd-hda-intel model=generic
options snd-intel-dspcfg dsp_driver=1
options snd-hda-intel probe_mask=1
options snd-hda-intel dmic_detect=0

Config: /etc/pulse/default.pa (saved original to: /etc/pulse/default.pa.orig)

#!/usr/bin/pulseaudio -nF
#
# This file is part of PulseAudio.
#
# PulseAudio is free software; you can redistribute it and/or modify it
# under the terms of the GNU Lesser General Public License as published by
# the Free Software Foundation; either version 2 of the License, or
# (at your option) any later version.
#
# PulseAudio is distributed in the hope that it will be useful, but
# WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
# General Public License for more details.
#
# You should have received a copy of the GNU Lesser General Public License
# along with PulseAudio; if not, see <http://www.gnu.org/licenses/>.

# This startup script is used only if PulseAudio is started per-user
# (i.e. not in system mode)

.fail

### Automatically restore the volume of streams and devices
load-module module-device-restore
load-module module-stream-restore
load-module module-card-restore

### Automatically augment property information from .desktop files
### stored in /usr/share/application
load-module module-augment-properties

### Should be after module-*-restore but before module-*-detect
load-module module-switch-on-port-available

### Use hot-plugged devices like Bluetooth or USB automatically (LP: #1702794)
.ifexists module-switch-on-connect.so
load-module module-switch-on-connect
.endif

### Load audio drivers statically
### (it's probably better to not load these drivers manually, but instead
### use module-udev-detect -- see below -- for doing this automatically)
load-module module-alsa-sink
load-module module-alsa-source device=hw:1,0
#load-module module-oss device="/dev/dsp" sink_name=output source_name=input
#load-module module-oss-mmap device="/dev/dsp" sink_name=output source_name=input
#load-module module-null-sink
#load-module module-pipe-sink

### Automatically load driver modules depending on the hardware available
.ifexists module-udev-detect.so
load-module module-udev-detect
.else
### Use the static hardware detection module (for systems that lack udev support)
load-module module-detect
.endif

### Automatically connect sink and source if JACK server is present
.ifexists module-jackdbus-detect.so
.nofail
load-module module-jackdbus-detect channels=2
.fail
.endif

### Automatically load driver modules for Bluetooth hardware
.ifexists module-bluetooth-policy.so
load-module module-bluetooth-policy
.endif

#.ifexists module-bluetooth-discover.so
#load-module module-bluetooth-discover
#.endif

### Load several protocols
.ifexists module-esound-protocol-unix.so
load-module module-esound-protocol-unix
.endif
load-module module-native-protocol-unix

### Network access (may be configured with paprefs, so leave this commented
### here if you plan to use paprefs)
#load-module module-esound-protocol-tcp
#load-module module-native-protocol-tcp
#load-module module-zeroconf-publish

### Load the RTP receiver module (also configured via paprefs, see above)
#load-module module-rtp-recv

### Load the RTP sender module (also configured via paprefs, see above)
#load-module module-null-sink sink_name=rtp format=s16be channels=2 rate=44100 sink_properties="device.description='RTP Multicast Sink'"
#load-module module-rtp-send source=rtp.monitor

### Load additional modules from GSettings. This can be configured with the paprefs tool.
### Please keep in mind that the modules configured by paprefs might conflict with manually
### loaded modules.
.ifexists module-gsettings.so
.nofail
load-module module-gsettings
.fail
.endif

### Automatically restore the default sink/source when changed by the user
### during runtime
### NOTE: This should be loaded as early as possible so that subsequent modules
### that look up the default sink/source get the right value
load-module module-default-device-restore

### Make sure we always have a sink around, even if it is a null sink.
load-module module-always-sink

### Honour intended role device property
load-module module-intended-roles

### Automatically suspend sinks/sources that become idle for too long
load-module module-suspend-on-idle

### If autoexit on idle is enabled we want to make sure we only quit
### when no local session needs us anymore.
.ifexists module-console-kit.so
load-module module-console-kit
.endif
.ifexists module-systemd-login.so
load-module module-systemd-login
.endif

### Enable positioned event sounds
load-module module-position-event-sounds

### Cork music/video streams when a phone stream is active
load-module module-role-cork

### Block audio recording for snap confined packages unless they have
### the "pulseaudio" or "audio-record" interfaces plugged.
.ifexists module-snap-policy.so
load-module module-snap-policy
.endif

### Modules to allow autoloading of filters (such as echo cancellation)
### on demand. module-filter-heuristics tries to determine what filters
### make sense, and module-filter-apply does the heavy-lifting of
### loading modules and rerouting streams.
load-module module-filter-heuristics
load-module module-filter-apply

### Make some devices default
#set-default-sink output
#set-default-source input

### Allow including a default.pa.d directory, which if present, can be used
### for additional configuration snippets.
### Note that those snippet files must have a .pa file extension, not .conf
.nofail
.include /etc/pulse/default.pa.d

Command: sudo dmesg (truncated)

[    0.000000] efi: EFI v2.40 by Apple
[    0.000000] efi: Apple Mac detected, using EFI v1.10 runtime services only
[    0.000000] DMI: Apple Inc. MacBookPro13,2/Mac-66E35819EE2D0D05, BIOS 451.120.7.0.0 03/16/2022
...

Command: inxi -AC --no-host

CPU:
  Info: dual core model: Intel Core i7-6567U bits: 64 type: MT MCP cache:
    L2: 512 KiB
  Speed (MHz): avg: 834 min/max: 400/3600 cores: 1: 712 2: 704 3: 863
    4: 1060
Audio:
  Device-1: Intel Sunrise Point-LP HD Audio driver: snd_hda_intel
  Device-2: Logitech HD Pro Webcam C920 type: USB
    driver: snd-usb-audio,uvcvideo
  Sound Server-1: ALSA v: k5.15.0-58-generic running: yes
  Sound Server-2: PulseAudio v: 15.99.1 running: yes
  Sound Server-3: PipeWire v: 0.3.48 running: yes

Command: aplay -l

**** List of PLAYBACK Hardware Devices ****
card 0: PCH [HDA Intel PCH], device 0: Generic Analog [Generic Analog]
  Subdevices: 1/1
  Subdevice #0: subdevice #0
card 0: PCH [HDA Intel PCH], device 3: Generic Digital [Generic Digital]
  Subdevices: 0/1
  Subdevice #0: subdevice #0

Command: aplay -L

null
    Discard all samples (playback) or generate zero samples (capture)
default
    Playback/recording through the PulseAudio sound server
samplerate
    Rate Converter Plugin Using Samplerate Library
speexrate
    Rate Converter Plugin Using Speex Resampler
jack
    JACK Audio Connection Kit
oss
    Open Sound System
pulse
    PulseAudio Sound Server
upmix
    Plugin for channel upmix (4,6,8)
vdownmix
    Plugin for channel downmix (stereo) with a simple spacialization
hw:CARD=PCH,DEV=0
    HDA Intel PCH, Generic Analog
    Direct hardware device without any conversions
hw:CARD=PCH,DEV=3
    HDA Intel PCH, Generic Digital
    Direct hardware device without any conversions
plughw:CARD=PCH,DEV=0
    HDA Intel PCH, Generic Analog
    Hardware device with all software conversions
plughw:CARD=PCH,DEV=3
    HDA Intel PCH, Generic Digital
    Hardware device with all software conversions
sysdefault:CARD=PCH
    HDA Intel PCH, Generic Analog
    Default Audio Device
front:CARD=PCH,DEV=0
    HDA Intel PCH, Generic Analog
    Front output / input
surround21:CARD=PCH,DEV=0
    HDA Intel PCH, Generic Analog
    2.1 Surround output to Front and Subwoofer speakers
surround40:CARD=PCH,DEV=0
    HDA Intel PCH, Generic Analog
    4.0 Surround output to Front and Rear speakers
surround41:CARD=PCH,DEV=0
    HDA Intel PCH, Generic Analog
    4.1 Surround output to Front, Rear and Subwoofer speakers
surround50:CARD=PCH,DEV=0
    HDA Intel PCH, Generic Analog
    5.0 Surround output to Front, Center and Rear speakers
surround51:CARD=PCH,DEV=0
    HDA Intel PCH, Generic Analog
    5.1 Surround output to Front, Center, Rear and Subwoofer speakers
surround71:CARD=PCH,DEV=0
    HDA Intel PCH, Generic Analog
    7.1 Surround output to Front, Center, Side, Rear and Woofer speakers
hdmi:CARD=PCH,DEV=0
    HDA Intel PCH, Generic Digital
    HDMI Audio Output
dmix:CARD=PCH,DEV=0
    HDA Intel PCH, Generic Analog
    Direct sample mixing device
dmix:CARD=PCH,DEV=3
    HDA Intel PCH, Generic Digital
    Direct sample mixing device
usbstream:CARD=PCH
    HDA Intel PCH
    USB Stream Output
usbstream:CARD=C920
    HD Pro Webcam C920
    USB Stream Output

** Command:** sudo lshw -c multimedia

  *-usb:0
       description: Video
       product: HD Pro Webcam C920
       vendor: Logitech, Inc.
       physical id: 1
       bus info: usb@1:8.1
       logical name: card1
       logical name: /dev/snd/controlC1
       logical name: /dev/snd/pcmC1D0c
       logical name: input15
       logical name: /dev/input/event9
       version: 0.11
       serial: FBC5372F
       capabilities: usb-2.00 usb
       configuration: driver=snd-usb-audio maxpower=500mA speed=480Mbit/s
  *-multimedia
       description: Audio device
       product: Sunrise Point-LP HD Audio
       vendor: Intel Corporation
       physical id: 1f.3
       bus info: pci@0000:00:1f.3
       logical name: card0
       logical name: /dev/snd/controlC0
       logical name: /dev/snd/hwC0D0
       logical name: /dev/snd/hwC0D2
       logical name: /dev/snd/pcmC0D0c
       logical name: /dev/snd/pcmC0D0p
       logical name: /dev/snd/pcmC0D3p
       version: 21
       width: 64 bits
       clock: 33MHz
       capabilities: pm msi bus_master cap_list
       configuration: driver=snd_hda_intel latency=64
       resources: irq:80 memory:82620000-82623fff memory:80000000-8000ffff

Command: hwinfo --sound

21: PCI 1f.3: 0403 Audio device
  [Created at pci.386]
  Unique ID: nS1_.+aEc0GNzkQ9
  SysFS ID: /devices/pci0000:00/0000:00:1f.3
  SysFS BusID: 0000:00:1f.3
  Hardware Class: sound
  Model: "Intel Sunrise Point-LP HD Audio"
  Vendor: pci 0x8086 "Intel Corporation"
  Device: pci 0x9d70 "Sunrise Point-LP HD Audio"
  SubVendor: pci 0x8086 "Intel Corporation"
  SubDevice: pci 0x7270
  Revision: 0x21
  Driver: "snd_hda_intel"
  Driver Modules: "snd_hda_intel"
  Memory Range: 0x82620000-0x82623fff (rw,non-prefetchable)
  Memory Range: 0x80000000-0x8000ffff (rw,non-prefetchable)
  IRQ: 80 (773 events)
  Module Alias: "pci:v00008086d00009D70sv00008086sd00007270bc04sc03i00"
  Driver Info #0:
    Driver Status: snd_hda_intel is active
    Driver Activation Cmd: "modprobe snd_hda_intel"
  Driver Info #1:
    Driver Status: snd_soc_skl is active
    Driver Activation Cmd: "modprobe snd_soc_skl"
  Config Status: cfg=new, avail=yes, need=no, active=unknown

Command: systemctl --failed

  UNIT LOAD ACTIVE SUB DESCRIPTION
0 loaded units listed.

Command: journalctl -k | grep -Ei "ALSA|HDA|sof|HDMI|snd[_-]|sound|hda.codec|hda.intel"

Jan 19 23:35:47 stinger kernel: ACPI: Added _OSI(Linux-Lenovo-NV-HDMI-Audio)
Jan 19 23:35:47 stinger kernel: pps_core: Software ver. 5.3.6 - Copyright 2005-2007 Rodolfo Giometti <giometti@linux.it>
Jan 19 23:35:47 stinger kernel: PCI-DMA: Using software bounce buffering for IO (SWIOTLB)
Jan 19 23:35:47 stinger kernel: software IO TLB: mapped [mem 0x000000006c451000-0x0000000070451000] (64MB)
Jan 19 23:35:48 stinger kernel: snd_hda_intel 0000:00:1f.3: dmic_detect option is deprecated, pass snd-intel-dspcfg.dsp_driver=1 option instead
Jan 19 23:35:48 stinger kernel: snd_hda_intel 0000:00:1f.3: bound 0000:00:02.0 (ops i915_audio_component_bind_ops [i915])
Jan 19 23:35:49 stinger kernel: snd_hda_codec_generic hdaudioC0D0: autoconfig for Generic: line_outs=2 (0x24/0x25/0x0/0x0/0x0) type:speaker
Jan 19 23:35:49 stinger kernel: snd_hda_codec_generic hdaudioC0D0:    speaker_outs=0 (0x0/0x0/0x0/0x0/0x0)
Jan 19 23:35:49 stinger kernel: snd_hda_codec_generic hdaudioC0D0:    hp_outs=1 (0x2c/0x0/0x0/0x0/0x0)
Jan 19 23:35:49 stinger kernel: snd_hda_codec_generic hdaudioC0D0:    mono: mono_out=0x0
Jan 19 23:35:49 stinger kernel: snd_hda_codec_generic hdaudioC0D0:    inputs:
Jan 19 23:35:49 stinger kernel: snd_hda_codec_generic hdaudioC0D0:      Internal Mic=0x44
Jan 19 23:35:49 stinger kernel: snd_hda_codec_generic hdaudioC0D0:      Mic=0x3c
Jan 19 23:35:49 stinger kernel: snd_hda_codec_generic hdaudioC0D2: autoconfig for Generic: line_outs=0 (0x0/0x0/0x0/0x0/0x0) type:line
Jan 19 23:35:49 stinger kernel: snd_hda_codec_generic hdaudioC0D2:    speaker_outs=0 (0x0/0x0/0x0/0x0/0x0)
Jan 19 23:35:49 stinger kernel: snd_hda_codec_generic hdaudioC0D2:    hp_outs=0 (0x0/0x0/0x0/0x0/0x0)
Jan 19 23:35:49 stinger kernel: snd_hda_codec_generic hdaudioC0D2:    mono: mono_out=0x0
Jan 19 23:35:49 stinger kernel: snd_hda_codec_generic hdaudioC0D2:    dig-out=0x3/0x0
Jan 19 23:35:49 stinger kernel: snd_hda_codec_generic hdaudioC0D2:    inputs:
Jan 19 23:35:49 stinger kernel: input: HDA Intel PCH HDMI as /devices/pci0000:00/0000:00:1f.3/sound/card0/input8
Jan 19 23:35:50 stinger kernel: usbcore: registered new interface driver snd-usb-audio
Jan 19 23:36:49 stinger kernel: audit: type=1326 audit(1674189409.500:77): auid=1000 uid=1000 gid=1000 ses=3 subj=snap.snap-store.ubuntu-software pid=3567 comm="snap-store" exe="/snap/snap-store/638/usr/bin/snap-store" sig=0 arch=c000003e syscall=314 compat=0 ip=0x7f957031573d code=0x50000

Command: apt policy timidity-daemon

timidity-daemon:
  Installed: (none)
  Candidate: 2.14.0-8ubuntu1
  Version table:
     2.14.0-8ubuntu1 500
        500 http://us.archive.ubuntu.com/ubuntu jammy/universe amd64 Packages
        500 http://us.archive.ubuntu.com/ubuntu jammy/universe i386 Packages

Command: fwupdmgr get-devices

WARNING: UEFI capsule updates not available or enabled in firmware setup
  See https://github.com/fwupd/fwupd/wiki/PluginFlag:capsules-unsupported for more information.
MacBookPro13,2
│
├─APPLE SSD AP1024J:
│     Device ID:          71b677ca0f1bc2c5b804fa1d59e52064ce589293
│     Summary:            NVM Express solid state drive
│     Current version:    14.17.01
│     Vendor:             Apple Inc. (NVME:0x106B)
│     GUIDs:              825a09e9-de07-5c12-b754-c3f4da26f96f
│                         0253c814-bd51-5c7f-aba7-b49d05c97c05
│                         17cda703-f027-570e-8a43-a532e0ef0751
│                         57b7cd54-8667-5675-9279-9c9485cf60cb
│                         14705b80-6aa6-5d1c-96b9-c1d6a5b17d29
│     Device Flags:       • Internal device
│                         • Updatable
│                         • System requires external power source
│                         • Needs a reboot after installation
│                         • Device is usable for the duration of the update
│
└─Apple Mobile Device (Recovery Mode):
      Device ID:          1f914e619b232dc4da68ec3389b98b20163003a2
      Vendor:             Apple Inc. (USB:0x05AC)
      GUIDs:              a9e7de28-ec6e-5742-b8f3-2fd016e172b3
                          7e2af001-aaea-5820-9cc8-f7ad68684b88
      Device Flags:       • Updatable
                          • Is in bootloader mode
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment