lib/raid/raid6/Makefile

Source file repositories/reference/linux-study-clean/lib/raid/raid6/Makefile

File Facts

System
Linux kernel
Corpus path
lib/raid/raid6/Makefile
Extension
[no extension]
Size
4077 bytes
Lines
127
Domain
Kernel Services
Bucket
lib
Inferred role
Kernel Services: build/configuration rule
Status
atlas-only

Why This File Exists

Shared kernel service surface used by multiple subsystems, including helpers, cryptography, virtualization support, and async I/O infrastructure.

Dependency Surface

Detected Declarations

Annotated Snippet

# SPDX-License-Identifier: GPL-2.0

ccflags-y			+= -I $(src)

ifeq ($(CONFIG_RAID6_PQ_ARCH),y)
CFLAGS_algos.o			+= -I$(src)/$(SRCARCH)
endif

obj-$(CONFIG_RAID6_PQ)		+= raid6_pq.o tests/

raid6_pq-y			+= algos.o tables.o

# generic integer generation and recovery implementation
raid6_pq-y			+= int1.o int2.o int4.o int8.o
raid6_pq-y			+= recov.o

# architecture-specific generation and recovery implementations:
raid6_pq-$(CONFIG_KERNEL_MODE_NEON) += arm/neon.o \
				   arm/neon1.o \
				   arm/neon2.o \
				   arm/neon4.o \
				   arm/neon8.o \
				   arm/recov_neon.o \
				   arm/recov_neon_inner.o
raid6_pq-$(CONFIG_LOONGARCH)	+= loongarch/loongarch_simd.o \
				   loongarch/recov_loongarch_simd.o
raid6_pq-$(CONFIG_ALTIVEC)	+= powerpc/altivec1.o \
				   powerpc/altivec2.o \
				   powerpc/altivec4.o \
				   powerpc/altivec8.o \
				   powerpc/vpermxor1.o \
				   powerpc/vpermxor2.o \
				   powerpc/vpermxor4.o \
				   powerpc/vpermxor8.o
raid6_pq-$(CONFIG_RISCV_ISA_V)	+= riscv/rvv.o \
				   riscv/recov_rvv.o
raid6_pq-$(CONFIG_S390)		+= s390/s390vx8.o \
				   s390/recov_s390xc.o
ifeq ($(CONFIG_X86),y)
raid6_pq-$(CONFIG_X86_32)	+= x86/mmx.o \
				   x86/sse1.o
endif
raid6_pq-$(CONFIG_X86)		+= x86/sse2.o \
				   x86/avx2.o \
				   x86/avx512.o \
				   x86/recov_ssse3.o \
				   x86/recov_avx2.o \
				   x86/recov_avx512.o

hostprogs			+= mktables

CFLAGS_arm/neon1.o += $(CC_FLAGS_FPU)
CFLAGS_arm/neon2.o += $(CC_FLAGS_FPU)
CFLAGS_arm/neon4.o += $(CC_FLAGS_FPU)
CFLAGS_arm/neon8.o += $(CC_FLAGS_FPU)
CFLAGS_arm/recov_neon_inner.o += $(CC_FLAGS_FPU)
CFLAGS_REMOVE_arm/neon1.o += $(CC_FLAGS_NO_FPU)
CFLAGS_REMOVE_arm/neon2.o += $(CC_FLAGS_NO_FPU)
CFLAGS_REMOVE_arm/neon4.o += $(CC_FLAGS_NO_FPU)
CFLAGS_REMOVE_arm/neon8.o += $(CC_FLAGS_NO_FPU)
CFLAGS_REMOVE_arm/recov_neon_inner.o += $(CC_FLAGS_NO_FPU)

ifeq ($(CONFIG_ALTIVEC),y)
altivec_flags := -maltivec $(call cc-option,-mabi=altivec)
# Enable <altivec.h>
altivec_flags += -isystem $(shell $(CC) -print-file-name=include)

CFLAGS_powerpc/altivec1.o += $(altivec_flags)
CFLAGS_powerpc/altivec2.o += $(altivec_flags)
CFLAGS_powerpc/altivec4.o += $(altivec_flags)

Annotation

Implementation Notes