Commit Graph

79 Commits

Author SHA1 Message Date
Leah Rowe b75490f8fc flashprog: bump to 5b4fdd1 from 2 May 2024
I've rebased the workaround-mx patch as follows. See:

commit 9a11cbf21a5078bcdb8db7584c44a9ee17020db4
Author: Nico Huber <nico.h@gmx.de>
Date:   Fri Jan 13 01:19:07 2023 +0100

    Let the flash context directly point to the used master

This change, now upstream in flashprog, made me have to do this in
the patch. I changed this:

flash->mst->spi.command(flash, sizeof(cmd), sizeof(buf), cmd, buf);

to this:

flash->mst.spi->command(flash, sizeof(cmd), sizeof(buf), cmd, buf);

It should work fine. This update imports the following upstream
patches from flashprog:

* 5b4fdd1 z60_flashprog.rules: Add udev rule for CH347
* 72c9e40 meson: Check for CPU families with known raw mem access
* 3458220 platform/meson: Port pciutils/pci.h workaround to Meson
* f279762 platform/meson: Check for libi386 on NetBSD
* 14da5f7 README: Convert to Markdown
* 8ddea57 README: Document branching and release policy
* 2522456 util/list_yet_unsupported_chips.sh: Fix path
* cbf9c11 spi: Don't cross 16MiB boundaries with long writes
* 823a704 dediprog: Skip warning on first attempt to read device string
* e8463c8 dediprog: Revise prefix check for given programmer id
* 38af1a1 dediprog: Revise id matching
* 4661e7c amd_spi100: Use flashprog_read_chunked() for progress reporting
* cdcfda2 read_memmapped: Use flashprog_read_chunked() for progress reporting
* 7679b5c spi25: Replace spi_read_chunked() with more abstract version
* ca1c7fd spi25: Normalize parameters of spi_nbyte_read()
* e36e3dc dediprog: Use default_spi_write_256
* 522a86d linux_spi: Use default_spi_read()/_write_256()
* 806509b cli_classic: Turn progress reporting into a progress bar
* 842d678 libflashrom: Return progress state to the library user
* aa714dd flashprog.c: Let select_erase_functions() return byte count
* 2eed4cf serprog: Add SPI Mode and CS Mode commands
* 821a085 dediprog: Implement id reading for SF600 and later
* 274e655 dediprog: Read device string early
* 0057822 dediprog: Add protocol detection for SF700 & SF600Plus-G2
* fb176d2 dediprog: Use more general 4BA write mode for newer protocols
* 0ab5c3d dediprog: Split device type and version parsing
* bdef5c2 dediprog: Use unsigned conversions to parse device string
* 5262e29 dediprog: Try to request 32B device string (instead of 16B)
* e76e21f dediprog: Get rid of some unnecessary hex constants
* 5a09d1e udelay: Lower the sleep vs delay threshold
* 03ad4a4 linux_mtd: Provide no-op delay implementation
* 211c6ec serprog: Refine flushing before synchronization
* 383b7fe serprog: Test synchronicity before trying to synchronize
* d7318ea serprog: Move synchronicity test into separate function
* 9a11cbf Let the flash context directly point to the used master
* aabb3e0 writeprotect: Hook wp functions into the chip driver
* 89569d6 memory_mapped: Reduce `decode_sizes` to a single `max_rom_decode`
* 929d2e1 internal: Pass programmer context down into chipset enables
* 7c717c3 internal: Pass programmer context down into board enables
* e3a2688 Pass programmer context to programmer->init()
* 2b66ad9 Start implementing struct flashprog_programmer
* 4517e92 memory_bus: Drop stale `size == 0` workaround and FIXME
* b197402 memory_bus: Split register mapping into own function
* 0e76d99 memory_bus: Move (un)map_flash_region into par master
* 9eec407 Perform default mapping only for respective chips
* 56b53dd wbsio_spi: Request memory mapping locally
* 5596190 it87spi: Request memory mapping locally
* 46449b4 spi25: Drop stale `bus == SPI` guards
* ab6b18f spi25: Move 4BA preparations into spi_prepare_4ba() hook
* 901fb95 Add prepare/finish_access() hooks for chip drivers
* a96aaa3 dediprog: Support long writes of 16MiB and more
* 1338936 Consider 4BA support when filtering erase functions
* 8d36db6 flashprog.8: Fix up serprog example
* d2ac303 flashprog.8: document new serprog cs parameter
* d1b9153 chipset_enable.c: Add Genoa to mendocino entry

