i2c-pnx: fix setting start/stop condition

The start/stop condtions are set in different places repetedly in the i2c-pnx
driver. Beside in i2c_pnx_start and i2c_pnx_stop the start/stop bit are also
set during the transfer of a i2c message in the master_xmit/rcv calls. This is
wrong since we can't set the start/stop condition during the transaction of a
single message any way. As a matter of fact, the driver will sometimes set both
the start and the stop bits at one time. This can be easily reproduced by
sending a simple read request like e.g
struct i2c_msg msgs[] = {
{ addr, 0, 1, buf },
{ addr, I2C_M_RD, offset, buf }
};
While processing the first message the i2c_pnx_master_xmit will set both the
start_bit and the stop_bit, which will eventually confuse the slave.

Fixed by remove setting start/stop condition from the transmit routines.

Signed-off-by: Luotao Fu <l.fu@pengutronix.de>
Signed-off-by: Ben Dooks <ben-linux@fluff.org>

authored by Luotao Fu and committed by Ben Dooks ad0194e8 96eb7164

-11
-11
drivers/i2c/busses/i2c-pnx.c
··· 172 172 /* We still have something to talk about... */ 173 173 val = *alg_data->mif.buf++; 174 174 175 - if (alg_data->mif.len == 1) { 176 - val |= stop_bit; 177 - if (!alg_data->last) 178 - val |= start_bit; 179 - } 180 - 181 175 alg_data->mif.len--; 182 176 iowrite32(val, I2C_REG_TX(alg_data)); 183 177 ··· 245 251 __func__); 246 252 247 253 if (alg_data->mif.len == 1) { 248 - /* Last byte, do not acknowledge next rcv. */ 249 - val |= stop_bit; 250 - if (!alg_data->last) 251 - val |= start_bit; 252 - 253 254 /* 254 255 * Enable interrupt RFDAIE (data in Rx fifo), 255 256 * and disable DRMIE (need data for Tx)