Google
  Web www.spinics.net

Re: [PATCH] Kvm: Qemu: save nvram

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


On Tue, Dec 02, 2008 at 10:25:49AM +0800, Zhang, Yang wrote:
> This patch to save the nvram. It save the nvram by specify the arg of 
> -name.And the saved file named by the arg. If do not specify the arg,
> it will not save the nvram

I think we might be better off having an explicit command line arg for nvram
path rather than hardcoding the directory, because there may well be times
where you want to have nvram saved, but don't want to specify -name, and
vica-verca. 

  -nvram foo.data

could prepend a default directory of $localstatedir/lib/qemu/nvram, where
$localstatedir  is set from 'configure' script, or

  -nvram /some/path/foo.data

would use the explicit path given.

> diff --git a/qemu/target-ia64/firmware.h b/qemu/target-ia64/firmware.h
> index 553a9f9..71aef2a 100644
> --- a/qemu/target-ia64/firmware.h
> +++ b/qemu/target-ia64/firmware.h
> @@ -34,11 +34,27 @@

[..snip...]

> +#define NVRAM_DIR "/usr/local/share/qemu/nvram/"

This is definitely wrong. You cannot assume /usr/local as the install
prefix, and using '$prefix/share' violates the FHS. '$prefix/share' is
for readonly data that can be shared across machines, not variable runtime
state data. I'd expect it to be in $localstatedir/lib/qemu/nvram, which
would normally default to $prefix/var/lib/qemu/nvram, but for distro package
builds typically be overridden to /var/lib/qemu/nvram. 

Daniel
-- 
|: Red Hat, Engineering, London   -o-   http://people.redhat.com/berrange/ :|
|: http://libvirt.org  -o-  http://virt-manager.org  -o-  http://ovirt.org :|
|: http://autobuild.org       -o-         http://search.cpan.org/~danberr/ :|
|: GnuPG: 7D3B9505  -o-  F3C9 553F A1DA 4AC2 5648 23C1 B3DF F742 7D3B 9505 :|
--
To unsubscribe from this list: send the line "unsubscribe kvm-ia64" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Home]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Photo]     [Yosemite News]    [Yosemite Photos]    [Video Projectors]     [PDAs]     [Free Online Dating]     [Hacking TiVo]     [Linux Kernel]     [Linux SCSI]     [XFree86]     [Devices]     [Big List of Linux Books]     [16.7MP]

  Powered by Linux