]> git.baikalelectronics.ru Git - kernel.git/commit
[IA64] use snprintf() on features field of /proc/cpuinfo
authorAron Griffis <aron@hp.com>
Mon, 5 Feb 2007 21:54:31 +0000 (13:54 -0800)
committerTony Luck <tony.luck@intel.com>
Mon, 5 Feb 2007 21:54:31 +0000 (13:54 -0800)
commit7d69deda3634b055510ab4685180c978db5fa92b
treeaf9c668674721573f8053856dafc5020fd443fb6
parent4dc74b4539aa32f9b81f9ba3be290f4985e4ec59
[IA64] use snprintf() on features field of /proc/cpuinfo

Some patches have turned up on xen-devel recently to convert strcpy()
to safer alternatives and so forth.  While reviewing those patches
I noticed that the features string building could be cleaned up.

This patch uses snprintf() instead of strcpy() and direct character
pointer manipulation.  It makes the features string building safe and
gets rid of the special case for features output in show_cpuinfo()

Additionally I removed the (int) cast of ARRAY_SIZE, which seems to
serve no purpose.

Signed-off-by: Aron Griffis <aron@hp.com>
Signed-off-by: Tony Luck <tony.luck@intel.com>
arch/ia64/kernel/setup.c