]> git.baikalelectronics.ru Git - kernel.git/commit
powerpc/pseries: Use ARRAY_SIZE to iterate over firmware_features_table array
authorNathan Fontenot <nfont@linux.vnet.ibm.com>
Wed, 24 Apr 2013 05:55:08 +0000 (05:55 +0000)
committerBenjamin Herrenschmidt <benh@kernel.crashing.org>
Fri, 26 Apr 2013 06:08:21 +0000 (16:08 +1000)
commit01c8591001b3fa92e7af8880aed682e7c3fa509a
tree0583e4dd038d0463ad8859f5d1ce33578d20ee45
parent0e6d1e38e852d92a238e66d9f5497bffde81f4f2
powerpc/pseries: Use ARRAY_SIZE to iterate over firmware_features_table array

When iterating over the entries in firmware_features_table we only need
to go over the actual number of entries in the array instead of declaring
it to be bigger and checking to make sure there is a valid entry in every
slot.

This patch removes the FIRMWARE_MAX_FEATURES #define and replaces the
array looping with the use of ARRAY_SIZE().

Signed-off-by: Nathan Fontenot <nfont@linux.vnet.ibm.com>
Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
arch/powerpc/include/asm/firmware.h
arch/powerpc/platforms/pseries/firmware.c