提交 7f32c9c6 编写于 作者: A Anton Blanchard 提交者: Benjamin Herrenschmidt

powerpc: Check RTAS extended log flag before checking length

The spec suggests we should first check the extended log flag before checking
the length field.
Signed-off-by: NAnton Blanchard <anton@samba.org>
Signed-off-by: NBenjamin Herrenschmidt <benh@kernel.crashing.org>
上级 d368514c
......@@ -160,7 +160,7 @@ static int log_rtas_len(char * buf)
/* rtas fixed header */
len = 8;
err = (struct rtas_error_log *)buf;
if (err->extended_log_length) {
if (err->extended && err->extended_log_length) {
/* extended header */
len += err->extended_log_length;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册