Commit 8f8d5745 authored by Max Filippov's avatar Max Filippov

xtensa: replace variant/core.h with asm/core.h

Introduce the header arch/xtensa/include/asm/core.h that provides
definitions for XCHAL macros missing in older xtensa releases. Use this
header instead of variant/core.h
Signed-off-by: default avatarMax Filippov <jcmvbkbc@gmail.com>
parent 8e65986d
/* SPDX-License-Identifier: GPL-2.0 */ /* SPDX-License-Identifier: GPL-2.0 */
#include <variant/core.h> #include <asm/core.h>
#include <asm/regs.h> #include <asm/regs.h>
#include <asm/asmmacro.h> #include <asm/asmmacro.h>
#include <asm/cacheasm.h> #include <asm/cacheasm.h>
......
...@@ -11,7 +11,7 @@ ...@@ -11,7 +11,7 @@
#ifndef _XTENSA_ASMMACRO_H #ifndef _XTENSA_ASMMACRO_H
#define _XTENSA_ASMMACRO_H #define _XTENSA_ASMMACRO_H
#include <variant/core.h> #include <asm/core.h>
/* /*
* Some little helpers for loops. Use zero-overhead-loops * Some little helpers for loops. Use zero-overhead-loops
......
...@@ -11,7 +11,7 @@ ...@@ -11,7 +11,7 @@
#ifndef _XTENSA_CACHE_H #ifndef _XTENSA_CACHE_H
#define _XTENSA_CACHE_H #define _XTENSA_CACHE_H
#include <variant/core.h> #include <asm/core.h>
#define L1_CACHE_SHIFT XCHAL_DCACHE_LINEWIDTH #define L1_CACHE_SHIFT XCHAL_DCACHE_LINEWIDTH
#define L1_CACHE_BYTES XCHAL_DCACHE_LINESIZE #define L1_CACHE_BYTES XCHAL_DCACHE_LINESIZE
......
...@@ -13,7 +13,7 @@ ...@@ -13,7 +13,7 @@
#include <linux/in6.h> #include <linux/in6.h>
#include <linux/uaccess.h> #include <linux/uaccess.h>
#include <variant/core.h> #include <asm/core.h>
/* /*
* computes the checksum of a memory block at buff, length len, * computes the checksum of a memory block at buff, length len,
......
...@@ -12,8 +12,8 @@ ...@@ -12,8 +12,8 @@
#ifndef _XTENSA_COPROCESSOR_H #ifndef _XTENSA_COPROCESSOR_H
#define _XTENSA_COPROCESSOR_H #define _XTENSA_COPROCESSOR_H
#include <variant/core.h>
#include <variant/tie.h> #include <variant/tie.h>
#include <asm/core.h>
#include <asm/types.h> #include <asm/types.h>
#ifdef __ASSEMBLY__ #ifdef __ASSEMBLY__
......
/* SPDX-License-Identifier: GPL-2.0 */
/* Copyright (C) 2019 Cadence Design Systems Inc. */
#ifndef _ASM_XTENSA_CORE_H
#define _ASM_XTENSA_CORE_H
#include <variant/core.h>
#ifndef XCHAL_SPANNING_WAY
#define XCHAL_SPANNING_WAY 0
#endif
#endif
...@@ -33,10 +33,6 @@ ...@@ -33,10 +33,6 @@
#define CA_WRITEBACK (0x4) #define CA_WRITEBACK (0x4)
#endif #endif
#ifndef XCHAL_SPANNING_WAY
#define XCHAL_SPANNING_WAY 0
#endif
#ifdef __ASSEMBLY__ #ifdef __ASSEMBLY__
#define XTENSA_HWVERSION_RC_2009_0 230000 #define XTENSA_HWVERSION_RC_2009_0 230000
......
...@@ -12,7 +12,7 @@ ...@@ -12,7 +12,7 @@
#define _XTENSA_IRQ_H #define _XTENSA_IRQ_H
#include <linux/init.h> #include <linux/init.h>
#include <variant/core.h> #include <asm/core.h>
#ifdef CONFIG_PLATFORM_NR_IRQS #ifdef CONFIG_PLATFORM_NR_IRQS
# define PLATFORM_NR_IRQS CONFIG_PLATFORM_NR_IRQS # define PLATFORM_NR_IRQS CONFIG_PLATFORM_NR_IRQS
......
...@@ -10,7 +10,7 @@ ...@@ -10,7 +10,7 @@
#ifndef _XTENSA_PROCESSOR_H #ifndef _XTENSA_PROCESSOR_H
#define _XTENSA_PROCESSOR_H #define _XTENSA_PROCESSOR_H
#include <variant/core.h> #include <asm/core.h>
#include <linux/compiler.h> #include <linux/compiler.h>
#include <linux/stringify.h> #include <linux/stringify.h>
......
...@@ -80,7 +80,7 @@ struct pt_regs { ...@@ -80,7 +80,7 @@ struct pt_regs {
unsigned long areg[16]; unsigned long areg[16];
}; };
#include <variant/core.h> #include <asm/core.h>
# define arch_has_single_step() (1) # define arch_has_single_step() (1)
# define task_pt_regs(tsk) ((struct pt_regs*) \ # define task_pt_regs(tsk) ((struct pt_regs*) \
......
...@@ -18,7 +18,7 @@ ...@@ -18,7 +18,7 @@
#ifndef _XTENSA_VECTORS_H #ifndef _XTENSA_VECTORS_H
#define _XTENSA_VECTORS_H #define _XTENSA_VECTORS_H
#include <variant/core.h> #include <asm/core.h>
#include <asm/kmem_layout.h> #include <asm/kmem_layout.h>
#if XCHAL_HAVE_PTP_MMU #if XCHAL_HAVE_PTP_MMU
......
...@@ -12,7 +12,7 @@ ...@@ -12,7 +12,7 @@
#include <linux/log2.h> #include <linux/log2.h>
#include <linux/percpu.h> #include <linux/percpu.h>
#include <linux/perf_event.h> #include <linux/perf_event.h>
#include <variant/core.h> #include <asm/core.h>
/* Breakpoint currently in use for each IBREAKA. */ /* Breakpoint currently in use for each IBREAKA. */
static DEFINE_PER_CPU(struct perf_event *, bp_on_reg[XCHAL_NUM_IBREAK]); static DEFINE_PER_CPU(struct perf_event *, bp_on_reg[XCHAL_NUM_IBREAK]);
......
...@@ -18,8 +18,8 @@ ...@@ -18,8 +18,8 @@
#include <asm/page.h> #include <asm/page.h>
#include <asm/thread_info.h> #include <asm/thread_info.h>
#include <asm/core.h>
#include <asm/vectors.h> #include <asm/vectors.h>
#include <variant/core.h>
OUTPUT_ARCH(xtensa) OUTPUT_ARCH(xtensa)
ENTRY(_start) ENTRY(_start)
......
...@@ -16,8 +16,8 @@ ...@@ -16,8 +16,8 @@
#include <linux/errno.h> #include <linux/errno.h>
#include <linux/linkage.h> #include <linux/linkage.h>
#include <variant/core.h>
#include <asm/asmmacro.h> #include <asm/asmmacro.h>
#include <asm/core.h>
/* /*
* computes a partial checksum, e.g. for TCP/UDP fragments * computes a partial checksum, e.g. for TCP/UDP fragments
......
...@@ -10,8 +10,8 @@ ...@@ -10,8 +10,8 @@
*/ */
#include <linux/linkage.h> #include <linux/linkage.h>
#include <variant/core.h>
#include <asm/asmmacro.h> #include <asm/asmmacro.h>
#include <asm/core.h>
/* /*
* void *memcpy(void *dst, const void *src, size_t len); * void *memcpy(void *dst, const void *src, size_t len);
......
...@@ -12,8 +12,8 @@ ...@@ -12,8 +12,8 @@
*/ */
#include <linux/linkage.h> #include <linux/linkage.h>
#include <variant/core.h>
#include <asm/asmmacro.h> #include <asm/asmmacro.h>
#include <asm/core.h>
/* /*
* void *memset(void *dst, int c, size_t length) * void *memset(void *dst, int c, size_t length)
......
...@@ -13,8 +13,8 @@ ...@@ -13,8 +13,8 @@
#include <linux/errno.h> #include <linux/errno.h>
#include <linux/linkage.h> #include <linux/linkage.h>
#include <variant/core.h>
#include <asm/asmmacro.h> #include <asm/asmmacro.h>
#include <asm/core.h>
/* /*
* char *__strncpy_user(char *dst, const char *src, size_t len) * char *__strncpy_user(char *dst, const char *src, size_t len)
......
...@@ -12,8 +12,8 @@ ...@@ -12,8 +12,8 @@
*/ */
#include <linux/linkage.h> #include <linux/linkage.h>
#include <variant/core.h>
#include <asm/asmmacro.h> #include <asm/asmmacro.h>
#include <asm/core.h>
/* /*
* size_t __strnlen_user(const char *s, size_t len) * size_t __strnlen_user(const char *s, size_t len)
......
...@@ -54,8 +54,8 @@ ...@@ -54,8 +54,8 @@
*/ */
#include <linux/linkage.h> #include <linux/linkage.h>
#include <variant/core.h>
#include <asm/asmmacro.h> #include <asm/asmmacro.h>
#include <asm/core.h>
.text .text
ENTRY(__xtensa_copy_user) ENTRY(__xtensa_copy_user)
......
...@@ -15,7 +15,7 @@ ...@@ -15,7 +15,7 @@
#ifndef _XTENSA_XT2000_HARDWARE_H #ifndef _XTENSA_XT2000_HARDWARE_H
#define _XTENSA_XT2000_HARDWARE_H #define _XTENSA_XT2000_HARDWARE_H
#include <variant/core.h> #include <asm/core.h>
/* /*
* On-board components. * On-board components.
......
...@@ -11,7 +11,7 @@ ...@@ -11,7 +11,7 @@
#ifndef _XTENSA_XT2000_SERIAL_H #ifndef _XTENSA_XT2000_SERIAL_H
#define _XTENSA_XT2000_SERIAL_H #define _XTENSA_XT2000_SERIAL_H
#include <variant/core.h> #include <asm/core.h>
#include <asm/io.h> #include <asm/io.h>
/* National-Semi PC16552D DUART: */ /* National-Semi PC16552D DUART: */
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment