mirror of
https://github.com/raspberrypi/linux.git
synced 2025-12-25 19:42:19 +00:00
MIPS: Octeon: Allow CVMSEG to be disabled
Don't include cvmseg states into thread_status when CONFIG_CAVIUM_OCTEON_CVMSEG_SIZE is not defined or 0. Fix compile for kernel without this feature. Signed-off-by: Jiaxun Yang <jiaxun.yang@flygoat.com> Signed-off-by: Thomas Bogendoerfer <tsbogend@alpha.franken.de>
This commit is contained in:
committed by
Thomas Bogendoerfer
parent
6e90049162
commit
b6007ff809
@@ -202,11 +202,13 @@ struct octeon_cop2_state {
|
||||
#define COP2_INIT \
|
||||
.cp2 = {0,},
|
||||
|
||||
#if defined(CONFIG_CAVIUM_OCTEON_CVMSEG_SIZE) && \
|
||||
CONFIG_CAVIUM_OCTEON_CVMSEG_SIZE > 0
|
||||
struct octeon_cvmseg_state {
|
||||
unsigned long cvmseg[CONFIG_CAVIUM_OCTEON_CVMSEG_SIZE]
|
||||
[cpu_dcache_line_size() / sizeof(unsigned long)];
|
||||
};
|
||||
|
||||
#endif
|
||||
#else
|
||||
#define COP2_INIT
|
||||
#endif
|
||||
@@ -263,7 +265,10 @@ struct thread_struct {
|
||||
unsigned long trap_nr;
|
||||
#ifdef CONFIG_CPU_CAVIUM_OCTEON
|
||||
struct octeon_cop2_state cp2 __attribute__ ((__aligned__(128)));
|
||||
#if defined(CONFIG_CAVIUM_OCTEON_CVMSEG_SIZE) && \
|
||||
CONFIG_CAVIUM_OCTEON_CVMSEG_SIZE > 0
|
||||
struct octeon_cvmseg_state cvmseg __attribute__ ((__aligned__(128)));
|
||||
#endif
|
||||
#endif
|
||||
struct mips_abi *abi;
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user