Github messages for voidlinux
 help / color / mirror / Atom feed
* [PR PATCH] sof-firmware: link firmwares for Jasper Lake and Tiger Lake
@ 2021-01-14  9:26 adriangoransson
  2021-01-14 10:26 ` [PR PATCH] [Updated] " adriangoransson
                   ` (16 more replies)
  0 siblings, 17 replies; 18+ messages in thread
From: adriangoransson @ 2021-01-14  9:26 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 1415 bytes --]

There is a new pull request by adriangoransson against master on the void-packages repository

https://github.com/adriangoransson/void-packages master
https://github.com/void-linux/void-packages/pull/27917

sof-firmware: link firmwares for Jasper Lake and Tiger Lake
After hours of trying to find out why SOF (from repo) didn't like my
hardware, I tried installing the archive directly from
github.com/thesofproject/sof-bin/ instead. To my surprise, it worked!

Taking a closer look at the template, I realized that the firmware files
for my system weren't linked, causing the following errors on boot.

```
[   11.829580] sof-audio-pci 0000:00:1f.3: error: request firmware intel/sof/sof-tgl.ri failed err: -2
[   11.829709] sof-audio-pci 0000:00:1f.3: error: failed to load DSP firmware -2
[   11.830177] sof-audio-pci 0000:00:1f.3: error: sof_probe_work failed err: -2
```

This PR **should** fix that, but my xbps-src fu is lacking, so I haven't
actually managed to build the package. I get the following logs, even
though I have wiped the {host,master}dir and did a binary-bootstrap
again. I'll have a closer look at the manual in the weekend.

```
=> Registering new packages to /host/binpkgs
index: skipping `sof-firmware-1.6.1_1' (x86_64), already registered.
index: 1 packages registered.
```

A patch file from https://github.com/void-linux/void-packages/pull/27917.patch is attached

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-master-27917.patch --]
[-- Type: text/x-diff, Size: 1980 bytes --]

From 854e2813058f8024c6c7aee0bbe092471d5d24a9 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Adrian=20G=C3=B6ransson?= <adriangoransson@gmail.com>
Date: Thu, 14 Jan 2021 10:13:40 +0100
Subject: [PATCH] sof-firmware: link firmwares for Jasper Lake and Tiger Lake

After hours of trying to find out why SOF (from repo) didn't like my
hardware, I tried installing the archive directly from
github.com/thesofproject/sof-bin/ instead. To my surprise, it worked!

Taking a closer look at the template, I realized that the firmware files
for my system weren't linked, causing the following errors on boot.

```
[   11.829580] sof-audio-pci 0000:00:1f.3: error: request firmware intel/sof/sof-tgl.ri failed err: -2
[   11.829709] sof-audio-pci 0000:00:1f.3: error: failed to load DSP firmware -2
[   11.830177] sof-audio-pci 0000:00:1f.3: error: sof_probe_work failed err: -2
```

This PR **should** fix that, but my xbps-src fu is lacking, so I haven't
actually managed to build the package. I get the following logs, even
though I have wiped the {host,master}dir and did a binary-bootstrap
again. I'll have a closer look at the manual in the weekend.

```
=> Registering new packages to /host/binpkgs
index: skipping `sof-firmware-1.6.1_1' (x86_64), already registered.
index: 1 packages registered.
```
---
 srcpkgs/sof-firmware/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/sof-firmware/template b/srcpkgs/sof-firmware/template
