Age | Commit message (Collapse) | Author |
|
update-initramfs used to keep track of which initramfs images it
created and "owned", to avoid overwriting the output of another
coinstalled initramfs generator. As discussed in #765750, this is no
longer a concern and the state checks have been removed.
Now that I'm confident this hasn't caused a regression, also remove
the state updates and the state directory. After this, there is no
turning back: a downgrade will leave update-initramfs owning nothing.
Signed-off-by: Ben Hutchings <ben@decadent.org.uk>
|
|
The direct invocation of update-initramfs in kernel package maintainer
scripts was removed in:
- Debian linux 2.6.39-1, thus in wheezy
- Ubuntu linux 4.15.0-18.19 (I think), thus in bionic
- kernel-package 12.001, thus in Debian squeeze and Ubuntu lucid
Signed-off-by: Ben Hutchings <ben@decadent.org.uk>
|
|
un-,mkinitramfs: add support for zstd
Closes: #955469
See merge request kernel-team/initramfs-tools!33
|
|
Prevents printf error carry over if wrong console is set
Closes: #960355
See merge request kernel-team/initramfs-tools!30
|
|
When overriding configured compressor, warn the user.
See merge request kernel-team/initramfs-tools!31
|
|
Add support for zstd compression and decompression.
Always use multithreaded compression, as zstd still
generates identical archives.
The zstd cmdline tool is usually able to decompress
gzip, xz, lzma and lz4 so make sure to try the tool
early.
Signed-off-by: Norbert Lange <nolange79@gmail.com>
|
|
|
|
Currently the _log_msg() functions is "void" typed - with no return -,
which in terms of shell means it returns whatever its last command
returns. This function is the basic building block for all error/warning
messages in initramfs-tools.
It was noticed [0] that in case of bad console is provided to kernel on
command-line, printf (and apparently all write()-related functions) returns
error, and so this error is carried over in _log_msg(). Happens that
checkfs() function has a loop that runs forever in this scenario (*if* fsck
is not present in initramfs, and obviously if "quiet" is not provided in the
command-line). The situation is easily reproducible and we can find various
reports dating back some years. The reports usually are of the form
"machine can't boot if wrong console is provided" or slightly different
forms of that, almost always relating serial consoles with boot issues.
This patch proposes a pretty simple fix: return zero on _log_msg().
We should definitely not brake the boot due to error log functions;
one could argue we could fix checkfs() and that's true, until eventually
we find another subtle corner case of "misuse" of the _log_msg() return
value (after some debugging), and fix that too, and so on...
W could also argue that printf shouldn't return error in this case,
and although a valid discussion, it's not worth to have users waiting
on a dilemma while boot is quite easy to brake, just by passing a wrong
kernel parameter (or having the underlying serial console device changed
to output to a different port than the previously set on kernel cmdline).
[0] bugs.launchpad.net/cloud-images/+bug/1573095/comments/46
Signed-off-by: Guilherme G. Piccoli <gpiccoli@canonical.com>
|
|
The Pinebook LCD disply does not show output until after the initramfs
is loaded, which is too late to enter an encryption passphrase or
debug issues with mounting the rootfs.
Fix this by adding modules to "fb": analogix-anx6345, pwm-sun4i,
sun4i-drm and sun8i-mixer.
|
|
I'm now using benh@debian.org in debian/changelog, so make these
consistent.
Signed-off-by: Ben Hutchings <ben@decadent.org.uk>
|
|
documentation.debian-projects.org seems to have gone away many
years ago, but web.archive.org has a copy so link to that.
Signed-off-by: Ben Hutchings <ben@decadent.org.uk>
|
|
This requires a heading row, so add one.
Signed-off-by: Ben Hutchings <ben@decadent.org.uk>
|
|
Signed-off-by: Ben Hutchings <ben@decadent.org.uk>
|
|
This is a short document and there is no need to break it up this
much.
Signed-off-by: Ben Hutchings <ben@decadent.org.uk>
|
|
Signed-off-by: Ben Hutchings <ben@decadent.org.uk>
|
|
I like to keep up with the official kernel releases. As a result the
firmware they wind up requiring is newer than what is available in
firmware packages.
I placed the firmware from the git repo in /lib/firmware/updates/
which the kernel searches before /lib/firmware. Kernel can
find them but update-initramfs cannot.
I have attached an initial patch that solves this. I am currently
using the resultng code and it is working fine for me.
The one thing the patch does not do is allow for a custom location
that can be provided to the kernel to search first.
This is because that's a little more complicated and requires a
decision wrt where to specify this location (ie the config file?).
[bwh: Text above is from AP's bug report with minor edits; I added
the subject line.]
Closes: #956663
Signed-off-by: Ben Hutchings <ben@decadent.org.uk>
|
|
These all seem to be harmless in practice, as the parameter values
should not contain metacharacters.
In _checkfs_once() *do not* quote $spinner or $force; if these
are empty then we do not want to add arguments for them. Add a
comment to suppress the warning.
Signed-off-by: Ben Hutchings <ben@decadent.org.uk>
|
|
If we have a generic framebuffer device then there should be no
need to set up any backlight in early boot.
Also, backlight devices are sometimes handled by large drm drivers
like i915 which we don't want to include by default.
Fixes: da8519036860 ("hook-functions: Include modules for Chromebook ...")
Signed-off-by: Ben Hutchings <ben@decadent.org.uk>
|
|
Signed-off-by: Ben Hutchings <ben@decadent.org.uk>
|
|
It was logging the link target, not the name of the symlink.
Signed-off-by: Ben Hutchings <ben@decadent.org.uk>
|
|
pthread_cancel() in libpthread.so.1 depends on functions in
libgcc_s.so.0, but uses dlopen() to link to it rather than having a
static dependency. Handle this dynamic dependency in copy_exec so
that it doesn't have to be handled in every affected hook script.
Closes: #950254
Signed-off-by: Ben Hutchings <ben@decadent.org.uk>
|
|
Signed-off-by: Ben Hutchings <ben@decadent.org.uk>
|
|
Signed-off-by: Ben Hutchings <ben@decadent.org.uk>
|
|
Enable multithreading across all CPUs. Don't change the compression
level as suggested, though. Users who still want faster compression
should choose a different compressor.
Closes: #942144
Signed-off-by: Ben Hutchings <ben@decadent.org.uk>
|
|
This is obsolete since Linux 2.6.28.
Signed-off-by: Ben Hutchings <ben@decadent.org.uk>
|
|
v86d currently maps parts of /dev/mem as executable, even though it
may use an emulator. For now, only mount /dev with the "noexec"
option if it's not present.
Closes: #940171
Signed-off-by: Ben Hutchings <ben@decadent.org.uk>
|
|
"update-initramfs -c -k all" used to re-create initramfs images if
they had been deleted without using "update-initramfs -d", as it used
the state directory to determine which kernel versions should have
them.
Since commit f39625a "update-initramfs: Make "-k all" take over other
initramfs images", it ignores the state directory and is almost
equivalent to "update-initramfs -u -k all".
Change it to operate on all installed kernel versions. This will
ignore which kernel versions suppressed initramfs generation, but
I think it's reasonable to assume users won't use these options
if they have installed such kernels.
Closes: #926401
Signed-off-by: Ben Hutchings <ben@decadent.org.uk>
|
|
This reverts commit 9f7bb9c72b5a50c0fbcd5f501072d3ff5aab91c4. All the
keyword=value forms for block device naming are now handled in
resolve_device.
Related-to: #944777
Signed-off-by: Ben Hutchings <ben@decadent.org.uk>
|
|
modinfo now prints an error message if modules.builtin.bin (created
by depmod) is missing. Copy it in early if it's present.
Closes: #948257
Signed-off-by: Ben Hutchings <ben@decadent.org.uk>
|
|
This reverts commit 9c823ad2b3284a6bd5cfbdfdd699d3e033cadd3f. It did
not solve the problem it was intended to, because it used "$DESTDIR"
in the destination argument to copy_exec and would therefore copy to
/var/tmp/<something> inside the initramfs.
Signed-off-by: Ben Hutchings <ben@decadent.org.uk>
|
|
Executables should always be installed into the initramfs with
copy_exec.
Signed-off-by: Ben Hutchings <ben@decadent.org.uk>
|
|
Do not copy SELinux context in mkinitramfs (Closes: #948365)
See merge request kernel-team/initramfs-tools!25
|
|
This is consistent with all the other copies into the initramfs.
Signed-off-by: Ben Hutchings <ben@decadent.org.uk>
|
|
Tighten permissions for /run/initramfs
See merge request kernel-team/initramfs-tools!22
|
|
/run/initramfs contains a log file from fsck of root file system,
which could perhaps contain sensitive information, for example if
/home or /var are also located there and fsck is triggered.
Let's tighten the permissions to 0700.
Signed-off-by: Topi Miettinen <toiwoton@gmail.com>
|
|
Fix some issues reported by lintian
See merge request kernel-team/initramfs-tools!21
|
|
debhelper 12 wants to run dh_installinitramfs, but we don't want this
- in particular, because it makes initramfs-tools-core's maintainer
scripts run update-initramfs.
Signed-off-by: Ben Hutchings <ben@decadent.org.uk>
|
|
Instead use the default one with option 'Z'.
|
|
hook-functions: Add f2fs as base in auto_add_modules
See merge request kernel-team/initramfs-tools!24
|
|
For people wanting to change their filesystem to F2FS or for embedded
devices with eMMC or sdcard, add the f2fs module and its dependency as
base module. Moreover, this adds "crc32" as hidden dependency module for
f2fs.
|
|
This reverts commit da64d1a11ca8680e69d67c192b8d6e60be6411ee, which
was a workaround for the inconsistent choices of interpreter path in
the early days of armhf and the limitations of copy_file at the time.
Now that copy_file automatically replicates symlinks and their
targets, we don't need to do anything special about the dynamic
linker.
An initramfs built for Debian 10 on armhf currently contains:
/lib/arm-linux-gnueabihf/ld-2.28.so regular file
/lib/arm-linux-gnueabihf/ld-linux-armhf.so.3 link to ld-2.28.so
/lib/arm-linux-gnueabihf/ld-linux.so.3 link to /lib/ld-linux-armhf.so.3
/lib/ld-linux-armhf.so.3 regular file
There are two *copies* of the dynamic linker as well as two symlinks
to one or the other of them.
After this commit, the initramfs contains:
/lib/arm-linux-gnueabihf/ld-2.28.so regular file
/lib/arm-linux-gnueabihf/ld-linux-armhf.so.3 link to ld-2.28.so
/lib/ld-linux-armhf.so.3 link to arm-linux-gnueabihf/ld-2.28.so
The /lib/…/ld-linux.so.3 symlink is no longer created, because Debian
armhf binaries all use /lib/ld-linux-armhf.so.3 as the interpreter
path, but it would be created if we ever switched over.
Signed-off-by: Ben Hutchings <ben@decadent.org.uk>
|
|
This reverts commit 879602b218973fc7a5f92874bbaf41ea818fae31. The
arm (OABI little-endian) port was replaced by armel and was last
released in Debian 5.0. The armeb (OABI big-endian) port never made
it into a Debian release and has died off completely.
Signed-off-by: Ben Hutchings <ben@decadent.org.uk>
|
|
Remove the temporary hack introduced by commit ab9130667d42 "init:
Take over handling of rootdelay parameter from udev boot script".
Signed-off-by: Ben Hutchings <ben@decadent.org.uk>
|
|
Fixes lintian: uses-debhelper-compat-file
See https://lintian.debian.org/tags/uses-debhelper-compat-file.html for more details.
|
|
Fixes lintian: package-uses-old-debhelper-compat-version
See https://lintian.debian.org/tags/package-uses-old-debhelper-compat-version.html for more details.
|
|
hook-functions: preloaded libraries should not end up in the initramfs
See merge request kernel-team/initramfs-tools!19
|
|
Closes: #944929
|
|
Don't require build dependency on shellcheck when nocheck profile is enabled
See merge request kernel-team/initramfs-tools!20
|
|
|
|
hook-functions: Handle dw_mmc-rockchip hidden dependency on rockchip-io-domain
See merge request kernel-team/initramfs-tools!18
|