Also add additional tools and libraries useful/needed for
compiling some of the ./tools in the kernel source.
Signed-off-by: Rolf Neugebauer <rolf.neugebauer@docker.com>
The vmlinux image is the un-stripped kernel image containing
full debug information which is useful for kernel debugging.
Signed-off-by: Rolf Neugebauer <rolf.neugebauer@docker.com>
For local testinf it is useful to store packages under a different
organisation on the hub (or indeed to select a different registry).
This is enabled by making the ORG configurable when calling make.
Signed-off-by: Rolf Neugebauer <rolf.neugebauer@docker.com>
While testing the patches on Windows we found some issues
which commit d0e6020dd2b25f8880 ("hvsock: fix a race in
hvs_stream_dequeue()") (cherry-picked as 0009) attempts to
fix.
Signed-off-by: Rolf Neugebauer <rolf.neugebauer@docker.com>
In order to enable Hyper-V sockets, the CONFIG_HYPERV_VSOCKETS
option must be set. This is different to the older kernel patches.
In order for the Hyper-V socket code to compile, f3dd3f4797652c311df
("vmbus: introduce in-place packet iterator") needed cherry-picking.
Signed-off-by: Rolf Neugebauer <rolf.neugebauer@docker.com>
This add a new version of the Hyper-V socket support based on
https://github.com/dcui/linux/commits/decui/hv_sock/next-20170504
Note, this changes the Linux side API to Hyper-V sockets as the
support is now based on the VMware/virtio socket implementation.
This means that the Address Family and the addressing changes.
Other patches from the 4.10 kernel are no longer needed as they
were already upstream.
The new Hyper-V socket code has not been tested, but the kernel
boots fine on HyperKit and Hyper-V.
Signed-off-by: Rolf Neugebauer <rolf.neugebauer@docker.com>
Note, the bugfix for the memory leak on a missing disk on Hyper-V
has been incorporated into 4.9 and 4.10 so has been removed from
our patch queue.
Signed-off-by: Rolf Neugebauer <rolf.neugebauer@docker.com>
This also adds the cherry-picked commit f1c635b439a5c017 ("scsi: storvsc: Workaround
for virtual DVD SCSI version") from 4.11 for the 4.9 and 4.10 kernels. This commit
fixes a crash/memory leak on Hyper-V when no disk drives are attached and if one
boots of a CD-ROM drive.
Signed-off-by: Rolf Neugebauer <rolf.neugebauer@docker.com>
Building debug kernels (with additional run time checks and debugging)
was broken a few commits back. This adds back support for building debug
kernels.
In addition, it builds and uploads debug kernels for selected kernel
series (4.9.x LTS and latest stable). The tag for these kernels has
a "_dbg" suffix.
Update documentation.
Signed-off-by: Rolf Neugebauer <rolf.neugebauer@docker.com>
- Use a RUN command per artefact created
- Use WORKDIR to avoid "cd /linux" on every RUN command
- Copy all relevant build artefacts to /out
- Only create one additional layer in final stage
- Add System.map to output image
Signed-off-by: Rolf Neugebauer <rolf.neugebauer@docker.com>
Previously we hardcoded `bzImage` which is not used for all
use cases or architectures.
fix#1630
Signed-off-by: Justin Cormack <justin.cormack@docker.com>
- Use multi-stage builds
- Use a single Dockerfile for all kernels
Kernel version and series are passed in as arguments
- Use a separate kernel config per kernel version
These have been copied from kernel_config and ran
through oldconfig to tidy them up
- Rename patch directories
- Refactor the Makefile to use a template
- Allows building of all kernels without arguments to make
- Use git tree hash as the image tag
- Don't build the image if the tag already exists
Signed-off-by: Rolf Neugebauer <rolf.neugebauer@docker.com>
- XFS filesystem support, as we plan to support this
- Quota support, as XFS has good support
- NVMe PCI support
- Per file encryption
- Device Mapper support, with main options
- BTRFS support (as a module, as it slows boot otherwise by several seconds).
Signed-off-by: Justin Cormack <justin.cormack@docker.com>
This was missed when things were renamed.
The intention with this code was (apparently) to provide a (pseudo)unique
hostname in the case where something more specific was not provided (e.g. by
DHCP). Make this a little clearer by using '(none)' rather than 'linuxkit' as
the default, in the normal case this will be overwritten by something more
specific and if it isn't we will change it to something somewhat unique derived
from the MAC address (as before). nb: '(none)' is already used by Debian so I
think it is a safe choice as the sentinel value.
The use of both CONFIG_DEFAULT_HOSTNAME and the explicit /etc/hostname from
mkimage.sh is likely to be redundant in some cases, but neither seems to
completely cover all cases so keep both.
Signed-off-by: Ian Campbell <ian.campbell@docker.com>
This is the default NIC provided by virt-install, I think it is also pretty
common on other virtualisation platforms since both the drivers and the
emulation are pretty widespread (IIRC Xen HVM guests used to get this by
default, and may still do).
Personally I'd probably try and remember to switch to virtio (or even e1000) in
preference, but that's one more thing to do.
Bump the image number.
Signed-off-by: Ian Campbell <ian.campbell@docker.com>
... and accept the defaults. Doing so enables some hw monitoring on Intel
(which enables some I2C thing) and explicitly disables a few Mellanox options.
Signed-off-by: Ian Campbell <ian.campbell@docker.com>
On some hv_sock workloads which quickly open/close many connections
occasionally, channel IDs would get re-used while still having work
pending. This can cause a kernel crash on a NULL pointer exception.
The three patches added to the 4.9.x and 4.10.x kernels fixes
these bugs. The patches are being prepared to be upstreamed, but for
now we cherry-picked them from the developers tree.
Signed-off-by: Rolf Neugebauer <rolf.neugebauer@docker.com>
The 4.9.19/4.10.7 kernels include the fix for the VMBus
memory leak, so we don't need to carry these patches anymore.
The patches against 4.9.x/4.10.x now also all have added a
"Origin" line pointing to the git tree the patches were cherry
picked from.
Signed-off-by: Rolf Neugebauer <rolf.neugebauer@docker.com>
This adds a timestamp to the start of the kernel command line. Like this (from
a random system I have lying around, line truncated by me):
[ 0.000000] tsc: Detected 2665.038 MHz processor
[ 0.000021] Calibrating delay loop (skipped), value calculated using tim...
[ 0.000023] pid_max: default: 32768 minimum: 301
[ 0.000041] ACPI: Core revision 20160831
[ 0.003782] ACPI: 2 ACPI AML tables successfully acquired and loaded
This would be handy in relation to #1403.
Signed-off-by: Ian Campbell <ian.campbell@docker.com>
For 4.9.18 and 4.10.6 cherry-picked the VMBus leak fix
from Linus' tree instead of char-misc.
Signed-off-by: Rolf Neugebauer <rolf.neugebauer@docker.com>
Unused. This should not affect anything, and I didnt actually bump
the kernel version; am working on te build in CI for this...
Signed-off-by: Justin Cormack <justin.cormack@docker.com>
Note, this also removes the LTS4.4 build options and replaces
it with a KERNEL= build option to select the kernel to build.
Signed-off-by: Rolf Neugebauer <rolf.neugebauer@docker.com>