lkml.org 
[lkml]   [2018]   [Jan]   [15]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
Date
SubjectRe: [PATCH] serial: 8250_dw: Avoid overflow in dw8250_set_termios
On Fri, Jan 12, 2018 at 3:45 PM, Ed Blake <ed.blake@sondrel.com> wrote:
> When searching for an achievable input clock rate that is within
> +/-1.6% of an integer multiple of the target baudx16 rate, there is the
> potential to overflow the i * rate calculations.
>
> For example, on a 32-bit system with a baud rate of 4000000, the
> i * max_rate calculation will overflow if i reaches 67 without finding
> an acceptable rate.
>
> Fix this by setting the upper boundary of the loop appropriately to
> avoid overflow.
>

It seems the change broke Bluetooth on some Intel platforms. I'm not
sure yet, but
see here:

https://github.com/Dunedan/mbp-2016-linux/issues/29#issuecomment-357583782

And for me the change is odd.

Why by the way neither Heikki, nor me had been Cc'ed with the change?

Perhaps I need to submit something to maintainer data base.

For now I would rather revert it and give another try.

--
With Best Regards,
Andy Shevchenko

\
 
 \ /
  Last update: 2018-01-15 21:31    [W:0.069 / U:0.916 seconds]
©2003-2018 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site