]> git.baikalelectronics.ru Git - kernel.git/commit
powerpc/prom: Switch to using structs for ibm_architecture_vec
authorMichael Ellerman <mpe@ellerman.id.au>
Fri, 18 Nov 2016 12:15:42 +0000 (23:15 +1100)
committerMichael Ellerman <mpe@ellerman.id.au>
Wed, 30 Nov 2016 12:19:59 +0000 (23:19 +1100)
commit22f53da00826d5b323a39025bccf7cf720578098
tree73fa1528e64b0145725dc00e4b75f300bb8f7689
parent24075a34671fbff4f28b051210cb82cdcc7c5533
powerpc/prom: Switch to using structs for ibm_architecture_vec

Now that we've defined structures to describe each of the client
architecture vectors, we can use those to construct the value we pass to
firmware.

This avoids the tricks we previously played with the W() macro, allows
us to properly endian annotate fields, and should help to avoid bugs
introduced by failing to have the correct number of zero pad bytes
between fields.

It also means we can avoid hard coding IBM_ARCH_VEC_NRCORES_OFFSET in
order to update the max_cpus value and instead just set it.

Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
arch/powerpc/include/asm/prom.h
arch/powerpc/kernel/prom_init.c