Re: [PATCH v2 1/5] serial: core: tidy invalid baudrate handling in uart_get_baud_rate

From: Max Filippov
Date: Thu Sep 28 2023 - 11:07:56 EST


On Thu, Sep 28, 2023 at 1:17 AM Greg Kroah-Hartman
<gregkh@xxxxxxxxxxxxxxxxxxx> wrote:
> On Tue, Sep 19, 2023 at 07:26:40PM -0700, Max Filippov wrote:
> > @@ -539,6 +537,7 @@ uart_get_divisor(struct uart_port *port, unsigned int baud)
> > {
> > unsigned int quot;
> >
> > + WARN_ON(baud == 0);
>
> Why is this needed? If this isn't happening today, then there's no need
> to check for this here.

I'll drop it then.

--
Thanks.
-- Max