blob: 34d2b676557c95e27f45c6d7085fed1474d07849 [file] [log] [blame]
Brad Bishop316dfdd2018-06-25 12:45:53 -04001# Augments upstream linux-firmware with additional and updated images
2# from Raspbian:
3# https://github.com/RPi-Distro/firmware-nonfree
4# https://github.com/RPi-Distro/bluez-firmware
Brad Bishop3a5fbf52017-12-04 02:17:07 -05005
Brad Bishop316dfdd2018-06-25 12:45:53 -04006LICENSE_append_rpi = "\
7 & Firmware-cypress \
8"
Brad Bishop3a5fbf52017-12-04 02:17:07 -05009
Brad Bishop316dfdd2018-06-25 12:45:53 -040010LIC_FILES_CHKSUM_append_rpi = "\
11 file://LICENCE.cypress;md5=cbc5f665d04f741f1e006d2096236ba7 \
12"
13NO_GENERIC_LICENSE[Firmware-cypress] = "LICENCE.cypress"
Brad Bishop6e60e8b2018-02-01 10:27:11 -050014
Brad Bishop316dfdd2018-06-25 12:45:53 -040015SRC_URI_append_rpi = " \
16 git://github.com/RPi-Distro/firmware-nonfree;destsuffix=raspbian-nf;name=raspbian-nf \
17 git://github.com/RPi-Distro/bluez-firmware;destsuffix=raspbian-bluez;name=raspbian-bluez \
18"
19
20SRCREV_raspbian-nf = "86e88fbf0345da49555d0ec34c80b4fbae7d0cd3"
21SRCREV_raspbian-bluez = "e28cd7ee8615de33aa7ec2b41d556af61a4a2707"
22SRCREV_FORMAT_rpi = "default+raspbian-nf+raspbian-bluez"
23
24do_install_append_rpi() {
25 install -d ${D}${nonarch_base_libdir}/firmware/brcm/
26
27 # Replace outdated linux-firmware files with updated ones from
28 # raspbian firmware-nonfree. Raspbian adds blobs and nvram
29 # definitions that are also necessary so copy those too.
30 for fw in brcmfmac43430-sdio brcmfmac43455-sdio ; do
31 install -m 0644 ${WORKDIR}/raspbian-nf/brcm/${fw}.* ${D}${nonarch_base_libdir}/firmware/brcm/
32 done
33
34 # Add missing Cypress Bluetooth files from raspbian bluez-firmware
35 for fw in BCM43430A1.hcd BCM4345C0.hcd ; do
36 install -m 0644 ${WORKDIR}/raspbian-bluez/broadcom/${fw} ${D}${nonarch_base_libdir}/firmware/brcm/
37 done
Brad Bishop3a5fbf52017-12-04 02:17:07 -050038}
39
Brad Bishop316dfdd2018-06-25 12:45:53 -040040# NB: Must prepend, else these become empty and their content is left in
41# the roll-up package which precedes them.
42PACKAGES_prepend_rpi = "\
43 ${PN}-bcm43455 \
44 ${PN}-cypress-license \
45 ${PN}-bcm43430a1-hcd \
46 ${PN}-bcm4345c0-hcd \
Brad Bishop3a5fbf52017-12-04 02:17:07 -050047"
Brad Bishop316dfdd2018-06-25 12:45:53 -040048
49# For additional Broadcom
50LICENSE_${PN}-bcm43455 = "Firmware-broadcom_bcm43xx"
51
52FILES_${PN}-bcm43430_append_rpi = " \
53 ${nonarch_base_libdir}/firmware/brcm/brcmfmac43430-sdio.txt \
54"
55FILES_${PN}-bcm43455 = " \
56 ${nonarch_base_libdir}/firmware/brcm/brcmfmac43455-sdio.* \
57"
58
59RDEPENDS_${PN}-bcm43455 += "${PN}-broadcom-license"
60
61# For additional Cypress
62FILES_${PN}-cypress-license = "\
63 ${nonarch_base_libdir}/firmware/LICENCE.cypress \
64"
65
66LICENSE_${PN}-bcm43430a1-hcd = "Firmware-cypress"
67LICENSE_${PN}-bcm4345c0-hcd = "Firmware-cypress"
68
69FILES_${PN}-bcm43430a1-hcd = " \
70 ${nonarch_base_libdir}/firmware/brcm/BCM43430A1.hcd \
71"
72FILES_${PN}-bcm4345c0-hcd = " \
73 ${nonarch_base_libdir}/firmware/brcm/BCM4345C0.hcd \
74"
75
76RDEPENDS_${PN}-bcm43430a1-hcd += "${PN}-cypress-license"
77RDEPENDS_${PN}-bcm4345c0-hcd += "${PN}-cypress-license"