index cf237de16a6..5be96a7e3ae 100644
--- a/srcpkgs/sof-firmware/template
+++ b/srcpkgs/sof-firmware/template
@@ -26,7 +26,7 @@ do_install() {
 	for arc in {bdw,byt,cht}; do
 		ln -s sof-${arc}-v${version}.ri ${DESTDIR}/usr/${intel_path}/sof/sof-${arc}.ri
 	done
-	for arc in {apl,cnl,icl}; do
+	for arc in {apl,cnl,icl,jsl,tgl}; do
 		ln -s intel-signed/sof-${arc}-v${version}.ri ${DESTDIR}/usr/${intel_path}/sof/sof-${arc}.ri
 	done
 	ln -s intel-signed/sof-apl-v${version}.ri ${DESTDIR}/usr/${intel_path}/sof/sof-glk.ri

^ permalink raw reply	[flat|nested] 18+ messages in thread

* Re: [PR PATCH] [Updated] sof-firmware: link firmwares for Jasper Lake and Tiger Lake
  2021-01-14  9:26 [PR PATCH] sof-firmware: link firmwares for Jasper Lake and Tiger Lake adriangoransson
@ 2021-01-14 10:26 ` adriangoransson
  2021-01-16  3:15 ` [PR REVIEW] " cinerea0
                   ` (15 subsequent siblings)
  16 siblings, 0 replies; 18+ messages in thread
From: adriangoransson @ 2021-01-14 10:26 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 1420 bytes --]

There is an updated pull request by adriangoransson against master on the void-packages repository

https://github.com/adriangoransson/void-packages master
https://github.com/void-linux/void-packages/pull/27917

sof-firmware: link firmwares for Jasper Lake and Tiger Lake
After hours of trying to find out why SOF (from repo) didn't like my
hardware, I tried installing the archive directly from
github.com/thesofproject/sof-bin/ instead. To my surprise, it worked!

Taking a closer look at the template, I realized that the firmware files
for my system weren't linked, causing the following errors on boot.

```
[   11.829580] sof-audio-pci 0000:00:1f.3: error: request firmware intel/sof/sof-tgl.ri failed err: -2
[   11.829709] sof-audio-pci 0000:00:1f.3: error: failed to load DSP firmware -2
[   11.830177] sof-audio-pci 0000:00:1f.3: error: sof_probe_work failed err: -2
```

This PR **should** fix that, but my xbps-src fu is lacking, so I haven't
actually managed to build the package. I get the following logs, even
though I have wiped the {host,master}dir and did a binary-bootstrap
again. I'll have a closer look at the manual in the weekend.

```
=> Registering new packages to /host/binpkgs
index: skipping `sof-firmware-1.6.1_1' (x86_64), already registered.
index: 1 packages registered.
```

A patch file from https://github.com/void-linux/void-packages/pull/27917.patch is attached

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-master-27917.patch --]
[-- Type: text/x-diff, Size: 1748 bytes --]

From 63442d3eff28ed032c444b3b812becf1a3fce7f6 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Adrian=20G=C3=B6ransson?= <adriangoransson@gmail.com>
Date: Thu, 14 Jan 2021 10:13:40 +0100
Subject: [PATCH] sof-firmware: link firmwares for Jasper Lake and Tiger Lake

After hours of trying to find out why SOF (from repo) didn't like my
hardware, I tried installing the archive directly from
github.com/thesofproject/sof-bin/ instead. To my surprise, it worked!

Taking a closer look at the template, I realized that the firmware files
for my system weren't linked, causing the following errors on boot.

```
[   11.829580] sof-audio-pci 0000:00:1f.3: error: request firmware intel/sof/sof-tgl.ri failed err: -2
[   11.829709] sof-audio-pci 0000:00:1f.3: error: failed to load DSP firmware -2
[   11.830177] sof-audio-pci 0000:00:1f.3: error: sof_probe_work failed err: -2
```
---
 srcpkgs/sof-firmware/template | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/srcpkgs/sof-firmware/template b/srcpkgs/sof-firmware/template
index cf237de16a6..f2703d7220d 100644
--- a/srcpkgs/sof-firmware/template
+++ b/srcpkgs/sof-firmware/template
@@ -1,7 +1,7 @@
 # Template file for 'sof-firmware'
 pkgname=sof-firmware
 version=1.6.1
-revision=1
+revision=2
 archs="i686* x86_64*"
 wrksrc="sof-bin-${version}"
 depends="alsa-ucm-conf"
@@ -26,7 +26,7 @@ do_install() {
 	for arc in {bdw,byt,cht}; do
 		ln -s sof-${arc}-v${version}.ri ${DESTDIR}/usr/${intel_path}/sof/sof-${arc}.ri
 	done
-	for arc in {apl,cnl,icl}; do
+	for arc in {apl,cnl,icl,jsl,tgl}; do
 		ln -s intel-signed/sof-${arc}-v${version}.ri ${DESTDIR}/usr/${intel_path}/sof/sof-${arc}.ri
 	done
 	ln -s intel-signed/sof-apl-v${version}.ri ${DESTDIR}/usr/${intel_path}/sof/sof-glk.ri

^ permalink raw reply	[flat|nested] 18+ messages in thread

* Re: [PR REVIEW] sof-firmware: link firmwares for Jasper Lake and Tiger Lake
  2021-01-14  9:26 [PR PATCH] sof-firmware: link firmwares for Jasper Lake and Tiger Lake adriangoransson
  2021-01-14 10:26 ` [PR PATCH] [Updated] " adriangoransson
@ 2021-01-16  3:15 ` cinerea0
  2021-01-16  4:24 ` cinerea0
                   ` (14 subsequent siblings)
  16 siblings, 0 replies; 18+ messages in thread
From: cinerea0 @ 2021-01-16  3:15 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 335 bytes --]

