Commit Graph

579 Commits (739207021d30676b617472da11feeecef19599ec)

Author SHA1 Message Date
Leah Rowe 739207021d Enable x86 U-Boot payload on every x86 board
Signed-off-by: Leah Rowe <leah@libreboot.org>
2024-11-28 20:31:48 +00:00
Leah Rowe ac5c87681f Add U-Boot x86_64 payload
Currently seems to stall when booted from the GRUB
payload, but works when booted from the SeaBIOS menu.

I also tested it as a standalone payload and it seems
to boot. Will test on hardware next, and start adding
it to more mainboards.

Signed-off-by: Leah Rowe <leah@libreboot.org>
2024-11-28 20:27:10 +00:00
Leah Rowe a70a9813d7 add arm-none-eabi-gcc-cs-c++ to fedora dependency
Signed-off-by: Leah Rowe <leah@libreboot.org>
2024-11-28 20:27:00 +00:00
Leah Rowe 5a641b071d Bump coreboot/next in line with lbmk
This version simply updates the revision, whereas
the corresponding lbmk patch was more invasive:

commit 9abddb82b9228be738382ddc178a9562926404b3
Author: Leah Rowe <leah@libreboot.org>
Date:   Wed Nov 6 22:28:45 2024 +0000

    Bump coreboot/next and merge coreboot/dell7

Canoeboot must be in sync with Libreboot at all times.
Well, the Libreboot patch also merges another tree
that Canoeboot doesn't have, containing the Dell OptiPlex
3050 Micro port, because Canoeboot can't support the
OptiPlek 3050 Micro.

So the Libreboot patch rebased many patches. This one
simply updates the revision.

Signed-off-by: Leah Rowe <leah@libreboot.org>
2024-11-28 20:26:53 +00:00
Leah Rowe 2d2cdd2368 data/coreboot: add missing variable
payload_uboot_i386 must be defined here, or the
build will fail for coreboot targets

Signed-off-by: Leah Rowe <leah@libreboot.org>
2024-11-28 19:55:57 +00:00
Leah Rowe 966fc8c23f Experimental U-Boot payload (32-bit dtb, U-Boot)
NOTE: Support added for xarch target x86_64-elf,
but U-Boot failed to build with this error:

OBJCOPY lib/efi_loader/helloworld.efi
x86_64-elf-objcopy: lib/efi_loader/helloworld_efi.so: invalid bfd target
make[2]: *** [scripts/Makefile.lib:476: lib/efi_loader/helloworld.efi] Error 1

Since I'm building U-Boot for x86_64 *on* an x86-64
host, and since that is currently the recommended type
of machine to use for cbmk development, and since the
other x86 payloads currently don't cross compile anyway,
this is an acceptable compromise for now. This is because
at present, I'm not making U-Boot the primary payload on x86,
instead preferring to chain it from GRUB and SeaBIOS.

The target.cfg file for x86 u-boot shows xarch/xtree commented.
Uncomment these to compile on crossgcc instead of hostcc.

I mention 64-bit because I initially did this first, but decided
to do 32-bit first. I'll work on the 64-bit one next (SPL).

It's only enabled in QEMU for now.

Signed-off-by: Leah Rowe <leah@libreboot.org>
2024-11-28 19:53:23 +00:00
Leah Rowe 9706835dd5 Canoeboot 20241102 release!
Signed-off-by: Leah Rowe <info@minifree.org>
2024-11-02 07:04:10 +00:00
Leah Rowe a7a1534fb1 rebase coreboot/next
same revision, but re-do the patches again.

i wasn't quite as thorough with some of it yesterday.

for example, i included the ifdtool nuke patch yesterday,
which is not actually required in cbmk

Signed-off-by: Leah Rowe <info@minifree.org>
2024-11-01 22:46:30 +00:00
Leah Rowe b1319f5dbb Link e6400 vbt from variant dir.
Since the E6400 was made into a variant for the E4300 dir,
the VBT file is now located in the e6400 variant directory,
instead of the main directory for the port, the latter of
which now accounts for both mainboards.

