Re: [PATCH 6/7] ARM: dts: Add dts for Raspberry Pi 4 + Cirrus Logic Lochnagar2

From: Richard Fitzgerald
Date: Thu Oct 15 2020 - 07:14:41 EST



On 15/10/2020 11:25, Nicolas Saenz Julienne wrote:
Hi Richard,
your series is very welcome, upstream support for audio codecs on the RPi4 has
always been lackluster.

Could you provide more information on the actual products? Are there custom
made hats for the RPi4 or this wired into a generic development board.

Info on the codecs is available from www.cirrus.com.
The Lochnagar audio development board is not a hat, but it can be wired
over to the RPi GPIO header. It is not specific to the RPi.

On Wed, 2020-10-14 at 15:54 +0100, Richard Fitzgerald wrote:
This is based on the default bcm2711-rpi-4-b.dts.

Note that you could've included bcm2711-rpi-4.dts (as if it was a .dtsi).

Ok, will change.

Configurations are provided for Cirrus Logic codecs CS42L92, CS47L15,
CS47L24, CS47L35, CS47L90 and WM8998.

For each codec there is a sound node and a codec device node and both
default to disabled. Enable the pair for the codec in use.

Signed-off-by: Richard Fitzgerald <rf@xxxxxxxxxxxxxxxxxxxxx>
---

Sadly I don't think creating a new device tree is a good solution here. If we
were to do so for every RPi hat/usage it'd become unmanageable very fast. There
is a way to maintain this in the open nonetheless. I suggest you build a DT
overlay and submit it to https://github.com/raspberrypi/linux, see
'arch/arm/boot/dts/overlays.' The Raspberry Pi engineers have a kernel branch

We want something in mainline so that it can be used by people
developing on mainline and taken as a starting point for configuring
the codecs for other host platforms. The RPi is a convenient platform to
use as the base because it is widely available and low-cost.

that tracks of the latest kernel release, so once you get the rest of patches
sorted out and they are included in a release it'll make sense to do so.

I can't tell for other distros, but opensuse packages overlays, so the effort
will ultimately be useful to users.

Regards,
Nicolas