I just ran the cppcheck static analysis tool over the source code of the Linux kernel. It said [linux-3.5-rc3/arch/xtensa/kernel/process.c:280]: (warning, inconclusive) Using size of pointer elfregs instead of size of its data. The source code is memset(elfregs, 0, sizeof (elfregs)); Suggest memset(elfregs, 0, sizeof (*elfregs)); might be better code.
A patch referencing this bug report has been merged in Linux v3.5-rc7: commit 688bb4158f64f3af0fe1d13e7642f8c4c402453e Author: Alan Cox <alan@linux.intel.com> Date: Wed Jul 11 14:02:50 2012 -0700 xtensa: fix incorrect memset