Signed-off-by: Leah Rowe <info@minifree.org>
2024-11-01 16:22:03 +00:00
Leah Rowe 6f39c7683a coreboot/default: Re-base patches
This is based on the same change recently made in
lbmk. A lot of unnecessary patches, and I want to
clean them all up.

Also, cbmk's /default didn't actually build, whereas
lbmk did, which is the primary motive for this rebase.
With this change, it should build again.

Signed-off-by: Leah Rowe <info@minifree.org>
2024-11-01 16:08:05 +00:00
Leah Rowe 44f5909e43 Canoeboot 20241031 release!
Signed-off-by: Leah Rowe <info@minifree.org>
2024-10-31 22:20:43 +00:00
Leah Rowe 54585c2e75 more irony prevention ready for halloween release
Signed-off-by: Leah Rowe <info@minifree.org>
2024-10-31 19:56:31 +00:00
Leah Rowe 2daddfd118 NEW MAINBOARDS: Dell OptiPlex 780 MT and USFF
Thanks go to Nicholas Chin and Lorenzo Aloe for working on
and testing this code. Based on the 780 MT port.

Signed-off-by: Leah Rowe <leah@libreboot.org>
2024-10-31 19:42:24 +00:00
Leah Rowe 19b4bf16e4 re-update seabios to latest revision
I reset it temporarily back to 1.16.3 when testing the
SeaBIOS hanging bug on 3050 micro, but the revision had
no effect; the bug was caused by a bad coreboot config

Signed-off-by: Leah Rowe <leah@libreboot.org>
2024-10-31 19:30:36 +00:00
Leah Rowe 121f3e304e re-affirm SeaGRUB as the primary payload
GRUB-as-primary was temporarily allowed in lbmk, because of
a temporary SeaBIOS bug on a machine that canoeboot doesn't
actually support yet, namely the 3050 Micro.

This same diff was also applied to lbmk, but lbmk also applied
changes to a coreboot config for the aforementioned mainboard.

Signed-off-by: Leah Rowe <leah@libreboot.org>
2024-10-31 19:29:33 +00:00
Nicholas Chin cee363c6d5 config/coreboot/default: Update MEC5035 patches
- Update the MEC5035 S3 patches to the versions that were sent upstream
  to prevent conflicts with subsequent patches for that EC.
- Update the patch that enables the S3 SMI handler in mainboard code so
  that all Latitudes use the handler.
- Add a new patch that tells the EC to route power button events to the
  host so that the OS can decide what to do. Without it, the EC powers
  off the system without letting the OS cleanly shut down.

Signed-off-by: Nicholas Chin <nic.c3.14@gmail.com>
2024-10-31 19:26:46 +00:00
Leah Rowe 4f08fe2a6e Use SeaBIOS 1.16.3 and enable debugging
This diff matches the setup currently used in coreboot.

Signed-off-by: Leah Rowe <info@minifree.org>
2024-10-31 19:24:45 +00:00
Leah Rowe 3f02e259ca rom.sh: remove unnecessary logic from copyps1bios
the .git directory never exists anyway, when doing a release,
so the purpose this is intended is defeated by lbmk's design.

individual headers say "pcsx-redux team" as copyright anyway,
and the code for generating that COPYING file, with MIT license
and correct years (matching the entire source code for the
open bios) remains correct.

a mitigation instead of this patch might be to maintain a hardcoded
list of authors, and manually update it over time, but this is not
required. however, it may be good practise for upstream to maintain
such a file. perhaps i should contact them?

Signed-off-by: Leah Rowe <leah@libreboot.org>
2024-10-31 19:24:16 +00:00
Leah Rowe 2db674f85e use redundant mirrors for recent utils imports
i mirrored riku's utils int, mxmdump and gpio-scripts
to the codeberg and disroot libreboot sites.

Signed-off-by: Leah Rowe <leah@libreboot.org>
2024-10-31 19:24:08 +00:00
Leah Rowe 41e0bc7db9 remove end slashes on repos in config/git/
Due to quirks in how caching works in lbmk, this may be
error-prone. I'll properly address it in the next audit.

