Thread (5 messages) flat view 5 messages, 3 authors, 2015-07-17

Re: [PATCH] Input-polldev:Check poll_interval range while registering input device

From: Marcus Overhagen <hidden>
Date: 2015-07-17 20:29:15

Possibly related (same subject, not in this thread)

On Thu, Jul 16, 2015 at 7:57 PM, Anshul Garg [off-list ref] wrote:
+       if (dev->poll_interval > dev->poll_interval_max ||
+                       dev->poll_interval < dev->poll_interval_min) {
+               pr_err("Poll interval Range incorrect\n");
+               return -EINVAL;
+       }

        if (!dev->poll_interval)
                dev->poll_interval = 500;
So priviously, if poll_interval was 0 you got a sane default of 500,
and now you get -EINVAL.

Is this really useful and correct, and nobody using it is passing 0?

regards
Marcus
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help