Merge ~robertliu/+git/kernel-snap:uc22-add-custom-firmware into ~ubuntu-cervinia/+git/kernel-snap:dev-uc22

Proposed by Robert Liu
Status: Merged
Merged at revision: a5f96003ed28e12607c7175f793703e341cf4449
Proposed branch: ~robertliu/+git/kernel-snap:uc22-add-custom-firmware
Merge into: ~ubuntu-cervinia/+git/kernel-snap:dev-uc22
Diff against target: 31 lines (+20/-0)
1 file modified
snap/snapcraft.yaml (+20/-0)
Reviewer Review Type Date Requested Status
Aristo Chen Approve
Ondrej Kubik Pending
Review via email: mp+430756@code.launchpad.net

Description of the change

The kernel snap still needs the custom-firmware part to include additional proprietary firmware.

To post a comment you must log in.
Revision history for this message
Ondrej Kubik (ondrak) wrote :

I think this can be done in in simpler way.
I assume you are remove firmware trimming, in order to preserve things from "firmware-custom" part.
In this case, simply build firmware-custom part after kernel part, then trimming is done before firmware-custom is primed.

Diff would be then:
+ firmware-custom:
+ after:
+ - kernel
+ plugin: nil
+ override-pull: |
+ # allow custom source definition
+ if [ -n "${SNAPDRAGON_KERNEL_SNAP_FIRMWARE:-}" ]; then
+ if [ -d ${SNAPDRAGON_KERNEL_SNAP_FIRMWARE} ]; then
+ cp -r ${SNAPDRAGON_KERNEL_SNAP_FIRMWARE}/* ${SNAPCRAFT_PART_SRC}
+ else
+ git clone --depth 1 ${SNAPDRAGON_KERNEL_SNAP_FIRMWARE} ${SNAPCRAFT_PART_SRC}
+ fi
+ else
+ echo "Missing env SNAPDRAGON_KERNEL_SNAP_FIRMWARE no custom firmware will be included"
+ touch no-snapdragon-kernel-snap-firmware
+ fi
+ override-build: |
+ mkdir -p ${SNAPCRAFT_PART_INSTALL}/firmware/qcom/sa8155p
+ cp -r * ${SNAPCRAFT_PART_INSTALL}/firmware/qcom/sa8155p

Revision history for this message
Robert Liu (robertliu) wrote :
Download full text (4.8 KiB)

Thanks Ondrej,
I updated the snapcraft.yaml and built a version locally. However, the size is much bigger than the previous recipe (199MB vs 167MB). It seems that "trim-firmware" keeps most of linux-firmware.

$ ls prime/firmware/
3com cpia2 ipw2200-bss.fw iwlwifi-Qu-b0-hr-b0-66.ucode mts_gsm.fw regulatory.db.p7s usbduxsigma_firmware.bin
RTL8192E ct2fw-3.2.5.1.bin ipw2200-ibss.fw iwlwifi-Qu-b0-jf-b0-66.ucode mts_mt9234mu.fw rockchip v4l-cx231xx-avcore-01.fw
acenic ctefx.bin ipw2200-sniffer.fw iwlwifi-Qu-c0-hr-b0-66.ucode mts_mt9234zba.fw rp2.fw v4l-cx23418-apu.fw
adaptec ctfw-3.2.5.1.bin iwlwifi-100-5.ucode iwlwifi-QuZ-a0-hr-b0-66.ucode mwl8k rt2561.bin v4l-cx23418-cpu.fw
advansys cxgb3 iwlwifi-1000-5.ucode iwlwifi-QuZ-a0-jf-b0-66.ucode myri10ge_eth_z8e.dat rt2561s.bin v4l-cx23418-dig.fw
agere_ap_fw.bin cxgb4 iwlwifi-105-6.ucode iwlwifi-cc-a0-66.ucode myri10ge_ethp_z8e.dat rt2661.bin v4l-cx2341x-dec.fw
agere_sta_fw.bin dvb-fe-xc4000-1.4.1.fw iwlwifi-135-6.ucode iwlwifi-ty-a0-gf-a0-66.ucode myri10ge_rss_eth_z8e.dat rt2860.bin v4l-cx2341x-enc.fw
amdgpu dvb-fe-xc5000-1.6.114.fw iwlwifi-2000-6.ucode kaweth myri10ge_rss_ethp_z8e.dat rt2870.bin v4l-cx2341x-init.mpg
ar5523.bin dvb-fe-xc5000c-4.1.30.7.fw iwlwifi-2030-6.ucode keyspan netronome rt73.bin v4l-cx23885-avcore-01.fw
ath10k dvb-usb-dib0700-1.20.fw iwlwifi-3160-17.ucode keyspan_pda nvidia rtl_bt v4l-cx25840.fw
ath11k dvb-usb-it9135-01.fw iwlwifi-3168-29.ucode korg phanfw.bin rtl_nic v4l-pvrusb2-24xxx-01.fw
ath3k-1.fw dvb-usb-it9135-02.fw iwlwifi-3945-2.ucode lbtf_usb.bin qcom rtlwifi v4l-pvrusb2-29xxx-01.fw
ath6k e100 iwlwifi-4965-2.ucode lgs8g75.fw qed rtw88 vicam
ath9k_htc ea iwlwifi-5000-5.ucode libertas ql2100_fw.bin rtw89 vntwusb.fw
atmel edgeport iwlwifi-5150-2.ucode liquidio ql2200_fw.bin slicoss vxge
atmel_at76c504_2958.bin emi26 iwlwifi-6000g2a-6.ucode mediatek ...

Read more...

Revision history for this message
Aristo Chen (aristochen) wrote :

LGTM

review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1diff --git a/snap/snapcraft.yaml b/snap/snapcraft.yaml
2index 559028d..86e2b83 100644
3--- a/snap/snapcraft.yaml
4+++ b/snap/snapcraft.yaml
5@@ -89,6 +89,26 @@ parts:
6 prime:
7 - firmware
8
9+ firmware-custom:
10+ after:
11+ - kernel
12+ plugin: nil
13+ override-pull: |
14+ # allow custom source definition
15+ if [ -n "${SNAPDRAGON_KERNEL_SNAP_FIRMWARE:-}" ]; then
16+ if [ -d ${SNAPDRAGON_KERNEL_SNAP_FIRMWARE} ]; then
17+ cp -r ${SNAPDRAGON_KERNEL_SNAP_FIRMWARE}/* ${SNAPCRAFT_PART_SRC}
18+ else
19+ git clone --depth 1 ${SNAPDRAGON_KERNEL_SNAP_FIRMWARE} ${SNAPCRAFT_PART_SRC}
20+ fi
21+ else
22+ echo "Missing env SNAPDRAGON_KERNEL_SNAP_FIRMWARE no custom firmware will be included"
23+ touch no-snapdragon-kernel-snap-firmware
24+ fi
25+ override-build: |
26+ mkdir -p ${SNAPCRAFT_PART_INSTALL}/firmware/qcom/sa8155p
27+ cp -r * ${SNAPCRAFT_PART_INSTALL}/firmware/qcom/sa8155p
28+
29 signing-test-keys:
30 plugin: dump
31 source: https://git.launchpad.net/~ubuntu-cervinia/+git/cervinia-test-keys

Subscribers

People subscribed via source and target branches

to all changes: