[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <yq1tta65oqt.fsf@ca-mkp.ca.oracle.com>
Date: Fri, 10 Jan 2025 16:44:16 -0500
From: "Martin K. Petersen" <martin.petersen@...cle.com>
To: Ma Ke <make_ruc2021@....com>
Cc: jejb@...ux.ibm.com, martin.petersen@...cle.com, jeff@...zik.org,
James.Bottomley@...elEye.com, linux-scsi@...r.kernel.org,
linux-kernel@...r.kernel.org, stable@...r.kernel.org
Subject: Re: [PATCH RESEND] [SCSI] raid class: Fix error handling in
raid_component_add
> The reference count of the device incremented in device_initialize()
> is not decremented when device_add() fails. Add a put_device() call
> before returning from the function to decrement reference count for
> cleanup. Or it could cause memory leak.
60c5fd2e8f3c ("scsi: core: raid_class: Remove raid_component_add()")
--
Martin K. Petersen Oracle Linux Engineering
Powered by blists - more mailing lists