]> git.proxmox.com Git - mirror_ubuntu-focal-kernel.git/blame - arch/cris/kernel/asm-offsets.c
Merge remote-tracking branches 'asoc/topic/ac97', 'asoc/topic/ac97-mfd', 'asoc/topic...
[mirror_ubuntu-focal-kernel.git] / arch / cris / kernel / asm-offsets.c
CommitLineData
b2441318 1// SPDX-License-Identifier: GPL-2.0
8e6b4dd1 2#include <linux/kbuild.h>
51533b61
MS
3#include <linux/sched.h>
4#include <asm/thread_info.h>
5
6/*
7 * Generate definitions needed by assembly language modules.
8 * This code generates raw asm output which is post-processed to extract
9 * and format the required data.
10 */
11
0365f707
JN
12#if !defined(CONFIG_ETRAX_ARCH_V10) && !defined(CONFIG_ETRAX_ARCH_V32)
13#error One of ARCH v10 and ARCH v32 must be true!
14#endif
15
51533b61
MS
16int main(void)
17{
18#define ENTRY(entry) DEFINE(PT_ ## entry, offsetof(struct pt_regs, entry))
19 ENTRY(orig_r10);
20 ENTRY(r13);
21 ENTRY(r12);
22 ENTRY(r11);
0365f707
JN
23 ENTRY(r10);
24 ENTRY(r9);
25#ifdef CONFIG_ETRAX_ARCH_V32
51533b61
MS
26 ENTRY(acr);
27 ENTRY(srs);
0365f707
JN
28#endif
29 ENTRY(mof);
30#ifdef CONFIG_ETRAX_ARCH_V10
31 ENTRY(dccr);
32#else
33 ENTRY(ccs);
34#endif
35 ENTRY(srp);
51533b61
MS
36 BLANK();
37#undef ENTRY
38#define ENTRY(entry) DEFINE(TI_ ## entry, offsetof(struct thread_info, entry))
0365f707
JN
39 ENTRY(task);
40 ENTRY(flags);
41 ENTRY(preempt_count);
42 BLANK();
51533b61
MS
43#undef ENTRY
44#define ENTRY(entry) DEFINE(THREAD_ ## entry, offsetof(struct thread_struct, entry))
45 ENTRY(ksp);
0365f707
JN
46 ENTRY(usp);
47#ifdef CONFIG_ETRAX_ARCH_V10
48 ENTRY(dccr);
49#else
50 ENTRY(ccs);
51#endif
52 BLANK();
51533b61
MS
53#undef ENTRY
54#define ENTRY(entry) DEFINE(TASK_ ## entry, offsetof(struct task_struct, entry))
0365f707
JN
55 ENTRY(pid);
56 BLANK();
57 DEFINE(LCLONE_VM, CLONE_VM);
58 DEFINE(LCLONE_UNTRACED, CLONE_UNTRACED);
59 return 0;
51533b61 60}