Package list squeezelite / 43a73ca
alsa mmap debugging Adrian Smith 8 years ago
1 changed file(s) with 7 addition(s) and 0 deletion(s). Raw diff Collapse all Expand all
955955
956956 if (alsa.mmap) {
957957
958 snd_pcm_avail_update(pcmp);
959
958960 if ((err = snd_pcm_mmap_begin(pcmp, &areas, &offset, &alsa_frames)) < 0) {
959961 LOG_WARN("error from mmap_begin: %s", snd_strerror(err));
960962 break;
961963 }
962964
963965 out_frames = (frames_t)alsa_frames;
966
967 // temp for debugging mmap issues
968 if ((areas[0].first + offset * areas[0].step) % 8 != 0) {
969 LOG_ERROR("Error: mmap offset not multiple of 8!");
970 }
964971 }
965972
966973 // perform crossfade buffer copying here as we do not know the actual out_frames value until here