diff options
| author | Thomas Zimmermann <tzimmermann@suse.de> | 2024-09-30 10:50:54 +0200 |
|---|---|---|
| committer | Thomas Zimmermann <tzimmermann@suse.de> | 2024-09-30 10:50:54 +0200 |
| commit | 2dd0ef5d951e9b565ddb324fe26c531b6a40bf82 (patch) | |
| tree | b24f5029eaa4cea229163c14549f571499c36fde /tools/testing/shared/linux/preempt.h | |
| parent | 15499749fbb864cc0737bc8ecaf0e28a6b6d62dd (diff) | |
| parent | 9852d85ec9d492ebef56dc5f229416c925758edc (diff) | |
Merge drm/drm-next into drm-misc-next
Get drm-misc-next to up v6.12-rc1.
Signed-off-by: Thomas Zimmermann <tzimmermann@suse.de>
Diffstat (limited to 'tools/testing/shared/linux/preempt.h')
| -rw-r--r-- | tools/testing/shared/linux/preempt.h | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/tools/testing/shared/linux/preempt.h b/tools/testing/shared/linux/preempt.h new file mode 100644 index 000000000000..edb10302b903 --- /dev/null +++ b/tools/testing/shared/linux/preempt.h @@ -0,0 +1,15 @@ +/* SPDX-License-Identifier: GPL-2.0 */ +#ifndef __LINUX_PREEMPT_H +#define __LINUX_PREEMPT_H + +extern int preempt_count; + +#define preempt_disable() uatomic_inc(&preempt_count) +#define preempt_enable() uatomic_dec(&preempt_count) + +static inline int in_interrupt(void) +{ + return 0; +} + +#endif /* __LINUX_PREEMPT_H */ |
