aboutsummaryrefslogtreecommitdiff
path: root/drivers/staging/otus
AgeCommit message (Collapse)Author
2010-04-05staging/otus: include slab.h from usbdrv.hTejun Heo
drivers/staging/otus/usbdrv.h users use slab facilities. Include linux/slab.h from usbdrv.h. Signed-off-by: Tejun Heo <tj@kernel.org>
2010-03-30include cleanup: Update gfp.h and slab.h includes to prepare for breaking ↵Tejun Heo
implicit slab.h inclusion from percpu.h percpu.h is included by sched.h and module.h and thus ends up being included when building most .c files. percpu.h includes slab.h which in turn includes gfp.h making everything defined by the two files universally available and complicating inclusion dependencies. percpu.h -> slab.h dependency is about to be removed. Prepare for this change by updating users of gfp and slab facilities include those headers directly instead of assuming availability. As this conversion needs to touch large number of source files, the following script is used as the basis of conversion. http://userweb.kernel.org/~tj/misc/slabh-sweep.py The script does the followings. * Scan files for gfp and slab usages and update includes such that only the necessary includes are there. ie. if only gfp is used, gfp.h, if slab is used, slab.h. * When the script inserts a new include, it looks at the include blocks and try to put the new include such that its order conforms to its surrounding. It's put in the include block which contains core kernel includes, in the same order that the rest are ordered - alphabetical, Christmas tree, rev-Xmas-tree or at the end if there doesn't seem to be any matching order. * If the script can't find a place to put a new include (mostly because the file doesn't have fitting include block), it prints out an error message indicating which .h file needs to be added to the file. The conversion was done in the following steps. 1. The initial automatic conversion of all .c files updated slightly over 4000 files, deleting around 700 includes and adding ~480 gfp.h and ~3000 slab.h inclusions. The script emitted errors for ~400 files. 2. Each error was manually checked. Some didn't need the inclusion, some needed manual addition while adding it to implementation .h or embedding .c file was more appropriate for others. This step added inclusions to around 150 files. 3. The script was run again and the output was compared to the edits from #2 to make sure no file was left behind. 4. Several build tests were done and a couple of problems were fixed. e.g. lib/decompress_*.c used malloc/free() wrappers around slab APIs requiring slab.h to be added manually. 5. The script was run on all .h files but without automatically editing them as sprinkling gfp.h and slab.h inclusions around .h files could easily lead to inclusion dependency hell. Most gfp.h inclusion directives were ignored as stuff from gfp.h was usually wildly available and often used in preprocessor macros. Each slab.h inclusion directive was examined and added manually as necessary. 6. percpu.h was updated not to include slab.h. 7. Build test were done on the following configurations and failures were fixed. CONFIG_GCOV_KERNEL was turned off for all tests (as my distributed build env didn't work with gcov compiles) and a few more options had to be turned off depending on archs to make things build (like ipr on powerpc/64 which failed due to missing writeq). * x86 and x86_64 UP and SMP allmodconfig and a custom test config. * powerpc and powerpc64 SMP allmodconfig * sparc and sparc64 SMP allmodconfig * ia64 SMP allmodconfig * s390 SMP allmodconfig * alpha SMP allmodconfig * um on x86_64 SMP allmodconfig 8. percpu.h modifications were reverted so that it could be applied as a separate patch and serve as bisection point. Given the fact that I had only a couple of failures from tests on step 6, I'm fairly confident about the coverage of this conversion patch. If there is a breakage, it's likely to be something in one of the arch headers which should be easily discoverable easily on most builds of the specific arch. Signed-off-by: Tejun Heo <tj@kernel.org> Guess-its-ok-by: Christoph Lameter <cl@linux-foundation.org> Cc: Ingo Molnar <mingo@redhat.com> Cc: Lee Schermerhorn <Lee.Schermerhorn@hp.com>
2010-03-03Staging: otus: fix memory leakd binderman
Fix memory leak in drivers/staging/otus Signed-off-by: David Binderman <dcb314@hotmail.com>
2010-03-03staging: fix typos "enalbe" -> "enable"Uwe Kleine-König
This patch was generated by git grep -E -l 'enalbe' drivers/staging | xargs -r perl -p -i -e 's/enalbe/enable/g' Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-03-03Staging: otus: fix assignment makes integer from pointer without a cast warningsJeff Mahoney
This patch fixes some %x pointer printing to %p. It also uses the skb_tail_pointer and skb_mac_header macros for accessing thos members. Signed-off-by: Jeff Mahoney <jeffm@suse.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-03-03staging: make USB device id constantNémeth Márton
The id_table field of the struct usb_device_id is constant in <linux/usb.h> so it is worth to make the initialization data also constant. The semantic match that finds this kind of pattern is as follows: (http://coccinelle.lip6.fr/) // <smpl> @r@ disable decl_init,const_decl_init; identifier I1, I2, x; @@ struct I1 { ... const struct I2 *x; ... }; @s@ identifier r.I1, y; identifier r.x, E; @@ struct I1 y = { .x = E, }; @c@ identifier r.I2; identifier s.E; @@ const struct I2 E[] = ... ; @depends on !c@ identifier r.I2; identifier s.E; @@ + const struct I2 E[] = ...; // </smpl> Signed-off-by: Németh Márton <nm127@freemail.hu> Cc: Julia Lawall <julia@diku.dk> Cc: cocci@diku.dk Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-03-03Staging: otus: zfTkipInit(): increment another pointerSimon Horman
Increment the pointer rather than its value. These appear to be logic errors. Thanks to Dan Carpenter for the first hunk of this change. Cc: Dan Carpenter <error27@gmail.com> Signed-off-by: Simon Horman <horms@verge.net.au> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-03-03Staging: otus: Fix ZM_SEQ_DEBUG macro for no-debug casehorms@vergenet.net
tcp_seq is only initialised in case where ZM_ENABLE_PERFORMANCE_EVALUATION is defined. So move the call to ZM_SEQ_DEBUG() and the decleration of tcp_seq in there too. This allows ZM_SEQ_DEBUG() to be removed from the non-ZM_ENABLE_PERFORMANCE_EVALUATION case in the header file. This resolves several compile warnings for the non-ZM_ENABLE_PERFORMANCE_EVALUATION case. However, the ZM_ENABLE_PERFORMANCE_EVALUATION case seems to be completely broken. $ gcc (Debian 4.4.2-8) 4.4.2 Copyright (C) 2009 Free Software Foundation, Inc. This is free software; see the source for copying conditions. There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. $ make ... drivers/staging/otus/80211core/cagg.c: In function 'zfAggRxEnabled': drivers/staging/otus/80211core/cagg.c:1872: warning: left-hand operand of comma expression has no effect drivers/staging/otus/80211core/cagg.c:1872: warning: left-hand operand of comma expression has no effect drivers/staging/otus/80211core/cagg.c:1872: warning: statement with no effect ... Signed-off-by: Simon Horman <horms@verge.net.au> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-03-03Staging: otus: remove unused constantshorms@vergenet.net
Signed-off-by: Simon Horman <horms@verge.net.au> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-03-03Staging: otus: remove unused variableshorms@vergenet.net
Signed-off-by: Simon Horman <horms@verge.net.au> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-03-03Staging: otus: dont mix declarations and codehorms@vergenet.net
$ gcc (Debian 4.4.2-8) 4.4.2 Copyright (C) 2009 Free Software Foundation, Inc. This is free software; see the source for copying conditions. There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. $ make ... drivers/staging/otus/ioctl.c: In function 'usbdrv_wpa_ioctl': drivers/staging/otus/ioctl.c:2253: warning: ISO C90 forbids mixed declarations and code ... Signed-off-by: Simon Horman <horms@verge.net.au> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-03-03Staging: otus: Add select WEXT_PRIV to Kconfig to prevent build failurePeter Huewe
Without WEXT_PRIV set the driver fails to build due to unknown fields in the iw_handler_def struct. Those fields are enclosed in WEXT_PRIV conditionals in the prototype of iw_handler_def in include/net/iw_handler.h Signed-off-by: Peter Huewe <peterhuewe@gmx.de> Acked-by: Simon Horman <horms@verge.net.au> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-03-03Staging: otus: 80211core: Fix &&/|| confusionRoel Kluin
This always evaluates to true. Signed-off-by: Roel Kluin <roel.kluin@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-03-03Staging: otus: off by one in usbdrvwext_siwessid()Dan Carpenter
A 33 char ESSID is too long and it could cause a buffer overflow a couple lines below when we put a NULL terminator on the end. Signed-off-by: Dan Carpenter <error27@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-03-03Staging: otus: Fix branch in zfProtRspSim()Roel Kluin
This semicolon is misplaced. Signed-off-by: Roel Kluin <roel.kluin@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-03-03Staging: otus: fix some sparse warningsThiago Farina
*apdbg.c: use NULL pointer instead of 0 interger. Also make two functions private. Signed-off-by: Thiago Farina <tfransosi@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2009-12-11Staging: fix assorted typos all over the placeAndré Goddard Rosa
Signed-off-by: André Goddard Rosa <andre.goddard@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2009-12-11Staging: otus : checkpatch.pl cleanup for some more .c filesMithlesh Thukral
Second lot of checkpatch.pl error and warning fixes for .c files of otus driver in staging tree. (Externs would be removed in a seperate patch) Signed-off-by: Mithlesh Thukral <mithlesh@linsyssoft.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2009-12-11Staging: otus : checkpatch.pl cleanup for .c filesMithlesh Thukral
First patch for checkpatch.pl error and warning fixes for .c files of otus driver in staging tree. Signed-off-by: Mithlesh Thukral <mithlesh@linsyssoft.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2009-12-11Staging: otus : checkpatch.pl cleanup for header filesMithlesh Thukral
Fix for checkpatch.pl errors and warnings in header files of otus driver. (There is a typedef which still remains. Plan to clean it up in next set of patches) Signed-off-by: Mithlesh Thukral <mithlesh@linsyssoft.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2009-12-04tree-wide: fix misspelling of "definition" in commentsAdam Buchbinder
"Definition" is misspelled "defintion" in several comments; this patch fixes them. No code changes. Signed-off-by: Adam Buchbinder <adam.buchbinder@gmail.com> Signed-off-by: Jiri Kosina <jkosina@suse.cz>
2009-10-30Staging: wireless drivers Kconfig changeGreg Kroah-Hartman
Change the wireless drivers to depend on CONFIG_WLAN instead of CONFIG_WLAN_80211 which is going away soon. Cc: John W. Linville <linville@tuxdriver.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2009-09-15staging: Make some structures staticJulia Lawall
This was done using a semantic patch (http://coccinelle.lip6.fr/) that checks that the declaration is not inside a function definition, that the defined variable is not exported using EXPORTED_SYMBOL, etc, and that the defined variable does not occur in any other file. If these conditions hold, static is added before the declaration. Signed-off-by: Julia Lawall <julia@diku.dk> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2009-09-15Staging: otus: includecheck fix: drivers/staging/otus/usbdrv.hJaswinder Singh Rajput
fix the following 'make includecheck' warning: drivers/staging/otus/usbdrv.h: linux/usb.h is included more than once. Signed-off-by: Jaswinder Singh Rajput <jaswinderrajput@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2009-09-15Staging: fix typos "man[ae]g?ment" -> "management"Uwe Kleine-König
This patch was generated by running git grep -E -l 'man[ae]g?ment' drivers/staging | xargs -r perl -p -i -e 's/\bman[ae]g?ment\b/management/g' Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de> Cc: Jiri Kosina <jkosina@suse.cz> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2009-09-15Staging: otus: Drop an unnecessary NULL testJulia Lawall
Apparently, the NULL test is not necessary at this point. The semantic patch that finds this problem is as follows: (http://www.emn.fr/x-info/coccinelle/) // <smpl> @@ type T; expression E; identifier i,fld; statement S; @@ - T i = E->fld; + T i; ... when != E when != i if (E == NULL) S + i = E->fld; // </smpl> Signed-off-by: Julia Lawall <julia@diku.dk> Acked-by: Jiri Slaby <jirislaby@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2009-09-15Staging: otus: remove dependency on WIRELESS_EXT versionAlexander Beregalov
As the driver is in mainline now we can remove such dependency. WIRELESS_EXT is 22 now and it is always defined. Signed-off-by: Alexander Beregalov <a.beregalov@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2009-09-15Staging: otus: Fix warnings in staging/otus/ioctl.cPranith Kumar
This fixes a number of warnings in the otus driver. Signed-off-by: D Pranith Kumar <bobby.prani@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2009-07-05net: use NETDEV_TX_OK instead of 0 in ndo_start_xmit() functionsPatrick McHardy
This patch is the result of an automatic spatch transformation to convert all ndo_start_xmit() return values of 0 to NETDEV_TX_OK. Some occurences are missed by the automatic conversion, those will be handled in a seperate patch. Signed-off-by: Patrick McHardy <kaber@trash.net> Signed-off-by: David S. Miller <davem@davemloft.net>
2009-07-05net: remove NET_RX_BAD and NET_RX_CN* definesFlorian Westphal
almost no users in the tree; and the few that use them treat them like NET_RX_DROP. Signed-off-by: Florian Westphal <fw@strlen.de> Signed-off-by: David S. Miller <davem@davemloft.net>
2009-06-19Staging: otus: beyond ARRAY_SIZE of wd->ap.wds.encryModeRoel Kluin
Do not go beyond ARRAY_SIZE of wd->ap.wds.encryMode Signed-off-by: Roel Kluin <roel.kluin@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2009-06-19Staging: otus: 80211core/ccmd.c: Fix Coding StyleDragoslav Zaric
Signed-off-by: Dragoslav Zaric <dragoslav.zaric.kd@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2009-04-17otus/zdusb.c: additional USB idnetifierDaniele Napolitano
Provide support for WN111v2 USB 802.11n adapter. Signed-off-by: Daniele Napolitano <dnax88@gmail.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2009-04-17Staging: otus: convert to netdev_opsAlexander Beregalov
Signed-off-by: Alexander Beregalov <a.beregalov@gmail.com> Acked-by: David S. Miller <davem@davemloft.net> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2009-04-05Merge git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/staging-2.6Linus Torvalds
* git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/staging-2.6: (714 commits) Staging: sxg: slicoss: Specify the license for Sahara SXG and Slicoss drivers Staging: serqt_usb: fix build due to proc tty changes Staging: serqt_usb: fix checkpatch errors Staging: serqt_usb: add TODO file Staging: serqt_usb: Lindent the code Staging: add USB serial Quatech driver staging: document that the wifi staging drivers a bit better Staging: echo cleanup Staging: BUG to BUG_ON changes Staging: remove some pointless conditionals before kfree_skb() Staging: line6: fix build error, select SND_RAWMIDI Staging: line6: fix checkpatch errors in variax.c Staging: line6: fix checkpatch errors in toneport.c Staging: line6: fix checkpatch errors in pcm.c Staging: line6: fix checkpatch errors in midibuf.c Staging: line6: fix checkpatch errors in midi.c Staging: line6: fix checkpatch errors in dumprequest.c Staging: line6: fix checkpatch errors in driver.c Staging: line6: fix checkpatch errors in audio.c Staging: line6: fix checkpatch errors in pod.c ...
2009-04-03staging: document that the wifi staging drivers a bit betterGreg Kroah-Hartman
The Linux wireless developers don't want to hear anything about the staging wireless drivers, for a wide range of miopic reasons. The following patch, based on a patch from Johannes Berg, tries to document this issue a bit better. Cc: Johannes Berg <johannes@sipsolutions.net> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2009-04-03Staging: BUG to BUG_ON changesStoyan Gaydarov
Signed-off-by: Stoyan Gaydarov <stoyboyker@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2009-04-03Staging: remove some pointless conditionals before kfree_skb()Wei Yongjun
Remove some pointless conditionals before kfree_skb(). Signed-off-by: Wei Yongjun <yjwei@cn.fujitsu.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2009-04-03Staging: otus: remove old irqreturn_t definitionAlexander Beregalov
See commit bedd30d9 (genirq: make irqreturn_t an enum) Signed-off-by: Alexander Beregalov <a.beregalov@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2009-04-03Staging: otus: 80211core/amsdu.c: Fix Coding StyleDragoslav Zaric
Signed-off-by: Dragoslav Zaric <dragoslav.zaric.kd@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2009-04-03Staging: otus: ioctl.c: Fix Coding StyleDragoslav Zaric
I run make on ioctl.c file and I got two warnings: drivers/staging/otus/ioctl.c: In function ¡usbdrv_wpa_ioctl¢: drivers/staging/otus/ioctl.c:2269: warning: ISO C90 forbids mixed declarations and code drivers/staging/otus/ioctl.c: In function ¡usbdrv_ioctl¢: drivers/staging/otus/ioctl.c:2448: warning: ISO C90 forbids mixed declarations and code From: Dragoslav Zaric <dragoslav.zaric.kd@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2009-04-03Staging: otus: fix mixed declarationsRandy Dunlap
Fix otus ISO C90 warnings: drivers/staging/otus/80211core/cmmsta.c:740: warning: ISO C90 forbids mixed declarations and code drivers/staging/otus/80211core/coid.c:219: warning: ISO C90 forbids mixed declarations and code drivers/staging/otus/80211core/coid.c:1437: warning: ISO C90 forbids mixed declarations and code drivers/staging/otus/hal/hprw.c:33: warning: ISO C90 forbids mixed declarations and code drivers/staging/otus/hal/hprw.c:53: warning: ISO C90 forbids mixed declarations and code drivers/staging/otus/hal/hprw.c:82: warning: ISO C90 forbids mixed declarations and code drivers/staging/otus/hal/hprw.c:163: warning: ISO C90 forbids mixed declarations and code drivers/staging/otus/hal/hprw.c:219: warning: ISO C90 forbids mixed declarations and code drivers/staging/otus/hal/hprw.c:831: warning: ISO C90 forbids mixed declarations and code drivers/staging/otus/hal/hprw.c:896: warning: ISO C90 forbids mixed declarations and code drivers/staging/otus/hal/hpmain.c:332: warning: ISO C90 forbids mixed declarations and code drivers/staging/otus/hal/hpmain.c:1329: warning: ISO C90 forbids mixed declarations and code drivers/staging/otus/hal/hpmain.c:1565: warning: ISO C90 forbids mixed declarations and code drivers/staging/otus/hal/hpmain.c:1606: warning: ISO C90 forbids mixed declarations and code drivers/staging/otus/hal/hpmain.c:1923: warning: ISO C90 forbids mixed declarations and code drivers/staging/otus/hal/hpmain.c:1997: warning: ISO C90 forbids mixed declarations and code drivers/staging/otus/hal/hpmain.c:2264: warning: ISO C90 forbids mixed declarations and code drivers/staging/otus/hal/hpmain.c:2296: warning: ISO C90 forbids mixed declarations and code drivers/staging/otus/hal/hpmain.c:2330: warning: ISO C90 forbids mixed declarations and code drivers/staging/otus/hal/hpmain.c:2350: warning: ISO C90 forbids mixed declarations and code drivers/staging/otus/hal/hpmain.c:2387: warning: ISO C90 forbids mixed declarations and code drivers/staging/otus/hal/hpmain.c:2425: warning: ISO C90 forbids mixed declarations and code drivers/staging/otus/hal/hpmain.c:4223: warning: ISO C90 forbids mixed declarations and code drivers/staging/otus/hal/hpmain.c:4283: warning: ISO C90 forbids mixed declarations and code drivers/staging/otus/hal/hpmain.c:4314: warning: ISO C90 forbids mixed declarations and code drivers/staging/otus/hal/hpmain.c:4380: warning: ISO C90 forbids mixed declarations and code drivers/staging/otus/hal/hpmain.c:4425: warning: ISO C90 forbids mixed declarations and code drivers/staging/otus/hal/hpmain.c:4531: warning: ISO C90 forbids mixed declarations and code drivers/staging/otus/hal/hpmain.c:4539: warning: ISO C90 forbids mixed declarations and code drivers/staging/otus/hal/hpusb.c:69: warning: ISO C90 forbids mixed declarations and code drivers/staging/otus/hal/hpusb.c:334: warning: ISO C90 forbids mixed declarations and code drivers/staging/otus/hal/hpusb.c:580: warning: ISO C90 forbids mixed declarations and code drivers/staging/otus/hal/hpreg.c:1774: warning: ISO C90 forbids mixed declarations and code drivers/staging/otus/hal/hpreg.c:2478: warning: ISO C90 forbids mixed declarations and code drivers/staging/otus/hal/hpani.c:61: warning: ISO C90 forbids mixed declarations and code drivers/staging/otus/hal/hpani.c:80: warning: ISO C90 forbids mixed declarations and code drivers/staging/otus/hal/hpani.c:145: warning: ISO C90 forbids mixed declarations and code drivers/staging/otus/hal/hpani.c:352: warning: ISO C90 forbids mixed declarations and code drivers/staging/otus/hal/hpani.c:393: warning: ISO C90 forbids mixed declarations and code drivers/staging/otus/hal/hpani.c:472: warning: ISO C90 forbids mixed declarations and code drivers/staging/otus/hal/hpani.c:517: warning: ISO C90 forbids mixed declarations and code drivers/staging/otus/hal/hpani.c:592: warning: ISO C90 forbids mixed declarations and code drivers/staging/otus/hal/hpani.c:633: warning: ISO C90 forbids mixed declarations and code Signed-off-by: Randy Dunlap <randy.dunlap@oracle.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2009-04-03Staging: otus: use USB API functions rather than constantsJulia Lawall
This set of patches introduces calls to the following set of functions: usb_endpoint_dir_in(epd) usb_endpoint_dir_out(epd) usb_endpoint_is_bulk_in(epd) usb_endpoint_is_bulk_out(epd) usb_endpoint_is_int_in(epd) usb_endpoint_is_int_out(epd) usb_endpoint_num(epd) usb_endpoint_type(epd) usb_endpoint_xfer_bulk(epd) usb_endpoint_xfer_control(epd) usb_endpoint_xfer_int(epd) usb_endpoint_xfer_isoc(epd) In some cases, introducing one of these functions is not possible, and it just replaces an explicit integer value by one of the following constants: USB_ENDPOINT_XFER_BULK USB_ENDPOINT_XFER_CONTROL USB_ENDPOINT_XFER_INT USB_ENDPOINT_XFER_ISOC An extract of the semantic patch that makes these changes is as follows: (http://www.emn.fr/x-info/coccinelle/) // <smpl> @r1@ struct usb_endpoint_descriptor *epd; @@ - ((epd->bmAttributes & \(USB_ENDPOINT_XFERTYPE_MASK\|3\)) == - \(USB_ENDPOINT_XFER_CONTROL\|0\)) + usb_endpoint_xfer_control(epd) @r5@ struct usb_endpoint_descriptor *epd; @@ - ((epd->bEndpointAddress & \(USB_ENDPOINT_DIR_MASK\|0x80\)) == - \(USB_DIR_IN\|0x80\)) + usb_endpoint_dir_in(epd) @inc@ @@ #include <linux/usb.h> @depends on !inc && (r1||r5)@ @@ + #include <linux/usb.h> #include <linux/usb/...> // </smpl> Signed-off-by: Julia Lawall <julia@diku.dk> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2009-04-03Staging: otus: logical/bit and confusionRoel Kluin
fix logical/bit and confusion Signed-off-by: Roel Kluin <roel.kluin@gmail.com> Cc: <lrodriguez@atheros.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2009-03-30trivial: Fix misspelling of firmwareNick Andrew
Fix misspelling of firmware. Signed-off-by: Nick Andrew <nick@nick-andrew.net> Signed-off-by: Jiri Kosina <jkosina@suse.cz>
2009-01-07staging: __FUNCTION__ is gcc-specific, use __func__Harvey Harrison
Signed-off-by: Harvey Harrison <harvey.harrison@gmail.com> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2009-01-06Staging: otus: remove dependence on kernel versionAlexander Beregalov
Dependence on kernel version is not needed anymore if we are in mainline now. Signed-off-by: Alexander Beregalov <a.beregalov@gmail.com> Cc: <lrodriguez@atheros.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2009-01-06Staging: otus: fix urb callback function typeGreg Kroah-Hartman
The #ifdef for version checking is wrong, and we no longer pass the struct pt_regs to the urb callback functions. This patch fixes this error. Cc: Luis Rodriguez <Luis.Rodriguez@Atheros.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2009-01-06Staging: otus: fix name clashJ.R. Mauro
Make p80211wext_handler_def in the otus driver static. It's not used outside this file and causes name clashes if it's visible. Signed-off by: J.R. Mauro <jrm8005@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2009-01-06Staging: otus: fix netdev->priv usageGreg Kroah-Hartman
Now that netdev->priv is gone, fix things up properly in the otus driver to use ml_priv as it should have always been doing. Cc: Luis R. Rodriguez <lrodriguez@atheros.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>