From 4a9fb9fb80c51a884aa3ab12bb0a44a1fa51fe37 Mon Sep 17 00:00:00 2001 From: Warner Losh Date: Tue, 30 Aug 2016 18:01:19 +0000 Subject: [PATCH] Remove CHS alignment. It's not needed and causes problems for the BBB boot partition. NetBSD removed it in 1.10 in their repo some time ago. Submitted by: Guy Yur PR: 183234 --- sbin/newfs_msdos/mkfs_msdos.c | 7 ------- 1 file changed, 7 deletions(-) diff --git a/sbin/newfs_msdos/mkfs_msdos.c b/sbin/newfs_msdos/mkfs_msdos.c index 90d7df855a25..f29760f7f25e 100644 --- a/sbin/newfs_msdos/mkfs_msdos.c +++ b/sbin/newfs_msdos/mkfs_msdos.c @@ -313,15 +313,8 @@ mkfs_msdos(const char *fname, const char *dtype, const struct msdos_options *op) bpb.bpbHiddenSecs = o.hidden_sectors; if (!(o.floppy || (o.drive_heads && o.sectors_per_track && o.bytes_per_sector && o.size && o.hidden_sectors_set))) { - off_t delta; getdiskinfo(fd, fname, dtype, o.hidden_sectors_set, &bpb); bpb.bpbHugeSectors -= (o.offset / bpb.bpbBytesPerSec); - delta = bpb.bpbHugeSectors % bpb.bpbSecPerTrack; - if (delta != 0) { - warnx("trim %d sectors to adjust to a multiple of %d", - (int)delta, bpb.bpbSecPerTrack); - bpb.bpbHugeSectors -= delta; - } if (bpb.bpbSecPerClust == 0) { /* set defaults */ if (bpb.bpbHugeSectors <= 6000) /* about 3MB -> 512 bytes */ bpb.bpbSecPerClust = 1;