blob: 3fb15cc28f1063edba337fca824c979f2f32037c [file] [log] [blame]
The Android Open Source Project1dc9e472009-03-03 19:28:35 -08001/****************************************************************************
2 ****************************************************************************
3 ***
4 *** This header was automatically generated from a Linux kernel header
5 *** of the same name, to make information necessary for userspace to
6 *** call into the kernel available to libc. It contains only constants,
7 *** structures, and macros generated from the original header, and thus,
8 *** contains no copyrightable information.
9 ***
Ben Cheng654325d2012-03-07 21:13:49 -080010 *** To edit the content of this header, modify the corresponding
11 *** source file (e.g. under external/kernel-headers/original/) then
12 *** run bionic/libc/kernel/tools/update_all.py
13 ***
14 *** Any manual change here will be lost the next time this script will
15 *** be run. You've been warned!
16 ***
The Android Open Source Project1dc9e472009-03-03 19:28:35 -080017 ****************************************************************************
18 ****************************************************************************/
19#ifndef _LINUX_SWAP_H
20#define _LINUX_SWAP_H
The Android Open Source Project1dc9e472009-03-03 19:28:35 -080021#include <linux/spinlock.h>
22#include <linux/linkage.h>
Ben Cheng654325d2012-03-07 21:13:49 -080023/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
The Android Open Source Project1dc9e472009-03-03 19:28:35 -080024#include <linux/mmzone.h>
25#include <linux/list.h>
26#include <linux/sched.h>
The Android Open Source Project1dc9e472009-03-03 19:28:35 -080027#include <asm/atomic.h>
Ben Cheng654325d2012-03-07 21:13:49 -080028/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
The Android Open Source Project1dc9e472009-03-03 19:28:35 -080029#include <asm/page.h>
Elliott Hughesc95eb572013-01-29 18:15:55 -080030#define SWAP_FLAG_PREFER 0x8000
The Android Open Source Project1dc9e472009-03-03 19:28:35 -080031#define SWAP_FLAG_PRIO_MASK 0x7fff
32#define SWAP_FLAG_PRIO_SHIFT 0
Ben Cheng654325d2012-03-07 21:13:49 -080033/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
The Android Open Source Project1dc9e472009-03-03 19:28:35 -080034#define MAX_SWAPFILES_SHIFT 5
35#define MAX_SWAPFILES (1 << MAX_SWAPFILES_SHIFT)
Ben Cheng654325d2012-03-07 21:13:49 -080036union swap_header {
37 struct {
38/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
39 char reserved[PAGE_SIZE - 10];
40 char magic[10];
41 } magic;
42 struct {
43/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
44 char bootbits[1024];
45 __u32 version;
46 __u32 last_page;
47 __u32 nr_badpages;
48/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
49 unsigned char sws_uuid[16];
50 unsigned char sws_volume[16];
51 __u32 padding[117];
52 __u32 badpages[1];
53/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
54 } info;
55};
The Android Open Source Project1dc9e472009-03-03 19:28:35 -080056typedef struct {
57 unsigned long val;
Ben Cheng654325d2012-03-07 21:13:49 -080058/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
The Android Open Source Project1dc9e472009-03-03 19:28:35 -080059} swp_entry_t;
The Android Open Source Project1dc9e472009-03-03 19:28:35 -080060struct reclaim_state {
61 unsigned long reclaimed_slab;
62};
Ben Cheng654325d2012-03-07 21:13:49 -080063/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
The Android Open Source Project1dc9e472009-03-03 19:28:35 -080064#endif