lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <49922A7A.7090609@kernel.org>
Date:	Wed, 11 Feb 2009 10:31:38 +0900
From:	Tejun Heo <tj@...nel.org>
To:	Ondrej Zary <linux@...nbow-software.org>
CC:	Alan Cox <alan@...rguk.ukuu.org.uk>, linux-ide@...r.kernel.org,
	linux-kernel@...r.kernel.org, Jeff Garzik <jeff@...zik.org>
Subject: Re: [PATCH] Resume from hibernation fails with pata_it821x RAID volume

Ondrej Zary wrote:
> Hello,
> hibernation didn't work for me since I started to use IT8212 controller. Now I 
> did some debugging (booting with no_console_suspend init=/bin/sh).
> 
> Found that resume fails (2.6.28) with "serial number mismatch 'some 
> garbage' != 'some other garbage'" and "revalidation failed" messages. That's 
> because the controller firmware fills different serial number in the IDENTIFY 
> every boot.
> 
> The patch below fixes the resume simply clearing the serial number. The proper 
> fix would be probably to fill in the serial number of the RAID volume 
> instead. I assume that there must be something like that stored on the drives 
> but I don't know where.
> 
> 
> Fix resume on pata_it821x RAID volume by clearing the serial number in 
> IDENTIFY data, which is otherwise different on each boot.
> 
> Signed-off-by: Ondrej Zary <linux@...nbow-software.org>
> 
> --- linux-2.6.28-orig/drivers/ata/pata_it821x.c	2009-01-02 17:18:36.000000000 +0100
> +++ linux/drivers/ata/pata_it821x.c	2009-02-02 17:47:57.000000000 +0100
> @@ -561,6 +561,9 @@
>  		id[83] |= 0x4400;	/* Word 83 is valid and LBA48 */
>  		id[86] |= 0x0400;	/* LBA48 on */
>  		id[ATA_ID_MAJOR_VER] |= 0x1F;
> +		/* Clear the serial number because it's different each boot
> +		   which breaks validation on resume */
> +		memset(&id[ATA_ID_SERNO], 0x20, ATA_ID_SERNO_LEN);
>  	}
>  	return err_mask;
>  }

Looks good to me.  Alan, Jeff?

-- 
tejun
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