Fix critical typo with _q_startAsyncWrite()

Commit 62dfdeb3642250bdb642dbf607a8c7b95e57835e introduce a
critical typo that revert a bug which are fixed in the
b4d5bd813f591dc618e0fff2d55d93eeccb1a26e commit.

Change-Id: I9ed29f5b443cbd7102878287d531d18a9351a2e5
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
Reviewed-by: Sergey Belyashov <Sergey.Belyashov@gmail.com>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Prevent multiple calls of WaitCommEvent

Commit ac0422e8c9e74f2275129e3c7c69ef64299f07a9 introduced a regression
that QSP::startAsyncCommunication() was called twice when a limited read
buffer is used. In the second call the WaitCommEvent function returned the
ERROR_INVALID_PARAMETER error that lead to a stall of the read sequence.

QSP::startAsyncCommunication() should be called only when the read buffer
has enough space.

Tested on Windows 8 with the virtual com0com ports using Qt5.

Change-Id: Icd6cada7c3acfd4e689ac76ec304416b00f52b50
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
Reviewed-by: Sergey Belyashov <Sergey.Belyashov@gmail.com>
Improve the QSP::clear() on Windows

Commit 9c88ad89801596e1d94acc4f32ff55c34118a66f solves a problem
partially. Still when used QSP::clear() with some devices (e.g.
virtual ports from the "AGG Software") the reading can be stalled.

It is reasonable to make following:

1. Prevent to reset the both readStarted and writeStarted variables
inside of QSP::clear() method. These variables shall be reset inside
of _q_completeXX() methods which will be called automatically from the
notifiers, since the PurgeComm should terminate pending read or write
operations.

2. Instead of startAsyncRead() should be called the
startAsyncCommunication(), that allow to correctly startup of the read
sequence.

This scenario can be reproduced with running of the
tst_QSerialPort::readAfterInputClear() autotest.

Tested on Windows 8 with the virtual com0com ports and with the
virtual ports from the "AGG Software" using Qt5.

Change-Id: Ic1a53334abd97667a9dd3291c3b975eb04062efd
Reviewed-by: Robert Kurjata <rkurjata@gmail.com>
Reviewed-by: Sergey Belyashov <Sergey.Belyashov@gmail.com>
Refactor and add missed changes up 5.2.0 to 5.3.2

Change-Id: I8a3c40202a89cd1fd264e324e6379d1f6220c340
Reviewed-by: Martin Smith <martin.smith@digia.com>
Reviewed-by: Sergey Belyashov <Sergey.Belyashov@gmail.com>
Add changelog for Qt 5.4.0

Change-Id: I7c15897db3429df3a0d122893662c20ede4c8f66
Reviewed-by: Sergey Belyashov <Sergey.Belyashov@gmail.com>
Remove foreign records from 5.4.0 changes

To this changelog were added wrong changes from 5.4.1.

Change-Id: I77cc5abb7d537dda3859969d18fb22546cf466ec
Reviewed-by: Sergey Belyashov <Sergey.Belyashov@gmail.com>
Merge remote-tracking branch 'origin/5.3' into 5.4

Change-Id: I078c03570399f5212b660b7ed29d3e45ed995896
Merge remote-tracking branch 'origin/5.4.0' into 5.4

Change-Id: Ic608866ccf52db4cd42bc2563a040d9cbd47d684
Merge "Merge remote-tracking branch 'origin/5.4.0' into 5.4" into refs/staging/5.4