can_read_data function should by called only from IO read callback. can_read_data feeds ringbuffer but don't call process_input() if there is pending result. So it is enought to just call process_input cause any pending data are already present in ring_buffer. This fix blocking read in unit/test-hfp exposed by previous patch. --- src/shared/hfp.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/shared/hfp.c b/src/shared/hfp.c index ea6494d..90e17c7 100644 --- a/src/shared/hfp.c +++ b/src/shared/hfp.c @@ -762,7 +762,7 @@ bool hfp_gw_send_result(struct hfp_gw *hfp, enum hfp_result result) */ if (hfp->result_pending) { hfp->result_pending = false; - can_read_data(hfp->io, hfp); + process_input(hfp); } return true; -- 1.9.1 -- To unsubscribe from this list: send the line "unsubscribe linux-bluetooth" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html