Signed-off-by: Leah Rowe <leah@libreboot.org>
2024-05-26 20:39:31 +01:00
Leah Rowe a02b152f44 rename nukeblobs to a more generic name
blobs.list is now nuke.list

this is because i'm going to import this functionality
into lbmk (libreboot build system).

libreboot will not do full deblobbing like canoeboot does,
but there are still certain files that i like to delete
in releases, such as u-boot's strlcat.c file under tests

calling it "nukeblobs" in libreboot makes no sense, but
i like to avoid merge conflicts when cherry-picking
patches between cbmk and lbmk, so i like to make sure
that functions and variables common to both are named
the name.

simply calling it "nuke" or calling the files "nuke.list"
is probably inoffensive while conveying the same meaning.

Signed-off-by: Leah Rowe <info@minifree.org>
2024-05-26 09:33:27 +01:00
Leah Rowe aa15eef32f config: add backup coreboot submodule repositories
this is using the same functionality that was added a few
commits ago, to override the use of "git submodule update"

each coreboot submodule has two repositories defined, with
the second one kicking in if the mail one fails upon cloning.

Signed-off-by: Leah Rowe <leah@libreboot.org>
2024-05-25 11:48:49 +01:00
Leah Rowe 9e88ef2449 coreboot/default: remove chromeec from module.list
Signed-off-by: Leah Rowe <leah@libreboot.org>
2024-05-25 11:44:46 +01:00
Leah Rowe 38fca598fb coreboot: only download the necessary submodules
whitelist what modules are downloaded, by adding
module.list files in the corresponding directories
under config/submodule/, per each coreboot tree.

this is making use of functionality added in the
previous commit.

Signed-off-by: Leah Rowe <leah@libreboot.org>
2024-05-25 11:43:42 +01:00
Nicholas Chin 3b2ebda890 Fix E6400 display reference clock patches
The ones I submitted before seem to have been outdated ones
that don't actually build properly.

Signed-off-by: Nicholas Chin <nic.c3.14@gmail.com>
2024-05-22 02:09:26 +01:00
Leah Rowe 995f052bb0 fix building coreboot images on i686 hosts
firstly, memtest86+ is currently not cross compiled and
relies on 64-bit headers (x86_64 only). a 32-bit distro
is unlikely to be able to build 64-bit binaries.

secondly: vboot throws a build error due to -Werror when
building on 32-bit hosts. we rely on vboot code to build
cbfstool, so turn off -Werror on vboot

that's all. 32-bit hosts are not recommended; it is assumed
that you are building on an x86_64 host. work will go into
the build system at a later date to make it more portable,
by cross compiling everything, but this should fix 32-bit
for now.

there are some x60/t60 users who still want to build roms,
so let's allow them that possibility.

Signed-off-by: Leah Rowe <leah@libreboot.org>
2024-05-21 23:42:27 +01:00
Mate Kukri 31d2c818eb Also try unlocking encrypted volume on NVMe 2024-05-21 20:26:07 +01:00
Mate Kukri f58b01c300 Add NVMe support to GRUB2 payload
Tested on OptiPlex 3050 (via injecting grub2.elf into WIP coreboot
port).
2024-05-21 18:24:01 +01:00
Nicholas Chin b892036edf Fix E6400 display issue with 1440 x 900 panel
The E6400 uses a 100 MHz reference clock on DPLL_REF_SSCLK, whereas
libgfxinit assumed that the reference was always 96 MHz. The frequency
difference caused by a 100 MHz reference with PLL config values
calculated assuming a 96 MHz reference were not significant enough to
cause noticable issues with the more common 1280 x 800 panels, but are
enough to matter for the 1440 x 900 panels which use a higher pixel
clock. This only affected the pre-OS graphics environment provided by
libgfxinit, as Linux drivers would determine the reference clock
frequency based on data in the VBT.

