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]
Message-Id: <C143A796-AFAA-4422-A60D-E462173BDC81@linaro.org>
Date:	Sun, 29 Nov 2015 17:19:30 +0800
From:	Pingbo Wen <pingbo.wen@...aro.org>
To:	Arnd Bergmann <arnd@...db.de>
Cc:	Pingbo Wen <pingbo.wen@...aro.org>, y2038@...ts.linaro.org,
	dmitry.torokhov@...il.com, aksgarg1989@...il.com,
	linux-input@...r.kernel.org, linux-kernel@...r.kernel.org,
	linux-api@...r.kernel.org
Subject: Re: [PATCH 2/3] input: evdev: add new ioctl EVIOCSIFTYPE / EVIOCGIFTYPE


> 在 2015年11月28日,00:59,Arnd Bergmann <arnd@...db.de> 写道:
> 
> On Friday 27 November 2015 18:00:31 WEN Pingbo wrote:
>> This patch depends on 'introduce new evdev interface'.
>> 
>> Userspace cat set / get evdev interface type via the two ioctl
>> commands. And default interface type is EV_IF_LEGACY, so the old binary
>> will work normal with new kernel. Maybe we should change this default
>> option to encourage people to move to new interface.
>> 
>> And since all events are stored as input_value in evdev, there are no
>> need to flush evdev_client's buffer if we change clk_type and if_type.
> 
> I would split out the change to evdev_set_clk_type into a separate patch.

Agreed.

> 
>> +	case EVIOCSIFTYPE:
>> +		if (get_user(if_type, ip))
>> +			return -EFAULT;
>> +
>> +		return evdev_set_if_type(client, if_type);
>> +	case EVIOCGIFTYPE:
>> +		return put_user(client->if_type, ip);
>> 	}
> 
> This look asymmetric: EVIOCSIFTYPE uses a EVDEV_* constant, while
> EVIOCGIFTYPE returns a EV_IF_* constant. Should those just
> be the same constants anyway?

Yes, thanks for pointing it out. I need add evdev_get_if_type() here.

Pingbo

--
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