Re: [PATCH 2/3] mkswap: allow creating swap on /dev/hd[ab]

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

 



The patch looks good.  Although as /dev/hda seems to be unused it probably 
won't affect anyone.  It would be nice to get this Debian bug closed before it 
turns 4.

On Sun, 13 May 2012, Petr Uzel <petr.uzel@xxxxxxx> wrote:
> Currently, mkswap does not allow swap to be created on /dev/hda and
> /dev/hdb. There is no reason why /dev/hda and /dev/hdb should be treated
> differently.
> 
> Addresses: http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=491021
> Cc: Russell Coker <russell@xxxxxxxxxxxx>
> Signed-off-by: Petr Uzel <petr.uzel@xxxxxxx>
> ---
>  disk-utils/mkswap.c |    5 -----
>  1 files changed, 0 insertions(+), 5 deletions(-)
> 
> diff --git a/disk-utils/mkswap.c b/disk-utils/mkswap.c
> index c7dedd7..dec34e1 100644
> --- a/disk-utils/mkswap.c
> +++ b/disk-utils/mkswap.c
> @@ -596,13 +596,8 @@ main(int argc, char **argv) {
>  		exit(EXIT_FAILURE);
>  	}
> 
> -	/* Want a block device. Probably not /dev/hda or /dev/hdb. */
>  	if (!S_ISBLK(statbuf.st_mode))
>  		check=0;
> -	else if (statbuf.st_rdev == 0x0300 || statbuf.st_rdev == 0x0340)
> -		errx(EXIT_FAILURE, _("error: "
> -			"will not try to make swapdevice on '%s'"),
> -			device_name);
>  	else if (is_mounted(device_name))
>  		errx(EXIT_FAILURE, _("error: "
>  			"%s is mounted; will not make swapspace."),


-- 
My Main Blog         http://etbe.coker.com.au/
My Documents Blog    http://doc.coker.com.au/
--
To unsubscribe from this list: send the line "unsubscribe util-linux" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Netdev]     [Ethernet Bridging]     [Linux Wireless]     [Kernel Newbies]     [Security]     [Linux for Hams]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux RAID]     [Linux Admin]     [Samba]

  Powered by Linux