Fix this by making the reference clock frequency in libgfxinit
configurable for GM45 based on a new coreboot Kconfig, which is set to
100 MHz for the E6400.

Signed-off-by: Nicholas Chin <nic.c3.14@gmail.com>
2024-05-21 18:18:22 +01:00
samuraikid f81c7ed8e9 Add pt qwerty keymap to lbmk
Signed-off-by: samuraikid <samuraikid@noreply.codeberg.org>
2024-05-21 18:16:44 +01:00
Leah Rowe 849466c0ac git.sh: allow patching submodules
for single-tree project (e.g. flashprog):
config/submodule/PROJECT/MODNAME/patches

for multi-tree project (e.g. coreboot):
config/submodule/PROJECT/TREE/MODNAME/patches

MODNAME is e.g.:
3rdparty/vboot directory in coreboot: would become vboot
(the submodule codepath is filtered to up to the final slash)

another example:
submodire src dir 3rdparty/foo/bar
MODNAME would be "bar"

Add whatever patches you like to a given submodule.

An example patch is included in this commit.

Signed-off-by: Leah Rowe <leah@libreboot.org>
2024-05-20 00:28:46 +01:00
livio fbac2d8fe6 Implemented failsafe options at boot and inside menus for enabling/disabling serial, spkmodem and gfxterm
Signed-off-by: Leah Rowe <info@minifree.org>
2024-05-16 05:56:08 +01:00
Leah Rowe 5c888669c6 disable x301 for next release (for now)
Signed-off-by: Leah Rowe <leah@libreboot.org>
2024-05-13 02:14:12 +01:00
Leah Rowe d423421995 remove all status checks. only handle release.
the release variable is all we need, turning a target on
or off for a given release.

the status checks were prone to bugs, and unnecessary; it
also broke certain benchmark scripts.

it's better to keep the cbmk logic simpler. board status
will be moved to the documentation instead.

Signed-off-by: Leah Rowe <leah@libreboot.org>
2024-05-13 02:07:22 +01:00
Leah Rowe 41f4ee3c2d Canoeboot 20240510 release
Signed-off-by: Leah Rowe <info@minifree.org>
2024-05-10 08:39:24 +01:00
Leah Rowe 0580373ff9 bump seabios to e5f2e4c69643bc3cd385306a9e5d29e11578148c
changes upstream, relative to the previous revision:

* e5f2e4c6 pciinit: don't misalign large BARs
* 731c88d5 stdvgaio: Only read/write one color palette entry at a time
* c5a361c0 stdvga: Add stdvga_set_vertical_size() helper function
* 22c91412 stdvga: Rename stdvga_get_vde() to stdvga_get_vertical_size()
* 549463db stdvga: Rename stdvga_set_scan_lines() to stdvga_set_character_height()
* c67914ac stdvga: Rename stdvga_set_text_block_specifier() to stdvga_set_font_location()
* aa94925d stdvga: Rework stdvga palette index paging interface functions
* 8de51a5a stdvga: Rename stdvga_toggle_intensity() to stdvga_set_palette_blinking()
* 96c7781f stdvga: Add comments to interface functions in stdvga.c
* 2996819f stdvga: Rename CGA palette functions
* 91368088 stdvgamodes: Improve naming of dac palette tables
* 70f43981 stdvgamodes: No need to store pelmask in vga_modes[]
* 1588fd14 vgasrc: Rename vgahw_get_linesize() to vgahw_minimum_linelength()
* d73e18bb vgasrc: Use curmode_g instead of vmode_g when mode is the current video mode
* 192e23b7 vbe: implement function 09h (get/set palette data)
* 3722c21d vgasrc: round up save/restore size
* 5d87ff25 vbe: Add VBE 2.0+ OemData field to struct vbe_info
* 163fd9f0 fix smbios blob length overflow
* 82faf1d5 Add LBA 64bit support for reads beyond 2TB.
* 3f082f38 Add AHCI Power ON + ICC_ACTIVE into port setup code
* 3ae88886 esp-scsi: terminate DMA transfer when ESP data transfer completes
* a6ed6b70 limit address space used for pci devices.

