mirror of
https://github.com/SCST-project/scst.git
synced 2026-05-14 09:11:27 +00:00
scstadmin: Restore support for replacing LUNs that are inside a group
Fixes: a3266ca8f2 ("scstadmin: Remove support for the "new" sysfs interface")
Reported-by: Pavel Klevtsov
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@9172 d57e44dd-8a1f-0410-8b47-8ef2f437770f
This commit is contained in:
@@ -2223,8 +2223,14 @@ sub replaceLun {
|
||||
$o_string =~ s/\s$//;
|
||||
|
||||
my ($path, $cmd);
|
||||
$path = make_path(SCST_TARGETS_DIR(), $driver, $target, SCST_LUNS,
|
||||
SCST_MGMT_IO);
|
||||
if (defined($group)) {
|
||||
$path = make_path(SCST_TARGETS_DIR(), $driver, $target,
|
||||
SCST_GROUPS, $group, SCST_LUNS,
|
||||
SCST_MGMT_IO);
|
||||
} else {
|
||||
$path = make_path(SCST_TARGETS_DIR(), $driver, $target,
|
||||
SCST_LUNS, SCST_MGMT_IO);
|
||||
}
|
||||
$cmd .= "replace $device $lun $o_string";
|
||||
|
||||
my $bytes = - ENOENT;
|
||||
|
||||
Reference in New Issue
Block a user