All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] MIPS: remove CONFIG_MIPS_LD_CAN_LINK_VDSO
@ 2023-01-20  6:33 Masahiro Yamada
  2023-01-20 16:08 ` Nathan Chancellor
                   ` (2 more replies)
  0 siblings, 3 replies; 4+ messages in thread
From: Masahiro Yamada @ 2023-01-20  6:33 UTC (permalink / raw)
  To: Thomas Bogendoerfer, linux-mips
  Cc: linux-kernel, Nathan Chancellor, Masahiro Yamada

Given commit e4412739472b ("Documentation: raise minimum supported
version of binutils to 2.25"), CONFIG_MIPS_LD_CAN_LINK_VDSO is always
'y'.

Signed-off-by: Masahiro Yamada <masahiroy@kernel.org>
---

 arch/mips/vdso/Kconfig  | 14 +-------------
 arch/mips/vdso/Makefile |  3 ---
 2 files changed, 1 insertion(+), 16 deletions(-)

diff --git a/arch/mips/vdso/Kconfig b/arch/mips/vdso/Kconfig
index a665f6108cb5..70140248da72 100644
--- a/arch/mips/vdso/Kconfig
+++ b/arch/mips/vdso/Kconfig
@@ -1,18 +1,6 @@
-# For the pre-R6 code in arch/mips/vdso/vdso.h for locating
-# the base address of VDSO, the linker will emit a R_MIPS_PC32
-# relocation in binutils > 2.25 but it will fail with older versions
-# because that relocation is not supported for that symbol. As a result
-# of which we are forced to disable the VDSO symbols when building
-# with < 2.25 binutils on pre-R6 kernels. For more references on why we
-# can't use other methods to get the base address of VDSO please refer to
-# the comments on that file.
-#
 # GCC (at least up to version 9.2) appears to emit function calls that make use
 # of the GOT when targeting microMIPS, which we can't use in the VDSO due to
 # the lack of relocations. As such, we disable the VDSO for microMIPS builds.
 
-config MIPS_LD_CAN_LINK_VDSO
-	def_bool LD_VERSION >= 22500 || LD_IS_LLD
-
 config MIPS_DISABLE_VDSO
-	def_bool CPU_MICROMIPS || (!CPU_MIPSR6 && !MIPS_LD_CAN_LINK_VDSO)
+	def_bool CPU_MICROMIPS
diff --git a/arch/mips/vdso/Makefile b/arch/mips/vdso/Makefile
index 1f7d5c6c10b0..18af9474ed0e 100644
--- a/arch/mips/vdso/Makefile
+++ b/arch/mips/vdso/Makefile
@@ -52,9 +52,6 @@ endif
 CFLAGS_REMOVE_vgettimeofday.o = $(CC_FLAGS_FTRACE)
 
 ifdef CONFIG_MIPS_DISABLE_VDSO
-  ifndef CONFIG_MIPS_LD_CAN_LINK_VDSO
-    $(warning MIPS VDSO requires binutils >= 2.25)
-  endif
   obj-vdso-y := $(filter-out vgettimeofday.o, $(obj-vdso-y))
 endif
 
-- 
2.34.1


^ permalink raw reply related	[flat|nested] 4+ messages in thread

* Re: [PATCH] MIPS: remove CONFIG_MIPS_LD_CAN_LINK_VDSO
  2023-01-20  6:33 [PATCH] MIPS: remove CONFIG_MIPS_LD_CAN_LINK_VDSO Masahiro Yamada
@ 2023-01-20 16:08 ` Nathan Chancellor
  2023-01-26 18:55 ` Philippe Mathieu-Daudé
  2023-01-27 16:28 ` Thomas Bogendoerfer
  2 siblings, 0 replies; 4+ messages in thread
From: Nathan Chancellor @ 2023-01-20 16:08 UTC (permalink / raw)
  To: Masahiro Yamada; +Cc: Thomas Bogendoerfer, linux-mips, linux-kernel

On Fri, Jan 20, 2023 at 03:33:51PM +0900, Masahiro Yamada wrote:
> Given commit e4412739472b ("Documentation: raise minimum supported
> version of binutils to 2.25"), CONFIG_MIPS_LD_CAN_LINK_VDSO is always
> 'y'.
> 
> Signed-off-by: Masahiro Yamada <masahiroy@kernel.org>

Thanks for the patch!

Reviewed-by: Nathan Chancellor <nathan@kernel.org>

> ---
> 
>  arch/mips/vdso/Kconfig  | 14 +-------------
>  arch/mips/vdso/Makefile |  3 ---
>  2 files changed, 1 insertion(+), 16 deletions(-)
> 
> diff --git a/arch/mips/vdso/Kconfig b/arch/mips/vdso/Kconfig
> index a665f6108cb5..70140248da72 100644
> --- a/arch/mips/vdso/Kconfig
> +++ b/arch/mips/vdso/Kconfig
> @@ -1,18 +1,6 @@
> -# For the pre-R6 code in arch/mips/vdso/vdso.h for locating
> -# the base address of VDSO, the linker will emit a R_MIPS_PC32
> -# relocation in binutils > 2.25 but it will fail with older versions
> -# because that relocation is not supported for that symbol. As a result
> -# of which we are forced to disable the VDSO symbols when building
> -# with < 2.25 binutils on pre-R6 kernels. For more references on why we
> -# can't use other methods to get the base address of VDSO please refer to
> -# the comments on that file.
> -#
>  # GCC (at least up to version 9.2) appears to emit function calls that make use
>  # of the GOT when targeting microMIPS, which we can't use in the VDSO due to
>  # the lack of relocations. As such, we disable the VDSO for microMIPS builds.
>  
> -config MIPS_LD_CAN_LINK_VDSO
> -	def_bool LD_VERSION >= 22500 || LD_IS_LLD
> -
>  config MIPS_DISABLE_VDSO
> -	def_bool CPU_MICROMIPS || (!CPU_MIPSR6 && !MIPS_LD_CAN_LINK_VDSO)
> +	def_bool CPU_MICROMIPS
> diff --git a/arch/mips/vdso/Makefile b/arch/mips/vdso/Makefile
> index 1f7d5c6c10b0..18af9474ed0e 100644
> --- a/arch/mips/vdso/Makefile
> +++ b/arch/mips/vdso/Makefile
> @@ -52,9 +52,6 @@ endif
>  CFLAGS_REMOVE_vgettimeofday.o = $(CC_FLAGS_FTRACE)
>  
>  ifdef CONFIG_MIPS_DISABLE_VDSO
> -  ifndef CONFIG_MIPS_LD_CAN_LINK_VDSO
> -    $(warning MIPS VDSO requires binutils >= 2.25)
> -  endif
>    obj-vdso-y := $(filter-out vgettimeofday.o, $(obj-vdso-y))
>  endif
>  
> -- 
> 2.34.1
> 

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [PATCH] MIPS: remove CONFIG_MIPS_LD_CAN_LINK_VDSO
  2023-01-20  6:33 [PATCH] MIPS: remove CONFIG_MIPS_LD_CAN_LINK_VDSO Masahiro Yamada
  2023-01-20 16:08 ` Nathan Chancellor
@ 2023-01-26 18:55 ` Philippe Mathieu-Daudé
  2023-01-27 16:28 ` Thomas Bogendoerfer
  2 siblings, 0 replies; 4+ messages in thread
From: Philippe Mathieu-Daudé @ 2023-01-26 18:55 UTC (permalink / raw)
  To: Masahiro Yamada, Thomas Bogendoerfer, linux-mips
  Cc: linux-kernel, Nathan Chancellor

On 20/1/23 07:33, Masahiro Yamada wrote:
> Given commit e4412739472b ("Documentation: raise minimum supported
> version of binutils to 2.25"), CONFIG_MIPS_LD_CAN_LINK_VDSO is always
> 'y'.
> 
> Signed-off-by: Masahiro Yamada <masahiroy@kernel.org>
> ---
> 
>   arch/mips/vdso/Kconfig  | 14 +-------------
>   arch/mips/vdso/Makefile |  3 ---
>   2 files changed, 1 insertion(+), 16 deletions(-)

Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>


^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [PATCH] MIPS: remove CONFIG_MIPS_LD_CAN_LINK_VDSO
  2023-01-20  6:33 [PATCH] MIPS: remove CONFIG_MIPS_LD_CAN_LINK_VDSO Masahiro Yamada
  2023-01-20 16:08 ` Nathan Chancellor
  2023-01-26 18:55 ` Philippe Mathieu-Daudé
@ 2023-01-27 16:28 ` Thomas Bogendoerfer
  2 siblings, 0 replies; 4+ messages in thread
From: Thomas Bogendoerfer @ 2023-01-27 16:28 UTC (permalink / raw)
  To: Masahiro Yamada; +Cc: linux-mips, linux-kernel, Nathan Chancellor

On Fri, Jan 20, 2023 at 03:33:51PM +0900, Masahiro Yamada wrote:
> Given commit e4412739472b ("Documentation: raise minimum supported
> version of binutils to 2.25"), CONFIG_MIPS_LD_CAN_LINK_VDSO is always
> 'y'.
> 
> Signed-off-by: Masahiro Yamada <masahiroy@kernel.org>
> ---
> 
>  arch/mips/vdso/Kconfig  | 14 +-------------
>  arch/mips/vdso/Makefile |  3 ---
>  2 files changed, 1 insertion(+), 16 deletions(-)
> 
> diff --git a/arch/mips/vdso/Kconfig b/arch/mips/vdso/Kconfig
> index a665f6108cb5..70140248da72 100644
> --- a/arch/mips/vdso/Kconfig
> +++ b/arch/mips/vdso/Kconfig
> @@ -1,18 +1,6 @@
> -# For the pre-R6 code in arch/mips/vdso/vdso.h for locating
> -# the base address of VDSO, the linker will emit a R_MIPS_PC32
> -# relocation in binutils > 2.25 but it will fail with older versions
> -# because that relocation is not supported for that symbol. As a result
> -# of which we are forced to disable the VDSO symbols when building
> -# with < 2.25 binutils on pre-R6 kernels. For more references on why we
> -# can't use other methods to get the base address of VDSO please refer to
> -# the comments on that file.
> -#
>  # GCC (at least up to version 9.2) appears to emit function calls that make use
>  # of the GOT when targeting microMIPS, which we can't use in the VDSO due to
>  # the lack of relocations. As such, we disable the VDSO for microMIPS builds.
>  
> -config MIPS_LD_CAN_LINK_VDSO
> -	def_bool LD_VERSION >= 22500 || LD_IS_LLD
> -
>  config MIPS_DISABLE_VDSO
> -	def_bool CPU_MICROMIPS || (!CPU_MIPSR6 && !MIPS_LD_CAN_LINK_VDSO)
> +	def_bool CPU_MICROMIPS
> diff --git a/arch/mips/vdso/Makefile b/arch/mips/vdso/Makefile
> index 1f7d5c6c10b0..18af9474ed0e 100644
> --- a/arch/mips/vdso/Makefile
> +++ b/arch/mips/vdso/Makefile
> @@ -52,9 +52,6 @@ endif
>  CFLAGS_REMOVE_vgettimeofday.o = $(CC_FLAGS_FTRACE)
>  
>  ifdef CONFIG_MIPS_DISABLE_VDSO
> -  ifndef CONFIG_MIPS_LD_CAN_LINK_VDSO
> -    $(warning MIPS VDSO requires binutils >= 2.25)
> -  endif
>    obj-vdso-y := $(filter-out vgettimeofday.o, $(obj-vdso-y))
>  endif
>  
> -- 
> 2.34.1

applied to mips-next.

Thomas.

-- 
Crap can work. Given enough thrust pigs will fly, but it's not necessarily a
good idea.                                                [ RFC1925, 2.3 ]

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2023-01-27 16:29 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-01-20  6:33 [PATCH] MIPS: remove CONFIG_MIPS_LD_CAN_LINK_VDSO Masahiro Yamada
2023-01-20 16:08 ` Nathan Chancellor
2023-01-26 18:55 ` Philippe Mathieu-Daudé
2023-01-27 16:28 ` Thomas Bogendoerfer

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.