From: sashiko-bot@kernel.org
To: "Xiaolei Wang" <wangxiaolei01@kaihong.com>
Cc: linux-pci@vger.kernel.org
Subject: Re: [PATCH] PCI/IDE: Destroy host bridge IDAs on release
Date: Thu, 19 Nov 2026 06:59:03 +0000 [thread overview]
Message-ID: <sashiko-outbox-222536@kernel.org> (raw)
In-Reply-To: <20261119065429.1824738-1-wangxiaolei01@kaihong.com>
> pci_ide_init_host_bridge() initializes two IDAs embedded in the host
> bridge and reserves stream ID 255 in ide_stream_ids_ida, which allocates
> an 128-byte IDA chunk. pci_release_host_bridge_dev(), however, only frees
> the resource lists and kfree()s the bridge, leaving both IDAs undestroyed.
> The chunk becomes unreferenced once the bridge is gone.
>
> This is observed at boot with CONFIG_DEBUG_KMEMLEAK:
>
> unreferenced object 0xffff000100d4df00 (size 128):
> comm "kworker/u16:3", pid 52, jiffies 4294892598
> backtrace (crc 6f8346e1):
> kmemleak_alloc+0x34/0x40
> __kmalloc_cache_noprof+0x3c0/0x56c
> ida_alloc_range+0x42c/0x554
> pci_ide_init_host_bridge+0x130/0x170
> [ ... ]
> pci_release_host_bridge_dev() just before kfree(), symmetric with
> pci_ide_destroy() which handles struct pci_dev.
>
> Fixes: 079115370d00 ("PCI/IDE: Initialize an ID for all IDE streams")
> Signed-off-by: Xiaolei Wang <wangxiaolei01@kaihong.com>
Sashiko has reviewed this patch and found no issues.
--
Sashiko AI review · https://sashiko.dev/#/patchset/20261119065429.1824738-1-wangxiaolei01@kaihong.com?part=1
next prev parent reply other threads:[~2026-11-19 6:59 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-11-19 6:54 [PATCH] PCI/IDE: Destroy host bridge IDAs on release Xiaolei Wang
2026-11-19 6:59 ` sashiko-bot [this message]
2026-11-19 13:33 ` Bartosz Golaszewski
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=sashiko-outbox-222536@kernel.org \
--to=sashiko-bot@kernel.org \
--cc=linux-pci@vger.kernel.org \
--cc=sashiko-reviews@lists.linux.dev \
--cc=wangxiaolei01@kaihong.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.