New review comment by cinerea0 on void-packages repository

https://github.com/void-linux/void-packages/pull/27917#discussion_r558794058

Comment:
I couldn't find a "jsl" binary anywhere in the tarball, so it shouldn't be listed here. However, there is an "ehl" binary in the intel-signed folder that should probably be included here.

^ permalink raw reply	[flat|nested] 18+ messages in thread

* Re: sof-firmware: link firmwares for Jasper Lake and Tiger Lake
  2021-01-14  9:26 [PR PATCH] sof-firmware: link firmwares for Jasper Lake and Tiger Lake adriangoransson
  2021-01-14 10:26 ` [PR PATCH] [Updated] " adriangoransson
  2021-01-16  3:15 ` [PR REVIEW] " cinerea0
@ 2021-01-16  4:24 ` cinerea0
  2021-01-16  9:17 ` [PR PATCH] [Updated] " adriangoransson
                   ` (13 subsequent siblings)
  16 siblings, 0 replies; 18+ messages in thread
From: cinerea0 @ 2021-01-16  4:24 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 329 bytes --]

New comment by cinerea0 on void-packages repository

https://github.com/void-linux/void-packages/pull/27917#issuecomment-761372212

Comment:
@adriangoransson Thanks for finding this error! I've made a suggestion above that I think will help this PR better conform to the current state of the firmware binaries being distributed.

^ permalink raw reply	[flat|nested] 18+ messages in thread

* Re: [PR PATCH] [Updated] sof-firmware: link firmwares for Jasper Lake and Tiger Lake
  2021-01-14  9:26 [PR PATCH] sof-firmware: link firmwares for Jasper Lake and Tiger Lake adriangoransson
                   ` (2 preceding siblings ...)
  2021-01-16  4:24 ` cinerea0
@ 2021-01-16  9:17 ` adriangoransson
  2021-01-16  9:17 ` [PR REVIEW] " adriangoransson
                   ` (12 subsequent siblings)
  16 siblings, 0 replies; 18+ messages in thread
From: adriangoransson @ 2021-01-16  9:17 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 1035 bytes --]

There is an updated pull request by adriangoransson against master on the void-packages repository

https://github.com/adriangoransson/void-packages master
https://github.com/void-linux/void-packages/pull/27917

sof-firmware: link firmwares for Jasper Lake and Tiger Lake
After hours of trying to find out why SOF (from repo) didn't like my
hardware, I tried installing the archive directly from
github.com/thesofproject/sof-bin/ instead. To my surprise, it worked!

Taking a closer look at the template, I realized that the firmware files
for my system weren't linked, causing the following errors on boot.

```
[   11.829580] sof-audio-pci 0000:00:1f.3: error: request firmware intel/sof/sof-tgl.ri failed err: -2
[   11.829709] sof-audio-pci 0000:00:1f.3: error: failed to load DSP firmware -2
[   11.830177] sof-audio-pci 0000:00:1f.3: error: sof_probe_work failed err: -2
```

**Note**
I have only tested this on Tiger Lake.

A patch file from https://github.com/void-linux/void-packages/pull/27917.patch is attached

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-master-27917.patch --]
[-- Type: text/x-diff, Size: 1800 bytes --]

From bf60b0d9593938be7b18bc462392420cd8a20c69 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Adrian=20G=C3=B6ransson?= <adriangoransson@gmail.com>
Date: Thu, 14 Jan 2021 10:13:40 +0100
Subject: [PATCH] sof-firmware: link firmwares for Elkhart Lake and Tiger Lake

After hours of trying to find out why SOF (from repo) didn't like my
hardware, I tried installing the archive directly from
github.com/thesofproject/sof-bin/ instead. To my surprise, it worked!

Taking a closer look at the template, I realized that the firmware files
for my system weren't linked, causing the following errors on boot.

```
[   11.829580] sof-audio-pci 0000:00:1f.3: error: request firmware intel/sof/sof-tgl.ri failed err: -2
[   11.829709] sof-audio-pci 0000:00:1f.3: error: failed to load DSP firmware -2
[   11.830177] sof-audio-pci 0000:00:1f.3: error: sof_probe_work failed err: -2
```

**Note**
I have only tested this with Tiger Lake.
---
 srcpkgs/sof-firmware/template | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/srcpkgs/sof-firmware/template b/srcpkgs/sof-firmware/template