Signed-off-by: Leah Rowe <info@minifree.org>
2024-05-10 05:48:57 +01:00
Leah Rowe 29d6d294ab Canoeboot 20240504 release
Signed-off-by: Leah Rowe <info@minifree.org>
2024-05-04 10:26:51 +01:00
Leah Rowe 79b00fbfaf coreboot: update latitude release status
working s3 means i'm happy to mark it as being stable.

Signed-off-by: Leah Rowe <leah@libreboot.org>
2024-05-04 10:24:55 +01:00
Leah Rowe ed8969d93f d510mo and d945gclf: disable for release
Signed-off-by: Leah Rowe <leah@libreboot.org>
2024-05-04 10:23:15 +01:00
Leah Rowe 5405584b5a mark lenovo x301 as stable for release
Signed-off-by: Leah Rowe <leah@libreboot.org>
2024-05-04 10:22:10 +01:00
Nicholas Chin 9d5e03268b coreboot/default: Add patches to fix S3 on SNB/IVB Latitudes
Signed-off-by: Nicholas Chin <nic.c3.14@gmail.com>
2024-05-04 10:21:59 +01:00
Leah Rowe dc41f55a09 coreboot/x301: set release=n (will re-test)
was reported broken on canoeboot 0.1, which uses 2021
coreboot. we use much newer coreboot now in libreboot, but
still, better be cautious. set to release=n.

i'll set status and remove release=n if it works on testing

Signed-off-by: Leah Rowe <leah@libreboot.org>
2024-05-04 10:21:28 +01:00
Leah Rowe c4fe290da8 mark x4x boards ready for release
Signed-off-by: Leah Rowe <leah@libreboot.org>
2024-05-04 10:20:41 +01:00
Leah Rowe a8aa1dc0f8 update config/git/docs (cbwww rev)
Signed-off-by: Leah Rowe <info@minifree.org>
2024-05-04 10:17:47 +01:00
Leah Rowe b64cab53eb coreboot: fix fam15h board configs for build
Signed-off-by: Leah Rowe <info@minifree.org>
2024-05-03 13:21:54 +01:00
Leah Rowe 7d652ac991 coreboot: never download blobs even if USE_BLOBS=y
Same idea as my never-download-microcode patch. Even if a
coreboot config enables blobs, the blobs are not actually
downloaded or inserted or otherwise handled in any way.

This means I can re-use lbmk-based coreboot configs without
as much modification, thus reducing the maintenance burden
for Canoeboot releases.

Signed-off-by: Leah Rowe <info@minifree.org>
2024-05-03 06:35:38 +01:00
Leah Rowe 57a63343fb Update coreboot to LB 20240504 (sync lbmk cd9685d1)
With other recent changes, and this patch, Canoeboot is now
in sync with Libreboot lbmk, commit:
cd9685d12d2b71a00cb6766bb85f392d4db92c83

This is with updated deblobbing, and Canoeboot's no-microcode
patches, that disable microcode updates universally.

Several patches from lbmk (for coreboot) aren't needed,
due to being for boards that Canoeboot does not use, so
those patches have been somewhat rebased, and configs
adapted, but this is otherwise identical.

As in previous Canoeboot updates, I've turned off this
option in all coreboot configs:
CONFIG_USE_BLOBS

Turning off that option prevents the coreboot build system
from ever attempting to use any blobs, but in practise it
would not have done so anyway, because Canoeboot disables
all handling of microcode in the build system.

Signed-off-by: Leah Rowe <info@minifree.org>
2024-05-03 05:59:00 +01:00
livio f288eb4b42 Fixed boot selection menu 2024-05-03 01:45:26 +01:00
Leah Rowe f44f2450a2 correct dell latitude status for release
it should be marked unstable, though these machines
are basically reliable; they have certain missing features
and quirky behaviour so it's important not to over-sell it

mark it as unstable, on all of the dell latitudes

