linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: "Martin K. Petersen" <martin.petersen@oracle.com>
To: Len Baker <len.baker@gmx.com>,
	James Smart <james.smart@broadcom.com>,
	Ram Vegesna <ram.vegesna@broadcom.com>,
	"James E.J. Bottomley" <jejb@linux.ibm.com>
Cc: "Martin K . Petersen" <martin.petersen@oracle.com>,
	linux-scsi@vger.kernel.org, linux-kernel@vger.kernel.org,
	Kees Cook <keescook@chromium.org>,
	target-devel@vger.kernel.org, linux-hardening@vger.kernel.org,
	Hannes Reinecke <hare@suse.de>
Subject: Re: [PATCH] scsi: elx: libefc: Prefer kcalloc over open coded arithmetic
Date: Wed, 22 Sep 2021 00:45:21 -0400	[thread overview]
Message-ID: <163228527480.25516.16772825174305781427.b4-ty@oracle.com> (raw)
In-Reply-To: <20210905062448.6587-1-len.baker@gmx.com>

On Sun, 5 Sep 2021 08:24:48 +0200, Len Baker wrote:

> As noted in the "Deprecated Interfaces, Language Features, Attributes,
> and Conventions" documentation [1], size calculations (especially
> multiplication) should not be performed in memory allocator (or similar)
> function arguments due to the risk of them overflowing. This could lead
> to values wrapping around and a smaller allocation being made than the
> caller was expecting. Using those allocations could lead to linear
> overflows of heap memory and other misbehaviors.
> 
> [...]

Applied to 5.16/scsi-queue, thanks!

[1/1] scsi: elx: libefc: Prefer kcalloc over open coded arithmetic
      https://git.kernel.org/mkp/scsi/c/0a5e20fc8ca7

-- 
Martin K. Petersen	Oracle Linux Engineering

      parent reply	other threads:[~2021-09-22  4:46 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-09-05  6:24 [PATCH] scsi: elx: libefc: Prefer kcalloc over open coded arithmetic Len Baker
2021-09-07 16:55 ` James Smart
2021-09-22  4:45 ` 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=163228527480.25516.16772825174305781427.b4-ty@oracle.com \
    --to=martin.petersen@oracle.com \
    --cc=hare@suse.de \
    --cc=james.smart@broadcom.com \
    --cc=jejb@linux.ibm.com \
    --cc=keescook@chromium.org \
    --cc=len.baker@gmx.com \
    --cc=linux-hardening@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-scsi@vger.kernel.org \
    --cc=ram.vegesna@broadcom.com \
    --cc=target-devel@vger.kernel.org \
    /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 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).