Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1299065
| Path | csiph.com!eternal-september.org!feeder.eternal-september.org!aioe.org!bofh.it!news.nic.it!robomod |
|---|---|
| From | Aniroop Mathur <aniroop.mathur@gmail.com> |
| Newsgroups | linux.kernel |
| Subject | Re: [PATCH] Input: evdev: avoid storing newest SYN_REPORT when dropping all events |
| Date | Tue, 29 Dec 2015 19:10:02 +0100 |
| Message-ID | <qL6SC-405-9@gated-at.bofh.it> (permalink) |
| References | <qJjKh-2gc-7@gated-at.bofh.it> <qKPI5-Ek-5@gated-at.bofh.it> |
| Dkim-Signature | v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type; bh=PjI16DUP2MbgVHBkaRpqkMRz9wNqL0cmRyQayR6zIdc=; b=D/SIYgPjLWxd19BlEhWmT5KgyRhPnQzL9R0dn1hEi0ArIE3B7sfoIzYMisZ2P+ZHrU ep1XW81BbEVQvkZTC1AoGH3gEZ8Uz/xEVz7P9bD7SlCwLFgymmtl4phFGcHbggxGqsMf BnNabk58a/vHdP0Aho2n+FBI9rX/BAwKquhs9UrsL42ClD9jfp1VhDuUuzQSUyonrVe7 N71Qk0iCD5ewgzbzRMQhl0Dcw3jHkwSJ7/hXlopjC+nFHYT+tLaT8PtJnhy5yxTdQTVl VkB8611V69dYUSYqC0Ls6mJTOt221Gd9J+n0YCLHq8ZS7dzPTlynpaomdO6n7KKAkufL IAdQ== |
| MIME-Version | 1.0 |
| X-Received | by 10.202.60.195 with SMTP id j186mr35382198oia.70.1451412145614; Tue, 29 Dec 2015 10:02:25 -0800 (PST) |
| Content-Type | text/plain; charset=UTF-8 |
| Sender | robomod@news.nic.it |
| List-ID | <linux-kernel.vger.kernel.org> |
| X-Mailing-List | linux-kernel@vger.kernel.org |
| Approved | robomod@news.nic.it |
| Lines | 54 |
| Organization | linux.* mail to news gateway |
| X-Original-Cc | Aniroop Mathur <a.mathur@samsung.com>, "linux-input@vger.kernel.org" <linux-input@vger.kernel.org>, lkml <linux-kernel@vger.kernel.org> |
| X-Original-Date | Tue, 29 Dec 2015 23:32:25 +0530 |
| X-Original-Message-ID | <CADYu308-H5A9RZPP=Daxbde2FXZjbWFiJXRzOSoKOmg4qUEy+Q@mail.gmail.com> |
| X-Original-References | <1450985148-804-1-git-send-email-a.mathur@samsung.com> <CAKdAkRR0aiziybrsDnvNwC7qCY7vg3K4UHaWfwkZ9oX7hguQOQ@mail.gmail.com> |
| X-Original-Sender | linux-kernel-owner@vger.kernel.org |
| Xref | csiph.com linux.kernel:1299065 |
Show key headers only | View raw
Hello Mr. Torokhov, On Tue, Dec 29, 2015 at 5:11 AM, Dmitry Torokhov <dmitry.torokhov@gmail.com> wrote: > Hi Aniroop, > > On Thu, Dec 24, 2015 at 11:25 AM, Aniroop Mathur <a.mathur@samsung.com> wrote: >> The newest event can be SYN_REPORT in case of dropping all old events when >> buffer is full, but as now there is no device data available to read so >> lets drop SYN_REPORT as well and store only SYN_DROPPED. >> > > We can not drop the SYN_REPORT event in this case as userspace needs > it to determine if the events that are coming after SYN_DROPPED are > part of a full packet or if they belong to a partial packet. From > Documentation/input/event-codes.txt: > > * SYN_DROPPED: > - Used to indicate buffer overrun in the evdev client's event queue. > Client should ignore all events up to and including next SYN_REPORT > event and query the device (using EVIOCG* ioctls) to obtain its > current state. > Okay I see. In case of buffer overrun, how about handling the partial packet case in evdev handler itself and free evdev client from handling it ? Normally, evdev buffer contain only full packets. But in case of dropping events, buffer would contain a partial packet almost all times and hence evdev client would have to handle the case of partial packet and as documentation says, client will ignore the events until new packet starts. So as a new protocol, after buffer overrun occurs, evdev handler can ignore the events until SYN_REPORT occurs and then start storing events. This way buffer will contain full packet as always and reading would be simplified for evdev clients. Accordingly, document can also be updated. Please let me know your opinion about it. Thanks and Regards, Aniroop Mathur > Thanks. > > -- > Dmitry -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
Back to linux.kernel | Previous | Next — Previous in thread | Find similar | Unroll thread
[PATCH] Input: evdev: avoid storing newest SYN_REPORT when dropping all events Aniroop Mathur <a.mathur@samsung.com> - 2015-12-24 20:30 +0100
Re: [PATCH] Input: evdev: avoid storing newest SYN_REPORT when dropping all events Dmitry Torokhov <dmitry.torokhov@gmail.com> - 2015-12-29 00:50 +0100
Re: [PATCH] Input: evdev: avoid storing newest SYN_REPORT when dropping all events Aniroop Mathur <aniroop.mathur@gmail.com> - 2015-12-29 19:10 +0100
csiph-web