Unverified Commit e99487d8 authored by openeuler-ci-bot's avatar openeuler-ci-bot Committed by Gitee
Browse files

!7223 major bugfix before 2023

Merge Pull Request from: @ci-robot 
 
PR sync from: Liao Chen <liaochen4@huawei.com>
https://mailweb.openeuler.org/hyperkitty/list/kernel@openeuler.org/message/ER76OUAAV3MG7MTA34FUOOWCKGKLB7EF/ 
major bugfix before 2023

Li Huafei (1):
  [Backport] powerpc/kprobes: Fix null pointer reference in
    arch_prepare_kprobe()

Mark Rutland (1):
  [Backport] irqchip/gic-v3: Ensure pseudo-NMIs have an ISB between ack
    and handling

Sergey Shtylyov (1):
  [Backport] genirq/ipi: Fix NULL pointer deref in
    irq_data_get_affinity_mask()


-- 
2.34.1
 
https://gitee.com/openeuler/kernel/issues/I9OZI6 
 
Link:https://gitee.com/openeuler/kernel/pulls/7223

 

Reviewed-by: default avatarZhang Jianhua <chris.zjh@huawei.com>
Signed-off-by: default avatarJialin Zhang <zhangjialin11@huawei.com>
parents 04dd32cb c856198f
Loading
Loading
Loading
Loading
+6 −1
Original line number Diff line number Diff line
@@ -123,7 +123,12 @@ int arch_prepare_kprobe(struct kprobe *p)
	preempt_disable();
	prev = get_kprobe(p->addr - 1);
	preempt_enable_no_resched();
	if (prev &&

	/*
	 * When prev is a ftrace-based kprobe, we don't have an insn, and it
	 * doesn't probe for prefixed instruction.
	 */
	if (prev && !kprobe_ftrace(prev) &&
	    ppc_inst_prefixed(ppc_inst_read((struct ppc_inst *)prev->ainsn.insn))) {
		printk("Cannot register a kprobe on the second word of prefixed instruction\n");
		ret = -EINVAL;
+3 −0
Original line number Diff line number Diff line
@@ -635,6 +635,9 @@ static inline void gic_handle_nmi(u32 irqnr, struct pt_regs *regs)

	if (static_branch_likely(&supports_deactivate_key))
		gic_write_eoir(irqnr);
	else
		isb();

	/*
	 * Leave the PSR.I bit set to prevent other NMIs to be
	 * received while handling this one.
+6 −2
Original line number Diff line number Diff line
@@ -186,9 +186,9 @@ EXPORT_SYMBOL_GPL(ipi_get_hwirq);
static int ipi_send_verify(struct irq_chip *chip, struct irq_data *data,
			   const struct cpumask *dest, unsigned int cpu)
{
	struct cpumask *ipimask = irq_data_get_affinity_mask(data);
	struct cpumask *ipimask;

	if (!chip || !ipimask)
	if (!chip || !data)
		return -EINVAL;

	if (!chip->ipi_send_single && !chip->ipi_send_mask)
@@ -197,6 +197,10 @@ static int ipi_send_verify(struct irq_chip *chip, struct irq_data *data,
	if (cpu >= nr_cpu_ids)
		return -EINVAL;

	ipimask = irq_data_get_affinity_mask(data);
	if (!ipimask)
		return -EINVAL;

	if (dest) {
		if (!cpumask_subset(dest, ipimask))
			return -EINVAL;