Signed-off-by: Leah Rowe <leah@libreboot.org>
2024-10-31 19:23:56 +00:00
Leah Rowe eb6ec319ed import Riku's int tool
Riku used this for debugging, when adding the MXM support
to the HP EliteBook 8560w port. It will be useful for other
work that I have planned, so I'm archiving this too!

Riku has a lot of useful code, that I meant to import ages ago.
Once I'm done importing these in lbmk, I'll add backup repos.

Signed-off-by: Leah Rowe <leah@libreboot.org>
2024-10-31 19:23:26 +00:00
Leah Rowe c995f2cce9 import Riku's gpio-scripts
Based on hell's code, but parses inteltool logs.

This will be useful for ports that I have planned, so
I'd like this to be included with Libreboot releases.

Signed-off-by: Leah Rowe <leah@libreboot.org>
2024-10-31 19:23:21 +00:00
Leah Rowe 67f986e8cf import Riku's mxmdump utility
Used to dump MXM config for a given mainboard. We used this
for the HP EliteBook 8560w.

I meant to import this via config/git/ ages ago.

Signed-off-by: Leah Rowe <leah@libreboot.org>
2024-10-31 19:23:14 +00:00
Leah Rowe a1aef7108f bump seabios
Signed-off-by: Leah Rowe <leah@libreboot.org>
2024-10-31 19:22:49 +00:00
Leah Rowe 2a4d0ce810 bump flashprog revision to d128a0a
This brings in the following important fix:

commit d128a0ae87086b37c0e5d7a8d934bcdee173402f
Author: Nicholas Chin <nic.c3.14@gmail.com>
Date:   Fri Sep 27 22:57:22 2024 -0600

    flashchips: Remove unsupported erase blocks for Winbond W25X{16,32,64}

    This family of chips does not support the 0x52 (32 KiB block erase) and
    0x60 (chip erase) opcodes according to their datasheet.

The full list of changes this brings in is as follows:

* d128a0a flashchips: Remove unsupported erase blocks for Winbond W25X{16,32,64}
* c6a924a Don't mention writing when erasing only (-E)
* dac4239 ch347_spi: Add 'spimode' parameter
* 56d236b chipset_enable: Add some newer AMD code names
* 3b9f152 chipset_enable: Probe AMD SPIBAR first and bail on ff
* 522160f meson: Add ft4222_spi

Nicholas Chin's patch fixes a bug on GM45 ThinkPads, where WX25
ICs (Winbond) could be read, but writes would fail in certain
cases because flashchips.c provided incorrect block erase commands.

This is unrelated to the --workaround-mx patch, for Macronix ICs.

Signed-off-by: Leah Rowe <leah@libreboot.org>
2024-10-31 19:22:31 +00:00
Leah Rowe f4be26e249 dependencies/fedora40: add python3-devel
I was build-testing gru_bob on an arm64 host, and got a
build error when compiling U-Boot.

Python.h missing - installing python3-devel fixes it.

Signed-off-by: Leah Rowe <leah@libreboot.org>
2024-10-31 19:22:00 +00:00
Leah Rowe 6d2efbcbc3 build: actually build pcsx-redux bios on release
I added support earlier, on rom.sh, but the main build script
specifically defines which projects are to be compiled. I've
modified it so that pcsx-redux (just the BIOS part) will also
be compiled.

Signed-off-by: Leah Rowe <leah@libreboot.org>
2024-10-31 19:21:17 +00:00
Leah Rowe f1ebdb50aa rom.sh: support making pcsx-redux bios release
I also checked the copyright declarations in the
directory src/mips/openbios where the PCSX-Redux BIOS
is, gleaning all the copyright years: 2019-2024 at this
time.

The years will be updated as and when PCSX-Redux is
updated in lbmk. Their BIOS is under MIT so I made lbmk
generate an appropriate COPYING file alongside the binary,
containing:

Copyright (c) 2019-2024 PCSX-Redux authors

Along with the actual text of the MIT license. With all
of this, the PCSX-Redux BIOS can now be included in
Libreboot releases.

No actual tarball is created. The release script in lbmk
simply copies the bin/ directory to ../roms

