linux-firmware: fix the mess of licenses
* LICENSE_CREATE_PACKAGE functionality in license.bbclass when enabled
adds new package with suffix:
LICENSE_PACKAGE_SUFFIX ??= "-lic"
but then it checks if ${PN}-${LICENSE_PACKAGE_SUFFIX} is included
in PACKAGES before adding it and when found it shows:
WARNING: linux-firmware-1_0.0+gitAUTOINC+4c0bf113a5-r0 do_package: linux-firmware-lic package already existed in linux-firmware.
and doesn't add the ${PN}-lic to PACKAGES and causes another warning:
WARNING: linux-firmware-1_0.0+gitAUTOINC+4c0bf113a5-r0 do_package: QA Issue: linux-firmware: Files/directories were installed but not shipped in any package:
/usr
/usr/share
/usr/share/licenses
/usr/share/licenses/linux-firmware
that's because it was searching ${PN}-lic in PACKAGES as a string
so it found ${PN}-lic as a substring of ${PN}-license, add a split
to search in an list
license.bbclass: Minor simplification of get_deployed_dependencies()
Since ${SSTATE_ARCHS} now contains ${PACKAGE_EXTRA_ARCHS} there is no
longer any need to add those extra architectures to the list of
architectures handled in get_deployed_dependencies().
Daniel Díaz [Tue, 14 Aug 2018 14:47:03 +0000 (09:47 -0500)]
multilib_header: recognize BPF as a target
When building with `clang -target bpf` using the
multilib_header, a recursion was unavoidable because
bits/wordsize.h would #include itself, still lacking
a definition for __MHWORDSIZE or __WORDSIZE.
Derek Straka [Tue, 30 Jan 2018 03:04:39 +0000 (22:04 -0500)]
python-native: add dependency for gdbm and db native packages
These two packages are required to ensure the manifest files contain
all of the generated packages. Without this, the db and gdbm packages
will not contain the .so files as they are skipped during the compilation steps
Ross Burton [Mon, 13 Aug 2018 23:59:39 +0000 (00:59 +0100)]
bzip2: use Yocto Project mirror for SRC_URI
The bzip.org domain expired and is now a holding site for adverts, so we can't
trust a tarball that appears on that site (luckily we have source checksums to
detect this).
For now, point SRC_URI at the tarball in the Yocto Project source mirror, but
set HOMEPAGE and UPSTREAM_CHECK_URI to the sourceware.org/bzip2/ page which
apparently will be resurrected as the new canonical home page.
Ross Burton [Mon, 13 Aug 2018 17:20:54 +0000 (18:20 +0100)]
classes: sanity-check LIC_FILES_CHKSUM
We assume that LIC_FILES_CHKSUM is a file: URI but don't actually verify this,
which can lead to problems if you have a URI that resolves to a path of / as
Bitbake will then dutifully checksum / recursively.
module-base.bbclass: fix out-of-tree module builds with custom EXTRA_OEMAKE
Commit d2aa88a6a92985f21414fceea2dc0facbf7f8779 was meant to backport build
dependencies on bc-native and openssl-native, but it also changed execution
of do_make_scripts() from calling make directly to using oe_runmake. That
change was made in master/sumo as part of a separate make-mod-scripts recipe.
Unfortunately, that doesn't work here in rocko in the context of module-base
class, as it gets executed inside out-of-tree module environment. Quite often
those out-of-tree modules provide own Makefile with custom EXTRA_OEMAKE var
defined. But do_make_scripts() gets executed within STAGING_KERNEL_DIR and
cannot simply use custom EXTRA_OEMAKE set by a module.
Move back to calling make and passing HOSTCC/HOSTCPP directly w/o using
EXTRA_OEMAKE.
For more details please see:
http://lists.openembedded.org/pipermail/openembedded-core/2018-August/154189.html
CVE-2017-16612: Fix heap overflows when parsing malicious files
It is possible to trigger heap overflows due to an integer overflow
while parsing images and a signedness issue while parsing comments.
The integer overflow occurs because the chosen limit 0x10000 for
dimensions is too large for 32 bit systems, because each pixel takes 4 bytes.
Properly chosen values allow an overflow which in turn will lead to less
allocated memory than needed for subsequent reads.
The signedness bug is triggered by reading the length of a comment
as unsigned int, but casting it to int when calling the function
XcursorCommentCreate. Turning length into a negative value allows the
check against XCURSOR_COMMENT_MAX_LEN to pass, and the following
addition of sizeof (XcursorComment) + 1 makes it possible to allocate
less memory than needed for subsequent reads.
Chen Qi [Mon, 14 May 2018 08:35:22 +0000 (16:35 +0800)]
devtool/sdk.py: error out in case of downloading file failure
It's possible that downloading file from updateserver fails. In
this case, we should error out instead of continue.
We have users reporting unexpected behavior of 'devtool sdk-update'.
When an invalid url is supplied, e.g., `devtool sdk-update http://invalid',
the program reports 'Note: Already up-to-date'.
This is obviously not expected. We should error out in such case.
Whenever perf got rebuilt, I was consistently getting errors such as
| find: '[...]/perf/1.0-r9/perf-1.0/plugin_mac80211.so': No such file or directory
| find: '[...]/perf/1.0-r9/perf-1.0/plugin_mac80211.so': No such file or directory
| find: find: '[...]/perf/1.0-r9/perf-1.0/libtraceevent.a''[...]/perf/1.0-r9/perf-1.0/libtraceevent.a': No such file or directory: No such file or directory
|
[...]
| find: cannot delete '/mnt/xfs/devel/pil/yocto/tmp-glibc/work/wandboard-oe-linux-gnueabi/perf/1.0-r9/perf-1.0/util/.pstack.o.cmd': No such file or directory
breaking the whole build. The root cause seems to be that the implicit
'make clean' done during do_configure ends up running in parallel, and
thus multiple find commands attempt to stat and/or delete the same
file.
A patch disabling parallelism for the clean target has been ack'ed
upstream (lkml.kernel.org/r/20180705134955.GB3686@krava), but it should
be harmless to pass JOBS=1 even with a fixed kernel. This can be removed
if and when all relevant -stable kernels have that patch.
Ross Burton [Fri, 9 Mar 2018 18:56:10 +0000 (20:56 +0200)]
cryptodev: refresh patches
The patch tool will apply patches by default with "fuzz", which is where if the
hunk context isn't present but what is there is close enough, it will force the
patch in.
Whilst this is useful when there's just whitespace changes, when applied to
source it is possible for a patch applied with fuzz to produce broken code which
still compiles (see #10450). This is obviously bad.
We'd like to eventually have do_patch() rejecting any fuzz on these grounds. For
that to be realistic the existing patches with fuzz need to be rebased and
reviewed.
Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Alexander Kanavin <alexander.kanavin@linux.intel.com> Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> Signed-off-by: Armin Kuster <akuster808@gmail.com>
One of the tarball mirrors is down; the other is blocked by Intel's corporate proxy
for being deemed 'suspicious' (the same problem might pop up in other
companies as well). Let's just take the source from github.
Ross Burton [Wed, 15 Nov 2017 16:47:41 +0000 (16:47 +0000)]
ovmf: refresh patches
The patch tool will apply patches by default with "fuzz", which is where if the
hunk context isn't present but what is there is close enough, it will force the
patch in.
Whilst this is useful when there's just whitespace changes, when applied to
source it is possible for a patch applied with fuzz to produce broken code which
still compiles (see #10450). This is obviously bad.
We'd like to eventually have do_patch() rejecting any fuzz on these grounds. For
that to be realistic the existing patches with fuzz need to be rebased and
reviewed.
Martin Jansa [Thu, 24 May 2018 14:56:01 +0000 (14:56 +0000)]
perf: fix build with kernel older than 4.8
* perf is failing to build for me since this oe-core commit:
commit 9b38c824961fc9dce51bda95c25dac91a69fc64f
Author: Hongxu Jia <hongxu.jia@windriver.com>
Date: Tue Apr 24 11:33:47 2018 +0800
perf: make a copy of kernel source to perf workdir
the problem is that perf sources in kernel older than 4.8 (in my case
4.4) are depending on the "global" include headers outside tools
directory, e.g. swab.h in:
kernel-source/tools$ git grep swab.h
perf/MANIFEST:include/linux/swab.h
perf/MANIFEST:include/uapi/linux/swab.h
perf/util/include/asm/byteorder.h:#include "../../../../include/uapi/linux/swab.h"
this was resolved in 4.8 with:
commit 7e3f36411342a54f1981fa97b43550b8406a3d69
Author: Arnaldo Carvalho de Melo <acme@redhat.com>
Date: Mon Jul 18 17:42:16 2016 -0300
Not used anymore. This also stops include linux/swab.h directly
from the kernel sources, remove that reference from the MANIFEST.
and few more changes to make tools/include more complete and standalone:
tools/include in 4.15:
asm asm-generic linux tools trace uapi
tools/include in 4.4:
asm asm-generic linux tools
but copying the include header even for kernels which don't really
need it doesn't add big overhead, so just copy include to perf sources
for all kernels.
perf: make a copy of kernel source to perf workdir
Since perf contaminates linux shared workdir, it probably caused
kernel-devsrc compile failure at world build.
...
|0 blocks
|cpio: ./tools/perf/arch/arm/util/sedr7ORqk: Cannot stat:
No such file or directory
|0 blocks
...
cpio tried to find a file at ${S}/tools/perf and failed
if the input list is not valid.
Make a copy of kernel shared source directory into a perf workdir
could fix the issue.
Bruce Ashfield [Sat, 28 Jul 2018 08:49:50 +0000 (16:49 +0800)]
make-mod-scripts: add build requirements for external modules
Newer kernels (4.14/v4.15+) have dependencies for the build of
modules (and hence external modules). Without these dependencies
explicitly in the build chain, you can end up with build failures like:
work-shared/qemux86/kernel-source/scripts/extract-cert.c:21:25: fatal
error: openssl/bio.h: No such file or directory
| #include <openssl/bio.h>
| ^
| compilation terminated.
| make[2]: *** [scripts/extract-cert] Error 1
| make[1]: *** [scripts] Error 2
To ensure that these headers are in place, and that the scripts use
our build environment flags, we add a dependency on openssl-native
and use oe_make to invoke the build.
Older kernels have no issues with the extra dependency, so there's no
need to make this conditional.
Signed-off-by: Bruce Ashfield <bruce.ashfield@windriver.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
[Tweaked to have changes in module*.bbclass instead from where
make-mod-scripts was split in sumo] Signed-off-by: Anuj Mittal <anuj.mittal@intel.com> Signed-off-by: Armin Kuster <akuster808@gmail.com>
Kernels which use tools/objtool can now fail when building external modules
due to objtool being missing, the generated files can also cause problems
for kernel-devsrc.
Ensure objtool is generated in make-mod-scripts by also calling
"make prepare".
For devsrc, delete the generated binaries since they'd be native
binaries and unsuitable for the target.
The oeqa kernel module tests also need to have the additional "make prepare"
step added.
Liwei Song [Thu, 1 Feb 2018 06:40:49 +0000 (01:40 -0500)]
linux-firmware: package all ibt-17-x-x.sfi/ddc firmware
All ibt-17-x-x.sfi/ddc firmware are use to support Intel Bluetooth 9560
they are needed in different version of Bluetooth driver since
4.14 kernel version.
commit b77bb7afe513 ("linux-firmware: package ibt-17-16-1 firmware")
only package one of the ibt-17 series firmware.
As the Bluetooth driver's update, to avoid packaging the ibt-17 firmware
one by one, install them in one package ibt-17.
Nicolas Dechesne [Fri, 12 Jan 2018 10:05:07 +0000 (11:05 +0100)]
linux-firmware: add packaging for QCOM firmware for APQ8016 and APQ8096
Firmware files for VPU and GPU found on various Qualcomm based devices, such as
Dragonboard 410c and/or Dragonboard 820c.
* venus-1.8 and adreno-a3xx firmware are VPU and GPU for Qualcomm APQ8016 SoC
* venus-4.2 and adreno-a530 firmware are VPU and GPU for Qualcomm APQ8096 SoC
# Access to certain kernel and userspace facilities
g kmem - - -
-g lock - - -
g tty @TTY_GID@ - -
g utmp - - -
[...]
The upstream documentation doc/UIDS-GIDS.md says that basic.conf.in is "the
precise list of the currently defined groups":
## Special `systemd` GIDs
`systemd` defines no special UIDs beyond what Linux already defines (see
above). However, it does define some special group/GID assignments, which are
primarily used for `systemd-udevd`'s device management. The precise list of the
currently defined groups is found in this `sysusers.d` snippet:
[basic.conf](https://raw.githubusercontent.com/systemd/systemd/master/sysusers.d/basic.conf.in)
It's strongly recommended that downstream distributions include these groups in
their default group databases.
Removing the creation of the group also avoids the need to define a GID
for it when using static ids.
Ross Burton [Fri, 15 Jun 2018 14:43:07 +0000 (15:43 +0100)]
minicom: change SRC_URI to use Debian mirrors
Alioth is dead and the minicom project on Salsa (the replacement for Alioth)
doesn't actually have any files in, so just use the Debian mirror instead.
Ross Burton [Fri, 15 Jun 2018 13:29:31 +0000 (14:29 +0100)]
shadow: update SRC_URI now Alioth is down
Alioth is dead so we can't use it for SRC_URI anymore. There is a shadow
repository on GitHub which is the new upstream, but for some reason it is
missing the 4.2.1 tag and tarball that we use. Also 4.2.1 was never uploaded
into Debian itself, so we can't use their mirror network either.
For now point SRC_URI at the Yocto Project source mirror and set
UPSTREAM_CHECK_URI so that we get nagged to upgrade to 4.6.
Signed-off-by: André Draszik <andre.draszik@jci.com> Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
(cherry picked from commit 77f692ecb39d880b2cb420850a31534860eb2cc5) Signed-off-by: Andre McCurdy <armccurdy@gmail.com> Signed-off-by: Armin Kuster <akuster808@gmail.com>
Anuj Mittal [Sat, 13 Jan 2018 10:02:37 +0000 (18:02 +0800)]
libxml2: fix makefile for ptests
Changes to Makefile in latest version mean when "make -k runtests" is executed,
it leads to errors like:
| make: *** No rule to make target 'runtest.c', needed by 'runtest.o'.
| make: *** No rule to make target 'SAX.c', needed by 'SAX.lo'.
| make: *** No rule to make target 'entities.c', needed by 'entities.lo'.
| make: *** No rule to make target 'encoding.c', needed by 'encoding.lo'.
Make sure that we don't try to check and compile the tests again on the target.
Bruce Ashfield [Fri, 18 May 2018 15:05:53 +0000 (11:05 -0400)]
linux-yoct/4.12: update to v4.12.24
Updating to include Paul Gortmaker's latest round of stable updates, which
comprise the following commits:
dc2f71a08d7a Linux 4.12.24 4cab262afa69 iio: adc: ti-ads1015: add 10% to conversion wait time 89f573e6f136 tools include: Do not use poison with C++ d4f418739d68 kprobes/x86: Disable preemption in ftrace-based jprobes 28861253362b perf test attr: Fix ignored test case result 12c60baac963 staging: fsl-mc/dpio: Fix incorrect comparison 43e1cab01765 serial: imx: Update cached mctrl value when changing RTS 6122e955f082 usbip: tools: Install all headers needed for libusbip development c1fce3e6296c serial: sh-sci: suppress warning for ports without dma channels 444cfc461e20 sysrq : fix Show Regs call trace on ARM 0040e82b1a65 usb: xhci: Return error when host is dead in xhci_disable_slot() e1667a3749da staging: fsl-dpaa2/eth: Account for Rx FD buffers on error path 7e22cbc6bd55 usb: mtu3: fix error return code in ssusb_gadget_init() c528464afcea EDAC, sb_edac: Fix missing break in switch e207a0c6a285 clocksource/drivers/arm_arch_timer: Validate CNTFRQ after enabling frame c3c5783f9303 serial: 8250: Preserve DLD[7:4] for PORT_XR17V35X ca7b446eff2f PCI: dra7xx: Create functional dependency between PCIe and PHY 7897f75fc207 usb: phy: tahvo: fix error handling in tahvo_usb_probe() c240911c41c3 mmc: sdhci-msm: fix issue with power irq 97227123b5f0 mmc: tmio: check mmc_regulator_get_supply return value 05ce425fa841 spi: spi-axi: fix potential use-after-free after deregistration 42f90afc67e4 spi: sh-msiof: Fix DMA transfer size check c652d0d523bf staging: rtl8188eu: avoid a null dereference on pmlmepriv 3dc08560ab63 serial: 8250_fintek: Fix rs485 disablement on invalid ioctl() d57c00699295 m68k: fix ColdFire node shift size calculation df74b0c1e0b4 staging: greybus: loopback: Fix iteration count on async path 96be1d656724 x86/entry/64: Don't use IST entry for #BP stack (part #2) 8e3f9a001776 selftests/x86/ldt_get: Add a few additional tests for limits 0d0517d16bc5 s390/pci: do not require AIS facility 778bf06a0661 PM / Domains: Fix genpd to deal with drivers returning 1 from ->prepare() bd4084ce13d2 s390: vfio-ccw: Do not attempt to free no-op, test and tic cda. fd6fe520a496 ima: fix hash algorithm initialization 83cd72f27843 usb: host: fix incorrect updating of offset 4ab295bc9cdf USB: usbfs: Filter flags passed in from user space d8ce9fecf049 USB: Fix off by one in type-specific length check of BOS SSP capability dc9843bd9e72 USB: core: Add type-specific length check of BOS descriptors ab95f86f0fac usb: xhci: fix panic in xhci_free_virt_devices_depth_first c1b551b8718a xhci: Don't show incorrect WARN message about events for empty rings 8412154c096c USB: ulpi: fix bus-node lookup 10d2d61bff44 usb: hub: Cycle HUB power when initialization fails da44857edd20 powerpc/kprobes: Fix call trace due to incorrect preempt count 67482fcb1f0a powerpc/kprobes: Disable preemption before invoking probe handler for optprobes 6f745a984365 powerpc/jprobes: Disable preemption when triggered through ftrace 3fefceeaca8e USB: serial: usb_debug: add new USB device id 9c971e7d3a9f USB: serial: option: add Quectel BG96 id cc01c484eee9 serial: 8250_pci: Add Amazon PCI serial device ID d16393b7a9d8 usb: quirks: Add no-lpm quirk for KY-688 USB 3.1 Type-C Hub 7a0ac9cc347c uas: Always apply US_FL_NO_ATA_1X quirk to Seagate devices 52c2b20403f0 s390/runtime instrumentation: simplify task exit handling 04dd38b88979 drm/fsl-dcu: enable IRQ before drm_atomic_helper_resume() f363e7cdb4f6 drm/fsl-dcu: avoid disabling pixel clock twice on suspend 2845e7d136c8 drm/i915: Prevent zero length "index" write 79413d6f2f6f drm/i915: Don't try indexed reads to alternate slave addresses f5cc8d6842e6 drm/i915/gvt: Correct ADDR_4K/2M/1G_MASK definition 1fab446c5b5a drm/i915: Fix false-positive assert_rpm_wakelock_held in i915_pmic_bus_access_notifier v2 708262ebbebc md: forbid a RAID5 from having both a bitmap and a journal. 40219fc4a45b e1000e: fix the use of magic numbers for buffer overrun issue 9bbd7fc437e0 include/linux/compiler-clang.h: handle randomizable anonymous structs 13782a203fb8 drm/amd/pp: fix typecast error in powerplay. dd1ab1b7a09e drm/ttm: once more fix ttm_buffer_object_transfer 1e1df0b0eb71 drm/hisilicon: Ensure LDI regs are properly configured. e10ca648a294 drm/panel: simple: Add missing panel_simple_unprepare() calls 28fb6325953c drm/radeon: fix atombios on big endian 0f7ff143e866 drm/tilcdc: Precalculate total frametime in tilcdc_crtc_set_mode() 00debaff36fb drm/amdgpu: Remove check which is not valid for certain VBIOS 53543b5a5062 drm/amdgpu: Properly allocate VM invalidate eng v2 6095ee5e76ed drm/amdgpu: correct reference clock value on vega10 8544b664f20e Revert "drm/radeon: dont switch vt on suspend" 3b28b8cd6364 nvme-pci: add quirk for delay before CHK RDY for WDC SN200 2c1ae94e88ee hwmon: (jc42) optionally try to disable the SMBUS timeout 8fcaaeed325c bcache: recover data from backing when data is clean 027fe49240fa bcache: only permit to recovery read error when cache device is clean 3746f4374ee2 bcache: Fix building error on MIPS 72ea117f664e cxl: Check if vphb exists before iterating over AFU devices 8ee52dd3b01a i2c: i801: Fix Failed to allocate irq -2147483648 error ab7ae0720406 eeprom: at24: check at24_read/write arguments 1025c12d637b eeprom: at24: correctly set the size for at24mac402 32aba2ddc564 eeprom: at24: fix reading from 24MAC402/24MAC602 ec5216d0e845 mmc: core: prepend 0x to OCR entry in sysfs a64429e1d089 mmc: core: prepend 0x to pre_eol_info entry in sysfs 32f6d6221e55 mmc: core: Do not leave the block driver in a suspended state fa455ca7acc6 arm64: module-plts: factor out PLT generation code for ftrace d9c2c353dc61 s390: revert ELF_ET_DYN_BASE base changes 5c10828c07be lockd: lost rollback of set_grace_period() in lockd_down_net() 91ed144855d5 crypto: skcipher - Fix skcipher_walk_aead_common 0ff5af74c047 nfsd: fix panic in posix_unblock_lock called from nfs4_laundromat b187299249a2 nfsd: Fix another OPEN stateid race 2e36e8a92541 nfsd: Fix stateid races between OPEN and CLOSE 237c8c16013d btrfs: clear space cache inode generation always e6eedfd1ca3f mm/hugetlb: fix NULL-pointer dereference on 5-level paging machine b19cd2bae194 autofs: revert "autofs: take more care to not update last_used on path walk" 9c0369beda80 device-dax: implement ->split() to catch invalid munmap attempts 0d73cfed1391 platform/x86: hp-wmi: Fix tablet mode detection for convertibles