<html>
  <head>
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8">
  </head>
  <body text="#000000" bgcolor="#FFFFFF">
    <div class="moz-cite-prefix">On 07.07.2018 12:07, Georg Chini wrote:<br>
    </div>
    <blockquote type="cite"
      cite="mid:99543cdd-86f7-37f9-c5fc-ab8a57fb0da3@chini.tk">
      <meta http-equiv="Content-Type" content="text/html; charset=utf-8">
      <div class="moz-cite-prefix">On 06.07.2018 08:43, Sathish
        Narasimman wrote:<br>
      </div>
      <blockquote type="cite"
cite="mid:CAOVXEJJfyEYE8Ex1H4f-xy1uRCH6jVsJcLRv8xjRqQ+rzSXvkA@mail.gmail.com">
        <div dir="ltr">Hi Luiz,
          <div><br>
          </div>
          <div>Yes, I am doing the polling. I an not changing that part
            of the code. In which it is default in which NBS also uses.</div>
          <div><br>
          </div>
          <div>Thanks,</div>
          <div>Sathish N</div>
        </div>
      </blockquote>
      <br>
      The current code does not poll for POLLOUT in all situations,<br>
      see comment in the code. You should check if POLLOUT is<br>
      really set in pollfd->events. Actually a situation like you<br>
      describe is "normal" but should not impact sound quality,<br>
      again see comment in the code. You could try if it helps to<br>
      remove the "if (blocks_to_write > 0)" and set writable=false<br>
      unconditionally.<br>
    </blockquote>
    <br>
    In fact, in all situations where you are woken up by POLLOUT but you<br>
    do not have a block to write, POLLOUT will not be polled on the next<br>
    iteration to prevent unnecessary looping. Therefore removing the if<br>
    condition may not help much. Does the write_block_size equal the<br>
    read_block_size? In theory, different sizes are supported, but I
    think<br>
    it could cause issues.<br>
    <br>
    <blockquote type="cite"
      cite="mid:99543cdd-86f7-37f9-c5fc-ab8a57fb0da3@chini.tk"> <br>
      <blockquote type="cite"
cite="mid:CAOVXEJJfyEYE8Ex1H4f-xy1uRCH6jVsJcLRv8xjRqQ+rzSXvkA@mail.gmail.com">
        <div class="gmail_extra"><br>
          <div class="gmail_quote">On Wed, Jul 4, 2018 at 9:29 PM, Luiz
            Augusto von Dentz <span dir="ltr"><<a
                href="mailto:luiz.dentz@gmail.com" target="_blank"
                moz-do-not-send="true">luiz.dentz@gmail.com</a>></span>
            wrote:<br>
            <blockquote class="gmail_quote" style="margin:0 0 0
              .8ex;border-left:1px #ccc solid;padding-left:1ex">Hi
              Sathish,<br>
              <span class=""><br>
                On Mon, Jul 2, 2018 at 4:25 PM, Sathish Narasimman <<a
                  href="mailto:nsathish41@gmail.com"
                  moz-do-not-send="true">nsathish41@gmail.com</a>>
                wrote:<br>
                > Hi,<br>
                ><br>
                > I am trying to make WBS with PulseAudio. I am
                almost successful in<br>
                > establishing the connection and making a WBS
                traffic.<br>
                ><br>
                > But out of 10 attempts or sometimes the TX packets
                are not sent due to<br>
                > POLLOUT is not reflected in the pollfd<br>
                >                 /* Test if the stream is writable
                */<br>
                >                 if (pollfd->revents &
                POLLOUT)<br>
                >                     writable = true;<br>
                <br>
              </span>Are you sure you are polling with POLLOUT?<br>
              <span class=""><br>
                > I would like to know what causes the stream as not
                writable.<br>
                > What are the connecting modules to resolve this?<br>
                > This happening only with WBS as NBS works good
                without any problem.<br>
                ><br>
                ><br>
                > Thanks,<br>
                > Sathish N<br>
                ></span></blockquote>
          </div>
        </div>
      </blockquote>
    </blockquote>
    <br>
  </body>
</html>