Skip to content

Commit

Permalink
s390/sclp_sdias: Add missing break and "fall through"
Browse files Browse the repository at this point in the history
If the last block of the HSA is read, EVSTATE_ALL_STORED is returned
by SCLP. Because of a missing break in the switch statement two trace
entries are written in this case: "all stored" and "part stored".

This patch adds the missing break and also adds a "fall through"
comment to improve the readability.

Signed-off-by: Michael Holzheu <holzheu@linux.vnet.ibm.com>
Reported-by: David A Gilbert <DavidAGilbert@uk.ibm.com>
Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
  • Loading branch information
Michael Holzheu authored and Martin Schwidefsky committed Aug 8, 2012
1 parent d050351 commit e206d3d
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions drivers/s390/char/sclp_sdias.c
Original file line number Diff line number Diff line change
Expand Up @@ -242,11 +242,13 @@ int sclp_sdias_copy(void *dest, int start_blk, int nr_blks)
switch (sdias_evbuf.event_status) {
case EVSTATE_ALL_STORED:
TRACE("all stored\n");
break;
case EVSTATE_PART_STORED:
TRACE("part stored: %i\n", sdias_evbuf.blk_cnt);
break;
case EVSTATE_NO_DATA:
TRACE("no data\n");
/* fall through */
default:
pr_err("Error from SCLP while copying hsa. "
"Event status = %x\n",
Expand Down

0 comments on commit e206d3d

Please sign in to comment.