提交 754e5f3f 编写于 作者: S Scott Wood 提交者: Paul Mackerras

[POWERPC] wrapper: Rename offset in offset_devp()

fdt_wrapper_create_node passes a variable called offset to offset_devp(),
which uses said parameter to initialize a local variable called offset.

Due to one of the odder aspects of the C language, the result is an
undefined variable, with no error or warning.
Signed-off-by: NScott Wood <scottwood@freescale.com>
Acked-by: NDavid Gibson <david@gibson.dropbear.id.au>
Signed-off-by: NPaul Mackerras <paulus@samba.org>
上级 5c3f5892
......@@ -44,8 +44,8 @@
#define offset_devp(off) \
({ \
int offset = (off); \
check_err(offset) ? NULL : (void *)(offset+1); \
int _offset = (off); \
check_err(_offset) ? NULL : (void *)(_offset+1); \
})
#define devp_offset(devp) (((int)(devp))-1)
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册