mirror of
https://github.com/ibm-s390-linux/s390-tools.git
synced 2026-08-05 02:14:52 +00:00
zipl/src: Fix problems when target parameters are specified by user
Steps to reproduce: Prepare some target disk for IPL, specifying its parameters via zipl "target options", and an image IMAGE_NAME located on another disk. Don't specify "-a" option. Actual result: Installation succeeded (resulting in unbootable setup) Expected result: "Error: Could not add image file 'IMAGE_NAME': File is not on target device" The problem is in incorrect evaluation of device number(dev_t) where the image is located by the function add_component_file_range() in case when target parameters are specified by user. Fixup: Retrieve info of the underlying disk without any user hints, passing zeroed structure job_target_data Signed-off-by: Eduard Shishkin <edward6@linux.ibm.com> Reviewed-by: Stefan Haberland <sth@linux.ibm.com> Signed-off-by: Steffen Eiden <seiden@linux.ibm.com>
This commit is contained in:
committed by
Steffen Eiden
parent
76aaf3d4a8
commit
fb0b6263d1
@@ -152,6 +152,7 @@ static inline int target_parameters_are_set(struct job_target_data *td)
|
||||
|
||||
int job_get(int argc, char* argv[], struct job_data** data);
|
||||
void job_free(struct job_data* job);
|
||||
void free_target_data(struct job_target_data *td);
|
||||
int type_from_target(char *target, disk_type_t *type);
|
||||
int check_job_dump_images(struct job_dump_data* dump, char* name);
|
||||
int check_job_images_ngdump(struct job_dump_data* dump, char* name);
|
||||
|
||||
Reference in New Issue
Block a user