OpenCores
URL https://opencores.org/ocsvn/or1k/or1k/trunk

Subversion Repositories or1k

[/] [or1k/] [trunk/] [linux/] [linux-2.4/] [arch/] [alpha/] [kernel/] [check_asm.c] - Blame information for rev 1765

Details | Compare with Previous | View Log

Line No. Rev Author Line
1 1275 phoenix
#include <linux/types.h>
2
#include <linux/stddef.h>
3
#include <linux/sched.h>
4
#include <asm/io.h>
5
 
6
int main()
7
{
8
        printf("#ifndef __ASM_OFFSETS_H__\n#define __ASM_OFFSETS_H__\n");
9
 
10
        printf("#define TASK_STATE %ld\n",
11
               (long)offsetof(struct task_struct, state));
12
        printf("#define TASK_FLAGS %ld\n",
13
               (long)offsetof(struct task_struct, flags));
14
        printf("#define TASK_SIGPENDING %ld\n",
15
               (long)offsetof(struct task_struct, sigpending));
16
        printf("#define TASK_ADDR_LIMIT %ld\n",
17
               (long)offsetof(struct task_struct, addr_limit));
18
        printf("#define TASK_EXEC_DOMAIN %ld\n",
19
               (long)offsetof(struct task_struct, exec_domain));
20
        printf("#define TASK_NEED_RESCHED %ld\n",
21
               (long)offsetof(struct task_struct, need_resched));
22
        printf("#define TASK_SIZE %ld\n", sizeof(struct task_struct));
23
        printf("#define STACK_SIZE %ld\n", sizeof(union task_union));
24
 
25
        printf("#define HAE_CACHE %ld\n",
26
               (long)offsetof(struct alpha_machine_vector, hae_cache));
27
        printf("#define HAE_REG %ld\n",
28
               (long)offsetof(struct alpha_machine_vector, hae_register));
29
 
30
        printf("#endif /* __ASM_OFFSETS_H__ */\n");
31
        return 0;
32
}

powered by: WebSVN 2.1.0

© copyright 1999-2025 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.