diff options
author | Stefan Weinhuber <wein@de.ibm.com> | 2009-12-07 06:51:53 -0500 |
---|---|---|
committer | Martin Schwidefsky <sky@mschwide.boeblingen.de.ibm.com> | 2009-12-07 06:51:35 -0500 |
commit | f4ac1d0255748fe0f8e128a26b1c29490cae5c08 (patch) | |
tree | 2e5e9c31f32194c1042440bce54301e86125f142 /drivers/s390/block/dasd_eckd.c | |
parent | b8ed5dd54895647c2690575aad6f07748c2c618a (diff) |
[S390] dasd: let device initialization wait for LCU setup
The first DASD that is set online for a specific logical control unit
has to do certain setup steps on the storage server to make full use
of it, for example it will enable PAV.
The features and characteristics reported by the storage server will
depend on this setup, so all other devices on the same LCU will need
to wait for the setup to be finished.
Signed-off-by: Stefan Weinhuber <wein@de.ibm.com>
Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
Diffstat (limited to 'drivers/s390/block/dasd_eckd.c')
-rw-r--r-- | drivers/s390/block/dasd_eckd.c | 37 |
1 files changed, 24 insertions, 13 deletions
diff --git a/drivers/s390/block/dasd_eckd.c b/drivers/s390/block/dasd_eckd.c index e38a09b5feae..5819dc02a143 100644 --- a/drivers/s390/block/dasd_eckd.c +++ b/drivers/s390/block/dasd_eckd.c | |||
@@ -1059,7 +1059,7 @@ dasd_eckd_psf_ssc(struct dasd_device *device, int enable_pav) | |||
1059 | /* | 1059 | /* |
1060 | * Valide storage server of current device. | 1060 | * Valide storage server of current device. |
1061 | */ | 1061 | */ |
1062 | static int dasd_eckd_validate_server(struct dasd_device *device) | 1062 | static void dasd_eckd_validate_server(struct dasd_device *device) |
1063 | { | 1063 | { |
1064 | int rc; | 1064 | int rc; |
1065 | struct dasd_eckd_private *private; | 1065 | struct dasd_eckd_private *private; |
@@ -1076,8 +1076,6 @@ static int dasd_eckd_validate_server(struct dasd_device *device) | |||
1076 | private = (struct dasd_eckd_private *) device->private; | 1076 | private = (struct dasd_eckd_private *) device->private; |
1077 | DBF_EVENT_DEVID(DBF_WARNING, device->cdev, "PSF-SSC for SSID %04x " | 1077 | DBF_EVENT_DEVID(DBF_WARNING, device->cdev, "PSF-SSC for SSID %04x " |
1078 | "returned rc=%d", private->uid.ssid, rc); | 1078 | "returned rc=%d", private->uid.ssid, rc); |
1079 | /* RE-Read Configuration Data */ | ||
1080 | return dasd_eckd_read_conf(device); | ||
1081 | } | 1079 | } |
1082 | 1080 | ||
1083 | /* | 1081 | /* |
@@ -1149,12 +1147,21 @@ dasd_eckd_check_characteristics(struct dasd_device *device) | |||
1149 | rc = is_known; | 1147 | rc = is_known; |
1150 | goto out_err2; | 1148 | goto out_err2; |
1151 | } | 1149 | } |
1150 | /* | ||
1151 | * dasd_eckd_vaildate_server is done on the first device that | ||
1152 | * is found for an LCU. All later other devices have to wait | ||
1153 | * for it, so they will read the correct feature codes. | ||
1154 | */ | ||
1152 | if (!is_known) { | 1155 | if (!is_known) { |
1153 | /* new lcu found */ | 1156 | dasd_eckd_validate_server(device); |
1154 | rc = dasd_eckd_validate_server(device); /* will switch pav on */ | 1157 | dasd_alias_lcu_setup_complete(device); |
1155 | if (rc) | 1158 | } else |
1156 | goto out_err3; | 1159 | dasd_alias_wait_for_lcu_setup(device); |
1157 | } | 1160 | |
1161 | /* device may report different configuration data after LCU setup */ | ||
1162 | rc = dasd_eckd_read_conf(device); | ||
1163 | if (rc) | ||
1164 | goto out_err3; | ||
1158 | 1165 | ||
1159 | /* Read Feature Codes */ | 1166 | /* Read Feature Codes */ |
1160 | dasd_eckd_read_features(device); | 1167 | dasd_eckd_read_features(device); |
@@ -3282,11 +3289,15 @@ int dasd_eckd_restore_device(struct dasd_device *device) | |||
3282 | if (is_known < 0) | 3289 | if (is_known < 0) |
3283 | return is_known; | 3290 | return is_known; |
3284 | if (!is_known) { | 3291 | if (!is_known) { |
3285 | /* new lcu found */ | 3292 | dasd_eckd_validate_server(device); |
3286 | rc = dasd_eckd_validate_server(device); /* will switch pav on */ | 3293 | dasd_alias_lcu_setup_complete(device); |
3287 | if (rc) | 3294 | } else |
3288 | goto out_err; | 3295 | dasd_alias_wait_for_lcu_setup(device); |
3289 | } | 3296 | |
3297 | /* RE-Read Configuration Data */ | ||
3298 | rc = dasd_eckd_read_conf(device); | ||
3299 | if (rc) | ||
3300 | goto out_err; | ||
3290 | 3301 | ||
3291 | /* Read Feature Codes */ | 3302 | /* Read Feature Codes */ |
3292 | dasd_eckd_read_features(device); | 3303 | dasd_eckd_read_features(device); |