cve_id stringlengths 13 16 | repo stringclasses 12
values | repo_url stringclasses 10
values | file_path stringlengths 7 62 | function_name stringlengths 4 52 | pa stringlengths 50 341k | pb stringlengths 33 341k | px stringlengths 50 338k | py stringlengths 33 338k | pa_sliced stringlengths 31 44.3k | pb_sliced stringlengths 31 44.6k | px_sliced stringlengths 51 45.8k | py_sliced stringlengths 33 46.9k | patch_sliced stringlengths 0 46.8k |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
CVE-2016-6130 | linux | https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux | drivers/s390/char/sclp_ctl.c | sclp_ctl_ioctl_sccb | static int sclp_ctl_ioctl_sccb(void *user_area) {
struct sclp_ctl_sccb ctl_sccb;
struct sccb_header *sccb;
int rc;
if (copy_from_user(&ctl_sccb, user_area, sizeof(ctl_sccb))) {
return -EFAULT;
}
if (!sclp_ctl_cmdw_supported(ctl_sccb.cmdw)) {
return -EOPNOTSUPP;
}
sccb = (... | static int sclp_ctl_ioctl_sccb(void *user_area) {
struct sclp_ctl_sccb ctl_sccb;
struct sccb_header *sccb;
unsigned long copied;
int rc;
if (copy_from_user(&ctl_sccb, user_area, sizeof(ctl_sccb))) {
return -EFAULT;
}
if (!sclp_ctl_cmdw_supported(ctl_sccb.cmdw)) {
return -EOPN... | static int sclp_ctl_ioctl_sccb(void *user_area) {
struct sclp_ctl_sccb ctl_sccb;
struct sccb_header *sccb;
int rc;
if (copy_from_user(&ctl_sccb, user_area, sizeof(ctl_sccb))) {
return -EFAULT;
}
if (!sclp_ctl_cmdw_supported(ctl_sccb.cmdw)) {
return -EOPNOTSUPP;
}
sccb = (... | static int sclp_ctl_ioctl_sccb(void *user_area) {
struct sclp_ctl_sccb ctl_sccb;
struct sccb_header *sccb;
unsigned long copied;
int rc;
if (copy_from_user(&ctl_sccb, user_area, sizeof(ctl_sccb))) {
return -EFAULT;
}
if (!sclp_ctl_cmdw_supported(ctl_sccb.cmdw)) {
return -EOPN... | static int sclp_ctl_ioctl_sccb(void *user_area) {
struct sccb_header *sccb;
int rc;
sccb = (void *) get_zeroed_page(GFP_KERNEL | GFP_DMA);
if (!sccb) {
return -ENOMEM;
}
if (copy_from_user(sccb, u64_to_uptr(ctl_sccb.sccb), sizeof(*sccb))) {
rc = -EFAULT;
goto out_free;
... | static int sclp_ctl_ioctl_sccb(void *user_area) {
struct sccb_header *sccb;
unsigned long copied;
int rc;
sccb = (void *) get_zeroed_page(GFP_KERNEL | GFP_DMA);
if (!sccb) {
return -ENOMEM;
}
copied = PAGE_SIZE - copy_from_user(sccb, u64_to_uptr(ctl_sccb.sccb), PAGE_SIZE);
if (of... | static int sclp_ctl_ioctl_sccb(void *user_area) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
struct sccb_header *sccb;
int rc;
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
sccb = (void *) get_zeroed_page(GFP_KERNEL | GFP_DMA);
if (!sccb) {
return -ENOMEM;
}
if (copy_from_user... | static int sclp_ctl_ioctl_sccb(void *user_area) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
struct sccb_header *sccb;
unsigned long copied;
int rc;
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
sccb = (void *) get_zeroed_page(GFP_KERNEL | GFP_DMA);
if (!sccb) {
return -ENOMEM;
... | static int sclp_ctl_ioctl_sccb(void *user_area) {
struct sccb_header *sccb;
+ unsigned long copied;
int rc;
sccb = (void *) get_zeroed_page(GFP_KERNEL | GFP_DMA);
if (!sccb) {
return -ENOMEM;
}
- if (copy_from_user(sccb, u64_to_uptr(ctl_sccb.sccb), sizeof(*sccb))) {
+ copied ... |
CVE-2016-6136 | kernel/auditsc.c | audit_log_execve_info | static void audit_log_execve_info(struct audit_context *context, struct audit_buffer **ab) {
int i, len;
size_t len_sent = 0;
const char *p;
char *buf;
p = (const char *)current->mm->arg_start;
audit_log_format(*ab, "argc=%d", context->execve.argc);
buf = kmalloc(MAX_EXECVE_AUDIT_LEN + 1, GF... | static void audit_log_execve_info(struct audit_context *context, struct audit_buffer **ab) {
long len_max;
long len_rem;
long len_full;
long len_buf;
long len_abuf;
long len_tmp;
bool require_data;
bool encode;
unsigned int iter;
unsigned int arg;
char *buf_head;
char *bu... | static void audit_log_execve_info(struct audit_context *context, struct audit_buffer **ab) {
int i, len;
size_t len_sent = 0;
const char *p;
char *buf;
p = (const char *)current->mm->arg_start;
audit_log_format(*ab, "argc=%d", context->execve.argc);
buf = kmalloc(MAX_EXECVE_AUDIT_LEN + 1, GF... | static void audit_log_execve_info(struct audit_context *context, struct audit_buffer **ab) {
long len_max;
long len_rem;
long len_full;
long len_buf;
long len_abuf;
long len_tmp;
bool require_data;
bool encode;
unsigned int iter;
unsigned int arg;
char *buf_head;
char *bu... | static void audit_log_execve_info(struct audit_context *context, struct audit_buffer **ab) {
int i, len;
size_t len_sent = 0;
const char *p;
char *buf;
p = (const char *)current->mm->arg_start;
audit_log_format(*ab, "argc=%d", context->execve.argc);
buf = kmalloc(MAX_EXECVE_AUDIT_LEN + 1, GF... | static void audit_log_execve_info(struct audit_context *context, struct audit_buffer **ab) {
long len_max;
long len_rem;
long len_full;
long len_buf;
long len_abuf;
long len_tmp;
bool require_data;
bool encode;
unsigned int iter;
unsigned int arg;
char *buf_head;
char *bu... | static void audit_log_execve_info(struct audit_context *context, struct audit_buffer **ab) {
int i, len;
size_t len_sent = 0;
const char *p;
char *buf;
p = (const char *)current->mm->arg_start;
audit_log_format(*ab, "argc=%d", context->execve.argc);
buf = kmalloc(MAX_EXECVE_AUDIT_LEN + 1, GF... | static void audit_log_execve_info(struct audit_context *context, struct audit_buffer **ab) {
long len_max;
long len_rem;
long len_full;
long len_buf;
long len_abuf;
long len_tmp;
bool require_data;
bool encode;
unsigned int iter;
unsigned int arg;
char *buf_head;
char *bu... | static void audit_log_execve_info(struct audit_context *context, struct audit_buffer **ab) {
- int i, len;
- size_t len_sent = 0;
- const char *p;
+ long len_max;
+ long len_rem;
+ long len_full;
+ long len_buf;
+ long len_abuf;
+ long len_tmp;
+ bool require_data;
+ bool encode;
+ ... | ||
CVE-2016-6156 | linux | https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux | drivers/platform/chrome/cros_ec_dev.c | ec_device_ioctl_xcmd | static long ec_device_ioctl_xcmd(struct cros_ec_dev *ec, void *arg) {
long ret;
struct cros_ec_command u_cmd;
struct cros_ec_command *s_cmd;
if (copy_from_user(&u_cmd, arg, sizeof(u_cmd))) {
return -EFAULT;
}
s_cmd = kmalloc(sizeof(*s_cmd) + max(u_cmd.outsize, u_cmd.insize), GFP_KERNEL);... | static long ec_device_ioctl_xcmd(struct cros_ec_dev *ec, void *arg) {
long ret;
struct cros_ec_command u_cmd;
struct cros_ec_command *s_cmd;
if (copy_from_user(&u_cmd, arg, sizeof(u_cmd))) {
return -EFAULT;
}
s_cmd = kmalloc(sizeof(*s_cmd) + max(u_cmd.outsize, u_cmd.insize), GFP_KERNEL);... | static long ec_device_ioctl_xcmd(struct cros_ec_dev *ec, void *arg) {
long ret;
struct cros_ec_command u_cmd;
struct cros_ec_command *s_cmd;
if (copy_from_user(&u_cmd, arg, sizeof(u_cmd))) {
return -EFAULT;
}
s_cmd = kmalloc(sizeof(*s_cmd) + max(u_cmd.outsize, u_cmd.insize), GFP_KERNEL);... | static long ec_device_ioctl_xcmd(struct cros_ec_dev *ec, void *arg) {
long ret;
struct cros_ec_command u_cmd;
struct cros_ec_command *s_cmd;
if (copy_from_user(&u_cmd, arg, sizeof(u_cmd))) {
return -EFAULT;
}
s_cmd = kmalloc(sizeof(*s_cmd) + max(u_cmd.outsize, u_cmd.insize), GFP_KERNEL);... | static long ec_device_ioctl_xcmd(struct cros_ec_dev *ec, void *arg) {
if (copy_from_user(&u_cmd, arg, sizeof(u_cmd))) {
return -EFAULT;
}
s_cmd = kmalloc(sizeof(*s_cmd) + max(u_cmd.outsize, u_cmd.insize), GFP_KERNEL);
if (!s_cmd) {
return -ENOMEM;
}
if (copy_from_user(s_cmd, arg,... | static long ec_device_ioctl_xcmd(struct cros_ec_dev *ec, void *arg) {
if (copy_from_user(&u_cmd, arg, sizeof(u_cmd))) {
return -EFAULT;
}
s_cmd = kmalloc(sizeof(*s_cmd) + max(u_cmd.outsize, u_cmd.insize), GFP_KERNEL);
if (!s_cmd) {
return -ENOMEM;
}
if (copy_from_user(s_cmd, arg,... | static long ec_device_ioctl_xcmd(struct cros_ec_dev *ec, void *arg) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
if (copy_from_user(&u_cmd, arg, sizeof(u_cmd))) {
return -EFAULT;
}
s_cmd = kmalloc(sizeof(*s_cmd) + max(u_cmd.outsize, u_cmd.insize), GFP_KERNEL);
if (!s_cmd) {
return... | static long ec_device_ioctl_xcmd(struct cros_ec_dev *ec, void *arg) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
if (copy_from_user(&u_cmd, arg, sizeof(u_cmd))) {
return -EFAULT;
}
s_cmd = kmalloc(sizeof(*s_cmd) + max(u_cmd.outsize, u_cmd.insize), GFP_KERNEL);
if (!s_cmd) {
return... | static long ec_device_ioctl_xcmd(struct cros_ec_dev *ec, void *arg) {
if (copy_from_user(&u_cmd, arg, sizeof(u_cmd))) {
return -EFAULT;
}
s_cmd = kmalloc(sizeof(*s_cmd) + max(u_cmd.outsize, u_cmd.insize), GFP_KERNEL);
if (!s_cmd) {
return -ENOMEM;
}
if (copy_from_user(s_... |
CVE-2016-6197 | linux | https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux | fs/overlayfs/dir.c | ovl_remove_upper | static int ovl_remove_upper(struct dentry *dentry, bool is_dir) {
struct dentry *upperdir = ovl_dentry_upper(dentry->d_parent);
struct inode *dir = upperdir->d_inode;
struct dentry *upper = ovl_dentry_upper(dentry);
int err;
mutex_lock_nested(&dir->i_mutex, I_MUTEX_PARENT);
err = -ESTALE;
if... | static int ovl_remove_upper(struct dentry *dentry, bool is_dir) {
struct dentry *upperdir = ovl_dentry_upper(dentry->d_parent);
struct inode *dir = upperdir->d_inode;
struct dentry *upper;
int err;
mutex_lock_nested(&dir->i_mutex, I_MUTEX_PARENT);
upper = lookup_one_len(dentry->d_name.name, uppe... | static int ovl_remove_upper(struct dentry *dentry, bool is_dir) {
struct dentry *upperdir = ovl_dentry_upper(dentry->d_parent);
struct inode *dir = upperdir->d_inode;
struct dentry *upper = ovl_dentry_upper(dentry);
int err;
mutex_lock_nested(&dir->i_mutex, I_MUTEX_PARENT);
err = -ESTALE;
if... | static int ovl_remove_upper(struct dentry *dentry, bool is_dir) {
struct dentry *upperdir = ovl_dentry_upper(dentry->d_parent);
struct inode *dir = upperdir->d_inode;
struct dentry *upper;
int err;
mutex_lock_nested(&dir->i_mutex, I_MUTEX_PARENT);
upper = lookup_one_len(dentry->d_name.name, uppe... | static int ovl_remove_upper(struct dentry *dentry, bool is_dir) {
struct dentry *upperdir = ovl_dentry_upper(dentry->d_parent);
struct inode *dir = upperdir->d_inode;
struct dentry *upper = ovl_dentry_upper(dentry);
int err;
mutex_lock_nested(&dir->i_mutex, I_MUTEX_PARENT);
err = -ESTALE;
if... | static int ovl_remove_upper(struct dentry *dentry, bool is_dir) {
struct dentry *upperdir = ovl_dentry_upper(dentry->d_parent);
struct inode *dir = upperdir->d_inode;
struct dentry *upper;
int err;
mutex_lock_nested(&dir->i_mutex, I_MUTEX_PARENT);
upper = lookup_one_len(dentry->d_name.name, uppe... | static int ovl_remove_upper(struct dentry *dentry, bool is_dir) {
struct dentry *upperdir = ovl_dentry_upper(dentry->d_parent);
struct inode *dir = upperdir->d_inode;
struct dentry *upper = ovl_dentry_upper(dentry);
int err;
mutex_lock_nested(&dir->i_mutex, I_MUTEX_PARENT);
err = -ESTALE;
if... | static int ovl_remove_upper(struct dentry *dentry, bool is_dir) {
struct dentry *upperdir = ovl_dentry_upper(dentry->d_parent);
struct inode *dir = upperdir->d_inode;
struct dentry *upper;
int err;
mutex_lock_nested(&dir->i_mutex, I_MUTEX_PARENT);
upper = lookup_one_len(dentry->d_name.name, uppe... | static int ovl_remove_upper(struct dentry *dentry, bool is_dir) {
struct dentry *upperdir = ovl_dentry_upper(dentry->d_parent);
struct inode *dir = upperdir->d_inode;
- struct dentry *upper = ovl_dentry_upper(dentry);
+ struct dentry *upper;
int err;
mutex_lock_nested(&dir->i_mutex, I_MUTEX_P... |
CVE-2016-6197 | linux | https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux | fs/overlayfs/dir.c | ovl_rename2 | static int ovl_rename2(struct inode *olddir, struct dentry *old, struct inode *newdir, struct dentry *new, unsigned int flags) {
int err;
enum ovl_path_type old_type;
enum ovl_path_type new_type;
struct dentry *old_upperdir;
struct dentry *new_upperdir;
struct dentry *olddentry;
struct dentr... | static int ovl_rename2(struct inode *olddir, struct dentry *old, struct inode *newdir, struct dentry *new, unsigned int flags) {
int err;
enum ovl_path_type old_type;
enum ovl_path_type new_type;
struct dentry *old_upperdir;
struct dentry *new_upperdir;
struct dentry *olddentry;
struct dentr... | static int ovl_rename2(struct inode *olddir, struct dentry *old, struct inode *newdir, struct dentry *new, unsigned int flags) {
int err;
enum ovl_path_type old_type;
enum ovl_path_type new_type;
struct dentry *old_upperdir;
struct dentry *new_upperdir;
struct dentry *olddentry;
struct dentr... | static int ovl_rename2(struct inode *olddir, struct dentry *old, struct inode *newdir, struct dentry *new, unsigned int flags) {
int err;
enum ovl_path_type old_type;
enum ovl_path_type new_type;
struct dentry *old_upperdir;
struct dentry *new_upperdir;
struct dentry *olddentry;
struct dentr... | static int ovl_rename2(struct inode *olddir, struct dentry *old, struct inode *newdir, struct dentry *new, unsigned int flags) {
bool overwrite = !(flags & RENAME_EXCHANGE);
bool is_dir = d_is_dir(old);
bool new_is_dir = false;
struct dentry *opaquedir = NULL;
if (flags & ~(RENAME_EXCHANGE | RENAME_... | static int ovl_rename2(struct inode *olddir, struct dentry *old, struct inode *newdir, struct dentry *new, unsigned int flags) {
bool overwrite = !(flags & RENAME_EXCHANGE);
bool is_dir = d_is_dir(old);
bool new_is_dir = false;
struct dentry *opaquedir = NULL;
if (flags & ~(RENAME_EXCHANGE | RENAME_... | static int ovl_rename2(struct inode *olddir, struct dentry *old, struct inode *newdir, struct dentry *new, unsigned int flags) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
bool overwrite = !(flags & RENAME_EXCHANGE);
bool is_dir = d_is_dir(old);
bool new_is_dir = false;
struct dentry *opaquedir =... | static int ovl_rename2(struct inode *olddir, struct dentry *old, struct inode *newdir, struct dentry *new, unsigned int flags) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
bool overwrite = !(flags & RENAME_EXCHANGE);
bool is_dir = d_is_dir(old);
bool new_is_dir = false;
struct dentry *opaquedir =... | static int ovl_rename2(struct inode *olddir, struct dentry *old, struct inode *newdir, struct dentry *new, unsigned int flags) {
bool overwrite = !(flags & RENAME_EXCHANGE);
bool is_dir = d_is_dir(old);
bool new_is_dir = false;
struct dentry *opaquedir = NULL;
if (flags & ~(RENAME_EXCHANGE | R... |
CVE-2016-6198 | linux | https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux | fs/open.c | vfs_open | int vfs_open(const struct path *path, struct file *file, const struct cred *cred) {
struct dentry *dentry = path->dentry;
struct inode *inode = dentry->d_inode;
file->f_path = *path;
if (dentry->d_flags & DCACHE_OP_SELECT_ODE) {
inode = dentry->d_op->d_select_inode(dentry, file->f_flags);
... | int vfs_open(const struct path *path, struct file *file, const struct cred *cred) {
struct inode *inode = vfs_select_inode(path->dentry, file->f_flags);
if (IS_ERR(inode)) {
return PTR_ERR(inode);
}
file->f_path = *path;
return do_dentry_open(file, inode, NULL, cred);
} | int vfs_open(const struct path *path, struct file *file, const struct cred *cred) {
struct dentry *dentry = path->dentry;
struct inode *inode = dentry->d_inode;
file->f_path = *path;
if (dentry->d_flags & DCACHE_OP_SELECT_ODE) {
inode = dentry->d_op->d_select_inode(dentry, file->f_flags);
... | int vfs_open(const struct path *path, struct file *file, const struct cred *cred) {
struct inode *inode = vfs_select_inode(path->dentry, file->f_flags);
if (IS_ERR(inode)) {
return PTR_ERR(inode);
}
file->f_path = *path;
return do_dentry_open(file, inode, NULL, cred);
} | int vfs_open(const struct path *path, struct file *file, const struct cred *cred) {
struct dentry *dentry = path->dentry;
struct inode *inode = dentry->d_inode;
file->f_path = *path;
if (dentry->d_flags & DCACHE_OP_SELECT_ODE) {
inode = dentry->d_op->d_select_inode(dentry, file->f_flags);
... | int vfs_open(const struct path *path, struct file *file, const struct cred *cred) {
struct inode *inode = vfs_select_inode(path->dentry, file->f_flags);
if (IS_ERR(inode)) {
return PTR_ERR(inode);
}
file->f_path = *path;
return do_dentry_open(file, inode, NULL, cred);
}
| int vfs_open(const struct path *path, struct file *file, const struct cred *cred) {
struct dentry *dentry = path->dentry;
struct inode *inode = dentry->d_inode;
file->f_path = *path;
if (dentry->d_flags & DCACHE_OP_SELECT_ODE) {
inode = dentry->d_op->d_select_inode(dentry, file->f_flags);
... | int vfs_open(const struct path *path, struct file *file, const struct cred *cred) {
struct inode *inode = vfs_select_inode(path->dentry, file->f_flags);
if (IS_ERR(inode)) {
return PTR_ERR(inode);
}
file->f_path = *path;
return do_dentry_open(file, inode, NULL, cred);
} | int vfs_open(const struct path *path, struct file *file, const struct cred *cred) {
- struct dentry *dentry = path->dentry;
- struct inode *inode = dentry->d_inode;
+ struct inode *inode = vfs_select_inode(path->dentry, file->f_flags);
+ if (IS_ERR(inode)) {
+ return PTR_ERR(inode);
+ }
file... |
CVE-2016-6213 | linux | https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux | fs/namespace.c | alloc_mnt_ns | static struct mnt_namespace *alloc_mnt_ns(struct user_namespace *user_ns) {
struct mnt_namespace *new_ns;
int ret;
new_ns = kmalloc(sizeof(struct mnt_namespace), GFP_KERNEL);
if (!new_ns) {
return ERR_PTR(-ENOMEM);
}
ret = ns_alloc_inum(&new_ns->ns);
if (ret) {
kfree(new_ns);... | static struct mnt_namespace *alloc_mnt_ns(struct user_namespace *user_ns) {
struct mnt_namespace *new_ns;
int ret;
new_ns = kmalloc(sizeof(struct mnt_namespace), GFP_KERNEL);
if (!new_ns) {
return ERR_PTR(-ENOMEM);
}
ret = ns_alloc_inum(&new_ns->ns);
if (ret) {
kfree(new_ns);... | static struct mnt_namespace *alloc_mnt_ns(struct user_namespace *user_ns) {
struct mnt_namespace *new_ns;
int ret;
new_ns = kmalloc(sizeof(struct mnt_namespace), GFP_KERNEL);
if (!new_ns) {
return ERR_PTR(-ENOMEM);
}
ret = ns_alloc_inum(&new_ns->ns);
if (ret) {
kfree(new_ns);... | static struct mnt_namespace *alloc_mnt_ns(struct user_namespace *user_ns) {
struct mnt_namespace *new_ns;
int ret;
new_ns = kmalloc(sizeof(struct mnt_namespace), GFP_KERNEL);
if (!new_ns) {
return ERR_PTR(-ENOMEM);
}
ret = ns_alloc_inum(&new_ns->ns);
if (ret) {
kfree(new_ns);... | static struct mnt_namespace *alloc_mnt_ns(struct user_namespace *user_ns) {
new_ns->user_ns = get_user_ns(user_ns);
return new_ns;
}
| static struct mnt_namespace *alloc_mnt_ns(struct user_namespace *user_ns) {
new_ns->user_ns = get_user_ns(user_ns);
new_ns->mounts = 0;
new_ns->pending_mounts = 0;
return new_ns;
}
| static struct mnt_namespace *alloc_mnt_ns(struct user_namespace *user_ns) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
new_ns->user_ns = get_user_ns(user_ns);
return new_ns;
}
| static struct mnt_namespace *alloc_mnt_ns(struct user_namespace *user_ns) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
new_ns->user_ns = get_user_ns(user_ns);
new_ns->mounts = 0;
new_ns->pending_mounts = 0;
return new_ns;
} | static struct mnt_namespace *alloc_mnt_ns(struct user_namespace *user_ns) {
new_ns->user_ns = get_user_ns(user_ns);
+ new_ns->mounts = 0;
+ new_ns->pending_mounts = 0;
return new_ns;
} |
CVE-2016-6213 | linux | https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux | fs/namespace.c | attach_recursive_mnt | static int attach_recursive_mnt(struct mount *source_mnt, struct mount *dest_mnt, struct mountpoint *dest_mp, struct path *parent_path) {
HLIST_HEAD(tree_list);
struct mount *child, *p;
struct hlist_node *n;
int err;
if (IS_MNT_SHARED(dest_mnt)) {
err = invent_group_ids(source_mnt, true);
... | static int attach_recursive_mnt(struct mount *source_mnt, struct mount *dest_mnt, struct mountpoint *dest_mp, struct path *parent_path) {
HLIST_HEAD(tree_list);
struct mnt_namespace *ns = dest_mnt->mnt_ns;
struct mount *child, *p;
struct hlist_node *n;
int err;
if (!parent_path) {
err = ... | static int attach_recursive_mnt(struct mount *source_mnt, struct mount *dest_mnt, struct mountpoint *dest_mp, struct path *parent_path) {
HLIST_HEAD(tree_list);
struct mountpoint *smp;
struct mount *child, *p;
struct hlist_node *n;
int err;
smp = get_mountpoint(source_mnt->mnt.mnt_root);
if ... | static int attach_recursive_mnt(struct mount *source_mnt, struct mount *dest_mnt, struct mountpoint *dest_mp, struct path *parent_path) {
HLIST_HEAD(tree_list);
struct mnt_namespace *ns = dest_mnt->mnt_ns;
struct mountpoint *smp;
struct mount *child, *p;
struct hlist_node *n;
int err;
smp = ... | static int attach_recursive_mnt(struct mount *source_mnt, struct mount *dest_mnt, struct mountpoint *dest_mp, struct path *parent_path) {
HLIST_HEAD(tree_list);
struct mount *child, *p;
int err;
if (IS_MNT_SHARED(dest_mnt)) {
err = invent_group_ids(source_mnt, true);
if (err) {
... | static int attach_recursive_mnt(struct mount *source_mnt, struct mount *dest_mnt, struct mountpoint *dest_mp, struct path *parent_path) {
HLIST_HEAD(tree_list);
struct mnt_namespace *ns = dest_mnt->mnt_ns;
struct mount *child, *p;
int err;
if (!parent_path) {
err = count_mounts(ns, source_mn... | static int attach_recursive_mnt(struct mount *source_mnt, struct mount *dest_mnt, struct mountpoint *dest_mp, struct path *parent_path) {
HLIST_HEAD(tree_list);
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
struct mount *child, *p;
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
int err;
/* PLACEH... | static int attach_recursive_mnt(struct mount *source_mnt, struct mount *dest_mnt, struct mountpoint *dest_mp, struct path *parent_path) {
HLIST_HEAD(tree_list);
struct mnt_namespace *ns = dest_mnt->mnt_ns;
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
struct mount *child, *p;
/* PLACEHOLDER: DO NOT ... | static int attach_recursive_mnt(struct mount *source_mnt, struct mount *dest_mnt, struct mountpoint *dest_mp, struct path *parent_path) {
HLIST_HEAD(tree_list);
+ struct mnt_namespace *ns = dest_mnt->mnt_ns;
struct mount *child, *p;
int err;
+ if (!parent_path) {
+ err = count_mounts(ns, so... |
CVE-2016-6213 | linux | https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux | fs/namespace.c | commit_tree | static void commit_tree(struct mount *mnt, struct mount *shadows) {
struct mount *parent = mnt->mnt_parent;
struct mount *m;
LIST_HEAD(head);
struct mnt_namespace *n = parent->mnt_ns;
BUG_ON(parent == mnt);
list_add_tail(&head, &mnt->mnt_list);
list_for_each_entry(m, &head, mnt_list)
m->... | static void commit_tree(struct mount *mnt, struct mount *shadows) {
struct mount *parent = mnt->mnt_parent;
struct mount *m;
LIST_HEAD(head);
struct mnt_namespace *n = parent->mnt_ns;
BUG_ON(parent == mnt);
list_add_tail(&head, &mnt->mnt_list);
list_for_each_entry(m, &head, mnt_list)
m->... | static void commit_tree(struct mount *mnt) {
struct mount *parent = mnt->mnt_parent;
struct mount *m;
LIST_HEAD(head);
struct mnt_namespace *n = parent->mnt_ns;
BUG_ON(parent == mnt);
list_add_tail(&head, &mnt->mnt_list);
list_for_each_entry(m, &head, mnt_list)
m->mnt_ns = n;
list_sp... | static void commit_tree(struct mount *mnt) {
struct mount *parent = mnt->mnt_parent;
struct mount *m;
LIST_HEAD(head);
struct mnt_namespace *n = parent->mnt_ns;
BUG_ON(parent == mnt);
list_add_tail(&head, &mnt->mnt_list);
list_for_each_entry(m, &head, mnt_list)
m->mnt_ns = n;
list_sp... | static void commit_tree(struct mount *mnt, struct mount *shadows) {
struct mount *parent = mnt->mnt_parent;
struct mnt_namespace *n = parent->mnt_ns;
list_splice(&head, n->list.prev);
attach_shadowed(mnt, parent, shadows);
touch_mnt_namespace(n);
}
| static void commit_tree(struct mount *mnt, struct mount *shadows) {
struct mount *parent = mnt->mnt_parent;
struct mnt_namespace *n = parent->mnt_ns;
list_splice(&head, n->list.prev);
n->mounts += n->pending_mounts;
n->pending_mounts = 0;
attach_shadowed(mnt, parent, shadows);
touch_mnt_name... | static void commit_tree(struct mount *mnt) {
struct mount *parent = mnt->mnt_parent;
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
struct mnt_namespace *n = parent->mnt_ns;
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
list_splice(&head, n->list.prev);
__attach_mnt(mnt, parent);
touch_mnt_na... | static void commit_tree(struct mount *mnt) {
struct mount *parent = mnt->mnt_parent;
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
struct mnt_namespace *n = parent->mnt_ns;
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
list_splice(&head, n->list.prev);
n->mounts += n->pending_mounts;
n->pend... | static void commit_tree(struct mount *mnt, struct mount *shadows) {
struct mount *parent = mnt->mnt_parent;
struct mnt_namespace *n = parent->mnt_ns;
list_splice(&head, n->list.prev);
+ n->mounts += n->pending_mounts;
+ n->pending_mounts = 0;
attach_shadowed(mnt, parent, shadows);
touch_... |
CVE-2016-6213 | linux | https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux | fs/namespace.c | copy_mnt_ns | struct mnt_namespace *copy_mnt_ns(unsigned long flags, struct mnt_namespace *ns, struct user_namespace *user_ns, struct fs_struct *new_fs) {
struct mnt_namespace *new_ns;
struct vfsmount *rootmnt = NULL, *pwdmnt = NULL;
struct mount *p, *q;
struct mount *old;
struct mount *new;
int copy_flags;
... | struct mnt_namespace *copy_mnt_ns(unsigned long flags, struct mnt_namespace *ns, struct user_namespace *user_ns, struct fs_struct *new_fs) {
struct mnt_namespace *new_ns;
struct vfsmount *rootmnt = NULL, *pwdmnt = NULL;
struct mount *p, *q;
struct mount *old;
struct mount *new;
int copy_flags;
... | struct mnt_namespace *copy_mnt_ns(unsigned long flags, struct mnt_namespace *ns, struct user_namespace *user_ns, struct fs_struct *new_fs) {
struct mnt_namespace *new_ns;
struct vfsmount *rootmnt = NULL, *pwdmnt = NULL;
struct mount *p, *q;
struct mount *old;
struct mount *new;
int copy_flags;
... | struct mnt_namespace *copy_mnt_ns(unsigned long flags, struct mnt_namespace *ns, struct user_namespace *user_ns, struct fs_struct *new_fs) {
struct mnt_namespace *new_ns;
struct vfsmount *rootmnt = NULL, *pwdmnt = NULL;
struct mount *p, *q;
struct mount *old;
struct mount *new;
int copy_flags;
... | struct mnt_namespace *copy_mnt_ns(unsigned long flags, struct mnt_namespace *ns, struct user_namespace *user_ns, struct fs_struct *new_fs) {
}
| struct mnt_namespace *copy_mnt_ns(unsigned long flags, struct mnt_namespace *ns, struct user_namespace *user_ns, struct fs_struct *new_fs) {
}
| struct mnt_namespace *copy_mnt_ns(unsigned long flags, struct mnt_namespace *ns, struct user_namespace *user_ns, struct fs_struct *new_fs) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
}
| struct mnt_namespace *copy_mnt_ns(unsigned long flags, struct mnt_namespace *ns, struct user_namespace *user_ns, struct fs_struct *new_fs) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
} | |
CVE-2016-6213 | linux | https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux | fs/namespace.c | create_mnt_ns | static struct mnt_namespace *create_mnt_ns(struct vfsmount *m) {
struct mnt_namespace *new_ns = alloc_mnt_ns(&init_user_ns);
if (!IS_ERR(new_ns)) {
struct mount *mnt = real_mount(m);
mnt->mnt_ns = new_ns;
new_ns->root = mnt;
list_add(&mnt->mnt_list, &new_ns->list);
} else {
... | static struct mnt_namespace *create_mnt_ns(struct vfsmount *m) {
struct mnt_namespace *new_ns = alloc_mnt_ns(&init_user_ns);
if (!IS_ERR(new_ns)) {
struct mount *mnt = real_mount(m);
mnt->mnt_ns = new_ns;
new_ns->root = mnt;
new_ns->mounts++;
list_add(&mnt->mnt_list, &new... | static struct mnt_namespace *create_mnt_ns(struct vfsmount *m) {
struct mnt_namespace *new_ns = alloc_mnt_ns(&init_user_ns);
if (!IS_ERR(new_ns)) {
struct mount *mnt = real_mount(m);
mnt->mnt_ns = new_ns;
new_ns->root = mnt;
list_add(&mnt->mnt_list, &new_ns->list);
} else {
... | static struct mnt_namespace *create_mnt_ns(struct vfsmount *m) {
struct mnt_namespace *new_ns = alloc_mnt_ns(&init_user_ns);
if (!IS_ERR(new_ns)) {
struct mount *mnt = real_mount(m);
mnt->mnt_ns = new_ns;
new_ns->root = mnt;
new_ns->mounts++;
list_add(&mnt->mnt_list, &new... | static struct mnt_namespace *create_mnt_ns(struct vfsmount *m) {
struct mnt_namespace *new_ns = alloc_mnt_ns(&init_user_ns);
if (!IS_ERR(new_ns)) {
new_ns->root = mnt;
list_add(&mnt->mnt_list, &new_ns->list);
} else {
}
return new_ns;
}
| static struct mnt_namespace *create_mnt_ns(struct vfsmount *m) {
struct mnt_namespace *new_ns = alloc_mnt_ns(&init_user_ns);
if (!IS_ERR(new_ns)) {
new_ns->root = mnt;
new_ns->mounts++;
list_add(&mnt->mnt_list, &new_ns->list);
} else {
}
return new_ns;
}
| static struct mnt_namespace *create_mnt_ns(struct vfsmount *m) {
struct mnt_namespace *new_ns = alloc_mnt_ns(&init_user_ns);
if (!IS_ERR(new_ns)) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
new_ns->root = mnt;
list_add(&mnt->mnt_list, &new_ns->list);
} else {
/* PLACEHOLDER: DO N... | static struct mnt_namespace *create_mnt_ns(struct vfsmount *m) {
struct mnt_namespace *new_ns = alloc_mnt_ns(&init_user_ns);
if (!IS_ERR(new_ns)) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
new_ns->root = mnt;
new_ns->mounts++;
list_add(&mnt->mnt_list, &new_ns->list);
} else ... | static struct mnt_namespace *create_mnt_ns(struct vfsmount *m) {
struct mnt_namespace *new_ns = alloc_mnt_ns(&init_user_ns);
if (!IS_ERR(new_ns)) {
new_ns->root = mnt;
+ new_ns->mounts++;
list_add(&mnt->mnt_list, &new_ns->list);
} else {
}
return new_ns;
} |
CVE-2016-6213 | linux | https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux | fs/namespace.c | umount_tree | static void umount_tree(struct mount *mnt, enum umount_tree_flags how) {
LIST_HEAD(tmp_list);
struct mount *p;
if (how & UMOUNT_PROPAGATE) {
propagate_mount_unlock(mnt);
}
for (p = mnt; p; p = next_mnt(p, mnt)) {
p->mnt.mnt_flags |= MNT_UMOUNT;
list_move(&p->mnt_list, &tmp_li... | static void umount_tree(struct mount *mnt, enum umount_tree_flags how) {
LIST_HEAD(tmp_list);
struct mount *p;
if (how & UMOUNT_PROPAGATE) {
propagate_mount_unlock(mnt);
}
for (p = mnt; p; p = next_mnt(p, mnt)) {
p->mnt.mnt_flags |= MNT_UMOUNT;
list_move(&p->mnt_list, &tmp_li... | static void umount_tree(struct mount *mnt, enum umount_tree_flags how) {
LIST_HEAD(tmp_list);
struct mount *p;
if (how & UMOUNT_PROPAGATE) {
propagate_mount_unlock(mnt);
}
for (p = mnt; p; p = next_mnt(p, mnt)) {
p->mnt.mnt_flags |= MNT_UMOUNT;
list_move(&p->mnt_list, &tmp_li... | static void umount_tree(struct mount *mnt, enum umount_tree_flags how) {
LIST_HEAD(tmp_list);
struct mount *p;
if (how & UMOUNT_PROPAGATE) {
propagate_mount_unlock(mnt);
}
for (p = mnt; p; p = next_mnt(p, mnt)) {
p->mnt.mnt_flags |= MNT_UMOUNT;
list_move(&p->mnt_list, &tmp_li... | static void umount_tree(struct mount *mnt, enum umount_tree_flags how) {
LIST_HEAD(tmp_list);
if (how & UMOUNT_PROPAGATE) {
propagate_mount_unlock(mnt);
}
for (p = mnt; p; p = next_mnt(p, mnt)) {
}
list_for_each_entry(p, &tmp_list, mnt_list) {
}
while (!list_empty(&tmp_list)) {
... | static void umount_tree(struct mount *mnt, enum umount_tree_flags how) {
LIST_HEAD(tmp_list);
if (how & UMOUNT_PROPAGATE) {
propagate_mount_unlock(mnt);
}
for (p = mnt; p; p = next_mnt(p, mnt)) {
}
list_for_each_entry(p, &tmp_list, mnt_list) {
}
while (!list_empty(&tmp_list)) {
... | static void umount_tree(struct mount *mnt, enum umount_tree_flags how) {
LIST_HEAD(tmp_list);
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
if (how & UMOUNT_PROPAGATE) {
propagate_mount_unlock(mnt);
}
for (p = mnt; p; p = next_mnt(p, mnt)) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
... | static void umount_tree(struct mount *mnt, enum umount_tree_flags how) {
LIST_HEAD(tmp_list);
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
if (how & UMOUNT_PROPAGATE) {
propagate_mount_unlock(mnt);
}
for (p = mnt; p; p = next_mnt(p, mnt)) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
... | static void umount_tree(struct mount *mnt, enum umount_tree_flags how) {
LIST_HEAD(tmp_list);
if (how & UMOUNT_PROPAGATE) {
propagate_mount_unlock(mnt);
}
for (p = mnt; p; p = next_mnt(p, mnt)) {
}
list_for_each_entry(p, &tmp_list, mnt_list) {
}
while (!list_empty(&tmp_... |
CVE-2016-6213 | linux | https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux | fs/pnode.c | propagate_one | static int propagate_one(struct mount *m) {
struct mount *child;
int type;
if (IS_MNT_NEW(m)) {
return 0;
}
if (!is_subdir(mp->m_dentry, m->mnt.mnt_root)) {
return 0;
}
if (peers(m, last_dest)) {
type = CL_MAKE_SHARED;
} else {
struct mount *n, *p;
... | static int propagate_one(struct mount *m) {
struct mount *child;
int type;
if (IS_MNT_NEW(m)) {
return 0;
}
if (!is_subdir(mp->m_dentry, m->mnt.mnt_root)) {
return 0;
}
if (peers(m, last_dest)) {
type = CL_MAKE_SHARED;
} else {
struct mount *n, *p;
... | static int propagate_one(struct mount *m) {
struct mount *child;
int type;
if (IS_MNT_NEW(m)) {
return 0;
}
if (!is_subdir(mp->m_dentry, m->mnt.mnt_root)) {
return 0;
}
if (peers(m, last_dest)) {
type = CL_MAKE_SHARED;
} else {
struct mount *n, *p;
... | static int propagate_one(struct mount *m) {
struct mount *child;
int type;
if (IS_MNT_NEW(m)) {
return 0;
}
if (!is_subdir(mp->m_dentry, m->mnt.mnt_root)) {
return 0;
}
if (peers(m, last_dest)) {
type = CL_MAKE_SHARED;
} else {
struct mount *n, *p;
... | static int propagate_one(struct mount *m) {
if (IS_MNT_NEW(m)) {
return 0;
}
if (peers(m, last_dest)) {
type = CL_MAKE_SHARED;
} else {
do {
struct mount *parent = last_source->mnt_parent;
if (last_source == first_source) {
break;
... | static int propagate_one(struct mount *m) {
if (IS_MNT_NEW(m)) {
return 0;
}
if (peers(m, last_dest)) {
type = CL_MAKE_SHARED;
} else {
do {
struct mount *parent = last_source->mnt_parent;
if (last_source == first_source) {
break;
... | static int propagate_one(struct mount *m) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
if (IS_MNT_NEW(m)) {
return 0;
}
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
if (peers(m, last_dest)) {
type = CL_MAKE_SHARED;
} else {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
... | static int propagate_one(struct mount *m) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
if (IS_MNT_NEW(m)) {
return 0;
}
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
if (peers(m, last_dest)) {
type = CL_MAKE_SHARED;
} else {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
... | static int propagate_one(struct mount *m) {
if (IS_MNT_NEW(m)) {
return 0;
}
if (peers(m, last_dest)) {
type = CL_MAKE_SHARED;
} else {
do {
struct mount *parent = last_source->mnt_parent;
if (last_source == first_source) {
break... |
CVE-2016-6327 | linux | https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux | drivers/infiniband/ulp/srpt/ib_srpt.c | srpt_handle_tsk_mgmt | static void srpt_handle_tsk_mgmt(struct srpt_rdma_ch *ch, struct srpt_recv_ioctx *recv_ioctx, struct srpt_send_ioctx *send_ioctx) {
struct srp_tsk_mgmt *srp_tsk;
struct se_cmd *cmd;
struct se_session *sess = ch->sess;
uint64_t unpacked_lun;
uint32_t tag = 0;
int tcm_tmr;
int rc;
BUG_ON(!... | static void srpt_handle_tsk_mgmt(struct srpt_rdma_ch *ch, struct srpt_recv_ioctx *recv_ioctx, struct srpt_send_ioctx *send_ioctx) {
struct srp_tsk_mgmt *srp_tsk;
struct se_cmd *cmd;
struct se_session *sess = ch->sess;
uint64_t unpacked_lun;
int tcm_tmr;
int rc;
BUG_ON(!send_ioctx);
srp_t... | static void srpt_handle_tsk_mgmt(struct srpt_rdma_ch *ch, struct srpt_recv_ioctx *recv_ioctx, struct srpt_send_ioctx *send_ioctx) {
struct srp_tsk_mgmt *srp_tsk;
struct se_cmd *cmd;
struct se_session *sess = ch->sess;
uint64_t unpacked_lun;
uint32_t tag = 0;
int tcm_tmr;
int rc;
BUG_ON(!... | static void srpt_handle_tsk_mgmt(struct srpt_rdma_ch *ch, struct srpt_recv_ioctx *recv_ioctx, struct srpt_send_ioctx *send_ioctx) {
struct srp_tsk_mgmt *srp_tsk;
struct se_cmd *cmd;
struct se_session *sess = ch->sess;
uint64_t unpacked_lun;
int tcm_tmr;
int rc;
BUG_ON(!send_ioctx);
srp_t... | static void srpt_handle_tsk_mgmt(struct srpt_rdma_ch *ch, struct srpt_recv_ioctx *recv_ioctx, struct srpt_send_ioctx *send_ioctx) {
struct se_session *sess = ch->sess;
uint64_t unpacked_lun;
uint32_t tag = 0;
int tcm_tmr;
BUG_ON(!send_ioctx);
srp_tsk = recv_ioctx->ioctx.buf;
pr_debug("recv t... | static void srpt_handle_tsk_mgmt(struct srpt_rdma_ch *ch, struct srpt_recv_ioctx *recv_ioctx, struct srpt_send_ioctx *send_ioctx) {
struct se_session *sess = ch->sess;
uint64_t unpacked_lun;
int tcm_tmr;
BUG_ON(!send_ioctx);
srp_tsk = recv_ioctx->ioctx.buf;
pr_debug("recv tsk_mgmt fn %d for task... | static void srpt_handle_tsk_mgmt(struct srpt_rdma_ch *ch, struct srpt_recv_ioctx *recv_ioctx, struct srpt_send_ioctx *send_ioctx) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
struct se_session *sess = ch->sess;
uint64_t unpacked_lun;
uint32_t tag = 0;
int tcm_tmr;
/* PLACEHOLDER: DO NOT DELET... | static void srpt_handle_tsk_mgmt(struct srpt_rdma_ch *ch, struct srpt_recv_ioctx *recv_ioctx, struct srpt_send_ioctx *send_ioctx) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
struct se_session *sess = ch->sess;
uint64_t unpacked_lun;
int tcm_tmr;
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
... | static void srpt_handle_tsk_mgmt(struct srpt_rdma_ch *ch, struct srpt_recv_ioctx *recv_ioctx, struct srpt_send_ioctx *send_ioctx) {
struct se_session *sess = ch->sess;
uint64_t unpacked_lun;
- uint32_t tag = 0;
int tcm_tmr;
BUG_ON(!send_ioctx);
srp_tsk = recv_ioctx->ioctx.buf;
pr_debug... |
CVE-2016-6480 | linux | https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux | drivers/scsi/aacraid/commctrl.c | ioctl_send_fib | static int ioctl_send_fib(struct aac_dev * dev, void *arg) {
struct hw_fib * kfib;
struct fib *fibptr;
struct hw_fib * hw_fib = (struct hw_fib *)0;
dma_addr_t hw_fib_pa = (dma_addr_t)0LL;
unsigned size;
int retval;
if (dev->in_reset) {
return -EBUSY;
}
fibptr = aac_fib_alloc(... | static int ioctl_send_fib(struct aac_dev * dev, void *arg) {
struct hw_fib * kfib;
struct fib *fibptr;
struct hw_fib * hw_fib = (struct hw_fib *)0;
dma_addr_t hw_fib_pa = (dma_addr_t)0LL;
unsigned int size, osize;
int retval;
if (dev->in_reset) {
return -EBUSY;
}
fibptr = aac... | static int ioctl_send_fib(struct aac_dev * dev, void *arg) {
struct hw_fib * kfib;
struct fib *fibptr;
struct hw_fib * hw_fib = (struct hw_fib *)0;
dma_addr_t hw_fib_pa = (dma_addr_t)0LL;
unsigned size;
int retval;
if (dev->in_reset) {
return -EBUSY;
}
fibptr = aac_fib_alloc(... | static int ioctl_send_fib(struct aac_dev * dev, void *arg) {
struct hw_fib * kfib;
struct fib *fibptr;
struct hw_fib * hw_fib = (struct hw_fib *)0;
dma_addr_t hw_fib_pa = (dma_addr_t)0LL;
unsigned int size, osize;
int retval;
if (dev->in_reset) {
return -EBUSY;
}
fibptr = aac... | static int ioctl_send_fib(struct aac_dev * dev, void *arg) {
dma_addr_t hw_fib_pa = (dma_addr_t)0LL;
unsigned size;
int retval;
fibptr = aac_fib_alloc(dev);
if(fibptr == NULL) {
return -ENOMEM;
}
kfib = fibptr->hw_fib_va;
if (copy_from_user((void *)kfib, arg, sizeof(struct aac_fi... | static int ioctl_send_fib(struct aac_dev * dev, void *arg) {
dma_addr_t hw_fib_pa = (dma_addr_t)0LL;
unsigned int size, osize;
int retval;
fibptr = aac_fib_alloc(dev);
if(fibptr == NULL) {
return -ENOMEM;
}
kfib = fibptr->hw_fib_va;
if (copy_from_user((void *)kfib, arg, sizeof(st... | static int ioctl_send_fib(struct aac_dev * dev, void *arg) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
dma_addr_t hw_fib_pa = (dma_addr_t)0LL;
unsigned size;
int retval;
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
fibptr = aac_fib_alloc(dev);
if(fibptr == NULL) {
return -ENOMEM... | static int ioctl_send_fib(struct aac_dev * dev, void *arg) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
dma_addr_t hw_fib_pa = (dma_addr_t)0LL;
unsigned int size, osize;
int retval;
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
fibptr = aac_fib_alloc(dev);
if(fibptr == NULL) {
ret... | static int ioctl_send_fib(struct aac_dev * dev, void *arg) {
dma_addr_t hw_fib_pa = (dma_addr_t)0LL;
- unsigned size;
+ unsigned int size, osize;
int retval;
fibptr = aac_fib_alloc(dev);
if(fibptr == NULL) {
return -ENOMEM;
}
kfib = fibptr->hw_fib_va;
if (copy_from_use... |
CVE-2016-6516 | linux | https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux | fs/ioctl.c | ioctl_file_dedupe_range | static long ioctl_file_dedupe_range(struct file *file, void *arg) {
struct file_dedupe_range *argp = arg;
struct file_dedupe_range *same = NULL;
int ret;
unsigned long size;
u16 count;
if (get_user(count, &argp->dest_count)) {
ret = -EFAULT;
goto out;
}
size = offsetof(st... | static long ioctl_file_dedupe_range(struct file *file, void *arg) {
struct file_dedupe_range *argp = arg;
struct file_dedupe_range *same = NULL;
int ret;
unsigned long size;
u16 count;
if (get_user(count, &argp->dest_count)) {
ret = -EFAULT;
goto out;
}
size = offsetof(st... | static long ioctl_file_dedupe_range(struct file *file, void *arg) {
struct file_dedupe_range *argp = arg;
struct file_dedupe_range *same = NULL;
int ret;
unsigned long size;
u16 count;
if (get_user(count, &argp->dest_count)) {
ret = -EFAULT;
goto out;
}
size = offsetof(st... | static long ioctl_file_dedupe_range(struct file *file, void *arg) {
struct file_dedupe_range *argp = arg;
struct file_dedupe_range *same = NULL;
int ret;
unsigned long size;
u16 count;
if (get_user(count, &argp->dest_count)) {
ret = -EFAULT;
goto out;
}
size = offsetof(st... | static long ioctl_file_dedupe_range(struct file *file, void *arg) {
struct file_dedupe_range *argp = arg;
if (get_user(count, &argp->dest_count)) {
goto out;
}
if (IS_ERR(same)) {
goto out;
}
ret = vfs_dedupe_file_range(file, same);
ret = copy_to_user(argp, same, size);
out:
... | static long ioctl_file_dedupe_range(struct file *file, void *arg) {
struct file_dedupe_range *argp = arg;
if (get_user(count, &argp->dest_count)) {
goto out;
}
if (IS_ERR(same)) {
goto out;
}
same->dest_count = count;
ret = vfs_dedupe_file_range(file, same);
ret = copy_to... | static long ioctl_file_dedupe_range(struct file *file, void *arg) {
struct file_dedupe_range *argp = arg;
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
if (get_user(count, &argp->dest_count)) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
goto out;
}
/* PLACEHOLDER: DO NOT DELETE THIS C... | static long ioctl_file_dedupe_range(struct file *file, void *arg) {
struct file_dedupe_range *argp = arg;
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
if (get_user(count, &argp->dest_count)) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
goto out;
}
/* PLACEHOLDER: DO NOT DELETE THIS C... | static long ioctl_file_dedupe_range(struct file *file, void *arg) {
struct file_dedupe_range *argp = arg;
if (get_user(count, &argp->dest_count)) {
goto out;
}
if (IS_ERR(same)) {
goto out;
}
+ same->dest_count = count;
ret = vfs_dedupe_file_range(file, same);
re... |
CVE-2016-6828 | linux | https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux | include/net/tcp.h | tcp_check_send_head | static inline void tcp_check_send_head(struct sock *sk, struct sk_buff *skb_unlinked) {
if (sk->sk_send_head == skb_unlinked) {
sk->sk_send_head = NULL;
}
} | static inline void tcp_check_send_head(struct sock *sk, struct sk_buff *skb_unlinked) {
if (sk->sk_send_head == skb_unlinked) {
sk->sk_send_head = NULL;
}
if (tcp_sk(sk)->highest_sack == skb_unlinked) {
tcp_sk(sk)->highest_sack = NULL;
}
} | static inline void tcp_check_send_head(struct sock *sk, struct sk_buff *skb_unlinked) {
if (sk->sk_send_head == skb_unlinked) {
sk->sk_send_head = NULL;
}
} | static inline void tcp_check_send_head(struct sock *sk, struct sk_buff *skb_unlinked) {
if (sk->sk_send_head == skb_unlinked) {
sk->sk_send_head = NULL;
}
if (tcp_sk(sk)->highest_sack == skb_unlinked) {
tcp_sk(sk)->highest_sack = NULL;
}
} | static inline void tcp_check_send_head(struct sock *sk, struct sk_buff *skb_unlinked) {
if (sk->sk_send_head == skb_unlinked) {
sk->sk_send_head = NULL;
}
}
| static inline void tcp_check_send_head(struct sock *sk, struct sk_buff *skb_unlinked) {
if (sk->sk_send_head == skb_unlinked) {
sk->sk_send_head = NULL;
}
if (tcp_sk(sk)->highest_sack == skb_unlinked) {
tcp_sk(sk)->highest_sack = NULL;
}
}
| static inline void tcp_check_send_head(struct sock *sk, struct sk_buff *skb_unlinked) {
if (sk->sk_send_head == skb_unlinked) {
sk->sk_send_head = NULL;
}
}
| static inline void tcp_check_send_head(struct sock *sk, struct sk_buff *skb_unlinked) {
if (sk->sk_send_head == skb_unlinked) {
sk->sk_send_head = NULL;
}
if (tcp_sk(sk)->highest_sack == skb_unlinked) {
tcp_sk(sk)->highest_sack = NULL;
}
} | static inline void tcp_check_send_head(struct sock *sk, struct sk_buff *skb_unlinked) {
if (sk->sk_send_head == skb_unlinked) {
sk->sk_send_head = NULL;
}
+ if (tcp_sk(sk)->highest_sack == skb_unlinked) {
+ tcp_sk(sk)->highest_sack = NULL;
+ }
} |
CVE-2016-7039 | linux | https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux | drivers/net/vxlan.c | vxlan_gro_receive | static struct sk_buff **vxlan_gro_receive(struct sk_buff **head, struct sk_buff *skb, struct udp_offload *uoff) {
struct sk_buff *p, **pp = NULL;
struct vxlanhdr *vh, *vh2;
unsigned int hlen, off_vx;
int flush = 1;
struct vxlan_sock *vs = container_of(uoff, struct vxlan_sock, udp_offloads);
u32 ... | static struct sk_buff **vxlan_gro_receive(struct sk_buff **head, struct sk_buff *skb, struct udp_offload *uoff) {
struct sk_buff *p, **pp = NULL;
struct vxlanhdr *vh, *vh2;
unsigned int hlen, off_vx;
int flush = 1;
struct vxlan_sock *vs = container_of(uoff, struct vxlan_sock, udp_offloads);
u32 ... | static struct sk_buff **vxlan_gro_receive(struct sk_buff **head, struct sk_buff *skb, struct udp_offload *uoff) {
struct sk_buff *p, **pp = NULL;
struct vxlanhdr *vh, *vh2;
unsigned int hlen, off_vx;
int flush = 1;
struct vxlan_sock *vs = container_of(uoff, struct vxlan_sock, udp_offloads);
u32 ... | static struct sk_buff **vxlan_gro_receive(struct sk_buff **head, struct sk_buff *skb, struct udp_offload *uoff) {
struct sk_buff *p, **pp = NULL;
struct vxlanhdr *vh, *vh2;
unsigned int hlen, off_vx;
int flush = 1;
struct vxlan_sock *vs = container_of(uoff, struct vxlan_sock, udp_offloads);
u32 ... | static struct sk_buff **vxlan_gro_receive(struct sk_buff **head, struct sk_buff *skb, struct udp_offload *uoff) {
off_vx = skb_gro_offset(skb);
hlen = off_vx + sizeof(*vh);
vh = skb_gro_header_fast(skb, off_vx);
if (skb_gro_header_hard(skb, hlen)) {
vh = skb_gro_header_slow(skb, hlen, off_vx);
... | static struct sk_buff **vxlan_gro_receive(struct sk_buff **head, struct sk_buff *skb, struct udp_offload *uoff) {
off_vx = skb_gro_offset(skb);
hlen = off_vx + sizeof(*vh);
vh = skb_gro_header_fast(skb, off_vx);
if (skb_gro_header_hard(skb, hlen)) {
vh = skb_gro_header_slow(skb, hlen, off_vx);
... | static struct sk_buff **vxlan_gro_receive(struct sk_buff **head, struct sk_buff *skb, struct udp_offload *uoff) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
off_vx = skb_gro_offset(skb);
hlen = off_vx + sizeof(*vh);
vh = skb_gro_header_fast(skb, off_vx);
if (skb_gro_header_hard(skb, hlen)) {
... | static struct sk_buff **vxlan_gro_receive(struct sk_buff **head, struct sk_buff *skb, struct udp_offload *uoff) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
off_vx = skb_gro_offset(skb);
hlen = off_vx + sizeof(*vh);
vh = skb_gro_header_fast(skb, off_vx);
if (skb_gro_header_hard(skb, hlen)) {
... | static struct sk_buff **vxlan_gro_receive(struct sk_buff **head, struct sk_buff *skb, struct udp_offload *uoff) {
off_vx = skb_gro_offset(skb);
hlen = off_vx + sizeof(*vh);
vh = skb_gro_header_fast(skb, off_vx);
if (skb_gro_header_hard(skb, hlen)) {
vh = skb_gro_header_slow(skb, hlen, off_... |
CVE-2016-7039 | linux | https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux | net/core/dev.c | dev_gro_receive | static enum gro_result dev_gro_receive(struct napi_struct *napi, struct sk_buff *skb) {
struct sk_buff **pp = NULL;
struct packet_offload *ptype;
__be16 type = skb->protocol;
struct list_head *head = &offload_base;
int same_flow;
enum gro_result ret;
int grow;
if (!(skb->dev->features & ... | static enum gro_result dev_gro_receive(struct napi_struct *napi, struct sk_buff *skb) {
struct sk_buff **pp = NULL;
struct packet_offload *ptype;
__be16 type = skb->protocol;
struct list_head *head = &offload_base;
int same_flow;
enum gro_result ret;
int grow;
if (!(skb->dev->features & ... | static enum gro_result dev_gro_receive(struct napi_struct *napi, struct sk_buff *skb) {
struct sk_buff **pp = NULL;
struct packet_offload *ptype;
__be16 type = skb->protocol;
struct list_head *head = &offload_base;
int same_flow;
enum gro_result ret;
int grow;
if (!(skb->dev->features & ... | static enum gro_result dev_gro_receive(struct napi_struct *napi, struct sk_buff *skb) {
struct sk_buff **pp = NULL;
struct packet_offload *ptype;
__be16 type = skb->protocol;
struct list_head *head = &offload_base;
int same_flow;
enum gro_result ret;
int grow;
if (!(skb->dev->features & ... | static enum gro_result dev_gro_receive(struct napi_struct *napi, struct sk_buff *skb) {
if (skb_is_gso(skb) || skb_has_frag_list(skb) || skb->csum_bad) {
goto normal;
}
gro_list_prepare(napi, skb);
list_for_each_entry_rcu(ptype, head, list) {
if (ptype->type != type || !ptype->callbacks.... | static enum gro_result dev_gro_receive(struct napi_struct *napi, struct sk_buff *skb) {
if (skb_is_gso(skb) || skb_has_frag_list(skb) || skb->csum_bad) {
goto normal;
}
gro_list_prepare(napi, skb);
list_for_each_entry_rcu(ptype, head, list) {
if (ptype->type != type || !ptype->callbacks.... | static enum gro_result dev_gro_receive(struct napi_struct *napi, struct sk_buff *skb) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
if (skb_is_gso(skb) || skb_has_frag_list(skb) || skb->csum_bad) {
goto normal;
}
gro_list_prepare(napi, skb);
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
... | static enum gro_result dev_gro_receive(struct napi_struct *napi, struct sk_buff *skb) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
if (skb_is_gso(skb) || skb_has_frag_list(skb) || skb->csum_bad) {
goto normal;
}
gro_list_prepare(napi, skb);
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
... | static enum gro_result dev_gro_receive(struct napi_struct *napi, struct sk_buff *skb) {
if (skb_is_gso(skb) || skb_has_frag_list(skb) || skb->csum_bad) {
goto normal;
}
gro_list_prepare(napi, skb);
list_for_each_entry_rcu(ptype, head, list) {
if (ptype->type != type || !ptype->cal... |
CVE-2016-7039 | linux | https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux | net/ethernet/eth.c | eth_gro_receive | struct sk_buff **eth_gro_receive(struct sk_buff **head, struct sk_buff *skb) {
struct sk_buff *p, **pp = NULL;
struct ethhdr *eh, *eh2;
unsigned int hlen, off_eth;
const struct packet_offload *ptype;
__be16 type;
int flush = 1;
off_eth = skb_gro_offset(skb);
hlen = off_eth + sizeof(*eh);... | struct sk_buff **eth_gro_receive(struct sk_buff **head, struct sk_buff *skb) {
struct sk_buff *p, **pp = NULL;
struct ethhdr *eh, *eh2;
unsigned int hlen, off_eth;
const struct packet_offload *ptype;
__be16 type;
int flush = 1;
off_eth = skb_gro_offset(skb);
hlen = off_eth + sizeof(*eh);... | struct sk_buff **eth_gro_receive(struct sk_buff **head, struct sk_buff *skb) {
struct sk_buff *p, **pp = NULL;
struct ethhdr *eh, *eh2;
unsigned int hlen, off_eth;
const struct packet_offload *ptype;
__be16 type;
int flush = 1;
off_eth = skb_gro_offset(skb);
hlen = off_eth + sizeof(*eh);... | struct sk_buff **eth_gro_receive(struct sk_buff **head, struct sk_buff *skb) {
struct sk_buff *p, **pp = NULL;
struct ethhdr *eh, *eh2;
unsigned int hlen, off_eth;
const struct packet_offload *ptype;
__be16 type;
int flush = 1;
off_eth = skb_gro_offset(skb);
hlen = off_eth + sizeof(*eh);... | struct sk_buff **eth_gro_receive(struct sk_buff **head, struct sk_buff *skb) {
off_eth = skb_gro_offset(skb);
hlen = off_eth + sizeof(*eh);
eh = skb_gro_header_fast(skb, off_eth);
if (skb_gro_header_hard(skb, hlen)) {
eh = skb_gro_header_slow(skb, hlen, off_eth);
if (unlikely(!eh)) {
... | struct sk_buff **eth_gro_receive(struct sk_buff **head, struct sk_buff *skb) {
off_eth = skb_gro_offset(skb);
hlen = off_eth + sizeof(*eh);
eh = skb_gro_header_fast(skb, off_eth);
if (skb_gro_header_hard(skb, hlen)) {
eh = skb_gro_header_slow(skb, hlen, off_eth);
if (unlikely(!eh)) {
... | struct sk_buff **eth_gro_receive(struct sk_buff **head, struct sk_buff *skb) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
off_eth = skb_gro_offset(skb);
hlen = off_eth + sizeof(*eh);
eh = skb_gro_header_fast(skb, off_eth);
if (skb_gro_header_hard(skb, hlen)) {
eh = skb_gro_header_slow(skb... | struct sk_buff **eth_gro_receive(struct sk_buff **head, struct sk_buff *skb) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
off_eth = skb_gro_offset(skb);
hlen = off_eth + sizeof(*eh);
eh = skb_gro_header_fast(skb, off_eth);
if (skb_gro_header_hard(skb, hlen)) {
eh = skb_gro_header_slow(skb... | struct sk_buff **eth_gro_receive(struct sk_buff **head, struct sk_buff *skb) {
off_eth = skb_gro_offset(skb);
hlen = off_eth + sizeof(*eh);
eh = skb_gro_header_fast(skb, off_eth);
if (skb_gro_header_hard(skb, hlen)) {
eh = skb_gro_header_slow(skb, hlen, off_eth);
if (unlikely(!eh)... |
CVE-2016-7039 | linux | https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux | net/ipv4/af_inet.c | inet_gro_receive | static struct sk_buff **inet_gro_receive(struct sk_buff **head, struct sk_buff *skb) {
const struct net_offload *ops;
struct sk_buff **pp = NULL;
struct sk_buff *p;
const struct iphdr *iph;
unsigned int hlen;
unsigned int off;
unsigned int id;
int flush = 1;
int proto;
off = skb_... | static struct sk_buff **inet_gro_receive(struct sk_buff **head, struct sk_buff *skb) {
const struct net_offload *ops;
struct sk_buff **pp = NULL;
struct sk_buff *p;
const struct iphdr *iph;
unsigned int hlen;
unsigned int off;
unsigned int id;
int flush = 1;
int proto;
off = skb_... | static struct sk_buff **inet_gro_receive(struct sk_buff **head, struct sk_buff *skb) {
const struct net_offload *ops;
struct sk_buff **pp = NULL;
struct sk_buff *p;
const struct iphdr *iph;
unsigned int hlen;
unsigned int off;
unsigned int id;
int flush = 1;
int proto;
off = skb_... | static struct sk_buff **inet_gro_receive(struct sk_buff **head, struct sk_buff *skb) {
const struct net_offload *ops;
struct sk_buff **pp = NULL;
struct sk_buff *p;
const struct iphdr *iph;
unsigned int hlen;
unsigned int off;
unsigned int id;
int flush = 1;
int proto;
off = skb_... | static struct sk_buff **inet_gro_receive(struct sk_buff **head, struct sk_buff *skb) {
off = skb_gro_offset(skb);
hlen = off + sizeof(*iph);
iph = skb_gro_header_fast(skb, off);
if (skb_gro_header_hard(skb, hlen)) {
iph = skb_gro_header_slow(skb, hlen, off);
if (unlikely(!iph)) {
... | static struct sk_buff **inet_gro_receive(struct sk_buff **head, struct sk_buff *skb) {
off = skb_gro_offset(skb);
hlen = off + sizeof(*iph);
iph = skb_gro_header_fast(skb, off);
if (skb_gro_header_hard(skb, hlen)) {
iph = skb_gro_header_slow(skb, hlen, off);
if (unlikely(!iph)) {
... | static struct sk_buff **inet_gro_receive(struct sk_buff **head, struct sk_buff *skb) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
off = skb_gro_offset(skb);
hlen = off + sizeof(*iph);
iph = skb_gro_header_fast(skb, off);
if (skb_gro_header_hard(skb, hlen)) {
iph = skb_gro_header_slow(skb,... | static struct sk_buff **inet_gro_receive(struct sk_buff **head, struct sk_buff *skb) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
off = skb_gro_offset(skb);
hlen = off + sizeof(*iph);
iph = skb_gro_header_fast(skb, off);
if (skb_gro_header_hard(skb, hlen)) {
iph = skb_gro_header_slow(skb,... | static struct sk_buff **inet_gro_receive(struct sk_buff **head, struct sk_buff *skb) {
off = skb_gro_offset(skb);
hlen = off + sizeof(*iph);
iph = skb_gro_header_fast(skb, off);
if (skb_gro_header_hard(skb, hlen)) {
iph = skb_gro_header_slow(skb, hlen, off);
if (unlikely(!iph)) {
... |
CVE-2016-7039 | linux | https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux | net/ipv4/fou.c | fou_gro_receive | static struct sk_buff **fou_gro_receive(struct sk_buff **head, struct sk_buff *skb, struct udp_offload *uoff) {
const struct net_offload *ops;
struct sk_buff **pp = NULL;
u8 proto = NAPI_GRO_CB(skb)->proto;
const struct net_offload **offloads;
rcu_read_lock();
offloads = NAPI_GRO_CB(skb)->is_ipv... | static struct sk_buff **fou_gro_receive(struct sk_buff **head, struct sk_buff *skb, struct udp_offload *uoff) {
const struct net_offload *ops;
struct sk_buff **pp = NULL;
u8 proto = NAPI_GRO_CB(skb)->proto;
const struct net_offload **offloads;
rcu_read_lock();
offloads = NAPI_GRO_CB(skb)->is_ipv... | static struct sk_buff **fou_gro_receive(struct sk_buff **head, struct sk_buff *skb, struct udp_offload *uoff) {
const struct net_offload *ops;
struct sk_buff **pp = NULL;
u8 proto = NAPI_GRO_CB(skb)->proto;
const struct net_offload **offloads;
rcu_read_lock();
offloads = NAPI_GRO_CB(skb)->is_ipv... | static struct sk_buff **fou_gro_receive(struct sk_buff **head, struct sk_buff *skb, struct udp_offload *uoff) {
const struct net_offload *ops;
struct sk_buff **pp = NULL;
u8 proto = NAPI_GRO_CB(skb)->proto;
const struct net_offload **offloads;
rcu_read_lock();
offloads = NAPI_GRO_CB(skb)->is_ipv... | static struct sk_buff **fou_gro_receive(struct sk_buff **head, struct sk_buff *skb, struct udp_offload *uoff) {
u8 proto = NAPI_GRO_CB(skb)->proto;
offloads = NAPI_GRO_CB(skb)->is_ipv6 ? inet6_offloads : inet_offloads;
ops = rcu_dereference(offloads[proto]);
if (!ops || !ops->callbacks.gro_receive) {
... | static struct sk_buff **fou_gro_receive(struct sk_buff **head, struct sk_buff *skb, struct udp_offload *uoff) {
u8 proto = NAPI_GRO_CB(skb)->proto;
offloads = NAPI_GRO_CB(skb)->is_ipv6 ? inet6_offloads : inet_offloads;
ops = rcu_dereference(offloads[proto]);
if (!ops || !ops->callbacks.gro_receive) {
... | static struct sk_buff **fou_gro_receive(struct sk_buff **head, struct sk_buff *skb, struct udp_offload *uoff) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
u8 proto = NAPI_GRO_CB(skb)->proto;
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
offloads = NAPI_GRO_CB(skb)->is_ipv6 ? inet6_offloads : inet_off... | static struct sk_buff **fou_gro_receive(struct sk_buff **head, struct sk_buff *skb, struct udp_offload *uoff) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
u8 proto = NAPI_GRO_CB(skb)->proto;
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
offloads = NAPI_GRO_CB(skb)->is_ipv6 ? inet6_offloads : inet_off... | static struct sk_buff **fou_gro_receive(struct sk_buff **head, struct sk_buff *skb, struct udp_offload *uoff) {
u8 proto = NAPI_GRO_CB(skb)->proto;
offloads = NAPI_GRO_CB(skb)->is_ipv6 ? inet6_offloads : inet_offloads;
ops = rcu_dereference(offloads[proto]);
if (!ops || !ops->callbacks.gro_receive)... |
CVE-2016-7039 | linux | https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux | net/ipv4/fou.c | gue_gro_receive | static struct sk_buff **gue_gro_receive(struct sk_buff **head, struct sk_buff *skb, struct udp_offload *uoff) {
const struct net_offload **offloads;
const struct net_offload *ops;
struct sk_buff **pp = NULL;
struct sk_buff *p;
struct guehdr *guehdr;
size_t len, optlen, hdrlen, off;
void *dat... | static struct sk_buff **gue_gro_receive(struct sk_buff **head, struct sk_buff *skb, struct udp_offload *uoff) {
const struct net_offload **offloads;
const struct net_offload *ops;
struct sk_buff **pp = NULL;
struct sk_buff *p;
struct guehdr *guehdr;
size_t len, optlen, hdrlen, off;
void *dat... | static struct sk_buff **gue_gro_receive(struct sk_buff **head, struct sk_buff *skb, struct udp_offload *uoff) {
const struct net_offload **offloads;
const struct net_offload *ops;
struct sk_buff **pp = NULL;
struct sk_buff *p;
struct guehdr *guehdr;
size_t len, optlen, hdrlen, off;
void *dat... | static struct sk_buff **gue_gro_receive(struct sk_buff **head, struct sk_buff *skb, struct udp_offload *uoff) {
const struct net_offload **offloads;
const struct net_offload *ops;
struct sk_buff **pp = NULL;
struct sk_buff *p;
struct guehdr *guehdr;
size_t len, optlen, hdrlen, off;
void *dat... | static struct sk_buff **gue_gro_receive(struct sk_buff **head, struct sk_buff *skb, struct udp_offload *uoff) {
u16 doffset = 0;
off = skb_gro_offset(skb);
len = off + sizeof(*guehdr);
guehdr = skb_gro_header_fast(skb, off);
if (skb_gro_header_hard(skb, len)) {
guehdr = skb_gro_header_slow(s... | static struct sk_buff **gue_gro_receive(struct sk_buff **head, struct sk_buff *skb, struct udp_offload *uoff) {
u16 doffset = 0;
off = skb_gro_offset(skb);
len = off + sizeof(*guehdr);
guehdr = skb_gro_header_fast(skb, off);
if (skb_gro_header_hard(skb, len)) {
guehdr = skb_gro_header_slow(s... | static struct sk_buff **gue_gro_receive(struct sk_buff **head, struct sk_buff *skb, struct udp_offload *uoff) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
u16 doffset = 0;
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
off = skb_gro_offset(skb);
len = off + sizeof(*guehdr);
guehdr = skb_gro_he... | static struct sk_buff **gue_gro_receive(struct sk_buff **head, struct sk_buff *skb, struct udp_offload *uoff) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
u16 doffset = 0;
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
off = skb_gro_offset(skb);
len = off + sizeof(*guehdr);
guehdr = skb_gro_he... | static struct sk_buff **gue_gro_receive(struct sk_buff **head, struct sk_buff *skb, struct udp_offload *uoff) {
u16 doffset = 0;
off = skb_gro_offset(skb);
len = off + sizeof(*guehdr);
guehdr = skb_gro_header_fast(skb, off);
if (skb_gro_header_hard(skb, len)) {
guehdr = skb_gro_header... |
CVE-2016-7039 | linux | https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux | net/ipv4/gre_offload.c | gre_gro_receive | static struct sk_buff **gre_gro_receive(struct sk_buff **head, struct sk_buff *skb) {
struct sk_buff **pp = NULL;
struct sk_buff *p;
const struct gre_base_hdr *greh;
unsigned int hlen, grehlen;
unsigned int off;
int flush = 1;
struct packet_offload *ptype;
__be16 type;
if (NAPI_GRO_C... | static struct sk_buff **gre_gro_receive(struct sk_buff **head, struct sk_buff *skb) {
struct sk_buff **pp = NULL;
struct sk_buff *p;
const struct gre_base_hdr *greh;
unsigned int hlen, grehlen;
unsigned int off;
int flush = 1;
struct packet_offload *ptype;
__be16 type;
if (NAPI_GRO_C... | static struct sk_buff **gre_gro_receive(struct sk_buff **head, struct sk_buff *skb) {
struct sk_buff **pp = NULL;
struct sk_buff *p;
const struct gre_base_hdr *greh;
unsigned int hlen, grehlen;
unsigned int off;
int flush = 1;
struct packet_offload *ptype;
__be16 type;
off = skb_gro_... | static struct sk_buff **gre_gro_receive(struct sk_buff **head, struct sk_buff *skb) {
struct sk_buff **pp = NULL;
struct sk_buff *p;
const struct gre_base_hdr *greh;
unsigned int hlen, grehlen;
unsigned int off;
int flush = 1;
struct packet_offload *ptype;
__be16 type;
off = skb_gro_... | static struct sk_buff **gre_gro_receive(struct sk_buff **head, struct sk_buff *skb) {
if (NAPI_GRO_CB(skb)->encap_mark) {
goto out;
}
NAPI_GRO_CB(skb)->encap_mark = 1;
off = skb_gro_offset(skb);
hlen = off + sizeof(*greh);
greh = skb_gro_header_fast(skb, off);
if (skb_gro_header_hard... | static struct sk_buff **gre_gro_receive(struct sk_buff **head, struct sk_buff *skb) {
if (NAPI_GRO_CB(skb)->encap_mark) {
goto out;
}
NAPI_GRO_CB(skb)->encap_mark = 1;
off = skb_gro_offset(skb);
hlen = off + sizeof(*greh);
greh = skb_gro_header_fast(skb, off);
if (skb_gro_header_hard... | static struct sk_buff **gre_gro_receive(struct sk_buff **head, struct sk_buff *skb) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
off = skb_gro_offset(skb);
hlen = off + sizeof(*greh);
greh = skb_gro_header_fast(skb, off);
if (skb_gro_header_hard(skb, hlen)) {
greh = skb_gro_header_slow(sk... | static struct sk_buff **gre_gro_receive(struct sk_buff **head, struct sk_buff *skb) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
off = skb_gro_offset(skb);
hlen = off + sizeof(*greh);
greh = skb_gro_header_fast(skb, off);
if (skb_gro_header_hard(skb, hlen)) {
greh = skb_gro_header_slow(sk... | static struct sk_buff **gre_gro_receive(struct sk_buff **head, struct sk_buff *skb) {
if (NAPI_GRO_CB(skb)->encap_mark) {
goto out;
}
NAPI_GRO_CB(skb)->encap_mark = 1;
off = skb_gro_offset(skb);
hlen = off + sizeof(*greh);
greh = skb_gro_header_fast(skb, off);
if (skb_gro_he... |
CVE-2016-7039 | linux | https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux | net/ipv4/udp_offload.c | udp_gro_receive | struct sk_buff **udp_gro_receive(struct sk_buff **head, struct sk_buff *skb, struct udphdr *uh) {
struct udp_offload_priv *uo_priv;
struct sk_buff *p, **pp = NULL;
struct udphdr *uh2;
unsigned int off = skb_gro_offset(skb);
int flush = 1;
if (NAPI_GRO_CB(skb)->encap_mark || (skb->ip_summed != CH... | struct sk_buff **udp_gro_receive(struct sk_buff **head, struct sk_buff *skb, struct udphdr *uh) {
struct udp_offload_priv *uo_priv;
struct sk_buff *p, **pp = NULL;
struct udphdr *uh2;
unsigned int off = skb_gro_offset(skb);
int flush = 1;
if (NAPI_GRO_CB(skb)->encap_mark || (skb->ip_summed != CH... | struct sk_buff **udp_gro_receive(struct sk_buff **head, struct sk_buff *skb, struct udphdr *uh) {
struct udp_offload_priv *uo_priv;
struct sk_buff *p, **pp = NULL;
struct udphdr *uh2;
unsigned int off = skb_gro_offset(skb);
int flush = 1;
if (NAPI_GRO_CB(skb)->udp_mark || (skb->ip_summed != CHEC... | struct sk_buff **udp_gro_receive(struct sk_buff **head, struct sk_buff *skb, struct udphdr *uh) {
struct udp_offload_priv *uo_priv;
struct sk_buff *p, **pp = NULL;
struct udphdr *uh2;
unsigned int off = skb_gro_offset(skb);
int flush = 1;
if (NAPI_GRO_CB(skb)->udp_mark || (skb->ip_summed != CHEC... | struct sk_buff **udp_gro_receive(struct sk_buff **head, struct sk_buff *skb, struct udphdr *uh) {
unsigned int off = skb_gro_offset(skb);
if (NAPI_GRO_CB(skb)->encap_mark || (skb->ip_summed != CHECKSUM_PARTIAL && NAPI_GRO_CB(skb)->csum_cnt == 0 && !NAPI_GRO_CB(skb)->csum_valid)) {
goto out;
}
NA... | struct sk_buff **udp_gro_receive(struct sk_buff **head, struct sk_buff *skb, struct udphdr *uh) {
unsigned int off = skb_gro_offset(skb);
if (NAPI_GRO_CB(skb)->encap_mark || (skb->ip_summed != CHECKSUM_PARTIAL && NAPI_GRO_CB(skb)->csum_cnt == 0 && !NAPI_GRO_CB(skb)->csum_valid)) {
goto out;
}
NA... | struct sk_buff **udp_gro_receive(struct sk_buff **head, struct sk_buff *skb, struct udphdr *uh) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
unsigned int off = skb_gro_offset(skb);
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
if (NAPI_GRO_CB(skb)->udp_mark || (skb->ip_summed != CHECKSUM_PARTIAL && N... | struct sk_buff **udp_gro_receive(struct sk_buff **head, struct sk_buff *skb, struct udphdr *uh) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
unsigned int off = skb_gro_offset(skb);
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
if (NAPI_GRO_CB(skb)->udp_mark || (skb->ip_summed != CHECKSUM_PARTIAL && N... | struct sk_buff **udp_gro_receive(struct sk_buff **head, struct sk_buff *skb, struct udphdr *uh) {
unsigned int off = skb_gro_offset(skb);
if (NAPI_GRO_CB(skb)->encap_mark || (skb->ip_summed != CHECKSUM_PARTIAL && NAPI_GRO_CB(skb)->csum_cnt == 0 && !NAPI_GRO_CB(skb)->csum_valid)) {
goto out;
}
... |
CVE-2016-7039 | linux | https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux | net/ipv6/ip6_offload.c | ipv6_gro_receive | static struct sk_buff **ipv6_gro_receive(struct sk_buff **head, struct sk_buff *skb) {
const struct net_offload *ops;
struct sk_buff **pp = NULL;
struct sk_buff *p;
struct ipv6hdr *iph;
unsigned int nlen;
unsigned int hlen;
unsigned int off;
u16 flush = 1;
int proto;
off = skb_gr... | static struct sk_buff **ipv6_gro_receive(struct sk_buff **head, struct sk_buff *skb) {
const struct net_offload *ops;
struct sk_buff **pp = NULL;
struct sk_buff *p;
struct ipv6hdr *iph;
unsigned int nlen;
unsigned int hlen;
unsigned int off;
u16 flush = 1;
int proto;
off = skb_gr... | static struct sk_buff **ipv6_gro_receive(struct sk_buff **head, struct sk_buff *skb) {
const struct net_offload *ops;
struct sk_buff **pp = NULL;
struct sk_buff *p;
struct ipv6hdr *iph;
unsigned int nlen;
unsigned int hlen;
unsigned int off;
u16 flush = 1;
int proto;
off = skb_gr... | static struct sk_buff **ipv6_gro_receive(struct sk_buff **head, struct sk_buff *skb) {
const struct net_offload *ops;
struct sk_buff **pp = NULL;
struct sk_buff *p;
struct ipv6hdr *iph;
unsigned int nlen;
unsigned int hlen;
unsigned int off;
u16 flush = 1;
int proto;
off = skb_gr... | static struct sk_buff **ipv6_gro_receive(struct sk_buff **head, struct sk_buff *skb) {
u16 flush = 1;
off = skb_gro_offset(skb);
hlen = off + sizeof(*iph);
iph = skb_gro_header_fast(skb, off);
if (skb_gro_header_hard(skb, hlen)) {
iph = skb_gro_header_slow(skb, hlen, off);
if (unlike... | static struct sk_buff **ipv6_gro_receive(struct sk_buff **head, struct sk_buff *skb) {
u16 flush = 1;
off = skb_gro_offset(skb);
hlen = off + sizeof(*iph);
iph = skb_gro_header_fast(skb, off);
if (skb_gro_header_hard(skb, hlen)) {
iph = skb_gro_header_slow(skb, hlen, off);
if (unlike... | static struct sk_buff **ipv6_gro_receive(struct sk_buff **head, struct sk_buff *skb) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
u16 flush = 1;
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
off = skb_gro_offset(skb);
hlen = off + sizeof(*iph);
iph = skb_gro_header_fast(skb, off);
if (skb... | static struct sk_buff **ipv6_gro_receive(struct sk_buff **head, struct sk_buff *skb) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
u16 flush = 1;
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
off = skb_gro_offset(skb);
hlen = off + sizeof(*iph);
iph = skb_gro_header_fast(skb, off);
if (skb... | static struct sk_buff **ipv6_gro_receive(struct sk_buff **head, struct sk_buff *skb) {
u16 flush = 1;
off = skb_gro_offset(skb);
hlen = off + sizeof(*iph);
iph = skb_gro_header_fast(skb, off);
if (skb_gro_header_hard(skb, hlen)) {
iph = skb_gro_header_slow(skb, hlen, off);
if... |
CVE-2016-7042 | linux | https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux | security/keys/proc.c | proc_keys_show | static int proc_keys_show(struct seq_file *m, void *v) {
struct rb_node *_p = v;
struct key *key = rb_entry(_p, struct key, serial_node);
struct timespec now;
unsigned long timo;
key_ref_t key_ref, skey_ref;
char xbuf[12];
int rc;
struct keyring_search_context ctx = {
.index_key.... | static int proc_keys_show(struct seq_file *m, void *v) {
struct rb_node *_p = v;
struct key *key = rb_entry(_p, struct key, serial_node);
struct timespec now;
unsigned long timo;
key_ref_t key_ref, skey_ref;
char xbuf[16];
int rc;
struct keyring_search_context ctx = {
.index_key.... | static int proc_keys_show(struct seq_file *m, void *v) {
struct rb_node *_p = v;
struct key *key = rb_entry(_p, struct key, serial_node);
struct timespec now;
unsigned long timo;
key_ref_t key_ref, skey_ref;
char xbuf[12];
int rc;
struct keyring_search_context ctx = {
.index_key.... | static int proc_keys_show(struct seq_file *m, void *v) {
struct rb_node *_p = v;
struct key *key = rb_entry(_p, struct key, serial_node);
struct timespec now;
unsigned long timo;
key_ref_t key_ref, skey_ref;
char xbuf[16];
int rc;
struct keyring_search_context ctx = {
.index_key.... | static int proc_keys_show(struct seq_file *m, void *v) {
key_ref_t key_ref, skey_ref;
char xbuf[12];
int rc;
}
| static int proc_keys_show(struct seq_file *m, void *v) {
key_ref_t key_ref, skey_ref;
char xbuf[16];
int rc;
}
| static int proc_keys_show(struct seq_file *m, void *v) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
key_ref_t key_ref, skey_ref;
char xbuf[12];
int rc;
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
}
| static int proc_keys_show(struct seq_file *m, void *v) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
key_ref_t key_ref, skey_ref;
char xbuf[16];
int rc;
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
} | static int proc_keys_show(struct seq_file *m, void *v) {
key_ref_t key_ref, skey_ref;
- char xbuf[12];
+ char xbuf[16];
int rc;
} |
CVE-2016-7097 | linux | https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux | fs/9p/acl.c | v9fs_xattr_set_acl | static int v9fs_xattr_set_acl(const struct xattr_handler *handler, struct dentry *dentry, const char *name, const void *value, size_t size, int flags) {
int retval;
struct posix_acl *acl;
struct v9fs_session_info *v9ses;
struct inode *inode = d_inode(dentry);
if (strcmp(name, "") != 0) {
ret... | static int v9fs_xattr_set_acl(const struct xattr_handler *handler, struct dentry *dentry, const char *name, const void *value, size_t size, int flags) {
int retval;
struct posix_acl *acl;
struct v9fs_session_info *v9ses;
struct inode *inode = d_inode(dentry);
if (strcmp(name, "") != 0) {
ret... | static int v9fs_xattr_set_acl(struct dentry *dentry, const char *name, const void *value, size_t size, int flags, int type) {
int retval;
struct posix_acl *acl;
struct v9fs_session_info *v9ses;
struct inode *inode = dentry->d_inode;
if (strcmp(name, "") != 0) {
return -EVAL;
}
v9ses ... | static int v9fs_xattr_set_acl(struct dentry *dentry, const char *name, const void *value, size_t size, int flags, int type) {
int retval;
struct posix_acl *acl;
struct v9fs_session_info *v9ses;
struct inode *inode = dentry->d_inode;
if (strcmp(name, "") != 0) {
return -EVAL;
}
v9ses ... | static int v9fs_xattr_set_acl(const struct xattr_handler *handler, struct dentry *dentry, const char *name, const void *value, size_t size, int flags) {
struct inode *inode = d_inode(dentry);
if (S_ISLNK(inode->i_mode)) {
return -EOPNOTSUPP;
}
if (!inode_owner_or_capable(inode)) {
return... | static int v9fs_xattr_set_acl(const struct xattr_handler *handler, struct dentry *dentry, const char *name, const void *value, size_t size, int flags) {
struct inode *inode = d_inode(dentry);
if (S_ISLNK(inode->i_mode)) {
return -EOPNOTSUPP;
}
if (!inode_owner_or_capable(inode)) {
return... | static int v9fs_xattr_set_acl(struct dentry *dentry, const char *name, const void *value, size_t size, int flags, int type) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
struct inode *inode = dentry->d_inode;
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
if (S_ISLNK(inode->i_mode)) {
return -E... | static int v9fs_xattr_set_acl(struct dentry *dentry, const char *name, const void *value, size_t size, int flags, int type) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
struct inode *inode = dentry->d_inode;
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
if (S_ISLNK(inode->i_mode)) {
return -E... | static int v9fs_xattr_set_acl(const struct xattr_handler *handler, struct dentry *dentry, const char *name, const void *value, size_t size, int flags) {
struct inode *inode = d_inode(dentry);
if (S_ISLNK(inode->i_mode)) {
return -EOPNOTSUPP;
}
if (!inode_owner_or_capable(inode)) {
... |
CVE-2016-7097 | linux | https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux | fs/btrfs/acl.c | __btrfs_set_acl | static int __btrfs_set_acl(struct btrfs_trans_handle *trans, struct inode *inode, struct posix_acl *acl, int type) {
int ret, size = 0;
const char *name;
char *value = NULL;
switch (type) {
case ACL_TYPE_ACCESS:
name = POSIX_ACL_XATTR_ACCESS;
if (acl) {
ret = posix_acl_eq... | static int __btrfs_set_acl(struct btrfs_trans_handle *trans, struct inode *inode, struct posix_acl *acl, int type) {
int ret, size = 0;
const char *name;
char *value = NULL;
switch (type) {
case ACL_TYPE_ACCESS:
name = POSIX_ACL_XATTR_ACCESS;
if (acl) {
ret = posix_acl_up... | static int __btrfs_set_acl(struct btrfs_trans_handle *trans, struct inode *inode, struct posix_acl *acl, int type) {
int ret, size = 0;
const char *name;
char *value = NULL;
switch (type) {
case ACL_TYPE_ACCESS:
name = POSIX_ACL_XATTR_ACCESS;
if (acl) {
ret = posix_acl_eq... | static int __btrfs_set_acl(struct btrfs_trans_handle *trans, struct inode *inode, struct posix_acl *acl, int type) {
int ret, size = 0;
const char *name;
char *value = NULL;
switch (type) {
case ACL_TYPE_ACCESS:
name = POSIX_ACL_XATTR_ACCESS;
if (acl) {
ret = posix_acl_up... | static int __btrfs_set_acl(struct btrfs_trans_handle *trans, struct inode *inode, struct posix_acl *acl, int type) {
switch (type) {
case ACL_TYPE_ACCESS:
if (acl) {
ret = posix_acl_equiv_mode(acl, &inode->i_mode);
if (ret < 0) {
return ret;
}
... | static int __btrfs_set_acl(struct btrfs_trans_handle *trans, struct inode *inode, struct posix_acl *acl, int type) {
switch (type) {
case ACL_TYPE_ACCESS:
if (acl) {
ret = posix_acl_update_mode(inode, &inode->i_mode, &acl);
if (ret) {
return ret;
}
... | static int __btrfs_set_acl(struct btrfs_trans_handle *trans, struct inode *inode, struct posix_acl *acl, int type) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
switch (type) {
case ACL_TYPE_ACCESS:
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
if (acl) {
ret = posix_acl_equiv_mode... | static int __btrfs_set_acl(struct btrfs_trans_handle *trans, struct inode *inode, struct posix_acl *acl, int type) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
switch (type) {
case ACL_TYPE_ACCESS:
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
if (acl) {
ret = posix_acl_update_mod... | static int __btrfs_set_acl(struct btrfs_trans_handle *trans, struct inode *inode, struct posix_acl *acl, int type) {
switch (type) {
case ACL_TYPE_ACCESS:
if (acl) {
- ret = posix_acl_equiv_mode(acl, &inode->i_mode);
- if (ret < 0) {
+ ret = posix_acl_update_mode(ino... |
CVE-2016-7097 | linux | https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux | fs/ceph/acl.c | ceph_set_acl | int ceph_set_acl(struct inode *inode, struct posix_acl *acl, int type) {
int ret = 0, size = 0;
const char *name = NULL;
char *value = NULL;
struct iattr newattrs;
umode_t new_mode = inode->i_mode, old_mode = inode->i_mode;
struct dentry *dentry;
switch (type) {
case ACL_TYPE_ACCESS:
... | int ceph_set_acl(struct inode *inode, struct posix_acl *acl, int type) {
int ret = 0, size = 0;
const char *name = NULL;
char *value = NULL;
struct iattr newattrs;
umode_t new_mode = inode->i_mode, old_mode = inode->i_mode;
struct dentry *dentry;
switch (type) {
case ACL_TYPE_ACCESS:
... | int ceph_set_acl(struct inode *inode, struct posix_acl *acl, int type) {
int ret = 0, size = 0;
const char *name = NULL;
char *value = NULL;
struct iattr newattrs;
umode_t new_mode = inode->i_mode, old_mode = inode->i_mode;
struct dentry *dentry;
switch (type) {
case ACL_TYPE_ACCESS:
... | int ceph_set_acl(struct inode *inode, struct posix_acl *acl, int type) {
int ret = 0, size = 0;
const char *name = NULL;
char *value = NULL;
struct iattr newattrs;
umode_t new_mode = inode->i_mode, old_mode = inode->i_mode;
struct dentry *dentry;
switch (type) {
case ACL_TYPE_ACCESS:
... | int ceph_set_acl(struct inode *inode, struct posix_acl *acl, int type) {
umode_t new_mode = inode->i_mode, old_mode = inode->i_mode;
switch (type) {
case ACL_TYPE_ACCESS:
if (acl) {
ret = posix_acl_equiv_mode(acl, &new_mode);
if (ret < 0) {
goto out;
... | int ceph_set_acl(struct inode *inode, struct posix_acl *acl, int type) {
umode_t new_mode = inode->i_mode, old_mode = inode->i_mode;
switch (type) {
case ACL_TYPE_ACCESS:
if (acl) {
ret = posix_acl_update_mode(inode, &new_mode, &acl);
if (ret) {
goto out;
... | int ceph_set_acl(struct inode *inode, struct posix_acl *acl, int type) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
umode_t new_mode = inode->i_mode, old_mode = inode->i_mode;
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
switch (type) {
case ACL_TYPE_ACCESS:
/* PLACEHOLDER: DO NOT DELETE THI... | int ceph_set_acl(struct inode *inode, struct posix_acl *acl, int type) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
umode_t new_mode = inode->i_mode, old_mode = inode->i_mode;
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
switch (type) {
case ACL_TYPE_ACCESS:
/* PLACEHOLDER: DO NOT DELETE THI... | int ceph_set_acl(struct inode *inode, struct posix_acl *acl, int type) {
umode_t new_mode = inode->i_mode, old_mode = inode->i_mode;
switch (type) {
case ACL_TYPE_ACCESS:
if (acl) {
- ret = posix_acl_equiv_mode(acl, &new_mode);
- if (ret < 0) {
+ ret = posix_acl... |
CVE-2016-7097 | linux | https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux | fs/ext2/acl.c | ext2_set_acl | int ext2_set_acl(struct inode *inode, struct posix_acl *acl, int type) {
int name_index;
void *value = NULL;
size_t size = 0;
int error;
switch(type) {
case ACL_TYPE_ACCESS:
name_index = EXT2_XATTR_DEX_POSIX_ACL_ACCESS;
if (acl) {
error = posix_acl_equiv_mode(acl, &in... | int ext2_set_acl(struct inode *inode, struct posix_acl *acl, int type) {
int name_index;
void *value = NULL;
size_t size = 0;
int error;
switch(type) {
case ACL_TYPE_ACCESS:
name_index = EXT2_XATTR_DEX_POSIX_ACL_ACCESS;
if (acl) {
error = posix_acl_update_mode(inode, ... | int ext2_set_acl(struct inode *inode, struct posix_acl *acl, int type) {
int name_index;
void *value = NULL;
size_t size = 0;
int error;
switch(type) {
case ACL_TYPE_ACCESS:
name_index = EXT2_XATTR_DEX_POSIX_ACL_ACCESS;
if (acl) {
error = posix_acl_equiv_mode(acl, &in... | int ext2_set_acl(struct inode *inode, struct posix_acl *acl, int type) {
int name_index;
void *value = NULL;
size_t size = 0;
int error;
switch(type) {
case ACL_TYPE_ACCESS:
name_index = EXT2_XATTR_DEX_POSIX_ACL_ACCESS;
if (acl) {
error = posix_acl_update_mode(inode, ... | int ext2_set_acl(struct inode *inode, struct posix_acl *acl, int type) {
switch(type) {
case ACL_TYPE_ACCESS:
if (acl) {
error = posix_acl_equiv_mode(acl, &inode->i_mode);
if (error < 0) {
return error;
} else {
inode->i_ctime = CURRENT... | int ext2_set_acl(struct inode *inode, struct posix_acl *acl, int type) {
switch(type) {
case ACL_TYPE_ACCESS:
if (acl) {
error = posix_acl_update_mode(inode, &inode->i_mode, &acl);
if (error) {
return error;
}
inode->i_ctime = CURRENT_TIME_... | int ext2_set_acl(struct inode *inode, struct posix_acl *acl, int type) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
switch(type) {
case ACL_TYPE_ACCESS:
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
if (acl) {
error = posix_acl_equiv_mode(acl, &inode->i_mode);
if (erro... | int ext2_set_acl(struct inode *inode, struct posix_acl *acl, int type) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
switch(type) {
case ACL_TYPE_ACCESS:
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
if (acl) {
error = posix_acl_update_mode(inode, &inode->i_mode, &acl);
... | int ext2_set_acl(struct inode *inode, struct posix_acl *acl, int type) {
switch(type) {
case ACL_TYPE_ACCESS:
if (acl) {
- error = posix_acl_equiv_mode(acl, &inode->i_mode);
- if (error < 0) {
+ error = posix_acl_update_mode(inode, &inode->i_mode, &acl);
+ ... |
CVE-2016-7097 | linux | https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux | fs/ext4/acl.c | __ext4_set_acl | static int __ext4_set_acl(handle_t *handle, struct inode *inode, int type, struct posix_acl *acl) {
int name_index;
void *value = NULL;
size_t size = 0;
int error;
switch (type) {
case ACL_TYPE_ACCESS:
name_index = EXT4_XATTR_DEX_POSIX_ACL_ACCESS;
if (acl) {
error = p... | static int __ext4_set_acl(handle_t *handle, struct inode *inode, int type, struct posix_acl *acl) {
int name_index;
void *value = NULL;
size_t size = 0;
int error;
switch (type) {
case ACL_TYPE_ACCESS:
name_index = EXT4_XATTR_DEX_POSIX_ACL_ACCESS;
if (acl) {
error = p... | static int __ext4_set_acl(handle_t *handle, struct inode *inode, int type, struct posix_acl *acl) {
int name_index;
void *value = NULL;
size_t size = 0;
int error;
switch (type) {
case ACL_TYPE_ACCESS:
name_index = EXT4_XATTR_DEX_POSIX_ACL_ACCESS;
if (acl) {
error = p... | static int __ext4_set_acl(handle_t *handle, struct inode *inode, int type, struct posix_acl *acl) {
int name_index;
void *value = NULL;
size_t size = 0;
int error;
switch (type) {
case ACL_TYPE_ACCESS:
name_index = EXT4_XATTR_DEX_POSIX_ACL_ACCESS;
if (acl) {
error = p... | static int __ext4_set_acl(handle_t *handle, struct inode *inode, int type, struct posix_acl *acl) {
switch (type) {
case ACL_TYPE_ACCESS:
if (acl) {
error = posix_acl_equiv_mode(acl, &inode->i_mode);
if (error < 0) {
return error;
} else {
... | static int __ext4_set_acl(handle_t *handle, struct inode *inode, int type, struct posix_acl *acl) {
switch (type) {
case ACL_TYPE_ACCESS:
if (acl) {
error = posix_acl_update_mode(inode, &inode->i_mode, &acl);
if (error) {
return error;
}
in... | static int __ext4_set_acl(handle_t *handle, struct inode *inode, int type, struct posix_acl *acl) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
switch (type) {
case ACL_TYPE_ACCESS:
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
if (acl) {
error = posix_acl_equiv_mode(acl, &inode->i... | static int __ext4_set_acl(handle_t *handle, struct inode *inode, int type, struct posix_acl *acl) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
switch (type) {
case ACL_TYPE_ACCESS:
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
if (acl) {
error = posix_acl_update_mode(inode, &inode... | static int __ext4_set_acl(handle_t *handle, struct inode *inode, int type, struct posix_acl *acl) {
switch (type) {
case ACL_TYPE_ACCESS:
if (acl) {
- error = posix_acl_equiv_mode(acl, &inode->i_mode);
- if (error < 0) {
+ error = posix_acl_update_mode(inode, &inode-... |
CVE-2016-7097 | linux | https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux | fs/f2fs/acl.c | __f2fs_set_acl | static int __f2fs_set_acl(struct inode *inode, int type, struct posix_acl *acl, struct page *ipage) {
struct f2fs_inode_info *fi = F2FS_I(inode);
int name_index;
void *value = NULL;
size_t size = 0;
int error;
switch (type) {
case ACL_TYPE_ACCESS:
name_index = F2FS_XATTR_DEX_POSIX_AC... | static int __f2fs_set_acl(struct inode *inode, int type, struct posix_acl *acl, struct page *ipage) {
struct f2fs_inode_info *fi = F2FS_I(inode);
int name_index;
void *value = NULL;
size_t size = 0;
int error;
switch (type) {
case ACL_TYPE_ACCESS:
name_index = F2FS_XATTR_DEX_POSIX_AC... | static int __f2fs_set_acl(struct inode *inode, int type, struct posix_acl *acl, struct page *ipage) {
struct f2fs_inode_info *fi = F2FS_I(inode);
int name_index;
void *value = NULL;
size_t size = 0;
int error;
switch (type) {
case ACL_TYPE_ACCESS:
name_index = F2FS_XATTR_DEX_POSIX_AC... | static int __f2fs_set_acl(struct inode *inode, int type, struct posix_acl *acl, struct page *ipage) {
struct f2fs_inode_info *fi = F2FS_I(inode);
int name_index;
void *value = NULL;
size_t size = 0;
int error;
switch (type) {
case ACL_TYPE_ACCESS:
name_index = F2FS_XATTR_DEX_POSIX_AC... | static int __f2fs_set_acl(struct inode *inode, int type, struct posix_acl *acl, struct page *ipage) {
struct f2fs_inode_info *fi = F2FS_I(inode);
switch (type) {
case ACL_TYPE_ACCESS:
if (acl) {
error = posix_acl_equiv_mode(acl, &inode->i_mode);
if (error < 0) {
... | static int __f2fs_set_acl(struct inode *inode, int type, struct posix_acl *acl, struct page *ipage) {
struct f2fs_inode_info *fi = F2FS_I(inode);
switch (type) {
case ACL_TYPE_ACCESS:
if (acl) {
error = posix_acl_update_mode(inode, &inode->i_mode, &acl);
if (error) {
... | static int __f2fs_set_acl(struct inode *inode, int type, struct posix_acl *acl, struct page *ipage) {
struct f2fs_inode_info *fi = F2FS_I(inode);
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
switch (type) {
case ACL_TYPE_ACCESS:
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
if (acl) {
... | static int __f2fs_set_acl(struct inode *inode, int type, struct posix_acl *acl, struct page *ipage) {
struct f2fs_inode_info *fi = F2FS_I(inode);
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
switch (type) {
case ACL_TYPE_ACCESS:
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
if (acl) {
... | static int __f2fs_set_acl(struct inode *inode, int type, struct posix_acl *acl, struct page *ipage) {
struct f2fs_inode_info *fi = F2FS_I(inode);
switch (type) {
case ACL_TYPE_ACCESS:
if (acl) {
- error = posix_acl_equiv_mode(acl, &inode->i_mode);
- if (error < 0) {
+ ... |
CVE-2016-7097 | linux | https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux | fs/gfs2/acl.c | gfs2_set_acl | int gfs2_set_acl(struct inode *inode, struct posix_acl *acl, int type) {
int error;
int len;
char *data;
const char *name = gfs2_acl_name(type);
BUG_ON(name == NULL);
if (acl && acl->a_count > GFS2_ACL_MAX_ENTRIES(GFS2_SB(inode))) {
return -E2BIG;
}
if (type == ACL_TYPE_ACCESS) {... | int gfs2_set_acl(struct inode *inode, struct posix_acl *acl, int type) {
int error;
int len;
char *data;
const char *name = gfs2_acl_name(type);
BUG_ON(name == NULL);
if (acl && acl->a_count > GFS2_ACL_MAX_ENTRIES(GFS2_SB(inode))) {
return -E2BIG;
}
if (type == ACL_TYPE_ACCESS) {... | int gfs2_set_acl(struct inode *inode, struct posix_acl *acl, int type) {
int error;
int len;
char *data;
const char *name = gfs2_acl_name(type);
BUG_ON(name == NULL);
if (acl && acl->a_count > GFS2_ACL_MAX_ENTRIES(GFS2_SB(inode))) {
return -E2BIG;
}
if (type == ACL_TYPE_ACCESS) {... | int gfs2_set_acl(struct inode *inode, struct posix_acl *acl, int type) {
int error;
int len;
char *data;
const char *name = gfs2_acl_name(type);
BUG_ON(name == NULL);
if (acl && acl->a_count > GFS2_ACL_MAX_ENTRIES(GFS2_SB(inode))) {
return -E2BIG;
}
if (type == ACL_TYPE_ACCESS) {... | int gfs2_set_acl(struct inode *inode, struct posix_acl *acl, int type) {
const char *name = gfs2_acl_name(type);
BUG_ON(name == NULL);
if (acl && acl->a_count > GFS2_ACL_MAX_ENTRIES(GFS2_SB(inode))) {
return -E2BIG;
}
if (type == ACL_TYPE_ACCESS) {
umode_t mode = inode->i_mode;
... | int gfs2_set_acl(struct inode *inode, struct posix_acl *acl, int type) {
const char *name = gfs2_acl_name(type);
BUG_ON(name == NULL);
if (acl && acl->a_count > GFS2_ACL_MAX_ENTRIES(GFS2_SB(inode))) {
return -E2BIG;
}
if (type == ACL_TYPE_ACCESS) {
umode_t mode = inode->i_mode;
... | int gfs2_set_acl(struct inode *inode, struct posix_acl *acl, int type) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
const char *name = gfs2_acl_name(type);
BUG_ON(name == NULL);
if (acl && acl->a_count > GFS2_ACL_MAX_ENTRIES(GFS2_SB(inode))) {
return -E2BIG;
}
if (type == ACL_TYPE_ACC... | int gfs2_set_acl(struct inode *inode, struct posix_acl *acl, int type) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
const char *name = gfs2_acl_name(type);
BUG_ON(name == NULL);
if (acl && acl->a_count > GFS2_ACL_MAX_ENTRIES(GFS2_SB(inode))) {
return -E2BIG;
}
if (type == ACL_TYPE_ACC... | int gfs2_set_acl(struct inode *inode, struct posix_acl *acl, int type) {
const char *name = gfs2_acl_name(type);
BUG_ON(name == NULL);
if (acl && acl->a_count > GFS2_ACL_MAX_ENTRIES(GFS2_SB(inode))) {
return -E2BIG;
}
if (type == ACL_TYPE_ACCESS) {
umode_t mode = inode->i_mod... |
CVE-2016-7097 | linux | https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux | fs/hfsplus/posix_acl.c | hfsplus_set_posix_acl | int hfsplus_set_posix_acl(struct inode *inode, struct posix_acl *acl, int type) {
int err;
char *xattr_name;
size_t size = 0;
char *value = NULL;
hfs_dbg(ACL_MOD, "[%s]: ino %lu\n", __func__, inode->i_ino);
switch (type) {
case ACL_TYPE_ACCESS:
xattr_name = POSIX_ACL_XATTR_ACCESS;
... | int hfsplus_set_posix_acl(struct inode *inode, struct posix_acl *acl, int type) {
int err;
char *xattr_name;
size_t size = 0;
char *value = NULL;
hfs_dbg(ACL_MOD, "[%s]: ino %lu\n", __func__, inode->i_ino);
switch (type) {
case ACL_TYPE_ACCESS:
xattr_name = POSIX_ACL_XATTR_ACCESS;
... | int hfsplus_set_posix_acl(struct inode *inode, struct posix_acl *acl, int type) {
int err;
char *xattr_name;
size_t size = 0;
char *value = NULL;
hfs_dbg(ACL_MOD, "[%s]: ino %lu\n", __func__, inode->i_ino);
switch (type) {
case ACL_TYPE_ACCESS:
xattr_name = POSIX_ACL_XATTR_ACCESS;
... | int hfsplus_set_posix_acl(struct inode *inode, struct posix_acl *acl, int type) {
int err;
char *xattr_name;
size_t size = 0;
char *value = NULL;
hfs_dbg(ACL_MOD, "[%s]: ino %lu\n", __func__, inode->i_ino);
switch (type) {
case ACL_TYPE_ACCESS:
xattr_name = POSIX_ACL_XATTR_ACCESS;
... | int hfsplus_set_posix_acl(struct inode *inode, struct posix_acl *acl, int type) {
switch (type) {
case ACL_TYPE_ACCESS:
if (acl) {
err = posix_acl_equiv_mode(acl, &inode->i_mode);
if (err < 0) {
return err;
}
}
err = 0;
break;
... | int hfsplus_set_posix_acl(struct inode *inode, struct posix_acl *acl, int type) {
switch (type) {
case ACL_TYPE_ACCESS:
if (acl) {
err = posix_acl_update_mode(inode, &inode->i_mode, &acl);
if (err) {
return err;
}
}
err = 0;
bre... | int hfsplus_set_posix_acl(struct inode *inode, struct posix_acl *acl, int type) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
switch (type) {
case ACL_TYPE_ACCESS:
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
if (acl) {
err = posix_acl_equiv_mode(acl, &inode->i_mode);
... | int hfsplus_set_posix_acl(struct inode *inode, struct posix_acl *acl, int type) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
switch (type) {
case ACL_TYPE_ACCESS:
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
if (acl) {
err = posix_acl_update_mode(inode, &inode->i_mode, &acl);
... | int hfsplus_set_posix_acl(struct inode *inode, struct posix_acl *acl, int type) {
switch (type) {
case ACL_TYPE_ACCESS:
if (acl) {
- err = posix_acl_equiv_mode(acl, &inode->i_mode);
- if (err < 0) {
+ err = posix_acl_update_mode(inode, &inode->i_mode, &acl);
+ ... |
CVE-2016-7097 | linux | https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux | fs/jffs2/acl.c | jffs2_set_acl | int jffs2_set_acl(struct inode *inode, struct posix_acl *acl, int type) {
int rc, xprefix;
switch (type) {
case ACL_TYPE_ACCESS:
xprefix = JFFS2_XPREFIX_ACL_ACCESS;
if (acl) {
umode_t mode = inode->i_mode;
rc = posix_acl_equiv_mode(acl, &mode);
if (rc < 0)... | int jffs2_set_acl(struct inode *inode, struct posix_acl *acl, int type) {
int rc, xprefix;
switch (type) {
case ACL_TYPE_ACCESS:
xprefix = JFFS2_XPREFIX_ACL_ACCESS;
if (acl) {
umode_t mode;
rc = posix_acl_update_mode(inode, &mode, &acl);
if (rc) {
... | int jffs2_set_acl(struct inode *inode, struct posix_acl *acl, int type) {
int rc, xprefix;
switch (type) {
case ACL_TYPE_ACCESS:
xprefix = JFFS2_XPREFIX_ACL_ACCESS;
if (acl) {
umode_t mode = inode->i_mode;
rc = posix_acl_equiv_mode(acl, &mode);
if (rc < 0)... | int jffs2_set_acl(struct inode *inode, struct posix_acl *acl, int type) {
int rc, xprefix;
switch (type) {
case ACL_TYPE_ACCESS:
xprefix = JFFS2_XPREFIX_ACL_ACCESS;
if (acl) {
umode_t mode;
rc = posix_acl_update_mode(inode, &mode, &acl);
if (rc) {
... | int jffs2_set_acl(struct inode *inode, struct posix_acl *acl, int type) {
switch (type) {
case ACL_TYPE_ACCESS:
if (acl) {
umode_t mode = inode->i_mode;
rc = posix_acl_equiv_mode(acl, &mode);
if (rc < 0) {
return rc;
}
if (inode... | int jffs2_set_acl(struct inode *inode, struct posix_acl *acl, int type) {
switch (type) {
case ACL_TYPE_ACCESS:
if (acl) {
umode_t mode;
rc = posix_acl_update_mode(inode, &mode, &acl);
if (rc) {
return rc;
}
if (inode->i_mode !=... | int jffs2_set_acl(struct inode *inode, struct posix_acl *acl, int type) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
switch (type) {
case ACL_TYPE_ACCESS:
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
if (acl) {
umode_t mode = inode->i_mode;
rc = posix_acl_equiv_mode(a... | int jffs2_set_acl(struct inode *inode, struct posix_acl *acl, int type) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
switch (type) {
case ACL_TYPE_ACCESS:
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
if (acl) {
umode_t mode;
rc = posix_acl_update_mode(inode, &mode, &a... | int jffs2_set_acl(struct inode *inode, struct posix_acl *acl, int type) {
switch (type) {
case ACL_TYPE_ACCESS:
if (acl) {
- umode_t mode = inode->i_mode;
- rc = posix_acl_equiv_mode(acl, &mode);
- if (rc < 0) {
+ umode_t mode;
+ rc = posix_acl_... |
CVE-2016-7097 | linux | https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux | fs/jfs/acl.c | __jfs_set_acl | static int __jfs_set_acl(tid_t tid, struct inode *inode, int type, struct posix_acl *acl) {
char *ea_name;
int rc;
int size = 0;
char *value = NULL;
switch (type) {
case ACL_TYPE_ACCESS:
ea_name = POSIX_ACL_XATTR_ACCESS;
if (acl) {
rc = posix_acl_equiv_mode(acl, &inod... | static int __jfs_set_acl(tid_t tid, struct inode *inode, int type, struct posix_acl *acl) {
char *ea_name;
int rc;
int size = 0;
char *value = NULL;
switch (type) {
case ACL_TYPE_ACCESS:
ea_name = POSIX_ACL_XATTR_ACCESS;
if (acl) {
rc = posix_acl_update_mode(inode, &i... | static int __jfs_set_acl(tid_t tid, struct inode *inode, int type, struct posix_acl *acl) {
char *ea_name;
int rc;
int size = 0;
char *value = NULL;
switch (type) {
case ACL_TYPE_ACCESS:
ea_name = POSIX_ACL_XATTR_ACCESS;
if (acl) {
rc = posix_acl_equiv_mode(acl, &inod... | static int __jfs_set_acl(tid_t tid, struct inode *inode, int type, struct posix_acl *acl) {
char *ea_name;
int rc;
int size = 0;
char *value = NULL;
switch (type) {
case ACL_TYPE_ACCESS:
ea_name = POSIX_ACL_XATTR_ACCESS;
if (acl) {
rc = posix_acl_update_mode(inode, &i... | static int __jfs_set_acl(tid_t tid, struct inode *inode, int type, struct posix_acl *acl) {
switch (type) {
case ACL_TYPE_ACCESS:
if (acl) {
rc = posix_acl_equiv_mode(acl, &inode->i_mode);
if (rc < 0) {
return rc;
}
inode->i_ctime = CURRENT... | static int __jfs_set_acl(tid_t tid, struct inode *inode, int type, struct posix_acl *acl) {
switch (type) {
case ACL_TYPE_ACCESS:
if (acl) {
rc = posix_acl_update_mode(inode, &inode->i_mode, &acl);
if (rc) {
return rc;
}
inode->i_ctime = CU... | static int __jfs_set_acl(tid_t tid, struct inode *inode, int type, struct posix_acl *acl) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
switch (type) {
case ACL_TYPE_ACCESS:
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
if (acl) {
rc = posix_acl_equiv_mode(acl, &inode->i_mode);
... | static int __jfs_set_acl(tid_t tid, struct inode *inode, int type, struct posix_acl *acl) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
switch (type) {
case ACL_TYPE_ACCESS:
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
if (acl) {
rc = posix_acl_update_mode(inode, &inode->i_mode, &... | static int __jfs_set_acl(tid_t tid, struct inode *inode, int type, struct posix_acl *acl) {
switch (type) {
case ACL_TYPE_ACCESS:
if (acl) {
- rc = posix_acl_equiv_mode(acl, &inode->i_mode);
- if (rc < 0) {
+ rc = posix_acl_update_mode(inode, &inode->i_mode, &acl);
+... |
CVE-2016-7097 | linux | https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux | fs/ocfs2/acl.c | ocfs2_set_acl | int ocfs2_set_acl(handle_t *handle, struct inode *inode, struct buffer_head *di_bh, int type, struct posix_acl *acl, struct ocfs2_alloc_context *meta_ac, struct ocfs2_alloc_context *data_ac) {
int name_index;
void *value = NULL;
size_t size = 0;
int ret;
if (S_ISLNK(inode->i_mode)) {
return ... | int ocfs2_set_acl(handle_t *handle, struct inode *inode, struct buffer_head *di_bh, int type, struct posix_acl *acl, struct ocfs2_alloc_context *meta_ac, struct ocfs2_alloc_context *data_ac) {
int name_index;
void *value = NULL;
size_t size = 0;
int ret;
if (S_ISLNK(inode->i_mode)) {
return ... | int ocfs2_set_acl(handle_t *handle, struct inode *inode, struct buffer_head *di_bh, int type, struct posix_acl *acl, struct ocfs2_alloc_context *meta_ac, struct ocfs2_alloc_context *data_ac) {
int name_index;
void *value = NULL;
size_t size = 0;
int ret;
if (S_ISLNK(inode->i_mode)) {
return ... | int ocfs2_set_acl(handle_t *handle, struct inode *inode, struct buffer_head *di_bh, int type, struct posix_acl *acl, struct ocfs2_alloc_context *meta_ac, struct ocfs2_alloc_context *data_ac) {
int name_index;
void *value = NULL;
size_t size = 0;
int ret;
if (S_ISLNK(inode->i_mode)) {
return ... | int ocfs2_set_acl(handle_t *handle, struct inode *inode, struct buffer_head *di_bh, int type, struct posix_acl *acl, struct ocfs2_alloc_context *meta_ac, struct ocfs2_alloc_context *data_ac) {
if (S_ISLNK(inode->i_mode)) {
return -EOPNOTSUPP;
}
switch (type) {
case ACL_TYPE_ACCESS:
if (a... | int ocfs2_set_acl(handle_t *handle, struct inode *inode, struct buffer_head *di_bh, int type, struct posix_acl *acl, struct ocfs2_alloc_context *meta_ac, struct ocfs2_alloc_context *data_ac) {
if (S_ISLNK(inode->i_mode)) {
return -EOPNOTSUPP;
}
switch (type) {
case ACL_TYPE_ACCESS:
if (a... | int ocfs2_set_acl(handle_t *handle, struct inode *inode, struct buffer_head *di_bh, int type, struct posix_acl *acl, struct ocfs2_alloc_context *meta_ac, struct ocfs2_alloc_context *data_ac) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
if (S_ISLNK(inode->i_mode)) {
return -EOPNOTSUPP;
}
switc... | int ocfs2_set_acl(handle_t *handle, struct inode *inode, struct buffer_head *di_bh, int type, struct posix_acl *acl, struct ocfs2_alloc_context *meta_ac, struct ocfs2_alloc_context *data_ac) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
if (S_ISLNK(inode->i_mode)) {
return -EOPNOTSUPP;
}
switc... | int ocfs2_set_acl(handle_t *handle, struct inode *inode, struct buffer_head *di_bh, int type, struct posix_acl *acl, struct ocfs2_alloc_context *meta_ac, struct ocfs2_alloc_context *data_ac) {
if (S_ISLNK(inode->i_mode)) {
return -EOPNOTSUPP;
}
switch (type) {
case ACL_TYPE_ACCESS:
... |
CVE-2016-7097 | linux | https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux | fs/reiserfs/xattr_acl.c | __reiserfs_set_acl | static int __reiserfs_set_acl(struct reiserfs_transaction_handle *th, struct inode *inode, int type, struct posix_acl *acl) {
char *name;
void *value = NULL;
size_t size = 0;
int error;
switch (type) {
case ACL_TYPE_ACCESS:
name = POSIX_ACL_XATTR_ACCESS;
if (acl) {
er... | static int __reiserfs_set_acl(struct reiserfs_transaction_handle *th, struct inode *inode, int type, struct posix_acl *acl) {
char *name;
void *value = NULL;
size_t size = 0;
int error;
switch (type) {
case ACL_TYPE_ACCESS:
name = POSIX_ACL_XATTR_ACCESS;
if (acl) {
er... | static int __reiserfs_set_acl(struct reiserfs_transaction_handle *th, struct inode *inode, int type, struct posix_acl *acl) {
char *name;
void *value = NULL;
size_t size = 0;
int error;
switch (type) {
case ACL_TYPE_ACCESS:
name = POSIX_ACL_XATTR_ACCESS;
if (acl) {
er... | static int __reiserfs_set_acl(struct reiserfs_transaction_handle *th, struct inode *inode, int type, struct posix_acl *acl) {
char *name;
void *value = NULL;
size_t size = 0;
int error;
switch (type) {
case ACL_TYPE_ACCESS:
name = POSIX_ACL_XATTR_ACCESS;
if (acl) {
er... | static int __reiserfs_set_acl(struct reiserfs_transaction_handle *th, struct inode *inode, int type, struct posix_acl *acl) {
switch (type) {
case ACL_TYPE_ACCESS:
if (acl) {
error = posix_acl_equiv_mode(acl, &inode->i_mode);
if (error < 0) {
return error;
... | static int __reiserfs_set_acl(struct reiserfs_transaction_handle *th, struct inode *inode, int type, struct posix_acl *acl) {
switch (type) {
case ACL_TYPE_ACCESS:
if (acl) {
error = posix_acl_update_mode(inode, &inode->i_mode, &acl);
if (error) {
return error;
... | static int __reiserfs_set_acl(struct reiserfs_transaction_handle *th, struct inode *inode, int type, struct posix_acl *acl) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
switch (type) {
case ACL_TYPE_ACCESS:
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
if (acl) {
error = posix_acl... | static int __reiserfs_set_acl(struct reiserfs_transaction_handle *th, struct inode *inode, int type, struct posix_acl *acl) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
switch (type) {
case ACL_TYPE_ACCESS:
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
if (acl) {
error = posix_acl... | static int __reiserfs_set_acl(struct reiserfs_transaction_handle *th, struct inode *inode, int type, struct posix_acl *acl) {
switch (type) {
case ACL_TYPE_ACCESS:
if (acl) {
- error = posix_acl_equiv_mode(acl, &inode->i_mode);
- if (error < 0) {
+ error = posix_acl_... |
CVE-2016-7097 | linux | https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux | fs/xfs/xfs_acl.c | xfs_set_acl | int xfs_set_acl(struct inode *inode, struct posix_acl *acl, int type) {
int error = 0;
if (!acl) {
goto set_acl;
}
error = -E2BIG;
if (acl->a_count > XFS_ACL_MAX_ENTRIES(XFS_M(inode->i_sb))) {
return error;
}
if (type == ACL_TYPE_ACCESS) {
umode_t mode = inode->i_mode... | int xfs_set_acl(struct inode *inode, struct posix_acl *acl, int type) {
int error = 0;
if (!acl) {
goto set_acl;
}
error = -E2BIG;
if (acl->a_count > XFS_ACL_MAX_ENTRIES(XFS_M(inode->i_sb))) {
return error;
}
if (type == ACL_TYPE_ACCESS) {
umode_t mode;
error ... | int xfs_set_acl(struct inode *inode, struct posix_acl *acl, int type) {
int error = 0;
if (!acl) {
goto set_acl;
}
error = -E2BIG;
if (acl->a_count > XFS_ACL_MAX_ENTRIES(XFS_M(inode->i_sb))) {
return error;
}
if (type == ACL_TYPE_ACCESS) {
umode_t mode = inode->i_mode... | int xfs_set_acl(struct inode *inode, struct posix_acl *acl, int type) {
int error = 0;
if (!acl) {
goto set_acl;
}
error = -E2BIG;
if (acl->a_count > XFS_ACL_MAX_ENTRIES(XFS_M(inode->i_sb))) {
return error;
}
if (type == ACL_TYPE_ACCESS) {
umode_t mode;
error ... | int xfs_set_acl(struct inode *inode, struct posix_acl *acl, int type) {
if (!acl) {
goto set_acl;
}
if (type == ACL_TYPE_ACCESS) {
umode_t mode = inode->i_mode;
error = posix_acl_equiv_mode(acl, &mode);
if (error <= 0) {
acl = NULL;
if (error < 0) {
... | int xfs_set_acl(struct inode *inode, struct posix_acl *acl, int type) {
if (!acl) {
goto set_acl;
}
if (type == ACL_TYPE_ACCESS) {
umode_t mode;
error = posix_acl_update_mode(inode, &mode, &acl);
if (error) {
return error;
}
error = xfs_set_mode(in... | int xfs_set_acl(struct inode *inode, struct posix_acl *acl, int type) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
if (!acl) {
goto set_acl;
}
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
if (type == ACL_TYPE_ACCESS) {
umode_t mode = inode->i_mode;
error = posix_acl_equiv... | int xfs_set_acl(struct inode *inode, struct posix_acl *acl, int type) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
if (!acl) {
goto set_acl;
}
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
if (type == ACL_TYPE_ACCESS) {
umode_t mode;
error = posix_acl_update_mode(inode, &m... | int xfs_set_acl(struct inode *inode, struct posix_acl *acl, int type) {
if (!acl) {
goto set_acl;
}
if (type == ACL_TYPE_ACCESS) {
- umode_t mode = inode->i_mode;
- error = posix_acl_equiv_mode(acl, &mode);
- if (error <= 0) {
- acl = NULL;
- if (error... |
CVE-2016-7117 | linux | https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux | net/socket.c | __sys_recvmmsg | int __sys_recvmmsg(int fd, struct mmsghdr *mmsg, unsigned int vlen, unsigned int flags, struct timespec *timeout) {
int fput_needed, err, datagrams;
struct socket *sock;
struct mmsghdr *entry;
struct compat_mmsghdr *compat_entry;
struct msghdr msg_sys;
struct timespec end_time;
if (timeout &... | int __sys_recvmmsg(int fd, struct mmsghdr *mmsg, unsigned int vlen, unsigned int flags, struct timespec *timeout) {
int fput_needed, err, datagrams;
struct socket *sock;
struct mmsghdr *entry;
struct compat_mmsghdr *compat_entry;
struct msghdr msg_sys;
struct timespec end_time;
if (timeout &... | int __sys_recvmmsg(int fd, struct mmsghdr *mmsg, unsigned int vlen, unsigned int flags, struct timespec *timeout) {
int fput_needed, err, datagrams;
struct socket *sock;
struct mmsghdr *entry;
struct compat_mmsghdr *compat_entry;
struct msghdr msg_sys;
struct timespec end_time;
if (timeout &... | int __sys_recvmmsg(int fd, struct mmsghdr *mmsg, unsigned int vlen, unsigned int flags, struct timespec *timeout) {
int fput_needed, err, datagrams;
struct socket *sock;
struct mmsghdr *entry;
struct compat_mmsghdr *compat_entry;
struct msghdr msg_sys;
struct timespec end_time;
if (timeout &... | int __sys_recvmmsg(int fd, struct mmsghdr *mmsg, unsigned int vlen, unsigned int flags, struct timespec *timeout) {
datagrams = 0;
sock = sockfd_lookup_light(fd, &err, &fput_needed);
if (!sock) {
return err;
}
err = sock_error(sock->sk);
if (err) {
goto out_put;
}
entry =... | int __sys_recvmmsg(int fd, struct mmsghdr *mmsg, unsigned int vlen, unsigned int flags, struct timespec *timeout) {
datagrams = 0;
sock = sockfd_lookup_light(fd, &err, &fput_needed);
if (!sock) {
return err;
}
err = sock_error(sock->sk);
if (err) {
goto out_put;
}
entry =... | int __sys_recvmmsg(int fd, struct mmsghdr *mmsg, unsigned int vlen, unsigned int flags, struct timespec *timeout) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
datagrams = 0;
sock = sockfd_lookup_light(fd, &err, &fput_needed);
if (!sock) {
return err;
}
err = sock_error(sock->sk);
... | int __sys_recvmmsg(int fd, struct mmsghdr *mmsg, unsigned int vlen, unsigned int flags, struct timespec *timeout) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
datagrams = 0;
sock = sockfd_lookup_light(fd, &err, &fput_needed);
if (!sock) {
return err;
}
err = sock_error(sock->sk);
... | int __sys_recvmmsg(int fd, struct mmsghdr *mmsg, unsigned int vlen, unsigned int flags, struct timespec *timeout) {
datagrams = 0;
sock = sockfd_lookup_light(fd, &err, &fput_needed);
if (!sock) {
return err;
}
err = sock_error(sock->sk);
if (err) {
goto out_put;
}
... |
CVE-2016-7425 | linux | https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux | drivers/scsi/arcmsr/arcmsr_hba.c | arcmsr_iop_message_xfer | static int arcmsr_iop_message_xfer(struct AdapterControlBlock *acb, struct scsi_cmnd *cmd) {
char *buffer;
unsigned short use_sg;
int retvalue = 0, transfer_len = 0;
unsigned long flags;
struct CMD_MESSAGE_FIELD *pcmdmessagefld;
uint32_t controlcode = (uint32_t)cmd->cmnd[5] << 24 | (uint32_t)cmd... | static int arcmsr_iop_message_xfer(struct AdapterControlBlock *acb, struct scsi_cmnd *cmd) {
char *buffer;
unsigned short use_sg;
int retvalue = 0, transfer_len = 0;
unsigned long flags;
struct CMD_MESSAGE_FIELD *pcmdmessagefld;
uint32_t controlcode = (uint32_t)cmd->cmnd[5] << 24 | (uint32_t)cmd... | static int arcmsr_iop_message_xfer(struct AdapterControlBlock *acb, struct scsi_cmnd *cmd) {
char *buffer;
unsigned short use_sg;
int retvalue = 0, transfer_len = 0;
unsigned long flags;
struct CMD_MESSAGE_FIELD *pcmdmessagefld;
uint32_t controlcode = (uint32_t)cmd->cmnd[5] << 24 | (uint32_t)cmd... | static int arcmsr_iop_message_xfer(struct AdapterControlBlock *acb, struct scsi_cmnd *cmd) {
char *buffer;
unsigned short use_sg;
int retvalue = 0, transfer_len = 0;
unsigned long flags;
struct CMD_MESSAGE_FIELD *pcmdmessagefld;
uint32_t controlcode = (uint32_t)cmd->cmnd[5] << 24 | (uint32_t)cmd... | static int arcmsr_iop_message_xfer(struct AdapterControlBlock *acb, struct scsi_cmnd *cmd) {
switch (controlcode) {
case ARCMSR_MESSAGE_WRITE_WQBUFFER: {
unsigned char *ver_addr;
int32_t user_len, cnt2end;
uint8_t *pQbuffer, *ptmpuserbuffer;
ver_addr = kmalloc(ARCMS_DATA_BUFLEN, ... | static int arcmsr_iop_message_xfer(struct AdapterControlBlock *acb, struct scsi_cmnd *cmd) {
switch (controlcode) {
case ARCMSR_MESSAGE_WRITE_WQBUFFER: {
unsigned char *ver_addr;
uint32_t user_len;
int32_t cnt2end;
uint8_t *pQbuffer, *ptmpuserbuffer;
ver_addr = kmalloc(AR... | static int arcmsr_iop_message_xfer(struct AdapterControlBlock *acb, struct scsi_cmnd *cmd) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
switch (controlcode) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
case ARCMSR_MESSAGE_WRITE_WQBUFFER: {
unsigned char *ver_addr;
int32_t user_len,... | static int arcmsr_iop_message_xfer(struct AdapterControlBlock *acb, struct scsi_cmnd *cmd) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
switch (controlcode) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
case ARCMSR_MESSAGE_WRITE_WQBUFFER: {
unsigned char *ver_addr;
uint32_t user_len... | static int arcmsr_iop_message_xfer(struct AdapterControlBlock *acb, struct scsi_cmnd *cmd) {
switch (controlcode) {
case ARCMSR_MESSAGE_WRITE_WQBUFFER: {
unsigned char *ver_addr;
- int32_t user_len, cnt2end;
+ uint32_t user_len;
+ int32_t cnt2end;
uint8_t *pQbuffer, *pt... |
CVE-2016-7910 | linux | https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux | block/genhd.c | disk_seqf_stop | static void disk_seqf_stop(struct seq_file *seqf, void *v) {
struct class_dev_iter *iter = seqf->private;
if (iter) {
class_dev_iter_exit(iter);
kfree(iter);
}
} | static void disk_seqf_stop(struct seq_file *seqf, void *v) {
struct class_dev_iter *iter = seqf->private;
if (iter) {
class_dev_iter_exit(iter);
kfree(iter);
seqf->private = NULL;
}
} | static void disk_seqf_stop(struct seq_file *seqf, void *v) {
struct class_dev_iter *iter = seqf->private;
if (iter) {
class_dev_iter_exit(iter);
kfree(iter);
}
} | static void disk_seqf_stop(struct seq_file *seqf, void *v) {
struct class_dev_iter *iter = seqf->private;
if (iter) {
class_dev_iter_exit(iter);
kfree(iter);
seqf->private = NULL;
}
} | static void disk_seqf_stop(struct seq_file *seqf, void *v) {
struct class_dev_iter *iter = seqf->private;
if (iter) {
class_dev_iter_exit(iter);
kfree(iter);
}
}
| static void disk_seqf_stop(struct seq_file *seqf, void *v) {
struct class_dev_iter *iter = seqf->private;
if (iter) {
class_dev_iter_exit(iter);
kfree(iter);
seqf->private = NULL;
}
}
| static void disk_seqf_stop(struct seq_file *seqf, void *v) {
struct class_dev_iter *iter = seqf->private;
if (iter) {
class_dev_iter_exit(iter);
kfree(iter);
}
}
| static void disk_seqf_stop(struct seq_file *seqf, void *v) {
struct class_dev_iter *iter = seqf->private;
if (iter) {
class_dev_iter_exit(iter);
kfree(iter);
seqf->private = NULL;
}
} | static void disk_seqf_stop(struct seq_file *seqf, void *v) {
struct class_dev_iter *iter = seqf->private;
if (iter) {
class_dev_iter_exit(iter);
kfree(iter);
+ seqf->private = NULL;
}
} |
CVE-2016-7911 | linux | https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux | fs/ioprio.c | get_task_ioprio | static int get_task_ioprio(struct task_struct *p) {
int ret;
ret = security_task_getioprio(p);
if (ret) {
goto out;
}
ret = IOPRIO_PRIO_VALUE(IOPRIO_CLASS_NONE, IOPRIO_NORM);
if (p->io_context) {
ret = p->io_context->ioprio;
}
out:
return ret;
} | static int get_task_ioprio(struct task_struct *p) {
int ret;
ret = security_task_getioprio(p);
if (ret) {
goto out;
}
ret = IOPRIO_PRIO_VALUE(IOPRIO_CLASS_NONE, IOPRIO_NORM);
task_lock(p);
if (p->io_context) {
ret = p->io_context->ioprio;
}
task_unlock(p);
out:
re... | static int get_task_ioprio(struct task_struct *p) {
int ret;
ret = security_task_getioprio(p);
if (ret) {
goto out;
}
ret = IOPRIO_PRIO_VALUE(IOPRIO_CLASS_NONE, IOPRIO_NORM);
if (p->io_context) {
ret = p->io_context->ioprio;
}
out:
return ret;
} | static int get_task_ioprio(struct task_struct *p) {
int ret;
ret = security_task_getioprio(p);
if (ret) {
goto out;
}
ret = IOPRIO_PRIO_VALUE(IOPRIO_CLASS_NONE, IOPRIO_NORM);
task_lock(p);
if (p->io_context) {
ret = p->io_context->ioprio;
}
task_unlock(p);
out:
re... | static int get_task_ioprio(struct task_struct *p) {
ret = security_task_getioprio(p);
ret = IOPRIO_PRIO_VALUE(IOPRIO_CLASS_NONE, IOPRIO_NORM);
if (p->io_context) {
ret = p->io_context->ioprio;
}
out:
return ret;
}
| static int get_task_ioprio(struct task_struct *p) {
ret = security_task_getioprio(p);
ret = IOPRIO_PRIO_VALUE(IOPRIO_CLASS_NONE, IOPRIO_NORM);
task_lock(p);
if (p->io_context) {
ret = p->io_context->ioprio;
}
task_unlock(p);
out:
return ret;
}
| static int get_task_ioprio(struct task_struct *p) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
ret = security_task_getioprio(p);
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
ret = IOPRIO_PRIO_VALUE(IOPRIO_CLASS_NONE, IOPRIO_NORM);
if (p->io_context) {
ret = p->io_context->ioprio;
}
o... | static int get_task_ioprio(struct task_struct *p) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
ret = security_task_getioprio(p);
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
ret = IOPRIO_PRIO_VALUE(IOPRIO_CLASS_NONE, IOPRIO_NORM);
task_lock(p);
if (p->io_context) {
ret = p->io_contex... | static int get_task_ioprio(struct task_struct *p) {
ret = security_task_getioprio(p);
ret = IOPRIO_PRIO_VALUE(IOPRIO_CLASS_NONE, IOPRIO_NORM);
+ task_lock(p);
if (p->io_context) {
ret = p->io_context->ioprio;
}
+ task_unlock(p);
out:
return ret;
} |
CVE-2016-7912 | linux | https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux | drivers/usb/gadget/f_fs.c | ffs_user_copy_worker | static void ffs_user_copy_worker(struct work_struct *work) {
struct ffs_io_data *io_data = container_of(work, struct ffs_io_data, work);
int ret = io_data->req->status ? io_data->req->status :
io_data->req->actual;
if (io_data->read && ret > 0) {
use_mm(io_data->mm);
ret = copy... | static void ffs_user_copy_worker(struct work_struct *work) {
struct ffs_io_data *io_data = container_of(work, struct ffs_io_data, work);
int ret = io_data->req->status ? io_data->req->status :
io_data->req->actual;
bool kiocb_has_eventfd = io_data->kiocb->ki_flags & IOCB_EVENTFD;
if (io_da... | static void ffs_user_copy_worker(struct work_struct *work) {
struct ffs_io_data *io_data = container_of(work, struct ffs_io_data, work);
int ret = io_data->req->status ? io_data->req->status :
io_data->req->actual;
if (io_data->read && ret > 0) {
int i;
size_t pos = 0;
... | static void ffs_user_copy_worker(struct work_struct *work) {
struct ffs_io_data *io_data = container_of(work, struct ffs_io_data, work);
int ret = io_data->req->status ? io_data->req->status :
io_data->req->actual;
if (io_data->read && ret > 0) {
int i;
size_t pos = 0;
... | static void ffs_user_copy_worker(struct work_struct *work) {
int ret = io_data->req->status ? io_data->req->status :
io_data->req->actual;
io_data->kiocb->ki_complete(io_data->kiocb, ret, ret);
if (io_data->ffs->ffs_eventfd && !(io_data->kiocb->ki_flags & IOCB_EVENTFD)) {
eventfd_signa... | static void ffs_user_copy_worker(struct work_struct *work) {
int ret = io_data->req->status ? io_data->req->status :
io_data->req->actual;
bool kiocb_has_eventfd = io_data->kiocb->ki_flags & IOCB_EVENTFD;
io_data->kiocb->ki_complete(io_data->kiocb, ret, ret);
if (io_data->ffs->ffs_eventfd ... | static void ffs_user_copy_worker(struct work_struct *work) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
int ret = io_data->req->status ? io_data->req->status :
io_data->req->actual;
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
aio_complete(io_data->kiocb, ret, ret);
usb_ep_free_req... | static void ffs_user_copy_worker(struct work_struct *work) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
int ret = io_data->req->status ? io_data->req->status :
io_data->req->actual;
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
aio_complete(io_data->kiocb, ret, ret);
usb_ep_free_req... | static void ffs_user_copy_worker(struct work_struct *work) {
int ret = io_data->req->status ? io_data->req->status :
io_data->req->actual;
+ bool kiocb_has_eventfd = io_data->kiocb->ki_flags & IOCB_EVENTFD;
io_data->kiocb->ki_complete(io_data->kiocb, ret, ret);
- if (io_data->ffs->ffs_ev... |
CVE-2016-7913 | linux | https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux | drivers/media/tuners/tuner-xc2028.c | xc2028_set_config | static int xc2028_set_config(struct dvb_frontend *fe, void *priv_cfg) {
struct xc2028_data *priv = fe->tuner_priv;
struct xc2028_ctrl *p = priv_cfg;
int rc = 0;
tuner_dbg("%s called\n", __func__);
mutex_lock(&priv->lock);
kfree(priv->ctrl.fname);
memcpy(&priv->ctrl, p, sizeof(priv->ctrl));
... | static int xc2028_set_config(struct dvb_frontend *fe, void *priv_cfg) {
struct xc2028_data *priv = fe->tuner_priv;
struct xc2028_ctrl *p = priv_cfg;
int rc = 0;
tuner_dbg("%s called\n", __func__);
mutex_lock(&priv->lock);
kfree(priv->ctrl.fname);
priv->ctrl.fname = NULL;
memcpy(&priv->ct... | static int xc2028_set_config(struct dvb_frontend *fe, void *priv_cfg) {
struct xc2028_data *priv = fe->tuner_priv;
struct xc2028_ctrl *p = priv_cfg;
int rc = 0;
tuner_dbg("%s called\n", __func__);
mutex_lock(&priv->lock);
kfree(priv->ctrl.fname);
memcpy(&priv->ctrl, p, sizeof(priv->ctrl));
... | static int xc2028_set_config(struct dvb_frontend *fe, void *priv_cfg) {
struct xc2028_data *priv = fe->tuner_priv;
struct xc2028_ctrl *p = priv_cfg;
int rc = 0;
tuner_dbg("%s called\n", __func__);
mutex_lock(&priv->lock);
kfree(priv->ctrl.fname);
priv->ctrl.fname = NULL;
memcpy(&priv->ct... | static int xc2028_set_config(struct dvb_frontend *fe, void *priv_cfg) {
kfree(priv->ctrl.fname);
memcpy(&priv->ctrl, p, sizeof(priv->ctrl));
if (p->fname) {
priv->ctrl.fname = kstrdup(p->fname, GFP_KERNEL);
if (priv->ctrl.fname == NULL) {
rc = -ENOMEM;
}
}
if (!fi... | static int xc2028_set_config(struct dvb_frontend *fe, void *priv_cfg) {
kfree(priv->ctrl.fname);
priv->ctrl.fname = NULL;
memcpy(&priv->ctrl, p, sizeof(priv->ctrl));
if (p->fname) {
priv->ctrl.fname = kstrdup(p->fname, GFP_KERNEL);
if (priv->ctrl.fname == NULL) {
return -ENOM... | static int xc2028_set_config(struct dvb_frontend *fe, void *priv_cfg) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
kfree(priv->ctrl.fname);
memcpy(&priv->ctrl, p, sizeof(priv->ctrl));
if (p->fname) {
priv->ctrl.fname = kstrdup(p->fname, GFP_KERNEL);
if (priv->ctrl.fname == NULL) {
... | static int xc2028_set_config(struct dvb_frontend *fe, void *priv_cfg) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
kfree(priv->ctrl.fname);
priv->ctrl.fname = NULL;
memcpy(&priv->ctrl, p, sizeof(priv->ctrl));
if (p->fname) {
priv->ctrl.fname = kstrdup(p->fname, GFP_KERNEL);
if (pr... | static int xc2028_set_config(struct dvb_frontend *fe, void *priv_cfg) {
kfree(priv->ctrl.fname);
+ priv->ctrl.fname = NULL;
memcpy(&priv->ctrl, p, sizeof(priv->ctrl));
if (p->fname) {
priv->ctrl.fname = kstrdup(p->fname, GFP_KERNEL);
if (priv->ctrl.fname == NULL) {
- rc =... |
CVE-2016-7914 | linux | https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux | lib/assoc_array.c | assoc_array_insert_into_terminal_node | static bool assoc_array_insert_into_terminal_node(struct assoc_array_edit *edit, const struct assoc_array_ops *ops, const void *index_key, struct assoc_array_walk_result *result) {
struct assoc_array_shortcut *shortcut, *new_s0;
struct assoc_array_node *node, *new_n0, *new_n1, *side;
struct assoc_array_ptr ... | static bool assoc_array_insert_into_terminal_node(struct assoc_array_edit *edit, const struct assoc_array_ops *ops, const void *index_key, struct assoc_array_walk_result *result) {
struct assoc_array_shortcut *shortcut, *new_s0;
struct assoc_array_node *node, *new_n0, *new_n1, *side;
struct assoc_array_ptr ... | static bool assoc_array_insert_into_terminal_node(struct assoc_array_edit *edit, const struct assoc_array_ops *ops, const void *index_key, struct assoc_array_walk_result *result) {
struct assoc_array_shortcut *shortcut, *new_s0;
struct assoc_array_node *node, *new_n0, *new_n1, *side;
struct assoc_array_ptr ... | static bool assoc_array_insert_into_terminal_node(struct assoc_array_edit *edit, const struct assoc_array_ops *ops, const void *index_key, struct assoc_array_walk_result *result) {
struct assoc_array_shortcut *shortcut, *new_s0;
struct assoc_array_node *node, *new_n0, *new_n1, *side;
struct assoc_array_ptr ... | static bool assoc_array_insert_into_terminal_node(struct assoc_array_edit *edit, const struct assoc_array_ops *ops, const void *index_key, struct assoc_array_walk_result *result) {
for (i = 0; i < ASSOC_ARRAY_FAN_; i++) {
ptr = node->slots[i];
if (ops->compare_object(assoc_array_ptr_to_leaf(ptr), in... | static bool assoc_array_insert_into_terminal_node(struct assoc_array_edit *edit, const struct assoc_array_ops *ops, const void *index_key, struct assoc_array_walk_result *result) {
for (i = 0; i < ASSOC_ARRAY_FAN_; i++) {
ptr = node->slots[i];
if (assoc_array_ptr_is_leaf(ptr) && ops->compare_object(... | static bool assoc_array_insert_into_terminal_node(struct assoc_array_edit *edit, const struct assoc_array_ops *ops, const void *index_key, struct assoc_array_walk_result *result) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
for (i = 0; i < ASSOC_ARRAY_FAN_; i++) {
ptr = node->slots[i];
/* PLACEHO... | static bool assoc_array_insert_into_terminal_node(struct assoc_array_edit *edit, const struct assoc_array_ops *ops, const void *index_key, struct assoc_array_walk_result *result) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
for (i = 0; i < ASSOC_ARRAY_FAN_; i++) {
ptr = node->slots[i];
/* PLACEHO... | static bool assoc_array_insert_into_terminal_node(struct assoc_array_edit *edit, const struct assoc_array_ops *ops, const void *index_key, struct assoc_array_walk_result *result) {
for (i = 0; i < ASSOC_ARRAY_FAN_; i++) {
ptr = node->slots[i];
- if (ops->compare_object(assoc_array_ptr_to_leaf(ptr)... |
CVE-2016-7915 | linux | https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux | drivers/hid/hid-core.c | hid_input_field | static void hid_input_field(struct hid_device *hid, struct hid_field *field, __u8 *data, int interrupt) {
unsigned n;
unsigned count = field->report_count;
unsigned offset = field->report_offset;
unsigned size = field->report_size;
__s32 min = field->logical_minimum;
__s32 max = field->logical_m... | static void hid_input_field(struct hid_device *hid, struct hid_field *field, __u8 *data, int interrupt) {
unsigned n;
unsigned count = field->report_count;
unsigned offset = field->report_offset;
unsigned size = field->report_size;
__s32 min = field->logical_minimum;
__s32 max = field->logical_m... | static void hid_input_field(struct hid_device *hid, struct hid_field *field, __u8 *data, int interrupt) {
unsigned n;
unsigned count = field->report_count;
unsigned offset = field->report_offset;
unsigned size = field->report_size;
__s32 min = field->logical_minimum;
__s32 max = field->logical_m... | static void hid_input_field(struct hid_device *hid, struct hid_field *field, __u8 *data, int interrupt) {
unsigned n;
unsigned count = field->report_count;
unsigned offset = field->report_offset;
unsigned size = field->report_size;
__s32 min = field->logical_minimum;
__s32 max = field->logical_m... | static void hid_input_field(struct hid_device *hid, struct hid_field *field, __u8 *data, int interrupt) {
unsigned count = field->report_count;
unsigned offset = field->report_offset;
unsigned size = field->report_size;
__s32 min = field->logical_minimum;
__s32 max = field->logical_maximum;
valu... | static void hid_input_field(struct hid_device *hid, struct hid_field *field, __u8 *data, int interrupt) {
unsigned count = field->report_count;
unsigned offset = field->report_offset;
unsigned size = field->report_size;
__s32 min = field->logical_minimum;
__s32 max = field->logical_maximum;
valu... | static void hid_input_field(struct hid_device *hid, struct hid_field *field, __u8 *data, int interrupt) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
unsigned count = field->report_count;
unsigned offset = field->report_offset;
unsigned size = field->report_size;
__s32 min = field->logical_minimum... | static void hid_input_field(struct hid_device *hid, struct hid_field *field, __u8 *data, int interrupt) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
unsigned count = field->report_count;
unsigned offset = field->report_offset;
unsigned size = field->report_size;
__s32 min = field->logical_minimum... | static void hid_input_field(struct hid_device *hid, struct hid_field *field, __u8 *data, int interrupt) {
unsigned count = field->report_count;
unsigned offset = field->report_offset;
unsigned size = field->report_size;
__s32 min = field->logical_minimum;
__s32 max = field->logical_maximum;
... |
CVE-2016-7916 | linux | https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux | fs/proc/base.c | environ_read | static ssize_t environ_read(struct file *file, char *buf, size_t count, loff_t *ppos) {
char *page;
unsigned long src = *ppos;
int ret = 0;
struct mm_struct *mm = file->private_data;
if (!mm) {
return 0;
}
page = (char *)__get_free_page(GFP_TEMPORARY);
if (!page) {
return... | static ssize_t environ_read(struct file *file, char *buf, size_t count, loff_t *ppos) {
char *page;
unsigned long src = *ppos;
int ret = 0;
struct mm_struct *mm = file->private_data;
if (!mm || !mm->env_end) {
return 0;
}
page = (char *)__get_free_page(GFP_TEMPORARY);
if (!page) ... | static ssize_t environ_read(struct file *file, char *buf, size_t count, loff_t *ppos) {
char *page;
unsigned long src = *ppos;
int ret = 0;
struct mm_struct *mm = file->private_data;
if (!mm) {
return 0;
}
page = (char *)__get_free_page(GFP_TEMPORARY);
if (!page) {
return... | static ssize_t environ_read(struct file *file, char *buf, size_t count, loff_t *ppos) {
char *page;
unsigned long src = *ppos;
int ret = 0;
struct mm_struct *mm = file->private_data;
if (!mm || !mm->env_end) {
return 0;
}
page = (char *)__get_free_page(GFP_TEMPORARY);
if (!page) ... | static ssize_t environ_read(struct file *file, char *buf, size_t count, loff_t *ppos) {
struct mm_struct *mm = file->private_data;
if (!mm) {
return 0;
}
page = (char *)__get_free_page(GFP_TEMPORARY);
if (!atomic_inc_not_zero(&mm->mm_users)) {
goto free;
}
while (count > 0) {... | static ssize_t environ_read(struct file *file, char *buf, size_t count, loff_t *ppos) {
struct mm_struct *mm = file->private_data;
if (!mm || !mm->env_end) {
return 0;
}
page = (char *)__get_free_page(GFP_TEMPORARY);
if (!atomic_inc_not_zero(&mm->mm_users)) {
goto free;
}
whi... | static ssize_t environ_read(struct file *file, char *buf, size_t count, loff_t *ppos) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
struct mm_struct *mm = file->private_data;
if (!mm) {
return 0;
}
page = (char *)__get_free_page(GFP_TEMPORARY);
/* PLACEHOLDER: DO NOT DELETE THIS COMMEN... | static ssize_t environ_read(struct file *file, char *buf, size_t count, loff_t *ppos) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
struct mm_struct *mm = file->private_data;
if (!mm || !mm->env_end) {
return 0;
}
page = (char *)__get_free_page(GFP_TEMPORARY);
/* PLACEHOLDER: DO NOT DE... | static ssize_t environ_read(struct file *file, char *buf, size_t count, loff_t *ppos) {
struct mm_struct *mm = file->private_data;
- if (!mm) {
+ if (!mm || !mm->env_end) {
return 0;
}
page = (char *)__get_free_page(GFP_TEMPORARY);
if (!atomic_inc_not_zero(&mm->mm_users)) {
... |
CVE-2016-8399 | linux | https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux | net/ipv4/ping.c | ping_common_sendmsg | int ping_common_sendmsg(int family, struct msghdr *msg, size_t len, void *user_icmph, size_t icmph_len) {
u8 type, code;
if (len > 0xFFFF) {
return -EMSGSIZE;
}
if (msg->msg_flags & MSG_OOB) {
return -EOPNOTSUPP;
}
if (memcpy_from_msg(user_icmph, msg, icmph_len)) {
return... | int ping_common_sendmsg(int family, struct msghdr *msg, size_t len, void *user_icmph, size_t icmph_len) {
u8 type, code;
if (len > 0xFFFF) {
return -EMSGSIZE;
}
if (len < icmph_len) {
return -EVAL;
}
if (msg->msg_flags & MSG_OOB) {
return -EOPNOTSUPP;
}
if (memcpy... | int ping_common_sendmsg(int family, struct msghdr *msg, size_t len, void *user_icmph, size_t icmph_len) {
u8 type, code;
if (len > 0xFFFF) {
return -EMSGSIZE;
}
if (msg->msg_flags & MSG_OOB) {
return -EOPNOTSUPP;
}
if (memcpy_from_msg(user_icmph, msg, icmph_len)) {
return... | int ping_common_sendmsg(int family, struct msghdr *msg, size_t len, void *user_icmph, size_t icmph_len) {
u8 type, code;
if (len > 0xFFFF) {
return -EMSGSIZE;
}
if (len < icmph_len) {
return -EVAL;
}
if (msg->msg_flags & MSG_OOB) {
return -EOPNOTSUPP;
}
if (memcpy... | int ping_common_sendmsg(int family, struct msghdr *msg, size_t len, void *user_icmph, size_t icmph_len) {
if (len > 0xFFFF) {
return -EMSGSIZE;
}
if (msg->msg_flags & MSG_OOB) {
return -EOPNOTSUPP;
}
if (memcpy_from_msg(user_icmph, msg, icmph_len)) {
return -EFAULT;
}
... | int ping_common_sendmsg(int family, struct msghdr *msg, size_t len, void *user_icmph, size_t icmph_len) {
if (len > 0xFFFF) {
return -EMSGSIZE;
}
if (len < icmph_len) {
return -EVAL;
}
if (msg->msg_flags & MSG_OOB) {
return -EOPNOTSUPP;
}
if (memcpy_from_msg(user_icmp... | int ping_common_sendmsg(int family, struct msghdr *msg, size_t len, void *user_icmph, size_t icmph_len) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
if (len > 0xFFFF) {
return -EMSGSIZE;
}
if (msg->msg_flags & MSG_OOB) {
return -EOPNOTSUPP;
}
if (memcpy_from_msg(user_icmph, ms... | int ping_common_sendmsg(int family, struct msghdr *msg, size_t len, void *user_icmph, size_t icmph_len) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
if (len > 0xFFFF) {
return -EMSGSIZE;
}
if (len < icmph_len) {
return -EVAL;
}
if (msg->msg_flags & MSG_OOB) {
return -E... | int ping_common_sendmsg(int family, struct msghdr *msg, size_t len, void *user_icmph, size_t icmph_len) {
if (len > 0xFFFF) {
return -EMSGSIZE;
+ }
+ if (len < icmph_len) {
+ return -EVAL;
}
if (msg->msg_flags & MSG_OOB) {
return -EOPNOTSUPP;
}
if (memcpy_from_ms... |
CVE-2016-8405 | linux | https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux | drivers/video/fbdev/core/fbcmap.c | fb_cmap_to_user | int fb_cmap_to_user(const struct fb_cmap *from, struct fb_cmap_user *to) {
int tooff = 0, fromoff = 0;
int size;
if (to->start > from->start) {
fromoff = to->start - from->start;
} else {
tooff = from->start - to->start;
}
size = to->len - tooff;
if (size > (int) (from->len -... | int fb_cmap_to_user(const struct fb_cmap *from, struct fb_cmap_user *to) {
unsigned int tooff = 0, fromoff = 0;
size_t size;
if (to->start > from->start) {
fromoff = to->start - from->start;
} else {
tooff = from->start - to->start;
}
if (fromoff >= from->len || tooff >= to->len)... | int fb_cmap_to_user(const struct fb_cmap *from, struct fb_cmap_user *to) {
int tooff = 0, fromoff = 0;
int size;
if (to->start > from->start) {
fromoff = to->start - from->start;
} else {
tooff = from->start - to->start;
}
size = to->len - tooff;
if (size > (int) (from->len -... | int fb_cmap_to_user(const struct fb_cmap *from, struct fb_cmap_user *to) {
unsigned int tooff = 0, fromoff = 0;
size_t size;
if (to->start > from->start) {
fromoff = to->start - from->start;
} else {
tooff = from->start - to->start;
}
if (fromoff >= from->len || tooff >= to->len)... | int fb_cmap_to_user(const struct fb_cmap *from, struct fb_cmap_user *to) {
int tooff = 0, fromoff = 0;
int size;
if (to->start > from->start) {
fromoff = to->start - from->start;
} else {
tooff = from->start - to->start;
}
size = to->len - tooff;
if (size > (int) (from->len -... | int fb_cmap_to_user(const struct fb_cmap *from, struct fb_cmap_user *to) {
unsigned int tooff = 0, fromoff = 0;
size_t size;
if (to->start > from->start) {
fromoff = to->start - from->start;
} else {
tooff = from->start - to->start;
}
if (fromoff >= from->len || tooff >= to->len)... | int fb_cmap_to_user(const struct fb_cmap *from, struct fb_cmap_user *to) {
int tooff = 0, fromoff = 0;
int size;
if (to->start > from->start) {
fromoff = to->start - from->start;
} else {
tooff = from->start - to->start;
}
size = to->len - tooff;
if (size > (int) (from->len -... | int fb_cmap_to_user(const struct fb_cmap *from, struct fb_cmap_user *to) {
unsigned int tooff = 0, fromoff = 0;
size_t size;
if (to->start > from->start) {
fromoff = to->start - from->start;
} else {
tooff = from->start - to->start;
}
if (fromoff >= from->len || tooff >= to->len)... | int fb_cmap_to_user(const struct fb_cmap *from, struct fb_cmap_user *to) {
- int tooff = 0, fromoff = 0;
- int size;
+ unsigned int tooff = 0, fromoff = 0;
+ size_t size;
if (to->start > from->start) {
fromoff = to->start - from->start;
} else {
tooff = from->start - to->start;
... |
CVE-2016-8405 | linux | https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux | drivers/video/fbdev/core/fbcmap.c | fb_copy_cmap | int fb_copy_cmap(const struct fb_cmap *from, struct fb_cmap *to) {
int tooff = 0, fromoff = 0;
int size;
if (to->start > from->start) {
fromoff = to->start - from->start;
} else {
tooff = from->start - to->start;
}
size = to->len - tooff;
if (size > (int) (from->len - fromoff... | int fb_copy_cmap(const struct fb_cmap *from, struct fb_cmap *to) {
unsigned int tooff = 0, fromoff = 0;
size_t size;
if (to->start > from->start) {
fromoff = to->start - from->start;
} else {
tooff = from->start - to->start;
}
if (fromoff >= from->len || tooff >= to->len) {
... | int fb_copy_cmap(const struct fb_cmap *from, struct fb_cmap *to) {
int tooff = 0, fromoff = 0;
int size;
if (to->start > from->start) {
fromoff = to->start - from->start;
} else {
tooff = from->start - to->start;
}
size = to->len - tooff;
if (size > (int) (from->len - fromoff... | int fb_copy_cmap(const struct fb_cmap *from, struct fb_cmap *to) {
unsigned int tooff = 0, fromoff = 0;
size_t size;
if (to->start > from->start) {
fromoff = to->start - from->start;
} else {
tooff = from->start - to->start;
}
if (fromoff >= from->len || tooff >= to->len) {
... | int fb_copy_cmap(const struct fb_cmap *from, struct fb_cmap *to) {
int tooff = 0, fromoff = 0;
int size;
if (to->start > from->start) {
fromoff = to->start - from->start;
} else {
tooff = from->start - to->start;
}
size = to->len - tooff;
if (size > (int) (from->len - fromoff... | int fb_copy_cmap(const struct fb_cmap *from, struct fb_cmap *to) {
unsigned int tooff = 0, fromoff = 0;
size_t size;
if (to->start > from->start) {
fromoff = to->start - from->start;
} else {
tooff = from->start - to->start;
}
if (fromoff >= from->len || tooff >= to->len) {
... | int fb_copy_cmap(const struct fb_cmap *from, struct fb_cmap *to) {
int tooff = 0, fromoff = 0;
int size;
if (to->start > from->start) {
fromoff = to->start - from->start;
} else {
tooff = from->start - to->start;
}
size = to->len - tooff;
if (size > (int) (from->len - fromoff... | int fb_copy_cmap(const struct fb_cmap *from, struct fb_cmap *to) {
unsigned int tooff = 0, fromoff = 0;
size_t size;
if (to->start > from->start) {
fromoff = to->start - from->start;
} else {
tooff = from->start - to->start;
}
if (fromoff >= from->len || tooff >= to->len) {
... | int fb_copy_cmap(const struct fb_cmap *from, struct fb_cmap *to) {
- int tooff = 0, fromoff = 0;
- int size;
+ unsigned int tooff = 0, fromoff = 0;
+ size_t size;
if (to->start > from->start) {
fromoff = to->start - from->start;
} else {
tooff = from->start - to->start;
}
-... |
CVE-2016-8630 | linux | https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux | arch/x86/kvm/emulate.c | x86_decode_insn | int x86_decode_insn(struct x86_emulate_ctxt *ctxt, void *insn, int insn_len) {
int rc = X86EMUL_CONTUE;
int mode = ctxt->mode;
int def_op_bytes, def_ad_bytes, goffset, simd_prefix;
bool op_prefix = false;
bool has_seg_override = false;
struct opcode opcode;
ctxt->memop.type = OP_NONE;
ct... | int x86_decode_insn(struct x86_emulate_ctxt *ctxt, void *insn, int insn_len) {
int rc = X86EMUL_CONTUE;
int mode = ctxt->mode;
int def_op_bytes, def_ad_bytes, goffset, simd_prefix;
bool op_prefix = false;
bool has_seg_override = false;
struct opcode opcode;
ctxt->memop.type = OP_NONE;
ct... | int x86_decode_insn(struct x86_emulate_ctxt *ctxt, void *insn, int insn_len) {
int rc = X86EMUL_CONTUE;
int mode = ctxt->mode;
int def_op_bytes, def_ad_bytes, goffset, simd_prefix;
bool op_prefix = false;
bool has_seg_override = false;
struct opcode opcode;
ctxt->memop.type = OP_NONE;
ct... | int x86_decode_insn(struct x86_emulate_ctxt *ctxt, void *insn, int insn_len) {
int rc = X86EMUL_CONTUE;
int mode = ctxt->mode;
int def_op_bytes, def_ad_bytes, goffset, simd_prefix;
bool op_prefix = false;
bool has_seg_override = false;
struct opcode opcode;
ctxt->memop.type = OP_NONE;
ct... | int x86_decode_insn(struct x86_emulate_ctxt *ctxt, void *insn, int insn_len) {
ctxt->memopp = NULL;
if (insn_len > 0) {
} else {
rc = __do_insn_fetch_bytes(ctxt, 1);
}
switch (mode) {
case X86EMUL_MODE_PROT16:
def_op_bytes = def_ad_bytes = 2;
break;
case X86EMUL_MODE_... | int x86_decode_insn(struct x86_emulate_ctxt *ctxt, void *insn, int insn_len) {
ctxt->memopp = NULL;
if (insn_len > 0) {
} else {
rc = __do_insn_fetch_bytes(ctxt, 1);
}
switch (mode) {
case X86EMUL_MODE_PROT16:
def_op_bytes = def_ad_bytes = 2;
break;
case X86EMUL_MODE_... | int x86_decode_insn(struct x86_emulate_ctxt *ctxt, void *insn, int insn_len) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
ctxt->memopp = NULL;
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
if (insn_len > 0) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
} else {
rc = __do_insn_fetch_... | int x86_decode_insn(struct x86_emulate_ctxt *ctxt, void *insn, int insn_len) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
ctxt->memopp = NULL;
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
if (insn_len > 0) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
} else {
rc = __do_insn_fetch_... | int x86_decode_insn(struct x86_emulate_ctxt *ctxt, void *insn, int insn_len) {
ctxt->memopp = NULL;
if (insn_len > 0) {
} else {
rc = __do_insn_fetch_bytes(ctxt, 1);
}
switch (mode) {
case X86EMUL_MODE_PROT16:
def_op_bytes = def_ad_bytes = 2;
break;
case X8... |
CVE-2016-8632 | linux | https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux | net/tipc/bearer.c | tipc_enable_l2_media | int tipc_enable_l2_media(struct net *net, struct tipc_bearer *b, struct nlattr *attr[]) {
struct net_device *dev;
char *driver_name = strchr((const char *)b->name, ':') + 1;
dev = dev_get_by_name(net, driver_name);
if (!dev) {
return -ENODEV;
}
rcu_assign_pointer(b->media_ptr, dev);
... | int tipc_enable_l2_media(struct net *net, struct tipc_bearer *b, struct nlattr *attr[]) {
struct net_device *dev;
char *driver_name = strchr((const char *)b->name, ':') + 1;
dev = dev_get_by_name(net, driver_name);
if (!dev) {
return -ENODEV;
}
if (tipc_mtu_bad(dev, 0)) {
dev_put... | int tipc_enable_l2_media(struct net *net, struct tipc_bearer *b, struct nlattr *attr[]) {
struct net_device *dev;
char *driver_name = strchr((const char *)b->name, ':') + 1;
dev = dev_get_by_name(net, driver_name);
if (!dev) {
return -ENODEV;
}
rcu_assign_pointer(b->media_ptr, dev);
... | int tipc_enable_l2_media(struct net *net, struct tipc_bearer *b, struct nlattr *attr[]) {
struct net_device *dev;
char *driver_name = strchr((const char *)b->name, ':') + 1;
dev = dev_get_by_name(net, driver_name);
if (!dev) {
return -ENODEV;
}
if (tipc_mtu_bad(dev, 0)) {
dev_put... | int tipc_enable_l2_media(struct net *net, struct tipc_bearer *b, struct nlattr *attr[]) {
char *driver_name = strchr((const char *)b->name, ':') + 1;
dev = dev_get_by_name(net, driver_name);
if (!dev) {
return -ENODEV;
}
rcu_assign_pointer(b->media_ptr, dev);
memcpy(b->bcast_addr.value, ... | int tipc_enable_l2_media(struct net *net, struct tipc_bearer *b, struct nlattr *attr[]) {
char *driver_name = strchr((const char *)b->name, ':') + 1;
dev = dev_get_by_name(net, driver_name);
if (!dev) {
return -ENODEV;
}
if (tipc_mtu_bad(dev, 0)) {
dev_put(dev);
return -EVAL;... | int tipc_enable_l2_media(struct net *net, struct tipc_bearer *b, struct nlattr *attr[]) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
char *driver_name = strchr((const char *)b->name, ':') + 1;
dev = dev_get_by_name(net, driver_name);
if (!dev) {
return -ENODEV;
}
rcu_assign_pointer(b-... | int tipc_enable_l2_media(struct net *net, struct tipc_bearer *b, struct nlattr *attr[]) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
char *driver_name = strchr((const char *)b->name, ':') + 1;
dev = dev_get_by_name(net, driver_name);
if (!dev) {
return -ENODEV;
}
if (tipc_mtu_bad(dev,... | int tipc_enable_l2_media(struct net *net, struct tipc_bearer *b, struct nlattr *attr[]) {
char *driver_name = strchr((const char *)b->name, ':') + 1;
dev = dev_get_by_name(net, driver_name);
if (!dev) {
return -ENODEV;
+ }
+ if (tipc_mtu_bad(dev, 0)) {
+ dev_put(dev);
+ retu... |
CVE-2016-8632 | linux | https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux | net/tipc/bearer.c | tipc_l2_device_event | static int tipc_l2_device_event(struct notifier_block *nb, unsigned long evt, void *ptr) {
struct net_device *dev = netdev_notifier_info_to_dev(ptr);
struct net *net = dev_net(dev);
struct tipc_net *tn = tipc_net(net);
struct tipc_bearer *b;
int i;
b = rtnl_dereference(dev->tipc_ptr);
if (!b... | static int tipc_l2_device_event(struct notifier_block *nb, unsigned long evt, void *ptr) {
struct net_device *dev = netdev_notifier_info_to_dev(ptr);
struct net *net = dev_net(dev);
struct tipc_net *tn = tipc_net(net);
struct tipc_bearer *b;
int i;
b = rtnl_dereference(dev->tipc_ptr);
if (!b... | static int tipc_l2_device_event(struct notifier_block *nb, unsigned long evt, void *ptr) {
struct net_device *dev = netdev_notifier_info_to_dev(ptr);
struct net *net = dev_net(dev);
struct tipc_bearer *b_ptr;
b_ptr = rtnl_dereference(dev->tipc_ptr);
if (!b_ptr) {
return NOTIFY_DONE;
}
... | static int tipc_l2_device_event(struct notifier_block *nb, unsigned long evt, void *ptr) {
struct net_device *dev = netdev_notifier_info_to_dev(ptr);
struct net *net = dev_net(dev);
struct tipc_bearer *b_ptr;
b_ptr = rtnl_dereference(dev->tipc_ptr);
if (!b_ptr) {
return NOTIFY_DONE;
}
... | static int tipc_l2_device_event(struct notifier_block *nb, unsigned long evt, void *ptr) {
struct net_device *dev = netdev_notifier_info_to_dev(ptr);
struct net *net = dev_net(dev);
struct tipc_net *tn = tipc_net(net);
b = rtnl_dereference(dev->tipc_ptr);
if (!b) {
for (i = 0; i < MAX_BEARER... | static int tipc_l2_device_event(struct notifier_block *nb, unsigned long evt, void *ptr) {
struct net_device *dev = netdev_notifier_info_to_dev(ptr);
struct net *net = dev_net(dev);
struct tipc_net *tn = tipc_net(net);
b = rtnl_dereference(dev->tipc_ptr);
if (!b) {
for (i = 0; i < MAX_BEARER... | static int tipc_l2_device_event(struct notifier_block *nb, unsigned long evt, void *ptr) {
struct net_device *dev = netdev_notifier_info_to_dev(ptr);
struct net *net = dev_net(dev);
struct tipc_bearer *b_ptr;
b_ptr = rtnl_dereference(dev->tipc_ptr);
if (!b_ptr) {
return NOTIFY_DONE;
}
... | static int tipc_l2_device_event(struct notifier_block *nb, unsigned long evt, void *ptr) {
struct net_device *dev = netdev_notifier_info_to_dev(ptr);
struct net *net = dev_net(dev);
struct tipc_bearer *b_ptr;
b_ptr = rtnl_dereference(dev->tipc_ptr);
if (!b_ptr) {
return NOTIFY_DONE;
}
... | static int tipc_l2_device_event(struct notifier_block *nb, unsigned long evt, void *ptr) {
struct net_device *dev = netdev_notifier_info_to_dev(ptr);
struct net *net = dev_net(dev);
struct tipc_net *tn = tipc_net(net);
b = rtnl_dereference(dev->tipc_ptr);
if (!b) {
for (i = 0; i < MAX... |
CVE-2016-8632 | linux | https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux | net/tipc/udp_media.c | tipc_udp_enable | static int tipc_udp_enable(struct net *net, struct tipc_bearer *b, struct nlattr *attrs[]) {
int err = -EVAL;
struct udp_bearer *ub;
struct udp_media_addr *remote;
struct udp_media_addr local = {0};
struct udp_port_cfg udp_conf = {0};
struct udp_tunnel_sock_cfg tuncfg = {NULL};
ub = kzalloc(... | static int tipc_udp_enable(struct net *net, struct tipc_bearer *b, struct nlattr *attrs[]) {
int err = -EVAL;
struct udp_bearer *ub;
struct udp_media_addr *remote;
struct udp_media_addr local = {0};
struct udp_port_cfg udp_conf = {0};
struct udp_tunnel_sock_cfg tuncfg = {NULL};
ub = kzalloc(... | static int tipc_udp_enable(struct net *net, struct tipc_bearer *b, struct nlattr *attrs[]) {
int err = -EVAL;
struct udp_bearer *ub;
struct udp_media_addr *remote;
struct udp_media_addr local = {0};
struct udp_port_cfg udp_conf = {0};
struct udp_tunnel_sock_cfg tuncfg = {NULL};
ub = kzalloc(... | static int tipc_udp_enable(struct net *net, struct tipc_bearer *b, struct nlattr *attrs[]) {
int err = -EVAL;
struct udp_bearer *ub;
struct udp_media_addr *remote;
struct udp_media_addr local = {0};
struct udp_port_cfg udp_conf = {0};
struct udp_tunnel_sock_cfg tuncfg = {NULL};
ub = kzalloc(... | static int tipc_udp_enable(struct net *net, struct tipc_bearer *b, struct nlattr *attrs[]) {
int err = -EVAL;
if (local.proto == htons(ETH_P_IP)) {
dev = __ip_dev_find(net, local.ipv4.s_addr, false);
if (!dev) {
goto err;
}
ub->ifindex = dev->ifindex;
b->mtu =... | static int tipc_udp_enable(struct net *net, struct tipc_bearer *b, struct nlattr *attrs[]) {
int err = -EVAL;
if (local.proto == htons(ETH_P_IP)) {
dev = __ip_dev_find(net, local.ipv4.s_addr, false);
if (!dev) {
goto err;
}
ub->ifindex = dev->ifindex;
if (tipc... | static int tipc_udp_enable(struct net *net, struct tipc_bearer *b, struct nlattr *attrs[]) {
int err = -EVAL;
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
if (local.proto == htons(ETH_P_IP)) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
dev = __ip_dev_find(net, local.ipv4.s_addr, false);
... | static int tipc_udp_enable(struct net *net, struct tipc_bearer *b, struct nlattr *attrs[]) {
int err = -EVAL;
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
if (local.proto == htons(ETH_P_IP)) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
dev = __ip_dev_find(net, local.ipv4.s_addr, false);
... | static int tipc_udp_enable(struct net *net, struct tipc_bearer *b, struct nlattr *attrs[]) {
int err = -EVAL;
if (local.proto == htons(ETH_P_IP)) {
dev = __ip_dev_find(net, local.ipv4.s_addr, false);
if (!dev) {
goto err;
}
ub->ifindex = dev->ifindex;
+ ... |
CVE-2016-8633 | linux | https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux | drivers/firewire/net.c | fwnet_incoming_packet | static int fwnet_incoming_packet(struct fwnet_device *dev, __be32 *buf, int len, int source_node_id, int generation, bool is_broadcast) {
struct sk_buff *skb;
struct net_device *net = dev->netdev;
struct rfc2734_header hdr;
unsigned lf;
unsigned long flags;
struct fwnet_peer *peer;
struct fw... | static int fwnet_incoming_packet(struct fwnet_device *dev, __be32 *buf, int len, int source_node_id, int generation, bool is_broadcast) {
struct sk_buff *skb;
struct net_device *net = dev->netdev;
struct rfc2734_header hdr;
unsigned lf;
unsigned long flags;
struct fwnet_peer *peer;
struct fw... | static int fwnet_incoming_packet(struct fwnet_device *dev, __be32 *buf, int len, int source_node_id, int generation, bool is_broadcast) {
struct sk_buff *skb;
struct net_device *net = dev->netdev;
struct rfc2734_header hdr;
unsigned lf;
unsigned long flags;
struct fwnet_peer *peer;
struct fw... | static int fwnet_incoming_packet(struct fwnet_device *dev, __be32 *buf, int len, int source_node_id, int generation, bool is_broadcast) {
struct sk_buff *skb;
struct net_device *net = dev->netdev;
struct rfc2734_header hdr;
unsigned lf;
unsigned long flags;
struct fwnet_peer *peer;
struct fw... | static int fwnet_incoming_packet(struct fwnet_device *dev, __be32 *buf, int len, int source_node_id, int generation, bool is_broadcast) {
struct net_device *net = dev->netdev;
u16 ether_type;
hdr.w0 = be32_to_cpu(buf[0]);
if (lf == RFC2374_HDR_UNFRAG) {
len -= RFC2374_UNFRAG_HDR_SIZE;
sk... | static int fwnet_incoming_packet(struct fwnet_device *dev, __be32 *buf, int len, int source_node_id, int generation, bool is_broadcast) {
struct net_device *net = dev->netdev;
u16 ether_type;
if (len <= RFC2374_UNFRAG_HDR_SIZE) {
return 0;
}
hdr.w0 = be32_to_cpu(buf[0]);
if (lf == RFC237... | static int fwnet_incoming_packet(struct fwnet_device *dev, __be32 *buf, int len, int source_node_id, int generation, bool is_broadcast) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
struct net_device *net = dev->netdev;
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
u16 ether_type;
hdr.w0 = be32_to... | static int fwnet_incoming_packet(struct fwnet_device *dev, __be32 *buf, int len, int source_node_id, int generation, bool is_broadcast) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
struct net_device *net = dev->netdev;
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
u16 ether_type;
if (len <= RFC23... | static int fwnet_incoming_packet(struct fwnet_device *dev, __be32 *buf, int len, int source_node_id, int generation, bool is_broadcast) {
struct net_device *net = dev->netdev;
u16 ether_type;
+ if (len <= RFC2374_UNFRAG_HDR_SIZE) {
+ return 0;
+ }
hdr.w0 = be32_to_cpu(buf[0]);
if (lf =... |
CVE-2016-8633 | linux | https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux | drivers/firewire/net.c | fwnet_receive_broadcast | static void fwnet_receive_broadcast(struct fw_iso_context *context, u32 cycle, size_t header_length, void *header, void *data) {
struct fwnet_device *dev;
struct fw_iso_packet packet;
__be16 *hdr_ptr;
__be32 *buf_ptr;
int retval;
u32 length;
u16 source_node_id;
u32 specifier_id;
u32 ... | static void fwnet_receive_broadcast(struct fw_iso_context *context, u32 cycle, size_t header_length, void *header, void *data) {
struct fwnet_device *dev;
struct fw_iso_packet packet;
__be16 *hdr_ptr;
__be32 *buf_ptr;
int retval;
u32 length;
unsigned long offset;
unsigned long flags;
... | static void fwnet_receive_broadcast(struct fw_iso_context *context, u32 cycle, size_t header_length, void *header, void *data) {
struct fwnet_device *dev;
struct fw_iso_packet packet;
__be16 *hdr_ptr;
__be32 *buf_ptr;
int retval;
u32 length;
u16 source_node_id;
u32 specifier_id;
u32 ... | static void fwnet_receive_broadcast(struct fw_iso_context *context, u32 cycle, size_t header_length, void *header, void *data) {
struct fwnet_device *dev;
struct fw_iso_packet packet;
__be16 *hdr_ptr;
__be32 *buf_ptr;
int retval;
u32 length;
unsigned long offset;
unsigned long flags;
... | static void fwnet_receive_broadcast(struct fw_iso_context *context, u32 cycle, size_t header_length, void *header, void *data) {
u32 length;
u16 source_node_id;
u32 specifier_id;
u32 ver;
unsigned long offset;
dev = data;
hdr_ptr = header;
length = be16_to_cpup(hdr_ptr);
offset = dev... | static void fwnet_receive_broadcast(struct fw_iso_context *context, u32 cycle, size_t header_length, void *header, void *data) {
u32 length;
unsigned long offset;
dev = data;
hdr_ptr = header;
length = be16_to_cpup(hdr_ptr);
offset = dev->rcv_buffer_size * dev->broadcast_rcv_next_ptr;
buf_pt... | static void fwnet_receive_broadcast(struct fw_iso_context *context, u32 cycle, size_t header_length, void *header, void *data) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
u32 length;
u16 source_node_id;
u32 specifier_id;
u32 ver;
unsigned long offset;
/* PLACEHOLDER: DO NOT DELETE THIS C... | static void fwnet_receive_broadcast(struct fw_iso_context *context, u32 cycle, size_t header_length, void *header, void *data) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
u32 length;
unsigned long offset;
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
dev = data;
hdr_ptr = header;
length ... | static void fwnet_receive_broadcast(struct fw_iso_context *context, u32 cycle, size_t header_length, void *header, void *data) {
u32 length;
- u16 source_node_id;
- u32 specifier_id;
- u32 ver;
unsigned long offset;
dev = data;
hdr_ptr = header;
length = be16_to_cpup(hdr_ptr);
of... |
CVE-2016-8645 | linux | https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux | net/ipv4/tcp_ipv4.c | tcp_v4_rcv | int tcp_v4_rcv(struct sk_buff *skb) {
const struct iphdr *iph;
const struct tcphdr *th;
struct sock *sk;
int ret;
struct net *net = dev_net(skb->dev);
if (skb->pkt_type != PACKET_HOST) {
goto discard_it;
}
TCP_C_STATS_BH(net, TCP_MIB_SEGS);
if (!pskb_may_pull(skb, sizeof(stru... | int tcp_v4_rcv(struct sk_buff *skb) {
const struct iphdr *iph;
const struct tcphdr *th;
struct sock *sk;
int ret;
struct net *net = dev_net(skb->dev);
if (skb->pkt_type != PACKET_HOST) {
goto discard_it;
}
TCP_C_STATS_BH(net, TCP_MIB_SEGS);
if (!pskb_may_pull(skb, sizeof(stru... | int tcp_v4_rcv(struct sk_buff *skb) {
const struct iphdr *iph;
const struct tcphdr *th;
struct sock *sk;
int ret;
struct net *net = dev_net(skb->dev);
if (skb->pkt_type != PACKET_HOST) {
goto discard_it;
}
TCP_C_STATS_BH(net, TCP_MIB_SEGS);
if (!pskb_may_pull(skb, sizeof(stru... | int tcp_v4_rcv(struct sk_buff *skb) {
const struct iphdr *iph;
const struct tcphdr *th;
struct sock *sk;
int ret;
struct net *net = dev_net(skb->dev);
if (skb->pkt_type != PACKET_HOST) {
goto discard_it;
}
TCP_C_STATS_BH(net, TCP_MIB_SEGS);
if (!pskb_may_pull(skb, sizeof(stru... | int tcp_v4_rcv(struct sk_buff *skb) {
if (!pskb_may_pull(skb, sizeof(struct tcphdr))) {
goto discard_it;
}
th = tcp_hdr(skb);
if (th->doff < sizeof(struct tcphdr) / 4) {
goto bad_packet;
}
if (!pskb_may_pull(skb, th->doff * 4)) {
goto discard_it;
}
if (skb_checksu... | int tcp_v4_rcv(struct sk_buff *skb) {
if (!pskb_may_pull(skb, sizeof(struct tcphdr))) {
goto discard_it;
}
th = tcp_hdr(skb);
if (th->doff < sizeof(struct tcphdr) / 4) {
goto bad_packet;
}
if (!pskb_may_pull(skb, th->doff * 4)) {
goto discard_it;
}
if (skb_checksu... | int tcp_v4_rcv(struct sk_buff *skb) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
if (!pskb_may_pull(skb, sizeof(struct tcphdr))) {
goto discard_it;
}
th = tcp_hdr(skb);
if (th->doff < sizeof(struct tcphdr) / 4) {
goto bad_packet;
}
if (!pskb_may_pull(skb, th->doff * 4)) {
... | int tcp_v4_rcv(struct sk_buff *skb) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
if (!pskb_may_pull(skb, sizeof(struct tcphdr))) {
goto discard_it;
}
th = tcp_hdr(skb);
if (th->doff < sizeof(struct tcphdr) / 4) {
goto bad_packet;
}
if (!pskb_may_pull(skb, th->doff * 4)) {
... | int tcp_v4_rcv(struct sk_buff *skb) {
if (!pskb_may_pull(skb, sizeof(struct tcphdr))) {
goto discard_it;
}
th = tcp_hdr(skb);
if (th->doff < sizeof(struct tcphdr) / 4) {
goto bad_packet;
}
if (!pskb_may_pull(skb, th->doff * 4)) {
goto discard_it;
}
if ... |
CVE-2016-8645 | linux | https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux | net/ipv6/tcp_ipv6.c | tcp_v6_do_rcv | static int tcp_v6_do_rcv(struct sock *sk, struct sk_buff *skb) {
struct ipv6_pinfo *np = inet6_sk(sk);
struct tcp_sock *tp;
struct sk_buff *opt_skb = NULL;
if (skb->protocol == htons(ETH_P_IP)) {
return tcp_v4_do_rcv(sk, skb);
}
if (sk_filter(sk, skb)) {
goto discard;
}
i... | static int tcp_v6_do_rcv(struct sock *sk, struct sk_buff *skb) {
struct ipv6_pinfo *np = inet6_sk(sk);
struct tcp_sock *tp;
struct sk_buff *opt_skb = NULL;
if (skb->protocol == htons(ETH_P_IP)) {
return tcp_v4_do_rcv(sk, skb);
}
if (tcp_filter(sk, skb)) {
goto discard;
}
... | static int tcp_v6_do_rcv(struct sock *sk, struct sk_buff *skb) {
struct ipv6_pinfo *np = inet6_sk(sk);
struct tcp_sock *tp;
struct sk_buff *opt_skb = NULL;
if (skb->protocol == htons(ETH_P_IP)) {
return tcp_v4_do_rcv(sk, skb);
}
if (tcp_v6_inbound_md5_hash(sk, skb)) {
goto discar... | static int tcp_v6_do_rcv(struct sock *sk, struct sk_buff *skb) {
struct ipv6_pinfo *np = inet6_sk(sk);
struct tcp_sock *tp;
struct sk_buff *opt_skb = NULL;
if (skb->protocol == htons(ETH_P_IP)) {
return tcp_v4_do_rcv(sk, skb);
}
if (tcp_v6_inbound_md5_hash(sk, skb)) {
goto discar... | static int tcp_v6_do_rcv(struct sock *sk, struct sk_buff *skb) {
struct ipv6_pinfo *np = inet6_sk(sk);
if (sk_filter(sk, skb)) {
goto discard;
}
if (np->rxopt.all) {
opt_skb = skb_clone(skb, sk_gfp_atomic(sk, GFP_ATOMIC));
}
if (sk->sk_state == TCP_ESTABLISHED) {
struct d... | static int tcp_v6_do_rcv(struct sock *sk, struct sk_buff *skb) {
struct ipv6_pinfo *np = inet6_sk(sk);
if (tcp_filter(sk, skb)) {
goto discard;
}
if (np->rxopt.all) {
opt_skb = skb_clone(skb, sk_gfp_atomic(sk, GFP_ATOMIC));
}
if (sk->sk_state == TCP_ESTABLISHED) {
struct ... | static int tcp_v6_do_rcv(struct sock *sk, struct sk_buff *skb) {
struct ipv6_pinfo *np = inet6_sk(sk);
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
if (sk_filter(sk, skb)) {
goto discard;
}
if (np->rxopt.all) {
opt_skb = skb_clone(skb, sk_gfp_atomic(sk, GFP_ATOMIC));
}
if (s... | static int tcp_v6_do_rcv(struct sock *sk, struct sk_buff *skb) {
struct ipv6_pinfo *np = inet6_sk(sk);
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
if (tcp_filter(sk, skb)) {
goto discard;
}
if (np->rxopt.all) {
opt_skb = skb_clone(skb, sk_gfp_atomic(sk, GFP_ATOMIC));
}
if (... | static int tcp_v6_do_rcv(struct sock *sk, struct sk_buff *skb) {
struct ipv6_pinfo *np = inet6_sk(sk);
- if (sk_filter(sk, skb)) {
+ if (tcp_filter(sk, skb)) {
goto discard;
}
if (np->rxopt.all) {
opt_skb = skb_clone(skb, sk_gfp_atomic(sk, GFP_ATOMIC));
}
if (sk->sk_sta... |
CVE-2016-8645 | linux | https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux | net/ipv6/tcp_ipv6.c | tcp_v6_rcv | static int tcp_v6_rcv(struct sk_buff *skb) {
const struct tcphdr *th;
const struct ipv6hdr *hdr;
struct sock *sk;
int ret;
struct net *net = dev_net(skb->dev);
if (skb->pkt_type != PACKET_HOST) {
goto discard_it;
}
TCP_C_STATS_BH(net, TCP_MIB_SEGS);
if (!pskb_may_pull(skb, si... | static int tcp_v6_rcv(struct sk_buff *skb) {
const struct tcphdr *th;
const struct ipv6hdr *hdr;
struct sock *sk;
int ret;
struct net *net = dev_net(skb->dev);
if (skb->pkt_type != PACKET_HOST) {
goto discard_it;
}
TCP_C_STATS_BH(net, TCP_MIB_SEGS);
if (!pskb_may_pull(skb, si... | static int tcp_v6_rcv(struct sk_buff *skb) {
const struct tcphdr *th;
const struct ipv6hdr *hdr;
struct sock *sk;
int ret;
struct net *net = dev_net(skb->dev);
if (skb->pkt_type != PACKET_HOST) {
goto discard_it;
}
TCP_C_STATS_BH(net, TCP_MIB_SEGS);
if (!pskb_may_pull(skb, si... | static int tcp_v6_rcv(struct sk_buff *skb) {
const struct tcphdr *th;
const struct ipv6hdr *hdr;
struct sock *sk;
int ret;
struct net *net = dev_net(skb->dev);
if (skb->pkt_type != PACKET_HOST) {
goto discard_it;
}
TCP_C_STATS_BH(net, TCP_MIB_SEGS);
if (!pskb_may_pull(skb, si... | static int tcp_v6_rcv(struct sk_buff *skb) {
if (!pskb_may_pull(skb, sizeof(struct tcphdr))) {
goto discard_it;
}
th = tcp_hdr(skb);
if (th->doff < sizeof(struct tcphdr)/4) {
goto bad_packet;
}
if (!pskb_may_pull(skb, th->doff*4)) {
goto discard_it;
}
if (skb_chec... | static int tcp_v6_rcv(struct sk_buff *skb) {
if (!pskb_may_pull(skb, sizeof(struct tcphdr))) {
goto discard_it;
}
th = tcp_hdr(skb);
if (th->doff < sizeof(struct tcphdr)/4) {
goto bad_packet;
}
if (!pskb_may_pull(skb, th->doff*4)) {
goto discard_it;
}
if (skb_chec... | static int tcp_v6_rcv(struct sk_buff *skb) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
if (!pskb_may_pull(skb, sizeof(struct tcphdr))) {
goto discard_it;
}
th = tcp_hdr(skb);
if (th->doff < sizeof(struct tcphdr)/4) {
goto bad_packet;
}
if (!pskb_may_pull(skb, th->doff*4))... | static int tcp_v6_rcv(struct sk_buff *skb) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
if (!pskb_may_pull(skb, sizeof(struct tcphdr))) {
goto discard_it;
}
th = tcp_hdr(skb);
if (th->doff < sizeof(struct tcphdr)/4) {
goto bad_packet;
}
if (!pskb_may_pull(skb, th->doff*4))... | static int tcp_v6_rcv(struct sk_buff *skb) {
if (!pskb_may_pull(skb, sizeof(struct tcphdr))) {
goto discard_it;
}
th = tcp_hdr(skb);
if (th->doff < sizeof(struct tcphdr)/4) {
goto bad_packet;
}
if (!pskb_may_pull(skb, th->doff*4)) {
goto discard_it;
}
... |
CVE-2016-8646 | linux | https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux | crypto/algif_hash.c | hash_accept | static int hash_accept(struct socket *sock, struct socket *newsock, int flags) {
struct sock *sk = sock->sk;
struct alg_sock *ask = alg_sk(sk);
struct hash_ctx *ctx = ask->private;
struct ahash_request *req = &ctx->req;
char state[crypto_ahash_statesize(crypto_ahash_reqtfm(req))];
struct sock *s... | static int hash_accept(struct socket *sock, struct socket *newsock, int flags) {
struct sock *sk = sock->sk;
struct alg_sock *ask = alg_sk(sk);
struct hash_ctx *ctx = ask->private;
struct ahash_request *req = &ctx->req;
char state[crypto_ahash_statesize(crypto_ahash_reqtfm(req))];
struct sock *s... | static int hash_accept(struct socket *sock, struct socket *newsock, int flags) {
struct sock *sk = sock->sk;
struct alg_sock *ask = alg_sk(sk);
struct hash_ctx *ctx = ask->private;
struct ahash_request *req = &ctx->req;
char state[crypto_ahash_statesize(crypto_ahash_reqtfm(req))];
struct sock *s... | static int hash_accept(struct socket *sock, struct socket *newsock, int flags) {
struct sock *sk = sock->sk;
struct alg_sock *ask = alg_sk(sk);
struct hash_ctx *ctx = ask->private;
struct ahash_request *req = &ctx->req;
char state[crypto_ahash_statesize(crypto_ahash_reqtfm(req))];
struct sock *s... | static int hash_accept(struct socket *sock, struct socket *newsock, int flags) {
struct sock *sk = sock->sk;
struct alg_sock *ask = alg_sk(sk);
struct hash_ctx *ctx = ask->private;
struct ahash_request *req = &ctx->req;
struct hash_ctx *ctx2;
int err;
err = crypto_ahash_export(req, state);
... | static int hash_accept(struct socket *sock, struct socket *newsock, int flags) {
struct sock *sk = sock->sk;
struct alg_sock *ask = alg_sk(sk);
struct hash_ctx *ctx = ask->private;
struct ahash_request *req = &ctx->req;
struct hash_ctx *ctx2;
bool more;
int err;
lock_sock(sk);
more =... | static int hash_accept(struct socket *sock, struct socket *newsock, int flags) {
struct sock *sk = sock->sk;
struct alg_sock *ask = alg_sk(sk);
struct hash_ctx *ctx = ask->private;
struct ahash_request *req = &ctx->req;
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
struct hash_ctx *ctx2;
int... | static int hash_accept(struct socket *sock, struct socket *newsock, int flags) {
struct sock *sk = sock->sk;
struct alg_sock *ask = alg_sk(sk);
struct hash_ctx *ctx = ask->private;
struct ahash_request *req = &ctx->req;
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
struct hash_ctx *ctx2;
boo... | static int hash_accept(struct socket *sock, struct socket *newsock, int flags) {
struct sock *sk = sock->sk;
struct alg_sock *ask = alg_sk(sk);
struct hash_ctx *ctx = ask->private;
struct ahash_request *req = &ctx->req;
struct hash_ctx *ctx2;
+ bool more;
int err;
- err = crypto_aha... |
CVE-2016-8650 | linux | https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux | lib/mpi/mpi-pow.c | mpi_powm | int mpi_powm(MPI res, MPI base, MPI exp, MPI mod) {
mpi_ptr_t mp_marker = NULL, bp_marker = NULL, ep_marker = NULL;
mpi_ptr_t xp_marker = NULL;
mpi_ptr_t tspace = NULL;
mpi_ptr_t rp, ep, mp, bp;
mpi_size_t esize, msize, bsize, rsize;
int esign, msign, bsign, rsign;
mpi_size_t size;
int m... | int mpi_powm(MPI res, MPI base, MPI exp, MPI mod) {
mpi_ptr_t mp_marker = NULL, bp_marker = NULL, ep_marker = NULL;
mpi_ptr_t xp_marker = NULL;
mpi_ptr_t tspace = NULL;
mpi_ptr_t rp, ep, mp, bp;
mpi_size_t esize, msize, bsize, rsize;
int esign, msign, bsign, rsign;
mpi_size_t size;
int m... | int mpi_powm(MPI res, MPI base, MPI exp, MPI mod) {
mpi_ptr_t mp_marker = NULL, bp_marker = NULL, ep_marker = NULL;
mpi_ptr_t xp_marker = NULL;
mpi_ptr_t tspace = NULL;
mpi_ptr_t rp, ep, mp, bp;
mpi_size_t esize, msize, bsize, rsize;
int esign, msign, bsign, rsign;
mpi_size_t size;
int m... | int mpi_powm(MPI res, MPI base, MPI exp, MPI mod) {
mpi_ptr_t mp_marker = NULL, bp_marker = NULL, ep_marker = NULL;
mpi_ptr_t xp_marker = NULL;
mpi_ptr_t tspace = NULL;
mpi_ptr_t rp, ep, mp, bp;
mpi_size_t esize, msize, bsize, rsize;
int esign, msign, bsign, rsign;
mpi_size_t size;
int m... | int mpi_powm(MPI res, MPI base, MPI exp, MPI mod) {
msize = mod->nlimbs;
size = 2 * msize;
if (!msize) {
return -EVAL;
}
if (!esize) {
rp[0] = 1;
res->nlimbs = (msize == 1 && mod->d[0] == 1) ? 0 : 1;
res->sign = 0;
goto leave;
}
leave:
rc = 0;
enomem:
... | int mpi_powm(MPI res, MPI base, MPI exp, MPI mod) {
msize = mod->nlimbs;
size = 2 * msize;
if (!msize) {
return -EVAL;
}
if (!esize) {
res->nlimbs = (msize == 1 && mod->d[0] == 1) ? 0 : 1;
if (res->nlimbs) {
if (mpi_resize(res, 1) < 0) {
goto enome... | int mpi_powm(MPI res, MPI base, MPI exp, MPI mod) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
msize = mod->nlimbs;
size = 2 * msize;
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
if (!msize) {
return -EVAL;
}
if (!esize) {
rp[0] = 1;
res->nlimbs = (msize == 1 && m... | int mpi_powm(MPI res, MPI base, MPI exp, MPI mod) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
msize = mod->nlimbs;
size = 2 * msize;
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
if (!msize) {
return -EVAL;
}
if (!esize) {
res->nlimbs = (msize == 1 && mod->d[0] == 1) ? 0 ... | int mpi_powm(MPI res, MPI base, MPI exp, MPI mod) {
msize = mod->nlimbs;
size = 2 * msize;
if (!msize) {
return -EVAL;
}
if (!esize) {
- rp[0] = 1;
res->nlimbs = (msize == 1 && mod->d[0] == 1) ? 0 : 1;
+ if (res->nlimbs) {
+ if (mpi_resize(res, 1) < 0... |
CVE-2016-8655 | linux | https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux | net/packet/af_packet.c | packet_set_ring | static int packet_set_ring(struct sock *sk, union tpacket_req_u *req_u, int closing, int tx_ring) {
struct pgv *pg_vec = NULL;
struct packet_sock *po = pkt_sk(sk);
int was_running, order = 0;
struct packet_ring_buffer *rb;
struct sk_buff_head *rb_queue;
__be16 num;
int err = -EVAL;
struc... | static int packet_set_ring(struct sock *sk, union tpacket_req_u *req_u, int closing, int tx_ring) {
struct pgv *pg_vec = NULL;
struct packet_sock *po = pkt_sk(sk);
int was_running, order = 0;
struct packet_ring_buffer *rb;
struct sk_buff_head *rb_queue;
__be16 num;
int err = -EVAL;
struc... | static int packet_set_ring(struct sock *sk, union tpacket_req_u *req_u, int closing, int tx_ring) {
struct pgv *pg_vec = NULL;
struct packet_sock *po = pkt_sk(sk);
int was_running, order = 0;
struct packet_ring_buffer *rb;
struct sk_buff_head *rb_queue;
__be16 num;
int err = -EVAL;
struc... | static int packet_set_ring(struct sock *sk, union tpacket_req_u *req_u, int closing, int tx_ring) {
struct pgv *pg_vec = NULL;
struct packet_sock *po = pkt_sk(sk);
int was_running, order = 0;
struct packet_ring_buffer *rb;
struct sk_buff_head *rb_queue;
__be16 num;
int err = -EVAL;
struc... | static int packet_set_ring(struct sock *sk, union tpacket_req_u *req_u, int closing, int tx_ring) {
struct packet_sock *po = pkt_sk(sk);
struct tpacket_req *req = &req_u->req;
if (!closing && tx_ring && (po->tp_version > TPACKET_V2)) {
WARN(1, "Tx-ring is not supported.\n");
goto out;
}
... | static int packet_set_ring(struct sock *sk, union tpacket_req_u *req_u, int closing, int tx_ring) {
struct packet_sock *po = pkt_sk(sk);
struct tpacket_req *req = &req_u->req;
lock_sock(sk);
if (!closing && tx_ring && (po->tp_version > TPACKET_V2)) {
WARN(1, "Tx-ring is not supported.\n");
... | static int packet_set_ring(struct sock *sk, union tpacket_req_u *req_u, int closing, int tx_ring) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
struct packet_sock *po = pkt_sk(sk);
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
struct tpacket_req *req = &req_u->req;
if (!closing && tx_ring && (po->... | static int packet_set_ring(struct sock *sk, union tpacket_req_u *req_u, int closing, int tx_ring) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
struct packet_sock *po = pkt_sk(sk);
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
struct tpacket_req *req = &req_u->req;
lock_sock(sk);
if (!closing ... | static int packet_set_ring(struct sock *sk, union tpacket_req_u *req_u, int closing, int tx_ring) {
struct packet_sock *po = pkt_sk(sk);
struct tpacket_req *req = &req_u->req;
+ lock_sock(sk);
if (!closing && tx_ring && (po->tp_version > TPACKET_V2)) {
WARN(1, "Tx-ring is not supported.\n");... |
CVE-2016-8655 | linux | https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux | net/packet/af_packet.c | packet_setsockopt | static int packet_setsockopt(struct socket *sock, int level, int optname, char *optval, unsigned int optlen) {
struct sock *sk = sock->sk;
struct packet_sock *po = pkt_sk(sk);
int ret;
if (level != SOL_PACKET) {
return -ENOPROTOOPT;
}
switch (optname) {
case PACKET_ADD_MEMBERSHIP:
... | static int packet_setsockopt(struct socket *sock, int level, int optname, char *optval, unsigned int optlen) {
struct sock *sk = sock->sk;
struct packet_sock *po = pkt_sk(sk);
int ret;
if (level != SOL_PACKET) {
return -ENOPROTOOPT;
}
switch (optname) {
case PACKET_ADD_MEMBERSHIP:
... | static int packet_setsockopt(struct socket *sock, int level, int optname, char *optval, unsigned int optlen) {
struct sock *sk = sock->sk;
struct packet_sock *po = pkt_sk(sk);
int ret;
if (level != SOL_PACKET) {
return -ENOPROTOOPT;
}
switch (optname) {
case PACKET_ADD_MEMBERSHIP:
... | static int packet_setsockopt(struct socket *sock, int level, int optname, char *optval, unsigned int optlen) {
struct sock *sk = sock->sk;
struct packet_sock *po = pkt_sk(sk);
int ret;
if (level != SOL_PACKET) {
return -ENOPROTOOPT;
}
switch (optname) {
case PACKET_ADD_MEMBERSHIP:
... | static int packet_setsockopt(struct socket *sock, int level, int optname, char *optval, unsigned int optlen) {
struct sock *sk = sock->sk;
struct packet_sock *po = pkt_sk(sk);
switch (optname) {
case PACKET_VERSION: {
if (optlen != sizeof(val)) {
return -EVAL;
}
if (p... | static int packet_setsockopt(struct socket *sock, int level, int optname, char *optval, unsigned int optlen) {
struct sock *sk = sock->sk;
struct packet_sock *po = pkt_sk(sk);
switch (optname) {
case PACKET_VERSION: {
if (optlen != sizeof(val)) {
return -EVAL;
}
if (c... | static int packet_setsockopt(struct socket *sock, int level, int optname, char *optval, unsigned int optlen) {
struct sock *sk = sock->sk;
struct packet_sock *po = pkt_sk(sk);
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
switch (optname) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
case PACK... | static int packet_setsockopt(struct socket *sock, int level, int optname, char *optval, unsigned int optlen) {
struct sock *sk = sock->sk;
struct packet_sock *po = pkt_sk(sk);
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
switch (optname) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
case PACK... | static int packet_setsockopt(struct socket *sock, int level, int optname, char *optval, unsigned int optlen) {
struct sock *sk = sock->sk;
struct packet_sock *po = pkt_sk(sk);
switch (optname) {
case PACKET_VERSION: {
if (optlen != sizeof(val)) {
return -EVAL;
}
- ... |
CVE-2016-8666 | linux | https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux | net/core/dev.c | dev_gro_receive | static enum gro_result dev_gro_receive(struct napi_struct *napi, struct sk_buff *skb) {
struct sk_buff **pp = NULL;
struct packet_offload *ptype;
__be16 type = skb->protocol;
struct list_head *head = &offload_base;
int same_flow;
enum gro_result ret;
int grow;
if (!(skb->dev->features & ... | static enum gro_result dev_gro_receive(struct napi_struct *napi, struct sk_buff *skb) {
struct sk_buff **pp = NULL;
struct packet_offload *ptype;
__be16 type = skb->protocol;
struct list_head *head = &offload_base;
int same_flow;
enum gro_result ret;
int grow;
if (!(skb->dev->features & ... | static enum gro_result dev_gro_receive(struct napi_struct *napi, struct sk_buff *skb) {
struct sk_buff **pp = NULL;
struct packet_offload *ptype;
__be16 type = skb->protocol;
struct list_head *head = &offload_base;
int same_flow;
enum gro_result ret;
int grow;
if (!(skb->dev->features & ... | static enum gro_result dev_gro_receive(struct napi_struct *napi, struct sk_buff *skb) {
struct sk_buff **pp = NULL;
struct packet_offload *ptype;
__be16 type = skb->protocol;
struct list_head *head = &offload_base;
int same_flow;
enum gro_result ret;
int grow;
if (!(skb->dev->features & ... | static enum gro_result dev_gro_receive(struct napi_struct *napi, struct sk_buff *skb) {
if (skb_is_gso(skb) || skb_has_frag_list(skb)) {
goto normal;
}
gro_list_prepare(napi, skb);
NAPI_GRO_CB(skb)->csum = skb->csum;
list_for_each_entry_rcu(ptype, head, list) {
if (ptype->type != typ... | static enum gro_result dev_gro_receive(struct napi_struct *napi, struct sk_buff *skb) {
if (skb_is_gso(skb) || skb_has_frag_list(skb)) {
goto normal;
}
gro_list_prepare(napi, skb);
NAPI_GRO_CB(skb)->csum = skb->csum;
list_for_each_entry_rcu(ptype, head, list) {
if (ptype->type != typ... | static enum gro_result dev_gro_receive(struct napi_struct *napi, struct sk_buff *skb) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
if (skb_is_gso(skb) || skb_has_frag_list(skb) || skb->csum_bad) {
goto normal;
}
gro_list_prepare(napi, skb);
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
... | static enum gro_result dev_gro_receive(struct napi_struct *napi, struct sk_buff *skb) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
if (skb_is_gso(skb) || skb_has_frag_list(skb) || skb->csum_bad) {
goto normal;
}
gro_list_prepare(napi, skb);
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
... | static enum gro_result dev_gro_receive(struct napi_struct *napi, struct sk_buff *skb) {
if (skb_is_gso(skb) || skb_has_frag_list(skb)) {
goto normal;
}
gro_list_prepare(napi, skb);
NAPI_GRO_CB(skb)->csum = skb->csum;
list_for_each_entry_rcu(ptype, head, list) {
if (ptype->typ... |
CVE-2016-8666 | linux | https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux | net/ipv4/gre_offload.c | gre_gro_receive | static struct sk_buff **gre_gro_receive(struct sk_buff **head, struct sk_buff *skb) {
struct sk_buff **pp = NULL;
struct sk_buff *p;
const struct gre_base_hdr *greh;
unsigned int hlen, grehlen;
unsigned int off;
int flush = 1;
struct packet_offload *ptype;
__be16 type;
off = skb_gro_... | static struct sk_buff **gre_gro_receive(struct sk_buff **head, struct sk_buff *skb) {
struct sk_buff **pp = NULL;
struct sk_buff *p;
const struct gre_base_hdr *greh;
unsigned int hlen, grehlen;
unsigned int off;
int flush = 1;
struct packet_offload *ptype;
__be16 type;
if (NAPI_GRO_C... | static struct sk_buff **gre_gro_receive(struct sk_buff **head, struct sk_buff *skb) {
struct sk_buff **pp = NULL;
struct sk_buff *p;
const struct gre_base_hdr *greh;
unsigned int hlen, grehlen;
unsigned int off;
int flush = 1;
struct packet_offload *ptype;
__be16 type;
off = skb_gro_... | static struct sk_buff **gre_gro_receive(struct sk_buff **head, struct sk_buff *skb) {
struct sk_buff **pp = NULL;
struct sk_buff *p;
const struct gre_base_hdr *greh;
unsigned int hlen, grehlen;
unsigned int off;
int flush = 1;
struct packet_offload *ptype;
__be16 type;
if (NAPI_GRO_C... | static struct sk_buff **gre_gro_receive(struct sk_buff **head, struct sk_buff *skb) {
int flush = 1;
__be16 type;
off = skb_gro_offset(skb);
hlen = off + sizeof(*greh);
greh = skb_gro_header_fast(skb, off);
if (skb_gro_header_hard(skb, hlen)) {
greh = skb_gro_header_slow(skb, hlen, off);... | static struct sk_buff **gre_gro_receive(struct sk_buff **head, struct sk_buff *skb) {
int flush = 1;
__be16 type;
if (NAPI_GRO_CB(skb)->encap_mark) {
goto out;
}
NAPI_GRO_CB(skb)->encap_mark = 1;
off = skb_gro_offset(skb);
hlen = off + sizeof(*greh);
greh = skb_gro_header_fast(sk... | static struct sk_buff **gre_gro_receive(struct sk_buff **head, struct sk_buff *skb) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
int flush = 1;
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
__be16 type;
off = skb_gro_offset(skb);
hlen = off + sizeof(*greh);
greh = skb_gro_header_fast(skb,... | static struct sk_buff **gre_gro_receive(struct sk_buff **head, struct sk_buff *skb) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
int flush = 1;
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
__be16 type;
if (NAPI_GRO_CB(skb)->encap_mark) {
goto out;
}
NAPI_GRO_CB(skb)->encap_mark =... | static struct sk_buff **gre_gro_receive(struct sk_buff **head, struct sk_buff *skb) {
int flush = 1;
__be16 type;
+ if (NAPI_GRO_CB(skb)->encap_mark) {
+ goto out;
+ }
+ NAPI_GRO_CB(skb)->encap_mark = 1;
off = skb_gro_offset(skb);
hlen = off + sizeof(*greh);
greh = skb_gro_head... |
CVE-2016-8666 | linux | https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux | net/ipv4/udp_offload.c | udp_gro_receive | static struct sk_buff **udp_gro_receive(struct sk_buff **head, struct sk_buff *skb) {
struct udp_offload_priv *uo_priv;
struct sk_buff *p, **pp = NULL;
struct udphdr *uh, *uh2;
unsigned int hlen, off;
int flush = 1;
if (NAPI_GRO_CB(skb)->udp_mark || (!skb->encapsulation && skb->ip_summed != CHEC... | static struct sk_buff **udp_gro_receive(struct sk_buff **head, struct sk_buff *skb) {
struct udp_offload_priv *uo_priv;
struct sk_buff *p, **pp = NULL;
struct udphdr *uh, *uh2;
unsigned int hlen, off;
int flush = 1;
if (NAPI_GRO_CB(skb)->encap_mark || (!skb->encapsulation && skb->ip_summed != CH... | struct sk_buff **udp_gro_receive(struct sk_buff **head, struct sk_buff *skb, struct udphdr *uh) {
struct udp_offload_priv *uo_priv;
struct sk_buff *p, **pp = NULL;
struct udphdr *uh2;
unsigned int off = skb_gro_offset(skb);
int flush = 1;
if (NAPI_GRO_CB(skb)->udp_mark || (skb->ip_summed != CHEC... | struct sk_buff **udp_gro_receive(struct sk_buff **head, struct sk_buff *skb, struct udphdr *uh) {
struct udp_offload_priv *uo_priv;
struct sk_buff *p, **pp = NULL;
struct udphdr *uh2;
unsigned int off = skb_gro_offset(skb);
int flush = 1;
if (NAPI_GRO_CB(skb)->encap_mark || (skb->ip_summed != CH... | static struct sk_buff **udp_gro_receive(struct sk_buff **head, struct sk_buff *skb) {
int flush = 1;
if (NAPI_GRO_CB(skb)->udp_mark || (!skb->encapsulation && skb->ip_summed != CHECKSUM_COMPLETE)) {
goto out;
}
NAPI_GRO_CB(skb)->udp_mark = 1;
off = skb_gro_offset(skb);
hlen = off + sizeo... | static struct sk_buff **udp_gro_receive(struct sk_buff **head, struct sk_buff *skb) {
int flush = 1;
if (NAPI_GRO_CB(skb)->encap_mark || (!skb->encapsulation && skb->ip_summed != CHECKSUM_COMPLETE)) {
goto out;
}
NAPI_GRO_CB(skb)->encap_mark = 1;
off = skb_gro_offset(skb);
hlen = off + s... | struct sk_buff **udp_gro_receive(struct sk_buff **head, struct sk_buff *skb, struct udphdr *uh) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
int flush = 1;
if (NAPI_GRO_CB(skb)->udp_mark || (skb->ip_summed != CHECKSUM_PARTIAL && NAPI_GRO_CB(skb)->csum_cnt == 0 && !NAPI_GRO_CB(skb)->csum_valid)) {
... | struct sk_buff **udp_gro_receive(struct sk_buff **head, struct sk_buff *skb, struct udphdr *uh) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
int flush = 1;
if (NAPI_GRO_CB(skb)->encap_mark || (skb->ip_summed != CHECKSUM_PARTIAL && NAPI_GRO_CB(skb)->csum_cnt == 0 && !NAPI_GRO_CB(skb)->csum_valid)) {
... | static struct sk_buff **udp_gro_receive(struct sk_buff **head, struct sk_buff *skb) {
int flush = 1;
- if (NAPI_GRO_CB(skb)->udp_mark || (!skb->encapsulation && skb->ip_summed != CHECKSUM_COMPLETE)) {
+ if (NAPI_GRO_CB(skb)->encap_mark || (!skb->encapsulation && skb->ip_summed != CHECKSUM_COMPLETE)) {
... |
CVE-2016-9083 | linux | https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux | drivers/vfio/pci/vfio_pci.c | vfio_pci_ioctl | static long vfio_pci_ioctl(void *device_data, unsigned int cmd, unsigned long arg) {
struct vfio_pci_device *vdev = device_data;
unsigned long minsz;
if (cmd == VFIO_DEVICE_GET_FO) {
struct vfio_device_info info;
minsz = offsetofend(struct vfio_device_info, num_irqs);
if (copy_from_u... | static long vfio_pci_ioctl(void *device_data, unsigned int cmd, unsigned long arg) {
struct vfio_pci_device *vdev = device_data;
unsigned long minsz;
if (cmd == VFIO_DEVICE_GET_FO) {
struct vfio_device_info info;
minsz = offsetofend(struct vfio_device_info, num_irqs);
if (copy_from_u... | static long vfio_pci_ioctl(void *device_data, unsigned int cmd, unsigned long arg) {
struct vfio_pci_device *vdev = device_data;
unsigned long minsz;
if (cmd == VFIO_DEVICE_GET_FO) {
struct vfio_device_info info;
minsz = offsetofend(struct vfio_device_info, num_irqs);
if (copy_from_u... | static long vfio_pci_ioctl(void *device_data, unsigned int cmd, unsigned long arg) {
struct vfio_pci_device *vdev = device_data;
unsigned long minsz;
if (cmd == VFIO_DEVICE_GET_FO) {
struct vfio_device_info info;
minsz = offsetofend(struct vfio_device_info, num_irqs);
if (copy_from_u... | static long vfio_pci_ioctl(void *device_data, unsigned int cmd, unsigned long arg) {
struct vfio_pci_device *vdev = device_data;
if (cmd == VFIO_DEVICE_GET_FO) {
if (copy_from_user(&info, (void *)arg, minsz)) {
return -EFAULT;
}
if (info.argsz < minsz) {
return -E... | static long vfio_pci_ioctl(void *device_data, unsigned int cmd, unsigned long arg) {
struct vfio_pci_device *vdev = device_data;
if (cmd == VFIO_DEVICE_GET_FO) {
if (copy_from_user(&info, (void *)arg, minsz)) {
return -EFAULT;
}
if (info.argsz < minsz) {
return -E... | static long vfio_pci_ioctl(void *device_data, unsigned int cmd, unsigned long arg) {
struct vfio_pci_device *vdev = device_data;
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
if (cmd == VFIO_DEVICE_GET_FO) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
if (copy_from_user(&info, (void *)arg, min... | static long vfio_pci_ioctl(void *device_data, unsigned int cmd, unsigned long arg) {
struct vfio_pci_device *vdev = device_data;
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
if (cmd == VFIO_DEVICE_GET_FO) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
if (copy_from_user(&info, (void *)arg, min... | static long vfio_pci_ioctl(void *device_data, unsigned int cmd, unsigned long arg) {
struct vfio_pci_device *vdev = device_data;
if (cmd == VFIO_DEVICE_GET_FO) {
if (copy_from_user(&info, (void *)arg, minsz)) {
return -EFAULT;
}
if (info.argsz < minsz) {
r... |
CVE-2016-9083 | linux | https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux | drivers/vfio/pci/vfio_pci_intrs.c | vfio_msi_enable | static int vfio_msi_enable(struct vfio_pci_device *vdev, int nvec, bool msix) {
struct pci_dev *pdev = vdev->pdev;
int ret;
if (!is_irq_none(vdev)) {
return -EVAL;
}
vdev->ctx = kzalloc(nvec * sizeof(struct vfio_pci_irq_ctx), GFP_KERNEL);
if (!vdev->ctx) {
return -ENOMEM;
}
... | static int vfio_msi_enable(struct vfio_pci_device *vdev, int nvec, bool msix) {
struct pci_dev *pdev = vdev->pdev;
int ret;
if (!is_irq_none(vdev)) {
return -EVAL;
}
vdev->ctx = kcalloc(nvec, sizeof(struct vfio_pci_irq_ctx), GFP_KERNEL);
if (!vdev->ctx) {
return -ENOMEM;
}
... | static int vfio_msi_enable(struct vfio_pci_device *vdev, int nvec, bool msix) {
struct pci_dev *pdev = vdev->pdev;
int ret;
if (!is_irq_none(vdev)) {
return -EVAL;
}
vdev->ctx = kzalloc(nvec * sizeof(struct vfio_pci_irq_ctx), GFP_KERNEL);
if (!vdev->ctx) {
return -ENOMEM;
}
... | static int vfio_msi_enable(struct vfio_pci_device *vdev, int nvec, bool msix) {
struct pci_dev *pdev = vdev->pdev;
int ret;
if (!is_irq_none(vdev)) {
return -EVAL;
}
vdev->ctx = kcalloc(nvec, sizeof(struct vfio_pci_irq_ctx), GFP_KERNEL);
if (!vdev->ctx) {
return -ENOMEM;
}
... | static int vfio_msi_enable(struct vfio_pci_device *vdev, int nvec, bool msix) {
if (!is_irq_none(vdev)) {
return -EVAL;
}
vdev->ctx = kzalloc(nvec * sizeof(struct vfio_pci_irq_ctx), GFP_KERNEL);
if (!vdev->ctx) {
return -ENOMEM;
}
if (msix) {
vdev->msix = kzalloc(nvec * s... | static int vfio_msi_enable(struct vfio_pci_device *vdev, int nvec, bool msix) {
if (!is_irq_none(vdev)) {
return -EVAL;
}
vdev->ctx = kcalloc(nvec, sizeof(struct vfio_pci_irq_ctx), GFP_KERNEL);
if (!vdev->ctx) {
return -ENOMEM;
}
if (msix) {
vdev->msix = kzalloc(nvec * si... | static int vfio_msi_enable(struct vfio_pci_device *vdev, int nvec, bool msix) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
if (!is_irq_none(vdev)) {
return -EVAL;
}
vdev->ctx = kzalloc(nvec * sizeof(struct vfio_pci_irq_ctx), GFP_KERNEL);
if (!vdev->ctx) {
return -ENOMEM;
}
... | static int vfio_msi_enable(struct vfio_pci_device *vdev, int nvec, bool msix) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
if (!is_irq_none(vdev)) {
return -EVAL;
}
vdev->ctx = kcalloc(nvec, sizeof(struct vfio_pci_irq_ctx), GFP_KERNEL);
if (!vdev->ctx) {
return -ENOMEM;
}
... | static int vfio_msi_enable(struct vfio_pci_device *vdev, int nvec, bool msix) {
if (!is_irq_none(vdev)) {
return -EVAL;
}
- vdev->ctx = kzalloc(nvec * sizeof(struct vfio_pci_irq_ctx), GFP_KERNEL);
+ vdev->ctx = kcalloc(nvec, sizeof(struct vfio_pci_irq_ctx), GFP_KERNEL);
if (!vdev->ctx) {
... |
CVE-2016-9084 | linux | https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux | drivers/vfio/pci/vfio_pci.c | vfio_pci_ioctl | static long vfio_pci_ioctl(void *device_data, unsigned int cmd, unsigned long arg) {
struct vfio_pci_device *vdev = device_data;
unsigned long minsz;
if (cmd == VFIO_DEVICE_GET_FO) {
struct vfio_device_info info;
minsz = offsetofend(struct vfio_device_info, num_irqs);
if (copy_from_u... | static long vfio_pci_ioctl(void *device_data, unsigned int cmd, unsigned long arg) {
struct vfio_pci_device *vdev = device_data;
unsigned long minsz;
if (cmd == VFIO_DEVICE_GET_FO) {
struct vfio_device_info info;
minsz = offsetofend(struct vfio_device_info, num_irqs);
if (copy_from_u... | static long vfio_pci_ioctl(void *device_data, unsigned int cmd, unsigned long arg) {
struct vfio_pci_device *vdev = device_data;
unsigned long minsz;
if (cmd == VFIO_DEVICE_GET_FO) {
struct vfio_device_info info;
minsz = offsetofend(struct vfio_device_info, num_irqs);
if (copy_from_u... | static long vfio_pci_ioctl(void *device_data, unsigned int cmd, unsigned long arg) {
struct vfio_pci_device *vdev = device_data;
unsigned long minsz;
if (cmd == VFIO_DEVICE_GET_FO) {
struct vfio_device_info info;
minsz = offsetofend(struct vfio_device_info, num_irqs);
if (copy_from_u... | static long vfio_pci_ioctl(void *device_data, unsigned int cmd, unsigned long arg) {
struct vfio_pci_device *vdev = device_data;
if (cmd == VFIO_DEVICE_GET_FO) {
if (copy_from_user(&info, (void *)arg, minsz)) {
return -EFAULT;
}
if (info.argsz < minsz) {
return -E... | static long vfio_pci_ioctl(void *device_data, unsigned int cmd, unsigned long arg) {
struct vfio_pci_device *vdev = device_data;
if (cmd == VFIO_DEVICE_GET_FO) {
if (copy_from_user(&info, (void *)arg, minsz)) {
return -EFAULT;
}
if (info.argsz < minsz) {
return -E... | static long vfio_pci_ioctl(void *device_data, unsigned int cmd, unsigned long arg) {
struct vfio_pci_device *vdev = device_data;
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
if (cmd == VFIO_DEVICE_GET_FO) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
if (copy_from_user(&info, (void *)arg, min... | static long vfio_pci_ioctl(void *device_data, unsigned int cmd, unsigned long arg) {
struct vfio_pci_device *vdev = device_data;
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
if (cmd == VFIO_DEVICE_GET_FO) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
if (copy_from_user(&info, (void *)arg, min... | static long vfio_pci_ioctl(void *device_data, unsigned int cmd, unsigned long arg) {
struct vfio_pci_device *vdev = device_data;
if (cmd == VFIO_DEVICE_GET_FO) {
if (copy_from_user(&info, (void *)arg, minsz)) {
return -EFAULT;
}
if (info.argsz < minsz) {
r... |
CVE-2016-9084 | linux | https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux | drivers/vfio/pci/vfio_pci_intrs.c | vfio_msi_enable | static int vfio_msi_enable(struct vfio_pci_device *vdev, int nvec, bool msix) {
struct pci_dev *pdev = vdev->pdev;
int ret;
if (!is_irq_none(vdev)) {
return -EVAL;
}
vdev->ctx = kzalloc(nvec * sizeof(struct vfio_pci_irq_ctx), GFP_KERNEL);
if (!vdev->ctx) {
return -ENOMEM;
}
... | static int vfio_msi_enable(struct vfio_pci_device *vdev, int nvec, bool msix) {
struct pci_dev *pdev = vdev->pdev;
int ret;
if (!is_irq_none(vdev)) {
return -EVAL;
}
vdev->ctx = kcalloc(nvec, sizeof(struct vfio_pci_irq_ctx), GFP_KERNEL);
if (!vdev->ctx) {
return -ENOMEM;
}
... | static int vfio_msi_enable(struct vfio_pci_device *vdev, int nvec, bool msix) {
struct pci_dev *pdev = vdev->pdev;
int ret;
if (!is_irq_none(vdev)) {
return -EVAL;
}
vdev->ctx = kzalloc(nvec * sizeof(struct vfio_pci_irq_ctx), GFP_KERNEL);
if (!vdev->ctx) {
return -ENOMEM;
}
... | static int vfio_msi_enable(struct vfio_pci_device *vdev, int nvec, bool msix) {
struct pci_dev *pdev = vdev->pdev;
int ret;
if (!is_irq_none(vdev)) {
return -EVAL;
}
vdev->ctx = kcalloc(nvec, sizeof(struct vfio_pci_irq_ctx), GFP_KERNEL);
if (!vdev->ctx) {
return -ENOMEM;
}
... | static int vfio_msi_enable(struct vfio_pci_device *vdev, int nvec, bool msix) {
if (!is_irq_none(vdev)) {
return -EVAL;
}
vdev->ctx = kzalloc(nvec * sizeof(struct vfio_pci_irq_ctx), GFP_KERNEL);
if (!vdev->ctx) {
return -ENOMEM;
}
if (msix) {
vdev->msix = kzalloc(nvec * s... | static int vfio_msi_enable(struct vfio_pci_device *vdev, int nvec, bool msix) {
if (!is_irq_none(vdev)) {
return -EVAL;
}
vdev->ctx = kcalloc(nvec, sizeof(struct vfio_pci_irq_ctx), GFP_KERNEL);
if (!vdev->ctx) {
return -ENOMEM;
}
if (msix) {
vdev->msix = kzalloc(nvec * si... | static int vfio_msi_enable(struct vfio_pci_device *vdev, int nvec, bool msix) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
if (!is_irq_none(vdev)) {
return -EVAL;
}
vdev->ctx = kzalloc(nvec * sizeof(struct vfio_pci_irq_ctx), GFP_KERNEL);
if (!vdev->ctx) {
return -ENOMEM;
}
... | static int vfio_msi_enable(struct vfio_pci_device *vdev, int nvec, bool msix) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
if (!is_irq_none(vdev)) {
return -EVAL;
}
vdev->ctx = kcalloc(nvec, sizeof(struct vfio_pci_irq_ctx), GFP_KERNEL);
if (!vdev->ctx) {
return -ENOMEM;
}
... | static int vfio_msi_enable(struct vfio_pci_device *vdev, int nvec, bool msix) {
if (!is_irq_none(vdev)) {
return -EVAL;
}
- vdev->ctx = kzalloc(nvec * sizeof(struct vfio_pci_irq_ctx), GFP_KERNEL);
+ vdev->ctx = kcalloc(nvec, sizeof(struct vfio_pci_irq_ctx), GFP_KERNEL);
if (!vdev->ctx) {
... |
CVE-2016-9120 | linux | https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux | drivers/staging/android/ion/ion.c | ion_free | void ion_free(struct ion_client *client, struct ion_handle *handle) {
bool valid_handle;
BUG_ON(client != handle->client);
mutex_lock(&client->lock);
valid_handle = ion_handle_validate(client, handle);
if (!valid_handle) {
WARN(1, "%s: invalid handle passed to free.\n", __func__);
mu... | void ion_free(struct ion_client *client, struct ion_handle *handle) {
BUG_ON(client != handle->client);
mutex_lock(&client->lock);
ion_free_nolock(client, handle);
mutex_unlock(&client->lock);
} | void ion_free(struct ion_client *client, struct ion_handle *handle) {
bool valid_handle;
BUG_ON(client != handle->client);
mutex_lock(&client->lock);
valid_handle = ion_handle_validate(client, handle);
if (!valid_handle) {
WARN(1, "%s: invalid handle passed to free.\n", __func__);
mu... | void ion_free(struct ion_client *client, struct ion_handle *handle) {
BUG_ON(client != handle->client);
mutex_lock(&client->lock);
ion_free_nolock(client, handle);
mutex_unlock(&client->lock);
} | void ion_free(struct ion_client *client, struct ion_handle *handle) {
bool valid_handle;
BUG_ON(client != handle->client);
mutex_lock(&client->lock);
valid_handle = ion_handle_validate(client, handle);
if (!valid_handle) {
WARN(1, "%s: invalid handle passed to free.\n", __func__);
mu... | void ion_free(struct ion_client *client, struct ion_handle *handle) {
BUG_ON(client != handle->client);
mutex_lock(&client->lock);
ion_free_nolock(client, handle);
mutex_unlock(&client->lock);
}
| void ion_free(struct ion_client *client, struct ion_handle *handle) {
bool valid_handle;
BUG_ON(client != handle->client);
mutex_lock(&client->lock);
valid_handle = ion_handle_validate(client, handle);
if (!valid_handle) {
WARN(1, "%s: invalid handle passed to free.\n", __func__);
mu... | void ion_free(struct ion_client *client, struct ion_handle *handle) {
BUG_ON(client != handle->client);
mutex_lock(&client->lock);
ion_free_nolock(client, handle);
mutex_unlock(&client->lock);
} | void ion_free(struct ion_client *client, struct ion_handle *handle) {
- bool valid_handle;
BUG_ON(client != handle->client);
mutex_lock(&client->lock);
- valid_handle = ion_handle_validate(client, handle);
- if (!valid_handle) {
- WARN(1, "%s: invalid handle passed to free.\n", __func__);
- ... |
CVE-2016-9120 | linux | https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux | drivers/staging/android/ion/ion.c | ion_handle_put | static int ion_handle_put(struct ion_handle *handle) {
struct ion_client *client = handle->client;
int ret;
mutex_lock(&client->lock);
ret = kref_put(&handle->ref, ion_handle_destroy);
mutex_unlock(&client->lock);
return ret;
} | int ion_handle_put(struct ion_handle *handle) {
struct ion_client *client = handle->client;
int ret;
mutex_lock(&client->lock);
ret = ion_handle_put_nolock(handle);
mutex_unlock(&client->lock);
return ret;
} | static int ion_handle_put(struct ion_handle *handle) {
struct ion_client *client = handle->client;
int ret;
mutex_lock(&client->lock);
ret = kref_put(&handle->ref, ion_handle_destroy);
mutex_unlock(&client->lock);
return ret;
} | int ion_handle_put(struct ion_handle *handle) {
struct ion_client *client = handle->client;
int ret;
mutex_lock(&client->lock);
ret = ion_handle_put_nolock(handle);
mutex_unlock(&client->lock);
return ret;
} | static int ion_handle_put(struct ion_handle *handle) {
struct ion_client *client = handle->client;
int ret;
mutex_lock(&client->lock);
ret = kref_put(&handle->ref, ion_handle_destroy);
mutex_unlock(&client->lock);
return ret;
}
| int ion_handle_put(struct ion_handle *handle) {
struct ion_client *client = handle->client;
int ret;
mutex_lock(&client->lock);
ret = ion_handle_put_nolock(handle);
mutex_unlock(&client->lock);
return ret;
}
| static int ion_handle_put(struct ion_handle *handle) {
struct ion_client *client = handle->client;
int ret;
mutex_lock(&client->lock);
ret = kref_put(&handle->ref, ion_handle_destroy);
mutex_unlock(&client->lock);
return ret;
}
| int ion_handle_put(struct ion_handle *handle) {
struct ion_client *client = handle->client;
int ret;
mutex_lock(&client->lock);
ret = ion_handle_put_nolock(handle);
mutex_unlock(&client->lock);
return ret;
} | -static int ion_handle_put(struct ion_handle *handle) {
+int ion_handle_put(struct ion_handle *handle) {
struct ion_client *client = handle->client;
int ret;
mutex_lock(&client->lock);
- ret = kref_put(&handle->ref, ion_handle_destroy);
+ ret = ion_handle_put_nolock(handle);
mutex_unlock(&clie... |
CVE-2016-9120 | linux | https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux | drivers/staging/android/ion/ion.c | ion_ioctl | static long ion_ioctl(struct file *filp, unsigned int cmd, unsigned long arg) {
struct ion_client *client = filp->private_data;
struct ion_device *dev = client->dev;
struct ion_handle *cleanup_handle = NULL;
int ret = 0;
unsigned int dir;
union {
struct ion_fd_data fd;
struct ion... | static long ion_ioctl(struct file *filp, unsigned int cmd, unsigned long arg) {
struct ion_client *client = filp->private_data;
struct ion_device *dev = client->dev;
struct ion_handle *cleanup_handle = NULL;
int ret = 0;
unsigned int dir;
union {
struct ion_fd_data fd;
struct ion... | static long ion_ioctl(struct file *filp, unsigned int cmd, unsigned long arg) {
struct ion_client *client = filp->private_data;
struct ion_device *dev = client->dev;
struct ion_handle *cleanup_handle = NULL;
int ret = 0;
unsigned int dir;
union {
struct ion_fd_data fd;
struct ion... | static long ion_ioctl(struct file *filp, unsigned int cmd, unsigned long arg) {
struct ion_client *client = filp->private_data;
struct ion_device *dev = client->dev;
struct ion_handle *cleanup_handle = NULL;
int ret = 0;
unsigned int dir;
union {
struct ion_fd_data fd;
struct ion... | static long ion_ioctl(struct file *filp, unsigned int cmd, unsigned long arg) {
struct ion_client *client = filp->private_data;
switch (cmd) {
case ION_IOC_FREE: {
struct ion_handle *handle;
handle = ion_handle_get_by_id(client, data.handle.handle);
if (IS_ERR(handle)) {
... | static long ion_ioctl(struct file *filp, unsigned int cmd, unsigned long arg) {
struct ion_client *client = filp->private_data;
switch (cmd) {
case ION_IOC_FREE: {
struct ion_handle *handle;
mutex_lock(&client->lock);
handle = ion_handle_get_by_id_nolock(client, data.handle.handle);
... | static long ion_ioctl(struct file *filp, unsigned int cmd, unsigned long arg) {
struct ion_client *client = filp->private_data;
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
switch (cmd) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
case ION_IOC_FREE: {
struct ion_handle *handle;
h... | static long ion_ioctl(struct file *filp, unsigned int cmd, unsigned long arg) {
struct ion_client *client = filp->private_data;
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
switch (cmd) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
case ION_IOC_FREE: {
struct ion_handle *handle;
m... | static long ion_ioctl(struct file *filp, unsigned int cmd, unsigned long arg) {
struct ion_client *client = filp->private_data;
switch (cmd) {
case ION_IOC_FREE: {
struct ion_handle *handle;
- handle = ion_handle_get_by_id(client, data.handle.handle);
+ mutex_lock(&client->lock);
... |
CVE-2016-9191 | linux | https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux | fs/proc/proc_sysctl.c | proc_sys_readdir | static int proc_sys_readdir(struct file *file, struct dir_context *ctx) {
struct ctl_table_header *head = grab_header(file_inode(file));
struct ctl_table_header *h = NULL;
struct ctl_table *entry;
struct ctl_dir *ctl_dir;
unsigned long pos;
if (IS_ERR(head)) {
return PTR_ERR(head);
}... | static int proc_sys_readdir(struct file *file, struct dir_context *ctx) {
struct ctl_table_header *head = grab_header(file_inode(file));
struct ctl_table_header *h = NULL;
struct ctl_table *entry;
struct ctl_dir *ctl_dir;
unsigned long pos;
if (IS_ERR(head)) {
return PTR_ERR(head);
}... | static int proc_sys_readdir(struct file *file, struct dir_context *ctx) {
struct ctl_table_header *head = grab_header(file_inode(file));
struct ctl_table_header *h = NULL;
struct ctl_table *entry;
struct ctl_dir *ctl_dir;
unsigned long pos;
if (IS_ERR(head)) {
return PTR_ERR(head);
}... | static int proc_sys_readdir(struct file *file, struct dir_context *ctx) {
struct ctl_table_header *head = grab_header(file_inode(file));
struct ctl_table_header *h = NULL;
struct ctl_table *entry;
struct ctl_dir *ctl_dir;
unsigned long pos;
if (IS_ERR(head)) {
return PTR_ERR(head);
}... | static int proc_sys_readdir(struct file *file, struct dir_context *ctx) {
if (!dir_emit_dots(file, ctx)) {
return 0;
}
sysctl_head_finish(head);
}
| static int proc_sys_readdir(struct file *file, struct dir_context *ctx) {
if (!dir_emit_dots(file, ctx)) {
goto out;
}
out:
sysctl_head_finish(head);
}
| static int proc_sys_readdir(struct file *file, struct dir_context *ctx) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
if (!dir_emit_dots(file, ctx)) {
return 0;
}
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
sysctl_head_finish(head);
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
}
| static int proc_sys_readdir(struct file *file, struct dir_context *ctx) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
if (!dir_emit_dots(file, ctx)) {
goto out;
}
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
out:
sysctl_head_finish(head);
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
... | static int proc_sys_readdir(struct file *file, struct dir_context *ctx) {
if (!dir_emit_dots(file, ctx)) {
- return 0;
+ goto out;
}
+out:
sysctl_head_finish(head);
} |
CVE-2016-9555 | linux | https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux | net/sctp/sm_statefuns.c | sctp_sf_ootb | sctp_disposition_t sctp_sf_ootb(struct net *net, const struct sctp_endpoint *ep, const struct sctp_association *asoc, const sctp_subtype_t type, void *arg, sctp_cmd_seq_t *commands) {
struct sctp_chunk *chunk = arg;
struct sk_buff *skb = chunk->skb;
sctp_chunkhdr_t *ch;
sctp_errhdr_t *err;
__u8 *ch_... | sctp_disposition_t sctp_sf_ootb(struct net *net, const struct sctp_endpoint *ep, const struct sctp_association *asoc, const sctp_subtype_t type, void *arg, sctp_cmd_seq_t *commands) {
struct sctp_chunk *chunk = arg;
struct sk_buff *skb = chunk->skb;
sctp_chunkhdr_t *ch;
sctp_errhdr_t *err;
__u8 *ch_... | sctp_disposition_t sctp_sf_ootb(struct net *net, const struct sctp_endpoint *ep, const struct sctp_association *asoc, const sctp_subtype_t type, void *arg, sctp_cmd_seq_t *commands) {
struct sctp_chunk *chunk = arg;
struct sk_buff *skb = chunk->skb;
sctp_chunkhdr_t *ch;
sctp_errhdr_t *err;
__u8 *ch_... | sctp_disposition_t sctp_sf_ootb(struct net *net, const struct sctp_endpoint *ep, const struct sctp_association *asoc, const sctp_subtype_t type, void *arg, sctp_cmd_seq_t *commands) {
struct sctp_chunk *chunk = arg;
struct sk_buff *skb = chunk->skb;
sctp_chunkhdr_t *ch;
sctp_errhdr_t *err;
__u8 *ch_... | sctp_disposition_t sctp_sf_ootb(struct net *net, const struct sctp_endpoint *ep, const struct sctp_association *asoc, const sctp_subtype_t type, void *arg, sctp_cmd_seq_t *commands) {
struct sctp_chunk *chunk = arg;
struct sk_buff *skb = chunk->skb;
SCTP_C_STATS(net, SCTP_MIB_OFBLUES);
ch = (sctp_chunkh... | sctp_disposition_t sctp_sf_ootb(struct net *net, const struct sctp_endpoint *ep, const struct sctp_association *asoc, const sctp_subtype_t type, void *arg, sctp_cmd_seq_t *commands) {
struct sctp_chunk *chunk = arg;
struct sk_buff *skb = chunk->skb;
SCTP_C_STATS(net, SCTP_MIB_OFBLUES);
ch = (sctp_chunkh... | sctp_disposition_t sctp_sf_ootb(struct net *net, const struct sctp_endpoint *ep, const struct sctp_association *asoc, const sctp_subtype_t type, void *arg, sctp_cmd_seq_t *commands) {
struct sctp_chunk *chunk = arg;
struct sk_buff *skb = chunk->skb;
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
SCTP_C_S... | sctp_disposition_t sctp_sf_ootb(struct net *net, const struct sctp_endpoint *ep, const struct sctp_association *asoc, const sctp_subtype_t type, void *arg, sctp_cmd_seq_t *commands) {
struct sctp_chunk *chunk = arg;
struct sk_buff *skb = chunk->skb;
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
SCTP_C_S... | sctp_disposition_t sctp_sf_ootb(struct net *net, const struct sctp_endpoint *ep, const struct sctp_association *asoc, const sctp_subtype_t type, void *arg, sctp_cmd_seq_t *commands) {
struct sctp_chunk *chunk = arg;
struct sk_buff *skb = chunk->skb;
SCTP_C_STATS(net, SCTP_MIB_OFBLUES);
ch = (sctp_c... |
CVE-2016-9588 | linux | https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux | arch/x86/kvm/vmx.c | handle_exception | static int handle_exception(struct kvm_vcpu *vcpu) {
struct vcpu_vmx *vmx = to_vmx(vcpu);
struct kvm_run *kvm_run = vcpu->run;
u32 intr_info, ex_no, error_code;
unsigned long cr2, rip, dr6;
u32 vect_info;
enum emulation_result er;
vect_info = vmx->idt_vectoring_info;
intr_info = vmx->exi... | static int handle_exception(struct kvm_vcpu *vcpu) {
struct vcpu_vmx *vmx = to_vmx(vcpu);
struct kvm_run *kvm_run = vcpu->run;
u32 intr_info, ex_no, error_code;
unsigned long cr2, rip, dr6;
u32 vect_info;
enum emulation_result er;
vect_info = vmx->idt_vectoring_info;
intr_info = vmx->exi... | static int handle_exception(struct kvm_vcpu *vcpu) {
struct vcpu_vmx *vmx = to_vmx(vcpu);
struct kvm_run *kvm_run = vcpu->run;
u32 intr_info, ex_no, error_code;
unsigned long cr2, rip, dr6;
u32 vect_info;
enum emulation_result er;
vect_info = vmx->idt_vectoring_info;
intr_info = vmx->exi... | static int handle_exception(struct kvm_vcpu *vcpu) {
struct vcpu_vmx *vmx = to_vmx(vcpu);
struct kvm_run *kvm_run = vcpu->run;
u32 intr_info, ex_no, error_code;
unsigned long cr2, rip, dr6;
u32 vect_info;
enum emulation_result er;
vect_info = vmx->idt_vectoring_info;
intr_info = vmx->exi... | static int handle_exception(struct kvm_vcpu *vcpu) {
struct vcpu_vmx *vmx = to_vmx(vcpu);
intr_info = vmx->exit_intr_info;
if (is_machine_check(intr_info)) {
return handle_machine_check(vcpu);
}
if ((intr_info & TR_FO_TR_TYPE_MASK) == TR_TYPE_NMI_TR) {
return 1;
}
if (is_no_d... | static int handle_exception(struct kvm_vcpu *vcpu) {
struct vcpu_vmx *vmx = to_vmx(vcpu);
intr_info = vmx->exit_intr_info;
if (is_machine_check(intr_info)) {
return handle_machine_check(vcpu);
}
if (is_nmi(intr_info)) {
return 1;
}
if (is_no_device(intr_info)) {
retur... | static int handle_exception(struct kvm_vcpu *vcpu) {
struct vcpu_vmx *vmx = to_vmx(vcpu);
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
intr_info = vmx->exit_intr_info;
if (is_machine_check(intr_info)) {
return handle_machine_check(vcpu);
}
if ((intr_info & TR_FO_TR_TYPE_MASK) == TR_TYPE... | static int handle_exception(struct kvm_vcpu *vcpu) {
struct vcpu_vmx *vmx = to_vmx(vcpu);
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
intr_info = vmx->exit_intr_info;
if (is_machine_check(intr_info)) {
return handle_machine_check(vcpu);
}
if (is_nmi(intr_info)) {
return 1;
... | static int handle_exception(struct kvm_vcpu *vcpu) {
struct vcpu_vmx *vmx = to_vmx(vcpu);
intr_info = vmx->exit_intr_info;
if (is_machine_check(intr_info)) {
return handle_machine_check(vcpu);
}
- if ((intr_info & TR_FO_TR_TYPE_MASK) == TR_TYPE_NMI_TR) {
+ if (is_nmi(intr_info)) {
... |
CVE-2016-9588 | linux | https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux | arch/x86/kvm/vmx.c | nested_vmx_exit_handled | static bool nested_vmx_exit_handled(struct kvm_vcpu *vcpu) {
u32 intr_info = vmcs_read32(VM_EXIT_TR_FO);
struct vcpu_vmx *vmx = to_vmx(vcpu);
struct vmcs12 *vmcs12 = get_vmcs12(vcpu);
u32 exit_reason = vmx->exit_reason;
trace_kvm_nested_vmexit(kvm_rip_read(vcpu), exit_reason, vmcs_readl(EXIT_QUALIFI... | static bool nested_vmx_exit_handled(struct kvm_vcpu *vcpu) {
u32 intr_info = vmcs_read32(VM_EXIT_TR_FO);
struct vcpu_vmx *vmx = to_vmx(vcpu);
struct vmcs12 *vmcs12 = get_vmcs12(vcpu);
u32 exit_reason = vmx->exit_reason;
trace_kvm_nested_vmexit(kvm_rip_read(vcpu), exit_reason, vmcs_readl(EXIT_QUALIFI... | static bool nested_vmx_exit_handled(struct kvm_vcpu *vcpu) {
u32 intr_info = vmcs_read32(VM_EXIT_TR_FO);
struct vcpu_vmx *vmx = to_vmx(vcpu);
struct vmcs12 *vmcs12 = get_vmcs12(vcpu);
u32 exit_reason = vmx->exit_reason;
trace_kvm_nested_vmexit(kvm_rip_read(vcpu), exit_reason, vmcs_readl(EXIT_QUALIFI... | static bool nested_vmx_exit_handled(struct kvm_vcpu *vcpu) {
u32 intr_info = vmcs_read32(VM_EXIT_TR_FO);
struct vcpu_vmx *vmx = to_vmx(vcpu);
struct vmcs12 *vmcs12 = get_vmcs12(vcpu);
u32 exit_reason = vmx->exit_reason;
trace_kvm_nested_vmexit(kvm_rip_read(vcpu), exit_reason, vmcs_readl(EXIT_QUALIFI... | static bool nested_vmx_exit_handled(struct kvm_vcpu *vcpu) {
u32 intr_info = vmcs_read32(VM_EXIT_TR_FO);
struct vcpu_vmx *vmx = to_vmx(vcpu);
struct vmcs12 *vmcs12 = get_vmcs12(vcpu);
u32 exit_reason = vmx->exit_reason;
trace_kvm_nested_vmexit(kvm_rip_read(vcpu), exit_reason, vmcs_readl(EXIT_QUALIFI... | static bool nested_vmx_exit_handled(struct kvm_vcpu *vcpu) {
u32 intr_info = vmcs_read32(VM_EXIT_TR_FO);
struct vcpu_vmx *vmx = to_vmx(vcpu);
struct vmcs12 *vmcs12 = get_vmcs12(vcpu);
u32 exit_reason = vmx->exit_reason;
trace_kvm_nested_vmexit(kvm_rip_read(vcpu), exit_reason, vmcs_readl(EXIT_QUALIFI... | static bool nested_vmx_exit_handled(struct kvm_vcpu *vcpu) {
u32 intr_info = vmcs_read32(VM_EXIT_TR_FO);
struct vcpu_vmx *vmx = to_vmx(vcpu);
struct vmcs12 *vmcs12 = get_vmcs12(vcpu);
u32 exit_reason = vmx->exit_reason;
trace_kvm_nested_vmexit(kvm_rip_read(vcpu), exit_reason, vmcs_readl(EXIT_QUALIFI... | static bool nested_vmx_exit_handled(struct kvm_vcpu *vcpu) {
u32 intr_info = vmcs_read32(VM_EXIT_TR_FO);
struct vcpu_vmx *vmx = to_vmx(vcpu);
struct vmcs12 *vmcs12 = get_vmcs12(vcpu);
u32 exit_reason = vmx->exit_reason;
trace_kvm_nested_vmexit(kvm_rip_read(vcpu), exit_reason, vmcs_readl(EXIT_QUALIFI... | static bool nested_vmx_exit_handled(struct kvm_vcpu *vcpu) {
u32 intr_info = vmcs_read32(VM_EXIT_TR_FO);
struct vcpu_vmx *vmx = to_vmx(vcpu);
struct vmcs12 *vmcs12 = get_vmcs12(vcpu);
u32 exit_reason = vmx->exit_reason;
trace_kvm_nested_vmexit(kvm_rip_read(vcpu), exit_reason, vmcs_readl(EXIT_Q... |
CVE-2016-9588 | linux | https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux | arch/x86/kvm/vmx.c | vmx_complete_atomic_exit | static void vmx_complete_atomic_exit(struct vcpu_vmx *vmx) {
u32 exit_intr_info;
if (!(vmx->exit_reason == EXIT_REASON_MCE_DURG_VMENTRY || vmx->exit_reason == EXIT_REASON_EXCEPTION_NMI)) {
return;
}
vmx->exit_intr_info = vmcs_read32(VM_EXIT_TR_FO);
exit_intr_info = vmx->exit_intr_info;
i... | static void vmx_complete_atomic_exit(struct vcpu_vmx *vmx) {
u32 exit_intr_info;
if (!(vmx->exit_reason == EXIT_REASON_MCE_DURG_VMENTRY || vmx->exit_reason == EXIT_REASON_EXCEPTION_NMI)) {
return;
}
vmx->exit_intr_info = vmcs_read32(VM_EXIT_TR_FO);
exit_intr_info = vmx->exit_intr_info;
i... | static void vmx_complete_atomic_exit(struct vcpu_vmx *vmx) {
u32 exit_intr_info;
if (!(vmx->exit_reason == EXIT_REASON_MCE_DURG_VMENTRY || vmx->exit_reason == EXIT_REASON_EXCEPTION_NMI)) {
return;
}
vmx->exit_intr_info = vmcs_read32(VM_EXIT_TR_FO);
exit_intr_info = vmx->exit_intr_info;
i... | static void vmx_complete_atomic_exit(struct vcpu_vmx *vmx) {
u32 exit_intr_info;
if (!(vmx->exit_reason == EXIT_REASON_MCE_DURG_VMENTRY || vmx->exit_reason == EXIT_REASON_EXCEPTION_NMI)) {
return;
}
vmx->exit_intr_info = vmcs_read32(VM_EXIT_TR_FO);
exit_intr_info = vmx->exit_intr_info;
i... | static void vmx_complete_atomic_exit(struct vcpu_vmx *vmx) {
vmx->exit_intr_info = vmcs_read32(VM_EXIT_TR_FO);
exit_intr_info = vmx->exit_intr_info;
if (is_machine_check(exit_intr_info)) {
kvm_machine_check();
}
if ((exit_intr_info & TR_FO_TR_TYPE_MASK) == TR_TYPE_NMI_TR && (exit_intr_info &... | static void vmx_complete_atomic_exit(struct vcpu_vmx *vmx) {
vmx->exit_intr_info = vmcs_read32(VM_EXIT_TR_FO);
exit_intr_info = vmx->exit_intr_info;
if (is_machine_check(exit_intr_info)) {
kvm_machine_check();
}
if (is_nmi(exit_intr_info)) {
kvm_before_handle_nmi(&vmx->vcpu);
}
}... | static void vmx_complete_atomic_exit(struct vcpu_vmx *vmx) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
vmx->exit_intr_info = vmcs_read32(VM_EXIT_TR_FO);
exit_intr_info = vmx->exit_intr_info;
if (is_machine_check(exit_intr_info)) {
kvm_machine_check();
}
if ((exit_intr_info & TR_FO_TR... | static void vmx_complete_atomic_exit(struct vcpu_vmx *vmx) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
vmx->exit_intr_info = vmcs_read32(VM_EXIT_TR_FO);
exit_intr_info = vmx->exit_intr_info;
if (is_machine_check(exit_intr_info)) {
kvm_machine_check();
}
if (is_nmi(exit_intr_info)) {
... | static void vmx_complete_atomic_exit(struct vcpu_vmx *vmx) {
vmx->exit_intr_info = vmcs_read32(VM_EXIT_TR_FO);
exit_intr_info = vmx->exit_intr_info;
if (is_machine_check(exit_intr_info)) {
kvm_machine_check();
}
- if ((exit_intr_info & TR_FO_TR_TYPE_MASK) == TR_TYPE_NMI_TR && (exit_intr... |
CVE-2016-9604 | linux | https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux | security/keys/keyctl.c | keyctl_join_session_keyring | long keyctl_join_session_keyring(const char *_name) {
char *name;
long ret;
name = NULL;
if (_name) {
name = strndup_user(_name, KEY_MAX_DESC_SIZE);
if (IS_ERR(name)) {
ret = PTR_ERR(name);
goto error;
}
}
ret = join_session_keyring(name);
kfre... | long keyctl_join_session_keyring(const char *_name) {
char *name;
long ret;
name = NULL;
if (_name) {
name = strndup_user(_name, KEY_MAX_DESC_SIZE);
if (IS_ERR(name)) {
ret = PTR_ERR(name);
goto error;
}
ret = -EPERM;
if (name[0] == '.') {
... | long keyctl_join_session_keyring(const char *_name) {
char *name;
long ret;
name = NULL;
if (_name) {
name = strndup_user(_name, PAGE_SIZE);
if (IS_ERR(name)) {
ret = PTR_ERR(name);
goto error;
}
}
ret = join_session_keyring(name);
kfree(name);... | long keyctl_join_session_keyring(const char *_name) {
char *name;
long ret;
name = NULL;
if (_name) {
name = strndup_user(_name, PAGE_SIZE);
if (IS_ERR(name)) {
ret = PTR_ERR(name);
goto error;
}
ret = -EPERM;
if (name[0] == '.') {
... | long keyctl_join_session_keyring(const char *_name) {
if (_name) {
name = strndup_user(_name, KEY_MAX_DESC_SIZE);
if (IS_ERR(name)) {
goto error;
}
}
ret = join_session_keyring(name);
kfree(name);
error:
return ret;
}
| long keyctl_join_session_keyring(const char *_name) {
if (_name) {
name = strndup_user(_name, KEY_MAX_DESC_SIZE);
if (IS_ERR(name)) {
goto error;
}
ret = -EPERM;
if (name[0] == '.') {
goto error_name;
}
}
ret = join_session_keyring(name... | long keyctl_join_session_keyring(const char *_name) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
if (_name) {
name = strndup_user(_name, PAGE_SIZE);
if (IS_ERR(name)) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
goto error;
}
}
ret = join_session_keyring(nam... | long keyctl_join_session_keyring(const char *_name) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
if (_name) {
name = strndup_user(_name, PAGE_SIZE);
if (IS_ERR(name)) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
goto error;
}
ret = -EPERM;
if (name[0... | long keyctl_join_session_keyring(const char *_name) {
if (_name) {
name = strndup_user(_name, KEY_MAX_DESC_SIZE);
if (IS_ERR(name)) {
goto error;
}
+ ret = -EPERM;
+ if (name[0] == '.') {
+ goto error_name;
+ }
}
ret = join_session_... |
CVE-2016-9644 | linux | https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux | arch/x86/kernel/kprobes/core.c | kprobe_fault_handler | int kprobe_fault_handler(struct pt_regs *regs, int trapnr) {
struct kprobe *cur = kprobe_running();
struct kprobe_ctlblk *kcb = get_kprobe_ctlblk();
if (unlikely(regs->ip == (unsigned long)cur->ainsn.insn)) {
WARN_ON(kcb->kprobe_status != KPROBE_HIT_SS && kcb->kprobe_status != KPROBE_REENTER);
... | int kprobe_fault_handler(struct pt_regs *regs, int trapnr) {
struct kprobe *cur = kprobe_running();
struct kprobe_ctlblk *kcb = get_kprobe_ctlblk();
if (unlikely(regs->ip == (unsigned long)cur->ainsn.insn)) {
WARN_ON(kcb->kprobe_status != KPROBE_HIT_SS && kcb->kprobe_status != KPROBE_REENTER);
... | int kprobe_fault_handler(struct pt_regs *regs, int trapnr) {
struct kprobe *cur = kprobe_running();
struct kprobe_ctlblk *kcb = get_kprobe_ctlblk();
if (unlikely(regs->ip == (unsigned long)cur->ainsn.insn)) {
WARN_ON(kcb->kprobe_status != KPROBE_HIT_SS && kcb->kprobe_status != KPROBE_REENTER);
... | int kprobe_fault_handler(struct pt_regs *regs, int trapnr) {
struct kprobe *cur = kprobe_running();
struct kprobe_ctlblk *kcb = get_kprobe_ctlblk();
if (unlikely(regs->ip == (unsigned long)cur->ainsn.insn)) {
WARN_ON(kcb->kprobe_status != KPROBE_HIT_SS && kcb->kprobe_status != KPROBE_REENTER);
... | int kprobe_fault_handler(struct pt_regs *regs, int trapnr) {
struct kprobe *cur = kprobe_running();
if (unlikely(regs->ip == (unsigned long)cur->ainsn.insn)) {
} else if (kcb->kprobe_status == KPROBE_HIT_ACTIVE || kcb->kprobe_status == KPROBE_HIT_SSDONE) {
kprobes_inc_nmissed_count(cur);
if ... | int kprobe_fault_handler(struct pt_regs *regs, int trapnr) {
struct kprobe *cur = kprobe_running();
if (unlikely(regs->ip == (unsigned long)cur->ainsn.insn)) {
} else if (kcb->kprobe_status == KPROBE_HIT_ACTIVE || kcb->kprobe_status == KPROBE_HIT_SSDONE) {
kprobes_inc_nmissed_count(cur);
if ... | int kprobe_fault_handler(struct pt_regs *regs, int trapnr) {
struct kprobe *cur = kprobe_running();
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
if (unlikely(regs->ip == (unsigned long)cur->ainsn.insn)) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
} else if (kcb->kprobe_status == KPROBE_HIT_ACTI... | int kprobe_fault_handler(struct pt_regs *regs, int trapnr) {
struct kprobe *cur = kprobe_running();
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
if (unlikely(regs->ip == (unsigned long)cur->ainsn.insn)) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
} else if (kcb->kprobe_status == KPROBE_HIT_ACTI... | int kprobe_fault_handler(struct pt_regs *regs, int trapnr) {
struct kprobe *cur = kprobe_running();
if (unlikely(regs->ip == (unsigned long)cur->ainsn.insn)) {
} else if (kcb->kprobe_status == KPROBE_HIT_ACTIVE || kcb->kprobe_status == KPROBE_HIT_SSDONE) {
kprobes_inc_nmissed_count(cur);
... |
CVE-2016-9644 | linux | https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux | arch/x86/kernel/traps.c | do_general_protection | dotraplinkage void do_general_protection(struct pt_regs *regs, long error_code) {
struct task_struct *tsk;
enum ctx_state prev_state;
prev_state = exception_enter();
conditional_sti(regs);
if (v8086_mode(regs)) {
local_irq_enable();
handle_vm86_fault((struct kernel_vm86_regs *) regs,... | dotraplinkage void do_general_protection(struct pt_regs *regs, long error_code) {
struct task_struct *tsk;
enum ctx_state prev_state;
prev_state = exception_enter();
conditional_sti(regs);
if (v8086_mode(regs)) {
local_irq_enable();
handle_vm86_fault((struct kernel_vm86_regs *) regs,... | dotraplinkage void do_general_protection(struct pt_regs *regs, long error_code) {
struct task_struct *tsk;
RCU_LOCKDEP_WARN(!rcu_is_watching(), "entry code didn't wake RCU");
conditional_sti(regs);
if (v8086_mode(regs)) {
local_irq_enable();
handle_vm86_fault((struct kernel_vm86_regs *) ... | dotraplinkage void do_general_protection(struct pt_regs *regs, long error_code) {
struct task_struct *tsk;
RCU_LOCKDEP_WARN(!rcu_is_watching(), "entry code didn't wake RCU");
conditional_sti(regs);
if (v8086_mode(regs)) {
local_irq_enable();
handle_vm86_fault((struct kernel_vm86_regs *) ... | dotraplinkage void do_general_protection(struct pt_regs *regs, long error_code) {
conditional_sti(regs);
if (v8086_mode(regs)) {
goto exit;
}
if (!user_mode(regs)) {
if (fixup_exception(regs)) {
goto exit;
}
tsk->thread.error_code = error_code;
tsk->th... | dotraplinkage void do_general_protection(struct pt_regs *regs, long error_code) {
conditional_sti(regs);
if (v8086_mode(regs)) {
goto exit;
}
if (!user_mode(regs)) {
if (fixup_exception(regs, X86_TRAP_GP)) {
goto exit;
}
tsk->thread.error_code = error_code;
... | dotraplinkage void do_general_protection(struct pt_regs *regs, long error_code) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
conditional_sti(regs);
if (v8086_mode(regs)) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
return;
}
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
if (!us... | dotraplinkage void do_general_protection(struct pt_regs *regs, long error_code) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
conditional_sti(regs);
if (v8086_mode(regs)) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
return;
}
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
if (!us... | dotraplinkage void do_general_protection(struct pt_regs *regs, long error_code) {
conditional_sti(regs);
if (v8086_mode(regs)) {
goto exit;
}
if (!user_mode(regs)) {
- if (fixup_exception(regs)) {
+ if (fixup_exception(regs, X86_TRAP_GP)) {
goto exit;
}
... |
CVE-2016-9644 | linux | https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux | arch/x86/kernel/traps.c | math_error | static void math_error(struct pt_regs *regs, int error_code, int trapnr) {
struct task_struct *task = current;
siginfo_t info;
unsigned short err;
char *str = (trapnr == X86_TRAP_MF) ? "fpu exception" :
"simd exception";
if (notify_die(DIE_TRAP, str, regs, error_code, trapnr, SIGFPE)... | static void math_error(struct pt_regs *regs, int error_code, int trapnr) {
struct task_struct *task = current;
siginfo_t info;
unsigned short err;
char *str = (trapnr == X86_TRAP_MF) ? "fpu exception" :
"simd exception";
if (notify_die(DIE_TRAP, str, regs, error_code, trapnr, SIGFPE)... | static void math_error(struct pt_regs *regs, int error_code, int trapnr) {
struct task_struct *task = current;
struct fpu *fpu = &task->thread.fpu;
siginfo_t info;
char *str = (trapnr == X86_TRAP_MF) ? "fpu exception" :
"simd exception";
if (notify_die(DIE_TRAP, str, regs, error_code... | static void math_error(struct pt_regs *regs, int error_code, int trapnr) {
struct task_struct *task = current;
struct fpu *fpu = &task->thread.fpu;
siginfo_t info;
char *str = (trapnr == X86_TRAP_MF) ? "fpu exception" :
"simd exception";
if (notify_die(DIE_TRAP, str, regs, error_code... | static void math_error(struct pt_regs *regs, int error_code, int trapnr) {
char *str = (trapnr == X86_TRAP_MF) ? "fpu exception" :
"simd exception";
if (notify_die(DIE_TRAP, str, regs, error_code, trapnr, SIGFPE) == NOTIFY_STOP) {
return;
}
conditional_sti(regs);
if (!user_mo... | static void math_error(struct pt_regs *regs, int error_code, int trapnr) {
char *str = (trapnr == X86_TRAP_MF) ? "fpu exception" :
"simd exception";
if (notify_die(DIE_TRAP, str, regs, error_code, trapnr, SIGFPE) == NOTIFY_STOP) {
return;
}
conditional_sti(regs);
if (!user_mo... | static void math_error(struct pt_regs *regs, int error_code, int trapnr) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
char *str = (trapnr == X86_TRAP_MF) ? "fpu exception" :
"simd exception";
if (notify_die(DIE_TRAP, str, regs, error_code, trapnr, SIGFPE) == NOTIFY_STOP) {
return;... | static void math_error(struct pt_regs *regs, int error_code, int trapnr) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
char *str = (trapnr == X86_TRAP_MF) ? "fpu exception" :
"simd exception";
if (notify_die(DIE_TRAP, str, regs, error_code, trapnr, SIGFPE) == NOTIFY_STOP) {
return;... | static void math_error(struct pt_regs *regs, int error_code, int trapnr) {
char *str = (trapnr == X86_TRAP_MF) ? "fpu exception" :
"simd exception";
if (notify_die(DIE_TRAP, str, regs, error_code, trapnr, SIGFPE) == NOTIFY_STOP) {
return;
}
conditional_sti(regs);
if (... |
CVE-2016-9644 | linux | https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux | arch/x86/mm/extable.c | early_fixup_exception | int early_fixup_exception(unsigned long *ip) {
const struct exception_table_entry *fixup;
unsigned long new_ip;
fixup = search_exception_tables(*ip);
if (fixup) {
new_ip = ex_fixup_addr(fixup);
if (fixup->fixup - fixup->insn >= 0x7ffffff0 - 4) {
return 0;
}
*i... | int early_fixup_exception(unsigned long *ip) {
const struct exception_table_entry *e;
unsigned long new_ip;
ex_handler_t handler;
e = search_exception_tables(*ip);
if (!e) {
return 0;
}
new_ip = ex_fixup_addr(e);
handler = ex_fixup_handler(e);
if (handler != ex_handler_defaul... | int early_fixup_exception(unsigned long *ip) {
const struct exception_table_entry *fixup;
unsigned long new_ip;
fixup = search_exception_tables(*ip);
if (fixup) {
new_ip = ex_fixup_addr(fixup);
if (fixup->fixup - fixup->insn >= 0x7ffffff0 - 4) {
return 0;
}
*i... | int early_fixup_exception(unsigned long *ip) {
const struct exception_table_entry *e;
unsigned long new_ip;
ex_handler_t handler;
e = search_exception_tables(*ip);
if (!e) {
return 0;
}
new_ip = ex_fixup_addr(e);
handler = ex_fixup_handler(e);
if (handler != ex_handler_defaul... | int early_fixup_exception(unsigned long *ip) {
const struct exception_table_entry *fixup;
unsigned long new_ip;
fixup = search_exception_tables(*ip);
if (fixup) {
new_ip = ex_fixup_addr(fixup);
if (fixup->fixup - fixup->insn >= 0x7ffffff0 - 4) {
return 0;
}
*i... | int early_fixup_exception(unsigned long *ip) {
const struct exception_table_entry *e;
unsigned long new_ip;
ex_handler_t handler;
e = search_exception_tables(*ip);
if (!e) {
return 0;
}
new_ip = ex_fixup_addr(e);
handler = ex_fixup_handler(e);
if (handler != ex_handler_defaul... | int early_fixup_exception(unsigned long *ip) {
const struct exception_table_entry *fixup;
unsigned long new_ip;
fixup = search_exception_tables(*ip);
if (fixup) {
new_ip = ex_fixup_addr(fixup);
if (fixup->fixup - fixup->insn >= 0x7ffffff0 - 4) {
return 0;
}
*i... | int early_fixup_exception(unsigned long *ip) {
const struct exception_table_entry *e;
unsigned long new_ip;
ex_handler_t handler;
e = search_exception_tables(*ip);
if (!e) {
return 0;
}
new_ip = ex_fixup_addr(e);
handler = ex_fixup_handler(e);
if (handler != ex_handler_defaul... | int early_fixup_exception(unsigned long *ip) {
- const struct exception_table_entry *fixup;
+ const struct exception_table_entry *e;
unsigned long new_ip;
- fixup = search_exception_tables(*ip);
- if (fixup) {
- new_ip = ex_fixup_addr(fixup);
- if (fixup->fixup - fixup->insn >= 0x7ffffff... |
CVE-2016-9644 | linux | https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux | arch/x86/mm/extable.c | fixup_exception | int fixup_exception(struct pt_regs *regs) {
const struct exception_table_entry *fixup;
unsigned long new_ip;
if (unlikely(SEGMENT_IS_PNP_CODE(regs->cs))) {
extern u32 pnp_bios_fault_eip, pnp_bios_fault_esp;
extern u32 pnp_bios_is_utter_crap;
pnp_bios_is_utter_crap = 1;
printk... | int fixup_exception(struct pt_regs *regs, int trapnr) {
const struct exception_table_entry *e;
ex_handler_t handler;
if (unlikely(SEGMENT_IS_PNP_CODE(regs->cs))) {
extern u32 pnp_bios_fault_eip, pnp_bios_fault_esp;
extern u32 pnp_bios_is_utter_crap;
pnp_bios_is_utter_crap = 1;
... | int fixup_exception(struct pt_regs *regs) {
const struct exception_table_entry *fixup;
unsigned long new_ip;
if (unlikely(SEGMENT_IS_PNP_CODE(regs->cs))) {
extern u32 pnp_bios_fault_eip, pnp_bios_fault_esp;
extern u32 pnp_bios_is_utter_crap;
pnp_bios_is_utter_crap = 1;
printk... | int fixup_exception(struct pt_regs *regs, int trapnr) {
const struct exception_table_entry *e;
ex_handler_t handler;
if (unlikely(SEGMENT_IS_PNP_CODE(regs->cs))) {
extern u32 pnp_bios_fault_eip, pnp_bios_fault_esp;
extern u32 pnp_bios_is_utter_crap;
pnp_bios_is_utter_crap = 1;
... | int fixup_exception(struct pt_regs *regs) {
const struct exception_table_entry *fixup;
unsigned long new_ip;
if (unlikely(SEGMENT_IS_PNP_CODE(regs->cs))) {
panic("do_trap: can't hit this");
}
fixup = search_exception_tables(regs->ip);
if (fixup) {
new_ip = ex_fixup_addr(fixup);
... | int fixup_exception(struct pt_regs *regs, int trapnr) {
const struct exception_table_entry *e;
ex_handler_t handler;
if (unlikely(SEGMENT_IS_PNP_CODE(regs->cs))) {
panic("do_trap: can't hit this");
}
e = search_exception_tables(regs->ip);
if (!e) {
return 0;
}
handler = e... | int fixup_exception(struct pt_regs *regs) {
const struct exception_table_entry *fixup;
unsigned long new_ip;
if (unlikely(SEGMENT_IS_PNP_CODE(regs->cs))) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
panic("do_trap: can't hit this");
}
fixup = search_exception_tables(regs->ip);
if ... | int fixup_exception(struct pt_regs *regs, int trapnr) {
const struct exception_table_entry *e;
ex_handler_t handler;
if (unlikely(SEGMENT_IS_PNP_CODE(regs->cs))) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
panic("do_trap: can't hit this");
}
e = search_exception_tables(regs->ip);
... | -int fixup_exception(struct pt_regs *regs) {
- const struct exception_table_entry *fixup;
- unsigned long new_ip;
+int fixup_exception(struct pt_regs *regs, int trapnr) {
+ const struct exception_table_entry *e;
+ ex_handler_t handler;
if (unlikely(SEGMENT_IS_PNP_CODE(regs->cs))) {
panic("do_t... |
CVE-2016-9644 | linux | https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux | arch/x86/mm/extable.c | sort_extable | void sort_extable(struct exception_table_entry *start, struct exception_table_entry *finish) {
struct exception_table_entry *p;
int i;
i = 0;
for (p = start; p < finish; p++) {
p->insn += i;
i += 4;
p->fixup += i;
i += 4;
}
sort(start, finish - start, sizeof(struc... | void sort_extable(struct exception_table_entry *start, struct exception_table_entry *finish) {
struct exception_table_entry *p;
int i;
i = 0;
for (p = start; p < finish; p++) {
p->insn += i;
i += 4;
p->fixup += i;
i += 4;
p->handler += i;
i += 4;
}
... | void sort_extable(struct exception_table_entry *start, struct exception_table_entry *finish) {
struct exception_table_entry *p;
int i;
i = 0;
for (p = start; p < finish; p++) {
p->insn += i;
i += 4;
p->fixup += i;
i += 4;
}
sort(start, finish - start, sizeof(struc... | void sort_extable(struct exception_table_entry *start, struct exception_table_entry *finish) {
struct exception_table_entry *p;
int i;
i = 0;
for (p = start; p < finish; p++) {
p->insn += i;
i += 4;
p->fixup += i;
i += 4;
p->handler += i;
i += 4;
}
... | void sort_extable(struct exception_table_entry *start, struct exception_table_entry *finish) {
i = 0;
for (p = start; p < finish; p++) {
i += 4;
i += 4;
}
sort(start, finish - start, sizeof(struct exception_table_entry), cmp_ex, NULL);
i = 0;
for (p = start; p < finish; p++) {
... | void sort_extable(struct exception_table_entry *start, struct exception_table_entry *finish) {
i = 0;
for (p = start; p < finish; p++) {
i += 4;
i += 4;
p->handler += i;
i += 4;
}
sort(start, finish - start, sizeof(struct exception_table_entry), cmp_ex, NULL);
i = 0;
... | void sort_extable(struct exception_table_entry *start, struct exception_table_entry *finish) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
i = 0;
for (p = start; p < finish; p++) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
i += 4;
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
i... | void sort_extable(struct exception_table_entry *start, struct exception_table_entry *finish) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
i = 0;
for (p = start; p < finish; p++) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
i += 4;
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
i... | void sort_extable(struct exception_table_entry *start, struct exception_table_entry *finish) {
i = 0;
for (p = start; p < finish; p++) {
i += 4;
+ i += 4;
+ p->handler += i;
i += 4;
}
sort(start, finish - start, sizeof(struct exception_table_entry), cmp_ex, NULL);
... |
CVE-2016-9644 | linux | https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux | scripts/sortextable.c | do_file | static void do_file(char const *const fname) {
table_sort_t custom_sort;
Elf32_Ehdr *ehdr = mmap_file(fname);
ehdr_curr = ehdr;
switch (ehdr->e_ident[EI_DATA]) {
default:
fprintf(stderr, "unrecognized ELF data encoding %d: %s\n", ehdr->e_ident[EI_DATA], fname);
fail_file();
b... | static void do_file(char const *const fname) {
table_sort_t custom_sort;
Elf32_Ehdr *ehdr = mmap_file(fname);
ehdr_curr = ehdr;
switch (ehdr->e_ident[EI_DATA]) {
default:
fprintf(stderr, "unrecognized ELF data encoding %d: %s\n", ehdr->e_ident[EI_DATA], fname);
fail_file();
b... | static void do_file(char const *const fname) {
table_sort_t custom_sort;
Elf32_Ehdr *ehdr = mmap_file(fname);
ehdr_curr = ehdr;
switch (ehdr->e_ident[EI_DATA]) {
default:
fprintf(stderr, "unrecognized ELF data encoding %d: %s\n", ehdr->e_ident[EI_DATA], fname);
fail_file();
b... | static void do_file(char const *const fname) {
table_sort_t custom_sort;
Elf32_Ehdr *ehdr = mmap_file(fname);
ehdr_curr = ehdr;
switch (ehdr->e_ident[EI_DATA]) {
default:
fprintf(stderr, "unrecognized ELF data encoding %d: %s\n", ehdr->e_ident[EI_DATA], fname);
fail_file();
b... | static void do_file(char const *const fname) {
switch (r2(&ehdr->e_machine)) {
case EM_X86_64:
case EM_S390:
break;
}
switch (ehdr->e_ident[EI_CLASS]) {
case ELFCLASS32:
do32(ehdr, fname, custom_sort);
break;
case ELFCLASS64: {
do64(ghdr, fname, custom_sort);
... | static void do_file(char const *const fname) {
switch (r2(&ehdr->e_machine)) {
case EM_X86_64:
custom_sort = x86_sort_relative_table;
break;
case EM_S390:
break;
}
switch (ehdr->e_ident[EI_CLASS]) {
case ELFCLASS32:
do32(ehdr, fname, custom_sort);
break;
... | static void do_file(char const *const fname) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
switch (r2(&ehdr->e_machine)) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
case EM_X86_64:
case EM_S390:
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
break;
/* PLACEHOLDER: DO NOT DELETE ... | static void do_file(char const *const fname) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
switch (r2(&ehdr->e_machine)) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
case EM_X86_64:
custom_sort = x86_sort_relative_table;
break;
case EM_S390:
/* PLACEHOLDER: DO NOT DELETE THI... | static void do_file(char const *const fname) {
switch (r2(&ehdr->e_machine)) {
case EM_X86_64:
+ custom_sort = x86_sort_relative_table;
+ break;
case EM_S390:
break;
}
switch (ehdr->e_ident[EI_CLASS]) {
case ELFCLASS32:
do32(ehdr, fname, custom_sort);
... |
CVE-2016-9685 | linux | https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux | fs/xfs/xfs_attr_list.c | xfs_attr_shortform_list | int xfs_attr_shortform_list(xfs_attr_list_context_t *context) {
attrlist_cursor_kern_t *cursor;
xfs_attr_sf_sort_t *sbuf, *sbp;
xfs_attr_shortform_t *sf;
xfs_attr_sf_entry_t *sfe;
xfs_inode_t *dp;
int sbsize, nsbuf, count, i;
int error;
ASSERT(context != NULL);
dp = context->dp;
... | int xfs_attr_shortform_list(xfs_attr_list_context_t *context) {
attrlist_cursor_kern_t *cursor;
xfs_attr_sf_sort_t *sbuf, *sbp;
xfs_attr_shortform_t *sf;
xfs_attr_sf_entry_t *sfe;
xfs_inode_t *dp;
int sbsize, nsbuf, count, i;
int error;
ASSERT(context != NULL);
dp = context->dp;
... | int xfs_attr_shortform_list(xfs_attr_list_context_t *context) {
attrlist_cursor_kern_t *cursor;
xfs_attr_sf_sort_t *sbuf, *sbp;
xfs_attr_shortform_t *sf;
xfs_attr_sf_entry_t *sfe;
xfs_inode_t *dp;
int sbsize, nsbuf, count, i;
int error;
ASSERT(context != NULL);
dp = context->dp;
... | int xfs_attr_shortform_list(xfs_attr_list_context_t *context) {
attrlist_cursor_kern_t *cursor;
xfs_attr_sf_sort_t *sbuf, *sbp;
xfs_attr_shortform_t *sf;
xfs_attr_sf_entry_t *sfe;
xfs_inode_t *dp;
int sbsize, nsbuf, count, i;
int error;
ASSERT(context != NULL);
dp = context->dp;
... | int xfs_attr_shortform_list(xfs_attr_list_context_t *context) {
ASSERT(context != NULL);
dp = context->dp;
ASSERT(dp != NULL);
ASSERT(dp->i_afp != NULL);
sf = (xfs_attr_shortform_t *)dp->i_afp->if_u1.if_data;
ASSERT(sf != NULL);
if (!sf->hdr.count) {
return(0);
}
cursor = con... | int xfs_attr_shortform_list(xfs_attr_list_context_t *context) {
ASSERT(context != NULL);
dp = context->dp;
ASSERT(dp != NULL);
ASSERT(dp->i_afp != NULL);
sf = (xfs_attr_shortform_t *)dp->i_afp->if_u1.if_data;
ASSERT(sf != NULL);
if (!sf->hdr.count) {
return(0);
}
cursor = con... | int xfs_attr_shortform_list(xfs_attr_list_context_t *context) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
ASSERT(context != NULL);
dp = context->dp;
ASSERT(dp != NULL);
ASSERT(dp->i_afp != NULL);
sf = (xfs_attr_shortform_t *)dp->i_afp->if_u1.if_data;
ASSERT(sf != NULL);
if (!sf->hdr.... | int xfs_attr_shortform_list(xfs_attr_list_context_t *context) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
ASSERT(context != NULL);
dp = context->dp;
ASSERT(dp != NULL);
ASSERT(dp->i_afp != NULL);
sf = (xfs_attr_shortform_t *)dp->i_afp->if_u1.if_data;
ASSERT(sf != NULL);
if (!sf->hdr.... | int xfs_attr_shortform_list(xfs_attr_list_context_t *context) {
ASSERT(context != NULL);
dp = context->dp;
ASSERT(dp != NULL);
ASSERT(dp->i_afp != NULL);
sf = (xfs_attr_shortform_t *)dp->i_afp->if_u1.if_data;
ASSERT(sf != NULL);
if (!sf->hdr.count) {
return(0);
}
c... |
CVE-2016-9754 | linux | https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux | kernel/trace/ring_buffer.c | ring_buffer_resize | int ring_buffer_resize(struct ring_buffer *buffer, unsigned long size, int cpu_id) {
struct ring_buffer_per_cpu *cpu_buffer;
unsigned long nr_pages;
int cpu, err = 0;
if (!buffer) {
return size;
}
if (cpu_id != RG_BUFFER_ALL_CPUS && !cpumask_test_cpu(cpu_id, buffer->cpumask)) {
r... | int ring_buffer_resize(struct ring_buffer *buffer, unsigned long size, int cpu_id) {
struct ring_buffer_per_cpu *cpu_buffer;
unsigned long nr_pages;
int cpu, err = 0;
if (!buffer) {
return size;
}
if (cpu_id != RG_BUFFER_ALL_CPUS && !cpumask_test_cpu(cpu_id, buffer->cpumask)) {
r... | int ring_buffer_resize(struct ring_buffer *buffer, unsigned long size, int cpu_id) {
struct ring_buffer_per_cpu *cpu_buffer;
unsigned long nr_pages;
int cpu, err = 0;
if (!buffer) {
return size;
}
if (cpu_id != RG_BUFFER_ALL_CPUS && !cpumask_test_cpu(cpu_id, buffer->cpumask)) {
r... | int ring_buffer_resize(struct ring_buffer *buffer, unsigned long size, int cpu_id) {
struct ring_buffer_per_cpu *cpu_buffer;
unsigned long nr_pages;
int cpu, err = 0;
if (!buffer) {
return size;
}
if (cpu_id != RG_BUFFER_ALL_CPUS && !cpumask_test_cpu(cpu_id, buffer->cpumask)) {
r... | int ring_buffer_resize(struct ring_buffer *buffer, unsigned long size, int cpu_id) {
if (cpu_id != RG_BUFFER_ALL_CPUS && !cpumask_test_cpu(cpu_id, buffer->cpumask)) {
return size;
}
size = DIV_ROUND_UP(size, BUF_PAGE_SIZE);
size *= BUF_PAGE_SIZE;
if (size < BUF_PAGE_SIZE * 2) {
size ... | int ring_buffer_resize(struct ring_buffer *buffer, unsigned long size, int cpu_id) {
if (cpu_id != RG_BUFFER_ALL_CPUS && !cpumask_test_cpu(cpu_id, buffer->cpumask)) {
return size;
}
nr_pages = DIV_ROUND_UP(size, BUF_PAGE_SIZE);
if (nr_pages < 2) {
nr_pages = 2;
}
size = nr_pages ... | int ring_buffer_resize(struct ring_buffer *buffer, unsigned long size, int cpu_id) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
if (cpu_id != RG_BUFFER_ALL_CPUS && !cpumask_test_cpu(cpu_id, buffer->cpumask)) {
return size;
}
size = DIV_ROUND_UP(size, BUF_PAGE_SIZE);
size *= BUF_PAGE_SIZE;... | int ring_buffer_resize(struct ring_buffer *buffer, unsigned long size, int cpu_id) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
if (cpu_id != RG_BUFFER_ALL_CPUS && !cpumask_test_cpu(cpu_id, buffer->cpumask)) {
return size;
}
nr_pages = DIV_ROUND_UP(size, BUF_PAGE_SIZE);
if (nr_pages < 2) ... | int ring_buffer_resize(struct ring_buffer *buffer, unsigned long size, int cpu_id) {
if (cpu_id != RG_BUFFER_ALL_CPUS && !cpumask_test_cpu(cpu_id, buffer->cpumask)) {
return size;
}
- size = DIV_ROUND_UP(size, BUF_PAGE_SIZE);
- size *= BUF_PAGE_SIZE;
- if (size < BUF_PAGE_SIZE * 2) {
- ... |
CVE-2016-9756 | linux | https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux | arch/x86/kvm/emulate.c | em_jmp_far | static int em_jmp_far(struct x86_emulate_ctxt *ctxt) {
int rc;
unsigned short sel, old_sel;
struct desc_struct old_desc, new_desc;
const struct x86_emulate_ops *ops = ctxt->ops;
u8 cpl = ctxt->ops->cpl(ctxt);
if (ctxt->mode == X86EMUL_MODE_PROT64) {
ops->get_segment(ctxt, &old_sel, &old_... | static int em_jmp_far(struct x86_emulate_ctxt *ctxt) {
int rc;
unsigned short sel;
struct desc_struct new_desc;
u8 cpl = ctxt->ops->cpl(ctxt);
memcpy(&sel, ctxt->src.valptr + ctxt->op_bytes, 2);
rc = __load_segment_descriptor(ctxt, sel, VCPU_SREG_CS, cpl, X86_TRANSFER_CALL_JMP, &new_desc);
i... | static int em_jmp_far(struct x86_emulate_ctxt *ctxt) {
int rc;
unsigned short sel, old_sel;
struct desc_struct old_desc, new_desc;
const struct x86_emulate_ops *ops = ctxt->ops;
u8 cpl = ctxt->ops->cpl(ctxt);
if (ctxt->mode == X86EMUL_MODE_PROT64) {
ops->get_segment(ctxt, &old_sel, &old_... | static int em_jmp_far(struct x86_emulate_ctxt *ctxt) {
int rc;
unsigned short sel;
struct desc_struct new_desc;
u8 cpl = ctxt->ops->cpl(ctxt);
memcpy(&sel, ctxt->src.valptr + ctxt->op_bytes, 2);
rc = __load_segment_descriptor(ctxt, sel, VCPU_SREG_CS, cpl, X86_TRANSFER_CALL_JMP, &new_desc);
i... | static int em_jmp_far(struct x86_emulate_ctxt *ctxt) {
int rc;
unsigned short sel, old_sel;
struct desc_struct old_desc, new_desc;
const struct x86_emulate_ops *ops = ctxt->ops;
u8 cpl = ctxt->ops->cpl(ctxt);
if (ctxt->mode == X86EMUL_MODE_PROT64) {
ops->get_segment(ctxt, &old_sel, &old_... | static int em_jmp_far(struct x86_emulate_ctxt *ctxt) {
int rc;
unsigned short sel;
struct desc_struct new_desc;
u8 cpl = ctxt->ops->cpl(ctxt);
memcpy(&sel, ctxt->src.valptr + ctxt->op_bytes, 2);
rc = __load_segment_descriptor(ctxt, sel, VCPU_SREG_CS, cpl, X86_TRANSFER_CALL_JMP, &new_desc);
i... | static int em_jmp_far(struct x86_emulate_ctxt *ctxt) {
int rc;
unsigned short sel, old_sel;
struct desc_struct old_desc, new_desc;
const struct x86_emulate_ops *ops = ctxt->ops;
u8 cpl = ctxt->ops->cpl(ctxt);
if (ctxt->mode == X86EMUL_MODE_PROT64) {
ops->get_segment(ctxt, &old_sel, &old_... | static int em_jmp_far(struct x86_emulate_ctxt *ctxt) {
int rc;
unsigned short sel;
struct desc_struct new_desc;
u8 cpl = ctxt->ops->cpl(ctxt);
memcpy(&sel, ctxt->src.valptr + ctxt->op_bytes, 2);
rc = __load_segment_descriptor(ctxt, sel, VCPU_SREG_CS, cpl, X86_TRANSFER_CALL_JMP, &new_desc);
i... | static int em_jmp_far(struct x86_emulate_ctxt *ctxt) {
int rc;
- unsigned short sel, old_sel;
- struct desc_struct old_desc, new_desc;
- const struct x86_emulate_ops *ops = ctxt->ops;
+ unsigned short sel;
+ struct desc_struct new_desc;
u8 cpl = ctxt->ops->cpl(ctxt);
- if (ctxt->mode == X86... |
CVE-2016-9756 | linux | https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux | arch/x86/kvm/emulate.c | em_ret_far | static int em_ret_far(struct x86_emulate_ctxt *ctxt) {
int rc;
unsigned long eip, cs;
u16 old_cs;
int cpl = ctxt->ops->cpl(ctxt);
struct desc_struct old_desc, new_desc;
const struct x86_emulate_ops *ops = ctxt->ops;
if (ctxt->mode == X86EMUL_MODE_PROT64) {
ops->get_segment(ctxt, &old... | static int em_ret_far(struct x86_emulate_ctxt *ctxt) {
int rc;
unsigned long eip, cs;
int cpl = ctxt->ops->cpl(ctxt);
struct desc_struct new_desc;
rc = emulate_pop(ctxt, &eip, ctxt->op_bytes);
if (rc != X86EMUL_CONTUE) {
return rc;
}
rc = emulate_pop(ctxt, &cs, ctxt->op_bytes);
... | static int em_ret_far(struct x86_emulate_ctxt *ctxt) {
int rc;
unsigned long eip, cs;
u16 old_cs;
int cpl = ctxt->ops->cpl(ctxt);
struct desc_struct old_desc, new_desc;
const struct x86_emulate_ops *ops = ctxt->ops;
if (ctxt->mode == X86EMUL_MODE_PROT64) {
ops->get_segment(ctxt, &old... | static int em_ret_far(struct x86_emulate_ctxt *ctxt) {
int rc;
unsigned long eip, cs;
int cpl = ctxt->ops->cpl(ctxt);
struct desc_struct new_desc;
rc = emulate_pop(ctxt, &eip, ctxt->op_bytes);
if (rc != X86EMUL_CONTUE) {
return rc;
}
rc = emulate_pop(ctxt, &cs, ctxt->op_bytes);
... | static int em_ret_far(struct x86_emulate_ctxt *ctxt) {
unsigned long eip, cs;
u16 old_cs;
int cpl = ctxt->ops->cpl(ctxt);
struct desc_struct old_desc, new_desc;
const struct x86_emulate_ops *ops = ctxt->ops;
if (ctxt->mode == X86EMUL_MODE_PROT64) {
ops->get_segment(ctxt, &old_cs, &old_de... | static int em_ret_far(struct x86_emulate_ctxt *ctxt) {
unsigned long eip, cs;
int cpl = ctxt->ops->cpl(ctxt);
struct desc_struct new_desc;
rc = emulate_pop(ctxt, &eip, ctxt->op_bytes);
if (rc != X86EMUL_CONTUE) {
return rc;
}
rc = emulate_pop(ctxt, &cs, ctxt->op_bytes);
if (rc !=... | static int em_ret_far(struct x86_emulate_ctxt *ctxt) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
unsigned long eip, cs;
u16 old_cs;
int cpl = ctxt->ops->cpl(ctxt);
struct desc_struct old_desc, new_desc;
const struct x86_emulate_ops *ops = ctxt->ops;
if (ctxt->mode == X86EMUL_MODE_PROT64)... | static int em_ret_far(struct x86_emulate_ctxt *ctxt) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
unsigned long eip, cs;
int cpl = ctxt->ops->cpl(ctxt);
struct desc_struct new_desc;
rc = emulate_pop(ctxt, &eip, ctxt->op_bytes);
if (rc != X86EMUL_CONTUE) {
return rc;
}
rc = emu... | static int em_ret_far(struct x86_emulate_ctxt *ctxt) {
unsigned long eip, cs;
- u16 old_cs;
int cpl = ctxt->ops->cpl(ctxt);
- struct desc_struct old_desc, new_desc;
- const struct x86_emulate_ops *ops = ctxt->ops;
- if (ctxt->mode == X86EMUL_MODE_PROT64) {
- ops->get_segment(ctxt, &old_cs,... |
CVE-2016-9793 | linux | https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux | net/core/sock.c | sock_setsockopt | int sock_setsockopt(struct socket *sock, int level, int optname, char *optval, unsigned int optlen) {
struct sock *sk = sock->sk;
int val;
int valbool;
struct linger ling;
int ret = 0;
if (optname == SO_BDTODEVICE) {
return sock_setbindtodevice(sk, optval, optlen);
}
if (optlen <... | int sock_setsockopt(struct socket *sock, int level, int optname, char *optval, unsigned int optlen) {
struct sock *sk = sock->sk;
int val;
int valbool;
struct linger ling;
int ret = 0;
if (optname == SO_BDTODEVICE) {
return sock_setbindtodevice(sk, optval, optlen);
}
if (optlen <... | int sock_setsockopt(struct socket *sock, int level, int optname, char *optval, unsigned int optlen) {
struct sock *sk = sock->sk;
int val;
int valbool;
struct linger ling;
int ret = 0;
if (optname == SO_BDTODEVICE) {
return sock_setbindtodevice(sk, optval, optlen);
}
if (optlen <... | int sock_setsockopt(struct socket *sock, int level, int optname, char *optval, unsigned int optlen) {
struct sock *sk = sock->sk;
int val;
int valbool;
struct linger ling;
int ret = 0;
if (optname == SO_BDTODEVICE) {
return sock_setbindtodevice(sk, optval, optlen);
}
if (optlen <... | int sock_setsockopt(struct socket *sock, int level, int optname, char *optval, unsigned int optlen) {
switch (optname) {
case SO_SNDBUF:
val = min_t(u32, val, sysctl_wmem_max);
set_sndbuf:
sk->sk_userlocks |= SOCK_SNDBUF_LOCK;
sk->sk_sndbuf = max_t(u32, val * 2, SOCK_M_SNDBUF);
s... | int sock_setsockopt(struct socket *sock, int level, int optname, char *optval, unsigned int optlen) {
switch (optname) {
case SO_SNDBUF:
val = min_t(u32, val, sysctl_wmem_max);
set_sndbuf:
sk->sk_userlocks |= SOCK_SNDBUF_LOCK;
sk->sk_sndbuf = max_t(int, val * 2, SOCK_M_SNDBUF);
s... | int sock_setsockopt(struct socket *sock, int level, int optname, char *optval, unsigned int optlen) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
switch (optname) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
case SO_SNDBUF:
val = min_t(u32, val, sysctl_wmem_max);
set_sndbuf:
sk->sk_... | int sock_setsockopt(struct socket *sock, int level, int optname, char *optval, unsigned int optlen) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
switch (optname) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
case SO_SNDBUF:
val = min_t(u32, val, sysctl_wmem_max);
set_sndbuf:
sk->sk_... | int sock_setsockopt(struct socket *sock, int level, int optname, char *optval, unsigned int optlen) {
switch (optname) {
case SO_SNDBUF:
val = min_t(u32, val, sysctl_wmem_max);
set_sndbuf:
sk->sk_userlocks |= SOCK_SNDBUF_LOCK;
- sk->sk_sndbuf = max_t(u32, val * 2, SOCK_M_SNDBUF);
+ ... |
CVE-2016-9794 | linux | https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux | sound/core/pcm_lib.c | snd_pcm_period_elapsed | void snd_pcm_period_elapsed(struct snd_pcm_substream *substream) {
struct snd_pcm_runtime *runtime;
unsigned long flags;
if (PCM_RUNTIME_CHECK(substream)) {
return;
}
runtime = substream->runtime;
snd_pcm_stream_lock_irqsave(substream, flags);
if (!snd_pcm_running(substream) || snd_p... | void snd_pcm_period_elapsed(struct snd_pcm_substream *substream) {
struct snd_pcm_runtime *runtime;
unsigned long flags;
if (PCM_RUNTIME_CHECK(substream)) {
return;
}
runtime = substream->runtime;
snd_pcm_stream_lock_irqsave(substream, flags);
if (!snd_pcm_running(substream) || snd_p... | void snd_pcm_period_elapsed(struct snd_pcm_substream *substream) {
struct snd_pcm_runtime *runtime;
unsigned long flags;
if (PCM_RUNTIME_CHECK(substream)) {
return;
}
runtime = substream->runtime;
if (runtime->transfer_ack_begin) {
runtime->transfer_ack_begin(substream);
}
... | void snd_pcm_period_elapsed(struct snd_pcm_substream *substream) {
struct snd_pcm_runtime *runtime;
unsigned long flags;
if (PCM_RUNTIME_CHECK(substream)) {
return;
}
runtime = substream->runtime;
if (runtime->transfer_ack_begin) {
runtime->transfer_ack_begin(substream);
}
... | void snd_pcm_period_elapsed(struct snd_pcm_substream *substream) {
if (PCM_RUNTIME_CHECK(substream)) {
return;
}
runtime = substream->runtime;
snd_pcm_stream_lock_irqsave(substream, flags);
if (!snd_pcm_running(substream) || snd_pcm_update_hw_ptr0(substream, 1) < 0) {
goto _end;
... | void snd_pcm_period_elapsed(struct snd_pcm_substream *substream) {
if (PCM_RUNTIME_CHECK(substream)) {
return;
}
runtime = substream->runtime;
snd_pcm_stream_lock_irqsave(substream, flags);
if (!snd_pcm_running(substream) || snd_pcm_update_hw_ptr0(substream, 1) < 0) {
goto _end;
... | void snd_pcm_period_elapsed(struct snd_pcm_substream *substream) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
if (PCM_RUNTIME_CHECK(substream)) {
return;
}
runtime = substream->runtime;
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
snd_pcm_stream_lock_irqsave(substream, flags);
if... | void snd_pcm_period_elapsed(struct snd_pcm_substream *substream) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
if (PCM_RUNTIME_CHECK(substream)) {
return;
}
runtime = substream->runtime;
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
snd_pcm_stream_lock_irqsave(substream, flags);
if... | void snd_pcm_period_elapsed(struct snd_pcm_substream *substream) {
if (PCM_RUNTIME_CHECK(substream)) {
return;
}
runtime = substream->runtime;
snd_pcm_stream_lock_irqsave(substream, flags);
if (!snd_pcm_running(substream) || snd_pcm_update_hw_ptr0(substream, 1) < 0) {
goto _e... |
CVE-2016-9806 | linux | https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux | net/netlink/af_netlink.c | netlink_dump | static int netlink_dump(struct sock *sk) {
struct netlink_sock *nlk = nlk_sk(sk);
struct netlink_callback *cb;
struct sk_buff *skb = NULL;
struct nlmsghdr *nlh;
int len, err = -ENOBUFS;
int alloc_size;
mutex_lock(nlk->cb_mutex);
if (!nlk->cb_running) {
err = -EVAL;
goto e... | static int netlink_dump(struct sock *sk) {
struct netlink_sock *nlk = nlk_sk(sk);
struct netlink_callback *cb;
struct sk_buff *skb = NULL;
struct nlmsghdr *nlh;
struct module *module;
int len, err = -ENOBUFS;
int alloc_size;
mutex_lock(nlk->cb_mutex);
if (!nlk->cb_running) {
... | static int netlink_dump(struct sock *sk) {
struct netlink_sock *nlk = nlk_sk(sk);
struct netlink_callback *cb;
struct sk_buff *skb = NULL;
struct nlmsghdr *nlh;
int len, err = -ENOBUFS;
int alloc_min_size;
int alloc_size;
mutex_lock(nlk->cb_mutex);
if (!nlk->cb_running) {
err... | static int netlink_dump(struct sock *sk) {
struct netlink_sock *nlk = nlk_sk(sk);
struct netlink_callback *cb;
struct sk_buff *skb = NULL;
struct nlmsghdr *nlh;
struct module *module;
int len, err = -ENOBUFS;
int alloc_min_size;
int alloc_size;
mutex_lock(nlk->cb_mutex);
if (!nlk... | static int netlink_dump(struct sock *sk) {
struct netlink_sock *nlk = nlk_sk(sk);
struct nlmsghdr *nlh;
int len, err = -ENOBUFS;
cb = &nlk->cb;
if (!netlink_rx_is_mmaped(sk) && atomic_read(&sk->sk_rmem_alloc) >= sk->sk_rcvbuf) {
goto errout_skb;
}
skb = netlink_alloc_skb(sk, alloc_si... | static int netlink_dump(struct sock *sk) {
struct netlink_sock *nlk = nlk_sk(sk);
struct nlmsghdr *nlh;
struct module *module;
int len, err = -ENOBUFS;
cb = &nlk->cb;
if (!netlink_rx_is_mmaped(sk) && atomic_read(&sk->sk_rmem_alloc) >= sk->sk_rcvbuf) {
goto errout_skb;
}
skb = net... | static int netlink_dump(struct sock *sk) {
struct netlink_sock *nlk = nlk_sk(sk);
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
struct nlmsghdr *nlh;
int len, err = -ENOBUFS;
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
if (!netlink_rx_is_mmaped(sk) && atomic_read(&sk->sk_rmem_alloc) >= sk->sk_... | static int netlink_dump(struct sock *sk) {
struct netlink_sock *nlk = nlk_sk(sk);
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
struct nlmsghdr *nlh;
struct module *module;
int len, err = -ENOBUFS;
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
if (!netlink_rx_is_mmaped(sk) && atomic_read(&sk... | static int netlink_dump(struct sock *sk) {
struct netlink_sock *nlk = nlk_sk(sk);
struct nlmsghdr *nlh;
+ struct module *module;
int len, err = -ENOBUFS;
cb = &nlk->cb;
if (!netlink_rx_is_mmaped(sk) && atomic_read(&sk->sk_rmem_alloc) >= sk->sk_rcvbuf) {
goto errout_skb;
}
... |
CVE-2017-0627 | linux | https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux | drivers/media/video/uvc/uvc_ctrl.c | uvc_ctrl_add_mapping | int uvc_ctrl_add_mapping(struct uvc_video_chain *chain, const struct uvc_control_mapping *mapping) {
struct uvc_device *dev = chain->dev;
struct uvc_control_mapping *map;
struct uvc_entity *entity;
struct uvc_control *ctrl;
int found = 0;
int ret;
if (mapping->id & ~V4L2_CTRL_ID_MASK) {
... | int uvc_ctrl_add_mapping(struct uvc_video_chain *chain, const struct uvc_control_mapping *mapping) {
struct uvc_device *dev = chain->dev;
struct uvc_control_mapping *map;
struct uvc_entity *entity;
struct uvc_control *ctrl;
int found = 0;
int ret;
if (mapping->id & ~V4L2_CTRL_ID_MASK) {
... | int uvc_ctrl_add_mapping(struct uvc_video_chain *chain, const struct uvc_control_mapping *mapping) {
struct uvc_device *dev = chain->dev;
struct uvc_control_mapping *map;
struct uvc_entity *entity;
struct uvc_control *ctrl;
int found = 0;
int ret;
if (mapping->id & ~V4L2_CTRL_ID_MASK) {
... | int uvc_ctrl_add_mapping(struct uvc_video_chain *chain, const struct uvc_control_mapping *mapping) {
struct uvc_device *dev = chain->dev;
struct uvc_control_mapping *map;
struct uvc_entity *entity;
struct uvc_control *ctrl;
int found = 0;
int ret;
if (mapping->id & ~V4L2_CTRL_ID_MASK) {
... | int uvc_ctrl_add_mapping(struct uvc_video_chain *chain, const struct uvc_control_mapping *mapping) {
if (ret < 0) {
goto done;
}
list_for_each_entry(map, &ctrl->info.mappings, list) {
}
ret = __uvc_ctrl_add_mapping(dev, ctrl, mapping);
if (ret < 0) {
atomic_dec(&dev->nmappings);
... | int uvc_ctrl_add_mapping(struct uvc_video_chain *chain, const struct uvc_control_mapping *mapping) {
if (ret < 0) {
goto done;
}
if (mapping->size > 32 || mapping->offset + mapping->size > ctrl->info.size * 8) {
ret = -EVAL;
goto done;
}
list_for_each_entry(map, &ctrl->info.m... | int uvc_ctrl_add_mapping(struct uvc_video_chain *chain, const struct uvc_control_mapping *mapping) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
if (ret < 0) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
goto done;
}
list_for_each_entry(map, &ctrl->info.mappings, list) {
/* PLACEHOLD... | int uvc_ctrl_add_mapping(struct uvc_video_chain *chain, const struct uvc_control_mapping *mapping) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
if (ret < 0) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
goto done;
}
if (mapping->size > 32 || mapping->offset + mapping->size > ctrl->info.... | int uvc_ctrl_add_mapping(struct uvc_video_chain *chain, const struct uvc_control_mapping *mapping) {
if (ret < 0) {
+ goto done;
+ }
+ if (mapping->size > 32 || mapping->offset + mapping->size > ctrl->info.size * 8) {
+ ret = -EVAL;
goto done;
}
list_for_each_entry(map, &ctr... |
CVE-2017-0750 | linux | https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux | fs/f2fs/super.c | sanity_check_raw_super | static int sanity_check_raw_super(struct super_block *sb, struct f2fs_super_block *raw_super) {
unsigned int blocksize;
if (F2FS_SUPER_MAGIC != le32_to_cpu(raw_super->magic)) {
f2fs_msg(sb, KERN_FO, "Magic Mismatch, valid(0x%x) - read(0x%x)", F2FS_SUPER_MAGIC, le32_to_cpu(raw_super->magic));
ret... | static int sanity_check_raw_super(struct super_block *sb, struct f2fs_super_block *raw_super) {
unsigned int blocksize;
if (F2FS_SUPER_MAGIC != le32_to_cpu(raw_super->magic)) {
f2fs_msg(sb, KERN_FO, "Magic Mismatch, valid(0x%x) - read(0x%x)", F2FS_SUPER_MAGIC, le32_to_cpu(raw_super->magic));
ret... | static int sanity_check_raw_super(struct super_block *sb, struct f2fs_super_block *raw_super) {
unsigned int blocksize;
if (F2FS_SUPER_MAGIC != le32_to_cpu(raw_super->magic)) {
f2fs_msg(sb, KERN_FO, "Magic Mismatch, valid(0x%x) - read(0x%x)", F2FS_SUPER_MAGIC, le32_to_cpu(raw_super->magic));
ret... | static int sanity_check_raw_super(struct super_block *sb, struct f2fs_super_block *raw_super) {
unsigned int blocksize;
if (F2FS_SUPER_MAGIC != le32_to_cpu(raw_super->magic)) {
f2fs_msg(sb, KERN_FO, "Magic Mismatch, valid(0x%x) - read(0x%x)", F2FS_SUPER_MAGIC, le32_to_cpu(raw_super->magic));
ret... | static int sanity_check_raw_super(struct super_block *sb, struct f2fs_super_block *raw_super) {
if (blocksize != F2FS_BLKSIZE) {
return 1;
}
if (le32_to_cpu(raw_super->log_sectorsize) > F2FS_MAX_LOG_SECTOR_SIZE || le32_to_cpu(raw_super->log_sectorsize) < F2FS_M_LOG_SECTOR_SIZE) {
return 1;
... | static int sanity_check_raw_super(struct super_block *sb, struct f2fs_super_block *raw_super) {
if (blocksize != F2FS_BLKSIZE) {
return 1;
}
if (le32_to_cpu(raw_super->log_blocks_per_seg) != 9) {
f2fs_msg(sb, KERN_FO, "Invalid log blocks per segment (%u)\n", le32_to_cpu(raw_super->log_blocks... | static int sanity_check_raw_super(struct super_block *sb, struct f2fs_super_block *raw_super) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
if (blocksize != F2FS_BLKSIZE) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
return 1;
}
if (le32_to_cpu(raw_super->log_sectorsize) > F2FS_MAX_LOG_S... | static int sanity_check_raw_super(struct super_block *sb, struct f2fs_super_block *raw_super) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
if (blocksize != F2FS_BLKSIZE) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
return 1;
}
if (le32_to_cpu(raw_super->log_blocks_per_seg) != 9) {
... | static int sanity_check_raw_super(struct super_block *sb, struct f2fs_super_block *raw_super) {
if (blocksize != F2FS_BLKSIZE) {
+ return 1;
+ }
+ if (le32_to_cpu(raw_super->log_blocks_per_seg) != 9) {
+ f2fs_msg(sb, KERN_FO, "Invalid log blocks per segment (%u)\n", le32_to_cpu(raw_super->log_... |
CVE-2017-0861 | linux | https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux | sound/core/pcm.c | snd_pcm_control_ioctl | static int snd_pcm_control_ioctl(struct snd_card *card, struct snd_ctl_file *control, unsigned int cmd, unsigned long arg) {
switch (cmd) {
case SNDRV_CTL_IOCTL_PCM_NEXT_DEVICE: {
int device;
if (get_user(device, (int *)arg)) {
return -EFAULT;
}
mutex_lock(®ister_m... | static int snd_pcm_control_ioctl(struct snd_card *card, struct snd_ctl_file *control, unsigned int cmd, unsigned long arg) {
switch (cmd) {
case SNDRV_CTL_IOCTL_PCM_NEXT_DEVICE: {
int device;
if (get_user(device, (int *)arg)) {
return -EFAULT;
}
mutex_lock(®ister_m... | static int snd_pcm_control_ioctl(struct snd_card *card, struct snd_ctl_file *control, unsigned int cmd, unsigned long arg) {
switch (cmd) {
case SNDRV_CTL_IOCTL_PCM_NEXT_DEVICE: {
int device;
if (get_user(device, (int *)arg)) {
return -EFAULT;
}
mutex_lock(®ister_m... | static int snd_pcm_control_ioctl(struct snd_card *card, struct snd_ctl_file *control, unsigned int cmd, unsigned long arg) {
switch (cmd) {
case SNDRV_CTL_IOCTL_PCM_NEXT_DEVICE: {
int device;
if (get_user(device, (int *)arg)) {
return -EFAULT;
}
mutex_lock(®ister_m... | static int snd_pcm_control_ioctl(struct snd_card *card, struct snd_ctl_file *control, unsigned int cmd, unsigned long arg) {
switch (cmd) {
case SNDRV_CTL_IOCTL_PCM_FO: {
info = (struct snd_pcm_info *)arg;
if (get_user(device, &info->device)) {
return -EFAULT;
}
pcm =... | static int snd_pcm_control_ioctl(struct snd_card *card, struct snd_ctl_file *control, unsigned int cmd, unsigned long arg) {
switch (cmd) {
case SNDRV_CTL_IOCTL_PCM_FO: {
info = (struct snd_pcm_info *)arg;
if (get_user(device, &info->device)) {
return -EFAULT;
}
pcm =... | static int snd_pcm_control_ioctl(struct snd_card *card, struct snd_ctl_file *control, unsigned int cmd, unsigned long arg) {
switch (cmd) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
case SNDRV_CTL_IOCTL_PCM_FO: {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
info = (struct snd_pcm_info *)arg... | static int snd_pcm_control_ioctl(struct snd_card *card, struct snd_ctl_file *control, unsigned int cmd, unsigned long arg) {
switch (cmd) {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
case SNDRV_CTL_IOCTL_PCM_FO: {
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
info = (struct snd_pcm_info *)arg... | static int snd_pcm_control_ioctl(struct snd_card *card, struct snd_ctl_file *control, unsigned int cmd, unsigned long arg) {
switch (cmd) {
case SNDRV_CTL_IOCTL_PCM_FO: {
info = (struct snd_pcm_info *)arg;
if (get_user(device, &info->device)) {
return -EFAULT;
}
... |
CVE-2017-1000 | linux | https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux | net/ipv4/ip_output.c | __ip_append_data | static int __ip_append_data(struct sock *sk, struct flowi4 *fl4, struct sk_buff_head *queue, struct inet_cork *cork, struct page_frag *pfrag, int getfrag(void *from, char *to, int offset, int len,
int odd, struct sk_buff *skb), void *from, int length, int transhdrlen, unsigned int flags) {
... | static int __ip_append_data(struct sock *sk, struct flowi4 *fl4, struct sk_buff_head *queue, struct inet_cork *cork, struct page_frag *pfrag, int getfrag(void *from, char *to, int offset, int len,
int odd, struct sk_buff *skb), void *from, int length, int transhdrlen, unsigned int flags) {
... | static int __ip_append_data(struct sock *sk, struct flowi4 *fl4, struct sk_buff_head *queue, struct inet_cork *cork, struct page_frag *pfrag, int getfrag(void *from, char *to, int offset, int len,
int odd, struct sk_buff *skb), void *from, int length, int transhdrlen, unsigned int flags) {
... | static int __ip_append_data(struct sock *sk, struct flowi4 *fl4, struct sk_buff_head *queue, struct inet_cork *cork, struct page_frag *pfrag, int getfrag(void *from, char *to, int offset, int len,
int odd, struct sk_buff *skb), void *from, int length, int transhdrlen, unsigned int flags) {
... | static int __ip_append_data(struct sock *sk, struct flowi4 *fl4, struct sk_buff_head *queue, struct inet_cork *cork, struct page_frag *pfrag, int getfrag(void *from, char *to, int offset, int len,
int odd, struct sk_buff *skb), void *from, int length, int transhdrlen, unsigned int flags) {
... | static int __ip_append_data(struct sock *sk, struct flowi4 *fl4, struct sk_buff_head *queue, struct inet_cork *cork, struct page_frag *pfrag, int getfrag(void *from, char *to, int offset, int len,
int odd, struct sk_buff *skb), void *from, int length, int transhdrlen, unsigned int flags) {
... | static int __ip_append_data(struct sock *sk, struct flowi4 *fl4, struct sk_buff_head *queue, struct inet_cork *cork, struct page_frag *pfrag, int getfrag(void *from, char *to, int offset, int len,
int odd, struct sk_buff *skb), void *from, int length, int transhdrlen, unsigned int flags) {
... | static int __ip_append_data(struct sock *sk, struct flowi4 *fl4, struct sk_buff_head *queue, struct inet_cork *cork, struct page_frag *pfrag, int getfrag(void *from, char *to, int offset, int len,
int odd, struct sk_buff *skb), void *from, int length, int transhdrlen, unsigned int flags) {
... | static int __ip_append_data(struct sock *sk, struct flowi4 *fl4, struct sk_buff_head *queue, struct inet_cork *cork, struct page_frag *pfrag, int getfrag(void *from, char *to, int offset, int len,
int odd, struct sk_buff *skb), void *from, int length, int transhdrlen, unsigned int flags) {... |
CVE-2017-1000 | linux | https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux | net/ipv4/udp.c | udp_send_skb | static int udp_send_skb(struct sk_buff *skb, struct flowi4 *fl4) {
struct sock *sk = skb->sk;
struct inet_sock *inet = inet_sk(sk);
struct udphdr *uh;
int err = 0;
int is_udplite = IS_UDPLITE(sk);
int offset = skb_transport_offset(skb);
int len = skb->len - offset;
__wsum csum = 0;
u... | static int udp_send_skb(struct sk_buff *skb, struct flowi4 *fl4) {
struct sock *sk = skb->sk;
struct inet_sock *inet = inet_sk(sk);
struct udphdr *uh;
int err = 0;
int is_udplite = IS_UDPLITE(sk);
int offset = skb_transport_offset(skb);
int len = skb->len - offset;
__wsum csum = 0;
u... | static int udp_send_skb(struct sk_buff *skb, struct flowi4 *fl4) {
struct sock *sk = skb->sk;
struct inet_sock *inet = inet_sk(sk);
struct udphdr *uh;
int err = 0;
int is_udplite = IS_UDPLITE(sk);
int offset = skb_transport_offset(skb);
int len = skb->len - offset;
__wsum csum = 0;
u... | static int udp_send_skb(struct sk_buff *skb, struct flowi4 *fl4) {
struct sock *sk = skb->sk;
struct inet_sock *inet = inet_sk(sk);
struct udphdr *uh;
int err = 0;
int is_udplite = IS_UDPLITE(sk);
int offset = skb_transport_offset(skb);
int len = skb->len - offset;
__wsum csum = 0;
u... | static int udp_send_skb(struct sk_buff *skb, struct flowi4 *fl4) {
struct sock *sk = skb->sk;
struct inet_sock *inet = inet_sk(sk);
int is_udplite = IS_UDPLITE(sk);
int offset = skb_transport_offset(skb);
uh = udp_hdr(skb);
if (is_udplite) {
} else if (sk->sk_no_check_tx) {
skb->ip_s... | static int udp_send_skb(struct sk_buff *skb, struct flowi4 *fl4) {
struct sock *sk = skb->sk;
struct inet_sock *inet = inet_sk(sk);
int is_udplite = IS_UDPLITE(sk);
int offset = skb_transport_offset(skb);
uh = udp_hdr(skb);
if (is_udplite) {
} else if (sk->sk_no_check_tx && !skb_is_gso(skb))... | static int udp_send_skb(struct sk_buff *skb, struct flowi4 *fl4) {
struct sock *sk = skb->sk;
struct inet_sock *inet = inet_sk(sk);
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
int is_udplite = IS_UDPLITE(sk);
int offset = skb_transport_offset(skb);
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */... | static int udp_send_skb(struct sk_buff *skb, struct flowi4 *fl4) {
struct sock *sk = skb->sk;
struct inet_sock *inet = inet_sk(sk);
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */
int is_udplite = IS_UDPLITE(sk);
int offset = skb_transport_offset(skb);
/* PLACEHOLDER: DO NOT DELETE THIS COMMENT */... | static int udp_send_skb(struct sk_buff *skb, struct flowi4 *fl4) {
struct sock *sk = skb->sk;
struct inet_sock *inet = inet_sk(sk);
int is_udplite = IS_UDPLITE(sk);
int offset = skb_transport_offset(skb);
uh = udp_hdr(skb);
if (is_udplite) {
- } else if (sk->sk_no_check_tx) {
+ } el... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.