Re: [PATCH v2] serial: 8250_pci: fix divide error bug if baud rate is 0

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Andy Shevchenko wrote:
> On Tue, 2016-04-26 at 16:40 +0200, David Müller wrote:
>> Since commit 21947ba654 (serial: 8250_pci: replace switch-case by 
>> formula), the 8250 driver crashes in the byt_set_termios() function
>> with a divide error.  
>> This is caused by the fact that a baud rate of 0 (B0)
>> is not handled properly.
> 
> Please, add that you fall back to 9600 in this case.
> 
> You may add Fixes tag as well as Cc to stable@ if needed.

Ok, I will change the wording of the commit message and add the Fixes
and Cc tags as desired.

>> +	/* gracefully handle the B0 case */
> 
> Capital letter first.
> 
> /* Gracefully handle the B0 case: fall back to B9600 */

I think this is a bit misleading. The baud rate is not changed, we
just make sure that the UART input clock is within acceptable limits.

--
To unsubscribe from this list: send the line "unsubscribe linux-serial" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html



[Index of Archives]     [Kernel Newbies]     [Security]     [Netfilter]     [Bugtraq]     [Linux PPP]     [Linux FS]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Samba]     [Video 4 Linux]     [Linmodem]     [Device Mapper]     [Linux Kernel for ARM]

  Powered by Linux