Re: [PATCH v2 3/4] input: evdev: Indicate buffer overrun with SYN_DROPPED.
From: Jeffrey Brown <hidden>
Date: 2011-04-04 21:53:02
Also in:
lkml
From: Jeffrey Brown <hidden>
Date: 2011-04-04 21:53:02
Also in:
lkml
Hi Dmitry, On Mon, Apr 4, 2011 at 2:33 PM, Dmitry Torokhov [off-list ref] wrote:
On Fri, Apr 01, 2011 at 11:54:18PM -0700, Jeff Brown wrote:quoted
+ * When the client buffer is full, drain the buffer and enqueue a + * SYN_DROPPED event to let the client know that events were dropped + * and the last packet was incomplete. We then consume all remaining + * events from the dropped packet until the next packet begins.I do not think we (kernel) should be doing this. Clients should take care and not allow overruns but if they happen the pain should be on the client to restore the context. It has to query the device to get its current state and it can drop the events till next sync as well.
That's fine. We should document SYN_DROPPED and mention that the client should wait until after the next SYN_REPORT to get back in sync.
Therefore I intend to apply the patch in the form below.
Looks good to me. It's more like my original patch. Jeff. -- To unsubscribe from this list: send the line "unsubscribe linux-input" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html