Signed-off-by: Leah Rowe <leah@libreboot.org>
2024-05-03 01:44:57 +01:00
Leah Rowe 322cd0f9f6 set gru bob/kevin stable for release
Signed-off-by: Leah Rowe <leah@libreboot.org>
2024-05-03 01:43:44 +01:00
Leah Rowe 3b34c79934 set dell latitudes stable for release
Signed-off-by: Leah Rowe <leah@libreboot.org>
2024-05-03 01:42:41 +01:00
Leah Rowe a297fced80 mark i945 machines as stable for release
the previous issue was tested, and can no longer be reproduced

Signed-off-by: Leah Rowe <leah@libreboot.org>
2024-05-03 01:41:24 +01:00
Leah Rowe 96eb7913a5 build/roms: simplified seagrub handling
Signed-off-by: Leah Rowe <leah@libreboot.org>
2024-05-03 01:22:15 +01:00
Leah Rowe 3eab399e7a update macbook21/x60/t60 status
Signed-off-by: Leah Rowe <leah@libreboot.org>
2024-05-03 01:10:40 +01:00
Leah Rowe bd9404c237 update more board statuses before release
what's left to properly test are pineview/x4x/i945 boards

Signed-off-by: Leah Rowe <leah@libreboot.org>
2024-05-03 00:59:07 +01:00
Leah Rowe a52db7899c add warning for coreboot/e6400_4mb
Signed-off-by: Leah Rowe <info@minifree.org>
2024-05-03 00:56:05 +01:00
Leah Rowe 9bff198adc declare gm45 thinkpads stable for release
Signed-off-by: Leah Rowe <leah@libreboot.org>
2024-05-03 00:51:17 +01:00
Leah Rowe d8bd88bff2 kcma-d8/kgpe-d16: mark as tested(unstable)
raminit has never been fully reliable on this board, and so
this board has never been stable. so, now that lbmk specifies
such status per board, mark these boards as such.

Signed-off-by: Leah Rowe <leah@libreboot.org>
2024-05-03 00:50:46 +01:00
Leah Rowe b56f79578a build/roms: report status when building images
export CBMK_VERSION_TYPE=x
x can be: stable, unstable

in target.cfg files, specify:
status=x
x can be: stable, unstable, broken, untested
if unset, cbmk defaults to "unknown"

if CBMK_VERSION_TYPE is set, no confirmation is asked
if the given target matches what's set (but what's set
in that environmental variable can only be stable or
unstable)

if CBMK_RELEASE="y", no confirmation is asked, unless
the target is something other than stable/unstable

"unstable" means it works, but has a few non-breaking
bugs, e.g. broken s3 on dell e6400

whereas, if raminit regularly fails or it is so absolutely
unreliable as to be unusable, then the board should be
declared "broken"

untested means: it has not been tested

With this change, it should now be easier to track whether
a given board is tested, in preparation for releases. When
working on trees/boards, status can be set for targets.

Also: in the board directory, you can add a "warn.txt" file
which will display a message. For example, if a board has a
particular quirk to watch out for, write that there. The message
will be printed during the build process, to stdout.

If status is anything *other* than stable, or it is unstable
but CBMK_VERSION_TYPE is not set to "unstable", and not building
a release, a confirmation is passed.

If the board is not specified as stable or unstable, during
a release build, the build is skipped and the ROM is not
provided in that release; this is in *addition* to
release="n" or release="y" that can be set in target.cfg,
which will skip the release build for that target if "n"

Signed-off-by: Leah Rowe <info@minifree.org>
2024-05-03 00:45:50 +01:00
Leah Rowe cca3294194 GRUB: bump to today's latest revision
GRUB has not pushed many patches to master since the recent 2.12
release, but there are a number of interesting fixes.

canoeboot is doing a release soon. bump to latest grub revision.

Some of the new patches in GRUB are interesting:

XFS fixes:

"fs/xfs: Handle non-continuous data blocks in directory extents"
68dd65cfdaad08b1f8ec01b84949b0bf88bc0d8c
Fixes: https://bugzilla.redhat.com/show_bug.cgi?id=2254370
Apparently, XFS could not boot in some reports, though this was
likely with BIOS or UEFI GRUB; no such reports were made to canoeboot

