#include <linux/fs.h>#include <linux/major.h>#include <linux/root_dev.h>#include <linux/sched.h>Go to the source code of this file.
Defines | |
| #define | SOCKFS_MAGIC 0x534F434B |
| #define | SYSFS_MAGIC 0x62656572 |
| #define | SHM_FS_MAGIC 0x02011994 |
Functions | |
| dentry * | rsbac_lookup_hash (struct qstr *name, struct dentry *base) |
| dentry * | rsbac_lookup_one_len (const char *name, struct dentry *base, int len) |
| super_block * | rsbac_get_super_block (kdev_t kdev) |
| void | FASTCALL (__fput(struct file *)) |
| static int | init_private_file (struct file *filp, struct dentry *dentry, int mode) |
|
|
|
|
|
Definition at line 25 of file fs.h. Referenced by lookup_aci_path_dentry(), and writable(). |
|
|
Definition at line 30 of file fs.h. Referenced by rsbac_mount(), rsbac_umount(), and writable(). |
|
|
|
|
||||||||||||||||
|
Definition at line 49 of file fs.h. Referenced by rsbac_read_open(), and rsbac_write_open(). 00050 {
00051 memset(filp, 0, sizeof(*filp));
00052 filp->f_mode = mode;
00053 atomic_set(&filp->f_count, 1);
00054 filp->f_dentry = dentry;
00055 filp->f_uid = current->fsuid;
00056 filp->f_gid = current->fsgid;
00057 filp->f_op = dentry->d_inode->i_fop;
00058 #if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,2)
00059 filp->f_mapping = dentry->d_inode->i_mapping;
00060 file_ra_state_init(&filp->f_ra, filp->f_mapping);
00061 #endif
00062 if (filp->f_op->open)
00063 return filp->f_op->open(dentry->d_inode, filp);
00064 else
00065 return 0;
00066 }
|
|
|
Definition at line 2071 of file aci_data_structures.c. References device_list_head, lookup_device(), NULL, rsbac_mount(), rsbac_printk(), rsbac_write_sem, and wakeup_auto(). Referenced by lookup_aci_path_dentry(), rsbac_acl_add_to_acl_entry(), rsbac_acl_get_mask(), rsbac_acl_get_rights(), rsbac_acl_get_single_right(), rsbac_acl_get_tlist(), rsbac_acl_remove_acl(), rsbac_acl_remove_acl_entry(), rsbac_acl_remove_from_acl_entry(), rsbac_acl_set_acl_entry(), rsbac_acl_set_mask(), rsbac_adf_request_int(), rsbac_adf_set_attr(), rsbac_auth_add_to_f_capset(), rsbac_auth_clear_f_capset(), rsbac_auth_copy_fp_capset(), rsbac_auth_get_f_caplist(), rsbac_auth_remove_from_f_capset(), rsbac_check_acl(), rsbac_mac_add_to_f_truset(), rsbac_mac_clear_f_truset(), rsbac_mac_copy_fp_truset(), rsbac_mac_get_f_trulist(), rsbac_mac_remove_from_f_truset(), and rsbac_write_open(). 02072 {
02073 struct rsbac_device_list_item_t * device_p;
02074 u_long dflags;
02075 struct super_block * sb_p;
02076
02077 if(RSBAC_IS_AUTO_DEV(kdev))
02078 return NULL;
02079
02080 /* get super_block-pointer */
02081 rsbac_read_lock(&device_list_head.lock, &dflags);
02082 device_p = lookup_device(kdev);
02083 if (!device_p)
02084 {
02085 rsbac_read_unlock(&device_list_head.lock, &dflags);
02086 down(&rsbac_write_sem);
02087 up(&rsbac_write_sem);
02088 #if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,0)
02089 sb_p = user_get_super(kdev);
02090 #else
02091 sb_p = get_super(kdev);
02092 #endif
02093 if(!sb_p)
02094 { /* Wait a second and retry */
02095 DECLARE_WAIT_QUEUE_HEAD(auto_wait);
02096 struct timer_list auto_timer;
02097
02098 rsbac_printk(KERN_INFO
02099 "rsbac_get_super_block(): device %02u:%02u not yet available, sleeping\n",
02100 RSBAC_MAJOR(kdev), RSBAC_MINOR(kdev));
02101 init_timer(&auto_timer);
02102 auto_timer.function = wakeup_auto;
02103 auto_timer.data = (u_long) &auto_wait;
02104 auto_timer.expires = jiffies + HZ;
02105 add_timer(&auto_timer);
02106 interruptible_sleep_on(&auto_wait);
02107
02108 #if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,0)
02109 sb_p = user_get_super(kdev);
02110 #else
02111 sb_p = get_super(kdev);
02112 #endif
02113 }
02114 if(sb_p)
02115 {
02116 device_p = lookup_device(kdev);
02117 if (!device_p)
02118 {
02119 rsbac_printk(KERN_INFO
02120 "rsbac_get_super_block(): auto-mounting device %02u:%02u\n",
02121 RSBAC_MAJOR(kdev), RSBAC_MINOR(kdev));
02122 rsbac_mount(sb_p, NULL);
02123 }
02124 /* free super_block pointer */
02125 drop_super(sb_p);
02126 rsbac_read_lock(&device_list_head.lock, &dflags);
02127 device_p = lookup_device(kdev);
02128 if (!device_p)
02129 {
02130 rsbac_printk(KERN_WARNING
02131 "rsbac_get_super_block(): unknown device %02u:%02u\n",
02132 RSBAC_MAJOR(kdev), RSBAC_MINOR(kdev));
02133 rsbac_read_unlock(&device_list_head.lock, &dflags);
02134 return NULL;
02135 }
02136 }
02137 else
02138 {
02139 return NULL;
02140 }
02141 }
02142 sb_p = device_p->sb_p;
02143 rsbac_read_unlock(&device_list_head.lock, &dflags);
02144 return sb_p;
02145 }
|
|
||||||||||||
|
|
|
||||||||||||||||
|
Referenced by lookup_aci_path_dentry(), rsbac_do_init(), rsbac_read_open(), and rsbac_write_open(). |
1.4.2