* [Bug 1276] platform bus use after free
@ 2023-08-22 6:22 bugzilla
2023-10-02 8:47 ` bugzilla
0 siblings, 1 reply; 2+ messages in thread
From: bugzilla @ 2023-08-22 6:22 UTC (permalink / raw)
To: dev
[-- Attachment #1: Type: text/plain, Size: 1432 bytes --]
https://bugs.dpdk.org/show_bug.cgi?id=1276
Bug ID: 1276
Summary: platform bus use after free
Product: DPDK
Version: 23.07
Hardware: ARM
OS: Linux
Status: UNCONFIRMED
Severity: critical
Priority: Normal
Component: ethdev
Assignee: dev@dpdk.org
Reporter: 869119842@qq.com
Target Milestone: ---
After I register a platform driver, a segment fault occurs when the program
call rte_eal_cleanup.
The code that causes this problem is at drivers/bus/platform/platform.c:615, as
follows:
static int
platform_bus_cleanup(void)
{
struct rte_platform_device *pdev, *tmp;
RTE_TAILQ_FOREACH_SAFE(pdev, &platform_bus.device_list, next, tmp) {
platform_bus_unplug(&pdev->device);
TAILQ_REMOVE(&platform_bus.device_list, pdev, next);
}
return 0;
}
To fix this, modify it as follows:
static int
platform_bus_cleanup(void)
{
struct rte_platform_device *pdev, *tmp;
RTE_TAILQ_FOREACH_SAFE(pdev, &platform_bus.device_list, next, tmp) {
TAILQ_REMOVE(&platform_bus.device_list, pdev, next);
platform_bus_unplug(&pdev->device);
}
return 0;
}
I'm lazy, that's all.
--
You are receiving this mail because:
You are the assignee for the bug.
[-- Attachment #2: Type: text/html, Size: 3317 bytes --]
^ permalink raw reply [flat|nested] 2+ messages in thread
* [Bug 1276] platform bus use after free
2023-08-22 6:22 [Bug 1276] platform bus use after free bugzilla
@ 2023-10-02 8:47 ` bugzilla
0 siblings, 0 replies; 2+ messages in thread
From: bugzilla @ 2023-10-02 8:47 UTC (permalink / raw)
To: dev
[-- Attachment #1: Type: text/plain, Size: 641 bytes --]
https://bugs.dpdk.org/show_bug.cgi?id=1276
David Marchand (david.marchand@redhat.com) changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|CONFIRMED |RESOLVED
CC| |david.marchand@redhat.com
Resolution|--- |FIXED
--- Comment #2 from David Marchand (david.marchand@redhat.com) ---
Fixed in d780011158ea ("bus/platform: fix bus cleanup").
Thanks.
--
You are receiving this mail because:
You are the assignee for the bug.
[-- Attachment #2: Type: text/html, Size: 2729 bytes --]
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2023-10-02 8:47 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-08-22 6:22 [Bug 1276] platform bus use after free bugzilla
2023-10-02 8:47 ` bugzilla
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).