]> git.itanic.dy.fi Git - linux-stable/commitdiff
s390/dasd: move dasd_eckd_read_fc_security
authorStefan Haberland <sth@linux.ibm.com>
Wed, 20 Oct 2021 11:51:21 +0000 (13:51 +0200)
committerJens Axboe <axboe@kernel.dk>
Wed, 20 Oct 2021 14:10:42 +0000 (08:10 -0600)
dasd_eckd_read_conf is called multiple times during device setup but the
fc_security feature needs to be read only once. So move it into the calling
function.

Signed-off-by: Stefan Haberland <sth@linux.ibm.com>
Reviewed-by: Jan Hoeppner <hoeppner@linux.ibm.com>
Link: https://lore.kernel.org/r/20211020115124.1735254-5-sth@linux.ibm.com
Signed-off-by: Jens Axboe <axboe@kernel.dk>
drivers/s390/block/dasd_eckd.c

index f6ff26472936d9f793d2cfa6a1bc3aa3ec381712..248006291c29a1091a6e36035e13d0e494c3f2d5 100644 (file)
@@ -1189,8 +1189,6 @@ static int dasd_eckd_read_conf(struct dasd_device *device)
                }
        }
 
-       dasd_eckd_read_fc_security(device);
-
        return path_err;
 }
 
@@ -2101,6 +2099,7 @@ dasd_eckd_check_characteristics(struct dasd_device *device)
        if (rc)
                goto out_err3;
 
+       dasd_eckd_read_fc_security(device);
        dasd_path_create_kobjects(device);
 
        /* Read Feature Codes */
@@ -5788,6 +5787,8 @@ static int dasd_eckd_reload_device(struct dasd_device *device)
        if (rc)
                goto out_err;
 
+       dasd_eckd_read_fc_security(device);
+
        rc = dasd_eckd_generate_uid(device);
        if (rc)
                goto out_err;