lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:	Mon, 26 Oct 2015 09:51:57 -0400
From:	Lyude <cpaul@...hat.com>
To:	Dmitry Torokhov <dmitry.torokhov@...il.com>
Cc:	David Herrmann <dh.herrmann@...il.com>,
	linux-kernel <linux-kernel@...r.kernel.org>,
	linux-input@...r.kernel.org, linux-api@...r.kernel.org,
	Andrew Morton <akpm@...ux-foundation.org>,
	Mauro Carvalho Chehab <mchehab@....samsung.com>,
	Greg KH <gregkh@...uxfoundation.org>,
	Arnd Bergmann <arnd@...db.de>, Joe Perches <joe@...ches.com>,
	Jiri Slaby <jslaby@...e.com>,
	Vishnu Patekar <vishnupatekar0510@...il.com>,
	Sebastian Ott <sebott@...ux.vnet.ibm.com>,
	Benjamin Tissoires <benjamin.tissoires@...hat.com>,
	Hans de Goede <hdegoede@...hat.com>,
	linux-doc@...r.kernel.org
Subject: Re: [PATCH v6.2 1/1] Input: Add userio module

Hi! So, I'm guessing you want me to merge this with the patch I've got
right now and post the new version? (Just making sure since I'm a bit
new to this :)

On Sat, 2015-10-24 at 15:40 -0700, Dmitry Torokhov wrote:
> Hi Stephen,
> 
> On Fri, Oct 23, 2015 at 04:47:46PM -0400, cpaul@...hat.com wrote:
> > From: Stephen Chandler Paul <cpaul@...hat.com>
> > 
> > Debugging input devices, specifically laptop touchpads, can be
> > tricky
> > without having the physical device handy. Here we try to remedy
> > that
> > with userio. This module allows an application to connect to a
> > character
> > device provided by the kernel, and emulate any serio device. In
> > combination with userspace programs that can record PS/2 devices
> > and
> > replay them through the /dev/userio device, this allows developers
> > to
> > debug driver issues on the PS/2 level with devices simply by
> > requesting
> > a recording from the user experiencing the issue without having to
> > have
> > the physical hardware in front of them.
> > 
> > Signed-off-by: Stephen Chandler Paul <cpaul@...hat.com>
> > Reviewed-by: David Herrmann <dh.herrmann@...il.com>
> > ---
> > 				    Changes
> > * Remove the if (!userio) { return -1; } check that somehow got
> > left in.
> > 
> > Sorry this took so long! I was wondering why you hadn't replied
> > yet, only to
> > notice I only made this change on my own tree and never sent out a
> > response
> > patch. Oops.
> 
> Thank you for making all the changes.
> 
> > +
> > +static ssize_t userio_char_read(struct file *file, char __user
> > *user_buffer,
> > +				size_t count, loff_t *ppos)
> > +{
> > +	struct userio_device *userio = file->private_data;
> > +	int ret;
> > +	size_t nonwrap_len, copylen;
> > +	unsigned char buf[USERIO_BUFSIZE];
> > +	unsigned long flags;
> > +
> > +	if (!count)
> > +		return 0;
> 
> This is not quite right: read of size 0 should still check if there
> is
> data in the buffer and return -EAGAIN for non-blocking descriptors.
> 
> I cooked a patch (below) that should adjust the read behavior (_+ a
> coupe of formatting changes), please take a look.
> 
> Thanks!
> 
-- 
Cheers,
	Lyude

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