mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Niklas Cassel <cassel@kernel.org>
To: Damien Le Moal <dlemoal@kernel.org>
Cc: Yang Zi <2959243019@qq.com>,
	linux-ide@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH] ata: pata_pdc2027x: fix division by zero in pdc_adjust_pll
Date: Mon, 31 Aug 2026 09:53:28 +0200	[thread overview]
Message-ID: <apUy-Im7MroUT54y@ryzen> (raw)
In-Reply-To: <8418baf3-4a3c-4011-ba5d-a9c2e4ea893b@kernel.org>

On Fri, Aug 28, 2026 at 02:48:06PM +0900, Damien Le Moal wrote:
> On 8/25/26 17:32, Yang Zi wrote:
> > pdc_adjust_pll() divides pout_required by pll_clock_khz before checking
> > that pll_clock_khz is within the valid range. If the PLL input clock is
> > less than 1000 Hz, pll_clock_khz is 0 and the division triggers a
> > divide-by-zero error.
> > 
> > Move the sanity check ahead of the division so the invalid input is
> > rejected before the ratio is computed.
> > 
> > Signed-off-by: Yang Zi <2959243019@qq.com>
> 
> This is needs a fixes tag I think.
> 
> Other than that, looks OK.
> 
> Reviewed-by: Damien Le Moal <dlemoal@kernel.org>

Hello Yang,

Please send a V2 with a Fixes tag.


Kind regards,
Niklas

      reply	other threads:[~2026-08-31  7:53 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-08-25  8:32 Yang Zi
2026-08-28  5:48 ` Damien Le Moal
2026-08-31  7:53   ` Niklas Cassel [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=apUy-Im7MroUT54y@ryzen \
    --to=cassel@kernel.org \
    --cc=2959243019@qq.com \
    --cc=dlemoal@kernel.org \
    --cc=linux-ide@vger.kernel.org \
    --cc=linux-kernel@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

all inboxes | Powered by JetHome®