I'm leaving the PCSX-Redux BIOS release uncompressed,
because, and this will sound patronising because that is
my precise intention: Windows users don't know how to do
anything. If I provide a tarball to Windows users, they
won't know what to do. Libreboot releases always go on rsync
mirrors, which also have HTTP servers with indexing enabled,
for browsing release files.

I mention Windows users, because most people who use the PCSX
Redux BIOS will probably use it on a PlayStation emulator, and
most emulator users are on Windows. I can't really be bothered
to provide it as a .zip archive, and it's only 512kb, so just
provide it uncompressed in Libreboot releases!

Releases were already possible under this scheme, so this
patch really just adds the COPYING file. It's simply a courtesy
to the PCSX-Redux developers, providing proper credit to them.

Signed-off-by: Leah Rowe <leah@libreboot.org>
2024-10-31 19:21:09 +00:00
Leah Rowe b2e41735f3 further irony prevention
most likely not code, or code that has source code, in
these examples, but let's play it cautiously.

Signed-off-by: Leah Rowe <info@minifree.org>
2024-10-29 12:43:35 +00:00
Leah Rowe 2478b53f09 coreboot/default: delete HDCP binary from rk3399
Not needed in our use-case, and probably doesn't have any
source code. Accidentally missed during prior audits.

Signed-off-by: Leah Rowe <info@minifree.org>
2024-10-29 12:28:10 +00:00
Leah Rowe 6e1ab7b624 irony prevention
people were raising a stink about futility test data
in GNU Boot recently, which is proprietary data that
they forgot to delete.

i was already deleting this data since october 2023,
when canoeboot pretty much first started, and they
recently started following suit in their project.

however, i was deleting specific files, found as a
result of intense auditing done in october 2023. to
be more cautious, this patch now simply deletes the
entire directory, so that no test data remains. this
ensures that any future additions upstream will not
be included inadvertently in releases.

not to gloat, but this was never an issue in canoeboot.
again to be clear, this is a preventative fix; titled
"irony prevention", because such a bug in a future
release would indeed be highly ironic.

irony is not allowed.

Signed-off-by: Leah Rowe <info@minifree.org>
2024-10-29 12:13:48 +00:00
Leah Rowe 03f7a7b53a rom.sh: disable seabios-as-primary if grub is main
the way it worked, the roms were still named seagrub
and the seabios rom would be compiled, but with the wrong
path, so seabios wouldn't be executed; seabios would hang
anyway, on this board.

instead, engineer it in such a way as to disable seabios_
images on such setups. also, rename seagrub_ to grub_.

i normally only permit seagrub, and not grub, but i make an
exception for 3050micro because we know grub works, but seabios
currently hangs on this board (which means no bsd).

dell optiplex 3050 micro isn't actually supported in canoeboot,
but the workaround patch for enabling grub as primary payload
was added so that cbmk will maintain parity with lbmk.

Signed-off-by: Leah Rowe <leah@libreboot.org>
2024-10-06 10:42:03 +01:00
Leah Rowe b6036e81d2 coreboot target.cfg: permit GRUB as primary payload
Dell OptiPlex 3050 Micro support was added to Libreboot,
which we can't add in Canoeboot, but SeaBIOS hung on that
board so we made GRUB the primary payload on that board.

SeaGRUB is still enforced on all Canoeboot targets at
present, but we want cbmk to maintain parity with lbmk.

Therefore, import this functionality into cbmk, but without
actually using it.

Add two variable options for target.cfg files:

* seabiosname
* grubname

This string defines where it would be located in CBFS.

Signed-off-by: Leah Rowe <leah@libreboot.org>
2024-10-06 10:39:12 +01:00
Leah Rowe 4c08c390dd git.sh: fix error with cache re-download
in some cases, on a fresh clone, the cached repo already
exists but lbmk tries to download it again. work around
this by checking that the directory exists; it's in the
main if statement, so that the "else" still applies. as
a result, the fallback to a live repo would un-fall back
to doing git-pull if the cached directory exists exists.

if it doesn't seem to make sense, it's because it doesn't.
this whole function needs to be rewritten better.

