Bug 2295922 - kernel: mmc: davinci: Don't strip remove function when driver is builtin
Summary: kernel: mmc: davinci: Don't strip remove function when driver is builtin
Keywords:
Status: CLOSED DUPLICATE of bug 2296047
Alias: None
Product: Security Response
Classification: Other
Component: vulnerability
Version: unspecified
Hardware: All
OS: Linux
medium
medium
Target Milestone: ---
Assignee: Product Security DevOps Team
QA Contact:
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2024-07-05 09:23 UTC by OSIDB Bzimport
Modified: 2024-07-12 13:27 UTC (History)
4 users (show)

Fixed In Version:
Clone Of:
Environment:
Last Closed: 2024-07-05 20:55:27 UTC
Embargoed:


Attachments (Terms of Use)

Description OSIDB Bzimport 2024-07-05 09:23:07 UTC
In the Linux kernel, the following vulnerability has been resolved:

mmc: davinci: Don't strip remove function when driver is builtin

Using __exit for the remove function results in the remove callback being
discarded with CONFIG_MMC_DAVINCI=y. When such a device gets unbound (e.g.
using sysfs or hotplug), the driver is just removed without the cleanup
being performed. This results in resource leaks. Fix it by compiling in the
remove callback unconditionally.

This also fixes a W=1 modpost warning:

WARNING: modpost: drivers/mmc/host/davinci_mmc: section mismatch in
reference: davinci_mmcsd_driver+0x10 (section: .data) ->
davinci_mmcsd_remove (section: .exit.text)

Comment 1 Mauro Matteo Cascella 2024-07-05 20:55:27 UTC

*** This bug has been marked as a duplicate of bug 2296047 ***


Note You need to log in before you can comment on or make changes to this bug.