Skip to content

Commit 9983deb

Browse files
author
Kent Overstreet
committed
Split out irqflags_types.h
We're working on only pulling in type definitions to sched.h whenever possible. Signed-off-by: Kent Overstreet <kent.overstreet@linux.dev>
1 parent 72375a8 commit 9983deb

File tree

3 files changed

+24
-14
lines changed

3 files changed

+24
-14
lines changed

include/linux/irqflags.h

Lines changed: 1 addition & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,7 @@
1212
#ifndef _LINUX_TRACE_IRQFLAGS_H
1313
#define _LINUX_TRACE_IRQFLAGS_H
1414

15+
#include <linux/irqflags_types.h>
1516
#include <linux/typecheck.h>
1617
#include <linux/cleanup.h>
1718
#include <asm/irqflags.h>
@@ -34,19 +35,6 @@
3435

3536
#ifdef CONFIG_TRACE_IRQFLAGS
3637

37-
/* Per-task IRQ trace events information. */
38-
struct irqtrace_events {
39-
unsigned int irq_events;
40-
unsigned long hardirq_enable_ip;
41-
unsigned long hardirq_disable_ip;
42-
unsigned int hardirq_enable_event;
43-
unsigned int hardirq_disable_event;
44-
unsigned long softirq_disable_ip;
45-
unsigned long softirq_enable_ip;
46-
unsigned int softirq_disable_event;
47-
unsigned int softirq_enable_event;
48-
};
49-
5038
DECLARE_PER_CPU(int, hardirqs_enabled);
5139
DECLARE_PER_CPU(int, hardirq_context);
5240

include/linux/irqflags_types.h

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
/* SPDX-License-Identifier: GPL-2.0 */
2+
#ifndef _LINUX_IRQFLAGS_TYPES_H
3+
#define _LINUX_IRQFLAGS_TYPES_H
4+
5+
#ifdef CONFIG_TRACE_IRQFLAGS
6+
7+
/* Per-task IRQ trace events information. */
8+
struct irqtrace_events {
9+
unsigned int irq_events;
10+
unsigned long hardirq_enable_ip;
11+
unsigned long hardirq_disable_ip;
12+
unsigned int hardirq_enable_event;
13+
unsigned int hardirq_disable_event;
14+
unsigned long softirq_disable_ip;
15+
unsigned long softirq_enable_ip;
16+
unsigned int softirq_disable_event;
17+
unsigned int softirq_enable_event;
18+
};
19+
20+
#endif
21+
22+
#endif /* _LINUX_IRQFLAGS_TYPES_H */

include/linux/sched.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,14 +11,14 @@
1111

1212
#include <asm/current.h>
1313

14+
#include <linux/irqflags_types.h>
1415
#include <linux/pid_types.h>
1516
#include <linux/sem.h>
1617
#include <linux/shm.h>
1718
#include <linux/kmsan_types.h>
1819
#include <linux/mutex_types.h>
1920
#include <linux/plist_types.h>
2021
#include <linux/hrtimer_types.h>
21-
#include <linux/irqflags.h>
2222
#include <linux/seccomp.h>
2323
#include <linux/nodemask_types.h>
2424
#include <linux/rcupdate.h>

0 commit comments

Comments
 (0)