xref: /freebsd/share/man/man4/nvram.4 (revision 02e9120893770924227138ba49df1edb3896112a)
1.\"
2.\"Copyright (c) 2010 iXsystems, Inc.
3.\"All rights reserved.
4.\" written by: Xin LI <delphij@FreeBSD.org>
5.\"
6.\"Redistribution and use in source and binary forms, with or without
7.\"modification, are permitted provided that the following conditions
8.\"are met:
9.\"1. Redistributions of source code must retain the above copyright
10.\"   notice, this list of conditions and the following disclaimer.
11.\"2. Redistributions in binary form must reproduce the above copyright
12.\"   notice, this list of conditions and the following disclaimer in the
13.\"   documentation and/or other materials provided with the distribution.
14.\"
15.\"THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND
16.\"ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
17.\"IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
18.\"ARE DISCLAIMED.  IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE
19.\"FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
20.\"DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
21.\"OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
22.\"HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
23.\"LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
24.\"OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
25.\"SUCH DAMAGE.
26.\"
27.Dd February 8, 2010
28.Dt NVRAM 4
29.Os
30.Sh NAME
31.Nm nvram
32.Nd "non-volatile RAM"
33.Sh SYNOPSIS
34To compile this driver into the kernel,
35place the following line in your
36kernel configuration file:
37.Bd -ragged -offset indent
38.Cd "device nvram"
39.Ed
40.Pp
41Alternatively, to load the driver as a
42module at boot time, place the following line in
43.Xr loader.conf 5 :
44.Bd -literal -offset indent
45nvram_load="YES"
46.Ed
47.Sh DESCRIPTION
48The
49.Nm
50driver provides access to BIOS configuration NVRAM on i386 and amd64
51systems.
52.Pp
53PC motherboard uses a small non-volatile memory to store BIOS settings
54which is usually part of its clock chip and sometimes referred as
55.Dq CMOS SRAM .
56This driver exposes bytes 14 through 128 of the NVRAM, or a total of
57114 bytes, at offset zero of the device file
58.Pa /dev/nvram .
59.Pp
60This driver is useful for cloning machines that shares the same hardware
61configuration and need same BIOS setting tweaks.
62.Sh IMPLEMENTATION NOTES
63The BIOS NVRAM's bytes 16 through 31 are checksummed at byte 32.
64This driver
65.Em does not
66take care for these checksums.
67.Sh EXAMPLES
68Backup existing BIOS NVRAM to
69.Pa nvram.bin :
70.Pp
71.Dl dd if=/dev/nvram of=nvram.bin
72.Pp
73Restore BIOS NVRAM from
74.Pa nvram.bin :
75.Pp
76.Dl dd if=nvram.bin of=/dev/nvram
77.Sh SEE ALSO
78.Xr dd 1
79.Sh HISTORY
80The
81.Nm
82device driver first appeared in
83.Fx 6.4 .
84.Sh AUTHORS
85.An -nosplit
86The
87.Nm
88device driver was written by
89.An Peter Wemm .
90This manual page was written by
91.An Xin LI .
92