index cf237de16a6..3f033e375b3 100644
--- a/srcpkgs/sof-firmware/template
+++ b/srcpkgs/sof-firmware/template
@@ -1,7 +1,7 @@
 # Template file for 'sof-firmware'
 pkgname=sof-firmware
 version=1.6.1
-revision=1
+revision=2
 archs="i686* x86_64*"
 wrksrc="sof-bin-${version}"
 depends="alsa-ucm-conf"
@@ -26,7 +26,7 @@ do_install() {
 	for arc in {bdw,byt,cht}; do
 		ln -s sof-${arc}-v${version}.ri ${DESTDIR}/usr/${intel_path}/sof/sof-${arc}.ri
 	done
-	for arc in {apl,cnl,icl}; do
+	for arc in {apl,cnl,icl,ehl,tgl}; do
 		ln -s intel-signed/sof-${arc}-v${version}.ri ${DESTDIR}/usr/${intel_path}/sof/sof-${arc}.ri
 	done
 	ln -s intel-signed/sof-apl-v${version}.ri ${DESTDIR}/usr/${intel_path}/sof/sof-glk.ri

^ permalink raw reply	[flat|nested] 18+ messages in thread

* Re: [PR REVIEW] sof-firmware: link firmwares for Jasper Lake and Tiger Lake
  2021-01-14  9:26 [PR PATCH] sof-firmware: link firmwares for Jasper Lake and Tiger Lake adriangoransson
                   ` (3 preceding siblings ...)
  2021-01-16  9:17 ` [PR PATCH] [Updated] " adriangoransson
@ 2021-01-16  9:17 ` adriangoransson
  2021-01-20  0:06 ` sof-firmware: link firmwares for Elkhart " ericonr
                   ` (11 subsequent siblings)
  16 siblings, 0 replies; 18+ messages in thread
From: adriangoransson @ 2021-01-16  9:17 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 309 bytes --]

New review comment by adriangoransson on void-packages repository

https://github.com/void-linux/void-packages/pull/27917#discussion_r558830438

Comment:
Huh, strange! I just copied jsl as seen in `go.sh` and didn't get any packaging errors, which is why I didn't verify. I removed jsl and added ehl instead!

^ permalink raw reply	[flat|nested] 18+ messages in thread

* Re: sof-firmware: link firmwares for Elkhart Lake and Tiger Lake
  2021-01-14  9:26 [PR PATCH] sof-firmware: link firmwares for Jasper Lake and Tiger Lake adriangoransson
                   ` (4 preceding siblings ...)
  2021-01-16  9:17 ` [PR REVIEW] " adriangoransson
@ 2021-01-20  0:06 ` ericonr
  2021-01-20  5:50 ` cinerea0
                   ` (10 subsequent siblings)
  16 siblings, 0 replies; 18+ messages in thread
From: ericonr @ 2021-01-20  0:06 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 248 bytes --]

New comment by ericonr on void-packages repository

https://github.com/void-linux/void-packages/pull/27917#issuecomment-763229545

Comment:
Could we use their own scripts so we don't have to always hunt down firmware we forgot to add symlinks for?

^ permalink raw reply	[flat|nested] 18+ messages in thread

* Re: sof-firmware: link firmwares for Elkhart Lake and Tiger Lake
  2021-01-14  9:26 [PR PATCH] sof-firmware: link firmwares for Jasper Lake and Tiger Lake adriangoransson
                   ` (5 preceding siblings ...)
  2021-01-20  0:06 ` sof-firmware: link firmwares for Elkhart " ericonr
