Re: [sigrok-devel] [PATCH 5/5] sr: fx2lafw: Calculate buffer size and timeout based on sample rate

2012-06-26 Thread Joel Holdsworth
Hey Lars yeah 1-4 look good to me. And you got it with the const thing. If you could resend 5 that would be great! Thanks Joel Lars-Peter Clausen wrote: >On 06/26/2012 08:56 AM, Joel Holdsworth wrote: >> Hi Lars, >> >> Thanks for these. They look really good. >> >> Just a couple of minor poi

Re: [sigrok-devel] [PATCH 5/5] sr: fx2lafw: Calculate buffer size and timeout based on sample rate

2012-06-26 Thread Lars-Peter Clausen
On 06/26/2012 08:56 AM, Joel Holdsworth wrote: > Hi Lars, > > Thanks for these. They look really good. > > Just a couple of minor points: >> +n = ctx->cur_samplerate / get_buffer_size(ctx) / 2; >> +timeout = total_size / (ctx->cur_samplerate / 1000); > These lines, particularly the first

Re: [sigrok-devel] [PATCH 5/5] sr: fx2lafw: Calculate buffer size and timeout based on sample rate

2012-06-26 Thread Joel Holdsworth
Hi Lars, Thanks for these. They look really good. Just a couple of minor points: > + n = ctx->cur_samplerate / get_buffer_size(ctx) / 2; > + timeout = total_size / (ctx->cur_samplerate / 1000); These lines, particularly the first one would be better with one division not 2. Also please