Major improvements to the ch341 driver v4

Grigori Goronzy
2016-04-15T21:18:19Z

Hi,

here's a hopefully final v4 of my ch341 patchset. Changelog below
this time, because it's cleary better this way. Please review.

v4:
- Fix parity even/odd mixup introduced in v3.
- Fix compilation errors of intermediate commits introduced in v3.

v3:
- Use u8 shorthand for unsigned char.
- Get rid of an unused variable.
- Improve error handling in set_termios.
- Only set mark/space when parity is enabled.
- Use C_* macros and some other simplifications.
- Patch termios HW flags for default CS8 case.
- Drop most style fixes.
- Unify definitions for the "general status" register bits.

v2:
- Improve/fix B0 handling.
- Fix initial/default configuration.
- Add tx_empty callback.
- Split up one patch:
- Reinitialize chip on reconfiguration.
- Add support for parity, frame length, stop bits.

v1:
- Initial version

Best regards
Grigori