mpic build failure for 7447_hpc defconfig (bisected)

Paul Gortmaker paul.gortmaker at windriver.com
Sat Jan 25 11:47:09 EST 2014


On Wed, Jan 8, 2014 at 5:45 PM, Paul Gortmaker
<paul.gortmaker at windriver.com> wrote:
> Commit 446f6d06fab0b49c61887ecbe8286d6aaa796637 ("powerpc/mpic: Properly
> set default triggers") breaks the mpc7447_hpc_defconfig as follows:
>
>   CC      arch/powerpc/sysdev/mpic.o
> arch/powerpc/sysdev/mpic.c: In function 'mpic_set_irq_type':
> arch/powerpc/sysdev/mpic.c:886:9: error: case label does not reduce to an integer constant
> arch/powerpc/sysdev/mpic.c:890:9: error: case label does not reduce to an integer constant
> arch/powerpc/sysdev/mpic.c:894:9: error: case label does not reduce to an integer constant
> arch/powerpc/sysdev/mpic.c:898:9: error: case label does not reduce to an integer constant
>
> Looking at the cpp output (gcc 4.7.3 from the kernel.org toolchains), I see:
>
>    case mpic->hw_set[MPIC_IDX_VECPRI_SENSE_EDGE] |
>         mpic->hw_set[MPIC_IDX_VECPRI_POLARITY_POSITIVE]:
>
> The pointer into an array appears because CONFIG_MPIC_WEIRD=y is set for
> this thing.
>
> -------------------
>   #ifdef CONFIG_MPIC_WEIRD
>   static u32 mpic_infos[][MPIC_IDX_END] = {
>         [0] = { /* Original OpenPIC compatible MPIC */
>
>   [...]
>
>   #define MPIC_INFO(name) mpic->hw_set[MPIC_IDX_##name]
>
>   #else /* CONFIG_MPIC_WEIRD */
>
>   #define MPIC_INFO(name) MPIC_##name
>
>   #endif /* CONFIG_MPIC_WEIRD */
> -------------------
>
>
> Given it has been broken since 3.4-rc5, is it safe to say MPIC_WEIRD is dead
> and unused?  Or should the case be converted to if/else or similar?  Or were
> other versions of gcc actually able to "see" constant numbers?

Ping.  I'll default to conversion to if/else since I don't see any other
solution that will solve thiis easily.  However I am tempted to delete
the abandonware platforms, if given a choice.  The 3.4 was quite some
time ago, and if nobody cared since then, well ....

P.
--

>
> Paul.
> --
> _______________________________________________
> Linuxppc-dev mailing list
> Linuxppc-dev at lists.ozlabs.org
> https://lists.ozlabs.org/listinfo/linuxppc-dev


More information about the Linuxppc-dev mailing list