swapfile.c (3aef83e0ef1ffb8ea3bea97be46821a45c952173) | swapfile.c (15ad7cdcfd76450d4beebc789ec646664238184d) |
---|---|
1/* 2 * linux/mm/swapfile.c 3 * 4 * Copyright (C) 1991, 1992, 1993, 1994 Linus Torvalds 5 * Swap reorganised 29.12.95, Stephen Tweedie 6 */ 7 8#include <linux/mm.h> --- 1354 unchanged lines hidden (view full) --- 1363 S_ISBLK(file->f_dentry->d_inode->i_mode) ? 1364 "partition" : "file\t", 1365 ptr->pages << (PAGE_SHIFT - 10), 1366 ptr->inuse_pages << (PAGE_SHIFT - 10), 1367 ptr->prio); 1368 return 0; 1369} 1370 | 1/* 2 * linux/mm/swapfile.c 3 * 4 * Copyright (C) 1991, 1992, 1993, 1994 Linus Torvalds 5 * Swap reorganised 29.12.95, Stephen Tweedie 6 */ 7 8#include <linux/mm.h> --- 1354 unchanged lines hidden (view full) --- 1363 S_ISBLK(file->f_dentry->d_inode->i_mode) ? 1364 "partition" : "file\t", 1365 ptr->pages << (PAGE_SHIFT - 10), 1366 ptr->inuse_pages << (PAGE_SHIFT - 10), 1367 ptr->prio); 1368 return 0; 1369} 1370 |
1371static struct seq_operations swaps_op = { | 1371static const struct seq_operations swaps_op = { |
1372 .start = swap_start, 1373 .next = swap_next, 1374 .stop = swap_stop, 1375 .show = swap_show 1376}; 1377 1378static int swaps_open(struct inode *inode, struct file *file) 1379{ 1380 return seq_open(file, &swaps_op); 1381} 1382 | 1372 .start = swap_start, 1373 .next = swap_next, 1374 .stop = swap_stop, 1375 .show = swap_show 1376}; 1377 1378static int swaps_open(struct inode *inode, struct file *file) 1379{ 1380 return seq_open(file, &swaps_op); 1381} 1382 |
1383static struct file_operations proc_swaps_operations = { | 1383static const struct file_operations proc_swaps_operations = { |
1384 .open = swaps_open, 1385 .read = seq_read, 1386 .llseek = seq_lseek, 1387 .release = seq_release, 1388}; 1389 1390static int __init procswaps_init(void) 1391{ --- 404 unchanged lines hidden --- | 1384 .open = swaps_open, 1385 .read = seq_read, 1386 .llseek = seq_lseek, 1387 .release = seq_release, 1388}; 1389 1390static int __init procswaps_init(void) 1391{ --- 404 unchanged lines hidden --- |