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

[Xen-changelog] [xen-unstable] [IA64] Create NVRAM save directory



# HG changeset patch
# User Alex Williamson <alex.williamson@xxxxxx>
# Date 1181921109 21600
# Node ID 33cc64dcaead095d4f8115a5b7f8565f5becaf1c
# Parent  1623f5f5094f4bc41be0d67f906b155e3704109c
[IA64] Create NVRAM save directory

If you use RPM to install XEN, the directory(/usr/lib/xen/boot)
will be removed when you un-install the RPM. This patch create
that directory before NVRAM file creating.

Signed-off-by: Zhang Xin <xing.z.zhang@xxxxxxxxx>
---
 tools/libxc/ia64/xc_ia64_hvm_build.c |    2 ++
 1 files changed, 2 insertions(+)

diff -r 1623f5f5094f -r 33cc64dcaead tools/libxc/ia64/xc_ia64_hvm_build.c
--- a/tools/libxc/ia64/xc_ia64_hvm_build.c      Thu Jun 14 15:32:22 2007 -0600
+++ b/tools/libxc/ia64/xc_ia64_hvm_build.c      Fri Jun 15 09:25:09 2007 -0600
@@ -735,6 +735,7 @@ int xc_ia64_save_to_nvram(int xc_handle,
     return 0;
 }
 
+#define NVRAM_DIR       "/usr/lib/xen/boot/"
 #define NVRAM_FILE_PATH        "/usr/lib/xen/boot/nvram_"
 int xc_ia64_nvram_init(int xc_handle, char *dom_name, uint32_t dom)
 {
@@ -749,6 +750,7 @@ int xc_ia64_nvram_init(int xc_handle, ch
         return -1;
     }
     strcpy(nvram_path + file_path_len, dom_name);
+    mkdir(NVRAM_DIR, 0765);
 
     nvram_fd = nvram_init(nvram_path);
     if ( nvram_fd == (uint64_t)(-1) )

_______________________________________________
Xen-changelog mailing list
Xen-changelog@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-changelog


 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.