"gfxmenu/view: Resolve false grub_errno disrupting boot process"
39c927df66c7ca62d97905d1385054ac9ce67209

"util/grub-fstest: Add a new command zfs-bootfs"
28c4405208cfb6e2cea737f6cbaf17e631bac6cd

The gnulib revision does not need to be updated at this time.

Signed-off-by: Leah Rowe <info@minifree.org>
2024-05-02 23:23:48 +01:00
Leah Rowe 428ebea0d9 grub xhci support
see:

https://github.com/9elements/grub/commits/xhci-module-upstreaming-squash_v4/

grub only supports xhci on bios/uefi targets, but not coreboot.
some newer machines don't have ps/2 controllers, and boot in a
way where ehci isn't available at startup; the controller can't
be used by ehci code, there must be xhci support.

the code is from Patrick Rudolph working on behalf of 9elements.
the code was also sent here for review:

https://lists.gnu.org/archive/html/grub-devel/2020-12/msg00111.html

however, upstream never merged these patches. canoeboot will have
to maintain these from now on. the patches have been rebased for
use with grub 2.12.

Signed-off-by: Leah Rowe <info@minifree.org>
2024-05-02 23:07:43 +01:00
Leah Rowe ccfbfffb10 enable serial console on fam15h boards
Signed-off-by: Leah Rowe <leah@libreboot.org>
2024-05-02 22:08:33 +01:00
Leah Rowe f340a10fbb update pico-serprog to new revision
this merges the fix from:
https://codeberg.org/libreboot/pico-serprog/pulls/1

however, PRs are not to be sent there. riku merged it in
his repository, and i pulled it in the mirror hosted
on libreboot codeberg

Signed-off-by: Leah Rowe <leah@libreboot.org>
2024-05-02 22:06:25 +01:00
Riku Viitanen ef0cf81948 Patch SeaBIOS: Add MXM support
Signed-off-by: Riku Viitanen <riku.viitanen@protonmail.com>
2024-05-02 22:06:06 +01:00
Riku Viitanen b5236f00a9 update revision: pico-serprog
should fix https://codeberg.org/libreboot/lbmk/issues/182

Signed-off-by: Riku Viitanen <riku.viitanen@protonmail.com>
2024-05-02 22:04:23 +01:00
Leah Rowe 5cf9880a9f update pico-serprog to Riku's new revision
Riku introduced three new patches:

* Add support for multiple chip selects. This allows you to
  control multiple chips from the same clip, on systems with
  dual flash setups, at least theoretically.
* Enable pull-up on unused chip selects - pull them high so
  that chips you connect that to are deactivated while flashing
  the target chip. This could be used on thinkpad W541 for
  instance, where miso/mosi have 0ohm between them via the two
  flash ICs. You could pull the other chip select high.
* Documentation for the above, in the pico-serprog readme.

This goes in tandem with a patch from Riku, present in the
recently integrated flashprog project, namely:

commit ddb6d926783d4f9cbee04c7392718ed8f89daa0e
Author: Riku Viitanen <riku.viitanen@protonmail.com>
Date:   Mon Jan 15 19:15:49 2024 +0200

    serprog: Add support for multiple SPI chip selects

This functionality will therefore be present in the next
release of Libreboot.

Signed-off-by: Leah Rowe <leah@libreboot.org>
2024-05-02 21:43:48 +01:00
Riku Viitanen 73cfc61d65 flashprog: apply the good old MX25 workaround 2024-05-02 21:43:33 +01:00
Leah Rowe 52f3bb2e64 remove remaining flashrom remnants (use flashprog)
we use flashprog now!

Signed-off-by: Leah Rowe <leah@libreboot.org>
2024-05-02 21:43:06 +01:00
Leah Rowe 8ec0c79d71 update parabola dependencies for flashprog
Signed-off-by: Leah Rowe <leah@libreboot.org>
2024-05-02 21:41:35 +01:00