Change dump_image API
This commit is contained in:
1 parent
10217cd331
commit
3f96851407
4 files changed
+7
-7
No files matched your search
+1
-1
@@ -115,7 +115,7 @@ int local_flash_image(struct image * image) {
|
||||
|
||||
}
|
||||
|
||||
struct image * local_dump_image(enum image_type image) {
|
||||
int local_dump_image(enum image_type image, const char * file) {
|
||||
|
||||
/* kernel on n900:
|
||||
system("nanddump -s 0x000800 -f /var/tmp/zImage /dev/mtd3");
|
||||
|
||||
+1
-1
@@ -27,7 +27,7 @@ int local_init(void);
|
||||
enum device local_get_device(void);
|
||||
|
||||
int local_flash_image(struct image * image);
|
||||
struct image * local_dump_image(enum image_type image);
|
||||
int local_dump_image(enum image_type image, const char * file);
|
||||
int local_check_badblocks(const char * device);
|
||||
|
||||
int local_reboot_device(void);
|
||||
|
||||
+4
-4
@@ -188,17 +188,17 @@ int dev_flash_image(struct device_info * dev, struct image * image) {
|
||||
|
||||
}
|
||||
|
||||
struct image * dev_dump_image(struct device_info * dev, enum image_type image) {
|
||||
int dev_dump_image(struct device_info * dev, enum image_type image, const char * file) {
|
||||
|
||||
if ( dev->method == METHOD_LOCAL )
|
||||
return local_dump_image(image);
|
||||
return local_dump_image(image, file);
|
||||
|
||||
if ( dev->method == METHOD_USB ) {
|
||||
ERROR("Dump image via USB is not supported");
|
||||
return NULL;
|
||||
return -1;
|
||||
}
|
||||
|
||||
return NULL;
|
||||
return -1;
|
||||
|
||||
}
|
||||
|
||||
|
||||
+1
-1
@@ -44,7 +44,7 @@ enum device dev_get_device(struct device_info * dev);
|
||||
int dev_cold_flash_images(struct device_info * dev, struct image * x2nd, struct image * secondary);
|
||||
int dev_load_image(struct device_info * dev, struct image * image);
|
||||
int dev_flash_image(struct device_info * dev, struct image * image);
|
||||
struct image * dev_dump_image(struct device_info * dev, enum image_type image);
|
||||
int dev_dump_image(struct device_info * dev, enum image_type image, const char * file);
|
||||
int dev_check_badblocks(struct device_info * dev, const char * device);
|
||||
|
||||
int dev_boot_device(struct device_info * dev, const char * cmdline);
|
||||
|
||||
Reference in new issue
Block a user