Module Name: src Committed By: martin Date: Tue Dec 27 13:12:10 UTC 2022
Modified Files: src/usr.sbin/sysinst: bsddisklabel.c Log Message: PR 57132: when calculation additional space available for the "expanded" partition (typically /) do not forget the reserved space (that might be required for the system/bootloader/other MD stuff). To generate a diff of this commit: cvs rdiff -u -r1.70 -r1.71 src/usr.sbin/sysinst/bsddisklabel.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
Modified files: Index: src/usr.sbin/sysinst/bsddisklabel.c diff -u src/usr.sbin/sysinst/bsddisklabel.c:1.70 src/usr.sbin/sysinst/bsddisklabel.c:1.71 --- src/usr.sbin/sysinst/bsddisklabel.c:1.70 Fri Dec 16 19:49:13 2022 +++ src/usr.sbin/sysinst/bsddisklabel.c Tue Dec 27 13:12:10 2022 @@ -1,4 +1,4 @@ -/* $NetBSD: bsddisklabel.c,v 1.70 2022/12/16 19:49:13 martin Exp $ */ +/* $NetBSD: bsddisklabel.c,v 1.71 2022/12/27 13:12:10 martin Exp $ */ /* * Copyright 1997 Piermont Information Systems Inc. @@ -1434,7 +1434,8 @@ apply_settings_to_partitions(struct disk * but check size limits. */ if (exp_ndx < wanted->num) { - daddr_t free_space = parts->free_space - planned_space; + daddr_t free_space = parts->free_space - planned_space - + wanted->reserved_space; daddr_t new_size = wanted->infos[exp_ndx].size; if (free_space > 0) new_size += roundup(free_space,align);