mirror of
https://github.com/vivier/EMILE.git
synced 2025-01-30 22:29:54 +00:00
print block info
This commit is contained in:
parent
7d3526ce23
commit
9695ef4eb5
@ -5,6 +5,7 @@ static __attribute__((used)) char* rcsid = "$CVSHeader$";
|
||||
*
|
||||
*/
|
||||
|
||||
#include <stdio.h>
|
||||
#include <sys/types.h>
|
||||
#include <unistd.h>
|
||||
#include <stdlib.h>
|
||||
@ -63,11 +64,14 @@ int emile_first_set_param_scsi(int fd, char *second_name)
|
||||
*count = container->blocks[i].count;
|
||||
if (container->blocks[i].count == 0)
|
||||
break;
|
||||
printf("(%d, %d) ", container->blocks[i].offset,
|
||||
container->blocks[i].count);
|
||||
current -= 4;
|
||||
offset = (long*)(&first[current]);
|
||||
*offset = container->blocks[i].offset;
|
||||
(*second_size) += container->blocks[i].count;
|
||||
}
|
||||
putchar('\n');
|
||||
/* mark end of blocks list */
|
||||
current -= 2;
|
||||
count = (short*)(&first[current]);
|
||||
|
@ -74,9 +74,13 @@ int emile_second_set_kernel_scsi(int fd, char *kernel_name)
|
||||
{
|
||||
if (container->blocks[i].count == 0)
|
||||
break;
|
||||
printf("(%d, %d) ", container->blocks[i].offset,
|
||||
container->blocks[i].count);
|
||||
kernel_image_size += container->blocks[i].count;
|
||||
}
|
||||
putchar('\n');
|
||||
kernel_image_size *= container->block_size;
|
||||
printf("kernel image size: %ld\n", kernel_image_size);
|
||||
|
||||
ret = lseek(fd, container_offset, SEEK_SET);
|
||||
if (ret != container_offset)
|
||||
|
Loading…
x
Reference in New Issue
Block a user