NetBSD-Bugs archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: bin/57921: swapon: Do not overwrite Linux swap header



The following reply was made to PR bin/57921; it has been noted by GNATS.

From: Izumi Tsutsui <tsutsui%ceres.dti.ne.jp@localhost>
To: thorpej%me.com@localhost
Cc: gnats-bugs%netbsd.org@localhost, tsutsui%ceres.dti.ne.jp@localhost
Subject: Re: bin/57921: swapon: Do not overwrite Linux swap header
Date: Sun, 11 Feb 2024 07:31:49 +0900

 > > i'm confused.  we skip the first PAGE_SIZE bytes on block devices,
 > > ie, any mbr or gpt accessed for this would be a block device.
 > 
 > Wait, what?  Why would we do this?  The block device specified for swap should be a partition, I don't see any reason whatsoever to skip any part of a partition assigned swap duty.
 
 If a swap partition is allocated at the top of the disk,
 we should preserve at least BSD disklabel and bootloaders etc.
 (though PAGE_SIZE is not enough for bootloaders on PAGE_SIZE=4096 ports)
 
 ---
 Izumi Tsutsui
 


Home | Main Index | Thread Index | Old Index