incremental fixes for "cleanup the RAID6 P/Q library v3"
Hi Andrew,
here are two incremental fixes for above series. They could be folded into "raid6: hide internals" and "raid6: rework registration of optimized algorithms" respectively if desired.
Diffstat:
Makefile | 2 -- x86/pq_arch.h | 8 ++++---- 2 files changed, 4 insertions(+), 6 deletions(-)
PATCH 1/2 raid6: remove duplicate ccflags-y line
This was added by a mismerge when rebasing, remove it.
Signed-off-by Christoph Hellwig <[email protected]>
--- lib/raid/raid6/Makefile | 2 -- 1 file changed, 2 deletions(-)
lib/raid/raid6/Makefile +0 -2
@@ -2,8 +2,6 @@ ccflags-y += -I $(src) -ccflags-y += -I $(src) - ifeq ($(CONFIG_RAID6_PQ_ARCH),y) CFLAGS_algos.o += -I$(src)/$(SRCARCH) endif
Signature · 1 line
2.53.0
PATCH 2/2 raid6/x86: register avx512 after avx2
In reply to Christoph HellwigThis way non-benchmarks configs still get avx512 if supported.
Signed-off-by Christoph Hellwig <[email protected]>
--- lib/raid/raid6/x86/pq_arch.h | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-)
lib/raid/raid6/x86/pq_arch.h +4 -4
@@ -60,16 +60,16 @@ static inline bool raid6_has_sse1_or_mmxext(void) static __always_inline void __init arch_raid6_init(void) {if (raid6_has_avx2 ()) { +raid6_algo_add (&raid6_avx2x1); +raid6_algo_add (&raid6_avx2x2); +if (IS_ENABLED (CONFIG_X86_64 )) +raid6_algo_add (&raid6_avx2x4);if (raid6_has_avx512 ()) {raid6_algo_add (&raid6_avx512x1);raid6_algo_add (&raid6_avx512x2);if (IS_ENABLED (CONFIG_X86_64 ))raid6_algo_add (&raid6_avx512x4); } -raid6_algo_add (&raid6_avx2x1); -raid6_algo_add (&raid6_avx2x2); -if (IS_ENABLED (CONFIG_X86_64 )) -raid6_algo_add (&raid6_avx2x4); }else if (IS_ENABLED (CONFIG_X86_64 ) ||raid6_has_sse2 ()) {/* x86_64 can assume SSE2 as baseline */ raid6_algo_add (&raid6_sse2x1);
Signature · 1 line
2.53.0