summaryrefstree
path: root/kernel/include/linux/harsh.h
blob: 6925f6c66bf8bafc6d8824deaa4dea6e43b583c3 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
#ifndef _HARSH_H
#define _HARSH_H

#define MAX_CORE 16

#include <linux/sched.h>

//#include <linux/uh.h>
/* uH_HARSH Command ID */
enum __HARSH_CMD_ID{
	HARSH_EVENT_INIT = 0x0,
	HARSH_EVENT_START,
	HARSH_EVENT_UNDEF_INST,
	HARSH_EVENT_UNDEF_INST_STATIC = 0x3
};

typedef struct core_info{
	u32 variant;
	u32 part;
	u32 revision;
} core_info_t;

typedef struct harsh_init {
	core_info_t core_info[MAX_CORE];
	u32 n_online_core;
} harsh_init_t;

typedef struct harsh_request {
	u32    instruction;
	u32    core;

/* task information */
	char   comm[TASK_COMM_LEN];
	pid_t  pid;

/* saved user registers - for emulation */
	struct pt_regs *regs;
} harsh_req_t;

enum {
	MIGRATION = 0x0,
	EMULATION,
	INSTRUCTION_ABORT = 0x2
};


#endif //_HARSH_H