Signed-off-by: Leah Rowe <leah@libreboot.org>
2024-10-06 10:19:16 +01:00
Leah Rowe 018486d912 add swig to fedora dependencies
needed when compiling u-boot

Signed-off-by: Leah Rowe <leah@libreboot.org>
2024-10-06 10:19:07 +01:00
Nicholas Chin 9a91abd9ef config/coreboot: Add Dell Latitude E4300
Add patches to convert the E6400 port into a GM45 Latitude variant and
add the E4300 as another variant, and create a config for the E4300.
Tested on my E6400 and E4300.

Signed-off-by: Nicholas Chin <nic.c3.14@gmail.com>
2024-10-06 10:17:26 +01:00
Leah Rowe 8cb66ef10e Add Sony PlayStation support to Canoeboot
I also added a "cleanargs" argument, similar to the makeargs
argument, to work around a build error.

This builds the PCSX-Redux PS1 BIOS. They reverse engineered
the Sony PS1 BIOS and wrote a free one under MIT license.

Run this:

./mk -b pcsx-redux

The file will appear: bin/playstation/openbios.bin

Yes. PlayStation support. It's even RYF-friendly:

* Replace BIOS chip with PCSX-Redux's open BIOS
* Install PsNee modchip (libre modchip firmware)
* Install PicoStation (libre optical disc drive emulator)
* Libre SDKs are available e.g. PSn00bSDK

I added this to Libreboot, because I'm working on a fork of
DuckStation. DuckStation recently went proprietary, so I'm making
a fork (soon to be launched) that is based on the libre version,
and I was told of PCSX-Redux's Open BIOS, so I decided to add it
to the *boot projects.

Signed-off-by: Leah Rowe <leah@libreboot.org>
Signed-off-by: Leah Rowe <info@minifree.org>
2024-10-06 09:38:17 +01:00
Leah Rowe 1b6d56e4bf config/git: Import pcsx-redux
We don't need the entire emulator, but we will be using
a specific part: src/mips/openbios

third_party/uC-sdk submodule is included, because it
contains the necessary header files when building open bios.

I will be adding Sony Playstation support to Canoeboot,
alongside a new emulator project to be announced soon.

Yes, RYF playstation is possible. A real playstation can
run this BIOS. Then disable the copy protection from the
CD controller by installing a modchip (PsNee runs free
modchip firmware), and picostation is also libre if you want
something to boot software from SD card instead of CD-R.

Very hackable 90s games console. Libre SDKs also exist that
are quite powerful, so you can actually use this machine while
avoiding all proprietary software of any kind.

Signed-off-by: Leah Rowe <leah@libreboot.org>
2024-10-06 09:36:15 +01:00
Leah Rowe c424795611 remove unused coreboot tree
the coreboot413 tree is only needed for the cbfstool
revision that it has, and only on lbmk. i accidentally
added it, in the recent cbmk revision updates.

Signed-off-by: Leah Rowe <info@minifree.org>
2024-08-15 00:30:07 +01:00
Leah Rowe 1d9f56bdf7 update config/submodule/coreboot
i forgot to update it, when updating coreboot revs based
on lbmk.

Signed-off-by: Leah Rowe <info@minifree.org>
2024-08-14 23:41:25 +01:00
Leah Rowe 01331db17f lib.sh: more verbose error in x_
part of the command was cut off in the output

Signed-off-by: Leah Rowe <info@minifree.org>
2024-08-14 22:15:55 +01:00
Leah Rowe c0ce9121a6 flashprog: bump to 639d563 (2024-08-02)
The workaround-mx patch was rebased on one section in spi.c,
because that part in upstream added QPI support; in the newly
rebase mx patch, the workaround_mx behaviour is only
honoured if QPI (Quad SPI) is not in use.

Quad SPI is not used in practise, on the machines where this
workaround is intended (GM45 ThinkPads with Macronix chips).

This imports the following upstream changes:

