2016-03-16 04:58:25 +07:00
|
|
|
/*
|
|
|
|
* Copyright 1997-1998 Transmeta Corporation -- All Rights Reserved
|
2005-04-17 05:20:36 +07:00
|
|
|
*
|
|
|
|
* This file is part of the Linux kernel and is made available under
|
|
|
|
* the terms of the GNU General Public License, version 2, or at your
|
|
|
|
* option, any later version, incorporated herein by reference.
|
2016-03-16 04:58:25 +07:00
|
|
|
*/
|
2005-04-17 05:20:36 +07:00
|
|
|
|
|
|
|
#include "autofs_i.h"
|
|
|
|
|
2015-11-17 22:20:54 +07:00
|
|
|
static const char *autofs4_get_link(struct dentry *dentry,
|
2015-12-30 03:58:39 +07:00
|
|
|
struct inode *inode,
|
|
|
|
struct delayed_call *done)
|
2005-04-17 05:20:36 +07:00
|
|
|
{
|
2015-11-17 22:20:54 +07:00
|
|
|
struct autofs_sb_info *sbi;
|
|
|
|
struct autofs_info *ino;
|
2016-03-16 04:58:25 +07:00
|
|
|
|
2015-11-17 22:20:54 +07:00
|
|
|
if (!dentry)
|
|
|
|
return ERR_PTR(-ECHILD);
|
|
|
|
sbi = autofs4_sbi(dentry->d_sb);
|
|
|
|
ino = autofs4_dentry_ino(dentry);
|
2014-01-24 06:55:01 +07:00
|
|
|
if (ino && !autofs4_oz_mode(sbi))
|
|
|
|
ino->last_used = jiffies;
|
2015-05-03 00:32:22 +07:00
|
|
|
return d_inode(dentry)->i_private;
|
2005-04-17 05:20:36 +07:00
|
|
|
}
|
|
|
|
|
2007-02-12 15:55:38 +07:00
|
|
|
const struct inode_operations autofs4_symlink_inode_operations = {
|
2015-11-17 22:20:54 +07:00
|
|
|
.get_link = autofs4_get_link
|
2005-04-17 05:20:36 +07:00
|
|
|
};
|