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>] [day] [month] [year] [list]
Message-ID: <5aa163d00902242046h76c92411u1c4f999958c96de6@mail.gmail.com>
Date:	Tue, 24 Feb 2009 23:46:01 -0500
From:	Mike Murphy <mamurph@...clemson.edu>
To:	linux-kernel@...r.kernel.org, linux-input@...r.kernel.org,
	linux-usb@...r.kernel.org
Cc:	Greg KH <greg@...ah.com>, Oliver Neukum <oliver@...kum.org>,
	Frederic Weisbecker <fweisbec@...il.com>
Subject: [PATCH] (final rfc revision) input: xpad.c - Xbox 360 wireless 
	support and sysfs interface

Greetings,

Attached is what I hope to be the final RFC version of the Xbox driver
patch. I have made the following changes:

1. Removed check for CONFIG_SYSFS (rely on dummy implementations of
the sysfs subsystem whenever sysfs is not enabled). Thanks Frederic
Weisbecker.

2. Fixed backwards ordering of sscanf return check. Thanks Frederic
Weisbecker and Greg K-H.

3. Checked code and made style adjustments to pass automated checks in
scripts/checkpatch.pl. There is one reported error in the xpad.h file,
as the following multi-line preprocessor macros cannot be wrapped in a
do-while loop (lines 279-288):

#define XPAD_XBOX360_VENDOR_PROTOCOL(vend,pr) \
	.match_flags = USB_DEVICE_ID_MATCH_VENDOR | \
			USB_DEVICE_ID_MATCH_INT_INFO, \
	.idVendor = (vend), \
	.bInterfaceClass = USB_CLASS_VENDOR_SPEC, \
	.bInterfaceSubClass = 93, \
	.bInterfaceProtocol = (pr)
#define XPAD_XBOX360_VENDOR(vend) \
	{ XPAD_XBOX360_VENDOR_PROTOCOL(vend, 1) }, \
	{ XPAD_XBOX360_VENDOR_PROTOCOL(vend, 129) }

I have managed to remove all other errors and warnings, but I'm not
sure all the changes actually enhance code readability.

4. The current full version of the source for the header and C file,
as well as a userspace support file to prevent X11 picking the game
pad up as a pointer input, are available at:
http://cirg.cs.clemson.edu/~mamurph/pub/xpad/

I was _NOT_ able to test the driver with any wired Xbox or Xbox 360
input devices. It turns out that the devices we thought were wired
(Xbox 360 wireless controller connected via a cable) actually
communicate with the receiver wirelessly, and the USB cable merely
provides power. Thus, I would appreciate it if anyone with wired
hardware is able to test this driver and report any bugs.

Assuming there are no more substantive changes, I plan to sign off on
the "final" version of this revision sometime over the weekend. Prior
to this final version, I will make the following "minor" changes:

1. Change default modes on read-write sysfs attributes from 0666 to
0644. Userspace can handle assigning appropriate permissions while
operational. The modes are 0666 for now to permit easier testing.

2. Document the sysfs interface in
Documentation/ABI/testing/game_device-sysfs-interface (perhaps this
needs a better name?)

3. Update Documentation/input/xpad.txt

Thanks,
Mike
-- 
Mike Murphy
Ph.D. Candidate and NSF Graduate Research Fellow
Clemson University School of Computing
120 McAdams Hall
Clemson, SC 29634-0974 USA
Tel: +1 864.656.2838   Fax: +1 864.656.0145
http://cirg.cs.clemson.edu/~mamurph

View attachment "xpad-20080224.patch" of type "text/x-patch" (63731 bytes)

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