Linux-SCSI Archive on lore.kernel.org
 help / color / Atom feed
From: "Martin K. Petersen" <martin.petersen@oracle.com>
To: kjlu@umn.edu, "wu000273@umn.edu" <wu000273@umn.edu>
Cc: "Martin K . Petersen" <martin.petersen@oracle.com>,
	Lee Duncan <lduncan@suse.com>,
	open-iscsi@googlegroups.com,
	"James E.J. Bottomley" <jejb@linux.ibm.com>,
	linux-scsi@vger.kernel.org, Chris Leech <cleech@redhat.com>,
	linux-kernel@vger.kernel.org
Subject: Re: [PATCH] scsi: Fix reference count leak in iscsi_boot_create_kobj.
Date: Tue,  2 Jun 2020 22:31:38 -0400
Message-ID: <159114947917.26776.6215710664403797046.b4-ty@oracle.com> (raw)
In-Reply-To: <20200528201353.14849-1-wu000273@umn.edu>

On Thu, 28 May 2020 15:13:53 -0500, wu000273@umn.edu wrote:

> kobject_init_and_add() should be handled when it return an error,
> because kobject_init_and_add() takes reference even when it fails.
> If this function returns an error, kobject_put() must be called to
> properly clean up the memory associated with the object. Previous
> commit "b8eb718348b8" fixed a similar problem. Thus replace calling
> kfree() by calling kobject_put().

Applied to 5.8/scsi-queue, thanks!

[1/1] scsi: iscsi: Fix reference count leak in iscsi_boot_create_kobj
      https://git.kernel.org/mkp/scsi/c/0267ffce562c

-- 
Martin K. Petersen	Oracle Linux Engineering

      parent reply index

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-05-28 20:13 wu000273
2020-05-29 15:09 ` Lee Duncan
2020-06-03  2:31 ` Martin K. Petersen [this message]

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=159114947917.26776.6215710664403797046.b4-ty@oracle.com \
    --to=martin.petersen@oracle.com \
    --cc=cleech@redhat.com \
    --cc=jejb@linux.ibm.com \
    --cc=kjlu@umn.edu \
    --cc=lduncan@suse.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-scsi@vger.kernel.org \
    --cc=open-iscsi@googlegroups.com \
    --cc=wu000273@umn.edu \
    /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

Linux-SCSI Archive on lore.kernel.org

Archives are clonable:
	git clone --mirror https://lore.kernel.org/linux-scsi/0 linux-scsi/git/0.git

	# If you have public-inbox 1.1+ installed, you may
	# initialize and index your mirror using the following commands:
	public-inbox-init -V2 linux-scsi linux-scsi/ https://lore.kernel.org/linux-scsi \
		linux-scsi@vger.kernel.org
	public-inbox-index linux-scsi

Example config snippet for mirrors

Newsgroup available over NNTP:
	nntp://nntp.lore.kernel.org/org.kernel.vger.linux-scsi


AGPL code for this site: git clone https://public-inbox.org/public-inbox.git