1. Mar 07, 2024
    • Michael Ellerman's avatar
      powerpc/83xx: Fix build failure with FPU=n · c2e5d70c
      Michael Ellerman authored
      
      
      Building eg. 83xx/mpc832x_rdb_defconfig with FPU=n, fails with:
      
        arch/powerpc/platforms/83xx/suspend.c: In function 'mpc83xx_suspend_enter':
        arch/powerpc/platforms/83xx/suspend.c:209:17: error: implicit declaration of function 'enable_kernel_fp'
          209 |                 enable_kernel_fp();
      
      Fix it by providing an enable_kernel_fp() stub for FPU=n builds,
      which allows using IS_ENABLED(CONFIG_PPC_FPU) around the call to
      enable_kernel_fp().
      
      Signed-off-by: default avatarMichael Ellerman <mpe@ellerman.id.au>
      Link: https://msgid.link/20240306125853.3714578-2-mpe@ellerman.id.au
      c2e5d70c
    • Michael Ellerman's avatar
      powerpc/64s: Fix get_hugepd_cache_index() build failure · 329105ce
      Michael Ellerman authored
      
      
      With CONFIG_BUG=n, the 64-bit Book3S build fails with:
      
        arch/powerpc/include/asm/book3s/64/pgtable-64k.h: In function 'get_hugepd_cache_index':
        arch/powerpc/include/asm/book3s/64/pgtable-64k.h:51:1: error: no return statement in function returning non-void
      
      Currently the body of the function is just BUG(), so when CONFIG_BUG=n
      it is an empty function, leading to the error.
      
      get_hugepd_cache_index() should never be called, the only call is behind
      an is_hugepd() check, which is always false for this configuration.
      
      Instead mark it as always inline, and change the BUG() to BUILD_BUG().
      That should allow the compiler to see that the function is never called,
      and therefore that it never returns, fixing the build error.
      
      Signed-off-by: default avatarMichael Ellerman <mpe@ellerman.id.au>
      Link: https://msgid.link/20240306125853.3714578-1-mpe@ellerman.id.au
      329105ce
  2. Mar 06, 2024
  3. Mar 03, 2024
  4. Feb 22, 2024