asix-sigma: Init cur_sample_rate
Init the cur_sample_rate to 200kHz. This is now the default sample rate for the ASIX Sigma if no other is specified by -c samplerate=N on the command line. Without this change, the driver would crash on SIGFPE because a division by zero would happen. Signed-off-by: Marek Vasut <marex@denx.de>
This commit is contained in:
parent
1e23158b93
commit
23b886bc40
|
@ -360,7 +360,7 @@ static GSList *scan(GSList *options)
|
|||
|
||||
sr_info("Found ASIX SIGMA - Serial: %s", serial_txt);
|
||||
|
||||
devc->cur_samplerate = 0;
|
||||
devc->cur_samplerate = samplerates[0];
|
||||
devc->period_ps = 0;
|
||||
devc->limit_msec = 0;
|
||||
devc->cur_firmware = -1;
|
||||
|
|
Loading…
Reference in New Issue