* Added -n flag to do not write to disk or flash (simulation)

* Added -S flag to specify subversion id manually while flashing or dumping
* Fixed support for the last fiasco image
  - Skip paddings
  - More verbose output while parsing FIASCO headers
* Initial implementation of the full direct FIASCO flasher
  - No need to dump manually before flashing
* Some warnings and code cleanup
* Fix building issue
* Add HAVE_GUI directive in config.mk
* Up to version 0.4
This commit is contained in:
pancake committed 2008-12-08 00:21:05 +01:00
1 parent edac98d26e
commit 3d427bfd77
11 files changed
+134 -41

No files matched your search

+11 -9
View File
@@ -19,7 +19,13 @@
#include "main.h"
#include "os.h"
#include <stdio.h>
#include <string.h>
#include <stdlib.h>
#include <signal.h>
#include <sys/types.h>
#include <sys/wait.h>
#include <sys/stat.h>
#if HAVE_SQUEUE
struct squeue_t *q;
@@ -43,23 +49,19 @@ void process_message(char *msg)
printf("[x] (%s)\n", msg);
str = strdup(msg);
arg = strchr(str, ':');
if (c!=NULL) {
if (c!=0) {
arg[0]='\0';
arg = arg +1;
if (!strcmp(str, "flash")) {
char buf[1024];
char *type = fpid_file(arg);
const char *type = fpid_file(arg);
if (type == NULL) {
squeue_push2(p, "error", "Unknown piece format", 1);
} else {
flash_image(arg, type, NULL);
}
} else flash_image(arg, type, NULL);
} else
if (!strcmp(str, "reset")) {
if (reboot_board() == 0) {
squeue_push2(p,"info", "Device reboots", 1);
} else
squeue_push2(p,"error", "Cannot reboot device", 1);
} else squeue_push2(p,"error", "Cannot reboot device", 1);
} else
if (!strcmp(str, "info")) {
get_rd_flags();
@@ -95,7 +97,7 @@ int queue_mode()
pid = dofork();
if (pid) {
wait(pid);
wait(&pid);
return 0;
} else {
p = squeue_open("/tmp/0xFFFF.1", Q_CREAT);