From: Daniel Thompson Date: Mon, 27 Oct 2014 18:51:43 +0000 (+0000) Subject: staging: android: logger: Fix log corruption regression X-Git-Tag: omap-for-v3.19/fixes-not-urgent-part1~14^2~8 X-Git-Url: http://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=5fecf3a1e1a0af61eb34eb6976ec9f59cca65d3f;p=pandora-kernel.git staging: android: logger: Fix log corruption regression Since commit cd678fce4280 ("switch logger to ->write_iter()"), any attempt to write to the log results in the log data being written over its own metadata, thus rendering the log unreadable. The problem was first detected when I ran an Android userspace on the v3.18-rc1 kernel. However the issue can also be observed with a non-Android userspace by using echo/cat to write to/from /dev/log_main . This patch resolves the problem by using a temporary to track the status of not-yet-committed writes to the log buffer. Signed-off-by: Daniel Thompson Cc: Al Viro Signed-off-by: Al Viro --- Reading git-diff-tree failed