diff options
| author | TheSiahxyz <164138827+TheSiahxyz@users.noreply.github.com> | 2025-12-21 16:57:44 +0900 |
|---|---|---|
| committer | TheSiahxyz <164138827+TheSiahxyz@users.noreply.github.com> | 2025-12-21 16:57:44 +0900 |
| commit | 5bb312993960adaa663701391a83f76b81edc60a (patch) | |
| tree | 8838656d0000d24a4c44f5a548b0b36477dbee60 /fedora/.local/bin/htop-vim/linux/IOPriority.h | |
| parent | a861a5fb4c3449abd9d43481c24a90fb91345d75 (diff) | |
created htop-vim/
Diffstat (limited to 'fedora/.local/bin/htop-vim/linux/IOPriority.h')
| -rw-r--r-- | fedora/.local/bin/htop-vim/linux/IOPriority.h | 36 |
1 files changed, 36 insertions, 0 deletions
diff --git a/fedora/.local/bin/htop-vim/linux/IOPriority.h b/fedora/.local/bin/htop-vim/linux/IOPriority.h new file mode 100644 index 0000000..78bc470 --- /dev/null +++ b/fedora/.local/bin/htop-vim/linux/IOPriority.h @@ -0,0 +1,36 @@ +#ifndef HEADER_IOPriority +#define HEADER_IOPriority +/* +htop - IOPriority.h +(C) 2004-2012 Hisham H. Muhammad +Released under the GNU GPLv2+, see the COPYING file +in the source distribution for its full text. + +Based on ionice, +Copyright (C) 2005 Jens Axboe <jens@axboe.dk> +Released under the terms of the GNU General Public License version 2 +*/ + +enum { + IOPRIO_CLASS_NONE, + IOPRIO_CLASS_RT, + IOPRIO_CLASS_BE, + IOPRIO_CLASS_IDLE, +}; + +#define IOPRIO_WHO_PROCESS 1 + +#define IOPRIO_CLASS_SHIFT (13) +#define IOPRIO_PRIO_MASK ((1UL << IOPRIO_CLASS_SHIFT) - 1) + +#define IOPriority_class(ioprio_) ((int) ((ioprio_) >> IOPRIO_CLASS_SHIFT) ) +#define IOPriority_data(ioprio_) ((int) ((ioprio_) & IOPRIO_PRIO_MASK) ) + +typedef int IOPriority; + +#define IOPriority_tuple(class_, data_) (((class_) << IOPRIO_CLASS_SHIFT) | (data_)) + +#define IOPriority_None IOPriority_tuple(IOPRIO_CLASS_NONE, 0) +#define IOPriority_Idle IOPriority_tuple(IOPRIO_CLASS_IDLE, 7) + +#endif |
