Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 373280
b: refs/heads/master
c: 1553556
h: refs/heads/master
v: v3
  • Loading branch information
Heiko Carstens authored and Martin Schwidefsky committed May 2, 2013
1 parent aeaecf4 commit 85df09b
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 19 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: e5d709bb5fb758281b5a5dbda50823bb68b3a066
refs/heads/master: 1553556067cd759f4fae8410bdaad33f5add78cc
20 changes: 2 additions & 18 deletions trunk/drivers/s390/char/sclp_cmd.c
Original file line number Diff line number Diff line change
Expand Up @@ -345,7 +345,6 @@ struct memory_increment {
struct list_head list;
u16 rn;
int standby;
int usecount;
};

struct assign_storage_sccb {
Expand Down Expand Up @@ -463,21 +462,10 @@ static int sclp_mem_change_state(unsigned long start, unsigned long size,
break;
if (start > istart + rzm - 1)
continue;
if (online) {
if (incr->usecount++)
continue;
/*
* Don't break the loop if one assign fails. Loop may
* be walked again on CANCEL and we can't save
* information if state changed before or not.
* So continue and increase usecount for all increments.
*/
if (online)
rc |= sclp_assign_storage(incr->rn);
} else {
if (--incr->usecount)
continue;
else
sclp_unassign_storage(incr->rn);
}
}
return rc ? -EIO : 0;
}
Expand Down Expand Up @@ -561,8 +549,6 @@ static void __init sclp_add_standby_memory(void)
add_memory_merged(0);
}

#define MEM_SCT_SIZE (1UL << SECTION_SIZE_BITS)

static void __init insert_increment(u16 rn, int standby, int assigned)
{
struct memory_increment *incr, *new_incr;
Expand All @@ -574,8 +560,6 @@ static void __init insert_increment(u16 rn, int standby, int assigned)
return;
new_incr->rn = rn;
new_incr->standby = standby;
if (!standby)
new_incr->usecount = rzm > MEM_SCT_SIZE ? rzm/MEM_SCT_SIZE : 1;
last_rn = 0;
prev = &sclp_mem_list;
list_for_each_entry(incr, &sclp_mem_list, list) {
Expand Down

0 comments on commit 85df09b

Please sign in to comment.