@ 2021-01-20  5:50 ` cinerea0
  2021-01-20  9:07 ` adriangoransson
                   ` (9 subsequent siblings)
  16 siblings, 0 replies; 18+ messages in thread
From: cinerea0 @ 2021-01-20  5:50 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 2073 bytes --]

New comment by cinerea0 on void-packages repository

https://github.com/void-linux/void-packages/pull/27917#issuecomment-763352523

Comment:
Good news: I was able to find a way to use their own script to do the installation with only a little bit of patching required; I'll copy my files below. Bad news: I also realized that this package didn't install the firmware tools that come with it, and in my attempt to do so I've run into another problem. The xbps-src error I've encountered is `SONAME: libsof_tplg_parser.so <-> UNKNOWN PKG PLEASE FIX!`. I know this is a problem with `common/shlibs`, but for the life of me I can't figure out where this library comes from.

Changed part of the template:
```shell
do_install() {
	for bin in tools/v${version}/*; do
		vbin ${bin}
	done
	vlicense LICENCE.NXP
	vmkdir usr/lib/firmware/intel
	export ROOT=${DESTDIR}
	export SOF_VERSION=v${version}
	./go.sh
}
```

go.sh.patch:
```patch
--- go.sh	2020-12-18 07:13:44.000000000 -0500
+++ "go (copy).sh"	2021-01-20 00:29:55.823488423 -0500
@@ -11,13 +11,13 @@
 test -n "${ROOT}" ||  \
     ROOT=
 test -n "${INTEL_PATH}" || \
-    INTEL_PATH=lib/firmware/intel
+    INTEL_PATH=usr/lib/firmware/intel
 test -n "${SOF_VERSION}" || \
     SOF_VERSION=$(git symbolic-ref HEAD 2>/dev/null | cut -d"/" -f 3| cut -d"-" -f 2)
 test -n "${SOF_VERSION}" || \
     { echo "Can't work out SOF_VERSION using git, please specify SOF_VERSION as environment variable"; exit 1; }
 
-test -d ${INTEL_PATH}/sof-tplg-${SOF_VERSION} || \
+test -d lib/firmware/intel/sof-tplg-${SOF_VERSION} || \
     { echo "Can't find version ${SOF_VERSION} - are you missing leading v?"; exit 2; }
 
 echo "Installing Intel firmware and topology $SOF_VERSION to $INTEL_PATH"
@@ -28,8 +28,9 @@
 rm -rf ${ROOT}/${INTEL_PATH}/sof-tplg
 
 # copy to destination
-cd lib/firmware
-cp -rf intel ${ROOT}/lib/firmware
+cd lib/firmware/intel
+cp -rf sof ${ROOT}/${INTEL_PATH}
+cp -rf sof-tplg-${SOF_VERSION} ${ROOT}/${INTEL_PATH}
 
 # add symlinks
 cd ${ROOT}/${INTEL_PATH}/sof
```

^ permalink raw reply	[flat|nested] 18+ messages in thread

* Re: sof-firmware: link firmwares for Elkhart Lake and Tiger Lake
  2021-01-14  9:26 [PR PATCH] sof-firmware: link firmwares for Jasper Lake and Tiger Lake adriangoransson
                   ` (6 preceding siblings ...)
  2021-01-20  5:50 ` cinerea0
@ 2021-01-20  9:07 ` adriangoransson
  2021-01-20 15:27 ` ericonr
                   ` (8 subsequent siblings)
  16 siblings, 0 replies; 18+ messages in thread
From: adriangoransson @ 2021-01-20  9:07 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 567 bytes --]

New comment by adriangoransson on void-packages repository

https://github.com/void-linux/void-packages/pull/27917#issuecomment-763453351

Comment:
Great to hear!

For the library, we need to build the original project, no? https://github.com/thesofproject/sof/blob/master/tools/tplg_parser/tplg_parser.c
Maybe it would be easier if the package skipped the distributed binaries and built everything from source? I'm completely new to xbps-src (and packaging as a whole really) so I have no idea how you generally go about doing this, but I would like to learn. :)

^ permalink raw reply	[flat|nested] 18+ messages in thread

* Re: sof-firmware: link firmwares for Elkhart Lake and Tiger Lake
  2021-01-14  9:26 [PR PATCH] sof-firmware: link firmwares for Jasper Lake and Tiger Lake adriangoransson
                   ` (7 preceding siblings ...)
  2021-01-20  9:07 ` adriangoransson
@ 2021-01-20 15:27 ` ericonr
  2021-01-21  0:29 ` cinerea0
                   ` (7 subsequent siblings)
  16 siblings, 0 replies; 18+ messages in thread
From: ericonr @ 2021-01-20 15:27 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 332 bytes --]

New comment by ericonr on void-packages repository

https://github.com/void-linux/void-packages/pull/27917#issuecomment-763709567

Comment:
Building firmware from source is not a good idea :)

@cinerea0 do you think you could try to upstream something to make their patch work for them and for us? Maybe add a `$PREFIX` variable.

^ permalink raw reply	[flat|nested] 18+ messages in thread

* Re: sof-firmware: link firmwares for Elkhart Lake and Tiger Lake
  2021-01-14  9:26 [PR PATCH] sof-firmware: link firmwares for Jasper Lake and Tiger Lake adriangoransson
                   ` (8 preceding siblings ...)
  2021-01-20 15:27 ` ericonr
@ 2021-01-21  0:29 ` cinerea0
  2021-01-21 20:45 ` adriangoransson
                   ` (6 subsequent siblings)
  16 siblings, 0 replies; 18+ messages in thread
From: cinerea0 @ 2021-01-21  0:29 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 762 bytes --]

New comment by cinerea0 on void-packages repository

https://github.com/void-linux/void-packages/pull/27917#issuecomment-764071602

Comment:
After a discussion with someone from the SOF project, and based on what I've read here, I think we should leave the tools out of this package because they're really only going to be used by firmware developers. If it becomes necessary in the future, I'll package the tools by building them from source.

As for the patch I posted earlier, I realized I don't actually need it. The following `do_install` function takes care of installation without the patch:
```shell
do_install() {
	vlicense LICENCE.NXP
	vmkdir usr/lib/firmware/intel
	export ROOT=${DESTDIR}/usr
	export SOF_VERSION=v${version}
	./go.sh
}
```

^ permalink raw reply	[flat|nested] 18+ messages in thread

* Re: sof-firmware: link firmwares for Elkhart Lake and Tiger Lake
  2021-01-14  9:26 [PR PATCH] sof-firmware: link firmwares for Jasper Lake and Tiger Lake adriangoransson
                   ` (9 preceding siblings ...)
  2021-01-21  0:29 ` cinerea0
@ 2021-01-21 20:45 ` adriangoransson
  2021-01-21 20:45 ` adriangoransson
                   ` (5 subsequent siblings)
  16 siblings, 0 replies; 18+ messages in thread
From: adriangoransson @ 2021-01-21 20:45 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 298 bytes --]

New comment by adriangoransson on void-packages repository

https://github.com/void-linux/void-packages/pull/27917#issuecomment-764925712

Comment:
Alright. Glad we can have something working. Should I edit the PR to reflect your changes, @cinerea0, or would you like to push the changes yourself?

^ permalink raw reply	[flat|nested] 18+ messages in thread

* Re: sof-firmware: link firmwares for Elkhart Lake and Tiger Lake
  2021-01-14  9:26 [PR PATCH] sof-firmware: link firmwares for Jasper Lake and Tiger Lake adriangoransson
                   ` (10 preceding siblings ...)
  2021-01-21 20:45 ` adriangoransson
@ 2021-01-21 20:45 ` adriangoransson
  2021-01-21 22:37 ` cinerea0
                   ` (4 subsequent siblings)
  16 siblings, 0 replies; 18+ messages in thread
From: adriangoransson @ 2021-01-21 20:45 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 301 bytes --]

New comment by adriangoransson on void-packages repository

https://github.com/void-linux/void-packages/pull/27917#issuecomment-764925712

Comment:
Alright! :) Glad we can have something working. Should I edit the PR to reflect your changes, @cinerea0, or would you like to push the changes yourself?

^ permalink raw reply	[flat|nested] 18+ messages in thread

* Re: sof-firmware: link firmwares for Elkhart Lake and Tiger Lake
  2021-01-14  9:26 [PR PATCH] sof-firmware: link firmwares for Jasper Lake and Tiger Lake adriangoransson
                   ` (11 preceding siblings ...)
  2021-01-21 20:45 ` adriangoransson
@ 2021-01-21 22:37 ` cinerea0
  2021-01-23 10:51 ` [PR PATCH] [Updated] " adriangoransson
                   ` (3 subsequent siblings)
  16 siblings, 0 replies; 18+ messages in thread
From: cinerea0 @ 2021-01-21 22:37 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 368 bytes --]

New comment by cinerea0 on void-packages repository

https://github.com/void-linux/void-packages/pull/27917#issuecomment-764986189

Comment:
@adriangoransson I think since your PR is already open, it would be best if you edited it to reflect the changes discussed here. Sorry that your first experience with fixing a packaging bug here turned out to be kind of janky!

^ permalink raw reply	[flat|nested] 18+ messages in thread

* Re: [PR PATCH] [Updated] sof-firmware: link firmwares for Elkhart Lake and Tiger Lake
  2021-01-14  9:26 [PR PATCH] sof-firmware: link firmwares for Jasper Lake and Tiger Lake adriangoransson
                   ` (12 preceding siblings ...)
  2021-01-21 22:37 ` cinerea0
@ 2021-01-23 10:51 ` adriangoransson
  2021-01-23 10:55 ` sof-firmware: use provided install script adriangoransson
                   ` (2 subsequent siblings)
  16 siblings, 0 replies; 18+ messages in thread
From: adriangoransson @ 2021-01-23 10:51 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 1036 bytes --]

There is an updated pull request by adriangoransson against master on the void-packages repository

https://github.com/adriangoransson/void-packages master
https://github.com/void-linux/void-packages/pull/27917

sof-firmware: link firmwares for Elkhart Lake and Tiger Lake
After hours of trying to find out why SOF (from repo) didn't like my
hardware, I tried installing the archive directly from
github.com/thesofproject/sof-bin/ instead. To my surprise, it worked!

Taking a closer look at the template, I realized that the firmware files
for my system weren't linked, causing the following errors on boot.

```
[   11.829580] sof-audio-pci 0000:00:1f.3: error: request firmware intel/sof/sof-tgl.ri failed err: -2
[   11.829709] sof-audio-pci 0000:00:1f.3: error: failed to load DSP firmware -2
[   11.830177] sof-audio-pci 0000:00:1f.3: error: sof_probe_work failed err: -2
```

**Note**
I have only tested this on Tiger Lake.

A patch file from https://github.com/void-linux/void-packages/pull/27917.patch is attached

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-master-27917.patch --]
[-- Type: text/x-diff, Size: 2574 bytes --]

From 96ba527470aaebf87d47a61101c0e6954b26af6b Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Adrian=20G=C3=B6ransson?= <adriangoransson@gmail.com>
Date: Thu, 14 Jan 2021 10:13:40 +0100
Subject: [PATCH] sof-firmware: use provided install script

Previous versions of this package manually linked firmware files.
This caused some firmwares to slip by unlinked.

As a consequence, the following errors were encountered on boot
with a Tiger Lake processor.

```
[   11.829580] sof-audio-pci 0000:00:1f.3: error: request firmware intel/sof/sof-tgl.ri failed err: -2
[   11.829709] sof-audio-pci 0000:00:1f.3: error: failed to load DSP firmware -2
[   11.830177] sof-audio-pci 0000:00:1f.3: error: sof_probe_work failed err: -2
```
---
 srcpkgs/sof-firmware/template | 30 +++++++-----------------------
 1 file changed, 7 insertions(+), 23 deletions(-)

diff --git a/srcpkgs/sof-firmware/template b/srcpkgs/sof-firmware/template
index cf237de16a6..544ce9c5893 100644
--- a/srcpkgs/sof-firmware/template
+++ b/srcpkgs/sof-firmware/template
@@ -1,7 +1,7 @@
 # Template file for 'sof-firmware'
 pkgname=sof-firmware
 version=1.6.1
-revision=1
+revision=2
 archs="i686* x86_64*"
 wrksrc="sof-bin-${version}"
 depends="alsa-ucm-conf"
@@ -13,27 +13,11 @@ distfiles="https://github.com/thesofproject/sof-bin/archive/v${version}.tar.gz"
 checksum=587b320030bc84de1aacba5d86d89ba1a4f67201baf8b9b61bb885af60643bfb
 
 do_install() {
-	local intel_path="lib/firmware/intel"
-	for f in ${intel_path}/sof/v${version}/*.{ldc,ri}; do
-		vinstall ${f} 0644 /usr/${intel_path}/sof
-	done
-	for f in ${intel_path}/sof/v${version}/intel-signed/*; do
-		vinstall ${f} 0644 /usr/${intel_path}/sof/intel-signed
-	done
-	for f in ${intel_path}/sof/v${version}/public-signed/*; do
-		vinstall ${f} 0644 /usr/${intel_path}/sof/public-signed
-	done
-	for arc in {bdw,byt,cht}; do
-		ln -s sof-${arc}-v${version}.ri ${DESTDIR}/usr/${intel_path}/sof/sof-${arc}.ri
-	done
-	for arc in {apl,cnl,icl}; do
-		ln -s intel-signed/sof-${arc}-v${version}.ri ${DESTDIR}/usr/${intel_path}/sof/sof-${arc}.ri
-	done
-	ln -s intel-signed/sof-apl-v${version}.ri ${DESTDIR}/usr/${intel_path}/sof/sof-glk.ri
-	ln -s intel-signed/sof-cnl-v${version}.ri ${DESTDIR}/usr/${intel_path}/sof/sof-cfl.ri
-	ln -s intel-signed/sof-cnl-v${version}.ri ${DESTDIR}/usr/${intel_path}/sof/sof-cml.ri
-	for f in ${intel_path}/sof-tplg-v${version}/*; do
-		vinstall ${f} 0644 /usr/${intel_path}/sof-tplg
-	done
 	vlicense LICENCE.NXP
+
+	export ROOT="${DESTDIR}/usr"
+	export SOF_VERSION="v${version}"
+
+	vmkdir usr/lib/firmware/intel
+	./go.sh
 }

^ permalink raw reply	[flat|nested] 18+ messages in thread

* Re: sof-firmware: use provided install script
  2021-01-14  9:26 [PR PATCH] sof-firmware: link firmwares for Jasper Lake and Tiger Lake adriangoransson
                   ` (13 preceding siblings ...)
  2021-01-23 10:51 ` [PR PATCH] [Updated] " adriangoransson
@ 2021-01-23 10:55 ` adriangoransson
  2021-01-26  3:12 ` ericonr
  2021-01-26  3:12 ` [PR PATCH] [Merged]: " ericonr
  16 siblings, 0 replies; 18+ messages in thread
From: adriangoransson @ 2021-01-23 10:55 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 310 bytes --]

New comment by adriangoransson on void-packages repository

https://github.com/void-linux/void-packages/pull/27917#issuecomment-765904943

Comment:
@cinerea0 No worries! I'm glad to help and I'm sure this won't be the last time! :)
Been a bit busy the last couple of days though, hence the delay in response.

^ permalink raw reply	[flat|nested] 18+ messages in thread

* Re: sof-firmware: use provided install script
  2021-01-14  9:26 [PR PATCH] sof-firmware: link firmwares for Jasper Lake and Tiger Lake adriangoransson
                   ` (14 preceding siblings ...)
  2021-01-23 10:55 ` sof-firmware: use provided install script adriangoransson
@ 2021-01-26  3:12 ` ericonr
  2021-01-26  3:12 ` [PR PATCH] [Merged]: " ericonr
  16 siblings, 0 replies; 18+ messages in thread
From: ericonr @ 2021-01-26  3:12 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 153 bytes --]

New comment by ericonr on void-packages repository

https://github.com/void-linux/void-packages/pull/27917#issuecomment-767260104

Comment:
Wonderful :)

^ permalink raw reply	[flat|nested] 18+ messages in thread

* Re: [PR PATCH] [Merged]: sof-firmware: use provided install script
  2021-01-14  9:26 [PR PATCH] sof-firmware: link firmwares for Jasper Lake and Tiger Lake adriangoransson
                   ` (15 preceding siblings ...)
  2021-01-26  3:12 ` ericonr
@ 2021-01-26  3:12 ` ericonr
  16 siblings, 0 replies; 18+ messages in thread
From: ericonr @ 2021-01-26  3:12 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 964 bytes --]

There's a merged pull request on the void-packages repository

sof-firmware: use provided install script
https://github.com/void-linux/void-packages/pull/27917

Description:
**note** this message may be out of date due to commits being squashed. Refer to the latest commit message instad.

After hours of trying to find out why SOF (from repo) didn't like my
hardware, I tried installing the archive directly from
github.com/thesofproject/sof-bin/ instead. To my surprise, it worked!

Taking a closer look at the template, I realized that the firmware files
for my system weren't linked, causing the following errors on boot.

```
[   11.829580] sof-audio-pci 0000:00:1f.3: error: request firmware intel/sof/sof-tgl.ri failed err: -2
[   11.829709] sof-audio-pci 0000:00:1f.3: error: failed to load DSP firmware -2
[   11.830177] sof-audio-pci 0000:00:1f.3: error: sof_probe_work failed err: -2
```

**Note**
I have only tested this on Tiger Lake.

^ permalink raw reply	[flat|nested] 18+ messages in thread

end of thread, other threads:[~2021-01-26  3:12 UTC | newest]

Thread overview: 18+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-01-14  9:26 [PR PATCH] sof-firmware: link firmwares for Jasper Lake and Tiger Lake adriangoransson
2021-01-14 10:26 ` [PR PATCH] [Updated] " adriangoransson
2021-01-16  3:15 ` [PR REVIEW] " cinerea0
2021-01-16  4:24 ` cinerea0
2021-01-16  9:17 ` [PR PATCH] [Updated] " adriangoransson
2021-01-16  9:17 ` [PR REVIEW] " adriangoransson
2021-01-20  0:06 ` sof-firmware: link firmwares for Elkhart " ericonr
2021-01-20  5:50 ` cinerea0
2021-01-20  9:07 ` adriangoransson
2021-01-20 15:27 ` ericonr
2021-01-21  0:29 ` cinerea0
2021-01-21 20:45 ` adriangoransson
2021-01-21 20:45 ` adriangoransson
2021-01-21 22:37 ` cinerea0
2021-01-23 10:51 ` [PR PATCH] [Updated] " adriangoransson
2021-01-23 10:55 ` sof-firmware: use provided install script adriangoransson
2021-01-26  3:12 ` ericonr
2021-01-26  3:12 ` [PR PATCH] [Merged]: " ericonr

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).