file.c (c203e45f069af47ca7623e4dcd8c00bfba2722e4) file.c (dda6445e219b5d1fd67e9426ce8d23f8fbfaaf66)
1/**
2 * eCryptfs: Linux filesystem encryption layer
3 *
4 * Copyright (C) 1997-2004 Erez Zadok
5 * Copyright (C) 2001-2004 Stony Brook University
6 * Copyright (C) 2004-2007 International Business Machines Corp.
7 * Author(s): Michael A. Halcrow <mhalcrow@us.ibm.com>
8 * Michael C. Thompson <mcthomps@us.ibm.com>

--- 16 unchanged lines hidden (view full) ---

25
26#include <linux/file.h>
27#include <linux/poll.h>
28#include <linux/mount.h>
29#include <linux/pagemap.h>
30#include <linux/security.h>
31#include <linux/compat.h>
32#include <linux/fs_stack.h>
1/**
2 * eCryptfs: Linux filesystem encryption layer
3 *
4 * Copyright (C) 1997-2004 Erez Zadok
5 * Copyright (C) 2001-2004 Stony Brook University
6 * Copyright (C) 2004-2007 International Business Machines Corp.
7 * Author(s): Michael A. Halcrow <mhalcrow@us.ibm.com>
8 * Michael C. Thompson <mcthomps@us.ibm.com>

--- 16 unchanged lines hidden (view full) ---

25
26#include <linux/file.h>
27#include <linux/poll.h>
28#include <linux/mount.h>
29#include <linux/pagemap.h>
30#include <linux/security.h>
31#include <linux/compat.h>
32#include <linux/fs_stack.h>
33#include <linux/smp_lock.h>
33#include "ecryptfs_kernel.h"
34
35/**
36 * ecryptfs_read_update_atime
37 *
38 * generic_file_read updates the atime of upper layer inode. But, it
39 * doesn't give us a chance to update the atime of the lower layer
40 * inode. This function is a wrapper to generic_file_read. It

--- 231 unchanged lines hidden (view full) ---

272 return rc;
273}
274
275static int ecryptfs_fasync(int fd, struct file *file, int flag)
276{
277 int rc = 0;
278 struct file *lower_file = NULL;
279
34#include "ecryptfs_kernel.h"
35
36/**
37 * ecryptfs_read_update_atime
38 *
39 * generic_file_read updates the atime of upper layer inode. But, it
40 * doesn't give us a chance to update the atime of the lower layer
41 * inode. This function is a wrapper to generic_file_read. It

--- 231 unchanged lines hidden (view full) ---

273 return rc;
274}
275
276static int ecryptfs_fasync(int fd, struct file *file, int flag)
277{
278 int rc = 0;
279 struct file *lower_file = NULL;
280
281 lock_kernel();
280 lower_file = ecryptfs_file_to_lower(file);
281 if (lower_file->f_op && lower_file->f_op->fasync)
282 rc = lower_file->f_op->fasync(fd, lower_file, flag);
282 lower_file = ecryptfs_file_to_lower(file);
283 if (lower_file->f_op && lower_file->f_op->fasync)
284 rc = lower_file->f_op->fasync(fd, lower_file, flag);
285 unlock_kernel();
283 return rc;
284}
285
286static int ecryptfs_ioctl(struct inode *inode, struct file *file,
287 unsigned int cmd, unsigned long arg);
288
289const struct file_operations ecryptfs_dir_fops = {
290 .readdir = ecryptfs_readdir,

--- 43 unchanged lines hidden ---
286 return rc;
287}
288
289static int ecryptfs_ioctl(struct inode *inode, struct file *file,
290 unsigned int cmd, unsigned long arg);
291
292const struct file_operations ecryptfs_dir_fops = {
293 .readdir = ecryptfs_readdir,

--- 43 unchanged lines hidden ---