Lines Matching refs:file
441 static ssize_t profile_load(struct file *f, const char __user *buf, size_t size, in profile_load()
458 static ssize_t profile_replace(struct file *f, const char __user *buf, in profile_replace()
475 static ssize_t profile_remove(struct file *f, const char __user *buf, in profile_remove()
520 static int ns_revision_release(struct inode *inode, struct file *file) in ns_revision_release() argument
522 struct aa_revision *rev = file->private_data; in ns_revision_release()
532 static ssize_t ns_revision_read(struct file *file, char __user *buf, in ns_revision_read() argument
535 struct aa_revision *rev = file->private_data; in ns_revision_read()
544 if (file->f_flags & O_NONBLOCK) in ns_revision_read()
563 static int ns_revision_open(struct inode *inode, struct file *file) in ns_revision_open() argument
573 file->private_data = rev; in ns_revision_open()
578 static __poll_t ns_revision_poll(struct file *file, poll_table *pt) in ns_revision_poll() argument
580 struct aa_revision *rev = file->private_data; in ns_revision_poll()
585 poll_wait(file, &rev->ns->wait, pt); in ns_revision_poll()
618 if (profile->file.dfa && *match_str == AA_CLASS_FILE) { in profile_query_cb()
619 dfa = profile->file.dfa; in profile_query_cb()
620 state = aa_dfa_match_len(dfa, profile->file.start, in profile_query_cb()
843 static void multi_transaction_set(struct file *file, in multi_transaction_set() argument
852 old = (struct multi_transaction *) file->private_data; in multi_transaction_set()
853 file->private_data = new; in multi_transaction_set()
858 static struct multi_transaction *multi_transaction_new(struct file *file, in multi_transaction_new() argument
877 static ssize_t multi_transaction_read(struct file *file, char __user *buf, in multi_transaction_read() argument
884 t = get_multi_transaction(file->private_data); in multi_transaction_read()
895 static int multi_transaction_release(struct inode *inode, struct file *file) in multi_transaction_release() argument
897 put_multi_transaction(file->private_data); in multi_transaction_release()
932 static ssize_t aa_write_access(struct file *file, const char __user *ubuf, in aa_write_access() argument
941 t = multi_transaction_new(file, ubuf, count); in aa_write_access()
974 multi_transaction_set(file, t, len); in aa_write_access()
1011 static int aa_sfs_seq_open(struct inode *inode, struct file *file) in aa_sfs_seq_open() argument
1013 return single_open(file, aa_sfs_seq_show, inode->i_private); in aa_sfs_seq_open()
1030 static int seq_profile_ ##NAME ##_open(struct inode *inode, struct file *file)\
1032 return seq_profile_open(inode, file, seq_profile_ ##NAME ##_show); \
1043 static int seq_profile_open(struct inode *inode, struct file *file, in seq_profile_open() argument
1047 int error = single_open(file, show, proxy); in seq_profile_open()
1050 file->private_data = NULL; in seq_profile_open()
1057 static int seq_profile_release(struct inode *inode, struct file *file) in seq_profile_release() argument
1059 struct seq_file *seq = (struct seq_file *) file->private_data; in seq_profile_release()
1062 return single_release(inode, file); in seq_profile_release()
1132 static int seq_ns_ ##NAME ##_open(struct inode *inode, struct file *file) \
1134 return single_open(file, seq_ns_ ##NAME ##_show, inode->i_private); \
1208 static int seq_rawdata_ ##NAME ##_open(struct inode *inode, struct file *file)\
1210 return seq_rawdata_open(inode, file, seq_rawdata_ ##NAME ##_show); \
1221 static int seq_rawdata_open(struct inode *inode, struct file *file, in seq_rawdata_open() argument
1231 error = single_open(file, show, data); in seq_rawdata_open()
1233 AA_BUG(file->private_data && in seq_rawdata_open()
1234 ((struct seq_file *)file->private_data)->private); in seq_rawdata_open()
1241 static int seq_rawdata_release(struct inode *inode, struct file *file) in seq_rawdata_release() argument
1243 struct seq_file *seq = (struct seq_file *) file->private_data; in seq_rawdata_release()
1248 return single_release(inode, file); in seq_rawdata_release()
1287 static ssize_t rawdata_read(struct file *file, char __user *buf, size_t size, in rawdata_read() argument
1290 struct aa_loaddata *rawdata = file->private_data; in rawdata_read()
1296 static int rawdata_release(struct inode *inode, struct file *file) in rawdata_release() argument
1298 aa_put_loaddata(file->private_data); in rawdata_release()
1303 static int rawdata_open(struct inode *inode, struct file *file) in rawdata_open() argument
1307 file->private_data = __aa_get_loaddata(inode->i_private); in rawdata_open()
1308 if (!file->private_data) in rawdata_open()
2181 static int profiles_open(struct inode *inode, struct file *file) in profiles_open() argument
2186 return seq_open(file, &aa_sfs_profiles_op); in profiles_open()
2189 static int profiles_release(struct inode *inode, struct file *file) in profiles_release() argument
2191 return seq_release(inode, file); in profiles_release()