* 639d563 README: Update flashprog.org URLs
* cbbd601 README: Update dependency list and Linux package names
* 79451f1 README: Rename "Packaging" -> "Source Packaging"
* 5b4695c README: Dial laptop warning down a little
* 7224085 udev rules: Add some more IDs
* 448457a ch347_spi: Add CH347F ID and loop over the entries
* e39549b ch347_spi: Search for compatible USB interface
* dfd0647 ich_descriptors: Refactor component density handling
* b2ad9fd ich_descriptors: Make use of SPI_ENGINE_PCH100 marker
* 140e22f chipset_enable: Make use of SPI_ENGINE_PCH100 marker
* 869f0e7 ichspi: Use `swseq_data' on ICH7 paths too
* eeee91b ichspi: Replace all switch/case on `ich_generation'
* ecba1d8 ichspi: Drop redundant bail-out cases in ich_set_bbar()
* e8babf4 ichspi: Use a single check to enable hwseq for PCH100+
* fda324b ichspi: Introduce SPI_ENGINE_PCH100 marker
* a1f6476 ichspi: Split ICH7 init out
* 3f75d44 ich_descriptors: Remove `Dual Output Fast Read' for newer gens
* 2862011 spi25: Try to set volatile quad-enable (QE) automatically
* 4ac536b spi25_statusreg: Allow to write (non-)volatile bits specifically
* b1d2bae dediprog: Fix and enable 4BA modes for SF600Plus-G2
* d0afeef dediprog: Disable 4BA modes for SF100 w/ protocol v2
* 1b1deda Implement QPI support
* a1b7f35 dediprog: Implement multi-i/o reads
* 008a44f dediprog: Split read/write command preparation by protocol
* 4760b6e spi25: Implement multi-i/o reads
* 0c9af0a spi25: Check quad-enable (QE) bit
* 930d421 spi25: Introduce generic spi_prepare_io()/spi_finish_io()
* 8d0f465 spi25: Extract 4BA preparations into new `spi25_prepare.c`
* 044c9dc Add FT4222H support
* fc7c13c linux_gpio2_spi: Implement multi i/o
* 5fc3154 bitbang_spi: Implement multi-i/o
* d16a911 bitbang_spi: Move API into its own header file
* 226bb87 flashchips: Add missing QE-bit definitions
* 4fa39c5 flashchips: Fill multi-i/o gaps in MX25U family
* 5f50999 flashchips: Fill multi-i/o gaps in MX25R family
* 46552c8 flashchips: Fill multi-i/o gaps in MX25L family
* 96786d0 flashchips: Fill quad-i/o gaps in XM25Q family
* a26a3c6 flashchips: Fill dual-i/o gaps in W25X family
* 2133f59 flashchips: Fill quad-i/o gaps in W25Q family
* 68573af flashchips: Split GD25Q127C and GD25Q128C
* 4da971f flashchips: Fill quad-i/o gaps in GD25*Q families
* f7e2d97 spi: Allow to define a quad-enable (QE) configuration bit
* 1412d9f spi: Rework FEATURE_QPI
* d518563 spi: Prepare for multi i/o and dummy bytes
* bd72a47 spi25_statusreg: support reading/writing configuration register
* 3d728e7 spi25_statusreg.c: support reading security register
* a358b14 flashchips: Split W25Q64.W -> W25Q64DW | W25Q64FW/W25Q64JW...Q
* 3127db1 manibuilder: Drop legacy flashrom tag collections
* 619d9c0 manibuilder: Use `test_build.sh'
* 6560bba manibuilder/almalinux: Install `diffutils' for new `test_build.sh'
* c7b549e test_build.sh: Compare output for -L of Make and Meson builds
* 72b30a0 test_build.sh: Don't try to run cross-compiled programs
* 3d2f212 test_build.sh: Allow to override Make and Meson commands
* 4eb9748 test_build.sh: Run tests for both Make and Meson builds
* 8279457 manibuilder: Add Alpine Linux 3.18 & 3.19 images
* 15e9b10 manibuilder/alpine: Install libjaylink-dev when available
* b8b3593 manibuilder: Add images for Fedora 38..40
* 7b05f09 manibuilder: Add images for Ubuntu 24.04 "Noble Numbat"
* 5e8b339 manibuilder/anita: Add NetBSD 10.0 i386 & amd64 images
* 61da8c7 manibuilder/anita: Export library path for libusb
* 39152af manibuilder: Set sourcearcade.org as default source
* 20073e7 Properly clear erase-block selection when bigger block is chosen
* 3824c8d ichspi: Allow all opcodes when the "opmenu" isn't locked
* 0d4354e flashchips: Add W25Q32JV-.M

