From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S932406AbcAHUd4 (ORCPT ); Fri, 8 Jan 2016 15:33:56 -0500 Received: from lxorguk.ukuu.org.uk ([81.2.110.251]:60694 "EHLO lxorguk.ukuu.org.uk" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1755752AbcAHUdy (ORCPT ); Fri, 8 Jan 2016 15:33:54 -0500 Date: Fri, 8 Jan 2016 20:33:40 +0000 From: One Thousand Gnomes To: Aniroop Mathur Cc: David Herrmann , Aniroop Mathur , Dmitry Torokhov , "open list:HID CORE LAYER" , linux-kernel Subject: Re: [PATCH] Input: evdev - add ioctl cmd EVIOCGBUFSIZE to get buffer size Message-ID: <20160108203340.2b728a41@lxorguk.ukuu.org.uk> In-Reply-To: References: <1452266588-3139-1-git-send-email-a.mathur@samsung.com> <20160108201346.6a6694e2@lxorguk.ukuu.org.uk> Organization: Intel Corporation X-Mailer: Claws Mail 3.12.0 (GTK+ 2.24.29; x86_64-redhat-linux-gnu) MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Sat, 9 Jan 2016 01:50:42 +0530 Aniroop Mathur wrote: > On Sat, Jan 9, 2016 at 1:43 AM, One Thousand Gnomes > wrote: > >> During system boot up, user space buf size is fixed, it cannot be > >> resized later and we cannot choose by hit&trial. > >> struct input_event* mBuffer = new input_event[mBuf]; > > > > Who says that won't change ? Imagine a future case where plugging in a > > device changes the buffer size ? > > > > Ofcourse buffer size can be changed but it will also change the value of bufsize > variable and accordingly user space client should also change its buf size. If its hot plugged why shouldn't that value change dynamically after you've asked ? Alan