[syslinux:master] hdt: Dumping HDT

syslinux-bot for Erwan Velu erwanaliasr1 at gmail.com
Mon Apr 25 15:28:52 PDT 2011


Commit-ID:  e84e864a207164e78c2a23a92268b9dca389d6ee
Gitweb:     http://syslinux.zytor.com/commit/e84e864a207164e78c2a23a92268b9dca389d6ee
Author:     Erwan Velu <erwanaliasr1 at gmail.com>
AuthorDate: Mon, 11 Apr 2011 20:32:27 +0200
Committer:  Erwan Velu <erwanaliasr1 at gmail.com>
CommitDate: Mon, 11 Apr 2011 20:32:27 +0200

hdt: Dumping HDT

HDT information is now dumped in the 'hdt' file


---
 com32/hdt/{hdt-dump-syslinux.c => hdt-dump-hdt.c} |   21 ++++++++++++++-------
 com32/hdt/hdt-dump.c                              |    1 +
 com32/hdt/hdt-dump.h                              |    1 +
 3 files changed, 16 insertions(+), 7 deletions(-)

diff --git a/com32/hdt/hdt-dump-syslinux.c b/com32/hdt/hdt-dump-hdt.c
similarity index 73%
copy from com32/hdt/hdt-dump-syslinux.c
copy to com32/hdt/hdt-dump-hdt.c
index 7cef925..d081ebd 100644
--- a/com32/hdt/hdt-dump-syslinux.c
+++ b/com32/hdt/hdt-dump-hdt.c
@@ -30,14 +30,21 @@
 #include "hdt-dump.h"
 #include <syslinux/config.h>
 
-void dump_syslinux(struct s_hardware *hardware, ZZJSON_CONFIG *config, ZZJSON **item) {
+void dump_hdt(struct s_hardware *hardware, ZZJSON_CONFIG *config, ZZJSON **item) {
 
+	(void) hardware;
 	CREATE_NEW_OBJECT;
-	add_hs(syslinux_fs);
-	add_hs(sv->version_string);
-	add_hi(sv->version);
-	add_hi(sv->max_api);
-	add_hs(sv->copyright_string);
+	add_s("hdt.product_name",PRODUCT_NAME);
+	add_s("hdt.version",VERSION);
+	add_s("hdt.code_name",CODENAME);
+	add_s("hdt.author", AUTHOR);
+	add_s("hdt.core_developer", CORE_DEVELOPER);
+	char *contributors[NB_CONTRIBUTORS] = CONTRIBUTORS;
+	for (int c = 0; c < NB_CONTRIBUTORS; c++) {
+		add_s("hdt.contributor", contributors[c]);
+	}
+	add_s("hdt.website",WEBSITE_URL);
+	add_s("hdt.irc_channel",IRC_CHANNEL);
 	FLUSH_OBJECT
-	to_cpio("syslinux");
+	to_cpio("hdt");
 }
diff --git a/com32/hdt/hdt-dump.c b/com32/hdt/hdt-dump.c
index ae531e2..886c224 100644
--- a/com32/hdt/hdt-dump.c
+++ b/com32/hdt/hdt-dump.c
@@ -132,6 +132,7 @@ void dump(struct s_hardware *hardware)
     dump_pci(hardware, &config, &json);
     dump_acpi(hardware, &config, &json);
     dump_kernel(hardware, &config, &json);
+    dump_hdt(hardware, &config, &json);
 
     /* We close & flush the file to send */
     cpio_close(upload);
diff --git a/com32/hdt/hdt-dump.h b/com32/hdt/hdt-dump.h
index a867368..5ae8c65 100644
--- a/com32/hdt/hdt-dump.h
+++ b/com32/hdt/hdt-dump.h
@@ -81,3 +81,4 @@ void dump_memory(struct s_hardware *hardware, ZZJSON_CONFIG *config, ZZJSON **it
 void dump_pci(struct s_hardware *hardware, ZZJSON_CONFIG *config, ZZJSON **item);
 void dump_acpi(struct s_hardware *hardware, ZZJSON_CONFIG *config, ZZJSON **item);
 void dump_kernel(struct s_hardware *hardware, ZZJSON_CONFIG *config, ZZJSON **item);
+void dump_hdt(struct s_hardware *hardware, ZZJSON_CONFIG *config, ZZJSON **item);



More information about the Syslinux-commits mailing list