Signed-off-by: Leah Rowe <leah@libreboot.org>
2024-08-14 22:15:49 +01:00
Leah Rowe 4d53d491c2 seabios/default: bump to ec0bc256 (2024-06-24)
This brings in a single change:

commit ec0bc256ae0ea08a32d3e854e329cfbc141f07ad
Author: Gerd Hoffmann <kraxel@redhat.com>
Date:   Mon Jun 24 10:44:09 2024 +0200

    limit address space used for pci devices, part two

This increases compatibility with i686 hosts, when allocating
memory for pci devices.

Signed-off-by: Leah Rowe <leah@libreboot.org>
2024-08-14 22:15:44 +01:00
Leah Rowe 8d6376e61e grub/*: Bump to rev b53ec06a1 (2024-06-17)
Of note: upstream has made several improvements to memory
management, and several fixes to file systems.

User-friendly change to LUKS: if the passphrase input failed,
the user is prompted again for the correct passphrase, instead
of GRUB just failing. Similar to cryptsetup luksOpen behaviour
under Linux.

This pulls in the following changes from upstream (gnu.org):

* b53ec06a1 util/grub-mkrescue: Check existence of option arguments
* ab9fe8030 loader/efi/fdt: Add fdtdump command to access device tree
* 0cfec355d osdep/devmapper/getroot: Unmark 2 strings for translation
* f171122f0 loader/emu/linux: Fix determination of program name
* 828717833 disk/cryptodisk: Fix translatable message
* 9a2134a70 tests: Add test for ZFS zstd
* f96df6fe9 fs/zfs/zfs: Add support for zstd compression
* 55d35d628 kern/efi/mm: Detect calls to grub_efi_drop_alloc() with wrong page counts
* 61f1d0a61 kern/efi/mm: Change grub_efi_allocate_pages_real() to call semantically correct free function
* dc0a3a27d kern/efi/mm: Change grub_efi_mm_add_regions() to keep track of map allocation size
* b990df0be tests/util/grub-fs-tester: Fix EROFS label tests in grub-fs-tester
* d41c64811 tests: Switch to requiring exfatprogs from exfat-utils
* c1ee4da6a tests/util/grub-shell-luks-tester: Fix detached header test getting wrong header path
* c22e052fe tests/util/grub-shell: Add flexibility in QEMU firmware handling
* d2fc9dfcd tests/util/grub-shell: Use pflash instead of -bios to load UEFI firmware
* 88a7e64c2 tests/util/grub-shell: Print gdbinfo if on EFI platform
* b8d29f114 configure: Add Debian/Ubuntu DejaVu font path
* 13b315c0a term/ns8250-spcr: Add one more 16550 debug type
* 8abec8e15 loader/i386/multiboot_mbi: Fix handling of errors in broken aout-kludge
* d35ff2251 net/drivers/ieee1275/ofnet: Remove 200 ms timeout in get_card_packet() to reduce input latency
* 86df79275 commands/efi/tpm: Re-enable measurements on confidential computing platforms
* 0b4d01794 util/grub-mkpasswd-pbkdf2: Simplify the main function implementation
* fa36f6376 kern/ieee1275/init: Add IEEE 1275 Radix support for KVM on Power
* c464f1ec3 fs/zfs/zfs: Mark vdev_zaps_v2 and head_errlog as supported
* 2ffc14ba9 types: Add missing casts in compile-time byteswaps
* c6ac49120 font: Add Fedora-specific font paths
* 5e8989e4e fs/bfs: Fix improper grub_free() on non-existing files
* c806e4dc8 io/gzio: Properly init a table
* 243682baa io/gzio: Abort early when get_byte() reads nothing
* bb65d81fe cli_lock: Add build option to block command line interface
* 56e58828c fs/erofs: Add tests for EROFS in grub-fs-tester
* 9d603061a fs/erofs: Add support for the EROFS
* 1ba39de62 safemath: Add ALIGN_UP_OVF() which checks for an overflow
* d291449ba docs: Fix spelling mistakes
* 6cc2e4481 util/grub.d/00_header.in: Quote background image pathname in output
* f456add5f disk/lvm: GRUB fails to detect LVM volumes due to an incorrect computation of mda_end
* 386b59ddb disk/cryptodisk: Allow user to retry failed passphrase
* 99b4c0c38 disk/mdraid1x_linux: Prevent infinite recursion
* b272ed230 efi: Fix stack protector issues
* 6744840b1 build: Track explicit module dependencies in Makefile.core.def

Signed-off-by: Leah Rowe <leah@libreboot.org>
2024-08-14 22:15:04 +01:00
Leah Rowe 4564c44ebe coreboot/default: bump to 97bc693ab (2024-07-29)
same as the recent update in lbmk, but adapted for cbmk,
e.g. the patches to disable microcode blobs by default.

i copied it from the lbmk update but updated nuke.list
and excluded certain patches not needed in canoeboot, such
as the new dell latitude patches and haswell nri

The coreboot/dell tree was also merged to /default, just
like in lbmk. This puts Canoeboot completely  in sync,
but with deblobbing as is customary for Canoeboot.

Signed-off-by: Leah Rowe <info@minifree.org>
2024-08-14 22:13:28 +01:00
Leah Rowe e4d2c38903 uefitool: Only define ACCESSPERMS on *nix
I re-read the modified code, and it has defines in place
for building on Windows; I was defining ACCESSPERMS
universally, but it should only be defined for non-Windows
systems, which the context in this code means Linux/BSD.

Signed-off-by: Leah Rowe <leah@libreboot.org>
2024-08-14 21:48:53 +01:00
Leah Rowe 1274291628 uefitool: Add patch working around musl libc issue
musl libc is very conservative in what it implements,
preferring a very "pure" libc implementation. this means
that it lacks many of the niceties found in others like
the GNU C Library; the latter implements many BSD libc
extensions, for example.

ACCESSPERMS is a #define in BSD libc that does:
S_IRWXU | S_IRWXG | S_IRWXO

Essentially, it provides a bitwise OR providing chmod 0777,
which can be used as shorthand in calls to functions such
as mkdir() available in all libc implementations.

In the case of uefitool, this define is indeed used on mkdir.
Conditionally re-define ACCESSPERMS, if undefined, so that musl
libc can be used when building uefitool.

Signed-off-by: Leah Rowe <leah@libreboot.org>
2024-08-14 21:48:46 +01:00
Leah Rowe 8b74fe2c14 lib.sh: new function mk() to handle trees in bulk
single-tree projects cannot be handled in bulk, e.g.
./mk -f project1 project2 project3

that is still the case, from the shell, but internally
it is now possible:
mk -f project1 project2 project3

mk() is a function that simply handles the given flag,
and all projects specified.

it does not handle cases without argument, for example
you cannot do:
mk -f

arguments must be provided. it can be used internally,
to simplify cases where multiple single-tree projects
must be handled, but *also* allows multi-tree projects
to be specified, without being able to actually handle
trees within that multi-tree project; so for example,
you can only specify coreboot, and then it would run
on every coreboot tree.

Signed-off-by: Leah Rowe <leah@libreboot.org>
2024-07-28 15:40:56 +01:00
Leah Rowe 7942aff43d general code cleanup in the build system
Signed-off-by: Leah Rowe <leah@libreboot.org>
2024-07-26 20:53:06 +01:00
Leah Rowe bd517a3d27 rom.sh: don't dry-run mkcoreboottar
same as the last change. make the main function a wrapper
that dry-runs the real function.

if the "dry" variable is blank, it executes.

Signed-off-by: Leah Rowe <leah@libreboot.org>
2024-07-22 23:49:00 +01:00