mirror of
https://mirrors.bfsu.edu.cn/git/linux.git
synced 2024-11-27 22:24:11 +08:00
[S390] memory hotplug: only unassign assigned increments
Make sure that only assigned storage increments are unassigned when attaching a storage element. Signed-off-by: Heiko Carstens <heiko.carstens@de.ibm.com> Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
This commit is contained in:
parent
e1202edadb
commit
8adb4ca344
@ -383,8 +383,10 @@ static int sclp_attach_storage(u8 id)
|
||||
switch (sccb->header.response_code) {
|
||||
case 0x0020:
|
||||
set_bit(id, sclp_storage_ids);
|
||||
for (i = 0; i < sccb->assigned; i++)
|
||||
sclp_unassign_storage(sccb->entries[i] >> 16);
|
||||
for (i = 0; i < sccb->assigned; i++) {
|
||||
if (sccb->entries[i])
|
||||
sclp_unassign_storage(sccb->entries[i] >> 16);
|
||||
}
|
||||
break;
|
||||
default:
|
||||
rc = -EIO;
|
||||
|
Loading…
Reference in New Issue
Block a user