OpenBSD CVS

CVS log for src/usr.sbin/installboot/loongson_installboot.c


[BACK] Up to [local] / src / usr.sbin / installboot

Request diff between arbitrary revisions


Default branch: MAIN


Revision 1.11 / (download) - annotate - [select for diffs], Wed Sep 17 16:12:10 2025 UTC (2 weeks, 1 day ago) by deraadt
Branch: MAIN
CVS Tags: HEAD
Changes since 1.10: +2 -2 lines
Diff to previous 1.10 (colored)

use DL_PARTNUM2NAME and DL_PARTNAME2NUM instead of arithmetic relative to 'a'

Revision 1.10 / (download) - annotate - [select for diffs], Sun Nov 6 20:03:48 2022 UTC (2 years, 10 months ago) by krw
Branch: MAIN
CVS Tags: OPENBSD_7_7_BASE, OPENBSD_7_7, OPENBSD_7_6_BASE, OPENBSD_7_6, OPENBSD_7_5_BASE, OPENBSD_7_5, OPENBSD_7_4_BASE, OPENBSD_7_4, OPENBSD_7_3_BASE, OPENBSD_7_3
Changes since 1.9: +2 -3 lines
Diff to previous 1.9 (colored)

Nuke some 'set but not used' pathlen variables.

ok beck@

Revision 1.9 / (download) - annotate - [select for diffs], Wed Oct 19 19:08:25 2022 UTC (2 years, 11 months ago) by kn
Branch: MAIN
Changes since 1.8: +3 -3 lines
Diff to previous 1.8 (colored)

Replace "newfs/fsck_ext2fs" with "newfs/msdos -t ext2fs", constify

OK miod

Revision 1.8 / (download) - annotate - [select for diffs], Tue Sep 27 11:48:57 2022 UTC (3 years ago) by kn
Branch: MAIN
Changes since 1.7: +6 -15 lines
Diff to previous 1.7 (colored)

fix passing explicit stage files

This fixes installboot regress on octeon; same diff as
macppc_installboot.c r1.6, powerpc64_installboot r1.7 and
octeon_installboot r1.8.

loongson was the last architecture requiring this fix.  I don't have a
machine to test it myself (loongson isn't built anymore, anyway) but given
the same diff works on four other architectures, this should just work.

Revision 1.7 / (download) - annotate - [select for diffs], Wed Sep 14 16:43:00 2022 UTC (3 years ago) by kn
Branch: MAIN
CVS Tags: OPENBSD_7_2_BASE, OPENBSD_7_2
Changes since 1.6: +1 -10 lines
Diff to previous 1.6 (colored)

Backout "Reflect script failure in exit code"

amd64 install using (G)PT seems busted as reported by tb

Revision 1.6 / (download) - annotate - [select for diffs], Sun Sep 11 07:38:33 2022 UTC (3 years ago) by miod
Branch: MAIN
Changes since 1.5: +3 -3 lines
Diff to previous 1.5 (colored)

Fix build after previous

Revision 1.5 / (download) - annotate - [select for diffs], Fri Sep 9 15:53:16 2022 UTC (3 years ago) by kn
Branch: MAIN
Changes since 1.4: +12 -3 lines
Diff to previous 1.4 (colored)

Reflect script failure in exit code

installboot(8) runs newfs(8) and fsck(8) via system(3) but only checks
failures of the function itself, always returning zero no matter what the
programs/shell returned.

This is bad for regress tests relying on correct return codes.

create_filesystem() itself must not exit as write_filesystem() calls it and
cleans up temporary files upon failure.

Make it return -1 if the script returned non-zero so write_filesystem()
handles it as error, cleans up and makes installboot exit 1.

Stop ignoring create_filesystem()'s return code in md_prepareboot() and
exit the same way.

Here's the change in behaviour on arm64 (newfs fails because of the
vnd/disklabel race, see "Race in disk_attach_callback?" on tech@):

	# installboot -vp vnd0 ; echo $?
	newfsing 6694ae5b0d7596ed.i
	newfs_msdos: /dev/r6694ae5b0d7596ed.i: No such file or directory
	0
	# ./obj/installboot -vp vnd0 ; echo $?
	newfsing 6694ae5b0d7596ed.i
	newfs_msdos: /dev/r6694ae5b0d7596ed.i: No such file or directory
	1

Tested on amd64 arm64 macppc octeon powerpc64 sparc64
OK millert

Revision 1.4 / (download) - annotate - [select for diffs], Tue Jul 20 14:51:56 2021 UTC (4 years, 2 months ago) by kettenis
Branch: MAIN
CVS Tags: OPENBSD_7_1_BASE, OPENBSD_7_1, OPENBSD_7_0_BASE, OPENBSD_7_0
Changes since 1.3: +6 -1 lines
Diff to previous 1.3 (colored)

Add -p option to "prepare" (newfs) a filesystem that will be used for
the bootloader.  This is a no-op on architectures where such a filesystem
isn't needed.

ok krw@, deraadt@

Revision 1.3 / (download) - annotate - [select for diffs], Sun Jul 19 15:23:08 2020 UTC (5 years, 2 months ago) by visa
Branch: MAIN
CVS Tags: OPENBSD_6_9_BASE, OPENBSD_6_9, OPENBSD_6_8_BASE, OPENBSD_6_8
Changes since 1.2: +4 -4 lines
Diff to previous 1.2 (colored)

Should use ufs_args here after all.

While here, make messages more correct.

Revision 1.2 / (download) - annotate - [select for diffs], Sat Jul 18 16:42:00 2020 UTC (5 years, 2 months ago) by deraadt
Branch: MAIN
Changes since 1.1: +2 -2 lines
Diff to previous 1.1 (colored)

use correct structure for mounting, duh
ok visa kettenis

Revision 1.1 / (download) - annotate - [select for diffs], Sat Jun 27 15:35:29 2020 UTC (5 years, 3 months ago) by deraadt
Branch: MAIN

convert macppc, octeon, and loongson to use MI installboot, removing
special case scripting in install.md.
(macppc still requires manual steps for HFS bootmode)
tested by krw, visa, gkoehler

This form allows you to request diff's between any two revisions of a file. You may select a symbolic revision name using the selection box or you may type in a numeric name using the type-in text box.