Daniel Leidert: Getting the audio over HDMI to work for the HP N54L microserver running Debian Wheezy and a Sapphire Radeon HD 6450
Conclusion: Sound over HDMI works with the Sapphire Radeon HD 6450 card in my HP N54L microserver. It requires a recent kernel and firmware from Wheezy 7.7 backports and the X.org server. There is no sound without X.org, even if audio has been enabled for the radeon kernel module. Last year I couldn't get audio over HDMI to work after I installed a Sapphire Radeon HD 6450 1 GB (
11190-02-20g) card into my N54L microserver. The cable that connects the HDMI interfaces between the card and the TV monitor supports HDMI 1.3, so audio should have been possible even then. However, I didn't get any audio output by XBMC playing video or music files. Nothing happened with stock Wheezy 7.1 and X.org/XBMC installed. So I removed the latter two and used the server as stock server without X/desktop and delayed my plans for an HTPC.Now I tried again after I found some new hints, that made me curious for a second try :) Imagine my joy, when (finally) speaker-test produced noise on the TV! So here is my configuration and a step-by-step guide to- enable Sound over HDMI for the Radeon HD 6450
- install a graphical environment
- install XBMC
- automatically start XBMC on boot
# apt-get autoremove --purge pulseaudio pulseaudio-utils pulseaudio-module-x11 gstreamer0.10-pulseaudioNext I installed a recent linux kernel and recent firmware from Wheezy backports:
# apt-get install alsa-base alsa-utils alsa-oss
# apt-get install -t wheezy-backports linux-image-amd64 firmware-linux-free firmware-linux firmware-linux-nonfree firmware-atheros firmware-bnx2 firmware-bnx2xThis put linux-image-3.16-0.bpo.3-amd64 and recent firmware onto my system. I've chosen to upgrade linux-image-amd64 instead to pick a special (recent) linux kernel package from Wheezy backports to keep up-to-date with recent kernels from there.Then I enabled the audio output of the kernel radeon module. Essentially there are at least three ways to do this. I use the one to modify /etc/modules.d/radeon.conf and set the audio parameter there. The hw_i2c parameter is disabled. I read, that it might cause trouble with the audio output here although I never personally experienced it:
options radeon audio=1 hw_i2c=0JFTR: This is how I boot the N54L by default:
GRUB_CMDLINE_LINUX_DEFAULT="quiet splash acpi=force pcie_aspm=force nmi_watchdog=0"After rebooting I see this for the Radeon card in question:
At this point, without having the X.org server installed, I still have no audio output to the connected monitor. Running alsamixer I only see the S/PDIF bar for the HDA ATI HDMI device, showing a value of
# lsmod egrep snd\ radeon\ drm awk ' print $1 ' sort
[..]
drm
drm_kms_helper
i2c_algo_bit
i2c_core
radeon
snd
snd_hda_codec
snd_hda_codec_hdmi
snd_hda_controller
snd_hda_intel
snd_hwdep
snd_pcm
snd_seq
snd_seq_device
snd_timer
soundcore
ttm
[..]
# lspci -k
[..]
01:00.0 VGA compatible controller: Advanced Micro Devices, Inc. [AMD/ATI] Caicos [Radeon HD 6450/7450/8450 / R5 230 OEM]
Subsystem: PC Partner Limited / Sapphire Technology Device e204
Kernel driver in use: radeon
01:00.1 Audio device: Advanced Micro Devices, Inc. [AMD/ATI] Caicos HDMI Audio [Radeon HD 6400 Series]
Subsystem: PC Partner Limited / Sapphire Technology Radeon HD 6450 1GB DDR3
Kernel driver in use: snd_hda_intel
[..]
# cat /sys/module/radeon/parameters/audio
1
# cat /sys/module/radeon/parameters/hw_i2c
0
# aplay -l
**** List of PLAYBACK Hardware Devices ****
card 0: HDMI [HDA ATI HDMI], device 3: HDMI 0 [HDMI 0]
Subdevices: 0/1
Subdevice #0: subdevice #0
# aplay -L
null
Discard all samples (playback) or generate zero samples (capture)
pulse
PulseAudio Sound Server
hdmi:CARD=HDMI,DEV=0
HDA ATI HDMI, HDMI 0
HDMI Audio Output
00. I can mute and un-mute this device but not change the value. No need to worry, sound comes with step two. Step 2 - Install a graphical environment (X.org server)Next is to install a graphical environment, basically the X.org server. This is done in Debian by the desktop task. Unfortunately tasksel makes use of APT::Install-Recommends="true" and would install a desktop environment and some more recommended packages. At the moment I don't want this, only X. So basically I installed only the task-desktop package with dependencies:
# apt-get install task-desktop xfonts-cyrillicNext is to install a display manager. I've chosen lightdm:
# apt-get install lightdm accountsserviceDone. Now (re-)start the X server. Simply ...
# service lightdm restart... should do. And now there is sound, probably due to the X.org Radeon driver. The following command created noise on the two monitor speakers :)
# speaker-test -c2 -D hdmi:0 -t pinkFinally there is sound over HDMI! Step 3 - Install XBMC To be continued ...
I have recently moved to Lausanne, Switzerland. Broadband Internet
access is not as cheap as in France.
If you re someone who doesn t like Debian s policy of automatically starting
on install (or its heinous cousin, the
It s been pointed out to me that many people aren t aware of the current status of Linux packages on mono-project.com, so I m here s a summary:
Stable packages
Mono 3.10.0, MonoDevelop 5.5.0.227, NuGet 2.8.1 and F# 3.1.1.26 packages are available. Plus related bits. MonoDevelop on Linux does not currently include the F# addin (there are a lot of pieces to get in place for this to work).
These are built for x86-64 CentOS 7, and should be compatible with RHEL 7, openSUSE 12.3, and derivatives. I haven t set up a SUSE 1-click install file yet, but I ll do it next week if someone reminds me.
They are also built for Debian 7 on i386, x86-64, and IBM zSeries processors. The same packages ought to work on Ubuntu 12.04 and above, and any derivatives of Debian or Ubuntu. Due to ABI changes, you need to add a second compatibility extension repository for Ubuntu 12.04 or 12.10 to get anything to work, and a different compatibility extension repository for Debian derivatives with Apache 2.4 if you want the mod-mono ASP.NET Apache module (Debian 8+, Ubuntu 13.10+, and derivatives, will need this).

Some of you may already be aware of the


Like 

There s a lot of discussion / moaning /arguing at this time, so I thought I d post something about how LAVA got into Debian Jessie, the work involved and the lessons I ve learnt. Hopefully, it will help someone avoid the disappointment of having their package missing the migration into a future stable release. This was going to be a talk at the Minidebconf-uk in Cambridge but I decided to put this out as a permanent blog entry in the hope that it will be a useful reference for the future, not just Jessie.
Context
LAVA relies on a number of dependencies which were at the time all this started NEW to Debian as well as many others already in Debian. I d been running LAVA using packages on my own system for a few months before the packages were ready for use on the main servers (I never actually installed LAVA using the old virtualenv method on my own systems, except in a VM). I did do quite a lot of this on my own but I also had a team supporting the effort and valuing the benefits of moving to a packaged system.
At the time, LAVA was based on Ubuntu (12.04 LTS Precise Pangolin) and a new Ubuntu LTS was close (Trusty Tahr 14.04) but I started work on this in 2013. By the time my packages were ready for general usage, it was winter 2013 and much too close to get anything into Ubuntu in time for Trusty. So I started a local repo using space provided by Linaro. At the same time, I started uploading the dependencies to Debian. json-schema-validator, django-testscenarios and others arrived in April and May 2014. (Trusty was released in April). LAVA arrived in NEW in May, being accepted into unstable at the end of June. LAVA arrived in testing for the first time in July 2014.
Upstream development continued apace and a regular monthly upload, with some hotfixes in between, continued until close to the freeze.
At this point, note that although upstream is a medium sized team, the Debian packaging also has a team but all the uploads were made by me. I planned ahead. I knew that I would be going to Macau for Linaro Connect in February a critical stage in the finalisation of the packages and the migration of existing instances from the old methods. I knew that I would be on vacation from August through to the end of September 2014 including at least two weeks with absolutely no connectivity of any kind.
Right at this time, Django1.7 arrived in experimental with the intent to go into unstable and hence into Jessie. This was a headache for me, I initially sought to delay the migration until after Jessie. However, we discussed it upstream, allocated time within the busy schedule and also sought help from within Debian with the RFH tag. Rapha l Hertzog contributed patches for django1.7 support and we worked on those patches upstream, once I was back from vacation. (The final week of my vacation was a work conference, so we had everyone together at one hacking table.)
Still there was more to do, the django1.7 patches allowed the unit tests to complete but broke other parts of the lava-server package and needed subsequent tweaks and fixes.
Even with all this, the auto-removal from testing for packages affected by RC bugs in their dependencies became very important to monitor (it still is). It would be useful if some packages had less complex dependency chains (I m looking at you, uwsgi) as the auto-removal also covers build-depends. This led to some more headaches with libmatheval. I m not good with functional programming languages, I did have some exposure to Scheme when working on Gnucash upstream but it wasn t pleasant. The thought of fixing a scheme problem in the test suite of libmatheval was daunting. Again though, asking for help, I found people in the upstream team who wanted to refresh their use of scheme and were able to help out. The fix migrated into testing in October.
Just for added complications, lava-server gained a few RC bugs of it s own during that time too fixed upstream but awkward nonetheless.
Achievement unlocked
So that s how a complex package like lava-server gets into stable. With a lot of help. The main problem with top-level packages like this is the sheer weight of the dependency chain. Something seemingly unrelated (like libmatheval) can seriously derail the migrations. The package doesn t use the matheval support provided by uwsgi. The bug in matheval wasn t in the parts of matheval used by uwsgi. It wasn t in a language I am at all comfortable in fixing but it s my name on the changelog of the NMU. That happened because I asked for help. OK, when django1.7 was scheduled to arrive in Debian unstable and I knew that lava was not ready, I reacted out of fear and anxiety. However, I sought help, help was provided and that help was enough to get upstream to a point where the side-effects of the required changes could be fixed.
Maintaining a top-level package in Debian is becoming more like maintaining a core package in Debian and that is a good thing. When your package has a lot of dependencies, those dependencies become part of the maintenance workload of your package. It doesn t matter if those are install time dependencies, build dependencies or reverse dependencies. It doesn t actually matter if the issues in those packages are in languages you would personally wish to be expunged from the archive. It becomes your problem but not yours alone.
Debian has a lot of flames right now and Enrico encouraged us to look at what else is actually happening in Debian besides those arguments. Well, on top of all this with lava, I also did what I could to help the arm64 port along and I m very happy that this has been accepted into Jessie as an official release architecture. That s a much bigger story than LAVA yet LAVA was and remains instrumental in how arm64 gained the support in the kernel and various upstreams which allowed patches to be accepted and fixes to be incorporated into Debian packages.
So a roll call of helpers who may otherwise not have been recognised via changelogs, in no particular order:
Meet Alfred. Alfred is a Debian user. He has a laptop with Debian and
a desktop environment running on it. Alfred does a lot of impotant
things on his computer: his hobby is to photograph his cat, and also
he works for a non-governmental organisation that investigates and
reports on human rights violations. His job involves a lot of travel
to many parts of the world, and he needs to handle a lot of very
sensitive information. His laptop uses full-disk encryption, and it's
generally speaking very well secured against the various security
threats that are due to his job.
He is worried about losing important data. He's not too worried that
the sensitive information he has will leak if his laptop is stolen,
but it might be impossible to re-create the data if the laptop is
gone. If he interviews a whistleblower for a slave-trading
corporation, and his laptop is stolen after that, it might be
impossible to ever meet with the whistleblower again.
Alfred wants backups of his data. He gets a USB thumb drive, and
plugs it in. The laptop has never seen the drive before, so it asks
Alfred if the drive should be used for backups. Alfred says yes.
The laptop formats the thumb drive, again with full-disk encryption,
and then runs a backup. The backup automatically picks up all the
files from Alfred's home directory, and some system confguration files
that may be necessary as well. (Read: /home and /etc.) Files that are
usually not very precious, such as web browser caches, are
automatically excluded.
Later, when Alfred wants to update the backup, he plugs in the same
drive again. The system recognises the drive, and runs the backup.
While the backup is running, Alfred has an indicator in his desktop
status bar. If Alfred leaves the drive plugged in, and changes
anything in his home directory, that gets immediately backed up to the
backup drive. Until the changes have been backed up, the indicator
stays on Alfred's status bar.
This isn't good enough, however. Alfred needs to carry the USB drive
with him, and if he's mugged, he might lose both the laptop and the
backup drive. Therefore, the system administrator at Alfred's NGO,
Janet, sets up an account on an online backup server, and e-mails
Alfred a configuration file, which Alfred drops into the backup
system's configuration tool.
From then on, whenever Alfred's laptop is online, and can see the
backup server (identified by an SSH host key), any changes Alfred
makes are backed up as soon as possible. For the next interview, as
soon as the interview is finished and Alfred closes the laptop lid to
suspend it, the backup has already finished, both to the online server
and the USB thumb drive.
Alfred is now happy, and no longer fears for the safety of his data.
Janet, however, is still a little worried, because the online backup
server is an attractive target for attacks. She asks Alfred to
configure the backup service on the laptop to encrypt and digitally
sign the backups, and sends the master backup public key with the
request. Janet keeps the corresponding private key in a secure
location.
Alfred goes into the configuration dialog, ticks the right box, and
drops in the server public key. The backup software generates a new
public key for the laptop to use for encrypting the backups, and
Alfred e-mails that to Janet, using PGP encrypted and signed e-mail.
He also puts the laptop backup encryption keys on a couple of USB
thumb drives, which he stores in safe places (in his sock drawer and
coffee jar, but don't tell anyone that).
Alfred's online backups are now encrypted with public keys so that
both Alfred and Janet can decrypt them, but only they can do that. The
backups are digitally signed so that if the server is hacked, the
backups can't be altered without it being detectable.
Some time passes.
Alfred needs to go to speak to the general assembly of the Cat
Conference, about how awesome his cat is. This requires him to travel
to the US, and he's worried that the US authorities will confiscate
his laptop and try to get at his work files that way. He deletes all
his work files, ssh keys, and other files that aren't necessary to
show his cat pictures at the conference.
The conference goes fine, and when Alfred comes back home, he gets the
USB thumb drive that contains his backup encryption key. He plugs it
in, tells the backup configuration software to import it. Alfred can
then open his backups on the online backup server in his file browser,
and can restore back his files by copying them with drag and drop.
However, the next day Alfred's cat, upset at how much he travels, pees
on the laptop. It is ruined. Everything is lost.
Alfred gets a new laptop from Janet, and installs Debian on it. During
installation, Alfred gives the installer the USB backup drive, and the
installer restores all of Alfred's own files, and also restores system
configuration. After a little while, Alfred has a newly installed
laptop with all his usual software and all of his files.
