mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Bryan O'Donoghue <bryan.odonoghue@linaro.org>
To: Rosen Penev <rosenp@gmail.com>, linux-usb@vger.kernel.org
Cc: Heikki Krogerus <heikki.krogerus@linux.intel.com>,
	Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
	Kees Cook <kees@kernel.org>,
	"Gustavo A. R. Silva" <gustavoars@kernel.org>,
	"open list:QUALCOMM TYPEC PORT MANAGER DRIVER"
	<linux-arm-msm@vger.kernel.org>,
	open list <linux-kernel@vger.kernel.org>,
	open "list:KERNEL" HARDENING "(not" covered by other
	"areas):Keyword:b__counted_by(_le|_be)?b"
	<linux-hardening@vger.kernel.org>
Subject: Re: [PATCHv2] usb: typec: qcom-pmic-typec: simplify allocation
Date: Wed, 11 Mar 2026 23:37:11 +0000	[thread overview]
Message-ID: <223e0295-1819-4234-90d9-7db440f25be3@linaro.org> (raw)
In-Reply-To: <20260311232347.18257-1-rosenp@gmail.com>

On 11/03/2026 23:23, Rosen Penev wrote:
> Change kzalloc + kcalloc to just kzalloc with a flexible array member.
> 
> Add __counted_by for extra runtime analysis when requested.
> 
> Move counting assignment immediately after allocation as required by
> __counted_by.
> 
> Signed-off-by: Rosen Penev <rosenp@gmail.com>

Hi Rosen.

Thanks for your patch.

I have the same feedback as Greg gave you previously on this.

Each line-item in your log should really be its own patch i.e. v3 should 
be three patches

[PATCH v3 1/3] Change kzalloc + kcalloc to just kzalloc with a flexible 
array member.

[PATCH v3 2/3] Add __counted_by for extra runtime analysis when requested.

[PATCH v3 3/3] Move counting assignment immediately after allocation as 
required by __counted_by.

Or something pretty close to that.

There are several reasons for that

1. Bisectability
    The ability to more easily bisect patches.

2. Logical separation
    If a change deserves its own line-item in a patch
    then that change almost certainly deserves its own patch.

3. Mixing stuff up in a big patch is confusing
    I look at a commit log and see lots of things going on in one go.
    I as a reviewer or say someone tracking -stable and deciding which
    patches to pull into my tree can't look at a patch a "just know" what
    it is doing.

So v3 should please

- Have a cover letter
- Contain three patches one for each logical change

Oh and reason 4 is the most important !

Patch count bragging rights !

---
bod

  reply	other threads:[~2026-03-11 23:37 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-03-11 23:23 Rosen Penev
2026-03-11 23:37 ` Bryan O'Donoghue [this message]
2026-03-12  0:12   ` Rosen Penev
2026-03-12  0:17     ` Bryan O'Donoghue

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=223e0295-1819-4234-90d9-7db440f25be3@linaro.org \
    --to=bryan.odonoghue@linaro.org \
    --cc=gregkh@linuxfoundation.org \
    --cc=gustavoars@kernel.org \
    --cc=heikki.krogerus@linux.intel.com \
    --cc=kees@kernel.org \
    --cc=linux-arm-msm@vger.kernel.org \
    --cc=linux-hardening@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-usb@vger.kernel.org \
    --cc=rosenp@gmail.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®