Re: [PATCH] pl2303: restore the old baud rate encoding for HXD (and newer) chips

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

 



Am 31.10.2013 13:30, schrieb Mika Westerberg:
> On Thu, Oct 31, 2013 at 01:02:56PM +0100, Frank Schäfer wrote:
>> 2) comment out the following line at the end of
>> pl2303_baudrate_encode_divisor_HXD():
>>
>> baud = 12000000 * 32 / ((1 << buf[1]) * buf[0]);
> This seems to fix the problem :)
>
> Once the line is commented out, the serial console works fine with the
> speeds I've been testing (115200, 230400 and 460800).

Urgh... so it seems getty gets confused if the actually set baud rate is
reported back.
The kernel still reports the standard baud rate (e.g. B230400), it only
sets the exact value in the c_ispeed and c_ospeed fields of the termios
struct.
So even if getty doesn't support non-standard baud rates, everything
should be fine.
I'll have to take a closer look at this issue later.

Ok, so now let's see if the fixed/improved divisor based method also
works for the HXD chip if we don't report the actually set baud rate.
Try commenting out the line

    baud = 12000000 * 32 / ((1 << A) * B);

at the end of pl2303_baudrate_encode_divisor() of a clean 3.12-rc kernel.
It's unlikely that this makes baud rates < 115200 working, but testing
both cases doesn't harm. ;)

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




[Index of Archives]     [Linux Media]     [Linux Input]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [Old Linux USB Devel Archive]

  Powered by Linux