diff --git a/drivers/staging/hilog/hilog.c b/drivers/staging/hilog/hilog.c index 4ae6b7bf75ac7bf40d3fbe66aece5d2bb8e61774..b641190431b0d4f10a4bcadad52b17feeafc7828 100644 --- a/drivers/staging/hilog/hilog.c +++ b/drivers/staging/hilog/hilog.c @@ -259,7 +259,7 @@ static void hilog_cover_old_log(size_t buf_len) size_t total_size = buf_len + sizeof(struct hilog_entry); int drop_log_lines = 0; - while (total_size + hilog_dev.size >= HILOG_BUFFER) { + while (total_size + hilog_dev.size > HILOG_BUFFER) { retval = hilog_read_ring_head_buffer((unsigned char *)&header, sizeof(header)); if (retval < 0)