Re: [PATCH v2 05/17] i2c: omap: split out [XR]DR and [XR]RDY

2012-07-02 Thread Felipe Balbi
On Tue, Jun 26, 2012 at 04:11:30PM +0530, Shubhrajyoti wrote: Hi Felipe, On Thursday 14 June 2012 09:54 PM, Felipe Balbi wrote: return IRQ_HANDLED; } - if (stat (OMAP_I2C_STAT_RRDY | OMAP_I2C_STAT_RDR)) { + if (stat

Re: [PATCH v2 05/17] i2c: omap: split out [XR]DR and [XR]RDY

2012-07-02 Thread Shubhrajyoti
On Monday 02 July 2012 05:03 PM, Felipe Balbi wrote: + num_bytes = dev-fifo_size; In case of a draining interrupt. The byte count may not be the fifo size. Do you agree? hmm... indeed, that should be dev-buf_len... can you fix that up or want me to resend ? Nope I

Re: [PATCH v2 05/17] i2c: omap: split out [XR]DR and [XR]RDY

2012-06-26 Thread Shubhrajyoti
Hi Felipe, On Thursday 14 June 2012 09:54 PM, Felipe Balbi wrote: return IRQ_HANDLED; } - if (stat (OMAP_I2C_STAT_RRDY | OMAP_I2C_STAT_RDR)) { + if (stat OMAP_I2C_STAT_RDR) { u8 num_bytes = 1; +

[PATCH v2 05/17] i2c: omap: split out [XR]DR and [XR]RDY

2012-06-14 Thread Felipe Balbi
While they do pretty much the same thing, there are a few peculiarities. Specially WRT erratas, it's best to split those out and re-factor the read/write loop to another function which both cases call. This last part will be done on another patch. While at that, also avoid an unncessary register