lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <105f1b15-9536-4847-a3c5-8ca0993cfa35@linux.ibm.com>
Date: Wed, 9 Apr 2025 20:52:08 +0530
From: Venkat Rao Bagalkote <venkat88@...ux.ibm.com>
To: Thomas Gleixner <tglx@...utronix.de>, Bert Karwatzki <spasswolf@....de>
Cc: Bjorn Helgaas <bhelgaas@...gle.com>, linux-kernel@...r.kernel.org,
        James.Bottomley@...senPartnership.com, Jonathan.Cameron@...wei.com,
        allenbh@...il.com, d-gole@...com, dave.jiang@...el.com,
        haiyangz@...rosoft.com, jdmason@...zu.us, kristo@...nel.org,
        linux-hyperv@...r.kernel.org, linux-pci@...r.kernel.org,
        linux-scsi@...r.kernel.org, logang@...tatee.com,
        manivannan.sadhasivam@...aro.org, martin.petersen@...cle.com,
        maz@...nel.org, mhklinux@...look.com, nm@...com, ntb@...ts.linux.dev,
        peterz@...radead.org, ssantosh@...nel.org, wei.huang2@....com,
        wei.liu@...nel.org, Madhavan Srinivasan <maddy@...ux.ibm.com>,
        Stephen Rothwell <sfr@...b.auug.org.au>, venkat88@...ux.ibm.com
Subject: Re: commit 7b025f3f85ed causes NULL pointer dereference


On 09/04/25 2:16 am, Thomas Gleixner wrote:
> On Tue, Apr 08 2025 at 18:20, Bert Karwatzki wrote:
>> Am Dienstag, dem 08.04.2025 um 17:29 +0200 schrieb Thomas Gleixner:
>>>> Can you please decode the lines please via:
>>>>
>>>>      scripts/faddr2line vmlinux msi_domain_first_desc+0x4/0x30
>>>>      scripts/faddr2line vmlinux msix_setup_interrupts+0x23b/0x280
>> I had to recompile with CONFIG_DEBUG_INFO=Y, and reran the test, the calltrace
>> is identical.
>>
>> $ scripts/faddr2line vmlinux msi_domain_first_desc+0x4/0x30
>> msi_domain_first_desc+0x4/0x30:
>> msi_domain_first_desc at kernel/irq/msi.c:400
>>
>> So it seems msi_domain_first_desc() is called with dev = NULL.


This issue is seen on IBM Power9 server also. Bisection is pointing to 
7b025f3f85ed4283d5a414371bb2ffd38d19033f as first bad commit.

I applied this patch on top of 20250409 and it fixes the issue.


> Yup
>
>> $ scripts/faddr2line vmlinux msix_setup_interrupts+0x23b/0x280
>> msix_setup_interrupts+0x23b/0x280:
>> msix_update_entries at drivers/pci/msi/msi.c:647 (discriminator 1)
> Aaarg. The patch below should fix that.
>
> Thanks,
>
>          tglx
> ---
> diff --git a/drivers/pci/msi/msi.c b/drivers/pci/msi/msi.c
> index 4027abcafe7a..77cc27e45b66 100644
> --- a/drivers/pci/msi/msi.c
> +++ b/drivers/pci/msi/msi.c
> @@ -680,8 +680,8 @@ static int __msix_setup_interrupts(struct pci_dev *__dev, struct msix_entry *ent
>   	if (ret)
>   		return ret;
>   
> -	retain_ptr(dev);
>   	msix_update_entries(dev, entries);
> +	retain_ptr(dev);
>   	return 0;
>   }
>   

Reported-by: Venkat Rao Bagalkote <venkat88@...ux.ibm.com>

Tested-by: Venkat Rao Bagalkote <venkat88@...ux.ibm.com>


Regards,

Venkat.


Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