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-2020-8648
linux
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux
drivers/tty/vt/selection.c
paste_selection
int paste_selection(struct tty_struct *tty) { struct vc_data *vc = tty->driver_data; int pasted = 0; unsigned int count; struct tty_ldisc *ld; DECLARE_WAITQUEUE(wait, current); console_lock(); poke_blanked_console(); console_unlock(); ld = tty_ldisc_ref_wait(tty); tty_buffer_lock...
int paste_selection(struct tty_struct *tty) { struct vc_data *vc = tty->driver_data; int pasted = 0; unsigned int count; struct tty_ldisc *ld; DECLARE_WAITQUEUE(wait, current); console_lock(); poke_blanked_console(); console_unlock(); ld = tty_ldisc_ref_wait(tty); tty_buffer_lock...
int paste_selection(struct tty_struct *tty) { struct vc_data *vc = tty->driver_data; int pasted = 0; unsigned int count; struct tty_ldisc *ld; DECLARE_WAITQUEUE(wait, current); int ret = 0; console_lock(); poke_blanked_console(); console_unlock(); ld = tty_ldisc_ref_wait(tty); ...
int paste_selection(struct tty_struct *tty) { struct vc_data *vc = tty->driver_data; int pasted = 0; unsigned int count; struct tty_ldisc *ld; DECLARE_WAITQUEUE(wait, current); int ret = 0; console_lock(); poke_blanked_console(); console_unlock(); ld = tty_ldisc_ref_wait(tty); ...
int paste_selection(struct tty_struct *tty) { add_wait_queue(&vc->paste_wait, &wait); while (sel_buffer && sel_buffer_lth > pasted) { set_current_state(TASK_TERRUPTIBLE); if (test_bit(TTY_THROTTLED, &tty->flags)) { schedule(); continue; } __set_current_sta...
int paste_selection(struct tty_struct *tty) { add_wait_queue(&vc->paste_wait, &wait); mutex_lock(&sel_lock); while (sel_buffer && sel_buffer_lth > pasted) { set_current_state(TASK_TERRUPTIBLE); if (test_bit(TTY_THROTTLED, &tty->flags)) { schedule(); continue; ...
int paste_selection(struct tty_struct *tty) { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ add_wait_queue(&vc->paste_wait, &wait); while (sel_buffer && sel_buffer_lth > pasted) { set_current_state(TASK_TERRUPTIBLE); if (signal_pending(current)) { ret = -ETR; break; ...
int paste_selection(struct tty_struct *tty) { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ add_wait_queue(&vc->paste_wait, &wait); mutex_lock(&sel_lock); while (sel_buffer && sel_buffer_lth > pasted) { set_current_state(TASK_TERRUPTIBLE); if (signal_pending(current)) { ret =...
int paste_selection(struct tty_struct *tty) { add_wait_queue(&vc->paste_wait, &wait); + mutex_lock(&sel_lock); while (sel_buffer && sel_buffer_lth > pasted) { set_current_state(TASK_TERRUPTIBLE); if (test_bit(TTY_THROTTLED, &tty->flags)) { schedule(); continue; ...
CVE-2020-8648
linux
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux
drivers/tty/vt/selection.c
set_selection
int set_selection(const struct tiocl_selection *sel, struct tty_struct *tty) { struct vc_data *vc = vc_cons[fg_console].d; int sel_mode, new_sel_start, new_sel_end, spc; char *bp, *obp; int i, ps, pe, multiplier; u16 c; int mode; poke_blanked_console(); { unsigned short xs, ys, x...
int set_selection(const struct tiocl_selection *sel, struct tty_struct *tty) { struct vc_data *vc = vc_cons[fg_console].d; int sel_mode, new_sel_start, new_sel_end, spc; char *bp, *obp; int i, ps, pe, multiplier; u16 c; int mode, ret = 0; poke_blanked_console(); { unsigned short ...
int set_selection(const struct tiocl_selection *sel, struct tty_struct *tty) { struct vc_data *vc = vc_cons[fg_console].d; int sel_mode, new_sel_start, new_sel_end, spc; char *bp, *obp; int i, ps, pe, multiplier; u16 c; int mode; poke_blanked_console(); { unsigned short xs, ys, x...
int set_selection(const struct tiocl_selection *sel, struct tty_struct *tty) { struct vc_data *vc = vc_cons[fg_console].d; int sel_mode, new_sel_start, new_sel_end, spc; char *bp, *obp; int i, ps, pe, multiplier; u16 c; int mode, ret = 0; poke_blanked_console(); { unsigned short ...
int set_selection(const struct tiocl_selection *sel, struct tty_struct *tty) { struct vc_data *vc = vc_cons[fg_console].d; u16 c; int mode; poke_blanked_console(); if (ps > pe) { pe = tmp; } switch (sel_mode) { case TIOCL_SELPOTER: highlight_pointer(pe); return 0;...
int set_selection(const struct tiocl_selection *sel, struct tty_struct *tty) { struct vc_data *vc = vc_cons[fg_console].d; u16 c; int mode, ret = 0; poke_blanked_console(); if (ps > pe) { pe = tmp; } mutex_lock(&sel_lock); switch (sel_mode) { case TIOCL_SELPOTER: high...
int set_selection(const struct tiocl_selection *sel, struct tty_struct *tty) { struct vc_data *vc = vc_cons[fg_console].d; /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ u16 c; int mode; poke_blanked_console(); /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ if (ps > pe) { /* PLACEHOLDER: D...
int set_selection(const struct tiocl_selection *sel, struct tty_struct *tty) { struct vc_data *vc = vc_cons[fg_console].d; /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ u16 c; int mode, ret = 0; poke_blanked_console(); /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ if (ps > pe) { /* PLACE...
int set_selection(const struct tiocl_selection *sel, struct tty_struct *tty) { struct vc_data *vc = vc_cons[fg_console].d; u16 c; - int mode; + int mode, ret = 0; poke_blanked_console(); if (ps > pe) { pe = tmp; } + mutex_lock(&sel_lock); switch (sel_mode) { case TI...
CVE-2020-8649
linux
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux
drivers/video/console/vgacon.c
vgacon_resize
static int vgacon_resize(struct vc_data *c, unsigned int width, unsigned int height, unsigned int user) { if (width % 2 || width > screen_info.orig_video_cols || height > (screen_info.orig_video_lines * vga_default_font_height)/ c->vc_font.height) { return (user) ? 0 : -EVAL; } if (CON_IS_VISIBLE(c)...
static int vgacon_resize(struct vc_data *c, unsigned int width, unsigned int height, unsigned int user) { if ((width << 1) * height > vga_vram_size) { return -EVAL; } if (width % 2 || width > screen_info.orig_video_cols || height > (screen_info.orig_video_lines * vga_default_font_height)/ c->vc_font...
static int vgacon_resize(struct vc_data *c, unsigned int width, unsigned int height, unsigned int user) { if (width % 2 || width > screen_info.orig_video_cols || height > (screen_info.orig_video_lines * vga_default_font_height)/ c->vc_font.height) { return (user) ? 0 : -EVAL; } if (CON_IS_VISIBLE(c)...
static int vgacon_resize(struct vc_data *c, unsigned int width, unsigned int height, unsigned int user) { if ((width << 1) * height > vga_vram_size) { return -EVAL; } if (width % 2 || width > screen_info.orig_video_cols || height > (screen_info.orig_video_lines * vga_default_font_height)/ c->vc_font...
static int vgacon_resize(struct vc_data *c, unsigned int width, unsigned int height, unsigned int user) { if (width % 2 || width > screen_info.orig_video_cols || height > (screen_info.orig_video_lines * vga_default_font_height)/ c->vc_font.height) { return (user) ? 0 : -EVAL; } if (CON_IS_VISIBLE(c)...
static int vgacon_resize(struct vc_data *c, unsigned int width, unsigned int height, unsigned int user) { if ((width << 1) * height > vga_vram_size) { return -EVAL; } if (width % 2 || width > screen_info.orig_video_cols || height > (screen_info.orig_video_lines * vga_default_font_height)/ c->vc_font...
static int vgacon_resize(struct vc_data *c, unsigned int width, unsigned int height, unsigned int user) { if (width % 2 || width > screen_info.orig_video_cols || height > (screen_info.orig_video_lines * vga_default_font_height)/ c->vc_font.height) { return (user) ? 0 : -EVAL; } if (CON_IS_VISIBLE(c)...
static int vgacon_resize(struct vc_data *c, unsigned int width, unsigned int height, unsigned int user) { if ((width << 1) * height > vga_vram_size) { return -EVAL; } if (width % 2 || width > screen_info.orig_video_cols || height > (screen_info.orig_video_lines * vga_default_font_height)/ c->vc_font...
static int vgacon_resize(struct vc_data *c, unsigned int width, unsigned int height, unsigned int user) { + if ((width << 1) * height > vga_vram_size) { + return -EVAL; + } if (width % 2 || width > screen_info.orig_video_cols || height > (screen_info.orig_video_lines * vga_default_font_height)/ c->vc...
CVE-2020-8694
linux
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux
drivers/powercap/powercap_sys.c
create_power_zone_common_attributes
static void create_power_zone_common_attributes( struct powercap_zone *power_zone) { int count = 0; power_zone->zone_dev_attrs[count++] = &dev_attr_name.attr; if (power_zone->ops->get_max_energy_range_uj) { power_zone->zone_dev_attrs[count++] = &dev_attr_max_energy_range_uj.attr; } if (power...
static void create_power_zone_common_attributes( struct powercap_zone *power_zone) { int count = 0; power_zone->zone_dev_attrs[count++] = &dev_attr_name.attr; if (power_zone->ops->get_max_energy_range_uj) { power_zone->zone_dev_attrs[count++] = &dev_attr_max_energy_range_uj.attr; } if (power...
static void create_power_zone_common_attributes( struct powercap_zone *power_zone) { int count = 0; power_zone->zone_dev_attrs[count++] = &dev_attr_name.attr; if (power_zone->ops->get_max_energy_range_uj) { power_zone->zone_dev_attrs[count++] = &dev_attr_max_energy_range_uj.attr; } if (power...
static void create_power_zone_common_attributes( struct powercap_zone *power_zone) { int count = 0; power_zone->zone_dev_attrs[count++] = &dev_attr_name.attr; if (power_zone->ops->get_max_energy_range_uj) { power_zone->zone_dev_attrs[count++] = &dev_attr_max_energy_range_uj.attr; } if (power...
static void create_power_zone_common_attributes( struct powercap_zone *power_zone) { if (power_zone->ops->get_energy_uj) { if (power_zone->ops->reset_energy_uj) { dev_attr_energy_uj.attr.mode = S_IWUSR | S_IRUGO; } else { dev_attr_energy_uj.attr.mode = S_IRUGO; } ...
static void create_power_zone_common_attributes( struct powercap_zone *power_zone) { if (power_zone->ops->get_energy_uj) { if (power_zone->ops->reset_energy_uj) { dev_attr_energy_uj.attr.mode = S_IWUSR | S_IRUSR; } else { dev_attr_energy_uj.attr.mode = S_IRUSR; } ...
static void create_power_zone_common_attributes( struct powercap_zone *power_zone) { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ if (power_zone->ops->get_energy_uj) { if (power_zone->ops->reset_energy_uj) { dev_attr_energy_uj.attr.mode = S_IWUSR | S_IRUGO; } else { dev_...
static void create_power_zone_common_attributes( struct powercap_zone *power_zone) { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ if (power_zone->ops->get_energy_uj) { if (power_zone->ops->reset_energy_uj) { dev_attr_energy_uj.attr.mode = S_IWUSR | S_IRUSR; } else { dev_...
static void create_power_zone_common_attributes( struct powercap_zone *power_zone) { if (power_zone->ops->get_energy_uj) { if (power_zone->ops->reset_energy_uj) { - dev_attr_energy_uj.attr.mode = S_IWUSR | S_IRUGO; + dev_attr_energy_uj.attr.mode = S_IWUSR | S_IRUSR; } else ...
CVE-2020-8835
linux
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux
kernel/bpf/verifier.c
reg_set_min_max
static void reg_set_min_max(struct bpf_reg_state *true_reg, struct bpf_reg_state *false_reg, u64 val, u8 opcode, bool is_jmp32) { s64 sval; if (__is_pointer_value(false, false_reg)) { return; } val = is_jmp32 ? (u32)val : val; sval = is_jmp32 ? (s64)(s32)val : (s64)val; switch (opcode) {...
static void reg_set_min_max(struct bpf_reg_state *true_reg, struct bpf_reg_state *false_reg, u64 val, u8 opcode, bool is_jmp32) { s64 sval; if (__is_pointer_value(false, false_reg)) { return; } val = is_jmp32 ? (u32)val : val; sval = is_jmp32 ? (s64)(s32)val : (s64)val; switch (opcode) {...
static void reg_set_min_max(struct bpf_reg_state *true_reg, struct bpf_reg_state *false_reg, u64 val, u8 opcode, bool is_jmp32) { s64 sval; if (__is_pointer_value(false, false_reg)) { return; } val = is_jmp32 ? (u32)val : val; sval = is_jmp32 ? (s64)(s32)val : (s64)val; switch (opcode) {...
static void reg_set_min_max(struct bpf_reg_state *true_reg, struct bpf_reg_state *false_reg, u64 val, u8 opcode, bool is_jmp32) { s64 sval; if (__is_pointer_value(false, false_reg)) { return; } val = is_jmp32 ? (u32)val : val; sval = is_jmp32 ? (s64)(s32)val : (s64)val; switch (opcode) {...
static void reg_set_min_max(struct bpf_reg_state *true_reg, struct bpf_reg_state *false_reg, u64 val, u8 opcode, bool is_jmp32) { if (__is_pointer_value(false, false_reg)) { return; } val = is_jmp32 ? (u32)val : val; sval = is_jmp32 ? (s64)(s32)val : (s64)val; switch (opcode) { case BPF_...
static void reg_set_min_max(struct bpf_reg_state *true_reg, struct bpf_reg_state *false_reg, u64 val, u8 opcode, bool is_jmp32) { if (__is_pointer_value(false, false_reg)) { return; } val = is_jmp32 ? (u32)val : val; sval = is_jmp32 ? (s64)(s32)val : (s64)val; switch (opcode) { case BPF_...
static void reg_set_min_max(struct bpf_reg_state *true_reg, struct bpf_reg_state *false_reg, u64 val, u8 opcode, bool is_jmp32) { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ if (__is_pointer_value(false, false_reg)) { return; } val = is_jmp32 ? (u32)val : val; sval = is_jmp32 ? (s64)(s32)v...
static void reg_set_min_max(struct bpf_reg_state *true_reg, struct bpf_reg_state *false_reg, u64 val, u8 opcode, bool is_jmp32) { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ if (__is_pointer_value(false, false_reg)) { return; } val = is_jmp32 ? (u32)val : val; sval = is_jmp32 ? (s64)(s32)v...
static void reg_set_min_max(struct bpf_reg_state *true_reg, struct bpf_reg_state *false_reg, u64 val, u8 opcode, bool is_jmp32) { if (__is_pointer_value(false, false_reg)) { return; } val = is_jmp32 ? (u32)val : val; sval = is_jmp32 ? (s64)(s32)val : (s64)val; switch (opcode) { c...
CVE-2020-8835
linux
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux
kernel/bpf/verifier.c
reg_set_min_max_inv
static void reg_set_min_max_inv(struct bpf_reg_state *true_reg, struct bpf_reg_state *false_reg, u64 val, u8 opcode, bool is_jmp32) { s64 sval; if (__is_pointer_value(false, false_reg)) { return; } val = is_jmp32 ? (u32)val : val; sval = is_jmp32 ? (s64)(s32)val : (s64)val; switch (opcod...
static void reg_set_min_max_inv(struct bpf_reg_state *true_reg, struct bpf_reg_state *false_reg, u64 val, u8 opcode, bool is_jmp32) { s64 sval; if (__is_pointer_value(false, false_reg)) { return; } val = is_jmp32 ? (u32)val : val; sval = is_jmp32 ? (s64)(s32)val : (s64)val; switch (opcod...
static void reg_set_min_max_inv(struct bpf_reg_state *true_reg, struct bpf_reg_state *false_reg, u64 val, u8 opcode, bool is_jmp32) { s64 sval; if (__is_pointer_value(false, false_reg)) { return; } val = is_jmp32 ? (u32)val : val; sval = is_jmp32 ? (s64)(s32)val : (s64)val; switch (opcod...
static void reg_set_min_max_inv(struct bpf_reg_state *true_reg, struct bpf_reg_state *false_reg, u64 val, u8 opcode, bool is_jmp32) { s64 sval; if (__is_pointer_value(false, false_reg)) { return; } val = is_jmp32 ? (u32)val : val; sval = is_jmp32 ? (s64)(s32)val : (s64)val; switch (opcod...
static void reg_set_min_max_inv(struct bpf_reg_state *true_reg, struct bpf_reg_state *false_reg, u64 val, u8 opcode, bool is_jmp32) { if (__is_pointer_value(false, false_reg)) { return; } val = is_jmp32 ? (u32)val : val; sval = is_jmp32 ? (s64)(s32)val : (s64)val; switch (opcode) { case ...
static void reg_set_min_max_inv(struct bpf_reg_state *true_reg, struct bpf_reg_state *false_reg, u64 val, u8 opcode, bool is_jmp32) { if (__is_pointer_value(false, false_reg)) { return; } val = is_jmp32 ? (u32)val : val; sval = is_jmp32 ? (s64)(s32)val : (s64)val; switch (opcode) { case ...
static void reg_set_min_max_inv(struct bpf_reg_state *true_reg, struct bpf_reg_state *false_reg, u64 val, u8 opcode, bool is_jmp32) { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ if (__is_pointer_value(false, false_reg)) { return; } val = is_jmp32 ? (u32)val : val; sval = is_jmp32 ? (s64)(s...
static void reg_set_min_max_inv(struct bpf_reg_state *true_reg, struct bpf_reg_state *false_reg, u64 val, u8 opcode, bool is_jmp32) { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ if (__is_pointer_value(false, false_reg)) { return; } val = is_jmp32 ? (u32)val : val; sval = is_jmp32 ? (s64)(s...
static void reg_set_min_max_inv(struct bpf_reg_state *true_reg, struct bpf_reg_state *false_reg, u64 val, u8 opcode, bool is_jmp32) { if (__is_pointer_value(false, false_reg)) { return; } val = is_jmp32 ? (u32)val : val; sval = is_jmp32 ? (s64)(s32)val : (s64)val; switch (opcode) { ...
CVE-2020-8992
linux
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux
fs/ext4/block_validity.c
ext4_protect_reserved_inode
static int ext4_protect_reserved_inode(struct super_block *sb, struct ext4_system_blocks *system_blks, u32 ino) { struct inode *inode; struct ext4_sb_info *sbi = EXT4_SB(sb); struct ext4_map_blocks map; u32 i = 0, num; int err = 0, n; if ((ino < EXT4_ROOT_O) || (ino > le32_to_cpu(sbi->s_es->s_in...
static int ext4_protect_reserved_inode(struct super_block *sb, struct ext4_system_blocks *system_blks, u32 ino) { struct inode *inode; struct ext4_sb_info *sbi = EXT4_SB(sb); struct ext4_map_blocks map; u32 i = 0, num; int err = 0, n; if ((ino < EXT4_ROOT_O) || (ino > le32_to_cpu(sbi->s_es->s_in...
static int ext4_protect_reserved_inode(struct super_block *sb, struct ext4_system_blocks *system_blks, u32 ino) { struct inode *inode; struct ext4_sb_info *sbi = EXT4_SB(sb); struct ext4_map_blocks map; u32 i = 0, num; int err = 0, n; if ((ino < EXT4_ROOT_O) || (ino > le32_to_cpu(sbi->s_es->s_in...
static int ext4_protect_reserved_inode(struct super_block *sb, struct ext4_system_blocks *system_blks, u32 ino) { struct inode *inode; struct ext4_sb_info *sbi = EXT4_SB(sb); struct ext4_map_blocks map; u32 i = 0, num; int err = 0, n; if ((ino < EXT4_ROOT_O) || (ino > le32_to_cpu(sbi->s_es->s_in...
static int ext4_protect_reserved_inode(struct super_block *sb, struct ext4_system_blocks *system_blks, u32 ino) { while (i < num) { map.m_lblk = i; map.m_len = num - i; n = ext4_map_blocks(NULL, inode, &map, 0); if (n < 0) { err = n; break; } i...
static int ext4_protect_reserved_inode(struct super_block *sb, struct ext4_system_blocks *system_blks, u32 ino) { while (i < num) { cond_resched(); map.m_lblk = i; map.m_len = num - i; n = ext4_map_blocks(NULL, inode, &map, 0); if (n < 0) { err = n; br...
static int ext4_protect_reserved_inode(struct super_block *sb, struct ext4_system_blocks *system_blks, u32 ino) { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ while (i < num) { map.m_lblk = i; map.m_len = num - i; n = ext4_map_blocks(NULL, inode, &map, 0); if (n < 0) { ...
static int ext4_protect_reserved_inode(struct super_block *sb, struct ext4_system_blocks *system_blks, u32 ino) { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ while (i < num) { cond_resched(); map.m_lblk = i; map.m_len = num - i; n = ext4_map_blocks(NULL, inode, &map, 0); ...
static int ext4_protect_reserved_inode(struct super_block *sb, struct ext4_system_blocks *system_blks, u32 ino) { while (i < num) { + cond_resched(); map.m_lblk = i; map.m_len = num - i; n = ext4_map_blocks(NULL, inode, &map, 0); if (n < 0) { err = n; ...
CVE-2020-9383
linux
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux
drivers/block/floppy.c
set_fdc
static void set_fdc(int drive) { if (drive >= 0 && drive < N_DRIVE) { fdc = FDC(drive); current_drive = drive; } if (fdc != 1 && fdc != 0) { pr_info("bad fdc value\n"); return; } set_dor(fdc, ~0, 8); set_dor(1 - fdc, ~8, 0); if (FDCS->rawcmd == 2) { re...
static void set_fdc(int drive) { unsigned int new_fdc = fdc; if (drive >= 0 && drive < N_DRIVE) { new_fdc = FDC(drive); current_drive = drive; } if (new_fdc >= N_FDC) { pr_info("bad fdc value\n"); return; } fdc = new_fdc; set_dor(fdc, ~0, 8); set_dor(1 - f...
static void set_fdc(int drive) { if (drive >= 0 && drive < N_DRIVE) { fdc = FDC(drive); current_drive = drive; } if (fdc != 1 && fdc != 0) { pr_info("bad fdc value\n"); return; } set_dor(fdc, ~0, 8); set_dor(1 - fdc, ~8, 0); if (FDCS->rawcmd == 2) { re...
static void set_fdc(int drive) { unsigned int new_fdc = fdc; if (drive >= 0 && drive < N_DRIVE) { new_fdc = FDC(drive); current_drive = drive; } if (new_fdc >= N_FDC) { pr_info("bad fdc value\n"); return; } fdc = new_fdc; set_dor(fdc, ~0, 8); set_dor(1 - f...
static void set_fdc(int drive) { if (drive >= 0 && drive < N_DRIVE) { fdc = FDC(drive); current_drive = drive; } if (fdc != 1 && fdc != 0) { pr_info("bad fdc value\n"); return; } set_dor(fdc, ~0, 8); set_dor(1 - fdc, ~8, 0); }
static void set_fdc(int drive) { unsigned int new_fdc = fdc; if (drive >= 0 && drive < N_DRIVE) { new_fdc = FDC(drive); current_drive = drive; } if (new_fdc >= N_FDC) { pr_info("bad fdc value\n"); return; } fdc = new_fdc; set_dor(fdc, ~0, 8); set_dor(1 - f...
static void set_fdc(int drive) { if (drive >= 0 && drive < N_DRIVE) { fdc = FDC(drive); current_drive = drive; } if (fdc != 1 && fdc != 0) { pr_info("bad fdc value\n"); return; } set_dor(fdc, ~0, 8); set_dor(1 - fdc, ~8, 0); /* PLACEHOLDER: DO NOT DELETE THIS ...
static void set_fdc(int drive) { unsigned int new_fdc = fdc; if (drive >= 0 && drive < N_DRIVE) { new_fdc = FDC(drive); current_drive = drive; } if (new_fdc >= N_FDC) { pr_info("bad fdc value\n"); return; } fdc = new_fdc; set_dor(fdc, ~0, 8); set_dor(1 - f...
static void set_fdc(int drive) { + unsigned int new_fdc = fdc; if (drive >= 0 && drive < N_DRIVE) { - fdc = FDC(drive); + new_fdc = FDC(drive); current_drive = drive; } - if (fdc != 1 && fdc != 0) { + if (new_fdc >= N_FDC) { pr_info("bad fdc value\n"); return...
CVE-2020-9391
linux
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux
mm/mmap.c
ksys_mmap_pgoff
unsigned long ksys_mmap_pgoff(unsigned long addr, unsigned long len, unsigned long prot, unsigned long flags, unsigned long fd, unsigned long pgoff) { struct file *file = NULL; unsigned long retval; addr = untagged_addr(addr); if (!(flags & MAP_ANONYMOUS)) { audit_mmap_fd(fd, flags); fil...
unsigned long ksys_mmap_pgoff(unsigned long addr, unsigned long len, unsigned long prot, unsigned long flags, unsigned long fd, unsigned long pgoff) { struct file *file = NULL; unsigned long retval; if (!(flags & MAP_ANONYMOUS)) { audit_mmap_fd(fd, flags); file = fget(fd); if (!file)...
unsigned long ksys_mmap_pgoff(unsigned long addr, unsigned long len, unsigned long prot, unsigned long flags, unsigned long fd, unsigned long pgoff) { struct file *file = NULL; unsigned long retval; addr = untagged_addr(addr); if (!(flags & MAP_ANONYMOUS)) { audit_mmap_fd(fd, flags); fil...
unsigned long ksys_mmap_pgoff(unsigned long addr, unsigned long len, unsigned long prot, unsigned long flags, unsigned long fd, unsigned long pgoff) { struct file *file = NULL; unsigned long retval; if (!(flags & MAP_ANONYMOUS)) { audit_mmap_fd(fd, flags); file = fget(fd); if (!file)...
unsigned long ksys_mmap_pgoff(unsigned long addr, unsigned long len, unsigned long prot, unsigned long flags, unsigned long fd, unsigned long pgoff) { struct file *file = NULL; unsigned long retval; addr = untagged_addr(addr); if (!(flags & MAP_ANONYMOUS)) { } else if (flags & MAP_HUGETLB) { } ...
unsigned long ksys_mmap_pgoff(unsigned long addr, unsigned long len, unsigned long prot, unsigned long flags, unsigned long fd, unsigned long pgoff) { struct file *file = NULL; unsigned long retval; if (!(flags & MAP_ANONYMOUS)) { } else if (flags & MAP_HUGETLB) { } retval = vm_mmap_pgoff(file, ...
unsigned long ksys_mmap_pgoff(unsigned long addr, unsigned long len, unsigned long prot, unsigned long flags, unsigned long fd, unsigned long pgoff) { struct file *file = NULL; unsigned long retval; addr = untagged_addr(addr); if (!(flags & MAP_ANONYMOUS)) { /* PLACEHOLDER: DO NOT DELETE THIS COMMEN...
unsigned long ksys_mmap_pgoff(unsigned long addr, unsigned long len, unsigned long prot, unsigned long flags, unsigned long fd, unsigned long pgoff) { struct file *file = NULL; unsigned long retval; if (!(flags & MAP_ANONYMOUS)) { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ } else if (flags & MAP_...
unsigned long ksys_mmap_pgoff(unsigned long addr, unsigned long len, unsigned long prot, unsigned long flags, unsigned long fd, unsigned long pgoff) { struct file *file = NULL; unsigned long retval; - addr = untagged_addr(addr); if (!(flags & MAP_ANONYMOUS)) { } else if (flags & MAP_HUGETLB) { ...
CVE-2021-0129
linux
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux
net/bluetooth/smp.c
smp_cmd_public_key
static int smp_cmd_public_key(struct l2cap_conn *conn, struct sk_buff *skb) { struct smp_cmd_public_key *key = (void *) skb->data; struct hci_conn *hcon = conn->hcon; struct l2cap_chan *chan = conn->smp; struct smp_chan *smp = chan->data; struct hci_dev *hdev = hcon->hdev; struct smp_cmd_pairing...
static int smp_cmd_public_key(struct l2cap_conn *conn, struct sk_buff *skb) { struct smp_cmd_public_key *key = (void *) skb->data; struct hci_conn *hcon = conn->hcon; struct l2cap_chan *chan = conn->smp; struct smp_chan *smp = chan->data; struct hci_dev *hdev = hcon->hdev; struct smp_cmd_pairing...
static int smp_cmd_public_key(struct l2cap_conn *conn, struct sk_buff *skb) { struct smp_cmd_public_key *key = (void *) skb->data; struct hci_conn *hcon = conn->hcon; struct l2cap_chan *chan = conn->smp; struct smp_chan *smp = chan->data; struct hci_dev *hdev = hcon->hdev; struct crypto_kpp *tfm...
static int smp_cmd_public_key(struct l2cap_conn *conn, struct sk_buff *skb) { struct smp_cmd_public_key *key = (void *) skb->data; struct hci_conn *hcon = conn->hcon; struct l2cap_chan *chan = conn->smp; struct smp_chan *smp = chan->data; struct hci_dev *hdev = hcon->hdev; struct crypto_kpp *tfm...
static int smp_cmd_public_key(struct l2cap_conn *conn, struct sk_buff *skb) { struct smp_cmd_public_key *key = (void *) skb->data; struct hci_conn *hcon = conn->hcon; struct l2cap_chan *chan = conn->smp; struct smp_chan *smp = chan->data; struct hci_dev *hdev = hcon->hdev; if (skb->len < sizeof(...
static int smp_cmd_public_key(struct l2cap_conn *conn, struct sk_buff *skb) { struct smp_cmd_public_key *key = (void *) skb->data; struct hci_conn *hcon = conn->hcon; struct l2cap_chan *chan = conn->smp; struct smp_chan *smp = chan->data; struct hci_dev *hdev = hcon->hdev; if (skb->len < sizeof(...
static int smp_cmd_public_key(struct l2cap_conn *conn, struct sk_buff *skb) { struct smp_cmd_public_key *key = (void *) skb->data; struct hci_conn *hcon = conn->hcon; struct l2cap_chan *chan = conn->smp; struct smp_chan *smp = chan->data; struct hci_dev *hdev = hcon->hdev; /* PLACEHOLDER: DO NOT...
static int smp_cmd_public_key(struct l2cap_conn *conn, struct sk_buff *skb) { struct smp_cmd_public_key *key = (void *) skb->data; struct hci_conn *hcon = conn->hcon; struct l2cap_chan *chan = conn->smp; struct smp_chan *smp = chan->data; struct hci_dev *hdev = hcon->hdev; /* PLACEHOLDER: DO NOT...
static int smp_cmd_public_key(struct l2cap_conn *conn, struct sk_buff *skb) { struct smp_cmd_public_key *key = (void *) skb->data; struct hci_conn *hcon = conn->hcon; struct l2cap_chan *chan = conn->smp; struct smp_chan *smp = chan->data; struct hci_dev *hdev = hcon->hdev; if (skb->len < ...
CVE-2021-0342
linux
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux
drivers/net/tun.c
tun_get_user
static ssize_t tun_get_user(struct tun_struct *tun, struct tun_file *tfile, void *msg_control, struct iov_iter *from, int noblock, bool more) { struct tun_pi pi = { 0, cpu_to_be16(ETH_P_IP) }; struct sk_buff *skb; size_t total_len = iov_iter_count(from); size_t len = total_len, align = tun->align, linea...
static ssize_t tun_get_user(struct tun_struct *tun, struct tun_file *tfile, void *msg_control, struct iov_iter *from, int noblock, bool more) { struct tun_pi pi = { 0, cpu_to_be16(ETH_P_IP) }; struct sk_buff *skb; size_t total_len = iov_iter_count(from); size_t len = total_len, align = tun->align, linea...
static ssize_t tun_get_user(struct tun_struct *tun, struct tun_file *tfile, void *msg_control, struct iov_iter *from, int noblock, bool more) { struct tun_pi pi = { 0, cpu_to_be16(ETH_P_IP) }; struct sk_buff *skb; size_t total_len = iov_iter_count(from); size_t len = total_len, align = tun->align, linea...
static ssize_t tun_get_user(struct tun_struct *tun, struct tun_file *tfile, void *msg_control, struct iov_iter *from, int noblock, bool more) { struct tun_pi pi = { 0, cpu_to_be16(ETH_P_IP) }; struct sk_buff *skb; size_t total_len = iov_iter_count(from); size_t len = total_len, align = tun->align, linea...
static ssize_t tun_get_user(struct tun_struct *tun, struct tun_file *tfile, void *msg_control, struct iov_iter *from, int noblock, bool more) { size_t total_len = iov_iter_count(from); size_t len = total_len, align = tun->align, linear; struct virtio_net_hdr gso = { 0 }; bool zerocopy = false; int s...
static ssize_t tun_get_user(struct tun_struct *tun, struct tun_file *tfile, void *msg_control, struct iov_iter *from, int noblock, bool more) { size_t total_len = iov_iter_count(from); size_t len = total_len, align = tun->align, linear; struct virtio_net_hdr gso = { 0 }; bool zerocopy = false; int s...
static ssize_t tun_get_user(struct tun_struct *tun, struct tun_file *tfile, void *msg_control, struct iov_iter *from, int noblock, bool more) { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ size_t total_len = iov_iter_count(from); size_t len = total_len, align = tun->align, linear; struct virtio_net_hdr...
static ssize_t tun_get_user(struct tun_struct *tun, struct tun_file *tfile, void *msg_control, struct iov_iter *from, int noblock, bool more) { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ size_t total_len = iov_iter_count(from); size_t len = total_len, align = tun->align, linear; struct virtio_net_hdr...
static ssize_t tun_get_user(struct tun_struct *tun, struct tun_file *tfile, void *msg_control, struct iov_iter *from, int noblock, bool more) { size_t total_len = iov_iter_count(from); size_t len = total_len, align = tun->align, linear; struct virtio_net_hdr gso = { 0 }; bool zerocopy = false; ...
CVE-2021-0447
linux
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux
net/l2tp/l2tp_ppp.c
pppol2tp_connect
static int pppol2tp_connect(struct socket *sock, struct sockaddr *uservaddr, int sockaddr_len, int flags) { struct sock *sk = sock->sk; struct sockaddr_pppol2tp *sp = (struct sockaddr_pppol2tp *) uservaddr; struct sockaddr_pppol2tpv3 *sp3 = (struct sockaddr_pppol2tpv3 *) uservaddr; struct pppox_sock *po...
static int pppol2tp_connect(struct socket *sock, struct sockaddr *uservaddr, int sockaddr_len, int flags) { struct sock *sk = sock->sk; struct sockaddr_pppol2tp *sp = (struct sockaddr_pppol2tp *) uservaddr; struct sockaddr_pppol2tpv3 *sp3 = (struct sockaddr_pppol2tpv3 *) uservaddr; struct pppox_sock *po...
static int pppol2tp_connect(struct socket *sock, struct sockaddr *uservaddr, int sockaddr_len, int flags) { struct sock *sk = sock->sk; struct sockaddr_pppol2tp *sp = (struct sockaddr_pppol2tp *) uservaddr; struct pppox_sock *po = pppox_sk(sk); struct l2tp_session *session = NULL; struct l2tp_tunnel...
static int pppol2tp_connect(struct socket *sock, struct sockaddr *uservaddr, int sockaddr_len, int flags) { struct sock *sk = sock->sk; struct sockaddr_pppol2tp *sp = (struct sockaddr_pppol2tp *) uservaddr; struct pppox_sock *po = pppox_sk(sk); struct l2tp_session *session = NULL; struct l2tp_tunnel...
static int pppol2tp_connect(struct socket *sock, struct sockaddr *uservaddr, int sockaddr_len, int flags) { struct sock *sk = sock->sk; struct pppox_sock *po = pppox_sk(sk); struct l2tp_session_cfg cfg = { 0, }; int ver = 2; lock_sock(sk); if (sockaddr_len == sizeof(struct sockaddr_pppol2tp)) { ...
static int pppol2tp_connect(struct socket *sock, struct sockaddr *uservaddr, int sockaddr_len, int flags) { struct sock *sk = sock->sk; struct pppox_sock *po = pppox_sk(sk); struct l2tp_session_cfg cfg = { 0, }; int ver = 2; lock_sock(sk); if (sockaddr_len == sizeof(struct sockaddr_pppol2tp)) { ...
static int pppol2tp_connect(struct socket *sock, struct sockaddr *uservaddr, int sockaddr_len, int flags) { struct sock *sk = sock->sk; /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ struct pppox_sock *po = pppox_sk(sk); /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ struct l2tp_session_cfg cfg = { 0,...
static int pppol2tp_connect(struct socket *sock, struct sockaddr *uservaddr, int sockaddr_len, int flags) { struct sock *sk = sock->sk; /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ struct pppox_sock *po = pppox_sk(sk); /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ struct l2tp_session_cfg cfg = { 0,...
static int pppol2tp_connect(struct socket *sock, struct sockaddr *uservaddr, int sockaddr_len, int flags) { struct sock *sk = sock->sk; struct pppox_sock *po = pppox_sk(sk); struct l2tp_session_cfg cfg = { 0, }; int ver = 2; lock_sock(sk); if (sockaddr_len == sizeof(struct sockaddr_pppol2...
CVE-2021-0447
linux
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux
net/l2tp/l2tp_ppp.c
pppol2tp_recv
static void pppol2tp_recv(struct l2tp_session *session, struct sk_buff *skb, int data_len) { struct pppol2tp_session *ps = l2tp_session_priv(session); struct sock *sk = NULL; sk = ps->sock; if (sk == NULL) { goto no_sock; } if (sk->sk_state & PPPOX_BOUND) { struct pppox_sock *po;...
static void pppol2tp_recv(struct l2tp_session *session, struct sk_buff *skb, int data_len) { struct pppol2tp_session *ps = l2tp_session_priv(session); struct sock *sk = NULL; rcu_read_lock(); sk = rcu_dereference(ps->sk); if (sk == NULL) { goto no_sock; } if (sk->sk_state & PPPOX_BOU...
static void pppol2tp_recv(struct l2tp_session *session, struct sk_buff *skb, int data_len) { struct pppol2tp_session *ps = l2tp_session_priv(session); struct sock *sk = NULL; sk = ps->sock; if (sk == NULL) { goto no_sock; } if (sk->sk_state & PPPOX_BOUND) { struct pppox_sock *po;...
static void pppol2tp_recv(struct l2tp_session *session, struct sk_buff *skb, int data_len) { struct pppol2tp_session *ps = l2tp_session_priv(session); struct sock *sk = NULL; rcu_read_lock(); sk = rcu_dereference(ps->sk); if (sk == NULL) { goto no_sock; } if (sk->sk_state & PPPOX_BOU...
static void pppol2tp_recv(struct l2tp_session *session, struct sk_buff *skb, int data_len) { struct pppol2tp_session *ps = l2tp_session_priv(session); struct sock *sk = NULL; sk = ps->sock; if (sk == NULL) { goto no_sock; } if (sk->sk_state & PPPOX_BOUND) { po = pppox_sk(sk); ...
static void pppol2tp_recv(struct l2tp_session *session, struct sk_buff *skb, int data_len) { struct pppol2tp_session *ps = l2tp_session_priv(session); struct sock *sk = NULL; rcu_read_lock(); sk = rcu_dereference(ps->sk); if (sk == NULL) { goto no_sock; } if (sk->sk_state & PPPOX_BOU...
static void pppol2tp_recv(struct l2tp_session *session, struct sk_buff *skb, int data_len) { struct pppol2tp_session *ps = l2tp_session_priv(session); struct sock *sk = NULL; sk = ps->sock; if (sk == NULL) { goto no_sock; } if (sk->sk_state & PPPOX_BOUND) { /* PLACEHOLDER: DO NOT DEL...
static void pppol2tp_recv(struct l2tp_session *session, struct sk_buff *skb, int data_len) { struct pppol2tp_session *ps = l2tp_session_priv(session); struct sock *sk = NULL; rcu_read_lock(); sk = rcu_dereference(ps->sk); if (sk == NULL) { goto no_sock; } if (sk->sk_state & PPPOX_BOU...
static void pppol2tp_recv(struct l2tp_session *session, struct sk_buff *skb, int data_len) { struct pppol2tp_session *ps = l2tp_session_priv(session); struct sock *sk = NULL; - sk = ps->sock; + rcu_read_lock(); + sk = rcu_dereference(ps->sk); if (sk == NULL) { goto no_sock; } ...
CVE-2021-0447
linux
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux
net/l2tp/l2tp_ppp.c
pppol2tp_release
static int pppol2tp_release(struct socket *sock) { struct sock *sk = sock->sk; struct l2tp_session *session; int error; if (!sk) { return 0; } error = -EBADF; lock_sock(sk); if (sock_flag(sk, SOCK_DEAD) != 0) { goto error; } pppox_unbind_sock(sk); sk->sk_state...
static int pppol2tp_release(struct socket *sock) { struct sock *sk = sock->sk; struct l2tp_session *session; int error; if (!sk) { return 0; } error = -EBADF; lock_sock(sk); if (sock_flag(sk, SOCK_DEAD) != 0) { goto error; } pppox_unbind_sock(sk); sk->sk_state...
static int pppol2tp_release(struct socket *sock) { struct sock *sk = sock->sk; struct l2tp_session *session; int error; if (!sk) { return 0; } error = -EBADF; lock_sock(sk); if (sock_flag(sk, SOCK_DEAD) != 0) { goto error; } pppox_unbind_sock(sk); sk->sk_state...
static int pppol2tp_release(struct socket *sock) { struct sock *sk = sock->sk; struct l2tp_session *session; int error; if (!sk) { return 0; } error = -EBADF; lock_sock(sk); if (sock_flag(sk, SOCK_DEAD) != 0) { goto error; } pppox_unbind_sock(sk); sk->sk_state...
static int pppol2tp_release(struct socket *sock) { struct sock *sk = sock->sk; if (!sk) { return 0; } lock_sock(sk); if (sock_flag(sk, SOCK_DEAD) != 0) { goto error; } pppox_unbind_sock(sk); sock_orphan(sk); session = pppol2tp_sock_to_session(sk); if (session != N...
static int pppol2tp_release(struct socket *sock) { struct sock *sk = sock->sk; if (!sk) { return 0; } lock_sock(sk); if (sock_flag(sk, SOCK_DEAD) != 0) { goto error; } pppox_unbind_sock(sk); sock_orphan(sk); session = pppol2tp_sock_to_session(sk); if (session != N...
static int pppol2tp_release(struct socket *sock) { struct sock *sk = sock->sk; /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ if (!sk) { return 0; } /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ lock_sock(sk); if (sock_flag(sk, SOCK_DEAD) != 0) { goto error; } pppox_un...
static int pppol2tp_release(struct socket *sock) { struct sock *sk = sock->sk; /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ if (!sk) { return 0; } /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ lock_sock(sk); if (sock_flag(sk, SOCK_DEAD) != 0) { goto error; } pppox_un...
static int pppol2tp_release(struct socket *sock) { struct sock *sk = sock->sk; if (!sk) { return 0; } lock_sock(sk); if (sock_flag(sk, SOCK_DEAD) != 0) { goto error; } pppox_unbind_sock(sk); sock_orphan(sk); session = pppol2tp_sock_to_session(sk); if ...
CVE-2021-0447
linux
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux
net/l2tp/l2tp_ppp.c
pppol2tp_seq_session_show
static void pppol2tp_seq_session_show(struct seq_file *m, void *v) { struct l2tp_session *session = v; struct l2tp_tunnel *tunnel = session->tunnel; struct pppol2tp_session *ps = l2tp_session_priv(session); struct pppox_sock *po = pppox_sk(ps->sock); u32 ip = 0; u16 port = 0; if (tunnel->soc...
static void pppol2tp_seq_session_show(struct seq_file *m, void *v) { struct l2tp_session *session = v; struct l2tp_tunnel *tunnel = session->tunnel; unsigned char state; char user_data_ok; struct sock *sk; u32 ip = 0; u16 port = 0; if (tunnel->sock) { struct inet_sock *inet = ine...
static void pppol2tp_seq_session_show(struct seq_file *m, void *v) { struct l2tp_session *session = v; struct l2tp_tunnel *tunnel = session->tunnel; struct pppol2tp_session *ps = l2tp_session_priv(session); struct pppox_sock *po = pppox_sk(ps->sock); u32 ip = 0; u16 port = 0; if (tunnel->soc...
static void pppol2tp_seq_session_show(struct seq_file *m, void *v) { struct l2tp_session *session = v; struct l2tp_tunnel *tunnel = session->tunnel; unsigned char state; char user_data_ok; struct sock *sk; u32 ip = 0; u16 port = 0; if (tunnel->sock) { struct inet_sock *inet = ine...
static void pppol2tp_seq_session_show(struct seq_file *m, void *v) { struct l2tp_session *session = v; struct l2tp_tunnel *tunnel = session->tunnel; struct pppol2tp_session *ps = l2tp_session_priv(session); struct pppox_sock *po = pppox_sk(ps->sock); u32 ip = 0; u16 port = 0; if (tunnel->soc...
static void pppol2tp_seq_session_show(struct seq_file *m, void *v) { struct l2tp_session *session = v; struct l2tp_tunnel *tunnel = session->tunnel; unsigned char state; char user_data_ok; struct sock *sk; u32 ip = 0; u16 port = 0; if (tunnel->sock) { struct inet_sock *inet = ine...
static void pppol2tp_seq_session_show(struct seq_file *m, void *v) { struct l2tp_session *session = v; struct l2tp_tunnel *tunnel = session->tunnel; struct pppol2tp_session *ps = l2tp_session_priv(session); struct pppox_sock *po = pppox_sk(ps->sock); u32 ip = 0; u16 port = 0; if (tunnel->soc...
static void pppol2tp_seq_session_show(struct seq_file *m, void *v) { struct l2tp_session *session = v; struct l2tp_tunnel *tunnel = session->tunnel; unsigned char state; char user_data_ok; struct sock *sk; u32 ip = 0; u16 port = 0; if (tunnel->sock) { struct inet_sock *inet = ine...
static void pppol2tp_seq_session_show(struct seq_file *m, void *v) { struct l2tp_session *session = v; struct l2tp_tunnel *tunnel = session->tunnel; - struct pppol2tp_session *ps = l2tp_session_priv(session); - struct pppox_sock *po = pppox_sk(ps->sock); + unsigned char state; + char user_data_ok...
CVE-2021-0447
linux
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux
net/l2tp/l2tp_ppp.c
pppol2tp_session_close
static void pppol2tp_session_close(struct l2tp_session *session) { struct pppol2tp_session *ps = l2tp_session_priv(session); struct sock *sk = ps->sock; struct socket *sock = sk->sk_socket; BUG_ON(session->magic != L2TP_SESSION_MAGIC); if (sock) { inet_shutdown(sock, 2); } l2tp_sessi...
static void pppol2tp_session_close(struct l2tp_session *session) { struct sock *sk; BUG_ON(session->magic != L2TP_SESSION_MAGIC); sk = pppol2tp_session_get_sock(session); if (sk) { if (sk->sk_socket) { inet_shutdown(sk->sk_socket, SEND_SHUTDOWN); } sock_put(sk); }...
static void pppol2tp_session_close(struct l2tp_session *session) { struct pppol2tp_session *ps = l2tp_session_priv(session); struct sock *sk = ps->sock; struct socket *sock = sk->sk_socket; BUG_ON(session->magic != L2TP_SESSION_MAGIC); if (sock) { inet_shutdown(sock, SEND_SHUTDOWN); } ...
static void pppol2tp_session_close(struct l2tp_session *session) { struct sock *sk; BUG_ON(session->magic != L2TP_SESSION_MAGIC); sk = pppol2tp_session_get_sock(session); if (sk) { if (sk->sk_socket) { inet_shutdown(sk->sk_socket, SEND_SHUTDOWN); } sock_put(sk); }...
static void pppol2tp_session_close(struct l2tp_session *session) { struct pppol2tp_session *ps = l2tp_session_priv(session); struct sock *sk = ps->sock; struct socket *sock = sk->sk_socket; BUG_ON(session->magic != L2TP_SESSION_MAGIC); if (sock) { inet_shutdown(sock, 2); } l2tp_sessi...
static void pppol2tp_session_close(struct l2tp_session *session) { struct sock *sk; BUG_ON(session->magic != L2TP_SESSION_MAGIC); sk = pppol2tp_session_get_sock(session); if (sk) { if (sk->sk_socket) { inet_shutdown(sk->sk_socket, SEND_SHUTDOWN); } sock_put(sk); }...
static void pppol2tp_session_close(struct l2tp_session *session) { struct pppol2tp_session *ps = l2tp_session_priv(session); struct sock *sk = ps->sock; struct socket *sock = sk->sk_socket; BUG_ON(session->magic != L2TP_SESSION_MAGIC); if (sock) { inet_shutdown(sock, SEND_SHUTDOWN); } ...
static void pppol2tp_session_close(struct l2tp_session *session) { struct sock *sk; BUG_ON(session->magic != L2TP_SESSION_MAGIC); sk = pppol2tp_session_get_sock(session); if (sk) { if (sk->sk_socket) { inet_shutdown(sk->sk_socket, SEND_SHUTDOWN); } sock_put(sk); }...
static void pppol2tp_session_close(struct l2tp_session *session) { - struct pppol2tp_session *ps = l2tp_session_priv(session); - struct sock *sk = ps->sock; - struct socket *sock = sk->sk_socket; + struct sock *sk; BUG_ON(session->magic != L2TP_SESSION_MAGIC); - if (sock) { - inet_shutdown(s...
CVE-2021-0447
linux
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux
net/l2tp/l2tp_ppp.c
pppol2tp_session_create
static int pppol2tp_session_create(struct net *net, struct l2tp_tunnel *tunnel, u32 session_id, u32 peer_session_id, struct l2tp_session_cfg *cfg) { int error; struct l2tp_session *session; struct pppol2tp_session *ps; if (!tunnel->sock) { error = -ENOENT; goto err; } if (cfg->mt...
static int pppol2tp_session_create(struct net *net, struct l2tp_tunnel *tunnel, u32 session_id, u32 peer_session_id, struct l2tp_session_cfg *cfg) { int error; struct l2tp_session *session; struct pppol2tp_session *ps; if (!tunnel->sock) { error = -ENOENT; goto err; } if (cfg->mt...
static int pppol2tp_session_create(struct net *net, struct l2tp_tunnel *tunnel, u32 session_id, u32 peer_session_id, struct l2tp_session_cfg *cfg) { int error; struct l2tp_session *session; struct pppol2tp_session *ps; if (!tunnel->sock) { error = -ENOENT; goto err; } if (cfg->mt...
static int pppol2tp_session_create(struct net *net, struct l2tp_tunnel *tunnel, u32 session_id, u32 peer_session_id, struct l2tp_session_cfg *cfg) { int error; struct l2tp_session *session; struct pppol2tp_session *ps; if (!tunnel->sock) { error = -ENOENT; goto err; } if (cfg->mt...
static int pppol2tp_session_create(struct net *net, struct l2tp_tunnel *tunnel, u32 session_id, u32 peer_session_id, struct l2tp_session_cfg *cfg) { session = l2tp_session_create(sizeof(struct pppol2tp_session), tunnel, session_id, peer_session_id, cfg); if (IS_ERR(session)) { goto err; } ps = l...
static int pppol2tp_session_create(struct net *net, struct l2tp_tunnel *tunnel, u32 session_id, u32 peer_session_id, struct l2tp_session_cfg *cfg) { session = l2tp_session_create(sizeof(struct pppol2tp_session), tunnel, session_id, peer_session_id, cfg); if (IS_ERR(session)) { goto err; } ps = l...
static int pppol2tp_session_create(struct net *net, struct l2tp_tunnel *tunnel, u32 session_id, u32 peer_session_id, struct l2tp_session_cfg *cfg) { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ session = l2tp_session_create(sizeof(struct pppol2tp_session), tunnel, session_id, peer_session_id, cfg); if (IS_...
static int pppol2tp_session_create(struct net *net, struct l2tp_tunnel *tunnel, u32 session_id, u32 peer_session_id, struct l2tp_session_cfg *cfg) { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ session = l2tp_session_create(sizeof(struct pppol2tp_session), tunnel, session_id, peer_session_id, cfg); if (IS_...
static int pppol2tp_session_create(struct net *net, struct l2tp_tunnel *tunnel, u32 session_id, u32 peer_session_id, struct l2tp_session_cfg *cfg) { session = l2tp_session_create(sizeof(struct pppol2tp_session), tunnel, session_id, peer_session_id, cfg); if (IS_ERR(session)) { goto err; } ...
CVE-2021-0447
linux
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux
net/l2tp/l2tp_ppp.c
pppol2tp_session_ioctl
static int pppol2tp_session_ioctl(struct l2tp_session *session, unsigned int cmd, unsigned long arg) { struct ifreq ifr; int err = 0; struct sock *sk; int val = (int) arg; struct pppol2tp_session *ps = l2tp_session_priv(session); struct l2tp_tunnel *tunnel = session->tunnel; struct pppol2tp_...
static int pppol2tp_session_ioctl(struct l2tp_session *session, unsigned int cmd, unsigned long arg) { struct ifreq ifr; int err = 0; struct sock *sk; int val = (int) arg; struct pppol2tp_session *ps = l2tp_session_priv(session); struct l2tp_tunnel *tunnel = session->tunnel; struct pppol2tp_...
static int pppol2tp_session_ioctl(struct l2tp_session *session, unsigned int cmd, unsigned long arg) { struct ifreq ifr; int err = 0; struct sock *sk; int val = (int) arg; struct pppol2tp_session *ps = l2tp_session_priv(session); struct l2tp_tunnel *tunnel = session->tunnel; struct pppol2tp_...
static int pppol2tp_session_ioctl(struct l2tp_session *session, unsigned int cmd, unsigned long arg) { struct ifreq ifr; int err = 0; struct sock *sk; int val = (int) arg; struct pppol2tp_session *ps = l2tp_session_priv(session); struct l2tp_tunnel *tunnel = session->tunnel; struct pppol2tp_...
static int pppol2tp_session_ioctl(struct l2tp_session *session, unsigned int cmd, unsigned long arg) { struct pppol2tp_session *ps = l2tp_session_priv(session); PRTK(session->debug, PPPOL2TP_MSG_CONTROL, KERN_DEBUG, "%s: pppol2tp_session_ioctl(cmd=%#x, arg=%#lx)\n", session->name, cmd, arg); sk = ps->sock; ...
static int pppol2tp_session_ioctl(struct l2tp_session *session, unsigned int cmd, unsigned long arg) { struct pppol2tp_session *ps = l2tp_session_priv(session); PRTK(session->debug, PPPOL2TP_MSG_CONTROL, KERN_DEBUG, "%s: pppol2tp_session_ioctl(cmd=%#x, arg=%#lx)\n", session->name, cmd, arg); sk = pppol2tp_s...
static int pppol2tp_session_ioctl(struct l2tp_session *session, unsigned int cmd, unsigned long arg) { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ struct pppol2tp_session *ps = l2tp_session_priv(session); /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ l2tp_dbg(session, L2TP_MSG_CONTROL, "%s: pppol2tp_s...
static int pppol2tp_session_ioctl(struct l2tp_session *session, unsigned int cmd, unsigned long arg) { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ struct pppol2tp_session *ps = l2tp_session_priv(session); /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ l2tp_dbg(session, L2TP_MSG_CONTROL, "%s: pppol2tp_s...
static int pppol2tp_session_ioctl(struct l2tp_session *session, unsigned int cmd, unsigned long arg) { struct pppol2tp_session *ps = l2tp_session_priv(session); PRTK(session->debug, PPPOL2TP_MSG_CONTROL, KERN_DEBUG, "%s: pppol2tp_session_ioctl(cmd=%#x, arg=%#lx)\n", session->name, cmd, arg); - sk = ps->so...
CVE-2021-0447
linux
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux
net/l2tp/l2tp_ppp.c
pppol2tp_session_setsockopt
static int pppol2tp_session_setsockopt(struct sock *sk, struct l2tp_session *session, int optname, int val) { int err = 0; struct pppol2tp_session *ps = l2tp_session_priv(session); switch (optname) { case PPPOL2TP_SO_RECVSEQ: if ((val != 0) && (val != 1)) { err = -EVAL; b...
static int pppol2tp_session_setsockopt(struct sock *sk, struct l2tp_session *session, int optname, int val) { int err = 0; switch (optname) { case PPPOL2TP_SO_RECVSEQ: if ((val != 0) && (val != 1)) { err = -EVAL; break; } session->recv_seq = val ? -1 : 0; ...
static int pppol2tp_session_setsockopt(struct sock *sk, struct l2tp_session *session, int optname, int val) { int err = 0; struct pppol2tp_session *ps = l2tp_session_priv(session); switch (optname) { case PPPOL2TP_SO_RECVSEQ: if ((val != 0) && (val != 1)) { err = -EVAL; b...
static int pppol2tp_session_setsockopt(struct sock *sk, struct l2tp_session *session, int optname, int val) { int err = 0; switch (optname) { case PPPOL2TP_SO_RECVSEQ: if ((val != 0) && (val != 1)) { err = -EVAL; break; } session->recv_seq = !!val; l2t...
static int pppol2tp_session_setsockopt(struct sock *sk, struct l2tp_session *session, int optname, int val) { int err = 0; struct pppol2tp_session *ps = l2tp_session_priv(session); switch (optname) { case PPPOL2TP_SO_RECVSEQ: PRTK(session->debug, PPPOL2TP_MSG_CONTROL, KERN_FO, "%s: set recv_seq=...
static int pppol2tp_session_setsockopt(struct sock *sk, struct l2tp_session *session, int optname, int val) { int err = 0; switch (optname) { case PPPOL2TP_SO_RECVSEQ: PRTK(session->debug, PPPOL2TP_MSG_CONTROL, KERN_FO, "%s: set recv_seq=%d\n", session->name, session->recv_seq); break; c...
static int pppol2tp_session_setsockopt(struct sock *sk, struct l2tp_session *session, int optname, int val) { int err = 0; struct pppol2tp_session *ps = l2tp_session_priv(session); switch (optname) { case PPPOL2TP_SO_RECVSEQ: /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ session->recv_seq = ...
static int pppol2tp_session_setsockopt(struct sock *sk, struct l2tp_session *session, int optname, int val) { int err = 0; switch (optname) { case PPPOL2TP_SO_RECVSEQ: /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ session->recv_seq = !!val; l2tp_info(session, L2TP_MSG_CONTROL, "%s: set r...
static int pppol2tp_session_setsockopt(struct sock *sk, struct l2tp_session *session, int optname, int val) { int err = 0; - struct pppol2tp_session *ps = l2tp_session_priv(session); switch (optname) { case PPPOL2TP_SO_RECVSEQ: PRTK(session->debug, PPPOL2TP_MSG_CONTROL, KERN_FO, "%s: set rec...
CVE-2021-0447
linux
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux
net/l2tp/l2tp_ppp.c
pppol2tp_show
static void pppol2tp_show(struct seq_file *m, void *arg) { struct l2tp_session *session = arg; struct pppol2tp_session *ps = l2tp_session_priv(session); if (ps) { struct pppox_sock *po = pppox_sk(ps->sock); if (po) { seq_printf(m, " interface %s\n", ppp_dev_name(&po->chan)); ...
static void pppol2tp_show(struct seq_file *m, void *arg) { struct l2tp_session *session = arg; struct sock *sk; sk = pppol2tp_session_get_sock(session); if (sk) { struct pppox_sock *po = pppox_sk(sk); seq_printf(m, " interface %s\n", ppp_dev_name(&po->chan)); sock_put(sk); ...
static void pppol2tp_show(struct seq_file *m, void *arg) { struct l2tp_session *session = arg; struct pppol2tp_session *ps = l2tp_session_priv(session); if (ps) { struct pppox_sock *po = pppox_sk(ps->sock); if (po) { seq_printf(m, " interface %s\n", ppp_dev_name(&po->chan)); ...
static void pppol2tp_show(struct seq_file *m, void *arg) { struct l2tp_session *session = arg; struct sock *sk; sk = pppol2tp_session_get_sock(session); if (sk) { struct pppox_sock *po = pppox_sk(sk); seq_printf(m, " interface %s\n", ppp_dev_name(&po->chan)); sock_put(sk); ...
static void pppol2tp_show(struct seq_file *m, void *arg) { struct l2tp_session *session = arg; struct pppol2tp_session *ps = l2tp_session_priv(session); if (ps) { struct pppox_sock *po = pppox_sk(ps->sock); if (po) { seq_printf(m, " interface %s\n", ppp_dev_name(&po->chan)); ...
static void pppol2tp_show(struct seq_file *m, void *arg) { struct l2tp_session *session = arg; struct sock *sk; sk = pppol2tp_session_get_sock(session); if (sk) { struct pppox_sock *po = pppox_sk(sk); seq_printf(m, " interface %s\n", ppp_dev_name(&po->chan)); sock_put(sk); ...
static void pppol2tp_show(struct seq_file *m, void *arg) { struct l2tp_session *session = arg; struct pppol2tp_session *ps = l2tp_session_priv(session); if (ps) { struct pppox_sock *po = pppox_sk(ps->sock); if (po) { seq_printf(m, " interface %s\n", ppp_dev_name(&po->chan)); ...
static void pppol2tp_show(struct seq_file *m, void *arg) { struct l2tp_session *session = arg; struct sock *sk; sk = pppol2tp_session_get_sock(session); if (sk) { struct pppox_sock *po = pppox_sk(sk); seq_printf(m, " interface %s\n", ppp_dev_name(&po->chan)); sock_put(sk); ...
static void pppol2tp_show(struct seq_file *m, void *arg) { struct l2tp_session *session = arg; - struct pppol2tp_session *ps = l2tp_session_priv(session); - if (ps) { - struct pppox_sock *po = pppox_sk(ps->sock); - if (po) { - seq_printf(m, " interface %s\n", ppp_dev_name(&po->cha...
CVE-2021-0512
linux
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux
drivers/hid/hid-core.c
hid_register_field
static struct hid_field *hid_register_field(struct hid_report *report, unsigned usages, unsigned values) { struct hid_field *field; if (report->maxfield == HID_MAX_FIELDS) { hid_err(report->device, "too many fields in report\n"); return NULL; } field = kzalloc((sizeof(struct hid_field) +...
static struct hid_field *hid_register_field(struct hid_report *report, unsigned usages) { struct hid_field *field; if (report->maxfield == HID_MAX_FIELDS) { hid_err(report->device, "too many fields in report\n"); return NULL; } field = kzalloc((sizeof(struct hid_field) + usages * sizeof(...
static struct hid_field *hid_register_field(struct hid_report *report, unsigned usages, unsigned values) { struct hid_field *field; if (report->maxfield == HID_MAX_FIELDS) { hid_err(report->device, "too many fields in report\n"); return NULL; } field = kzalloc((sizeof(struct hid_field) +...
static struct hid_field *hid_register_field(struct hid_report *report, unsigned usages) { struct hid_field *field; if (report->maxfield == HID_MAX_FIELDS) { hid_err(report->device, "too many fields in report\n"); return NULL; } field = kzalloc((sizeof(struct hid_field) + usages * sizeof(...
static struct hid_field *hid_register_field(struct hid_report *report, unsigned usages, unsigned values) { if (report->maxfield == HID_MAX_FIELDS) { return NULL; } field = kzalloc((sizeof(struct hid_field) + usages * sizeof(struct hid_usage) + values * sizeof(unsigned)), GFP_KERNEL); if (!field)...
static struct hid_field *hid_register_field(struct hid_report *report, unsigned usages) { if (report->maxfield == HID_MAX_FIELDS) { return NULL; } field = kzalloc((sizeof(struct hid_field) + usages * sizeof(struct hid_usage) + usages * sizeof(unsigned)), GFP_KERNEL); if (!field) { return...
static struct hid_field *hid_register_field(struct hid_report *report, unsigned usages, unsigned values) { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ if (report->maxfield == HID_MAX_FIELDS) { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ return NULL; } field = kzalloc((sizeof(struct hid_f...
static struct hid_field *hid_register_field(struct hid_report *report, unsigned usages) { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ if (report->maxfield == HID_MAX_FIELDS) { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ return NULL; } field = kzalloc((sizeof(struct hid_field) + usages * ...
-static struct hid_field *hid_register_field(struct hid_report *report, unsigned usages, unsigned values) { +static struct hid_field *hid_register_field(struct hid_report *report, unsigned usages) { if (report->maxfield == HID_MAX_FIELDS) { return NULL; } - field = kzalloc((sizeof(struct hid_field...
CVE-2021-0605
linux
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux
net/key/af_key.c
pfkey_dump
static int pfkey_dump(struct sock *sk, struct sk_buff *skb, const struct sadb_msg *hdr, void * const *ext_hdrs) { u8 proto; struct xfrm_address_filter *filter = NULL; struct pfkey_sock *pfk = pfkey_sk(sk); mutex_lock(&pfk->dump_lock); if (pfk->dump.dump != NULL) { mutex_unlock(&pfk->dump_loc...
static int pfkey_dump(struct sock *sk, struct sk_buff *skb, const struct sadb_msg *hdr, void * const *ext_hdrs) { u8 proto; struct xfrm_address_filter *filter = NULL; struct pfkey_sock *pfk = pfkey_sk(sk); mutex_lock(&pfk->dump_lock); if (pfk->dump.dump != NULL) { mutex_unlock(&pfk->dump_loc...
static int pfkey_dump(struct sock *sk, struct sk_buff *skb, const struct sadb_msg *hdr, void * const *ext_hdrs) { u8 proto; struct xfrm_address_filter *filter = NULL; struct pfkey_sock *pfk = pfkey_sk(sk); mutex_lock(&pfk->dump_lock); if (pfk->dump.dump != NULL) { mutex_unlock(&pfk->dump_loc...
static int pfkey_dump(struct sock *sk, struct sk_buff *skb, const struct sadb_msg *hdr, void * const *ext_hdrs) { u8 proto; struct xfrm_address_filter *filter = NULL; struct pfkey_sock *pfk = pfkey_sk(sk); mutex_lock(&pfk->dump_lock); if (pfk->dump.dump != NULL) { mutex_unlock(&pfk->dump_loc...
static int pfkey_dump(struct sock *sk, struct sk_buff *skb, const struct sadb_msg *hdr, void * const *ext_hdrs) { struct pfkey_sock *pfk = pfkey_sk(sk); if (ext_hdrs[SADB_X_EXT_FILTER - 1]) { struct sadb_x_filter *xfilter = ext_hdrs[SADB_X_EXT_FILTER - 1]; filter = kmalloc(sizeof(*filter), GFP_K...
static int pfkey_dump(struct sock *sk, struct sk_buff *skb, const struct sadb_msg *hdr, void * const *ext_hdrs) { struct pfkey_sock *pfk = pfkey_sk(sk); if (ext_hdrs[SADB_X_EXT_FILTER - 1]) { struct sadb_x_filter *xfilter = ext_hdrs[SADB_X_EXT_FILTER - 1]; if ((xfilter->sadb_x_filter_splen >= (s...
static int pfkey_dump(struct sock *sk, struct sk_buff *skb, const struct sadb_msg *hdr, void * const *ext_hdrs) { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ struct pfkey_sock *pfk = pfkey_sk(sk); /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ if (ext_hdrs[SADB_X_EXT_FILTER - 1]) { struct sadb_...
static int pfkey_dump(struct sock *sk, struct sk_buff *skb, const struct sadb_msg *hdr, void * const *ext_hdrs) { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ struct pfkey_sock *pfk = pfkey_sk(sk); /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ if (ext_hdrs[SADB_X_EXT_FILTER - 1]) { struct sadb_...
static int pfkey_dump(struct sock *sk, struct sk_buff *skb, const struct sadb_msg *hdr, void * const *ext_hdrs) { struct pfkey_sock *pfk = pfkey_sk(sk); if (ext_hdrs[SADB_X_EXT_FILTER - 1]) { struct sadb_x_filter *xfilter = ext_hdrs[SADB_X_EXT_FILTER - 1]; + if ((xfilter->sadb_x_filter_splen ...
CVE-2021-0920
linux
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux
net/unix/af_unix.c
unix_dgram_recvmsg
static int unix_dgram_recvmsg(struct socket *sock, struct msghdr *msg, size_t size, int flags) { struct scm_cookie scm; struct sock *sk = sock->sk; struct unix_sock *u = unix_sk(sk); struct sk_buff *skb, *last; long timeo; int skip; int err; err = -EOPNOTSUPP; if (flags&MSG_OOB) { ...
static int unix_dgram_recvmsg(struct socket *sock, struct msghdr *msg, size_t size, int flags) { struct scm_cookie scm; struct sock *sk = sock->sk; struct unix_sock *u = unix_sk(sk); struct sk_buff *skb, *last; long timeo; int skip; int err; err = -EOPNOTSUPP; if (flags&MSG_OOB) { ...
static int unix_dgram_recvmsg(struct socket *sock, struct msghdr *msg, size_t size, int flags) { struct scm_cookie scm; struct sock *sk = sock->sk; struct unix_sock *u = unix_sk(sk); struct sk_buff *skb, *last; long timeo; int err; int peeked, skip; err = -EOPNOTSUPP; if (flags&MSG_O...
static int unix_dgram_recvmsg(struct socket *sock, struct msghdr *msg, size_t size, int flags) { struct scm_cookie scm; struct sock *sk = sock->sk; struct unix_sock *u = unix_sk(sk); struct sk_buff *skb, *last; long timeo; int err; int peeked, skip; err = -EOPNOTSUPP; if (flags&MSG_O...
static int unix_dgram_recvmsg(struct socket *sock, struct msghdr *msg, size_t size, int flags) { struct sock *sk = sock->sk; struct unix_sock *u = unix_sk(sk); err = -EOPNOTSUPP; if (flags&MSG_OOB) { goto out; } timeo = sock_rcvtimeo(sk, flags & MSG_DONTWAIT); do { mutex_lock...
static int unix_dgram_recvmsg(struct socket *sock, struct msghdr *msg, size_t size, int flags) { struct sock *sk = sock->sk; struct unix_sock *u = unix_sk(sk); err = -EOPNOTSUPP; if (flags&MSG_OOB) { goto out; } timeo = sock_rcvtimeo(sk, flags & MSG_DONTWAIT); do { mutex_lock...
static int unix_dgram_recvmsg(struct socket *sock, struct msghdr *msg, size_t size, int flags) { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ struct sock *sk = sock->sk; struct unix_sock *u = unix_sk(sk); /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ err = -EOPNOTSUPP; if (flags&MSG_OOB) { ...
static int unix_dgram_recvmsg(struct socket *sock, struct msghdr *msg, size_t size, int flags) { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ struct sock *sk = sock->sk; struct unix_sock *u = unix_sk(sk); /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ err = -EOPNOTSUPP; if (flags&MSG_OOB) { ...
static int unix_dgram_recvmsg(struct socket *sock, struct msghdr *msg, size_t size, int flags) { struct sock *sk = sock->sk; struct unix_sock *u = unix_sk(sk); err = -EOPNOTSUPP; if (flags&MSG_OOB) { goto out; } timeo = sock_rcvtimeo(sk, flags & MSG_DONTWAIT); do { ...
CVE-2021-0920
linux
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux
net/unix/af_unix.c
unix_stream_read_generic
static int unix_stream_read_generic(struct unix_stream_read_state *state, bool freezable) { struct scm_cookie scm; struct socket *sock = state->socket; struct sock *sk = sock->sk; struct unix_sock *u = unix_sk(sk); int copied = 0; int flags = state->flags; int noblock = flags & MSG_DONTWAIT;...
static int unix_stream_read_generic(struct unix_stream_read_state *state, bool freezable) { struct scm_cookie scm; struct socket *sock = state->socket; struct sock *sk = sock->sk; struct unix_sock *u = unix_sk(sk); int copied = 0; int flags = state->flags; int noblock = flags & MSG_DONTWAIT;...
static int unix_stream_read_generic(struct unix_stream_read_state *state, bool freezable) { struct scm_cookie scm; struct socket *sock = state->socket; struct sock *sk = sock->sk; struct unix_sock *u = unix_sk(sk); int copied = 0; int flags = state->flags; int noblock = flags & MSG_DONTWAIT;...
static int unix_stream_read_generic(struct unix_stream_read_state *state, bool freezable) { struct scm_cookie scm; struct socket *sock = state->socket; struct sock *sk = sock->sk; struct unix_sock *u = unix_sk(sk); int copied = 0; int flags = state->flags; int noblock = flags & MSG_DONTWAIT;...
static int unix_stream_read_generic(struct unix_stream_read_state *state, bool freezable) { struct socket *sock = state->socket; struct sock *sk = sock->sk; struct unix_sock *u = unix_sk(sk); int flags = state->flags; int noblock = flags & MSG_DONTWAIT; size_t size = state->size; if (unlikel...
static int unix_stream_read_generic(struct unix_stream_read_state *state, bool freezable) { struct socket *sock = state->socket; struct sock *sk = sock->sk; struct unix_sock *u = unix_sk(sk); int flags = state->flags; int noblock = flags & MSG_DONTWAIT; size_t size = state->size; if (unlikel...
static int unix_stream_read_generic(struct unix_stream_read_state *state, bool freezable) { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ struct socket *sock = state->socket; struct sock *sk = sock->sk; struct unix_sock *u = unix_sk(sk); /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ int flags = ...
static int unix_stream_read_generic(struct unix_stream_read_state *state, bool freezable) { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ struct socket *sock = state->socket; struct sock *sk = sock->sk; struct unix_sock *u = unix_sk(sk); /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ int flags = ...
static int unix_stream_read_generic(struct unix_stream_read_state *state, bool freezable) { struct socket *sock = state->socket; struct sock *sk = sock->sk; struct unix_sock *u = unix_sk(sk); int flags = state->flags; int noblock = flags & MSG_DONTWAIT; size_t size = state->size; if ...
CVE-2021-0935
linux
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux
net/ipv6/datagram.c
__ip6_datagram_connect
int __ip6_datagram_connect(struct sock *sk, struct sockaddr *uaddr, int addr_len) { struct sockaddr_in6 *usin = (struct sockaddr_in6 *) uaddr; struct inet_sock *inet = inet_sk(sk); struct ipv6_pinfo *np = inet6_sk(sk); struct in6_addr *daddr; int addr_type; int err; __be32 fl6_flowlabel = 0;...
int __ip6_datagram_connect(struct sock *sk, struct sockaddr *uaddr, int addr_len) { struct sockaddr_in6 *usin = (struct sockaddr_in6 *) uaddr; struct inet_sock *inet = inet_sk(sk); struct ipv6_pinfo *np = inet6_sk(sk); struct in6_addr *daddr, old_daddr; __be32 fl6_flowlabel = 0; __be32 old_fl6_f...
int __ip6_datagram_connect(struct sock *sk, struct sockaddr *uaddr, int addr_len) { struct sockaddr_in6 *usin = (struct sockaddr_in6 *) uaddr; struct inet_sock *inet = inet_sk(sk); struct ipv6_pinfo *np = inet6_sk(sk); struct in6_addr *daddr; int addr_type; int err; __be32 fl6_flowlabel = 0;...
int __ip6_datagram_connect(struct sock *sk, struct sockaddr *uaddr, int addr_len) { struct sockaddr_in6 *usin = (struct sockaddr_in6 *) uaddr; struct inet_sock *inet = inet_sk(sk); struct ipv6_pinfo *np = inet6_sk(sk); struct in6_addr *daddr, old_daddr; __be32 fl6_flowlabel = 0; __be32 old_fl6_f...
int __ip6_datagram_connect(struct sock *sk, struct sockaddr *uaddr, int addr_len) { struct inet_sock *inet = inet_sk(sk); struct ipv6_pinfo *np = inet6_sk(sk); struct in6_addr *daddr; int addr_type; int err; __be32 fl6_flowlabel = 0; if (usin->sin6_family == AF_ET) { if (__ipv6_only_...
int __ip6_datagram_connect(struct sock *sk, struct sockaddr *uaddr, int addr_len) { struct inet_sock *inet = inet_sk(sk); struct ipv6_pinfo *np = inet6_sk(sk); struct in6_addr *daddr, old_daddr; __be32 fl6_flowlabel = 0; __be32 old_fl6_flowlabel; __be32 old_dport; int addr_type; int err;...
int __ip6_datagram_connect(struct sock *sk, struct sockaddr *uaddr, int addr_len) { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ struct inet_sock *inet = inet_sk(sk); struct ipv6_pinfo *np = inet6_sk(sk); struct in6_addr *daddr; int addr_type; int err; __be32 fl6_flowlabel = 0; if (usin...
int __ip6_datagram_connect(struct sock *sk, struct sockaddr *uaddr, int addr_len) { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ struct inet_sock *inet = inet_sk(sk); struct ipv6_pinfo *np = inet6_sk(sk); struct in6_addr *daddr, old_daddr; __be32 fl6_flowlabel = 0; __be32 old_fl6_flowlabel; ...
int __ip6_datagram_connect(struct sock *sk, struct sockaddr *uaddr, int addr_len) { struct inet_sock *inet = inet_sk(sk); struct ipv6_pinfo *np = inet6_sk(sk); - struct in6_addr *daddr; + struct in6_addr *daddr, old_daddr; + __be32 fl6_flowlabel = 0; + __be32 old_fl6_flowlabel; + __be32 old_dp...
CVE-2021-0937
linux
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux
net/ipv4/netfilter/arp_tables.c
translate_compat_table
static int translate_compat_table(struct net *net, struct xt_table_info **pinfo, void **pentry0, const struct compat_arpt_replace *compatr) { unsigned int i, j; struct xt_table_info *newinfo, *info; void *pos, *entry0, *entry1; struct compat_arpt_entry *iter0; struct arpt_replace repl; unsigned ...
static int translate_compat_table(struct net *net, struct xt_table_info **pinfo, void **pentry0, const struct compat_arpt_replace *compatr) { unsigned int i, j; struct xt_table_info *newinfo, *info; void *pos, *entry0, *entry1; struct compat_arpt_entry *iter0; struct arpt_replace repl; unsigned ...
static int translate_compat_table(struct net *net, struct xt_table_info **pinfo, void **pentry0, const struct compat_arpt_replace *compatr) { unsigned int i, j; struct xt_table_info *newinfo, *info; void *pos, *entry0, *entry1; struct compat_arpt_entry *iter0; struct arpt_replace repl; unsigned ...
static int translate_compat_table(struct net *net, struct xt_table_info **pinfo, void **pentry0, const struct compat_arpt_replace *compatr) { unsigned int i, j; struct xt_table_info *newinfo, *info; void *pos, *entry0, *entry1; struct compat_arpt_entry *iter0; struct arpt_replace repl; unsigned ...
static int translate_compat_table(struct net *net, struct xt_table_info **pinfo, void **pentry0, const struct compat_arpt_replace *compatr) { size = compatr->size; newinfo = xt_alloc_table_info(size); if (!newinfo) { goto out_unlock; } newinfo->number = compatr->num_entries; entry1 = new...
static int translate_compat_table(struct net *net, struct xt_table_info **pinfo, void **pentry0, const struct compat_arpt_replace *compatr) { size = compatr->size; newinfo = xt_alloc_table_info(size); if (!newinfo) { goto out_unlock; } memset(newinfo->entries, 0, size); newinfo->number =...
static int translate_compat_table(struct net *net, struct xt_table_info **pinfo, void **pentry0, const struct compat_arpt_replace *compatr) { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ size = compatr->size; /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ newinfo = xt_alloc_table_info(size); if (!ne...
static int translate_compat_table(struct net *net, struct xt_table_info **pinfo, void **pentry0, const struct compat_arpt_replace *compatr) { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ size = compatr->size; /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ newinfo = xt_alloc_table_info(size); if (!ne...
static int translate_compat_table(struct net *net, struct xt_table_info **pinfo, void **pentry0, const struct compat_arpt_replace *compatr) { size = compatr->size; newinfo = xt_alloc_table_info(size); if (!newinfo) { goto out_unlock; } + memset(newinfo->entries, 0, size); newinfo->...
CVE-2021-0937
linux
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux
net/ipv4/netfilter/ip_tables.c
translate_compat_table
static int translate_compat_table(struct net *net, struct xt_table_info **pinfo, void **pentry0, const struct compat_ipt_replace *compatr) { unsigned int i, j; struct xt_table_info *newinfo, *info; void *pos, *entry0, *entry1; struct compat_ipt_entry *iter0; struct ipt_replace repl; unsigned int...
static int translate_compat_table(struct net *net, struct xt_table_info **pinfo, void **pentry0, const struct compat_ipt_replace *compatr) { unsigned int i, j; struct xt_table_info *newinfo, *info; void *pos, *entry0, *entry1; struct compat_ipt_entry *iter0; struct ipt_replace repl; unsigned int...
static int translate_compat_table(struct net *net, struct xt_table_info **pinfo, void **pentry0, const struct compat_ipt_replace *compatr) { unsigned int i, j; struct xt_table_info *newinfo, *info; void *pos, *entry0, *entry1; struct compat_ipt_entry *iter0; struct ipt_replace repl; unsigned int...
static int translate_compat_table(struct net *net, struct xt_table_info **pinfo, void **pentry0, const struct compat_ipt_replace *compatr) { unsigned int i, j; struct xt_table_info *newinfo, *info; void *pos, *entry0, *entry1; struct compat_ipt_entry *iter0; struct ipt_replace repl; unsigned int...
static int translate_compat_table(struct net *net, struct xt_table_info **pinfo, void **pentry0, const struct compat_ipt_replace *compatr) { size = compatr->size; newinfo = xt_alloc_table_info(size); if (!newinfo) { goto out_unlock; } newinfo->number = compatr->num_entries; entry1 = newi...
static int translate_compat_table(struct net *net, struct xt_table_info **pinfo, void **pentry0, const struct compat_ipt_replace *compatr) { size = compatr->size; newinfo = xt_alloc_table_info(size); if (!newinfo) { goto out_unlock; } memset(newinfo->entries, 0, size); newinfo->number = ...
static int translate_compat_table(struct net *net, struct xt_table_info **pinfo, void **pentry0, const struct compat_ipt_replace *compatr) { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ size = compatr->size; /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ newinfo = xt_alloc_table_info(size); if (!new...
static int translate_compat_table(struct net *net, struct xt_table_info **pinfo, void **pentry0, const struct compat_ipt_replace *compatr) { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ size = compatr->size; /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ newinfo = xt_alloc_table_info(size); if (!new...
static int translate_compat_table(struct net *net, struct xt_table_info **pinfo, void **pentry0, const struct compat_ipt_replace *compatr) { size = compatr->size; newinfo = xt_alloc_table_info(size); if (!newinfo) { goto out_unlock; } + memset(newinfo->entries, 0, size); newinfo->n...
CVE-2021-0937
linux
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux
net/ipv6/netfilter/ip6_tables.c
translate_compat_table
static int translate_compat_table(struct net *net, struct xt_table_info **pinfo, void **pentry0, const struct compat_ip6t_replace *compatr) { unsigned int i, j; struct xt_table_info *newinfo, *info; void *pos, *entry0, *entry1; struct compat_ip6t_entry *iter0; struct ip6t_replace repl; unsigned ...
static int translate_compat_table(struct net *net, struct xt_table_info **pinfo, void **pentry0, const struct compat_ip6t_replace *compatr) { unsigned int i, j; struct xt_table_info *newinfo, *info; void *pos, *entry0, *entry1; struct compat_ip6t_entry *iter0; struct ip6t_replace repl; unsigned ...
static int translate_compat_table(struct net *net, struct xt_table_info **pinfo, void **pentry0, const struct compat_ip6t_replace *compatr) { unsigned int i, j; struct xt_table_info *newinfo, *info; void *pos, *entry0, *entry1; struct compat_ip6t_entry *iter0; struct ip6t_replace repl; unsigned ...
static int translate_compat_table(struct net *net, struct xt_table_info **pinfo, void **pentry0, const struct compat_ip6t_replace *compatr) { unsigned int i, j; struct xt_table_info *newinfo, *info; void *pos, *entry0, *entry1; struct compat_ip6t_entry *iter0; struct ip6t_replace repl; unsigned ...
static int translate_compat_table(struct net *net, struct xt_table_info **pinfo, void **pentry0, const struct compat_ip6t_replace *compatr) { size = compatr->size; newinfo = xt_alloc_table_info(size); if (!newinfo) { goto out_unlock; } newinfo->number = compatr->num_entries; entry1 = new...
static int translate_compat_table(struct net *net, struct xt_table_info **pinfo, void **pentry0, const struct compat_ip6t_replace *compatr) { size = compatr->size; newinfo = xt_alloc_table_info(size); if (!newinfo) { goto out_unlock; } memset(newinfo->entries, 0, size); newinfo->number =...
static int translate_compat_table(struct net *net, struct xt_table_info **pinfo, void **pentry0, const struct compat_ip6t_replace *compatr) { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ size = compatr->size; /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ newinfo = xt_alloc_table_info(size); if (!ne...
static int translate_compat_table(struct net *net, struct xt_table_info **pinfo, void **pentry0, const struct compat_ip6t_replace *compatr) { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ size = compatr->size; /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ newinfo = xt_alloc_table_info(size); if (!ne...
static int translate_compat_table(struct net *net, struct xt_table_info **pinfo, void **pentry0, const struct compat_ip6t_replace *compatr) { size = compatr->size; newinfo = xt_alloc_table_info(size); if (!newinfo) { goto out_unlock; } + memset(newinfo->entries, 0, size); newinfo->...
CVE-2021-0937
linux
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux
net/netfilter/x_tables.c
xt_compat_match_from_user
void xt_compat_match_from_user(struct xt_entry_match *m, void **dstptr, unsigned int *size) { const struct xt_match *match = m->u.kernel.match; struct compat_xt_entry_match *cm = (struct compat_xt_entry_match *)m; int pad, off = xt_compat_match_offset(match); u_int16_t msize = cm->u.user.match_size; ...
void xt_compat_match_from_user(struct xt_entry_match *m, void **dstptr, unsigned int *size) { const struct xt_match *match = m->u.kernel.match; struct compat_xt_entry_match *cm = (struct compat_xt_entry_match *)m; int off = xt_compat_match_offset(match); u_int16_t msize = cm->u.user.match_size; char...
void xt_compat_match_from_user(struct xt_entry_match *m, void **dstptr, unsigned int *size) { const struct xt_match *match = m->u.kernel.match; struct compat_xt_entry_match *cm = (struct compat_xt_entry_match *)m; int pad, off = xt_compat_match_offset(match); u_int16_t msize = cm->u.user.match_size; ...
void xt_compat_match_from_user(struct xt_entry_match *m, void **dstptr, unsigned int *size) { const struct xt_match *match = m->u.kernel.match; struct compat_xt_entry_match *cm = (struct compat_xt_entry_match *)m; int off = xt_compat_match_offset(match); u_int16_t msize = cm->u.user.match_size; char...
void xt_compat_match_from_user(struct xt_entry_match *m, void **dstptr, unsigned int *size) { const struct xt_match *match = m->u.kernel.match; struct compat_xt_entry_match *cm = (struct compat_xt_entry_match *)m; int pad, off = xt_compat_match_offset(match); u_int16_t msize = cm->u.user.match_size; ...
void xt_compat_match_from_user(struct xt_entry_match *m, void **dstptr, unsigned int *size) { const struct xt_match *match = m->u.kernel.match; struct compat_xt_entry_match *cm = (struct compat_xt_entry_match *)m; int off = xt_compat_match_offset(match); u_int16_t msize = cm->u.user.match_size; m = ...
void xt_compat_match_from_user(struct xt_entry_match *m, void **dstptr, unsigned int *size) { const struct xt_match *match = m->u.kernel.match; struct compat_xt_entry_match *cm = (struct compat_xt_entry_match *)m; int pad, off = xt_compat_match_offset(match); u_int16_t msize = cm->u.user.match_size; ...
void xt_compat_match_from_user(struct xt_entry_match *m, void **dstptr, unsigned int *size) { const struct xt_match *match = m->u.kernel.match; struct compat_xt_entry_match *cm = (struct compat_xt_entry_match *)m; int off = xt_compat_match_offset(match); u_int16_t msize = cm->u.user.match_size; /* P...
void xt_compat_match_from_user(struct xt_entry_match *m, void **dstptr, unsigned int *size) { const struct xt_match *match = m->u.kernel.match; struct compat_xt_entry_match *cm = (struct compat_xt_entry_match *)m; - int pad, off = xt_compat_match_offset(match); + int off = xt_compat_match_offset(match)...
CVE-2021-0937
linux
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux
net/netfilter/x_tables.c
xt_compat_target_from_user
void xt_compat_target_from_user(struct xt_entry_target *t, void **dstptr, unsigned int *size) { const struct xt_target *target = t->u.kernel.target; struct compat_xt_entry_target *ct = (struct compat_xt_entry_target *)t; int pad, off = xt_compat_target_offset(target); u_int16_t tsize = ct->u.user.target...
void xt_compat_target_from_user(struct xt_entry_target *t, void **dstptr, unsigned int *size) { const struct xt_target *target = t->u.kernel.target; struct compat_xt_entry_target *ct = (struct compat_xt_entry_target *)t; int off = xt_compat_target_offset(target); u_int16_t tsize = ct->u.user.target_size...
void xt_compat_target_from_user(struct xt_entry_target *t, void **dstptr, unsigned int *size) { const struct xt_target *target = t->u.kernel.target; struct compat_xt_entry_target *ct = (struct compat_xt_entry_target *)t; int pad, off = xt_compat_target_offset(target); u_int16_t tsize = ct->u.user.target...
void xt_compat_target_from_user(struct xt_entry_target *t, void **dstptr, unsigned int *size) { const struct xt_target *target = t->u.kernel.target; struct compat_xt_entry_target *ct = (struct compat_xt_entry_target *)t; int off = xt_compat_target_offset(target); u_int16_t tsize = ct->u.user.target_size...
void xt_compat_target_from_user(struct xt_entry_target *t, void **dstptr, unsigned int *size) { const struct xt_target *target = t->u.kernel.target; struct compat_xt_entry_target *ct = (struct compat_xt_entry_target *)t; int pad, off = xt_compat_target_offset(target); u_int16_t tsize = ct->u.user.target...
void xt_compat_target_from_user(struct xt_entry_target *t, void **dstptr, unsigned int *size) { const struct xt_target *target = t->u.kernel.target; struct compat_xt_entry_target *ct = (struct compat_xt_entry_target *)t; int off = xt_compat_target_offset(target); u_int16_t tsize = ct->u.user.target_size...
void xt_compat_target_from_user(struct xt_entry_target *t, void **dstptr, unsigned int *size) { const struct xt_target *target = t->u.kernel.target; struct compat_xt_entry_target *ct = (struct compat_xt_entry_target *)t; int pad, off = xt_compat_target_offset(target); u_int16_t tsize = ct->u.user.target...
void xt_compat_target_from_user(struct xt_entry_target *t, void **dstptr, unsigned int *size) { const struct xt_target *target = t->u.kernel.target; struct compat_xt_entry_target *ct = (struct compat_xt_entry_target *)t; int off = xt_compat_target_offset(target); u_int16_t tsize = ct->u.user.target_size...
void xt_compat_target_from_user(struct xt_entry_target *t, void **dstptr, unsigned int *size) { const struct xt_target *target = t->u.kernel.target; struct compat_xt_entry_target *ct = (struct compat_xt_entry_target *)t; - int pad, off = xt_compat_target_offset(target); + int off = xt_compat_target_off...
CVE-2021-1048
linux
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux
fs/eventpoll.c
ep_loop_check_proc
static int ep_loop_check_proc(void *priv, void *cookie, int call_nests) { int error = 0; struct file *file = priv; struct eventpoll *ep = file->private_data; struct eventpoll *ep_tovisit; struct rb_node *rbp; struct epitem *epi; mutex_lock_nested(&ep->mtx, call_nests + 1); ep->visited = ...
static int ep_loop_check_proc(void *priv, void *cookie, int call_nests) { int error = 0; struct file *file = priv; struct eventpoll *ep = file->private_data; struct eventpoll *ep_tovisit; struct rb_node *rbp; struct epitem *epi; mutex_lock_nested(&ep->mtx, call_nests + 1); ep->visited = ...
static int ep_loop_check_proc(void *priv, void *cookie, int call_nests) { int error = 0; struct file *file = priv; struct eventpoll *ep = file->private_data; struct eventpoll *ep_tovisit; struct rb_node *rbp; struct epitem *epi; mutex_lock_nested(&ep->mtx, call_nests + 1); ep->visited = ...
static int ep_loop_check_proc(void *priv, void *cookie, int call_nests) { int error = 0; struct file *file = priv; struct eventpoll *ep = file->private_data; struct eventpoll *ep_tovisit; struct rb_node *rbp; struct epitem *epi; mutex_lock_nested(&ep->mtx, call_nests + 1); ep->visited = ...
static int ep_loop_check_proc(void *priv, void *cookie, int call_nests) { for (rbp = rb_first_cached(&ep->rbr); rbp; rbp = rb_next(rbp)) { if (unlikely(is_file_epoll(epi->ffd.file))) { } else { if (list_empty(&epi->ffd.file->f_tfile_llink)) { get_file(epi->ffd.file); ...
static int ep_loop_check_proc(void *priv, void *cookie, int call_nests) { for (rbp = rb_first_cached(&ep->rbr); rbp; rbp = rb_next(rbp)) { if (unlikely(is_file_epoll(epi->ffd.file))) { } else { if (list_empty(&epi->ffd.file->f_tfile_llink)) { if (get_file_rcu(epi->ffd.fil...
static int ep_loop_check_proc(void *priv, void *cookie, int call_nests) { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ for (rbp = rb_first(&ep->rbr); rbp; rbp = rb_next(rbp)) { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ if (unlikely(is_file_epoll(epi->ffd.file))) { /* PLACEHOLDER: DO NOT DEL...
static int ep_loop_check_proc(void *priv, void *cookie, int call_nests) { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ for (rbp = rb_first(&ep->rbr); rbp; rbp = rb_next(rbp)) { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ if (unlikely(is_file_epoll(epi->ffd.file))) { /* PLACEHOLDER: DO NOT DEL...
static int ep_loop_check_proc(void *priv, void *cookie, int call_nests) { for (rbp = rb_first_cached(&ep->rbr); rbp; rbp = rb_next(rbp)) { if (unlikely(is_file_epoll(epi->ffd.file))) { } else { if (list_empty(&epi->ffd.file->f_tfile_llink)) { - get_file(epi->ffd.file)...
CVE-2021-20265
linux
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux
net/unix/af_unix.c
unix_stream_recvmsg
static int unix_stream_recvmsg(struct kiocb *iocb, struct socket *sock, struct msghdr *msg, size_t size, int flags) { struct sock_iocb *siocb = kiocb_to_siocb(iocb); struct scm_cookie tmp_scm; struct sock *sk = sock->sk; struct unix_sock *u = unix_sk(sk); DECLARE_SOCKADDR(struct sockaddr_un *, sunad...
static int unix_stream_recvmsg(struct kiocb *iocb, struct socket *sock, struct msghdr *msg, size_t size, int flags) { struct sock_iocb *siocb = kiocb_to_siocb(iocb); struct scm_cookie tmp_scm; struct sock *sk = sock->sk; struct unix_sock *u = unix_sk(sk); DECLARE_SOCKADDR(struct sockaddr_un *, sunad...
static int unix_stream_recvmsg(struct socket *sock, struct msghdr *msg, size_t size, int flags) { struct scm_cookie scm; struct sock *sk = sock->sk; struct unix_sock *u = unix_sk(sk); DECLARE_SOCKADDR(struct sockaddr_un *, sunaddr, msg->msg_name); int copied = 0; int noblock = flags & MSG_DONTWA...
static int unix_stream_recvmsg(struct socket *sock, struct msghdr *msg, size_t size, int flags) { struct scm_cookie scm; struct sock *sk = sock->sk; struct unix_sock *u = unix_sk(sk); DECLARE_SOCKADDR(struct sockaddr_un *, sunaddr, msg->msg_name); int copied = 0; int noblock = flags & MSG_DONTWA...
static int unix_stream_recvmsg(struct kiocb *iocb, struct socket *sock, struct msghdr *msg, size_t size, int flags) { struct sock_iocb *siocb = kiocb_to_siocb(iocb); if (!siocb->scm) { siocb->scm = &tmp_scm; } do { int chunk; struct sk_buff *skb, *last; unix_state_lock(sk...
static int unix_stream_recvmsg(struct kiocb *iocb, struct socket *sock, struct msghdr *msg, size_t size, int flags) { struct sock_iocb *siocb = kiocb_to_siocb(iocb); if (!siocb->scm) { siocb->scm = &tmp_scm; } do { int chunk; struct sk_buff *skb, *last; unix_state_lock(sk...
static int unix_stream_recvmsg(struct socket *sock, struct msghdr *msg, size_t size, int flags) { struct scm_cookie scm; /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ memset(&scm, 0, sizeof(scm)); /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ do { int chunk; struct sk_buff *skb, *las...
static int unix_stream_recvmsg(struct socket *sock, struct msghdr *msg, size_t size, int flags) { struct scm_cookie scm; /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ memset(&scm, 0, sizeof(scm)); /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ do { int chunk; struct sk_buff *skb, *las...
static int unix_stream_recvmsg(struct kiocb *iocb, struct socket *sock, struct msghdr *msg, size_t size, int flags) { struct sock_iocb *siocb = kiocb_to_siocb(iocb); if (!siocb->scm) { siocb->scm = &tmp_scm; } do { int chunk; struct sk_buff *skb, *last; unix_stat...
CVE-2021-20292
linux
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux
drivers/gpu/drm/nouveau/nouveau_sgdma.c
nouveau_sgdma_create_ttm
struct ttm_tt * nouveau_sgdma_create_ttm(struct ttm_buffer_object *bo, uint32_t page_flags) { struct nouveau_drm *drm = nouveau_bdev(bo->bdev); struct nouveau_sgdma_be *nvbe; nvbe = kzalloc(sizeof(*nvbe), GFP_KERNEL); if (!nvbe) { return NULL; } if (drm->client.device.info.family < NV_DE...
struct ttm_tt * nouveau_sgdma_create_ttm(struct ttm_buffer_object *bo, uint32_t page_flags) { struct nouveau_drm *drm = nouveau_bdev(bo->bdev); struct nouveau_sgdma_be *nvbe; nvbe = kzalloc(sizeof(*nvbe), GFP_KERNEL); if (!nvbe) { return NULL; } if (drm->client.device.info.family < NV_DE...
struct ttm_tt * nouveau_sgdma_create_ttm(struct ttm_bo_device *bdev, unsigned long size, uint32_t page_flags, struct page *dummy_read_page) { struct nouveau_drm *drm = nouveau_bdev(bdev); struct nouveau_sgdma_be *nvbe; nvbe = kzalloc(sizeof(*nvbe), GFP_KERNEL); if (!nvbe) { return NULL; } ...
struct ttm_tt * nouveau_sgdma_create_ttm(struct ttm_bo_device *bdev, unsigned long size, uint32_t page_flags, struct page *dummy_read_page) { struct nouveau_drm *drm = nouveau_bdev(bdev); struct nouveau_sgdma_be *nvbe; nvbe = kzalloc(sizeof(*nvbe), GFP_KERNEL); if (!nvbe) { return NULL; } ...
struct ttm_tt * nouveau_sgdma_create_ttm(struct ttm_buffer_object *bo, uint32_t page_flags) { nvbe = kzalloc(sizeof(*nvbe), GFP_KERNEL); if (!nvbe) { return NULL; } if (ttm_dma_tt_init(&nvbe->ttm, bo, page_flags)) { return NULL; } }
struct ttm_tt * nouveau_sgdma_create_ttm(struct ttm_buffer_object *bo, uint32_t page_flags) { nvbe = kzalloc(sizeof(*nvbe), GFP_KERNEL); if (!nvbe) { return NULL; } if (ttm_dma_tt_init(&nvbe->ttm, bo, page_flags)) { kfree(nvbe); return NULL; } }
struct ttm_tt * nouveau_sgdma_create_ttm(struct ttm_bo_device *bdev, unsigned long size, uint32_t page_flags, struct page *dummy_read_page) { struct nouveau_drm *drm = nouveau_bdev(bdev); /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ nvbe = kzalloc(sizeof(*nvbe), GFP_KERNEL); if (!nvbe) { return...
struct ttm_tt * nouveau_sgdma_create_ttm(struct ttm_bo_device *bdev, unsigned long size, uint32_t page_flags, struct page *dummy_read_page) { struct nouveau_drm *drm = nouveau_bdev(bdev); /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ nvbe = kzalloc(sizeof(*nvbe), GFP_KERNEL); if (!nvbe) { return...
struct ttm_tt * nouveau_sgdma_create_ttm(struct ttm_buffer_object *bo, uint32_t page_flags) { nvbe = kzalloc(sizeof(*nvbe), GFP_KERNEL); if (!nvbe) { return NULL; } if (ttm_dma_tt_init(&nvbe->ttm, bo, page_flags)) { + kfree(nvbe); return NULL; } }
CVE-2021-20292
linux
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux
drivers/gpu/drm/ttm/ttm_tt.c
ttm_dma_tt_init
int ttm_dma_tt_init(struct ttm_dma_tt *ttm_dma, struct ttm_buffer_object *bo, uint32_t page_flags) { struct ttm_tt *ttm = &ttm_dma->ttm; ttm_tt_init_fields(ttm, bo, page_flags); IT_LIST_HEAD(&ttm_dma->pages_list); if (ttm_dma_tt_alloc_page_directory(ttm_dma)) { ttm_tt_destroy(ttm); pr_er...
int ttm_dma_tt_init(struct ttm_dma_tt *ttm_dma, struct ttm_buffer_object *bo, uint32_t page_flags) { struct ttm_tt *ttm = &ttm_dma->ttm; ttm_tt_init_fields(ttm, bo, page_flags); IT_LIST_HEAD(&ttm_dma->pages_list); if (ttm_dma_tt_alloc_page_directory(ttm_dma)) { pr_err("Failed allocating page tab...
int ttm_dma_tt_init(struct ttm_dma_tt *ttm_dma, struct ttm_bo_device *bdev, unsigned long size, uint32_t page_flags, struct page *dummy_read_page) { struct ttm_tt *ttm = &ttm_dma->ttm; ttm->bdev = bdev; ttm->glob = bdev->glob; ttm->num_pages = (size + PAGE_SIZE - 1) >> PAGE_SHIFT; ttm->caching_state...
int ttm_dma_tt_init(struct ttm_dma_tt *ttm_dma, struct ttm_bo_device *bdev, unsigned long size, uint32_t page_flags, struct page *dummy_read_page) { struct ttm_tt *ttm = &ttm_dma->ttm; ttm->bdev = bdev; ttm->glob = bdev->glob; ttm->num_pages = (size + PAGE_SIZE - 1) >> PAGE_SHIFT; ttm->caching_state...
int ttm_dma_tt_init(struct ttm_dma_tt *ttm_dma, struct ttm_buffer_object *bo, uint32_t page_flags) { struct ttm_tt *ttm = &ttm_dma->ttm; ttm_tt_init_fields(ttm, bo, page_flags); if (ttm_dma_tt_alloc_page_directory(ttm_dma)) { ttm_tt_destroy(ttm); pr_err("Failed allocating page table\n"); ...
int ttm_dma_tt_init(struct ttm_dma_tt *ttm_dma, struct ttm_buffer_object *bo, uint32_t page_flags) { struct ttm_tt *ttm = &ttm_dma->ttm; ttm_tt_init_fields(ttm, bo, page_flags); if (ttm_dma_tt_alloc_page_directory(ttm_dma)) { pr_err("Failed allocating page table\n"); return -ENOMEM; } }
int ttm_dma_tt_init(struct ttm_dma_tt *ttm_dma, struct ttm_bo_device *bdev, unsigned long size, uint32_t page_flags, struct page *dummy_read_page) { struct ttm_tt *ttm = &ttm_dma->ttm; ttm->bdev = bdev; ttm->glob = bdev->glob; ttm->num_pages = (size + PAGE_SIZE - 1) >> PAGE_SHIFT; ttm->caching_state...
int ttm_dma_tt_init(struct ttm_dma_tt *ttm_dma, struct ttm_bo_device *bdev, unsigned long size, uint32_t page_flags, struct page *dummy_read_page) { struct ttm_tt *ttm = &ttm_dma->ttm; ttm->bdev = bdev; ttm->glob = bdev->glob; ttm->num_pages = (size + PAGE_SIZE - 1) >> PAGE_SHIFT; ttm->caching_state...
int ttm_dma_tt_init(struct ttm_dma_tt *ttm_dma, struct ttm_buffer_object *bo, uint32_t page_flags) { struct ttm_tt *ttm = &ttm_dma->ttm; ttm_tt_init_fields(ttm, bo, page_flags); if (ttm_dma_tt_alloc_page_directory(ttm_dma)) { - ttm_tt_destroy(ttm); pr_err("Failed allocating page table\n"...
CVE-2021-20292
linux
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux
drivers/gpu/drm/ttm/ttm_tt.c
ttm_tt_init
int ttm_tt_init(struct ttm_tt *ttm, struct ttm_buffer_object *bo, uint32_t page_flags) { ttm_tt_init_fields(ttm, bo, page_flags); if (ttm_tt_alloc_page_directory(ttm)) { ttm_tt_destroy(ttm); pr_err("Failed allocating page table\n"); return -ENOMEM; } return 0; }
int ttm_tt_init(struct ttm_tt *ttm, struct ttm_buffer_object *bo, uint32_t page_flags) { ttm_tt_init_fields(ttm, bo, page_flags); if (ttm_tt_alloc_page_directory(ttm)) { pr_err("Failed allocating page table\n"); return -ENOMEM; } return 0; }
int ttm_tt_init(struct ttm_tt *ttm, struct ttm_bo_device *bdev, unsigned long size, uint32_t page_flags, struct page *dummy_read_page) { ttm->bdev = bdev; ttm->glob = bdev->glob; ttm->num_pages = (size + PAGE_SIZE - 1) >> PAGE_SHIFT; ttm->caching_state = tt_cached; ttm->page_flags = page_flags; ...
int ttm_tt_init(struct ttm_tt *ttm, struct ttm_bo_device *bdev, unsigned long size, uint32_t page_flags, struct page *dummy_read_page) { ttm->bdev = bdev; ttm->glob = bdev->glob; ttm->num_pages = (size + PAGE_SIZE - 1) >> PAGE_SHIFT; ttm->caching_state = tt_cached; ttm->page_flags = page_flags; ...
int ttm_tt_init(struct ttm_tt *ttm, struct ttm_buffer_object *bo, uint32_t page_flags) { ttm_tt_init_fields(ttm, bo, page_flags); if (ttm_tt_alloc_page_directory(ttm)) { ttm_tt_destroy(ttm); pr_err("Failed allocating page table\n"); return -ENOMEM; } return 0; }
int ttm_tt_init(struct ttm_tt *ttm, struct ttm_buffer_object *bo, uint32_t page_flags) { ttm_tt_init_fields(ttm, bo, page_flags); if (ttm_tt_alloc_page_directory(ttm)) { pr_err("Failed allocating page table\n"); return -ENOMEM; } return 0; }
int ttm_tt_init(struct ttm_tt *ttm, struct ttm_bo_device *bdev, unsigned long size, uint32_t page_flags, struct page *dummy_read_page) { ttm->bdev = bdev; ttm->glob = bdev->glob; ttm->num_pages = (size + PAGE_SIZE - 1) >> PAGE_SHIFT; ttm->caching_state = tt_cached; ttm->page_flags = page_flags; ...
int ttm_tt_init(struct ttm_tt *ttm, struct ttm_bo_device *bdev, unsigned long size, uint32_t page_flags, struct page *dummy_read_page) { ttm->bdev = bdev; ttm->glob = bdev->glob; ttm->num_pages = (size + PAGE_SIZE - 1) >> PAGE_SHIFT; ttm->caching_state = tt_cached; ttm->page_flags = page_flags; ...
int ttm_tt_init(struct ttm_tt *ttm, struct ttm_buffer_object *bo, uint32_t page_flags) { ttm_tt_init_fields(ttm, bo, page_flags); if (ttm_tt_alloc_page_directory(ttm)) { - ttm_tt_destroy(ttm); pr_err("Failed allocating page table\n"); return -ENOMEM; } return 0; }
CVE-2021-20317
linux
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux
include/linux/timerqueue.h
timerqueue_getnext
static inline struct timerqueue_node *timerqueue_getnext(struct timerqueue_head *head) { return head->next; }
static inline struct timerqueue_node *timerqueue_getnext(struct timerqueue_head *head) { struct rb_node *leftmost = rb_first_cached(&head->rb_root); return rb_entry(leftmost, struct timerqueue_node, node); }
static inline struct timerqueue_node *timerqueue_getnext(struct timerqueue_head *head) { return head->next; }
static inline struct timerqueue_node *timerqueue_getnext(struct timerqueue_head *head) { struct rb_node *leftmost = rb_first_cached(&head->rb_root); return rb_entry(leftmost, struct timerqueue_node, node); }
static inline struct timerqueue_node *timerqueue_getnext(struct timerqueue_head *head) { return head->next; }
static inline struct timerqueue_node *timerqueue_getnext(struct timerqueue_head *head) { struct rb_node *leftmost = rb_first_cached(&head->rb_root); return rb_entry(leftmost, struct timerqueue_node, node); }
static inline struct timerqueue_node *timerqueue_getnext(struct timerqueue_head *head) { return head->next; }
static inline struct timerqueue_node *timerqueue_getnext(struct timerqueue_head *head) { struct rb_node *leftmost = rb_first_cached(&head->rb_root); return rb_entry(leftmost, struct timerqueue_node, node); }
static inline struct timerqueue_node *timerqueue_getnext(struct timerqueue_head *head) { - return head->next; + struct rb_node *leftmost = rb_first_cached(&head->rb_root); + return rb_entry(leftmost, struct timerqueue_node, node); }
CVE-2021-20317
linux
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux
include/linux/timerqueue.h
timerqueue_init_head
static inline void timerqueue_init_head(struct timerqueue_head *head) { head->head = RB_ROOT; head->next = NULL; }
static inline void timerqueue_init_head(struct timerqueue_head *head) { head->rb_root = RB_ROOT_CACHED; }
static inline void timerqueue_init_head(struct timerqueue_head *head) { head->head = RB_ROOT; head->next = NULL; }
static inline void timerqueue_init_head(struct timerqueue_head *head) { head->rb_root = RB_ROOT_CACHED; }
static inline void timerqueue_init_head(struct timerqueue_head *head) { head->head = RB_ROOT; head->next = NULL; }
static inline void timerqueue_init_head(struct timerqueue_head *head) { head->rb_root = RB_ROOT_CACHED; }
static inline void timerqueue_init_head(struct timerqueue_head *head) { head->head = RB_ROOT; head->next = NULL; }
static inline void timerqueue_init_head(struct timerqueue_head *head) { head->rb_root = RB_ROOT_CACHED; }
static inline void timerqueue_init_head(struct timerqueue_head *head) { - head->head = RB_ROOT; - head->next = NULL; + head->rb_root = RB_ROOT_CACHED; }
CVE-2021-20317
linux
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux
lib/timerqueue.c
timerqueue_add
bool timerqueue_add(struct timerqueue_head *head, struct timerqueue_node *node) { struct rb_node **p = &head->head.rb_node; struct rb_node *parent = NULL; struct timerqueue_node *ptr; WARN_ON_ONCE(!RB_EMPTY_NODE(&node->node)); while (*p) { parent = *p; ptr = rb_entry(parent, struct t...
bool timerqueue_add(struct timerqueue_head *head, struct timerqueue_node *node) { struct rb_node **p = &head->rb_root.rb_root.rb_node; struct rb_node *parent = NULL; struct timerqueue_node *ptr; bool leftmost = true; WARN_ON_ONCE(!RB_EMPTY_NODE(&node->node)); while (*p) { parent = *p; ...
bool timerqueue_add(struct timerqueue_head *head, struct timerqueue_node *node) { struct rb_node **p = &head->head.rb_node; struct rb_node *parent = NULL; struct timerqueue_node *ptr; WARN_ON_ONCE(!RB_EMPTY_NODE(&node->node)); while (*p) { parent = *p; ptr = rb_entry(parent, struct t...
bool timerqueue_add(struct timerqueue_head *head, struct timerqueue_node *node) { struct rb_node **p = &head->rb_root.rb_root.rb_node; struct rb_node *parent = NULL; struct timerqueue_node *ptr; bool leftmost = true; WARN_ON_ONCE(!RB_EMPTY_NODE(&node->node)); while (*p) { parent = *p; ...
bool timerqueue_add(struct timerqueue_head *head, struct timerqueue_node *node) { struct rb_node **p = &head->head.rb_node; struct rb_node *parent = NULL; struct timerqueue_node *ptr; WARN_ON_ONCE(!RB_EMPTY_NODE(&node->node)); while (*p) { parent = *p; ptr = rb_entry(parent, struct t...
bool timerqueue_add(struct timerqueue_head *head, struct timerqueue_node *node) { struct rb_node **p = &head->rb_root.rb_root.rb_node; struct rb_node *parent = NULL; struct timerqueue_node *ptr; bool leftmost = true; WARN_ON_ONCE(!RB_EMPTY_NODE(&node->node)); while (*p) { parent = *p; ...
bool timerqueue_add(struct timerqueue_head *head, struct timerqueue_node *node) { struct rb_node **p = &head->head.rb_node; struct rb_node *parent = NULL; struct timerqueue_node *ptr; WARN_ON_ONCE(!RB_EMPTY_NODE(&node->node)); while (*p) { parent = *p; ptr = rb_entry(parent, struct t...
bool timerqueue_add(struct timerqueue_head *head, struct timerqueue_node *node) { struct rb_node **p = &head->rb_root.rb_root.rb_node; struct rb_node *parent = NULL; struct timerqueue_node *ptr; bool leftmost = true; WARN_ON_ONCE(!RB_EMPTY_NODE(&node->node)); while (*p) { parent = *p; ...
bool timerqueue_add(struct timerqueue_head *head, struct timerqueue_node *node) { - struct rb_node **p = &head->head.rb_node; + struct rb_node **p = &head->rb_root.rb_root.rb_node; struct rb_node *parent = NULL; struct timerqueue_node *ptr; + bool leftmost = true; WARN_ON_ONCE(!RB_EMPTY_NODE(&n...
CVE-2021-20317
linux
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux
lib/timerqueue.c
timerqueue_del
bool timerqueue_del(struct timerqueue_head *head, struct timerqueue_node *node) { WARN_ON_ONCE(RB_EMPTY_NODE(&node->node)); if (head->next == node) { struct rb_node *rbn = rb_next(&node->node); head->next = rb_entry_safe(rbn, struct timerqueue_node, node); } rb_erase(&node->node, &head->...
bool timerqueue_del(struct timerqueue_head *head, struct timerqueue_node *node) { WARN_ON_ONCE(RB_EMPTY_NODE(&node->node)); rb_erase_cached(&node->node, &head->rb_root); RB_CLEAR_NODE(&node->node); return !RB_EMPTY_ROOT(&head->rb_root.rb_root); }
bool timerqueue_del(struct timerqueue_head *head, struct timerqueue_node *node) { WARN_ON_ONCE(RB_EMPTY_NODE(&node->node)); if (head->next == node) { struct rb_node *rbn = rb_next(&node->node); head->next = rbn ? rb_entry(rbn, struct timerqueue_node, node) : NULL; } rb_erase(&node->node,...
bool timerqueue_del(struct timerqueue_head *head, struct timerqueue_node *node) { WARN_ON_ONCE(RB_EMPTY_NODE(&node->node)); rb_erase_cached(&node->node, &head->rb_root); RB_CLEAR_NODE(&node->node); return !RB_EMPTY_ROOT(&head->rb_root.rb_root); }
bool timerqueue_del(struct timerqueue_head *head, struct timerqueue_node *node) { WARN_ON_ONCE(RB_EMPTY_NODE(&node->node)); if (head->next == node) { struct rb_node *rbn = rb_next(&node->node); head->next = rb_entry_safe(rbn, struct timerqueue_node, node); } rb_erase(&node->node, &head->...
bool timerqueue_del(struct timerqueue_head *head, struct timerqueue_node *node) { WARN_ON_ONCE(RB_EMPTY_NODE(&node->node)); rb_erase_cached(&node->node, &head->rb_root); RB_CLEAR_NODE(&node->node); return !RB_EMPTY_ROOT(&head->rb_root.rb_root); }
bool timerqueue_del(struct timerqueue_head *head, struct timerqueue_node *node) { WARN_ON_ONCE(RB_EMPTY_NODE(&node->node)); if (head->next == node) { struct rb_node *rbn = rb_next(&node->node); head->next = rbn ? rb_entry(rbn, struct timerqueue_node, node) : NULL; } rb_erase(&node->node,...
bool timerqueue_del(struct timerqueue_head *head, struct timerqueue_node *node) { WARN_ON_ONCE(RB_EMPTY_NODE(&node->node)); rb_erase_cached(&node->node, &head->rb_root); RB_CLEAR_NODE(&node->node); return !RB_EMPTY_ROOT(&head->rb_root.rb_root); }
bool timerqueue_del(struct timerqueue_head *head, struct timerqueue_node *node) { WARN_ON_ONCE(RB_EMPTY_NODE(&node->node)); - if (head->next == node) { - struct rb_node *rbn = rb_next(&node->node); - head->next = rb_entry_safe(rbn, struct timerqueue_node, node); - } - rb_erase(&node->node, ...
CVE-2021-20322
linux
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux
net/ipv6/route.c
rt6_insert_exception
static int rt6_insert_exception(struct rt6_info *nrt, const struct fib6_result *res) { struct net *net = dev_net(nrt->dst.dev); struct rt6_exception_bucket *bucket; struct fib6_info *f6i = res->f6i; struct in6_addr *src_key = NULL; struct rt6_exception *rt6_ex; struct fib6_nh *nh = res->nh; ...
static int rt6_insert_exception(struct rt6_info *nrt, const struct fib6_result *res) { struct net *net = dev_net(nrt->dst.dev); struct rt6_exception_bucket *bucket; struct fib6_info *f6i = res->f6i; struct in6_addr *src_key = NULL; struct rt6_exception *rt6_ex; struct fib6_nh *nh = res->nh; ...
static int rt6_insert_exception(struct rt6_info *nrt, struct fib6_info *ort) { struct net *net = dev_net(nrt->dst.dev); struct rt6_exception_bucket *bucket; struct in6_addr *src_key = NULL; struct rt6_exception *rt6_ex; int err = 0; spin_lock_bh(&rt6_exception_lock); if (ort->exception_bucke...
static int rt6_insert_exception(struct rt6_info *nrt, struct fib6_info *ort) { struct net *net = dev_net(nrt->dst.dev); struct rt6_exception_bucket *bucket; struct in6_addr *src_key = NULL; struct rt6_exception *rt6_ex; int max_depth; int err = 0; spin_lock_bh(&rt6_exception_lock); if (o...
static int rt6_insert_exception(struct rt6_info *nrt, const struct fib6_result *res) { struct in6_addr *src_key = NULL; struct fib6_nh *nh = res->nh; int err = 0; bucket = rcu_dereference_protected(nh->rt6i_exception_bucket, lockdep_is_held(&rt6_exception_lock)); if (!bucket) { bucket = kcal...
static int rt6_insert_exception(struct rt6_info *nrt, const struct fib6_result *res) { struct in6_addr *src_key = NULL; struct fib6_nh *nh = res->nh; int max_depth; int err = 0; bucket = rcu_dereference_protected(nh->rt6i_exception_bucket, lockdep_is_held(&rt6_exception_lock)); if (!bucket) { ...
static int rt6_insert_exception(struct rt6_info *nrt, struct fib6_info *ort) { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ struct in6_addr *src_key = NULL; /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ int err = 0; /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ if (ort->exception_bucket_flushed...
static int rt6_insert_exception(struct rt6_info *nrt, struct fib6_info *ort) { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ struct in6_addr *src_key = NULL; /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ int max_depth; int err = 0; /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ if (ort->excep...
static int rt6_insert_exception(struct rt6_info *nrt, const struct fib6_result *res) { struct in6_addr *src_key = NULL; struct fib6_nh *nh = res->nh; + int max_depth; int err = 0; bucket = rcu_dereference_protected(nh->rt6i_exception_bucket, lockdep_is_held(&rt6_exception_lock)); if (!bucke...
CVE-2021-21781
linux
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux
arch/arm/kernel/signal.c
get_signal_page
struct page *get_signal_page(void) { unsigned long ptr; unsigned offset; struct page *page; void *addr; page = alloc_pages(GFP_KERNEL, 0); if (!page) { return NULL; } addr = page_address(page); offset = 0x200 + (get_random_int() & 0x7fc); signal_return_offset = offset; ...
struct page *get_signal_page(void) { unsigned long ptr; unsigned offset; struct page *page; void *addr; page = alloc_pages(GFP_KERNEL, 0); if (!page) { return NULL; } addr = page_address(page); memset32(addr, __opcode_to_mem_arm(0xe7fddef1), PAGE_SIZE / sizeof(u32)); offs...
struct page *get_signal_page(void) { unsigned long ptr; unsigned offset; struct page *page; void *addr; page = alloc_pages(GFP_KERNEL, 0); if (!page) { return NULL; } addr = page_address(page); offset = 0x200 + (get_random_int() & 0x7fc); signal_return_offset = offset; ...
struct page *get_signal_page(void) { unsigned long ptr; unsigned offset; struct page *page; void *addr; page = alloc_pages(GFP_KERNEL, 0); if (!page) { return NULL; } addr = page_address(page); memset32(addr, __opcode_to_mem_arm(0xe7fddef1), PAGE_SIZE / sizeof(u32)); offs...
struct page *get_signal_page(void) { page = alloc_pages(GFP_KERNEL, 0); if (!page) { return NULL; } addr = page_address(page); offset = 0x200 + (get_random_int() & 0x7fc); memcpy(addr + offset, sigreturn_codes, sizeof(sigreturn_codes)); ptr = (unsigned long)addr + offset; flush_i...
struct page *get_signal_page(void) { page = alloc_pages(GFP_KERNEL, 0); if (!page) { return NULL; } addr = page_address(page); memset32(addr, __opcode_to_mem_arm(0xe7fddef1), PAGE_SIZE / sizeof(u32)); offset = 0x200 + (get_random_int() & 0x7fc); memcpy(addr + offset, sigreturn_codes,...
struct page *get_signal_page(void) { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ page = alloc_pages(GFP_KERNEL, 0); if (!page) { return NULL; } addr = page_address(page); offset = 0x200 + (get_random_int() & 0x7fc); /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ memcpy(addr + of...
struct page *get_signal_page(void) { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ page = alloc_pages(GFP_KERNEL, 0); if (!page) { return NULL; } addr = page_address(page); memset32(addr, __opcode_to_mem_arm(0xe7fddef1), PAGE_SIZE / sizeof(u32)); offset = 0x200 + (get_random_int() & ...
struct page *get_signal_page(void) { page = alloc_pages(GFP_KERNEL, 0); if (!page) { return NULL; } addr = page_address(page); + memset32(addr, __opcode_to_mem_arm(0xe7fddef1), PAGE_SIZE / sizeof(u32)); offset = 0x200 + (get_random_int() & 0x7fc); memcpy(addr + offset, sigretu...
CVE-2021-22543
linux
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux
virt/kvm/kvm_main.c
hva_to_pfn_remapped
static int hva_to_pfn_remapped(struct vm_area_struct *vma, unsigned long addr, bool *async, bool write_fault, bool *writable, kvm_pfn_t *p_pfn) { kvm_pfn_t pfn; pte_t *ptep; spinlock_t *ptl; int r; r = follow_pte(vma->vm_mm, addr, &ptep, &ptl); if (r) { bool unlocked = false; r =...
static int hva_to_pfn_remapped(struct vm_area_struct *vma, unsigned long addr, bool *async, bool write_fault, bool *writable, kvm_pfn_t *p_pfn) { kvm_pfn_t pfn; pte_t *ptep; spinlock_t *ptl; int r; r = follow_pte(vma->vm_mm, addr, &ptep, &ptl); if (r) { bool unlocked = false; r =...
static int hva_to_pfn_remapped(struct vm_area_struct *vma, unsigned long addr, bool *async, bool write_fault, bool *writable, kvm_pfn_t *p_pfn) { kvm_pfn_t pfn; pte_t *ptep; spinlock_t *ptl; int r; r = follow_pte_pmd(vma->vm_mm, addr, &ptep, NULL, &ptl); if (r) { bool unlocked = false; ...
static int hva_to_pfn_remapped(struct vm_area_struct *vma, unsigned long addr, bool *async, bool write_fault, bool *writable, kvm_pfn_t *p_pfn) { kvm_pfn_t pfn; pte_t *ptep; spinlock_t *ptl; int r; r = follow_pte_pmd(vma->vm_mm, addr, &ptep, NULL, &ptl); if (r) { bool unlocked = false; ...
static int hva_to_pfn_remapped(struct vm_area_struct *vma, unsigned long addr, bool *async, bool write_fault, bool *writable, kvm_pfn_t *p_pfn) { r = follow_pte(vma->vm_mm, addr, &ptep, &ptl); if (r) { bool unlocked = false; r = fixup_user_fault(current->mm, addr, (write_fault ? FAULT_FLAG_WRITE...
static int hva_to_pfn_remapped(struct vm_area_struct *vma, unsigned long addr, bool *async, bool write_fault, bool *writable, kvm_pfn_t *p_pfn) { r = follow_pte(vma->vm_mm, addr, &ptep, &ptl); if (r) { bool unlocked = false; r = fixup_user_fault(current->mm, addr, (write_fault ? FAULT_FLAG_WRITE...
static int hva_to_pfn_remapped(struct vm_area_struct *vma, unsigned long addr, bool *async, bool write_fault, bool *writable, kvm_pfn_t *p_pfn) { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ r = follow_pte_pmd(vma->vm_mm, addr, &ptep, NULL, &ptl); if (r) { bool unlocked = false; r = fixup_u...
static int hva_to_pfn_remapped(struct vm_area_struct *vma, unsigned long addr, bool *async, bool write_fault, bool *writable, kvm_pfn_t *p_pfn) { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ r = follow_pte_pmd(vma->vm_mm, addr, &ptep, NULL, &ptl); if (r) { bool unlocked = false; r = fixup_u...
static int hva_to_pfn_remapped(struct vm_area_struct *vma, unsigned long addr, bool *async, bool write_fault, bool *writable, kvm_pfn_t *p_pfn) { r = follow_pte(vma->vm_mm, addr, &ptep, &ptl); if (r) { bool unlocked = false; r = fixup_user_fault(current->mm, addr, (write_fault ? FAULT_FLAG_...
CVE-2021-22555
linux
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux
net/ipv4/netfilter/arp_tables.c
translate_compat_table
static int translate_compat_table(struct net *net, struct xt_table_info **pinfo, void **pentry0, const struct compat_arpt_replace *compatr) { unsigned int i, j; struct xt_table_info *newinfo, *info; void *pos, *entry0, *entry1; struct compat_arpt_entry *iter0; struct arpt_replace repl; unsigned ...
static int translate_compat_table(struct net *net, struct xt_table_info **pinfo, void **pentry0, const struct compat_arpt_replace *compatr) { unsigned int i, j; struct xt_table_info *newinfo, *info; void *pos, *entry0, *entry1; struct compat_arpt_entry *iter0; struct arpt_replace repl; unsigned ...
static int translate_compat_table(struct net *net, struct xt_table_info **pinfo, void **pentry0, const struct compat_arpt_replace *compatr) { unsigned int i, j; struct xt_table_info *newinfo, *info; void *pos, *entry0, *entry1; struct compat_arpt_entry *iter0; struct arpt_replace repl; unsigned ...
static int translate_compat_table(struct net *net, struct xt_table_info **pinfo, void **pentry0, const struct compat_arpt_replace *compatr) { unsigned int i, j; struct xt_table_info *newinfo, *info; void *pos, *entry0, *entry1; struct compat_arpt_entry *iter0; struct arpt_replace repl; unsigned ...
static int translate_compat_table(struct net *net, struct xt_table_info **pinfo, void **pentry0, const struct compat_arpt_replace *compatr) { size = compatr->size; newinfo = xt_alloc_table_info(size); if (!newinfo) { goto out_unlock; } newinfo->number = compatr->num_entries; entry1 = new...
static int translate_compat_table(struct net *net, struct xt_table_info **pinfo, void **pentry0, const struct compat_arpt_replace *compatr) { size = compatr->size; newinfo = xt_alloc_table_info(size); if (!newinfo) { goto out_unlock; } memset(newinfo->entries, 0, size); newinfo->number =...
static int translate_compat_table(struct net *net, struct xt_table_info **pinfo, void **pentry0, const struct compat_arpt_replace *compatr) { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ size = compatr->size; /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ newinfo = xt_alloc_table_info(size); if (!ne...
static int translate_compat_table(struct net *net, struct xt_table_info **pinfo, void **pentry0, const struct compat_arpt_replace *compatr) { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ size = compatr->size; /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ newinfo = xt_alloc_table_info(size); if (!ne...
static int translate_compat_table(struct net *net, struct xt_table_info **pinfo, void **pentry0, const struct compat_arpt_replace *compatr) { size = compatr->size; newinfo = xt_alloc_table_info(size); if (!newinfo) { goto out_unlock; } + memset(newinfo->entries, 0, size); newinfo->...
CVE-2021-22555
linux
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux
net/ipv4/netfilter/ip_tables.c
translate_compat_table
static int translate_compat_table(struct net *net, struct xt_table_info **pinfo, void **pentry0, const struct compat_ipt_replace *compatr) { unsigned int i, j; struct xt_table_info *newinfo, *info; void *pos, *entry0, *entry1; struct compat_ipt_entry *iter0; struct ipt_replace repl; unsigned int...
static int translate_compat_table(struct net *net, struct xt_table_info **pinfo, void **pentry0, const struct compat_ipt_replace *compatr) { unsigned int i, j; struct xt_table_info *newinfo, *info; void *pos, *entry0, *entry1; struct compat_ipt_entry *iter0; struct ipt_replace repl; unsigned int...
static int translate_compat_table(struct net *net, struct xt_table_info **pinfo, void **pentry0, const struct compat_ipt_replace *compatr) { unsigned int i, j; struct xt_table_info *newinfo, *info; void *pos, *entry0, *entry1; struct compat_ipt_entry *iter0; struct ipt_replace repl; unsigned int...
static int translate_compat_table(struct net *net, struct xt_table_info **pinfo, void **pentry0, const struct compat_ipt_replace *compatr) { unsigned int i, j; struct xt_table_info *newinfo, *info; void *pos, *entry0, *entry1; struct compat_ipt_entry *iter0; struct ipt_replace repl; unsigned int...
static int translate_compat_table(struct net *net, struct xt_table_info **pinfo, void **pentry0, const struct compat_ipt_replace *compatr) { size = compatr->size; newinfo = xt_alloc_table_info(size); if (!newinfo) { goto out_unlock; } newinfo->number = compatr->num_entries; entry1 = newi...
static int translate_compat_table(struct net *net, struct xt_table_info **pinfo, void **pentry0, const struct compat_ipt_replace *compatr) { size = compatr->size; newinfo = xt_alloc_table_info(size); if (!newinfo) { goto out_unlock; } memset(newinfo->entries, 0, size); newinfo->number = ...
static int translate_compat_table(struct net *net, struct xt_table_info **pinfo, void **pentry0, const struct compat_ipt_replace *compatr) { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ size = compatr->size; /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ newinfo = xt_alloc_table_info(size); if (!new...
static int translate_compat_table(struct net *net, struct xt_table_info **pinfo, void **pentry0, const struct compat_ipt_replace *compatr) { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ size = compatr->size; /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ newinfo = xt_alloc_table_info(size); if (!new...
static int translate_compat_table(struct net *net, struct xt_table_info **pinfo, void **pentry0, const struct compat_ipt_replace *compatr) { size = compatr->size; newinfo = xt_alloc_table_info(size); if (!newinfo) { goto out_unlock; } + memset(newinfo->entries, 0, size); newinfo->n...
CVE-2021-22555
linux
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux
net/ipv6/netfilter/ip6_tables.c
translate_compat_table
static int translate_compat_table(struct net *net, struct xt_table_info **pinfo, void **pentry0, const struct compat_ip6t_replace *compatr) { unsigned int i, j; struct xt_table_info *newinfo, *info; void *pos, *entry0, *entry1; struct compat_ip6t_entry *iter0; struct ip6t_replace repl; unsigned ...
static int translate_compat_table(struct net *net, struct xt_table_info **pinfo, void **pentry0, const struct compat_ip6t_replace *compatr) { unsigned int i, j; struct xt_table_info *newinfo, *info; void *pos, *entry0, *entry1; struct compat_ip6t_entry *iter0; struct ip6t_replace repl; unsigned ...
static int translate_compat_table(struct net *net, struct xt_table_info **pinfo, void **pentry0, const struct compat_ip6t_replace *compatr) { unsigned int i, j; struct xt_table_info *newinfo, *info; void *pos, *entry0, *entry1; struct compat_ip6t_entry *iter0; struct ip6t_replace repl; unsigned ...
static int translate_compat_table(struct net *net, struct xt_table_info **pinfo, void **pentry0, const struct compat_ip6t_replace *compatr) { unsigned int i, j; struct xt_table_info *newinfo, *info; void *pos, *entry0, *entry1; struct compat_ip6t_entry *iter0; struct ip6t_replace repl; unsigned ...
static int translate_compat_table(struct net *net, struct xt_table_info **pinfo, void **pentry0, const struct compat_ip6t_replace *compatr) { size = compatr->size; newinfo = xt_alloc_table_info(size); if (!newinfo) { goto out_unlock; } newinfo->number = compatr->num_entries; entry1 = new...
static int translate_compat_table(struct net *net, struct xt_table_info **pinfo, void **pentry0, const struct compat_ip6t_replace *compatr) { size = compatr->size; newinfo = xt_alloc_table_info(size); if (!newinfo) { goto out_unlock; } memset(newinfo->entries, 0, size); newinfo->number =...
static int translate_compat_table(struct net *net, struct xt_table_info **pinfo, void **pentry0, const struct compat_ip6t_replace *compatr) { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ size = compatr->size; /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ newinfo = xt_alloc_table_info(size); if (!ne...
static int translate_compat_table(struct net *net, struct xt_table_info **pinfo, void **pentry0, const struct compat_ip6t_replace *compatr) { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ size = compatr->size; /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ newinfo = xt_alloc_table_info(size); if (!ne...
static int translate_compat_table(struct net *net, struct xt_table_info **pinfo, void **pentry0, const struct compat_ip6t_replace *compatr) { size = compatr->size; newinfo = xt_alloc_table_info(size); if (!newinfo) { goto out_unlock; } + memset(newinfo->entries, 0, size); newinfo->...
CVE-2021-22555
linux
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux
net/netfilter/x_tables.c
xt_compat_match_from_user
void xt_compat_match_from_user(struct xt_entry_match *m, void **dstptr, unsigned int *size) { const struct xt_match *match = m->u.kernel.match; struct compat_xt_entry_match *cm = (struct compat_xt_entry_match *)m; int pad, off = xt_compat_match_offset(match); u_int16_t msize = cm->u.user.match_size; ...
void xt_compat_match_from_user(struct xt_entry_match *m, void **dstptr, unsigned int *size) { const struct xt_match *match = m->u.kernel.match; struct compat_xt_entry_match *cm = (struct compat_xt_entry_match *)m; int off = xt_compat_match_offset(match); u_int16_t msize = cm->u.user.match_size; char...
void xt_compat_match_from_user(struct xt_entry_match *m, void **dstptr, unsigned int *size) { const struct xt_match *match = m->u.kernel.match; struct compat_xt_entry_match *cm = (struct compat_xt_entry_match *)m; int pad, off = xt_compat_match_offset(match); u_int16_t msize = cm->u.user.match_size; ...
void xt_compat_match_from_user(struct xt_entry_match *m, void **dstptr, unsigned int *size) { const struct xt_match *match = m->u.kernel.match; struct compat_xt_entry_match *cm = (struct compat_xt_entry_match *)m; int off = xt_compat_match_offset(match); u_int16_t msize = cm->u.user.match_size; char...
void xt_compat_match_from_user(struct xt_entry_match *m, void **dstptr, unsigned int *size) { const struct xt_match *match = m->u.kernel.match; struct compat_xt_entry_match *cm = (struct compat_xt_entry_match *)m; int pad, off = xt_compat_match_offset(match); u_int16_t msize = cm->u.user.match_size; ...
void xt_compat_match_from_user(struct xt_entry_match *m, void **dstptr, unsigned int *size) { const struct xt_match *match = m->u.kernel.match; struct compat_xt_entry_match *cm = (struct compat_xt_entry_match *)m; int off = xt_compat_match_offset(match); u_int16_t msize = cm->u.user.match_size; m = ...
void xt_compat_match_from_user(struct xt_entry_match *m, void **dstptr, unsigned int *size) { const struct xt_match *match = m->u.kernel.match; struct compat_xt_entry_match *cm = (struct compat_xt_entry_match *)m; int pad, off = xt_compat_match_offset(match); u_int16_t msize = cm->u.user.match_size; ...
void xt_compat_match_from_user(struct xt_entry_match *m, void **dstptr, unsigned int *size) { const struct xt_match *match = m->u.kernel.match; struct compat_xt_entry_match *cm = (struct compat_xt_entry_match *)m; int off = xt_compat_match_offset(match); u_int16_t msize = cm->u.user.match_size; /* P...
void xt_compat_match_from_user(struct xt_entry_match *m, void **dstptr, unsigned int *size) { const struct xt_match *match = m->u.kernel.match; struct compat_xt_entry_match *cm = (struct compat_xt_entry_match *)m; - int pad, off = xt_compat_match_offset(match); + int off = xt_compat_match_offset(match)...
CVE-2021-22555
linux
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux
net/netfilter/x_tables.c
xt_compat_target_from_user
void xt_compat_target_from_user(struct xt_entry_target *t, void **dstptr, unsigned int *size) { const struct xt_target *target = t->u.kernel.target; struct compat_xt_entry_target *ct = (struct compat_xt_entry_target *)t; int pad, off = xt_compat_target_offset(target); u_int16_t tsize = ct->u.user.target...
void xt_compat_target_from_user(struct xt_entry_target *t, void **dstptr, unsigned int *size) { const struct xt_target *target = t->u.kernel.target; struct compat_xt_entry_target *ct = (struct compat_xt_entry_target *)t; int off = xt_compat_target_offset(target); u_int16_t tsize = ct->u.user.target_size...
void xt_compat_target_from_user(struct xt_entry_target *t, void **dstptr, unsigned int *size) { const struct xt_target *target = t->u.kernel.target; struct compat_xt_entry_target *ct = (struct compat_xt_entry_target *)t; int pad, off = xt_compat_target_offset(target); u_int16_t tsize = ct->u.user.target...
void xt_compat_target_from_user(struct xt_entry_target *t, void **dstptr, unsigned int *size) { const struct xt_target *target = t->u.kernel.target; struct compat_xt_entry_target *ct = (struct compat_xt_entry_target *)t; int off = xt_compat_target_offset(target); u_int16_t tsize = ct->u.user.target_size...
void xt_compat_target_from_user(struct xt_entry_target *t, void **dstptr, unsigned int *size) { const struct xt_target *target = t->u.kernel.target; struct compat_xt_entry_target *ct = (struct compat_xt_entry_target *)t; int pad, off = xt_compat_target_offset(target); u_int16_t tsize = ct->u.user.target...
void xt_compat_target_from_user(struct xt_entry_target *t, void **dstptr, unsigned int *size) { const struct xt_target *target = t->u.kernel.target; struct compat_xt_entry_target *ct = (struct compat_xt_entry_target *)t; int off = xt_compat_target_offset(target); u_int16_t tsize = ct->u.user.target_size...
void xt_compat_target_from_user(struct xt_entry_target *t, void **dstptr, unsigned int *size) { const struct xt_target *target = t->u.kernel.target; struct compat_xt_entry_target *ct = (struct compat_xt_entry_target *)t; int pad, off = xt_compat_target_offset(target); u_int16_t tsize = ct->u.user.target...
void xt_compat_target_from_user(struct xt_entry_target *t, void **dstptr, unsigned int *size) { const struct xt_target *target = t->u.kernel.target; struct compat_xt_entry_target *ct = (struct compat_xt_entry_target *)t; int off = xt_compat_target_offset(target); u_int16_t tsize = ct->u.user.target_size...
void xt_compat_target_from_user(struct xt_entry_target *t, void **dstptr, unsigned int *size) { const struct xt_target *target = t->u.kernel.target; struct compat_xt_entry_target *ct = (struct compat_xt_entry_target *)t; - int pad, off = xt_compat_target_offset(target); + int off = xt_compat_target_off...
CVE-2021-22600
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); unsigned long *rx_owner_map = NULL; int was_running, order = 0; struct packet_ring_buffer *rb; struct sk_buff_head *rb_queue; __...
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); unsigned long *rx_owner_map = NULL; int was_running, order = 0; struct packet_ring_buffer *rb; struct sk_buff_head *rb_queue; __...
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); unsigned long *rx_owner_map = NULL; int was_running, order = 0; struct packet_ring_buffer *rb; struct sk_buff_head *rb_queue; __...
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); unsigned long *rx_owner_map = NULL; int was_running, order = 0; struct packet_ring_buffer *rb; struct sk_buff_head *rb_queue; __...
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); unsigned long *rx_owner_map = NULL; struct tpacket_req *req = &req_u->req; rb = tx_ring ? &po->tx_ring : &po->rx_ring; if (!closing) { if (packet_read_pend...
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); unsigned long *rx_owner_map = NULL; struct tpacket_req *req = &req_u->req; rb = tx_ring ? &po->tx_ring : &po->rx_ring; if (!closing) { if (packet_read_pend...
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); unsigned long *rx_owner_map = NULL; /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ struct tpacket_req *req = &req_u->r...
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); unsigned long *rx_owner_map = NULL; /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ struct tpacket_req *req = &req_u->r...
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); unsigned long *rx_owner_map = NULL; struct tpacket_req *req = &req_u->req; rb = tx_ring ? &po->tx_ring : &po->rx_ring; if (!closing) { if (packet_re...
CVE-2021-23133
linux
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux
net/sctp/socket.c
sctp_close
static void sctp_close(struct sock *sk, long timeout) { struct net *net = sock_net(sk); struct sctp_endpoint *ep; struct sctp_association *asoc; struct list_head *pos, *temp; unsigned int data_was_unread; pr_debug("%s: sk:%p, timeout:%ld\n", __func__, sk, timeout); lock_sock_nested(sk, SGLE_...
static void sctp_close(struct sock *sk, long timeout) { struct net *net = sock_net(sk); struct sctp_endpoint *ep; struct sctp_association *asoc; struct list_head *pos, *temp; unsigned int data_was_unread; pr_debug("%s: sk:%p, timeout:%ld\n", __func__, sk, timeout); lock_sock_nested(sk, SGLE_...
static void sctp_close(struct sock *sk, long timeout) { struct net *net = sock_net(sk); struct sctp_endpoint *ep; struct sctp_association *asoc; struct list_head *pos, *temp; unsigned int data_was_unread; pr_debug("%s: sk:%p, timeout:%ld\n", __func__, sk, timeout); lock_sock_nested(sk, SGLE_...
static void sctp_close(struct sock *sk, long timeout) { struct net *net = sock_net(sk); struct sctp_endpoint *ep; struct sctp_association *asoc; struct list_head *pos, *temp; unsigned int data_was_unread; pr_debug("%s: sk:%p, timeout:%ld\n", __func__, sk, timeout); lock_sock_nested(sk, SGLE_...
static void sctp_close(struct sock *sk, long timeout) { struct net *net = sock_net(sk); pr_debug("%s: sk:%p, timeout:%ld\n", __func__, sk, timeout); lock_sock_nested(sk, SGLE_DEPTH_NESTG); inet_sk_set_state(sk, SCTP_SS_CLOSG); ep = sctp_sk(sk)->ep; data_was_unread = sctp_queue_purge_ulpevents(&s...
static void sctp_close(struct sock *sk, long timeout) { struct net *net = sock_net(sk); pr_debug("%s: sk:%p, timeout:%ld\n", __func__, sk, timeout); lock_sock_nested(sk, SGLE_DEPTH_NESTG); inet_sk_set_state(sk, SCTP_SS_CLOSG); ep = sctp_sk(sk)->ep; data_was_unread = sctp_queue_purge_ulpevents(&s...
static void sctp_close(struct sock *sk, long timeout) { struct net *net = sock_net(sk); /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ pr_debug("%s: sk:%p, timeout:%ld\n", __func__, sk, timeout); lock_sock_nested(sk, SGLE_DEPTH_NESTG); /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ inet_sk_set_sta...
static void sctp_close(struct sock *sk, long timeout) { struct net *net = sock_net(sk); /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ pr_debug("%s: sk:%p, timeout:%ld\n", __func__, sk, timeout); lock_sock_nested(sk, SGLE_DEPTH_NESTG); /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ inet_sk_set_sta...
static void sctp_close(struct sock *sk, long timeout) { struct net *net = sock_net(sk); pr_debug("%s: sk:%p, timeout:%ld\n", __func__, sk, timeout); lock_sock_nested(sk, SGLE_DEPTH_NESTG); inet_sk_set_state(sk, SCTP_SS_CLOSG); ep = sctp_sk(sk)->ep; data_was_unread = sctp_queue_purge_ulpev...
CVE-2021-23133
linux
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux
net/sctp/socket.c
sctp_destroy_sock
static void sctp_destroy_sock(struct sock *sk) { struct sctp_sock *sp; pr_debug("%s: sk:%p\n", __func__, sk); sp = sctp_sk(sk); if (sp->ep == NULL) { return; } if (sp->do_auto_asconf) { sp->do_auto_asconf = 0; list_del(&sp->auto_asconf_list); } sctp_endpoint_free(...
static void sctp_destroy_sock(struct sock *sk) { struct sctp_sock *sp; pr_debug("%s: sk:%p\n", __func__, sk); sp = sctp_sk(sk); if (sp->ep == NULL) { return; } if (sp->do_auto_asconf) { sp->do_auto_asconf = 0; spin_lock_bh(&sock_net(sk)->sctp.addr_wq_lock); list_d...
static void sctp_destroy_sock(struct sock *sk) { struct sctp_sock *sp; pr_debug("%s: sk:%p\n", __func__, sk); sp = sctp_sk(sk); if (sp->ep == NULL) { return; } if (sp->do_auto_asconf) { sp->do_auto_asconf = 0; list_del(&sp->auto_asconf_list); } sctp_endpoint_free(...
static void sctp_destroy_sock(struct sock *sk) { struct sctp_sock *sp; pr_debug("%s: sk:%p\n", __func__, sk); sp = sctp_sk(sk); if (sp->ep == NULL) { return; } if (sp->do_auto_asconf) { sp->do_auto_asconf = 0; spin_lock_bh(&sock_net(sk)->sctp.addr_wq_lock); list_d...
static void sctp_destroy_sock(struct sock *sk) { pr_debug("%s: sk:%p\n", __func__, sk); sp = sctp_sk(sk); if (sp->do_auto_asconf) { sp->do_auto_asconf = 0; list_del(&sp->auto_asconf_list); } sctp_endpoint_free(sp->ep); sk_sockets_allocated_dec(sk); sock_prot_inuse_add(sock_ne...
static void sctp_destroy_sock(struct sock *sk) { pr_debug("%s: sk:%p\n", __func__, sk); sp = sctp_sk(sk); if (sp->do_auto_asconf) { sp->do_auto_asconf = 0; spin_lock_bh(&sock_net(sk)->sctp.addr_wq_lock); list_del(&sp->auto_asconf_list); spin_unlock_bh(&sock_net(sk)->sctp.addr...
static void sctp_destroy_sock(struct sock *sk) { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ pr_debug("%s: sk:%p\n", __func__, sk); sp = sctp_sk(sk); /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ if (sp->do_auto_asconf) { sp->do_auto_asconf = 0; list_del(&sp->auto_asconf_list); ...
static void sctp_destroy_sock(struct sock *sk) { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ pr_debug("%s: sk:%p\n", __func__, sk); sp = sctp_sk(sk); /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ if (sp->do_auto_asconf) { sp->do_auto_asconf = 0; spin_lock_bh(&sock_net(sk)->sctp.add...
static void sctp_destroy_sock(struct sock *sk) { pr_debug("%s: sk:%p\n", __func__, sk); sp = sctp_sk(sk); if (sp->do_auto_asconf) { sp->do_auto_asconf = 0; + spin_lock_bh(&sock_net(sk)->sctp.addr_wq_lock); list_del(&sp->auto_asconf_list); + spin_unlock_bh(&sock_net(sk)->s...
CVE-2021-26401
linux
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux
arch/x86/kernel/cpu/bugs.c
spectre_v2_select_retpoline
static enum spectre_v2_mitigation spectre_v2_select_retpoline(void) { if (!IS_ENABLED(CONFIG_RETPOLE)) { pr_err("Kernel not compiled with retpoline; no mitigation available!"); return SPECTRE_V2_NONE; } if (boot_cpu_data.x86_vendor == X86_VENDOR_AMD) { if (!boot_cpu_has(X86_FEATURE_L...
static enum spectre_v2_mitigation spectre_v2_select_retpoline(void) { if (!IS_ENABLED(CONFIG_RETPOLE)) { pr_err("Kernel not compiled with retpoline; no mitigation available!"); return SPECTRE_V2_NONE; } return SPECTRE_V2_RETPOLE; }
static enum spectre_v2_mitigation spectre_v2_select_retpoline(void) { if (!IS_ENABLED(CONFIG_RETPOLE)) { pr_err("Kernel not compiled with retpoline; no mitigation available!"); return SPECTRE_V2_NONE; } if (boot_cpu_data.x86_vendor == X86_VENDOR_AMD || boot_cpu_data.x86_vendor == X86_VENDOR_...
static enum spectre_v2_mitigation spectre_v2_select_retpoline(void) { if (!IS_ENABLED(CONFIG_RETPOLE)) { pr_err("Kernel not compiled with retpoline; no mitigation available!"); return SPECTRE_V2_NONE; } return SPECTRE_V2_RETPOLE; }
static enum spectre_v2_mitigation spectre_v2_select_retpoline(void) { if (!IS_ENABLED(CONFIG_RETPOLE)) { pr_err("Kernel not compiled with retpoline; no mitigation available!"); return SPECTRE_V2_NONE; } if (boot_cpu_data.x86_vendor == X86_VENDOR_AMD) { if (!boot_cpu_has(X86_FEATURE_L...
static enum spectre_v2_mitigation spectre_v2_select_retpoline(void) { if (!IS_ENABLED(CONFIG_RETPOLE)) { pr_err("Kernel not compiled with retpoline; no mitigation available!"); return SPECTRE_V2_NONE; } return SPECTRE_V2_RETPOLE; }
static enum spectre_v2_mitigation spectre_v2_select_retpoline(void) { if (!IS_ENABLED(CONFIG_RETPOLE)) { pr_err("Kernel not compiled with retpoline; no mitigation available!"); return SPECTRE_V2_NONE; } if (boot_cpu_data.x86_vendor == X86_VENDOR_AMD || boot_cpu_data.x86_vendor == X86_VENDOR_...
static enum spectre_v2_mitigation spectre_v2_select_retpoline(void) { if (!IS_ENABLED(CONFIG_RETPOLE)) { pr_err("Kernel not compiled with retpoline; no mitigation available!"); return SPECTRE_V2_NONE; } return SPECTRE_V2_RETPOLE; }
static enum spectre_v2_mitigation spectre_v2_select_retpoline(void) { if (!IS_ENABLED(CONFIG_RETPOLE)) { pr_err("Kernel not compiled with retpoline; no mitigation available!"); return SPECTRE_V2_NONE; } - if (boot_cpu_data.x86_vendor == X86_VENDOR_AMD) { - if (!boot_cpu_has(X86_FE...
CVE-2021-26930
linux
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux
drivers/block/xen-blkback/blkback.c
xen_blkbk_map
static int xen_blkbk_map(struct xen_blkif_ring *ring, struct grant_page *pages[], int num, bool ro) { struct gnttab_map_grant_ref map[BLKIF_MAX_SEGMENTS_PER_REQUEST]; struct page *pages_to_gnt[BLKIF_MAX_SEGMENTS_PER_REQUEST]; struct persistent_gnt *persistent_gnt = NULL; phys_addr_t addr = 0; int i,...
static int xen_blkbk_map(struct xen_blkif_ring *ring, struct grant_page *pages[], int num, bool ro) { struct gnttab_map_grant_ref map[BLKIF_MAX_SEGMENTS_PER_REQUEST]; struct page *pages_to_gnt[BLKIF_MAX_SEGMENTS_PER_REQUEST]; struct persistent_gnt *persistent_gnt = NULL; phys_addr_t addr = 0; int i,...
static int xen_blkbk_map(struct xen_blkif_ring *ring, struct grant_page *pages[], int num, bool ro) { struct gnttab_map_grant_ref map[BLKIF_MAX_SEGMENTS_PER_REQUEST]; struct page *pages_to_gnt[BLKIF_MAX_SEGMENTS_PER_REQUEST]; struct persistent_gnt *persistent_gnt = NULL; phys_addr_t addr = 0; int i,...
static int xen_blkbk_map(struct xen_blkif_ring *ring, struct grant_page *pages[], int num, bool ro) { struct gnttab_map_grant_ref map[BLKIF_MAX_SEGMENTS_PER_REQUEST]; struct page *pages_to_gnt[BLKIF_MAX_SEGMENTS_PER_REQUEST]; struct persistent_gnt *persistent_gnt = NULL; phys_addr_t addr = 0; int i,...
static int xen_blkbk_map(struct xen_blkif_ring *ring, struct grant_page *pages[], int num, bool ro) { struct persistent_gnt *persistent_gnt = NULL; int segs_to_map = 0; int ret = 0; int last_map = 0, map_until = 0; struct xen_blkif *blkif = ring->blkif; again: for (i = map_until; i < num; i++) {...
static int xen_blkbk_map(struct xen_blkif_ring *ring, struct grant_page *pages[], int num, bool ro) { struct persistent_gnt *persistent_gnt = NULL; int segs_to_map = 0; int ret = 0; int last_map = 0, map_until = 0; struct xen_blkif *blkif = ring->blkif; again: for (i = map_until; i < num; i++) {...
static int xen_blkbk_map(struct xen_blkif_ring *ring, struct grant_page *pages[], int num, bool ro) { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ struct persistent_gnt *persistent_gnt = NULL; /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ int segs_to_map = 0; int ret = 0; int last_map = 0, map_...
static int xen_blkbk_map(struct xen_blkif_ring *ring, struct grant_page *pages[], int num, bool ro) { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ struct persistent_gnt *persistent_gnt = NULL; /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ int segs_to_map = 0; int ret = 0; int last_map = 0, map_...
static int xen_blkbk_map(struct xen_blkif_ring *ring, struct grant_page *pages[], int num, bool ro) { struct persistent_gnt *persistent_gnt = NULL; int segs_to_map = 0; int ret = 0; int last_map = 0, map_until = 0; struct xen_blkif *blkif = ring->blkif; again: for (i = map_until; i < num...
CVE-2021-26931
linux
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux
drivers/block/xen-blkback/blkback.c
xen_blkbk_map
static int xen_blkbk_map(struct xen_blkif_ring *ring, struct grant_page *pages[], int num, bool ro) { struct gnttab_map_grant_ref map[BLKIF_MAX_SEGMENTS_PER_REQUEST]; struct page *pages_to_gnt[BLKIF_MAX_SEGMENTS_PER_REQUEST]; struct persistent_gnt *persistent_gnt = NULL; phys_addr_t addr = 0; int i,...
static int xen_blkbk_map(struct xen_blkif_ring *ring, struct grant_page *pages[], int num, bool ro) { struct gnttab_map_grant_ref map[BLKIF_MAX_SEGMENTS_PER_REQUEST]; struct page *pages_to_gnt[BLKIF_MAX_SEGMENTS_PER_REQUEST]; struct persistent_gnt *persistent_gnt = NULL; phys_addr_t addr = 0; int i,...
static int xen_blkbk_map(struct xen_blkif_ring *ring, struct grant_page *pages[], int num, bool ro) { struct gnttab_map_grant_ref map[BLKIF_MAX_SEGMENTS_PER_REQUEST]; struct page *pages_to_gnt[BLKIF_MAX_SEGMENTS_PER_REQUEST]; struct persistent_gnt *persistent_gnt = NULL; phys_addr_t addr = 0; int i,...
static int xen_blkbk_map(struct xen_blkif_ring *ring, struct grant_page *pages[], int num, bool ro) { struct gnttab_map_grant_ref map[BLKIF_MAX_SEGMENTS_PER_REQUEST]; struct page *pages_to_gnt[BLKIF_MAX_SEGMENTS_PER_REQUEST]; struct persistent_gnt *persistent_gnt = NULL; phys_addr_t addr = 0; int i,...
static int xen_blkbk_map(struct xen_blkif_ring *ring, struct grant_page *pages[], int num, bool ro) { struct persistent_gnt *persistent_gnt = NULL; int segs_to_map = 0; int ret = 0; struct xen_blkif *blkif = ring->blkif; again: for (i = map_until; i < num; i++) { uint32_t flags; if (...
static int xen_blkbk_map(struct xen_blkif_ring *ring, struct grant_page *pages[], int num, bool ro) { struct persistent_gnt *persistent_gnt = NULL; int segs_to_map = 0; int ret = 0; struct xen_blkif *blkif = ring->blkif; again: for (i = map_until; i < num; i++) { uint32_t flags; if (...
static int xen_blkbk_map(struct xen_blkif_ring *ring, struct grant_page *pages[], int num, bool ro) { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ struct persistent_gnt *persistent_gnt = NULL; /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ int segs_to_map = 0; int ret = 0; /* PLACEHOLDER: DO NOT...
static int xen_blkbk_map(struct xen_blkif_ring *ring, struct grant_page *pages[], int num, bool ro) { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ struct persistent_gnt *persistent_gnt = NULL; /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ int segs_to_map = 0; int ret = 0; /* PLACEHOLDER: DO NOT...
static int xen_blkbk_map(struct xen_blkif_ring *ring, struct grant_page *pages[], int num, bool ro) { struct persistent_gnt *persistent_gnt = NULL; int segs_to_map = 0; int ret = 0; struct xen_blkif *blkif = ring->blkif; again: for (i = map_until; i < num; i++) { uint32_t flags; ...
CVE-2021-26932
linux
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux
arch/x86/xen/p2m.c
clear_foreign_p2m_mapping
int clear_foreign_p2m_mapping(struct gnttab_unmap_grant_ref *unmap_ops, struct gnttab_unmap_grant_ref *kunmap_ops, struct page **pages, unsigned int count) { int i, ret = 0; if (xen_feature(XENFEAT_auto_translated_physmap)) { return 0; } for (i = 0; i < count; i++) { unsigned long mfn = ...
int clear_foreign_p2m_mapping(struct gnttab_unmap_grant_ref *unmap_ops, struct gnttab_unmap_grant_ref *kunmap_ops, struct page **pages, unsigned int count) { int i, ret = 0; if (xen_feature(XENFEAT_auto_translated_physmap)) { return 0; } for (i = 0; i < count; i++) { unsigned long mfn = ...
int clear_foreign_p2m_mapping(struct gnttab_unmap_grant_ref *unmap_ops, struct gnttab_unmap_grant_ref *kunmap_ops, struct page **pages, unsigned int count) { int i, ret = 0; if (xen_feature(XENFEAT_auto_translated_physmap)) { return 0; } for (i = 0; i < count; i++) { unsigned long mfn = ...
int clear_foreign_p2m_mapping(struct gnttab_unmap_grant_ref *unmap_ops, struct gnttab_unmap_grant_ref *kunmap_ops, struct page **pages, unsigned int count) { int i, ret = 0; if (xen_feature(XENFEAT_auto_translated_physmap)) { return 0; } for (i = 0; i < count; i++) { unsigned long mfn = ...
int clear_foreign_p2m_mapping(struct gnttab_unmap_grant_ref *unmap_ops, struct gnttab_unmap_grant_ref *kunmap_ops, struct page **pages, unsigned int count) { int i, ret = 0; for (i = 0; i < count; i++) { unsigned long mfn = __pfn_to_mfn(page_to_pfn(pages[i])); unsigned long pfn = page_to_pfn(pag...
int clear_foreign_p2m_mapping(struct gnttab_unmap_grant_ref *unmap_ops, struct gnttab_unmap_grant_ref *kunmap_ops, struct page **pages, unsigned int count) { int i, ret = 0; for (i = 0; i < count; i++) { unsigned long mfn = __pfn_to_mfn(page_to_pfn(pages[i])); unsigned long pfn = page_to_pfn(pag...
int clear_foreign_p2m_mapping(struct gnttab_unmap_grant_ref *unmap_ops, struct gnttab_unmap_grant_ref *kunmap_ops, struct page **pages, unsigned int count) { int i, ret = 0; /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ for (i = 0; i < count; i++) { unsigned long mfn = __pfn_to_mfn(page_to_pfn(pages...
int clear_foreign_p2m_mapping(struct gnttab_unmap_grant_ref *unmap_ops, struct gnttab_unmap_grant_ref *kunmap_ops, struct page **pages, unsigned int count) { int i, ret = 0; /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ for (i = 0; i < count; i++) { unsigned long mfn = __pfn_to_mfn(page_to_pfn(pages...
int clear_foreign_p2m_mapping(struct gnttab_unmap_grant_ref *unmap_ops, struct gnttab_unmap_grant_ref *kunmap_ops, struct page **pages, unsigned int count) { int i, ret = 0; for (i = 0; i < count; i++) { unsigned long mfn = __pfn_to_mfn(page_to_pfn(pages[i])); unsigned long pfn = page_to_pf...
CVE-2021-27363
linux
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux
drivers/scsi/scsi_transport_iscsi.c
iscsi_if_recv_msg
static int iscsi_if_recv_msg(struct sk_buff *skb, struct nlmsghdr *nlh, uint32_t *group) { int err = 0; struct iscsi_uevent *ev = nlmsg_data(nlh); struct iscsi_transport *transport = NULL; struct iscsi_internal *priv; struct iscsi_cls_session *session; struct iscsi_cls_conn *conn; struct isc...
static int iscsi_if_recv_msg(struct sk_buff *skb, struct nlmsghdr *nlh, uint32_t *group) { int err = 0; struct iscsi_uevent *ev = nlmsg_data(nlh); struct iscsi_transport *transport = NULL; struct iscsi_internal *priv; struct iscsi_cls_session *session; struct iscsi_cls_conn *conn; struct isc...
static int iscsi_if_recv_msg(struct sk_buff *skb, struct nlmsghdr *nlh, uint32_t *group) { int err = 0; u32 portid; struct iscsi_uevent *ev = nlmsg_data(nlh); struct iscsi_transport *transport = NULL; struct iscsi_internal *priv; struct iscsi_cls_session *session; struct iscsi_cls_conn *conn...
static int iscsi_if_recv_msg(struct sk_buff *skb, struct nlmsghdr *nlh, uint32_t *group) { int err = 0; u32 portid; struct iscsi_uevent *ev = nlmsg_data(nlh); struct iscsi_transport *transport = NULL; struct iscsi_internal *priv; struct iscsi_cls_session *session; struct iscsi_cls_conn *conn...
static int iscsi_if_recv_msg(struct sk_buff *skb, struct nlmsghdr *nlh, uint32_t *group) { struct iscsi_endpoint *ep = NULL; if (nlh->nlmsg_type == ISCSI_UEVENT_PATH_UPDATE) { } else { } switch (nlh->nlmsg_type) { case ISCSI_UEVENT_CREATE_SESSION: err = iscsi_if_create_session(priv, ep, ...
static int iscsi_if_recv_msg(struct sk_buff *skb, struct nlmsghdr *nlh, uint32_t *group) { struct iscsi_endpoint *ep = NULL; if (!netlink_capable(skb, CAP_SYS_ADM)) { return -EPERM; } if (nlh->nlmsg_type == ISCSI_UEVENT_PATH_UPDATE) { } else { } switch (nlh->nlmsg_type) { case IS...
static int iscsi_if_recv_msg(struct sk_buff *skb, struct nlmsghdr *nlh, uint32_t *group) { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ struct iscsi_endpoint *ep = NULL; if (nlh->nlmsg_type == ISCSI_UEVENT_PATH_UPDATE) { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ } else { /* PLACEHOLDER: DO ...
static int iscsi_if_recv_msg(struct sk_buff *skb, struct nlmsghdr *nlh, uint32_t *group) { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ struct iscsi_endpoint *ep = NULL; if (!netlink_capable(skb, CAP_SYS_ADM)) { return -EPERM; } if (nlh->nlmsg_type == ISCSI_UEVENT_PATH_UPDATE) { /* PLAC...
static int iscsi_if_recv_msg(struct sk_buff *skb, struct nlmsghdr *nlh, uint32_t *group) { struct iscsi_endpoint *ep = NULL; + if (!netlink_capable(skb, CAP_SYS_ADM)) { + return -EPERM; + } if (nlh->nlmsg_type == ISCSI_UEVENT_PATH_UPDATE) { } else { } switch (nlh->nlmsg_type) { ...
CVE-2021-27363
linux
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux
drivers/scsi/scsi_transport_iscsi.c
show_transport_handle
static ssize_t show_transport_handle(struct device *dev, struct device_attribute *attr, char *buf) { struct iscsi_internal *priv = dev_to_iscsi_internal(dev); return sprintf(buf, "%llu\n", (unsigned long long)iscsi_handle(priv->iscsi_transport)); }
static ssize_t show_transport_handle(struct device *dev, struct device_attribute *attr, char *buf) { struct iscsi_internal *priv = dev_to_iscsi_internal(dev); if (!capable(CAP_SYS_ADM)) { return -EACCES; } return sprintf(buf, "%llu\n", (unsigned long long)iscsi_handle(priv->iscsi_transport)); }
static ssize_t show_transport_handle(struct device *dev, struct device_attribute *attr, char *buf) { struct iscsi_internal *priv = dev_to_iscsi_internal(dev); return sprintf(buf, "%llu\n", (unsigned long long)iscsi_handle(priv->iscsi_transport)); }
static ssize_t show_transport_handle(struct device *dev, struct device_attribute *attr, char *buf) { struct iscsi_internal *priv = dev_to_iscsi_internal(dev); if (!capable(CAP_SYS_ADM)) { return -EACCES; } return sprintf(buf, "%llu\n", (unsigned long long)iscsi_handle(priv->iscsi_transport)); }
static ssize_t show_transport_handle(struct device *dev, struct device_attribute *attr, char *buf) { struct iscsi_internal *priv = dev_to_iscsi_internal(dev); return sprintf(buf, "%llu\n", (unsigned long long)iscsi_handle(priv->iscsi_transport)); }
static ssize_t show_transport_handle(struct device *dev, struct device_attribute *attr, char *buf) { struct iscsi_internal *priv = dev_to_iscsi_internal(dev); if (!capable(CAP_SYS_ADM)) { return -EACCES; } return sprintf(buf, "%llu\n", (unsigned long long)iscsi_handle(priv->iscsi_transport)); }
static ssize_t show_transport_handle(struct device *dev, struct device_attribute *attr, char *buf) { struct iscsi_internal *priv = dev_to_iscsi_internal(dev); return sprintf(buf, "%llu\n", (unsigned long long)iscsi_handle(priv->iscsi_transport)); }
static ssize_t show_transport_handle(struct device *dev, struct device_attribute *attr, char *buf) { struct iscsi_internal *priv = dev_to_iscsi_internal(dev); if (!capable(CAP_SYS_ADM)) { return -EACCES; } return sprintf(buf, "%llu\n", (unsigned long long)iscsi_handle(priv->iscsi_transport)); }
static ssize_t show_transport_handle(struct device *dev, struct device_attribute *attr, char *buf) { struct iscsi_internal *priv = dev_to_iscsi_internal(dev); + if (!capable(CAP_SYS_ADM)) { + return -EACCES; + } return sprintf(buf, "%llu\n", (unsigned long long)iscsi_handle(priv->iscsi_transport...
CVE-2021-27364
linux
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux
drivers/scsi/scsi_transport_iscsi.c
iscsi_if_recv_msg
static int iscsi_if_recv_msg(struct sk_buff *skb, struct nlmsghdr *nlh, uint32_t *group) { int err = 0; struct iscsi_uevent *ev = nlmsg_data(nlh); struct iscsi_transport *transport = NULL; struct iscsi_internal *priv; struct iscsi_cls_session *session; struct iscsi_cls_conn *conn; struct isc...
static int iscsi_if_recv_msg(struct sk_buff *skb, struct nlmsghdr *nlh, uint32_t *group) { int err = 0; struct iscsi_uevent *ev = nlmsg_data(nlh); struct iscsi_transport *transport = NULL; struct iscsi_internal *priv; struct iscsi_cls_session *session; struct iscsi_cls_conn *conn; struct isc...
static int iscsi_if_recv_msg(struct sk_buff *skb, struct nlmsghdr *nlh, uint32_t *group) { int err = 0; u32 portid; struct iscsi_uevent *ev = nlmsg_data(nlh); struct iscsi_transport *transport = NULL; struct iscsi_internal *priv; struct iscsi_cls_session *session; struct iscsi_cls_conn *conn...
static int iscsi_if_recv_msg(struct sk_buff *skb, struct nlmsghdr *nlh, uint32_t *group) { int err = 0; u32 portid; struct iscsi_uevent *ev = nlmsg_data(nlh); struct iscsi_transport *transport = NULL; struct iscsi_internal *priv; struct iscsi_cls_session *session; struct iscsi_cls_conn *conn...
static int iscsi_if_recv_msg(struct sk_buff *skb, struct nlmsghdr *nlh, uint32_t *group) { struct iscsi_endpoint *ep = NULL; if (nlh->nlmsg_type == ISCSI_UEVENT_PATH_UPDATE) { } else { } switch (nlh->nlmsg_type) { case ISCSI_UEVENT_CREATE_SESSION: err = iscsi_if_create_session(priv, ep, ...
static int iscsi_if_recv_msg(struct sk_buff *skb, struct nlmsghdr *nlh, uint32_t *group) { struct iscsi_endpoint *ep = NULL; if (!netlink_capable(skb, CAP_SYS_ADM)) { return -EPERM; } if (nlh->nlmsg_type == ISCSI_UEVENT_PATH_UPDATE) { } else { } switch (nlh->nlmsg_type) { case IS...
static int iscsi_if_recv_msg(struct sk_buff *skb, struct nlmsghdr *nlh, uint32_t *group) { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ struct iscsi_endpoint *ep = NULL; if (nlh->nlmsg_type == ISCSI_UEVENT_PATH_UPDATE) { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ } else { /* PLACEHOLDER: DO ...
static int iscsi_if_recv_msg(struct sk_buff *skb, struct nlmsghdr *nlh, uint32_t *group) { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ struct iscsi_endpoint *ep = NULL; if (!netlink_capable(skb, CAP_SYS_ADM)) { return -EPERM; } if (nlh->nlmsg_type == ISCSI_UEVENT_PATH_UPDATE) { /* PLAC...
static int iscsi_if_recv_msg(struct sk_buff *skb, struct nlmsghdr *nlh, uint32_t *group) { struct iscsi_endpoint *ep = NULL; + if (!netlink_capable(skb, CAP_SYS_ADM)) { + return -EPERM; + } if (nlh->nlmsg_type == ISCSI_UEVENT_PATH_UPDATE) { } else { } switch (nlh->nlmsg_type) { ...
CVE-2021-27364
linux
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux
drivers/scsi/scsi_transport_iscsi.c
show_transport_handle
static ssize_t show_transport_handle(struct device *dev, struct device_attribute *attr, char *buf) { struct iscsi_internal *priv = dev_to_iscsi_internal(dev); return sprintf(buf, "%llu\n", (unsigned long long)iscsi_handle(priv->iscsi_transport)); }
static ssize_t show_transport_handle(struct device *dev, struct device_attribute *attr, char *buf) { struct iscsi_internal *priv = dev_to_iscsi_internal(dev); if (!capable(CAP_SYS_ADM)) { return -EACCES; } return sprintf(buf, "%llu\n", (unsigned long long)iscsi_handle(priv->iscsi_transport)); }
static ssize_t show_transport_handle(struct device *dev, struct device_attribute *attr, char *buf) { struct iscsi_internal *priv = dev_to_iscsi_internal(dev); return sprintf(buf, "%llu\n", (unsigned long long)iscsi_handle(priv->iscsi_transport)); }
static ssize_t show_transport_handle(struct device *dev, struct device_attribute *attr, char *buf) { struct iscsi_internal *priv = dev_to_iscsi_internal(dev); if (!capable(CAP_SYS_ADM)) { return -EACCES; } return sprintf(buf, "%llu\n", (unsigned long long)iscsi_handle(priv->iscsi_transport)); }
static ssize_t show_transport_handle(struct device *dev, struct device_attribute *attr, char *buf) { struct iscsi_internal *priv = dev_to_iscsi_internal(dev); return sprintf(buf, "%llu\n", (unsigned long long)iscsi_handle(priv->iscsi_transport)); }
static ssize_t show_transport_handle(struct device *dev, struct device_attribute *attr, char *buf) { struct iscsi_internal *priv = dev_to_iscsi_internal(dev); if (!capable(CAP_SYS_ADM)) { return -EACCES; } return sprintf(buf, "%llu\n", (unsigned long long)iscsi_handle(priv->iscsi_transport)); }
static ssize_t show_transport_handle(struct device *dev, struct device_attribute *attr, char *buf) { struct iscsi_internal *priv = dev_to_iscsi_internal(dev); return sprintf(buf, "%llu\n", (unsigned long long)iscsi_handle(priv->iscsi_transport)); }
static ssize_t show_transport_handle(struct device *dev, struct device_attribute *attr, char *buf) { struct iscsi_internal *priv = dev_to_iscsi_internal(dev); if (!capable(CAP_SYS_ADM)) { return -EACCES; } return sprintf(buf, "%llu\n", (unsigned long long)iscsi_handle(priv->iscsi_transport)); }
static ssize_t show_transport_handle(struct device *dev, struct device_attribute *attr, char *buf) { struct iscsi_internal *priv = dev_to_iscsi_internal(dev); + if (!capable(CAP_SYS_ADM)) { + return -EACCES; + } return sprintf(buf, "%llu\n", (unsigned long long)iscsi_handle(priv->iscsi_transport...
CVE-2021-28039
linux
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux
arch/x86/xen/p2m.c
__set_phys_to_machine
bool __set_phys_to_machine(unsigned long pfn, unsigned long mfn) { pte_t *ptep; unsigned int level; if (unlikely(pfn >= xen_p2m_size)) { BUG_ON(mfn != VALID_P2M_ENTRY); return true; } if (likely(!xen_safe_write_ulong(xen_p2m_addr + pfn, mfn))) { return true; } ptep = ...
bool __set_phys_to_machine(unsigned long pfn, unsigned long mfn) { pte_t *ptep; unsigned int level; if (unlikely(pfn >= xen_p2m_size)) { return mfn == VALID_P2M_ENTRY; } if (likely(!xen_safe_write_ulong(xen_p2m_addr + pfn, mfn))) { return true; } ptep = lookup_address((unsign...
bool __set_phys_to_machine(unsigned long pfn, unsigned long mfn) { pte_t *ptep; unsigned int level; if (unlikely(pfn >= xen_p2m_size)) { BUG_ON(mfn != VALID_P2M_ENTRY); return true; } if (likely(!xen_safe_write_ulong(xen_p2m_addr + pfn, mfn))) { return true; } ptep = ...
bool __set_phys_to_machine(unsigned long pfn, unsigned long mfn) { pte_t *ptep; unsigned int level; if (unlikely(pfn >= xen_p2m_size)) { return mfn == VALID_P2M_ENTRY; } if (likely(!xen_safe_write_ulong(xen_p2m_addr + pfn, mfn))) { return true; } ptep = lookup_address((unsign...
bool __set_phys_to_machine(unsigned long pfn, unsigned long mfn) { if (unlikely(pfn >= xen_p2m_size)) { BUG_ON(mfn != VALID_P2M_ENTRY); return true; } }
bool __set_phys_to_machine(unsigned long pfn, unsigned long mfn) { if (unlikely(pfn >= xen_p2m_size)) { return mfn == VALID_P2M_ENTRY; } }
bool __set_phys_to_machine(unsigned long pfn, unsigned long mfn) { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ if (unlikely(pfn >= xen_p2m_size)) { BUG_ON(mfn != VALID_P2M_ENTRY); return true; } /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ }
bool __set_phys_to_machine(unsigned long pfn, unsigned long mfn) { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ if (unlikely(pfn >= xen_p2m_size)) { return mfn == VALID_P2M_ENTRY; } /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ }
bool __set_phys_to_machine(unsigned long pfn, unsigned long mfn) { if (unlikely(pfn >= xen_p2m_size)) { - BUG_ON(mfn != VALID_P2M_ENTRY); - return true; + return mfn == VALID_P2M_ENTRY; } }
CVE-2021-28039
linux
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux
arch/x86/xen/p2m.c
xen_vmalloc_p2m_tree
void xen_vmalloc_p2m_tree(void) { static struct vm_struct vm; unsigned long p2m_limit; xen_p2m_last_pfn = xen_max_p2m_pfn; p2m_limit = (phys_addr_t)P2M_LIMIT * 1024 * 1024 * 1024 / PAGE_SIZE; vm.flags = VM_ALLOC; vm.size = ALIGN(sizeof(unsigned long) * max(xen_max_p2m_pfn, p2m_limit), PMD_SIZE *...
void xen_vmalloc_p2m_tree(void) { static struct vm_struct vm; unsigned long p2m_limit; xen_p2m_last_pfn = xen_max_p2m_pfn; p2m_limit = (phys_addr_t)P2M_LIMIT * 1024 * 1024 * 1024 / PAGE_SIZE; if (!p2m_limit && IS_ENABLED(CONFIG_XEN_UNPOPULATED_ALLOC)) { p2m_limit = xen_start_info->nr_pages *...
void xen_vmalloc_p2m_tree(void) { static struct vm_struct vm; unsigned long p2m_limit; xen_p2m_last_pfn = xen_max_p2m_pfn; p2m_limit = (phys_addr_t)P2M_LIMIT * 1024 * 1024 * 1024 / PAGE_SIZE; vm.flags = VM_ALLOC; vm.size = ALIGN(sizeof(unsigned long) * max(xen_max_p2m_pfn, p2m_limit), PMD_SIZE *...
void xen_vmalloc_p2m_tree(void) { static struct vm_struct vm; unsigned long p2m_limit; xen_p2m_last_pfn = xen_max_p2m_pfn; p2m_limit = (phys_addr_t)P2M_LIMIT * 1024 * 1024 * 1024 / PAGE_SIZE; if (!p2m_limit && IS_ENABLED(CONFIG_XEN_UNPOPULATED_ALLOC)) { p2m_limit = xen_start_info->nr_pages *...
void xen_vmalloc_p2m_tree(void) { p2m_limit = (phys_addr_t)P2M_LIMIT * 1024 * 1024 * 1024 / PAGE_SIZE; vm.flags = VM_ALLOC; vm.size = ALIGN(sizeof(unsigned long) * max(xen_max_p2m_pfn, p2m_limit), PMD_SIZE * PMDS_PER_MID_PAGE); vm_area_register_early(&vm, PMD_SIZE * PMDS_PER_MID_PAGE); pr_notice("p2...
void xen_vmalloc_p2m_tree(void) { p2m_limit = (phys_addr_t)P2M_LIMIT * 1024 * 1024 * 1024 / PAGE_SIZE; if (!p2m_limit && IS_ENABLED(CONFIG_XEN_UNPOPULATED_ALLOC)) { p2m_limit = xen_start_info->nr_pages * XEN_EXTRA_MEM_RATIO; } vm.flags = VM_ALLOC; vm.size = ALIGN(sizeof(unsigned long) * max(...
void xen_vmalloc_p2m_tree(void) { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ p2m_limit = (phys_addr_t)P2M_LIMIT * 1024 * 1024 * 1024 / PAGE_SIZE; vm.flags = VM_ALLOC; vm.size = ALIGN(sizeof(unsigned long) * max(xen_max_p2m_pfn, p2m_limit), PMD_SIZE * PMDS_PER_MID_PAGE); vm_area_register_early(&vm...
void xen_vmalloc_p2m_tree(void) { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ p2m_limit = (phys_addr_t)P2M_LIMIT * 1024 * 1024 * 1024 / PAGE_SIZE; if (!p2m_limit && IS_ENABLED(CONFIG_XEN_UNPOPULATED_ALLOC)) { p2m_limit = xen_start_info->nr_pages * XEN_EXTRA_MEM_RATIO; } vm.flags = VM_ALLOC...
void xen_vmalloc_p2m_tree(void) { p2m_limit = (phys_addr_t)P2M_LIMIT * 1024 * 1024 * 1024 / PAGE_SIZE; + if (!p2m_limit && IS_ENABLED(CONFIG_XEN_UNPOPULATED_ALLOC)) { + p2m_limit = xen_start_info->nr_pages * XEN_EXTRA_MEM_RATIO; + } vm.flags = VM_ALLOC; vm.size = ALIGN(sizeof(unsigned long)...
CVE-2021-28039
linux
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux
arch/x86/xen/setup.c
xen_memory_setup
char * xen_memory_setup(void) { unsigned long max_pfn, pfn_s, n_pfns; phys_addr_t mem_end, addr, size, chunk_size; u32 type; int rc; struct xen_memory_map memmap; unsigned long max_pages; unsigned long extra_pages = 0; int i; int op; xen_parse_512gb(); max_pfn = xen_get_pages...
char * xen_memory_setup(void) { unsigned long max_pfn, pfn_s, n_pfns; phys_addr_t mem_end, addr, size, chunk_size; u32 type; int rc; struct xen_memory_map memmap; unsigned long max_pages; unsigned long extra_pages = 0; int i; int op; xen_parse_512gb(); max_pfn = xen_get_pages...
char * xen_memory_setup(void) { unsigned long max_pfn, pfn_s, n_pfns; phys_addr_t mem_end, addr, size, chunk_size; u32 type; int rc; struct xen_memory_map memmap; unsigned long max_pages; unsigned long extra_pages = 0; int i; int op; xen_parse_512gb(); max_pfn = xen_get_pages...
char * xen_memory_setup(void) { unsigned long max_pfn, pfn_s, n_pfns; phys_addr_t mem_end, addr, size, chunk_size; u32 type; int rc; struct xen_memory_map memmap; unsigned long max_pages; unsigned long extra_pages = 0; int i; int op; xen_parse_512gb(); max_pfn = xen_get_pages...
char * xen_memory_setup(void) { unsigned long extra_pages = 0; max_pfn = xen_get_pages_limit(); max_pfn = min(max_pfn, xen_start_info->nr_pages); mem_end = PFN_PHYS(max_pfn); max_pages = xen_get_max_pages(); max_pages += xen_foreach_remap_area(max_pfn, xen_count_remap_pages); if (max_pages >...
char * xen_memory_setup(void) { unsigned long extra_pages = 0; max_pfn = xen_get_pages_limit(); max_pfn = min(max_pfn, xen_start_info->nr_pages); mem_end = PFN_PHYS(max_pfn); max_pages = xen_get_max_pages(); max_pages += xen_foreach_remap_area(max_pfn, xen_count_remap_pages); if (max_pages >...
char * xen_memory_setup(void) { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ unsigned long extra_pages = 0; /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ max_pfn = xen_get_pages_limit(); max_pfn = min(max_pfn, xen_start_info->nr_pages); mem_end = PFN_PHYS(max_pfn); /* PLACEHOLDER: DO NOT DE...
char * xen_memory_setup(void) { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ unsigned long extra_pages = 0; /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ max_pfn = xen_get_pages_limit(); max_pfn = min(max_pfn, xen_start_info->nr_pages); mem_end = PFN_PHYS(max_pfn); /* PLACEHOLDER: DO NOT DE...
char * xen_memory_setup(void) { unsigned long extra_pages = 0; max_pfn = xen_get_pages_limit(); max_pfn = min(max_pfn, xen_start_info->nr_pages); mem_end = PFN_PHYS(max_pfn); max_pages = xen_get_max_pages(); max_pages += xen_foreach_remap_area(max_pfn, xen_count_remap_pages); if (max...
CVE-2021-28375
linux
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux
drivers/misc/fastrpc.c
fastrpc_internal_invoke
static int fastrpc_internal_invoke(struct fastrpc_user *fl, u32 kernel, u32 handle, u32 sc, struct fastrpc_invoke_args *args) { struct fastrpc_invoke_ctx *ctx = NULL; int err = 0; if (!fl->sctx) { return -EVAL; } if (!fl->cctx->rpdev) { return -EPIPE; } ctx = fastrpc_context_...
static int fastrpc_internal_invoke(struct fastrpc_user *fl, u32 kernel, u32 handle, u32 sc, struct fastrpc_invoke_args *args) { struct fastrpc_invoke_ctx *ctx = NULL; int err = 0; if (!fl->sctx) { return -EVAL; } if (!fl->cctx->rpdev) { return -EPIPE; } if (handle == FASTRPC_...
static int fastrpc_internal_invoke(struct fastrpc_user *fl, u32 kernel, u32 handle, u32 sc, struct fastrpc_invoke_args *args) { struct fastrpc_invoke_ctx *ctx = NULL; int err = 0; if (!fl->sctx) { return -EVAL; } if (!fl->cctx->rpdev) { return -EPIPE; } ctx = fastrpc_context_...
static int fastrpc_internal_invoke(struct fastrpc_user *fl, u32 kernel, u32 handle, u32 sc, struct fastrpc_invoke_args *args) { struct fastrpc_invoke_ctx *ctx = NULL; int err = 0; if (!fl->sctx) { return -EVAL; } if (!fl->cctx->rpdev) { return -EPIPE; } if (handle == FASTRPC_...
static int fastrpc_internal_invoke(struct fastrpc_user *fl, u32 kernel, u32 handle, u32 sc, struct fastrpc_invoke_args *args) { if (!fl->cctx->rpdev) { return -EPIPE; } ctx = fastrpc_context_alloc(fl, kernel, sc, args); if (IS_ERR(ctx)) { return PTR_ERR(ctx); } if (ctx->nscalars)...
static int fastrpc_internal_invoke(struct fastrpc_user *fl, u32 kernel, u32 handle, u32 sc, struct fastrpc_invoke_args *args) { if (!fl->cctx->rpdev) { return -EPIPE; } if (handle == FASTRPC_IT_HANDLE && !kernel) { dev_warn_ratelimited(fl->sctx->dev, "user app trying to send a kernel RPC mes...
static int fastrpc_internal_invoke(struct fastrpc_user *fl, u32 kernel, u32 handle, u32 sc, struct fastrpc_invoke_args *args) { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ if (!fl->cctx->rpdev) { return -EPIPE; } ctx = fastrpc_context_alloc(fl, kernel, sc, args); if (IS_ERR(ctx)) { ...
static int fastrpc_internal_invoke(struct fastrpc_user *fl, u32 kernel, u32 handle, u32 sc, struct fastrpc_invoke_args *args) { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ if (!fl->cctx->rpdev) { return -EPIPE; } if (handle == FASTRPC_IT_HANDLE && !kernel) { dev_warn_ratelimited(fl->sc...
static int fastrpc_internal_invoke(struct fastrpc_user *fl, u32 kernel, u32 handle, u32 sc, struct fastrpc_invoke_args *args) { if (!fl->cctx->rpdev) { return -EPIPE; + } + if (handle == FASTRPC_IT_HANDLE && !kernel) { + dev_warn_ratelimited(fl->sctx->dev, "user app trying to send a kernel R...
CVE-2021-28660
linux
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux
drivers/staging/rtl8188eu/os_dep/ioctl_linux.c
rtw_wx_set_scan
static int rtw_wx_set_scan(struct net_device *dev, struct iw_request_info *a, union iwreq_data *wrqu, char *extra) { u8 _status = false; int ret = 0; struct adapter *padapter = (struct adapter *)rtw_netdev_priv(dev); struct mlme_priv *pmlmepriv = &padapter->mlmepriv; struct ndis_802_11_ssid ssid[RTW...
static int rtw_wx_set_scan(struct net_device *dev, struct iw_request_info *a, union iwreq_data *wrqu, char *extra) { u8 _status = false; int ret = 0; struct adapter *padapter = (struct adapter *)rtw_netdev_priv(dev); struct mlme_priv *pmlmepriv = &padapter->mlmepriv; struct ndis_802_11_ssid ssid[RTW...
static int rtw_wx_set_scan(struct net_device *dev, struct iw_request_info *a, union iwreq_data *wrqu, char *extra) { u8 _status = false; int ret = 0; struct adapter *padapter = rtw_netdev_priv(dev); struct mlme_priv *pmlmepriv = &padapter->mlmepriv; struct ndis_802_11_ssid ssid[RTW_SSID_SCAN_AMOUNT]...
static int rtw_wx_set_scan(struct net_device *dev, struct iw_request_info *a, union iwreq_data *wrqu, char *extra) { u8 _status = false; int ret = 0; struct adapter *padapter = rtw_netdev_priv(dev); struct mlme_priv *pmlmepriv = &padapter->mlmepriv; struct ndis_802_11_ssid ssid[RTW_SSID_SCAN_AMOUNT]...
static int rtw_wx_set_scan(struct net_device *dev, struct iw_request_info *a, union iwreq_data *wrqu, char *extra) { if (wrqu->data.length == sizeof(struct iw_scan_req)) { } else { if (wrqu->data.length >= WEXT_CSCAN_HEADER_SIZE && !memcmp(extra, WEXT_CSCAN_HEADER, WEXT_CSCAN_HEADER_SIZE)) { ...
static int rtw_wx_set_scan(struct net_device *dev, struct iw_request_info *a, union iwreq_data *wrqu, char *extra) { if (wrqu->data.length == sizeof(struct iw_scan_req)) { } else { if (wrqu->data.length >= WEXT_CSCAN_HEADER_SIZE && !memcmp(extra, WEXT_CSCAN_HEADER, WEXT_CSCAN_HEADER_SIZE)) { ...
static int rtw_wx_set_scan(struct net_device *dev, struct iw_request_info *a, union iwreq_data *wrqu, char *extra) { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ if (wrqu->data.length == sizeof(struct iw_scan_req)) { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ } else { if (wrqu->data.length >...
static int rtw_wx_set_scan(struct net_device *dev, struct iw_request_info *a, union iwreq_data *wrqu, char *extra) { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ if (wrqu->data.length == sizeof(struct iw_scan_req)) { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ } else { if (wrqu->data.length >...
static int rtw_wx_set_scan(struct net_device *dev, struct iw_request_info *a, union iwreq_data *wrqu, char *extra) { if (wrqu->data.length == sizeof(struct iw_scan_req)) { } else { if (wrqu->data.length >= WEXT_CSCAN_HEADER_SIZE && !memcmp(extra, WEXT_CSCAN_HEADER, WEXT_CSCAN_HEADER_SIZE)) { ...
CVE-2021-28688
linux
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux
drivers/block/xen-blkback/blkback.c
xen_blkbk_map
static int xen_blkbk_map(struct xen_blkif_ring *ring, struct grant_page *pages[], int num, bool ro) { struct gnttab_map_grant_ref map[BLKIF_MAX_SEGMENTS_PER_REQUEST]; struct page *pages_to_gnt[BLKIF_MAX_SEGMENTS_PER_REQUEST]; struct persistent_gnt *persistent_gnt = NULL; phys_addr_t addr = 0; int i,...
static int xen_blkbk_map(struct xen_blkif_ring *ring, struct grant_page *pages[], int num, bool ro) { struct gnttab_map_grant_ref map[BLKIF_MAX_SEGMENTS_PER_REQUEST]; struct page *pages_to_gnt[BLKIF_MAX_SEGMENTS_PER_REQUEST]; struct persistent_gnt *persistent_gnt = NULL; phys_addr_t addr = 0; int i,...
static int xen_blkbk_map(struct xen_blkif *blkif, struct grant_page *pages[], int num, bool ro) { struct gnttab_map_grant_ref map[BLKIF_MAX_SEGMENTS_PER_REQUEST]; struct page *pages_to_gnt[BLKIF_MAX_SEGMENTS_PER_REQUEST]; struct persistent_gnt *persistent_gnt = NULL; phys_addr_t addr = 0; int i, seg...
static int xen_blkbk_map(struct xen_blkif *blkif, struct grant_page *pages[], int num, bool ro) { struct gnttab_map_grant_ref map[BLKIF_MAX_SEGMENTS_PER_REQUEST]; struct page *pages_to_gnt[BLKIF_MAX_SEGMENTS_PER_REQUEST]; struct persistent_gnt *persistent_gnt = NULL; phys_addr_t addr = 0; int i, seg...
static int xen_blkbk_map(struct xen_blkif_ring *ring, struct grant_page *pages[], int num, bool ro) { struct persistent_gnt *persistent_gnt = NULL; int segs_to_map = 0; int ret = 0; int last_map = 0, map_until = 0; struct xen_blkif *blkif = ring->blkif; again: for (i = map_until; i < num; i++) {...
static int xen_blkbk_map(struct xen_blkif_ring *ring, struct grant_page *pages[], int num, bool ro) { struct persistent_gnt *persistent_gnt = NULL; int segs_to_map = 0; int ret = 0; int last_map = 0, map_until = 0; struct xen_blkif *blkif = ring->blkif; again: for (i = map_until; i < num; i++) {...
static int xen_blkbk_map(struct xen_blkif *blkif, struct grant_page *pages[], int num, bool ro) { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ struct persistent_gnt *persistent_gnt = NULL; /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ int segs_to_map = 0; int ret = 0; int last_map = 0, map_unti...
static int xen_blkbk_map(struct xen_blkif *blkif, struct grant_page *pages[], int num, bool ro) { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ struct persistent_gnt *persistent_gnt = NULL; /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ int segs_to_map = 0; int ret = 0; int last_map = 0, map_unti...
static int xen_blkbk_map(struct xen_blkif_ring *ring, struct grant_page *pages[], int num, bool ro) { struct persistent_gnt *persistent_gnt = NULL; int segs_to_map = 0; int ret = 0; int last_map = 0, map_until = 0; struct xen_blkif *blkif = ring->blkif; again: for (i = map_until; i < num...
CVE-2021-28691
linux
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux
drivers/net/xen-netback/interface.c
xenvif_connect_data
int xenvif_connect_data(struct xenvif_queue *queue, unsigned long tx_ring_ref, unsigned long rx_ring_ref, unsigned int tx_evtchn, unsigned int rx_evtchn) { struct task_struct *task; int err; BUG_ON(queue->tx_irq); BUG_ON(queue->task); BUG_ON(queue->dealloc_task); err = xenvif_map_frontend_data_r...
int xenvif_connect_data(struct xenvif_queue *queue, unsigned long tx_ring_ref, unsigned long rx_ring_ref, unsigned int tx_evtchn, unsigned int rx_evtchn) { struct task_struct *task; int err; BUG_ON(queue->tx_irq); BUG_ON(queue->task); BUG_ON(queue->dealloc_task); err = xenvif_map_frontend_data_r...
int xenvif_connect_data(struct xenvif_queue *queue, unsigned long tx_ring_ref, unsigned long rx_ring_ref, unsigned int tx_evtchn, unsigned int rx_evtchn) { struct xenbus_device *dev = xenvif_to_xenbus_device(queue->vif); struct task_struct *task; int err; BUG_ON(queue->tx_irq); BUG_ON(queue->task); ...
int xenvif_connect_data(struct xenvif_queue *queue, unsigned long tx_ring_ref, unsigned long rx_ring_ref, unsigned int tx_evtchn, unsigned int rx_evtchn) { struct xenbus_device *dev = xenvif_to_xenbus_device(queue->vif); struct task_struct *task; int err; BUG_ON(queue->tx_irq); BUG_ON(queue->task); ...
int xenvif_connect_data(struct xenvif_queue *queue, unsigned long tx_ring_ref, unsigned long rx_ring_ref, unsigned int tx_evtchn, unsigned int rx_evtchn) { err = xenvif_map_frontend_data_rings(queue, tx_ring_ref, rx_ring_ref); task = kthread_run(xenvif_kthread_guest_rx, queue, "%s-guest-rx", queue->name); i...
int xenvif_connect_data(struct xenvif_queue *queue, unsigned long tx_ring_ref, unsigned long rx_ring_ref, unsigned int tx_evtchn, unsigned int rx_evtchn) { err = xenvif_map_frontend_data_rings(queue, tx_ring_ref, rx_ring_ref); task = kthread_run(xenvif_kthread_guest_rx, queue, "%s-guest-rx", queue->name); i...
int xenvif_connect_data(struct xenvif_queue *queue, unsigned long tx_ring_ref, unsigned long rx_ring_ref, unsigned int tx_evtchn, unsigned int rx_evtchn) { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ err = xenvif_map_frontend_data_rings(queue, tx_ring_ref, rx_ring_ref); /* PLACEHOLDER: DO NOT DELETE THIS ...
int xenvif_connect_data(struct xenvif_queue *queue, unsigned long tx_ring_ref, unsigned long rx_ring_ref, unsigned int tx_evtchn, unsigned int rx_evtchn) { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ err = xenvif_map_frontend_data_rings(queue, tx_ring_ref, rx_ring_ref); /* PLACEHOLDER: DO NOT DELETE THIS ...
int xenvif_connect_data(struct xenvif_queue *queue, unsigned long tx_ring_ref, unsigned long rx_ring_ref, unsigned int tx_evtchn, unsigned int rx_evtchn) { err = xenvif_map_frontend_data_rings(queue, tx_ring_ref, rx_ring_ref); task = kthread_run(xenvif_kthread_guest_rx, queue, "%s-guest-rx", queue->name); ...
CVE-2021-28691
linux
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux
drivers/net/xen-netback/interface.c
xenvif_disconnect_queue
static void xenvif_disconnect_queue(struct xenvif_queue *queue) { if (queue->task) { kthread_stop(queue->task); queue->task = NULL; } if (queue->dealloc_task) { kthread_stop(queue->dealloc_task); queue->dealloc_task = NULL; } if (queue->napi.poll) { netif_napi...
static void xenvif_disconnect_queue(struct xenvif_queue *queue) { if (queue->task) { kthread_stop(queue->task); put_task_struct(queue->task); queue->task = NULL; } if (queue->dealloc_task) { kthread_stop(queue->dealloc_task); queue->dealloc_task = NULL; } if (...
static void xenvif_disconnect_queue(struct xenvif_queue *queue) { if (queue->task) { kthread_stop(queue->task); queue->task = NULL; } if (queue->dealloc_task) { kthread_stop(queue->dealloc_task); queue->dealloc_task = NULL; } if (queue->napi.poll) { netif_napi...
static void xenvif_disconnect_queue(struct xenvif_queue *queue) { if (queue->task) { kthread_stop(queue->task); put_task_struct(queue->task); queue->task = NULL; } if (queue->dealloc_task) { kthread_stop(queue->dealloc_task); queue->dealloc_task = NULL; } if (...
static void xenvif_disconnect_queue(struct xenvif_queue *queue) { if (queue->task) { kthread_stop(queue->task); queue->task = NULL; } }
static void xenvif_disconnect_queue(struct xenvif_queue *queue) { if (queue->task) { kthread_stop(queue->task); put_task_struct(queue->task); queue->task = NULL; } }
static void xenvif_disconnect_queue(struct xenvif_queue *queue) { if (queue->task) { kthread_stop(queue->task); queue->task = NULL; } /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ }
static void xenvif_disconnect_queue(struct xenvif_queue *queue) { if (queue->task) { kthread_stop(queue->task); put_task_struct(queue->task); queue->task = NULL; } /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ }
static void xenvif_disconnect_queue(struct xenvif_queue *queue) { if (queue->task) { kthread_stop(queue->task); + put_task_struct(queue->task); queue->task = NULL; } }
CVE-2021-28711
linux
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux
drivers/block/xen-blkfront.c
blkif_interrupt
static irqreturn_t blkif_interrupt(int irq, void *dev_id) { struct request *req; struct blkif_response bret; RG_IDX i, rp; unsigned long flags; struct blkfront_info *info = (struct blkfront_info *)dev_id; int error; spin_lock_irqsave(&info->io_lock, flags); if (unlikely(info->connected !...
static irqreturn_t blkif_interrupt(int irq, void *dev_id) { struct request *req; struct blkif_response bret; RG_IDX i, rp; unsigned long flags; struct blkfront_info *info = (struct blkfront_info *)dev_id; int error; unsigned int eoiflag = XEN_EOI_FLAG_SPURIOUS; spin_lock_irqsave(&info->i...
static irqreturn_t blkif_interrupt(int irq, void *dev_id) { struct request *req; struct blkif_response bret; RG_IDX i, rp; unsigned long flags; struct blkfront_ring_info *rinfo = (struct blkfront_ring_info *)dev_id; struct blkfront_info *info = rinfo->dev_info; if (unlikely(info->connected !...
static irqreturn_t blkif_interrupt(int irq, void *dev_id) { struct request *req; struct blkif_response bret; RG_IDX i, rp; unsigned long flags; struct blkfront_ring_info *rinfo = (struct blkfront_ring_info *)dev_id; struct blkfront_info *info = rinfo->dev_info; unsigned int eoiflag = XEN_EOI...
static irqreturn_t blkif_interrupt(int irq, void *dev_id) { struct blkfront_info *info = (struct blkfront_info *)dev_id; int error; spin_lock_irqsave(&info->io_lock, flags); if (unlikely(info->connected != BLKIF_STATE_CONNECTED)) { spin_unlock_irqrestore(&info->io_lock, flags); return IR...
static irqreturn_t blkif_interrupt(int irq, void *dev_id) { struct blkfront_info *info = (struct blkfront_info *)dev_id; int error; unsigned int eoiflag = XEN_EOI_FLAG_SPURIOUS; spin_lock_irqsave(&info->io_lock, flags); if (unlikely(info->connected != BLKIF_STATE_CONNECTED)) { spin_unlock_ir...
static irqreturn_t blkif_interrupt(int irq, void *dev_id) { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ struct blkfront_ring_info *rinfo = (struct blkfront_ring_info *)dev_id; struct blkfront_info *info = rinfo->dev_info; if (unlikely(info->connected != BLKIF_STATE_CONNECTED)) { return IRQ_HAN...
static irqreturn_t blkif_interrupt(int irq, void *dev_id) { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ struct blkfront_ring_info *rinfo = (struct blkfront_ring_info *)dev_id; struct blkfront_info *info = rinfo->dev_info; unsigned int eoiflag = XEN_EOI_FLAG_SPURIOUS; if (unlikely(info->connected !...
static irqreturn_t blkif_interrupt(int irq, void *dev_id) { struct blkfront_info *info = (struct blkfront_info *)dev_id; int error; + unsigned int eoiflag = XEN_EOI_FLAG_SPURIOUS; spin_lock_irqsave(&info->io_lock, flags); if (unlikely(info->connected != BLKIF_STATE_CONNECTED)) { spin_un...
CVE-2021-28711
linux
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux
drivers/block/xen-blkfront.c
setup_blkring
static int setup_blkring(struct xenbus_device *dev, struct blkfront_info *info) { struct blkif_sring *sring; int err, i; unsigned long ring_size = info->nr_ring_pages * XEN_PAGE_SIZE; grant_ref_t gref[XENBUS_MAX_RG_GRANTS]; for (i = 0; i < info->nr_ring_pages; i++) info->ring_ref[i] = GRANT_...
static int setup_blkring(struct xenbus_device *dev, struct blkfront_info *info) { struct blkif_sring *sring; int err, i; unsigned long ring_size = info->nr_ring_pages * XEN_PAGE_SIZE; grant_ref_t gref[XENBUS_MAX_RG_GRANTS]; for (i = 0; i < info->nr_ring_pages; i++) info->ring_ref[i] = GRANT_...
static int setup_blkring(struct xenbus_device *dev, struct blkfront_ring_info *rinfo) { struct blkif_sring *sring; int err, i; struct blkfront_info *info = rinfo->dev_info; unsigned long ring_size = info->nr_ring_pages * XEN_PAGE_SIZE; grant_ref_t gref[XENBUS_MAX_RG_GRANTS]; for (i = 0; i < info...
static int setup_blkring(struct xenbus_device *dev, struct blkfront_ring_info *rinfo) { struct blkif_sring *sring; int err, i; struct blkfront_info *info = rinfo->dev_info; unsigned long ring_size = info->nr_ring_pages * XEN_PAGE_SIZE; grant_ref_t gref[XENBUS_MAX_RG_GRANTS]; for (i = 0; i < info...
static int setup_blkring(struct xenbus_device *dev, struct blkfront_info *info) { if (err) { goto fail; } err = bind_evtchn_to_irqhandler(info->evtchn, blkif_interrupt, 0, "blkif", info); if (err <= 0) { xenbus_dev_fatal(dev, err, "bind_evtchn_to_irqhandler failed"); goto fail; ...
static int setup_blkring(struct xenbus_device *dev, struct blkfront_info *info) { if (err) { goto fail; } err = bind_evtchn_to_irqhandler_lateeoi(info->evtchn, blkif_interrupt, 0, "blkif", info); if (err <= 0) { xenbus_dev_fatal(dev, err, "bind_evtchn_to_irqhandler failed"); goto...
static int setup_blkring(struct xenbus_device *dev, struct blkfront_ring_info *rinfo) { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ if (err) { goto fail; } err = bind_evtchn_to_irqhandler(rinfo->evtchn, blkif_interrupt, 0, "blkif", rinfo); if (err <= 0) { xenbus_dev_fatal(dev, err,...
static int setup_blkring(struct xenbus_device *dev, struct blkfront_ring_info *rinfo) { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ if (err) { goto fail; } err = bind_evtchn_to_irqhandler_lateeoi(rinfo->evtchn, blkif_interrupt, 0, "blkif", rinfo); if (err <= 0) { xenbus_dev_fatal(d...
static int setup_blkring(struct xenbus_device *dev, struct blkfront_info *info) { if (err) { goto fail; } - err = bind_evtchn_to_irqhandler(info->evtchn, blkif_interrupt, 0, "blkif", info); + err = bind_evtchn_to_irqhandler_lateeoi(info->evtchn, blkif_interrupt, 0, "blkif", info); if (err...
CVE-2021-28712
linux
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux
drivers/net/xen-netfront.c
setup_netfront_single
static int setup_netfront_single(struct netfront_queue *queue) { int err; err = xenbus_alloc_evtchn(queue->info->xbdev, &queue->tx_evtchn); if (err < 0) { goto fail; } err = bind_evtchn_to_irqhandler(queue->tx_evtchn, xennet_interrupt, 0, queue->info->netdev->name, queue); if (err < 0) {...
static int setup_netfront_single(struct netfront_queue *queue) { int err; err = xenbus_alloc_evtchn(queue->info->xbdev, &queue->tx_evtchn); if (err < 0) { goto fail; } err = bind_evtchn_to_irqhandler_lateeoi(queue->tx_evtchn, xennet_interrupt, 0, queue->info->netdev->name, queue); if (er...
static int setup_netfront_single(struct netfront_queue *queue) { int err; err = xenbus_alloc_evtchn(queue->info->xbdev, &queue->tx_evtchn); if (err < 0) { goto fail; } err = bind_evtchn_to_irqhandler(queue->tx_evtchn, xennet_interrupt, 0, queue->info->netdev->name, queue); if (err < 0) {...
static int setup_netfront_single(struct netfront_queue *queue) { int err; err = xenbus_alloc_evtchn(queue->info->xbdev, &queue->tx_evtchn); if (err < 0) { goto fail; } err = bind_evtchn_to_irqhandler_lateeoi(queue->tx_evtchn, xennet_interrupt, 0, queue->info->netdev->name, queue); if (er...
static int setup_netfront_single(struct netfront_queue *queue) { if (err < 0) { goto fail; } err = bind_evtchn_to_irqhandler(queue->tx_evtchn, xennet_interrupt, 0, queue->info->netdev->name, queue); if (err < 0) { goto bind_fail; } queue->rx_evtchn = queue->tx_evtchn; queue->...
static int setup_netfront_single(struct netfront_queue *queue) { if (err < 0) { goto fail; } err = bind_evtchn_to_irqhandler_lateeoi(queue->tx_evtchn, xennet_interrupt, 0, queue->info->netdev->name, queue); if (err < 0) { goto bind_fail; } queue->rx_evtchn = queue->tx_evtchn; ...
static int setup_netfront_single(struct netfront_queue *queue) { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ if (err < 0) { goto fail; } err = bind_evtchn_to_irqhandler(queue->tx_evtchn, xennet_interrupt, 0, queue->info->netdev->name, queue); if (err < 0) { goto bind_fail; } ...
static int setup_netfront_single(struct netfront_queue *queue) { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ if (err < 0) { goto fail; } err = bind_evtchn_to_irqhandler_lateeoi(queue->tx_evtchn, xennet_interrupt, 0, queue->info->netdev->name, queue); if (err < 0) { goto bind_fail; ...
static int setup_netfront_single(struct netfront_queue *queue) { if (err < 0) { goto fail; } - err = bind_evtchn_to_irqhandler(queue->tx_evtchn, xennet_interrupt, 0, queue->info->netdev->name, queue); + err = bind_evtchn_to_irqhandler_lateeoi(queue->tx_evtchn, xennet_interrupt, 0, queue->info-...
CVE-2021-28712
linux
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux
drivers/net/xen-netfront.c
setup_netfront_split
static int setup_netfront_split(struct netfront_queue *queue) { int err; err = xenbus_alloc_evtchn(queue->info->xbdev, &queue->tx_evtchn); if (err < 0) { goto fail; } err = xenbus_alloc_evtchn(queue->info->xbdev, &queue->rx_evtchn); if (err < 0) { goto alloc_rx_evtchn_fail; }...
static int setup_netfront_split(struct netfront_queue *queue) { int err; err = xenbus_alloc_evtchn(queue->info->xbdev, &queue->tx_evtchn); if (err < 0) { goto fail; } err = xenbus_alloc_evtchn(queue->info->xbdev, &queue->rx_evtchn); if (err < 0) { goto alloc_rx_evtchn_fail; }...
static int setup_netfront_split(struct netfront_queue *queue) { int err; err = xenbus_alloc_evtchn(queue->info->xbdev, &queue->tx_evtchn); if (err < 0) { goto fail; } err = xenbus_alloc_evtchn(queue->info->xbdev, &queue->rx_evtchn); if (err < 0) { goto alloc_rx_evtchn_fail; }...
static int setup_netfront_split(struct netfront_queue *queue) { int err; err = xenbus_alloc_evtchn(queue->info->xbdev, &queue->tx_evtchn); if (err < 0) { goto fail; } err = xenbus_alloc_evtchn(queue->info->xbdev, &queue->rx_evtchn); if (err < 0) { goto alloc_rx_evtchn_fail; }...
static int setup_netfront_split(struct netfront_queue *queue) { snprintf(queue->tx_irq_name, sizeof(queue->tx_irq_name), "%s-tx", queue->name); err = bind_evtchn_to_irqhandler(queue->tx_evtchn, xennet_tx_interrupt, 0, queue->tx_irq_name, queue); if (err < 0) { goto bind_tx_fail; } queue->tx_...
static int setup_netfront_split(struct netfront_queue *queue) { snprintf(queue->tx_irq_name, sizeof(queue->tx_irq_name), "%s-tx", queue->name); err = bind_evtchn_to_irqhandler_lateeoi(queue->tx_evtchn, xennet_tx_interrupt, 0, queue->tx_irq_name, queue); if (err < 0) { goto bind_tx_fail; } qu...
static int setup_netfront_split(struct netfront_queue *queue) { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ snprintf(queue->tx_irq_name, sizeof(queue->tx_irq_name), "%s-tx", queue->name); err = bind_evtchn_to_irqhandler(queue->tx_evtchn, xennet_tx_interrupt, 0, queue->tx_irq_name, queue); if (err < 0)...
static int setup_netfront_split(struct netfront_queue *queue) { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ snprintf(queue->tx_irq_name, sizeof(queue->tx_irq_name), "%s-tx", queue->name); err = bind_evtchn_to_irqhandler_lateeoi(queue->tx_evtchn, xennet_tx_interrupt, 0, queue->tx_irq_name, queue); if (...
static int setup_netfront_split(struct netfront_queue *queue) { snprintf(queue->tx_irq_name, sizeof(queue->tx_irq_name), "%s-tx", queue->name); - err = bind_evtchn_to_irqhandler(queue->tx_evtchn, xennet_tx_interrupt, 0, queue->tx_irq_name, queue); + err = bind_evtchn_to_irqhandler_lateeoi(queue->tx_evtchn, ...
CVE-2021-28712
linux
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux
drivers/net/xen-netfront.c
xennet_fill_frags
static int xennet_fill_frags(struct netfront_queue *queue, struct sk_buff *skb, struct sk_buff_head *list) { RG_IDX cons = queue->rx.rsp_cons; struct sk_buff *nskb; while ((nskb = __skb_dequeue(list))) { struct xen_netif_rx_response rx; skb_frag_t *nfrag = &skb_shinfo(nskb)->frags[0]; ...
static int xennet_fill_frags(struct netfront_queue *queue, struct sk_buff *skb, struct sk_buff_head *list) { RG_IDX cons = queue->rx.rsp_cons; struct sk_buff *nskb; while ((nskb = __skb_dequeue(list))) { struct xen_netif_rx_response rx; skb_frag_t *nfrag = &skb_shinfo(nskb)->frags[0]; ...
static int xennet_fill_frags(struct netfront_queue *queue, struct sk_buff *skb, struct sk_buff_head *list) { RG_IDX cons = queue->rx.rsp_cons; struct sk_buff *nskb; while ((nskb = __skb_dequeue(list))) { struct xen_netif_rx_response rx; skb_frag_t *nfrag = &skb_shinfo(nskb)->frags[0]; ...
static int xennet_fill_frags(struct netfront_queue *queue, struct sk_buff *skb, struct sk_buff_head *list) { RG_IDX cons = queue->rx.rsp_cons; struct sk_buff *nskb; while ((nskb = __skb_dequeue(list))) { struct xen_netif_rx_response rx; skb_frag_t *nfrag = &skb_shinfo(nskb)->frags[0]; ...
static int xennet_fill_frags(struct netfront_queue *queue, struct sk_buff *skb, struct sk_buff_head *list) { RG_IDX cons = queue->rx.rsp_cons; while ((nskb = __skb_dequeue(list))) { struct xen_netif_rx_response rx; skb_frag_t *nfrag = &skb_shinfo(nskb)->frags[0]; RG_COPY_RESPONSE(&queue-...
static int xennet_fill_frags(struct netfront_queue *queue, struct sk_buff *skb, struct sk_buff_head *list) { RG_IDX cons = queue->rx.rsp_cons; while ((nskb = __skb_dequeue(list))) { struct xen_netif_rx_response rx; skb_frag_t *nfrag = &skb_shinfo(nskb)->frags[0]; RG_COPY_RESPONSE(&queue-...
static int xennet_fill_frags(struct netfront_queue *queue, struct sk_buff *skb, struct sk_buff_head *list) { RG_IDX cons = queue->rx.rsp_cons; /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ while ((nskb = __skb_dequeue(list))) { struct xen_netif_rx_response rx; skb_frag_t *nfrag = &skb_shinfo...
static int xennet_fill_frags(struct netfront_queue *queue, struct sk_buff *skb, struct sk_buff_head *list) { RG_IDX cons = queue->rx.rsp_cons; /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ while ((nskb = __skb_dequeue(list))) { struct xen_netif_rx_response rx; skb_frag_t *nfrag = &skb_shinfo...
static int xennet_fill_frags(struct netfront_queue *queue, struct sk_buff *skb, struct sk_buff_head *list) { RG_IDX cons = queue->rx.rsp_cons; while ((nskb = __skb_dequeue(list))) { struct xen_netif_rx_response rx; skb_frag_t *nfrag = &skb_shinfo(nskb)->frags[0]; RG_COPY_RESPONSE(&...
CVE-2021-28712
linux
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux
drivers/net/xen-netfront.c
xennet_get_extras
static int xennet_get_extras(struct netfront_queue *queue, struct xen_netif_extra_info *extras, RG_IDX rp) { struct xen_netif_extra_info extra; struct device *dev = &queue->info->netdev->dev; RG_IDX cons = queue->rx.rsp_cons; int err = 0; do { struct sk_buff *skb; grant_ref_t ref; ...
static int xennet_get_extras(struct netfront_queue *queue, struct xen_netif_extra_info *extras, RG_IDX rp) { struct xen_netif_extra_info extra; struct device *dev = &queue->info->netdev->dev; RG_IDX cons = queue->rx.rsp_cons; int err = 0; do { struct sk_buff *skb; grant_ref_t ref; ...
static int xennet_get_extras(struct netfront_queue *queue, struct xen_netif_extra_info *extras, RG_IDX rp) { struct xen_netif_extra_info extra; struct device *dev = &queue->info->netdev->dev; RG_IDX cons = queue->rx.rsp_cons; int err = 0; do { struct sk_buff *skb; grant_ref_t ref; ...
static int xennet_get_extras(struct netfront_queue *queue, struct xen_netif_extra_info *extras, RG_IDX rp) { struct xen_netif_extra_info extra; struct device *dev = &queue->info->netdev->dev; RG_IDX cons = queue->rx.rsp_cons; int err = 0; do { struct sk_buff *skb; grant_ref_t ref; ...
static int xennet_get_extras(struct netfront_queue *queue, struct xen_netif_extra_info *extras, RG_IDX rp) { RG_IDX cons = queue->rx.rsp_cons; do { struct sk_buff *skb; grant_ref_t ref; if (unlikely(cons + 1 == rp)) { if (net_ratelimit()) { dev_warn(dev, "Miss...
static int xennet_get_extras(struct netfront_queue *queue, struct xen_netif_extra_info *extras, RG_IDX rp) { RG_IDX cons = queue->rx.rsp_cons; do { struct sk_buff *skb; grant_ref_t ref; if (unlikely(cons + 1 == rp)) { if (net_ratelimit()) { dev_warn(dev, "Miss...
static int xennet_get_extras(struct netfront_queue *queue, struct xen_netif_extra_info *extras, RG_IDX rp) { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ RG_IDX cons = queue->rx.rsp_cons; /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ do { struct sk_buff *skb; grant_ref_t ref; if...
static int xennet_get_extras(struct netfront_queue *queue, struct xen_netif_extra_info *extras, RG_IDX rp) { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ RG_IDX cons = queue->rx.rsp_cons; /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ do { struct sk_buff *skb; grant_ref_t ref; if...
static int xennet_get_extras(struct netfront_queue *queue, struct xen_netif_extra_info *extras, RG_IDX rp) { RG_IDX cons = queue->rx.rsp_cons; do { struct sk_buff *skb; grant_ref_t ref; if (unlikely(cons + 1 == rp)) { if (net_ratelimit()) { dev_warn(de...
CVE-2021-28712
linux
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux
drivers/net/xen-netfront.c
xennet_get_responses
static int xennet_get_responses(struct netfront_queue *queue, struct netfront_rx_info *rinfo, RG_IDX rp, struct sk_buff_head *list) { struct xen_netif_rx_response *rx = &rinfo->rx, rx_local; struct xen_netif_extra_info *extras = rinfo->extras; struct device *dev = &queue->info->netdev->dev; RG_IDX cons ...
static int xennet_get_responses(struct netfront_queue *queue, struct netfront_rx_info *rinfo, RG_IDX rp, struct sk_buff_head *list) { struct xen_netif_rx_response *rx = &rinfo->rx, rx_local; struct xen_netif_extra_info *extras = rinfo->extras; struct device *dev = &queue->info->netdev->dev; RG_IDX cons ...
static int xennet_get_responses(struct netfront_queue *queue, struct netfront_rx_info *rinfo, RG_IDX rp, struct sk_buff_head *list, bool *need_xdp_flush) { struct xen_netif_rx_response *rx = &rinfo->rx, rx_local; int max = XEN_NETIF_NR_SLOTS_M + (rx->status <= RX_COPY_THRESHOLD); RG_IDX cons = queue->rx.rsp...
static int xennet_get_responses(struct netfront_queue *queue, struct netfront_rx_info *rinfo, RG_IDX rp, struct sk_buff_head *list, bool *need_xdp_flush) { struct xen_netif_rx_response *rx = &rinfo->rx, rx_local; int max = XEN_NETIF_NR_SLOTS_M + (rx->status <= RX_COPY_THRESHOLD); RG_IDX cons = queue->rx.rsp...
static int xennet_get_responses(struct netfront_queue *queue, struct netfront_rx_info *rinfo, RG_IDX rp, struct sk_buff_head *list) { struct xen_netif_rx_response *rx = &rinfo->rx, rx_local; struct xen_netif_extra_info *extras = rinfo->extras; RG_IDX cons = queue->rx.rsp_cons; struct sk_buff *skb = xenn...
static int xennet_get_responses(struct netfront_queue *queue, struct netfront_rx_info *rinfo, RG_IDX rp, struct sk_buff_head *list) { struct xen_netif_rx_response *rx = &rinfo->rx, rx_local; struct xen_netif_extra_info *extras = rinfo->extras; RG_IDX cons = queue->rx.rsp_cons; struct sk_buff *skb = xenn...
static int xennet_get_responses(struct netfront_queue *queue, struct netfront_rx_info *rinfo, RG_IDX rp, struct sk_buff_head *list, bool *need_xdp_flush) { struct xen_netif_rx_response *rx = &rinfo->rx, rx_local; int max = XEN_NETIF_NR_SLOTS_M + (rx->status <= RX_COPY_THRESHOLD); RG_IDX cons = queue->rx.rsp...
static int xennet_get_responses(struct netfront_queue *queue, struct netfront_rx_info *rinfo, RG_IDX rp, struct sk_buff_head *list, bool *need_xdp_flush) { struct xen_netif_rx_response *rx = &rinfo->rx, rx_local; int max = XEN_NETIF_NR_SLOTS_M + (rx->status <= RX_COPY_THRESHOLD); RG_IDX cons = queue->rx.rsp...
static int xennet_get_responses(struct netfront_queue *queue, struct netfront_rx_info *rinfo, RG_IDX rp, struct sk_buff_head *list) { struct xen_netif_rx_response *rx = &rinfo->rx, rx_local; struct xen_netif_extra_info *extras = rinfo->extras; RG_IDX cons = queue->rx.rsp_cons; struct sk_buff *skb =...
CVE-2021-28712
linux
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux
drivers/net/xen-netfront.c
xennet_init_queue
static int xennet_init_queue(struct netfront_queue *queue) { unsigned short i; int err = 0; char *devid; spin_lock_init(&queue->tx_lock); spin_lock_init(&queue->rx_lock); setup_timer(&queue->rx_refill_timer, rx_refill_timeout, (unsigned long)queue); devid = strrchr(queue->info->xbdev->nodena...
static int xennet_init_queue(struct netfront_queue *queue) { unsigned short i; int err = 0; char *devid; spin_lock_init(&queue->tx_lock); spin_lock_init(&queue->rx_lock); spin_lock_init(&queue->rx_cons_lock); setup_timer(&queue->rx_refill_timer, rx_refill_timeout, (unsigned long)queue); ...
static int xennet_init_queue(struct netfront_queue *queue) { unsigned short i; int err = 0; char *devid; spin_lock_init(&queue->tx_lock); spin_lock_init(&queue->rx_lock); timer_setup(&queue->rx_refill_timer, rx_refill_timeout, 0); devid = strrchr(queue->info->xbdev->nodename, '/') + 1; s...
static int xennet_init_queue(struct netfront_queue *queue) { unsigned short i; int err = 0; char *devid; spin_lock_init(&queue->tx_lock); spin_lock_init(&queue->rx_lock); spin_lock_init(&queue->rx_cons_lock); timer_setup(&queue->rx_refill_timer, rx_refill_timeout, 0); devid = strrchr(que...
static int xennet_init_queue(struct netfront_queue *queue) { spin_lock_init(&queue->rx_lock); setup_timer(&queue->rx_refill_timer, rx_refill_timeout, (unsigned long)queue); }
static int xennet_init_queue(struct netfront_queue *queue) { spin_lock_init(&queue->rx_lock); spin_lock_init(&queue->rx_cons_lock); setup_timer(&queue->rx_refill_timer, rx_refill_timeout, (unsigned long)queue); }
static int xennet_init_queue(struct netfront_queue *queue) { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ spin_lock_init(&queue->rx_lock); timer_setup(&queue->rx_refill_timer, rx_refill_timeout, 0); /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ }
static int xennet_init_queue(struct netfront_queue *queue) { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ spin_lock_init(&queue->rx_lock); spin_lock_init(&queue->rx_cons_lock); timer_setup(&queue->rx_refill_timer, rx_refill_timeout, 0); /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ }
static int xennet_init_queue(struct netfront_queue *queue) { spin_lock_init(&queue->rx_lock); + spin_lock_init(&queue->rx_cons_lock); setup_timer(&queue->rx_refill_timer, rx_refill_timeout, (unsigned long)queue); }
CVE-2021-28712
linux
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux
drivers/net/xen-netfront.c
xennet_interrupt
static irqreturn_t xennet_interrupt(int irq, void *dev_id) { xennet_tx_interrupt(irq, dev_id); xennet_rx_interrupt(irq, dev_id); return IRQ_HANDLED; }
static irqreturn_t xennet_interrupt(int irq, void *dev_id) { unsigned int eoiflag = XEN_EOI_FLAG_SPURIOUS; if (xennet_handle_tx(dev_id, &eoiflag) && xennet_handle_rx(dev_id, &eoiflag)) { xen_irq_lateeoi(irq, eoiflag); } return IRQ_HANDLED; }
static irqreturn_t xennet_interrupt(int irq, void *dev_id) { xennet_tx_interrupt(irq, dev_id); xennet_rx_interrupt(irq, dev_id); return IRQ_HANDLED; }
static irqreturn_t xennet_interrupt(int irq, void *dev_id) { unsigned int eoiflag = XEN_EOI_FLAG_SPURIOUS; if (xennet_handle_tx(dev_id, &eoiflag) && xennet_handle_rx(dev_id, &eoiflag)) { xen_irq_lateeoi(irq, eoiflag); } return IRQ_HANDLED; }
static irqreturn_t xennet_interrupt(int irq, void *dev_id) { xennet_tx_interrupt(irq, dev_id); xennet_rx_interrupt(irq, dev_id); return IRQ_HANDLED; }
static irqreturn_t xennet_interrupt(int irq, void *dev_id) { unsigned int eoiflag = XEN_EOI_FLAG_SPURIOUS; if (xennet_handle_tx(dev_id, &eoiflag) && xennet_handle_rx(dev_id, &eoiflag)) { xen_irq_lateeoi(irq, eoiflag); } return IRQ_HANDLED; }
static irqreturn_t xennet_interrupt(int irq, void *dev_id) { xennet_tx_interrupt(irq, dev_id); xennet_rx_interrupt(irq, dev_id); return IRQ_HANDLED; }
static irqreturn_t xennet_interrupt(int irq, void *dev_id) { unsigned int eoiflag = XEN_EOI_FLAG_SPURIOUS; if (xennet_handle_tx(dev_id, &eoiflag) && xennet_handle_rx(dev_id, &eoiflag)) { xen_irq_lateeoi(irq, eoiflag); } return IRQ_HANDLED; }
static irqreturn_t xennet_interrupt(int irq, void *dev_id) { - xennet_tx_interrupt(irq, dev_id); - xennet_rx_interrupt(irq, dev_id); + unsigned int eoiflag = XEN_EOI_FLAG_SPURIOUS; + if (xennet_handle_tx(dev_id, &eoiflag) && xennet_handle_rx(dev_id, &eoiflag)) { + xen_irq_lateeoi(irq, eoiflag); + ...
CVE-2021-28712
linux
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux
drivers/net/xen-netfront.c
xennet_poll
static int xennet_poll(struct napi_struct *napi, int budget) { struct netfront_queue *queue = container_of(napi, struct netfront_queue, napi); struct net_device *dev = queue->info->netdev; struct sk_buff *skb; struct netfront_rx_info rinfo; struct xen_netif_rx_response *rx = &rinfo.rx; struct xe...
static int xennet_poll(struct napi_struct *napi, int budget) { struct netfront_queue *queue = container_of(napi, struct netfront_queue, napi); struct net_device *dev = queue->info->netdev; struct sk_buff *skb; struct netfront_rx_info rinfo; struct xen_netif_rx_response *rx = &rinfo.rx; struct xe...
static int xennet_poll(struct napi_struct *napi, int budget) { struct netfront_queue *queue = container_of(napi, struct netfront_queue, napi); struct net_device *dev = queue->info->netdev; struct sk_buff *skb; struct netfront_rx_info rinfo; struct xen_netif_rx_response *rx = &rinfo.rx; struct xe...
static int xennet_poll(struct napi_struct *napi, int budget) { struct netfront_queue *queue = container_of(napi, struct netfront_queue, napi); struct net_device *dev = queue->info->netdev; struct sk_buff *skb; struct netfront_rx_info rinfo; struct xen_netif_rx_response *rx = &rinfo.rx; struct xe...
static int xennet_poll(struct napi_struct *napi, int budget) { struct xen_netif_rx_response *rx = &rinfo.rx; rp = queue->rx.sring->rsp_prod; if (RG_RESPONSE_PROD_OVERFLOW(&queue->rx, rp)) { return 0; } i = queue->rx.rsp_cons; work_done = 0; while ((i != rp) && (work_done < budget)) {...
static int xennet_poll(struct napi_struct *napi, int budget) { struct xen_netif_rx_response *rx = &rinfo.rx; rp = queue->rx.sring->rsp_prod; if (RG_RESPONSE_PROD_OVERFLOW(&queue->rx, rp)) { return 0; } i = queue->rx.rsp_cons; work_done = 0; while ((i != rp) && (work_done < budget)) {...
static int xennet_poll(struct napi_struct *napi, int budget) { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ struct xen_netif_rx_response *rx = &rinfo.rx; /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ rp = queue->rx.sring->rsp_prod; if (RG_RESPONSE_PROD_OVERFLOW(&queue->rx, rp)) { /* PLACEHOLDER...
static int xennet_poll(struct napi_struct *napi, int budget) { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ struct xen_netif_rx_response *rx = &rinfo.rx; /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ rp = queue->rx.sring->rsp_prod; if (RG_RESPONSE_PROD_OVERFLOW(&queue->rx, rp)) { /* PLACEHOLDER...
static int xennet_poll(struct napi_struct *napi, int budget) { struct xen_netif_rx_response *rx = &rinfo.rx; rp = queue->rx.sring->rsp_prod; if (RG_RESPONSE_PROD_OVERFLOW(&queue->rx, rp)) { return 0; } i = queue->rx.rsp_cons; work_done = 0; while ((i != rp) && (work_done < b...
CVE-2021-28712
linux
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux
drivers/net/xen-netfront.c
xennet_rx_interrupt
static irqreturn_t xennet_rx_interrupt(int irq, void *dev_id) { struct netfront_queue *queue = dev_id; struct net_device *dev = queue->info->netdev; if (queue->info->broken) { return IRQ_HANDLED; } if (likely(netif_carrier_ok(dev) && RG_HAS_UNCONSUMED_RESPONSES(&queue->rx))) { napi_s...
static irqreturn_t xennet_rx_interrupt(int irq, void *dev_id) { unsigned int eoiflag = XEN_EOI_FLAG_SPURIOUS; if (likely(xennet_handle_rx(dev_id, &eoiflag))) { xen_irq_lateeoi(irq, eoiflag); } return IRQ_HANDLED; }
static irqreturn_t xennet_rx_interrupt(int irq, void *dev_id) { struct netfront_queue *queue = dev_id; struct net_device *dev = queue->info->netdev; if (queue->info->broken) { return IRQ_HANDLED; } if (likely(netif_carrier_ok(dev) && RG_HAS_UNCONSUMED_RESPONSES(&queue->rx))) { napi_s...
static irqreturn_t xennet_rx_interrupt(int irq, void *dev_id) { unsigned int eoiflag = XEN_EOI_FLAG_SPURIOUS; if (likely(xennet_handle_rx(dev_id, &eoiflag))) { xen_irq_lateeoi(irq, eoiflag); } return IRQ_HANDLED; }
static irqreturn_t xennet_rx_interrupt(int irq, void *dev_id) { struct netfront_queue *queue = dev_id; struct net_device *dev = queue->info->netdev; if (queue->info->broken) { return IRQ_HANDLED; } if (likely(netif_carrier_ok(dev) && RG_HAS_UNCONSUMED_RESPONSES(&queue->rx))) { napi_s...
static irqreturn_t xennet_rx_interrupt(int irq, void *dev_id) { unsigned int eoiflag = XEN_EOI_FLAG_SPURIOUS; if (likely(xennet_handle_rx(dev_id, &eoiflag))) { xen_irq_lateeoi(irq, eoiflag); } return IRQ_HANDLED; }
static irqreturn_t xennet_rx_interrupt(int irq, void *dev_id) { struct netfront_queue *queue = dev_id; struct net_device *dev = queue->info->netdev; if (queue->info->broken) { return IRQ_HANDLED; } if (likely(netif_carrier_ok(dev) && RG_HAS_UNCONSUMED_RESPONSES(&queue->rx))) { napi_s...
static irqreturn_t xennet_rx_interrupt(int irq, void *dev_id) { unsigned int eoiflag = XEN_EOI_FLAG_SPURIOUS; if (likely(xennet_handle_rx(dev_id, &eoiflag))) { xen_irq_lateeoi(irq, eoiflag); } return IRQ_HANDLED; }
static irqreturn_t xennet_rx_interrupt(int irq, void *dev_id) { - struct netfront_queue *queue = dev_id; - struct net_device *dev = queue->info->netdev; - if (queue->info->broken) { - return IRQ_HANDLED; - } - if (likely(netif_carrier_ok(dev) && RG_HAS_UNCONSUMED_RESPONSES(&queue->rx))) { - ...
CVE-2021-28712
linux
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux
drivers/net/xen-netfront.c
xennet_tx_buf_gc
static void xennet_tx_buf_gc(struct netfront_queue *queue) { RG_IDX cons, prod; unsigned short id; struct sk_buff *skb; const struct device *dev = &queue->info->netdev->dev; BUG_ON(!netif_carrier_ok(queue->info->netdev)); do { prod = queue->tx.sring->rsp_prod; if (RG_RESPONSE_PRO...
static bool xennet_tx_buf_gc(struct netfront_queue *queue) { RG_IDX cons, prod; unsigned short id; struct sk_buff *skb; bool work_done = false; const struct device *dev = &queue->info->netdev->dev; BUG_ON(!netif_carrier_ok(queue->info->netdev)); do { prod = queue->tx.sring->rsp_prod;...
static void xennet_tx_buf_gc(struct netfront_queue *queue) { RG_IDX cons, prod; unsigned short id; struct sk_buff *skb; bool more_to_do; const struct device *dev = &queue->info->netdev->dev; BUG_ON(!netif_carrier_ok(queue->info->netdev)); do { prod = queue->tx.sring->rsp_prod; ...
static bool xennet_tx_buf_gc(struct netfront_queue *queue) { RG_IDX cons, prod; unsigned short id; struct sk_buff *skb; bool more_to_do; bool work_done = false; const struct device *dev = &queue->info->netdev->dev; BUG_ON(!netif_carrier_ok(queue->info->netdev)); do { prod = queue...
static void xennet_tx_buf_gc(struct netfront_queue *queue) { struct sk_buff *skb; const struct device *dev = &queue->info->netdev->dev; do { prod = queue->tx.sring->rsp_prod; if (RG_RESPONSE_PROD_OVERFLOW(&queue->tx, prod)) { dev_alert(dev, "Illegal number of responses %u\n", pro...
static bool xennet_tx_buf_gc(struct netfront_queue *queue) { struct sk_buff *skb; bool work_done = false; const struct device *dev = &queue->info->netdev->dev; do { prod = queue->tx.sring->rsp_prod; if (RG_RESPONSE_PROD_OVERFLOW(&queue->tx, prod)) { dev_alert(dev, "Illegal nu...
static void xennet_tx_buf_gc(struct netfront_queue *queue) { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ struct sk_buff *skb; /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ const struct device *dev = &queue->info->netdev->dev; /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ do { prod = qu...
static bool xennet_tx_buf_gc(struct netfront_queue *queue) { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ struct sk_buff *skb; /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ bool work_done = false; const struct device *dev = &queue->info->netdev->dev; /* PLACEHOLDER: DO NOT DELETE THIS COMMENT *...
-static void xennet_tx_buf_gc(struct netfront_queue *queue) { +static bool xennet_tx_buf_gc(struct netfront_queue *queue) { struct sk_buff *skb; + bool work_done = false; const struct device *dev = &queue->info->netdev->dev; do { prod = queue->tx.sring->rsp_prod; if (RG_RESPONSE_PROD...
CVE-2021-28713
linux
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux
drivers/tty/hvc/hvc_xen.c
domU_read_console
static int domU_read_console(uint32_t vtermno, char *buf, int len) { struct xencons_interface *intf; XENCONS_RG_IDX cons, prod; int recv = 0; struct xencons_info *xencons = vtermno_to_xencons(vtermno); if (xencons == NULL) { return -EVAL; } intf = xencons->intf; cons = intf->in_c...
static int domU_read_console(uint32_t vtermno, char *buf, int len) { struct xencons_interface *intf; XENCONS_RG_IDX cons, prod; int recv = 0; struct xencons_info *xencons = vtermno_to_xencons(vtermno); unsigned int eoiflag = 0; if (xencons == NULL) { return -EVAL; } intf = xencon...
static int domU_read_console(uint32_t vtermno, char *buf, int len) { struct xencons_interface *intf; XENCONS_RG_IDX cons, prod; int recv = 0; struct xencons_info *xencons = vtermno_to_xencons(vtermno); if (xencons == NULL) { return -EVAL; } intf = xencons->intf; cons = intf->in_c...
static int domU_read_console(uint32_t vtermno, char *buf, int len) { struct xencons_interface *intf; XENCONS_RG_IDX cons, prod; int recv = 0; struct xencons_info *xencons = vtermno_to_xencons(vtermno); unsigned int eoiflag = 0; if (xencons == NULL) { return -EVAL; } intf = xencon...
static int domU_read_console(uint32_t vtermno, char *buf, int len) { struct xencons_info *xencons = vtermno_to_xencons(vtermno); if (xencons == NULL) { return -EVAL; } intf = xencons->intf; intf->in_cons = cons; notify_daemon(xencons); return recv; }
static int domU_read_console(uint32_t vtermno, char *buf, int len) { struct xencons_info *xencons = vtermno_to_xencons(vtermno); unsigned int eoiflag = 0; if (xencons == NULL) { return -EVAL; } intf = xencons->intf; intf->in_cons = cons; if (intf->out_cons != xencons->out_cons) { ...
static int domU_read_console(uint32_t vtermno, char *buf, int len) { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ struct xencons_info *xencons = vtermno_to_xencons(vtermno); if (xencons == NULL) { return -EVAL; } intf = xencons->intf; /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ in...
static int domU_read_console(uint32_t vtermno, char *buf, int len) { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ struct xencons_info *xencons = vtermno_to_xencons(vtermno); unsigned int eoiflag = 0; if (xencons == NULL) { return -EVAL; } intf = xencons->intf; /* PLACEHOLDER: DO NOT...
static int domU_read_console(uint32_t vtermno, char *buf, int len) { struct xencons_info *xencons = vtermno_to_xencons(vtermno); + unsigned int eoiflag = 0; if (xencons == NULL) { return -EVAL; } intf = xencons->intf; intf->in_cons = cons; - notify_daemon(xencons); + if (intf...
CVE-2021-28713
linux
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux
drivers/tty/hvc/hvc_xen.c
xen_hvc_init
static int xen_hvc_init(void) { int r; struct xencons_info *info; const struct hv_ops *ops; if (!xen_domain()) { return -ENODEV; } if (xen_initial_domain()) { ops = &dom0_hvc_ops; r = xen_initial_domain_console_init(); if (r < 0) { return r; } ...
static int xen_hvc_init(void) { int r; struct xencons_info *info; const struct hv_ops *ops; if (!xen_domain()) { return -ENODEV; } if (xen_initial_domain()) { ops = &dom0_hvc_ops; r = xen_initial_domain_console_init(); if (r < 0) { return r; } ...
static int xen_hvc_init(void) { int r; struct xencons_info *info; const struct hv_ops *ops; if (!xen_domain()) { return -ENODEV; } if (xen_initial_domain()) { ops = &dom0_hvc_ops; r = xen_initial_domain_console_init(); if (r < 0) { return r; } ...
static int xen_hvc_init(void) { int r; struct xencons_info *info; const struct hv_ops *ops; if (!xen_domain()) { return -ENODEV; } if (xen_initial_domain()) { ops = &dom0_hvc_ops; r = xen_initial_domain_console_init(); if (r < 0) { return r; } ...
static int xen_hvc_init(void) { if (xen_initial_domain()) { } else { info = vtermno_to_xencons(HVC_COOKIE); info->irq = bind_evtchn_to_irq(info->evtchn); } if (info->irq < 0) { } else { irq_set_noprobe(info->irq); } info->hvc = hvc_alloc(HVC_COOKIE, info->irq, ops, 25...
static int xen_hvc_init(void) { if (xen_initial_domain()) { } else { info = vtermno_to_xencons(HVC_COOKIE); info->irq = bind_evtchn_to_irq_lateeoi(info->evtchn); } if (info->irq < 0) { } else { irq_set_noprobe(info->irq); } info->hvc = hvc_alloc(HVC_COOKIE, info->irq,...
static int xen_hvc_init(void) { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ if (xen_initial_domain()) { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ } else { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ info = vtermno_to_xencons(HVC_COOKIE); info->irq = bind_evtchn_to_irq(info->e...
static int xen_hvc_init(void) { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ if (xen_initial_domain()) { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ } else { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ info = vtermno_to_xencons(HVC_COOKIE); info->irq = bind_evtchn_to_irq_lateeoi...
static int xen_hvc_init(void) { if (xen_initial_domain()) { } else { info = vtermno_to_xencons(HVC_COOKIE); - info->irq = bind_evtchn_to_irq(info->evtchn); + info->irq = bind_evtchn_to_irq_lateeoi(info->evtchn); } if (info->irq < 0) { } else { irq_set_noprobe(in...
CVE-2021-28713
linux
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux
drivers/tty/hvc/hvc_xen.c
xencons_connect_backend
static int xencons_connect_backend(struct xenbus_device *dev, struct xencons_info *info) { int ret, evtchn, devid, ref, irq; struct xenbus_transaction xbt; grant_ref_t gref_head; ret = xenbus_alloc_evtchn(dev, &evtchn); if (ret) { return ret; } info->evtchn = evtchn; irq = bind_e...
static int xencons_connect_backend(struct xenbus_device *dev, struct xencons_info *info) { int ret, evtchn, devid, ref, irq; struct xenbus_transaction xbt; grant_ref_t gref_head; ret = xenbus_alloc_evtchn(dev, &evtchn); if (ret) { return ret; } info->evtchn = evtchn; irq = bind_i...
static int xencons_connect_backend(struct xenbus_device *dev, struct xencons_info *info) { int ret, evtchn, devid, ref, irq; struct xenbus_transaction xbt; grant_ref_t gref_head; ret = xenbus_alloc_evtchn(dev, &evtchn); if (ret) { return ret; } info->evtchn = evtchn; irq = bind_e...
static int xencons_connect_backend(struct xenbus_device *dev, struct xencons_info *info) { int ret, evtchn, devid, ref, irq; struct xenbus_transaction xbt; grant_ref_t gref_head; ret = xenbus_alloc_evtchn(dev, &evtchn); if (ret) { return ret; } info->evtchn = evtchn; irq = bind_i...
static int xencons_connect_backend(struct xenbus_device *dev, struct xencons_info *info) { ret = xenbus_alloc_evtchn(dev, &evtchn); info->evtchn = evtchn; irq = bind_evtchn_to_irq(evtchn); if (irq < 0) { return irq; } info->irq = irq; info->hvc = hvc_alloc(xenbus_devid_to_vtermno(dev...
static int xencons_connect_backend(struct xenbus_device *dev, struct xencons_info *info) { ret = xenbus_alloc_evtchn(dev, &evtchn); info->evtchn = evtchn; irq = bind_interdomain_evtchn_to_irq_lateeoi(dev->otherend_id, evtchn); if (irq < 0) { return irq; } info->irq = irq; info->hvc =...
static int xencons_connect_backend(struct xenbus_device *dev, struct xencons_info *info) { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ ret = xenbus_alloc_evtchn(dev, &evtchn); /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ info->evtchn = evtchn; irq = bind_evtchn_to_irq(evtchn); if (irq < 0) { ...
static int xencons_connect_backend(struct xenbus_device *dev, struct xencons_info *info) { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ ret = xenbus_alloc_evtchn(dev, &evtchn); /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ info->evtchn = evtchn; irq = bind_interdomain_evtchn_to_irq_lateeoi(dev, evt...
static int xencons_connect_backend(struct xenbus_device *dev, struct xencons_info *info) { ret = xenbus_alloc_evtchn(dev, &evtchn); info->evtchn = evtchn; - irq = bind_evtchn_to_irq(evtchn); + irq = bind_interdomain_evtchn_to_irq_lateeoi(dev->otherend_id, evtchn); if (irq < 0) { return ir...
CVE-2021-28714
linux
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux
drivers/net/xen-netback/rx.c
xenvif_rx_dequeue
static struct sk_buff *xenvif_rx_dequeue(struct xenvif_queue *queue) { struct sk_buff *skb; spin_lock_irq(&queue->rx_queue.lock); skb = __skb_dequeue(&queue->rx_queue); if (skb) { queue->rx_queue_len -= skb->len; if (queue->rx_queue_len < queue->rx_queue_max) { struct netdev_...
static struct sk_buff *xenvif_rx_dequeue(struct xenvif_queue *queue) { struct sk_buff *skb; spin_lock_irq(&queue->rx_queue.lock); skb = __skb_dequeue(&queue->rx_queue); if (skb) { xenvif_update_needed_slots(queue, skb_peek(&queue->rx_queue)); queue->rx_queue_len -= skb->len; if (...
static struct sk_buff *xenvif_rx_dequeue(struct xenvif_queue *queue) { struct sk_buff *skb; spin_lock_irq(&queue->rx_queue.lock); skb = __skb_dequeue(&queue->rx_queue); if (skb) { queue->rx_queue_len -= skb->len; if (queue->rx_queue_len < queue->rx_queue_max) { struct netdev_...
static struct sk_buff *xenvif_rx_dequeue(struct xenvif_queue *queue) { struct sk_buff *skb; spin_lock_irq(&queue->rx_queue.lock); skb = __skb_dequeue(&queue->rx_queue); if (skb) { xenvif_update_needed_slots(queue, skb_peek(&queue->rx_queue)); queue->rx_queue_len -= skb->len; if (...
static struct sk_buff *xenvif_rx_dequeue(struct xenvif_queue *queue) { if (skb) { queue->rx_queue_len -= skb->len; if (queue->rx_queue_len < queue->rx_queue_max) { txq = netdev_get_tx_queue(queue->vif->dev, queue->id); netif_tx_wake_queue(txq); } } }
static struct sk_buff *xenvif_rx_dequeue(struct xenvif_queue *queue) { if (skb) { xenvif_update_needed_slots(queue, skb_peek(&queue->rx_queue)); queue->rx_queue_len -= skb->len; if (queue->rx_queue_len < queue->rx_queue_max) { txq = netdev_get_tx_queue(queue->vif->dev, queue->id)...
static struct sk_buff *xenvif_rx_dequeue(struct xenvif_queue *queue) { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ if (skb) { queue->rx_queue_len -= skb->len; if (queue->rx_queue_len < queue->rx_queue_max) { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ txq = netdev_get_tx_queu...
static struct sk_buff *xenvif_rx_dequeue(struct xenvif_queue *queue) { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ if (skb) { xenvif_update_needed_slots(queue, skb_peek(&queue->rx_queue)); queue->rx_queue_len -= skb->len; if (queue->rx_queue_len < queue->rx_queue_max) { /* PLACEHOL...
static struct sk_buff *xenvif_rx_dequeue(struct xenvif_queue *queue) { if (skb) { + xenvif_update_needed_slots(queue, skb_peek(&queue->rx_queue)); queue->rx_queue_len -= skb->len; if (queue->rx_queue_len < queue->rx_queue_max) { txq = netdev_get_tx_queue(queue->vif->dev, queu...
CVE-2021-28714
linux
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux
drivers/net/xen-netback/rx.c
xenvif_rx_queue_ready
static bool xenvif_rx_queue_ready(struct xenvif_queue *queue) { RG_IDX prod, cons; prod = queue->rx.sring->req_prod; cons = queue->rx.req_cons; return queue->stalled && prod - cons >= 1; }
static bool xenvif_rx_queue_ready(struct xenvif_queue *queue) { unsigned int needed = READ_ONCE(queue->rx_slots_needed); return queue->stalled && xenvif_rx_queue_slots(queue) >= needed; }
static bool xenvif_rx_queue_ready(struct xenvif_queue *queue) { RG_IDX prod, cons; prod = queue->rx.sring->req_prod; cons = queue->rx.req_cons; return queue->stalled && prod - cons >= 1; }
static bool xenvif_rx_queue_ready(struct xenvif_queue *queue) { unsigned int needed = READ_ONCE(queue->rx_slots_needed); return queue->stalled && xenvif_rx_queue_slots(queue) >= needed; }
static bool xenvif_rx_queue_ready(struct xenvif_queue *queue) { RG_IDX prod, cons; prod = queue->rx.sring->req_prod; cons = queue->rx.req_cons; return queue->stalled && prod - cons >= 1; }
static bool xenvif_rx_queue_ready(struct xenvif_queue *queue) { unsigned int needed = READ_ONCE(queue->rx_slots_needed); return queue->stalled && xenvif_rx_queue_slots(queue) >= needed; }
static bool xenvif_rx_queue_ready(struct xenvif_queue *queue) { RG_IDX prod, cons; prod = queue->rx.sring->req_prod; cons = queue->rx.req_cons; return queue->stalled && prod - cons >= 1; }
static bool xenvif_rx_queue_ready(struct xenvif_queue *queue) { unsigned int needed = READ_ONCE(queue->rx_slots_needed); return queue->stalled && xenvif_rx_queue_slots(queue) >= needed; }
static bool xenvif_rx_queue_ready(struct xenvif_queue *queue) { - RG_IDX prod, cons; - prod = queue->rx.sring->req_prod; - cons = queue->rx.req_cons; - return queue->stalled && prod - cons >= 1; + unsigned int needed = READ_ONCE(queue->rx_slots_needed); + return queue->stalled && xenvif_rx_queue_slot...
CVE-2021-28714
linux
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux
drivers/net/xen-netback/rx.c
xenvif_rx_queue_stalled
static bool xenvif_rx_queue_stalled(struct xenvif_queue *queue) { RG_IDX prod, cons; prod = queue->rx.sring->req_prod; cons = queue->rx.req_cons; return !queue->stalled && prod - cons < 1 && time_after(jiffies, queue->last_rx_time + queue->vif->stall_timeout); }
static bool xenvif_rx_queue_stalled(const struct xenvif_queue *queue) { unsigned int needed = READ_ONCE(queue->rx_slots_needed); return !queue->stalled && xenvif_rx_queue_slots(queue) < needed && time_after(jiffies, queue->last_rx_time + queue->vif->stall_timeout); }
static bool xenvif_rx_queue_stalled(struct xenvif_queue *queue) { RG_IDX prod, cons; prod = queue->rx.sring->req_prod; cons = queue->rx.req_cons; return !queue->stalled && prod - cons < 1 && time_after(jiffies, queue->last_rx_time + queue->vif->stall_timeout); }
static bool xenvif_rx_queue_stalled(const struct xenvif_queue *queue) { unsigned int needed = READ_ONCE(queue->rx_slots_needed); return !queue->stalled && xenvif_rx_queue_slots(queue) < needed && time_after(jiffies, queue->last_rx_time + queue->vif->stall_timeout); }
static bool xenvif_rx_queue_stalled(struct xenvif_queue *queue) { RG_IDX prod, cons; prod = queue->rx.sring->req_prod; cons = queue->rx.req_cons; return !queue->stalled && prod - cons < 1 && time_after(jiffies, queue->last_rx_time + queue->vif->stall_timeout); }
static bool xenvif_rx_queue_stalled(const struct xenvif_queue *queue) { unsigned int needed = READ_ONCE(queue->rx_slots_needed); return !queue->stalled && xenvif_rx_queue_slots(queue) < needed && time_after(jiffies, queue->last_rx_time + queue->vif->stall_timeout); }
static bool xenvif_rx_queue_stalled(struct xenvif_queue *queue) { RG_IDX prod, cons; prod = queue->rx.sring->req_prod; cons = queue->rx.req_cons; return !queue->stalled && prod - cons < 1 && time_after(jiffies, queue->last_rx_time + queue->vif->stall_timeout); }
static bool xenvif_rx_queue_stalled(const struct xenvif_queue *queue) { unsigned int needed = READ_ONCE(queue->rx_slots_needed); return !queue->stalled && xenvif_rx_queue_slots(queue) < needed && time_after(jiffies, queue->last_rx_time + queue->vif->stall_timeout); }
-static bool xenvif_rx_queue_stalled(struct xenvif_queue *queue) { - RG_IDX prod, cons; - prod = queue->rx.sring->req_prod; - cons = queue->rx.req_cons; - return !queue->stalled && prod - cons < 1 && time_after(jiffies, queue->last_rx_time + queue->vif->stall_timeout); +static bool xenvif_rx_queue_stalled(c...
CVE-2021-28714
linux
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux
drivers/net/xen-netback/rx.c
xenvif_rx_queue_tail
void xenvif_rx_queue_tail(struct xenvif_queue *queue, struct sk_buff *skb) { unsigned long flags; spin_lock_irqsave(&queue->rx_queue.lock, flags); __skb_queue_tail(&queue->rx_queue, skb); queue->rx_queue_len += skb->len; if (queue->rx_queue_len > queue->rx_queue_max) { struct net_device *dev...
void xenvif_rx_queue_tail(struct xenvif_queue *queue, struct sk_buff *skb) { unsigned long flags; spin_lock_irqsave(&queue->rx_queue.lock, flags); if (skb_queue_empty(&queue->rx_queue)) { xenvif_update_needed_slots(queue, skb); } __skb_queue_tail(&queue->rx_queue, skb); queue->rx_queue_l...
void xenvif_rx_queue_tail(struct xenvif_queue *queue, struct sk_buff *skb) { unsigned long flags; spin_lock_irqsave(&queue->rx_queue.lock, flags); __skb_queue_tail(&queue->rx_queue, skb); queue->rx_queue_len += skb->len; if (queue->rx_queue_len > queue->rx_queue_max) { struct net_device *dev...
void xenvif_rx_queue_tail(struct xenvif_queue *queue, struct sk_buff *skb) { unsigned long flags; spin_lock_irqsave(&queue->rx_queue.lock, flags); if (skb_queue_empty(&queue->rx_queue)) { xenvif_update_needed_slots(queue, skb); } __skb_queue_tail(&queue->rx_queue, skb); queue->rx_queue_l...
void xenvif_rx_queue_tail(struct xenvif_queue *queue, struct sk_buff *skb) { spin_lock_irqsave(&queue->rx_queue.lock, flags); __skb_queue_tail(&queue->rx_queue, skb); queue->rx_queue_len += skb->len; if (queue->rx_queue_len > queue->rx_queue_max) { netif_tx_stop_queue(netdev_get_tx_queue(dev, qu...
void xenvif_rx_queue_tail(struct xenvif_queue *queue, struct sk_buff *skb) { spin_lock_irqsave(&queue->rx_queue.lock, flags); if (skb_queue_empty(&queue->rx_queue)) { xenvif_update_needed_slots(queue, skb); } __skb_queue_tail(&queue->rx_queue, skb); queue->rx_queue_len += skb->len; if (q...
void xenvif_rx_queue_tail(struct xenvif_queue *queue, struct sk_buff *skb) { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ spin_lock_irqsave(&queue->rx_queue.lock, flags); __skb_queue_tail(&queue->rx_queue, skb); queue->rx_queue_len += skb->len; if (queue->rx_queue_len > queue->rx_queue_max) { /...
void xenvif_rx_queue_tail(struct xenvif_queue *queue, struct sk_buff *skb) { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ spin_lock_irqsave(&queue->rx_queue.lock, flags); if (skb_queue_empty(&queue->rx_queue)) { xenvif_update_needed_slots(queue, skb); } __skb_queue_tail(&queue->rx_queue, sk...
void xenvif_rx_queue_tail(struct xenvif_queue *queue, struct sk_buff *skb) { spin_lock_irqsave(&queue->rx_queue.lock, flags); + if (skb_queue_empty(&queue->rx_queue)) { + xenvif_update_needed_slots(queue, skb); + } __skb_queue_tail(&queue->rx_queue, skb); queue->rx_queue_len += skb->len; ...
CVE-2021-28714
linux
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux
drivers/net/xen-netback/rx.c
xenvif_rx_ring_slots_available
static bool xenvif_rx_ring_slots_available(struct xenvif_queue *queue) { RG_IDX prod, cons; struct sk_buff *skb; int needed; unsigned long flags; spin_lock_irqsave(&queue->rx_queue.lock, flags); skb = skb_peek(&queue->rx_queue); if (!skb) { spin_unlock_irqrestore(&queue->rx_queue.loc...
static bool xenvif_rx_ring_slots_available(struct xenvif_queue *queue) { RG_IDX prod, cons; unsigned int needed; needed = READ_ONCE(queue->rx_slots_needed); if (!needed) { return false; } do { prod = queue->rx.sring->req_prod; cons = queue->rx.req_cons; if (prod -...
static bool xenvif_rx_ring_slots_available(struct xenvif_queue *queue) { RG_IDX prod, cons; struct sk_buff *skb; int needed; unsigned long flags; spin_lock_irqsave(&queue->rx_queue.lock, flags); skb = skb_peek(&queue->rx_queue); if (!skb) { spin_unlock_irqrestore(&queue->rx_queue.loc...
static bool xenvif_rx_ring_slots_available(struct xenvif_queue *queue) { RG_IDX prod, cons; unsigned int needed; needed = READ_ONCE(queue->rx_slots_needed); if (!needed) { return false; } do { prod = queue->rx.sring->req_prod; cons = queue->rx.req_cons; if (prod -...
static bool xenvif_rx_ring_slots_available(struct xenvif_queue *queue) { RG_IDX prod, cons; struct sk_buff *skb; int needed; unsigned long flags; spin_lock_irqsave(&queue->rx_queue.lock, flags); skb = skb_peek(&queue->rx_queue); if (!skb) { spin_unlock_irqrestore(&queue->rx_queue.loc...
static bool xenvif_rx_ring_slots_available(struct xenvif_queue *queue) { RG_IDX prod, cons; unsigned int needed; needed = READ_ONCE(queue->rx_slots_needed); if (!needed) { return false; } do { prod = queue->rx.sring->req_prod; cons = queue->rx.req_cons; if (prod -...
static bool xenvif_rx_ring_slots_available(struct xenvif_queue *queue) { RG_IDX prod, cons; struct sk_buff *skb; int needed; unsigned long flags; spin_lock_irqsave(&queue->rx_queue.lock, flags); skb = skb_peek(&queue->rx_queue); if (!skb) { spin_unlock_irqrestore(&queue->rx_queue.loc...
static bool xenvif_rx_ring_slots_available(struct xenvif_queue *queue) { RG_IDX prod, cons; unsigned int needed; needed = READ_ONCE(queue->rx_slots_needed); if (!needed) { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ } do { prod = queue->rx.sring->req_prod; cons = queue-...
static bool xenvif_rx_ring_slots_available(struct xenvif_queue *queue) { RG_IDX prod, cons; - struct sk_buff *skb; - int needed; - unsigned long flags; - spin_lock_irqsave(&queue->rx_queue.lock, flags); - skb = skb_peek(&queue->rx_queue); - if (!skb) { - spin_unlock_irqrestore(&queue->rx_...
CVE-2021-28951
linux
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux
fs/io_uring.c
__io_req_task_submit
static void __io_req_task_submit(struct io_kiocb *req) { struct io_ring_ctx *ctx = req->ctx; mutex_lock(&ctx->uring_lock); if (!ctx->sqo_dead && !__io_sq_thread_acquire_mm(ctx) && !__io_sq_thread_acquire_files(ctx)) { __io_queue_sqe(req, NULL); } else { __io_req_task_cancel(req, -EFAULT)...
static void __io_req_task_submit(struct io_kiocb *req) { struct io_ring_ctx *ctx = req->ctx; mutex_lock(&ctx->uring_lock); if (!ctx->sqo_dead && !__io_sq_thread_acquire_mm(ctx) && !__io_sq_thread_acquire_files(ctx)) { __io_queue_sqe(req, NULL); } else { __io_req_task_cancel(req, -EFAULT)...
static void __io_req_task_submit(struct io_kiocb *req) { struct io_ring_ctx *ctx = req->ctx; mutex_lock(&ctx->uring_lock); if (!ctx->sqo_dead && !__io_sq_thread_acquire_mm(ctx)) { __io_queue_sqe(req, NULL); } else { __io_req_task_cancel(req, -EFAULT); } mutex_unlock(&ctx->uring_l...
static void __io_req_task_submit(struct io_kiocb *req) { struct io_ring_ctx *ctx = req->ctx; mutex_lock(&ctx->uring_lock); if (!ctx->sqo_dead && !__io_sq_thread_acquire_mm(ctx)) { __io_queue_sqe(req, NULL); } else { __io_req_task_cancel(req, -EFAULT); } mutex_unlock(&ctx->uring_l...
static void __io_req_task_submit(struct io_kiocb *req) { struct io_ring_ctx *ctx = req->ctx; if (!ctx->sqo_dead && !__io_sq_thread_acquire_mm(ctx) && !__io_sq_thread_acquire_files(ctx)) { } else { } mutex_unlock(&ctx->uring_lock); }
static void __io_req_task_submit(struct io_kiocb *req) { struct io_ring_ctx *ctx = req->ctx; if (!ctx->sqo_dead && !__io_sq_thread_acquire_mm(ctx) && !__io_sq_thread_acquire_files(ctx)) { } else { } mutex_unlock(&ctx->uring_lock); ctx->flags &= ~IORG_SETUP_R_DISABLED; }
static void __io_req_task_submit(struct io_kiocb *req) { struct io_ring_ctx *ctx = req->ctx; /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ if (!ctx->sqo_dead && !__io_sq_thread_acquire_mm(ctx)) { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ } else { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */...
static void __io_req_task_submit(struct io_kiocb *req) { struct io_ring_ctx *ctx = req->ctx; /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ if (!ctx->sqo_dead && !__io_sq_thread_acquire_mm(ctx)) { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ } else { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */...
static void __io_req_task_submit(struct io_kiocb *req) { struct io_ring_ctx *ctx = req->ctx; if (!ctx->sqo_dead && !__io_sq_thread_acquire_mm(ctx) && !__io_sq_thread_acquire_files(ctx)) { } else { } mutex_unlock(&ctx->uring_lock); + ctx->flags &= ~IORG_SETUP_R_DISABLED; }
CVE-2021-28951
linux
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux
fs/io_uring.c
io_disable_sqo_submit
static void io_disable_sqo_submit(struct io_ring_ctx *ctx) { mutex_lock(&ctx->uring_lock); ctx->sqo_dead = 1; mutex_unlock(&ctx->uring_lock); if (ctx->rings) { io_ring_set_wakeup_flag(ctx); } }
static void io_disable_sqo_submit(struct io_ring_ctx *ctx) { mutex_lock(&ctx->uring_lock); ctx->sqo_dead = 1; if (ctx->flags & IORG_SETUP_R_DISABLED) { io_sq_offload_start(ctx); } mutex_unlock(&ctx->uring_lock); if (ctx->rings) { io_ring_set_wakeup_flag(ctx); } }
static void io_disable_sqo_submit(struct io_ring_ctx *ctx) { mutex_lock(&ctx->uring_lock); ctx->sqo_dead = 1; mutex_unlock(&ctx->uring_lock); if (ctx->rings) { io_ring_set_wakeup_flag(ctx); } }
static void io_disable_sqo_submit(struct io_ring_ctx *ctx) { mutex_lock(&ctx->uring_lock); ctx->sqo_dead = 1; if (ctx->flags & IORG_SETUP_R_DISABLED) { io_sq_offload_start(ctx); } mutex_unlock(&ctx->uring_lock); if (ctx->rings) { io_ring_set_wakeup_flag(ctx); } }
static void io_disable_sqo_submit(struct io_ring_ctx *ctx) { mutex_lock(&ctx->uring_lock); ctx->sqo_dead = 1; mutex_unlock(&ctx->uring_lock); if (ctx->rings) { io_ring_set_wakeup_flag(ctx); } }
static void io_disable_sqo_submit(struct io_ring_ctx *ctx) { mutex_lock(&ctx->uring_lock); ctx->sqo_dead = 1; if (ctx->flags & IORG_SETUP_R_DISABLED) { io_sq_offload_start(ctx); } mutex_unlock(&ctx->uring_lock); if (ctx->rings) { io_ring_set_wakeup_flag(ctx); } }
static void io_disable_sqo_submit(struct io_ring_ctx *ctx) { mutex_lock(&ctx->uring_lock); ctx->sqo_dead = 1; mutex_unlock(&ctx->uring_lock); if (ctx->rings) { io_ring_set_wakeup_flag(ctx); } }
static void io_disable_sqo_submit(struct io_ring_ctx *ctx) { mutex_lock(&ctx->uring_lock); ctx->sqo_dead = 1; if (ctx->flags & IORG_SETUP_R_DISABLED) { io_sq_offload_start(ctx); } mutex_unlock(&ctx->uring_lock); if (ctx->rings) { io_ring_set_wakeup_flag(ctx); } }
static void io_disable_sqo_submit(struct io_ring_ctx *ctx) { mutex_lock(&ctx->uring_lock); ctx->sqo_dead = 1; + if (ctx->flags & IORG_SETUP_R_DISABLED) { + io_sq_offload_start(ctx); + } mutex_unlock(&ctx->uring_lock); if (ctx->rings) { io_ring_set_wakeup_flag(ctx); } }
CVE-2021-28951
linux
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux
fs/io_uring.c
io_register_enable_rings
static int io_register_enable_rings(struct io_ring_ctx *ctx) { if (!(ctx->flags & IORG_SETUP_R_DISABLED)) { return -EBADFD; } if (ctx->restrictions.registered) { ctx->restricted = 1; } ctx->flags &= ~IORG_SETUP_R_DISABLED; io_sq_offload_start(ctx); return 0; }
static int io_register_enable_rings(struct io_ring_ctx *ctx) { if (!(ctx->flags & IORG_SETUP_R_DISABLED)) { return -EBADFD; } if (ctx->restrictions.registered) { ctx->restricted = 1; } io_sq_offload_start(ctx); return 0; }
static int io_register_enable_rings(struct io_ring_ctx *ctx) { if (!(ctx->flags & IORG_SETUP_R_DISABLED)) { return -EBADFD; } if (ctx->restrictions.registered) { ctx->restricted = 1; } ctx->flags &= ~IORG_SETUP_R_DISABLED; io_sq_offload_start(ctx); return 0; }
static int io_register_enable_rings(struct io_ring_ctx *ctx) { if (!(ctx->flags & IORG_SETUP_R_DISABLED)) { return -EBADFD; } if (ctx->restrictions.registered) { ctx->restricted = 1; } io_sq_offload_start(ctx); return 0; }
static int io_register_enable_rings(struct io_ring_ctx *ctx) { if (!(ctx->flags & IORG_SETUP_R_DISABLED)) { return -EBADFD; } if (ctx->restrictions.registered) { ctx->restricted = 1; } ctx->flags &= ~IORG_SETUP_R_DISABLED; io_sq_offload_start(ctx); }
static int io_register_enable_rings(struct io_ring_ctx *ctx) { if (!(ctx->flags & IORG_SETUP_R_DISABLED)) { return -EBADFD; } if (ctx->restrictions.registered) { ctx->restricted = 1; } io_sq_offload_start(ctx); }
static int io_register_enable_rings(struct io_ring_ctx *ctx) { if (!(ctx->flags & IORG_SETUP_R_DISABLED)) { return -EBADFD; } if (ctx->restrictions.registered) { ctx->restricted = 1; } ctx->flags &= ~IORG_SETUP_R_DISABLED; io_sq_offload_start(ctx); /* PLACEHOLDER: DO NOT DELE...
static int io_register_enable_rings(struct io_ring_ctx *ctx) { if (!(ctx->flags & IORG_SETUP_R_DISABLED)) { return -EBADFD; } if (ctx->restrictions.registered) { ctx->restricted = 1; } io_sq_offload_start(ctx); /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ }
static int io_register_enable_rings(struct io_ring_ctx *ctx) { if (!(ctx->flags & IORG_SETUP_R_DISABLED)) { return -EBADFD; } if (ctx->restrictions.registered) { ctx->restricted = 1; } - ctx->flags &= ~IORG_SETUP_R_DISABLED; io_sq_offload_start(ctx); }
CVE-2021-28964
linux
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux
fs/btrfs/ctree.c
get_old_root
static inline struct extent_buffer * get_old_root(struct btrfs_root *root, u64 time_seq) { struct tree_mod_elem *tm; struct extent_buffer *eb = NULL; struct extent_buffer *eb_root; u64 eb_root_owner = 0; struct extent_buffer *old; struct tree_mod_root *old_root = NULL; u64 old_generation = 0...
static inline struct extent_buffer * get_old_root(struct btrfs_root *root, u64 time_seq) { struct tree_mod_elem *tm; struct extent_buffer *eb = NULL; struct extent_buffer *eb_root; u64 eb_root_owner = 0; struct extent_buffer *old; struct tree_mod_root *old_root = NULL; u64 old_generation = 0...
static inline struct extent_buffer * get_old_root(struct btrfs_root *root, u64 time_seq) { struct btrfs_fs_info *fs_info = root->fs_info; struct tree_mod_elem *tm; struct extent_buffer *eb = NULL; struct extent_buffer *eb_root; u64 eb_root_owner = 0; struct extent_buffer *old; struct tree_mo...
static inline struct extent_buffer * get_old_root(struct btrfs_root *root, u64 time_seq) { struct btrfs_fs_info *fs_info = root->fs_info; struct tree_mod_elem *tm; struct extent_buffer *eb = NULL; struct extent_buffer *eb_root; u64 eb_root_owner = 0; struct extent_buffer *old; struct tree_mo...
static inline struct extent_buffer * get_old_root(struct btrfs_root *root, u64 time_seq) { eb_root = btrfs_read_lock_root_node(root); tm = __tree_mod_log_oldest_root(root->fs_info, eb_root, time_seq); if (!tm) { return eb_root; } if (tm->op == MOD_LOG_ROOT_REPLACE) { old_root = &tm->...
static inline struct extent_buffer * get_old_root(struct btrfs_root *root, u64 time_seq) { eb_root = btrfs_read_lock_root_node(root); tm = __tree_mod_log_oldest_root(root->fs_info, eb_root, time_seq); if (!tm) { return eb_root; } if (tm->op == MOD_LOG_ROOT_REPLACE) { old_root = &tm->...
static inline struct extent_buffer * get_old_root(struct btrfs_root *root, u64 time_seq) { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ eb_root = btrfs_read_lock_root_node(root); tm = __tree_mod_log_oldest_root(eb_root, time_seq); if (!tm) { return eb_root; } if (tm->op == MOD_LOG_ROOT_...
static inline struct extent_buffer * get_old_root(struct btrfs_root *root, u64 time_seq) { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ eb_root = btrfs_read_lock_root_node(root); tm = __tree_mod_log_oldest_root(eb_root, time_seq); if (!tm) { return eb_root; } if (tm->op == MOD_LOG_ROOT_...
static inline struct extent_buffer * get_old_root(struct btrfs_root *root, u64 time_seq) { eb_root = btrfs_read_lock_root_node(root); tm = __tree_mod_log_oldest_root(root->fs_info, eb_root, time_seq); if (!tm) { return eb_root; } if (tm->op == MOD_LOG_ROOT_REPLACE) { old_root...
CVE-2021-28971
linux
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux
arch/x86/events/intel/ds.c
intel_pmu_drain_pebs_nhm
static void intel_pmu_drain_pebs_nhm(struct pt_regs *iregs) { struct cpu_hw_events *cpuc = this_cpu_ptr(&cpu_hw_events); struct debug_store *ds = cpuc->ds; struct perf_event *event; void *base, *at, *top; short counts[MAX_PEBS_EVENTS] = {}; short error[MAX_PEBS_EVENTS] = {}; int bit, i; ...
static void intel_pmu_drain_pebs_nhm(struct pt_regs *iregs) { struct cpu_hw_events *cpuc = this_cpu_ptr(&cpu_hw_events); struct debug_store *ds = cpuc->ds; struct perf_event *event; void *base, *at, *top; short counts[MAX_PEBS_EVENTS] = {}; short error[MAX_PEBS_EVENTS] = {}; int bit, i; ...
static void intel_pmu_drain_pebs_nhm(struct pt_regs *iregs, struct perf_sample_data *data) { struct cpu_hw_events *cpuc = this_cpu_ptr(&cpu_hw_events); struct debug_store *ds = cpuc->ds; struct perf_event *event; void *base, *at, *top; short counts[TEL_PMC_IDX_FIXED + MAX_FIXED_PEBS_EVENTS] = {}; ...
static void intel_pmu_drain_pebs_nhm(struct pt_regs *iregs, struct perf_sample_data *data) { struct cpu_hw_events *cpuc = this_cpu_ptr(&cpu_hw_events); struct debug_store *ds = cpuc->ds; struct perf_event *event; void *base, *at, *top; short counts[TEL_PMC_IDX_FIXED + MAX_FIXED_PEBS_EVENTS] = {}; ...
static void intel_pmu_drain_pebs_nhm(struct pt_regs *iregs) { struct cpu_hw_events *cpuc = this_cpu_ptr(&cpu_hw_events); struct debug_store *ds = cpuc->ds; base = (struct pebs_record_nhm *)(unsigned long)ds->pebs_buffer_base; top = (struct pebs_record_nhm *)(unsigned long)ds->pebs_index; if (unlikel...
static void intel_pmu_drain_pebs_nhm(struct pt_regs *iregs) { struct cpu_hw_events *cpuc = this_cpu_ptr(&cpu_hw_events); struct debug_store *ds = cpuc->ds; base = (struct pebs_record_nhm *)(unsigned long)ds->pebs_buffer_base; top = (struct pebs_record_nhm *)(unsigned long)ds->pebs_index; if (unlikel...
static void intel_pmu_drain_pebs_nhm(struct pt_regs *iregs, struct perf_sample_data *data) { struct cpu_hw_events *cpuc = this_cpu_ptr(&cpu_hw_events); struct debug_store *ds = cpuc->ds; /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ base = (struct pebs_record_nhm *)(unsigned long)ds->pebs_buffer_base; ...
static void intel_pmu_drain_pebs_nhm(struct pt_regs *iregs, struct perf_sample_data *data) { struct cpu_hw_events *cpuc = this_cpu_ptr(&cpu_hw_events); struct debug_store *ds = cpuc->ds; /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ base = (struct pebs_record_nhm *)(unsigned long)ds->pebs_buffer_base; ...
static void intel_pmu_drain_pebs_nhm(struct pt_regs *iregs) { struct cpu_hw_events *cpuc = this_cpu_ptr(&cpu_hw_events); struct debug_store *ds = cpuc->ds; base = (struct pebs_record_nhm *)(unsigned long)ds->pebs_buffer_base; top = (struct pebs_record_nhm *)(unsigned long)ds->pebs_index; if (u...
CVE-2021-28972
linux
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux
drivers/pci/hotplug/rpadlpar_sysfs.c
add_slot_store
static ssize_t add_slot_store(struct kobject *kobj, struct kobj_attribute *attr, const char *buf, size_t nbytes) { char drc_name[MAX_DRC_NAME_LEN]; char *end; int rc; if (nbytes >= MAX_DRC_NAME_LEN) { return 0; } memcpy(drc_name, buf, nbytes); end = strchr(drc_name, '\n'); if (!e...
static ssize_t add_slot_store(struct kobject *kobj, struct kobj_attribute *attr, const char *buf, size_t nbytes) { char drc_name[MAX_DRC_NAME_LEN]; char *end; int rc; if (nbytes >= MAX_DRC_NAME_LEN) { return 0; } strscpy(drc_name, buf, nbytes + 1); end = strchr(drc_name, '\n'); i...
static ssize_t add_slot_store(struct kobject *kobj, struct kobj_attribute *attr, const char *buf, size_t nbytes) { char drc_name[MAX_DRC_NAME_LEN]; char *end; int rc; if (nbytes >= MAX_DRC_NAME_LEN) { return 0; } memcpy(drc_name, buf, nbytes); end = strchr(drc_name, '\n'); if (!e...
static ssize_t add_slot_store(struct kobject *kobj, struct kobj_attribute *attr, const char *buf, size_t nbytes) { char drc_name[MAX_DRC_NAME_LEN]; char *end; int rc; if (nbytes >= MAX_DRC_NAME_LEN) { return 0; } strscpy(drc_name, buf, nbytes + 1); end = strchr(drc_name, '\n'); i...
static ssize_t add_slot_store(struct kobject *kobj, struct kobj_attribute *attr, const char *buf, size_t nbytes) { if (nbytes >= MAX_DRC_NAME_LEN) { return 0; } memcpy(drc_name, buf, nbytes); end = strchr(drc_name, '\n'); if (!end) { end = &drc_name[nbytes]; } *end = '\0'; ...
static ssize_t add_slot_store(struct kobject *kobj, struct kobj_attribute *attr, const char *buf, size_t nbytes) { if (nbytes >= MAX_DRC_NAME_LEN) { return 0; } strscpy(drc_name, buf, nbytes + 1); end = strchr(drc_name, '\n'); if (end) { *end = '\0'; } rc = dlpar_add_slot(drc...
static ssize_t add_slot_store(struct kobject *kobj, struct kobj_attribute *attr, const char *buf, size_t nbytes) { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ if (nbytes >= MAX_DRC_NAME_LEN) { return 0; } memcpy(drc_name, buf, nbytes); end = strchr(drc_name, '\n'); if (!end) { ...
static ssize_t add_slot_store(struct kobject *kobj, struct kobj_attribute *attr, const char *buf, size_t nbytes) { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ if (nbytes >= MAX_DRC_NAME_LEN) { return 0; } strscpy(drc_name, buf, nbytes + 1); end = strchr(drc_name, '\n'); if (end) { ...
static ssize_t add_slot_store(struct kobject *kobj, struct kobj_attribute *attr, const char *buf, size_t nbytes) { if (nbytes >= MAX_DRC_NAME_LEN) { return 0; } - memcpy(drc_name, buf, nbytes); + strscpy(drc_name, buf, nbytes + 1); end = strchr(drc_name, '\n'); - if (!end) { - e...
CVE-2021-28972
linux
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux
drivers/pci/hotplug/rpadlpar_sysfs.c
remove_slot_store
static ssize_t remove_slot_store(struct kobject *kobj, struct kobj_attribute *attr, const char *buf, size_t nbytes) { char drc_name[MAX_DRC_NAME_LEN]; int rc; char *end; if (nbytes >= MAX_DRC_NAME_LEN) { return 0; } memcpy(drc_name, buf, nbytes); end = strchr(drc_name, '\n'); if ...
static ssize_t remove_slot_store(struct kobject *kobj, struct kobj_attribute *attr, const char *buf, size_t nbytes) { char drc_name[MAX_DRC_NAME_LEN]; int rc; char *end; if (nbytes >= MAX_DRC_NAME_LEN) { return 0; } strscpy(drc_name, buf, nbytes + 1); end = strchr(drc_name, '\n'); ...
static ssize_t remove_slot_store(struct kobject *kobj, struct kobj_attribute *attr, const char *buf, size_t nbytes) { char drc_name[MAX_DRC_NAME_LEN]; int rc; char *end; if (nbytes >= MAX_DRC_NAME_LEN) { return 0; } memcpy(drc_name, buf, nbytes); end = strchr(drc_name, '\n'); if ...
static ssize_t remove_slot_store(struct kobject *kobj, struct kobj_attribute *attr, const char *buf, size_t nbytes) { char drc_name[MAX_DRC_NAME_LEN]; int rc; char *end; if (nbytes >= MAX_DRC_NAME_LEN) { return 0; } strscpy(drc_name, buf, nbytes + 1); end = strchr(drc_name, '\n'); ...
static ssize_t remove_slot_store(struct kobject *kobj, struct kobj_attribute *attr, const char *buf, size_t nbytes) { if (nbytes >= MAX_DRC_NAME_LEN) { return 0; } memcpy(drc_name, buf, nbytes); end = strchr(drc_name, '\n'); if (!end) { end = &drc_name[nbytes]; } *end = '\0';...
static ssize_t remove_slot_store(struct kobject *kobj, struct kobj_attribute *attr, const char *buf, size_t nbytes) { if (nbytes >= MAX_DRC_NAME_LEN) { return 0; } strscpy(drc_name, buf, nbytes + 1); end = strchr(drc_name, '\n'); if (end) { *end = '\0'; } rc = dlpar_remove_sl...
static ssize_t remove_slot_store(struct kobject *kobj, struct kobj_attribute *attr, const char *buf, size_t nbytes) { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ if (nbytes >= MAX_DRC_NAME_LEN) { return 0; } memcpy(drc_name, buf, nbytes); end = strchr(drc_name, '\n'); if (!end) { ...
static ssize_t remove_slot_store(struct kobject *kobj, struct kobj_attribute *attr, const char *buf, size_t nbytes) { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ if (nbytes >= MAX_DRC_NAME_LEN) { return 0; } strscpy(drc_name, buf, nbytes + 1); end = strchr(drc_name, '\n'); if (end) { ...
static ssize_t remove_slot_store(struct kobject *kobj, struct kobj_attribute *attr, const char *buf, size_t nbytes) { if (nbytes >= MAX_DRC_NAME_LEN) { return 0; } - memcpy(drc_name, buf, nbytes); + strscpy(drc_name, buf, nbytes + 1); end = strchr(drc_name, '\n'); - if (!end) { - ...
CVE-2021-29154
linux
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux
arch/x86/net/bpf_jit_comp.c
do_jit
static int do_jit(struct bpf_prog *bpf_prog, int *addrs, u8 *image, int oldproglen, struct jit_context *ctx) { struct bpf_insn *insn = bpf_prog->insnsi; int insn_cnt = bpf_prog->len; bool seen_ld_abs = ctx->seen_ld_abs | (oldproglen == 0); bool seen_exit = false; u8 temp[BPF_MAX_SN_SIZE + BPF_SN_SAF...
static int do_jit(struct bpf_prog *bpf_prog, int *addrs, u8 *image, int oldproglen, struct jit_context *ctx) { struct bpf_insn *insn = bpf_prog->insnsi; int insn_cnt = bpf_prog->len; bool seen_ld_abs = ctx->seen_ld_abs | (oldproglen == 0); bool seen_exit = false; u8 temp[BPF_MAX_SN_SIZE + BPF_SN_SAF...
static int do_jit(struct bpf_prog *bpf_prog, int *addrs, u8 *image, int oldproglen, struct jit_context *ctx) { bool tail_call_reachable = bpf_prog->aux->tail_call_reachable; struct bpf_insn *insn = bpf_prog->insnsi; bool callee_regs_used[4] = {}; int insn_cnt = bpf_prog->len; bool tail_call_seen = f...
static int do_jit(struct bpf_prog *bpf_prog, int *addrs, u8 *image, int oldproglen, struct jit_context *ctx) { bool tail_call_reachable = bpf_prog->aux->tail_call_reachable; struct bpf_insn *insn = bpf_prog->insnsi; bool callee_regs_used[4] = {}; int insn_cnt = bpf_prog->len; bool tail_call_seen = f...
static int do_jit(struct bpf_prog *bpf_prog, int *addrs, u8 *image, int oldproglen, struct jit_context *ctx) { struct bpf_insn *insn = bpf_prog->insnsi; int insn_cnt = bpf_prog->len; bool seen_ld_abs = ctx->seen_ld_abs | (oldproglen == 0); int proglen = 0; u8 *prog = temp; for (i = 0; i < insn_c...
static int do_jit(struct bpf_prog *bpf_prog, int *addrs, u8 *image, int oldproglen, struct jit_context *ctx) { struct bpf_insn *insn = bpf_prog->insnsi; int insn_cnt = bpf_prog->len; bool seen_ld_abs = ctx->seen_ld_abs | (oldproglen == 0); int proglen = 0; u8 *prog = temp; for (i = 0; i < insn_c...
static int do_jit(struct bpf_prog *bpf_prog, int *addrs, u8 *image, int oldproglen, struct jit_context *ctx) { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ struct bpf_insn *insn = bpf_prog->insnsi; /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ int insn_cnt = bpf_prog->len; bool tail_call_seen = fal...
static int do_jit(struct bpf_prog *bpf_prog, int *addrs, u8 *image, int oldproglen, struct jit_context *ctx) { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ struct bpf_insn *insn = bpf_prog->insnsi; /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ int insn_cnt = bpf_prog->len; bool tail_call_seen = fal...
static int do_jit(struct bpf_prog *bpf_prog, int *addrs, u8 *image, int oldproglen, struct jit_context *ctx) { struct bpf_insn *insn = bpf_prog->insnsi; int insn_cnt = bpf_prog->len; bool seen_ld_abs = ctx->seen_ld_abs | (oldproglen == 0); int proglen = 0; u8 *prog = temp; for (i = 0; i <...
CVE-2021-29155
linux
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux
kernel/bpf/verifier.c
adjust_ptr_min_max_vals
static int adjust_ptr_min_max_vals(struct bpf_verifier_env *env, struct bpf_insn *insn, const struct bpf_reg_state *ptr_reg, const struct bpf_reg_state *off_reg) { struct bpf_verifier_state *vstate = env->cur_state; struct bpf_func_state *state = vstate->frame[vstate->curframe]; struct bpf_reg_state *regs =...
static int adjust_ptr_min_max_vals(struct bpf_verifier_env *env, struct bpf_insn *insn, const struct bpf_reg_state *ptr_reg, const struct bpf_reg_state *off_reg) { struct bpf_verifier_state *vstate = env->cur_state; struct bpf_func_state *state = vstate->frame[vstate->curframe]; struct bpf_reg_state *regs =...
static int adjust_ptr_min_max_vals(struct bpf_verifier_env *env, struct bpf_insn *insn, const struct bpf_reg_state *ptr_reg, const struct bpf_reg_state *off_reg) { struct bpf_verifier_state *vstate = env->cur_state; struct bpf_func_state *state = vstate->frame[vstate->curframe]; struct bpf_reg_state *regs =...
static int adjust_ptr_min_max_vals(struct bpf_verifier_env *env, struct bpf_insn *insn, const struct bpf_reg_state *ptr_reg, const struct bpf_reg_state *off_reg) { struct bpf_verifier_state *vstate = env->cur_state; struct bpf_func_state *state = vstate->frame[vstate->curframe]; struct bpf_reg_state *regs =...
static int adjust_ptr_min_max_vals(struct bpf_verifier_env *env, struct bpf_insn *insn, const struct bpf_reg_state *ptr_reg, const struct bpf_reg_state *off_reg) { bool known = tnum_is_const(off_reg->var_off); s64 smin_val = off_reg->smin_value, smax_val = off_reg->smax_value, smin_ptr = ptr_reg->smin_value, sm...
static int adjust_ptr_min_max_vals(struct bpf_verifier_env *env, struct bpf_insn *insn, const struct bpf_reg_state *ptr_reg, const struct bpf_reg_state *off_reg) { bool known = tnum_is_const(off_reg->var_off); s64 smin_val = off_reg->smin_value, smax_val = off_reg->smax_value, smin_ptr = ptr_reg->smin_value, sm...
static int adjust_ptr_min_max_vals(struct bpf_verifier_env *env, struct bpf_insn *insn, const struct bpf_reg_state *ptr_reg, const struct bpf_reg_state *off_reg) { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ bool known = tnum_is_const(off_reg->var_off); s64 smin_val = off_reg->smin_value, smax_val = off_r...
static int adjust_ptr_min_max_vals(struct bpf_verifier_env *env, struct bpf_insn *insn, const struct bpf_reg_state *ptr_reg, const struct bpf_reg_state *off_reg) { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ bool known = tnum_is_const(off_reg->var_off); s64 smin_val = off_reg->smin_value, smax_val = off_r...
static int adjust_ptr_min_max_vals(struct bpf_verifier_env *env, struct bpf_insn *insn, const struct bpf_reg_state *ptr_reg, const struct bpf_reg_state *off_reg) { bool known = tnum_is_const(off_reg->var_off); s64 smin_val = off_reg->smin_value, smax_val = off_reg->smax_value, smin_ptr = ptr_reg->smin_value,...
CVE-2021-29264
linux
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux
drivers/net/ethernet/freescale/gianfar.c
gfar_add_rx_frag
static bool gfar_add_rx_frag(struct gfar_rx_buff *rxb, u32 lstatus, struct sk_buff *skb, bool first) { int size = lstatus & BD_LENGTH_MASK; struct page *page = rxb->page; if (likely(first)) { skb_put(skb, size); } else { if (lstatus & BD_LFLAG(RXBD_LAST)) { size -= skb->len; ...
static bool gfar_add_rx_frag(struct gfar_rx_buff *rxb, u32 lstatus, struct sk_buff *skb, bool first) { int size = lstatus & BD_LENGTH_MASK; struct page *page = rxb->page; if (likely(first)) { skb_put(skb, size); } else { if (lstatus & BD_LFLAG(RXBD_LAST)) { size -= skb->len; ...
static bool gfar_add_rx_frag(struct gfar_rx_buff *rxb, u32 lstatus, struct sk_buff *skb, bool first) { int size = lstatus & BD_LENGTH_MASK; struct page *page = rxb->page; if (likely(first)) { skb_put(skb, size); } else { if (lstatus & BD_LFLAG(RXBD_LAST)) { size -= skb->len; ...
static bool gfar_add_rx_frag(struct gfar_rx_buff *rxb, u32 lstatus, struct sk_buff *skb, bool first) { int size = lstatus & BD_LENGTH_MASK; struct page *page = rxb->page; if (likely(first)) { skb_put(skb, size); } else { if (lstatus & BD_LFLAG(RXBD_LAST)) { size -= skb->len; ...
static bool gfar_add_rx_frag(struct gfar_rx_buff *rxb, u32 lstatus, struct sk_buff *skb, bool first) { int size = lstatus & BD_LENGTH_MASK; if (likely(first)) { } else { if (lstatus & BD_LFLAG(RXBD_LAST)) { size -= skb->len; } skb_add_rx_frag(skb, skb_shinfo(skb)->nr_frag...
static bool gfar_add_rx_frag(struct gfar_rx_buff *rxb, u32 lstatus, struct sk_buff *skb, bool first) { int size = lstatus & BD_LENGTH_MASK; if (likely(first)) { } else { if (lstatus & BD_LFLAG(RXBD_LAST)) { size -= skb->len; } WARN(size < 0, "gianfar: rx fragment size und...
static bool gfar_add_rx_frag(struct gfar_rx_buff *rxb, u32 lstatus, struct sk_buff *skb, bool first) { int size = lstatus & BD_LENGTH_MASK; /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ if (likely(first)) { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ } else { if (lstatus & BD_LFLAG(RXBD_LA...
static bool gfar_add_rx_frag(struct gfar_rx_buff *rxb, u32 lstatus, struct sk_buff *skb, bool first) { int size = lstatus & BD_LENGTH_MASK; /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ if (likely(first)) { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ } else { if (lstatus & BD_LFLAG(RXBD_LA...
static bool gfar_add_rx_frag(struct gfar_rx_buff *rxb, u32 lstatus, struct sk_buff *skb, bool first) { int size = lstatus & BD_LENGTH_MASK; if (likely(first)) { } else { if (lstatus & BD_LFLAG(RXBD_LAST)) { size -= skb->len; + } + WARN(size < 0, "gianfar: rx fragment ...
CVE-2021-29264
linux
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux
drivers/net/ethernet/freescale/gianfar.c
gfar_clean_rx_ring
static int gfar_clean_rx_ring(struct gfar_priv_rx_q *rx_queue, int rx_work_limit) { struct net_device *ndev = rx_queue->ndev; struct gfar_private *priv = netdev_priv(ndev); struct rxbd8 *bdp; int i, howmany = 0; struct sk_buff *skb = rx_queue->skb; int cleaned_cnt = gfar_rxbd_unused(rx_queue); ...
static int gfar_clean_rx_ring(struct gfar_priv_rx_q *rx_queue, int rx_work_limit) { struct net_device *ndev = rx_queue->ndev; struct gfar_private *priv = netdev_priv(ndev); struct rxbd8 *bdp; int i, howmany = 0; struct sk_buff *skb = rx_queue->skb; int cleaned_cnt = gfar_rxbd_unused(rx_queue); ...
int gfar_clean_rx_ring(struct gfar_priv_rx_q *rx_queue, int rx_work_limit) { struct net_device *ndev = rx_queue->ndev; struct gfar_private *priv = netdev_priv(ndev); struct rxbd8 *bdp; int i, howmany = 0; struct sk_buff *skb = rx_queue->skb; int cleaned_cnt = gfar_rxbd_unused(rx_queue); unsi...
int gfar_clean_rx_ring(struct gfar_priv_rx_q *rx_queue, int rx_work_limit) { struct net_device *ndev = rx_queue->ndev; struct gfar_private *priv = netdev_priv(ndev); struct rxbd8 *bdp; int i, howmany = 0; struct sk_buff *skb = rx_queue->skb; int cleaned_cnt = gfar_rxbd_unused(rx_queue); unsi...
static int gfar_clean_rx_ring(struct gfar_priv_rx_q *rx_queue, int rx_work_limit) { struct sk_buff *skb = rx_queue->skb; while (rx_work_limit--) { u32 lstatus; if (cleaned_cnt >= GFAR_RX_BUFF_ALLOC) { gfar_alloc_rx_buffs(rx_queue, cleaned_cnt); cleaned_cnt = 0; } ...
static int gfar_clean_rx_ring(struct gfar_priv_rx_q *rx_queue, int rx_work_limit) { struct sk_buff *skb = rx_queue->skb; while (rx_work_limit--) { u32 lstatus; if (cleaned_cnt >= GFAR_RX_BUFF_ALLOC) { gfar_alloc_rx_buffs(rx_queue, cleaned_cnt); cleaned_cnt = 0; } ...
int gfar_clean_rx_ring(struct gfar_priv_rx_q *rx_queue, int rx_work_limit) { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ struct sk_buff *skb = rx_queue->skb; /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ while (rx_work_limit--) { u32 lstatus; if (cleaned_cnt >= GFAR_RX_BUFF_ALLOC) { ...
int gfar_clean_rx_ring(struct gfar_priv_rx_q *rx_queue, int rx_work_limit) { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ struct sk_buff *skb = rx_queue->skb; /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ while (rx_work_limit--) { u32 lstatus; if (cleaned_cnt >= GFAR_RX_BUFF_ALLOC) { ...
static int gfar_clean_rx_ring(struct gfar_priv_rx_q *rx_queue, int rx_work_limit) { struct sk_buff *skb = rx_queue->skb; while (rx_work_limit--) { u32 lstatus; if (cleaned_cnt >= GFAR_RX_BUFF_ALLOC) { gfar_alloc_rx_buffs(rx_queue, cleaned_cnt); cleaned_cnt = 0; ...
CVE-2021-29266
linux
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux
drivers/vhost/vdpa.c
vhost_vdpa_config_put
static void vhost_vdpa_config_put(struct vhost_vdpa *v) { if (v->config_ctx) { eventfd_ctx_put(v->config_ctx); } }
static void vhost_vdpa_config_put(struct vhost_vdpa *v) { if (v->config_ctx) { eventfd_ctx_put(v->config_ctx); v->config_ctx = NULL; } }
static void vhost_vdpa_config_put(struct vhost_vdpa *v) { if (v->config_ctx) { eventfd_ctx_put(v->config_ctx); } }
static void vhost_vdpa_config_put(struct vhost_vdpa *v) { if (v->config_ctx) { eventfd_ctx_put(v->config_ctx); v->config_ctx = NULL; } }
static void vhost_vdpa_config_put(struct vhost_vdpa *v) { if (v->config_ctx) { eventfd_ctx_put(v->config_ctx); } }
static void vhost_vdpa_config_put(struct vhost_vdpa *v) { if (v->config_ctx) { eventfd_ctx_put(v->config_ctx); v->config_ctx = NULL; } }
static void vhost_vdpa_config_put(struct vhost_vdpa *v) { if (v->config_ctx) { eventfd_ctx_put(v->config_ctx); } }
static void vhost_vdpa_config_put(struct vhost_vdpa *v) { if (v->config_ctx) { eventfd_ctx_put(v->config_ctx); v->config_ctx = NULL; } }
static void vhost_vdpa_config_put(struct vhost_vdpa *v) { if (v->config_ctx) { eventfd_ctx_put(v->config_ctx); + v->config_ctx = NULL; } }
CVE-2021-29646
linux
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux
net/tipc/node.c
tipc_nl_retrieve_key
static int tipc_nl_retrieve_key(struct nlattr **attrs, struct tipc_aead_key **key) { struct nlattr *attr = attrs[TIPC_NLA_NODE_KEY]; if (!attr) { return -ENODATA; } *key = (struct tipc_aead_key *)nla_data(attr); if (nla_len(attr) < tipc_aead_key_size(*key)) { return -EVAL; } ...
static int tipc_nl_retrieve_key(struct nlattr **attrs, struct tipc_aead_key **pkey) { struct nlattr *attr = attrs[TIPC_NLA_NODE_KEY]; struct tipc_aead_key *key; if (!attr) { return -ENODATA; } if (nla_len(attr) < sizeof(*key)) { return -EVAL; } key = (struct tipc_aead_key *)n...
static int tipc_nl_retrieve_key(struct nlattr **attrs, struct tipc_aead_key **key) { struct nlattr *attr = attrs[TIPC_NLA_NODE_KEY]; if (!attr) { return -ENODATA; } *key = (struct tipc_aead_key *)nla_data(attr); if (nla_len(attr) < tipc_aead_key_size(*key)) { return -EVAL; } ...
static int tipc_nl_retrieve_key(struct nlattr **attrs, struct tipc_aead_key **pkey) { struct nlattr *attr = attrs[TIPC_NLA_NODE_KEY]; struct tipc_aead_key *key; if (!attr) { return -ENODATA; } if (nla_len(attr) < sizeof(*key)) { return -EVAL; } key = (struct tipc_aead_key *)n...
static int tipc_nl_retrieve_key(struct nlattr **attrs, struct tipc_aead_key **key) { struct nlattr *attr = attrs[TIPC_NLA_NODE_KEY]; if (!attr) { return -ENODATA; } *key = (struct tipc_aead_key *)nla_data(attr); if (nla_len(attr) < tipc_aead_key_size(*key)) { return -EVAL; } ...
static int tipc_nl_retrieve_key(struct nlattr **attrs, struct tipc_aead_key **pkey) { struct nlattr *attr = attrs[TIPC_NLA_NODE_KEY]; struct tipc_aead_key *key; if (!attr) { return -ENODATA; } if (nla_len(attr) < sizeof(*key)) { return -EVAL; } key = (struct tipc_aead_key *)n...
static int tipc_nl_retrieve_key(struct nlattr **attrs, struct tipc_aead_key **key) { struct nlattr *attr = attrs[TIPC_NLA_NODE_KEY]; if (!attr) { return -ENODATA; } *key = (struct tipc_aead_key *)nla_data(attr); if (nla_len(attr) < tipc_aead_key_size(*key)) { return -EVAL; } ...
static int tipc_nl_retrieve_key(struct nlattr **attrs, struct tipc_aead_key **pkey) { struct nlattr *attr = attrs[TIPC_NLA_NODE_KEY]; struct tipc_aead_key *key; if (!attr) { return -ENODATA; } if (nla_len(attr) < sizeof(*key)) { return -EVAL; } key = (struct tipc_aead_key *)n...
-static int tipc_nl_retrieve_key(struct nlattr **attrs, struct tipc_aead_key **key) { +static int tipc_nl_retrieve_key(struct nlattr **attrs, struct tipc_aead_key **pkey) { struct nlattr *attr = attrs[TIPC_NLA_NODE_KEY]; + struct tipc_aead_key *key; if (!attr) { return -ENODATA; } - *key =...
CVE-2021-29647
linux
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux
net/qrtr/qrtr.c
qrtr_recvmsg
static int qrtr_recvmsg(struct socket *sock, struct msghdr *msg, size_t size, int flags) { DECLARE_SOCKADDR(struct sockaddr_qrtr *, addr, msg->msg_name); struct sock *sk = sock->sk; struct sk_buff *skb; struct qrtr_cb *cb; int copied, rc; lock_sock(sk); if (sock_flag(sk, SOCK_ZAPPED)) { ...
static int qrtr_recvmsg(struct socket *sock, struct msghdr *msg, size_t size, int flags) { DECLARE_SOCKADDR(struct sockaddr_qrtr *, addr, msg->msg_name); struct sock *sk = sock->sk; struct sk_buff *skb; struct qrtr_cb *cb; int copied, rc; lock_sock(sk); if (sock_flag(sk, SOCK_ZAPPED)) { ...
static int qrtr_recvmsg(struct socket *sock, struct msghdr *msg, size_t size, int flags) { DECLARE_SOCKADDR(struct sockaddr_qrtr *, addr, msg->msg_name); const struct qrtr_hdr *phdr; struct sock *sk = sock->sk; struct sk_buff *skb; int copied, rc; lock_sock(sk); if (sock_flag(sk, SOCK_ZAPPED...
static int qrtr_recvmsg(struct socket *sock, struct msghdr *msg, size_t size, int flags) { DECLARE_SOCKADDR(struct sockaddr_qrtr *, addr, msg->msg_name); const struct qrtr_hdr *phdr; struct sock *sk = sock->sk; struct sk_buff *skb; int copied, rc; lock_sock(sk); if (sock_flag(sk, SOCK_ZAPPED...
static int qrtr_recvmsg(struct socket *sock, struct msghdr *msg, size_t size, int flags) { if (addr) { addr->sq_family = AF_QIPCRTR; } }
static int qrtr_recvmsg(struct socket *sock, struct msghdr *msg, size_t size, int flags) { if (addr) { memset(addr, 0, sizeof(*addr)); addr->sq_family = AF_QIPCRTR; } }
static int qrtr_recvmsg(struct socket *sock, struct msghdr *msg, size_t size, int flags) { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ if (addr) { addr->sq_family = AF_QIPCRTR; /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ } /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ }
static int qrtr_recvmsg(struct socket *sock, struct msghdr *msg, size_t size, int flags) { /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ if (addr) { memset(addr, 0, sizeof(*addr)); addr->sq_family = AF_QIPCRTR; /* PLACEHOLDER: DO NOT DELETE THIS COMMENT */ } /* PLACEHOLDER: DO NOT DE...
static int qrtr_recvmsg(struct socket *sock, struct msghdr *msg, size_t size, int flags) { if (addr) { + memset(addr, 0, sizeof(*addr)); addr->sq_family = AF_QIPCRTR; } }