On Fri, Jan 23, 2009 at 10:53:42PM +0000, Hugh Dickins wrote: > Please, can we make it subject to a new option, -f perhaps? Yes, we can. That sounds better than exec mkswap by default. > Then SuSE can add that option in their ppc64 scripts, and > I can edit it out again, and nobody gets caught out by > their swapon going off doing its own unexpected mkswap. > > By the way, that #define MAX_PAGESIZE (64 * 1024): there's people > now using pagesize 256kB on ppc64, don't know if you want to cater > for them too (maybe they're not using swap, or not switching). hmm.. is it supported by upstream kernel? > I checked the various sources earlier today, though I didn't find > an S2SUSPEND. They all modify some other part of the swap header, > but not such that you need worry about it. S1SUSPEND and ULSUSPEND > both modify the end of the badpage list, just before the signature: > I really ought to lower MAX_SWAP_BADPAGES to reflect that. TuxOnIce > modifies the start of the swap header (in the bootbits area). But > neither area would need restoring when just rewriting the signature: > a simple write of the signature would be much better than mkswap. sounds good. BTW, there are many requests to zap bootbits area by mkswap (by default when there is not a disklabel) to remove a superblock of the original filesystem. Now we have very often valid swap area on a valid filesystem... (Sometimes it's pretty dangerous, for example some (idiotic) LiveCDs automatically call swapon when found a valid swap header on disk.) Karel -- Karel Zak <kzak@xxxxxxxxxx> -- To unsubscribe from this list: send the line "unsubscribe util-linux-ng" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html