This source file includes following definitions.
- qnx6_lookup
1
2
3
4
5
6
7
8
9
10
11
12
13
14 #include "qnx6.h"
15
16 struct dentry *qnx6_lookup(struct inode *dir, struct dentry *dentry,
17 unsigned int flags)
18 {
19 unsigned ino;
20 struct page *page;
21 struct inode *foundinode = NULL;
22 const char *name = dentry->d_name.name;
23 int len = dentry->d_name.len;
24
25 if (len > QNX6_LONG_NAME_MAX)
26 return ERR_PTR(-ENAMETOOLONG);
27
28 ino = qnx6_find_entry(len, dir, name, &page);
29 if (ino) {
30 foundinode = qnx6_iget(dir->i_sb, ino);
31 qnx6_put_page(page);
32 if (IS_ERR(foundinode))
33 pr_debug("lookup->iget -> error %ld\n",
34 PTR_ERR(foundinode));
35 } else {
36 pr_debug("%s(): not found %s\n", __func__, name);
37 }
38 return d_splice_alias(foundinode, dentry);
39 }