lkml.org 
[lkml]   [2013]   [May]   [9]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
From
Subject[PATCH 13/14] bcon: Fix wrap-around behaviour
Date
This seems to have broken around the introduction of format 1.1.  When
wrapping around, we should increment the wrap counter before writing it
out, not after.

Signed-off-by: Joern Engel <joern@logfs.org>
---
drivers/block/blockconsole.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/block/blockconsole.c b/drivers/block/blockconsole.c
index 01ddbc6..65f8ace 100644
--- a/drivers/block/blockconsole.c
+++ b/drivers/block/blockconsole.c
@@ -229,8 +229,8 @@ static void bcon_advance_write_bytes(struct blockconsole *bc, int bytes)
bc->write_bytes += bytes;
if (bc->write_bytes >= bc->max_bytes) {
bc->write_bytes = 0;
- bcon_init_first_page(bc);
bc->round++;
+ bcon_init_first_page(bc);
}
}

--
1.7.10.4


\
 
 \ /
  Last update: 2013-05-10 01:21    [W:0.163 / U:0.104 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site