Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 09 Jan 2012 20:52:27 -0700
From:      Ian Lepore <freebsd@damnhippie.dyndns.org>
To:        =?iso-8859-2?Q?=A3ukasz?= Kurek <kamikadze29@o2.pl>
Cc:        freebsd-hackers@freebsd.org
Subject:   Re: backup BIOS settings
Message-ID:  <1326167547.2199.54.camel@revolution.hippie.lan>
In-Reply-To: <192396d2.4ca0430d.4f0baa06.40411@o2.pl>
References:  <192396d2.4ca0430d.4f0baa06.40411@o2.pl>

next in thread | previous in thread | raw e-mail | index | archive | help
On Tue, 2012-01-10 at 04:01 +0100, Łukasz Kurek wrote:
> Hi,
> Is it possible to backup BIOS settings (CMOS configuration) to file and restore this settings on the other machine (the same hardware configuration and the same BIOS)?
> 
> I try do it for this way:
> 
> kldload nvram
> 
> dd if=/dev/nvram of=nvram.bin   (backup)
> 
> dd if=nvram.bin of=/dev/nvram   (restore)
> 
> 
> but this way always load default BIOS settings, not my (probably there is some kind of error).

Examine the contents of the nvram.bin file with hexdump.  If every byte
has the same value, I just posted a patch to this list earlier today
(subject is "trouble with atrtc") that will fix the problem.

Many new RTC chipsets have more than the original 114 bytes of nvram.
The nvram driver doesn't currently provide access to the extra banks.
I'm not sure whether the BIOS would store anything in those other banks,
but if so, failing to save and restore those values might cause the
behavior you see.

Also, it's not directly related to your question, but I notice the
nvram(4) manpage says the driver does nothing about the checksum, but
looking at the driver code, it does recalculate the checksum when it
writes to nvram.

-- Ian





Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?1326167547.2199.54.camel>