aboutsummaryrefslogtreecommitdiff
path: root/drivers/message/i2o
AgeCommit message (Collapse)AuthorFilesLines
2010-08-07scsi/i2o: restore ioctl changesArnd Bergmann1-5/+16
This restores the changes from "scsi/i2o_block: cleanup ioctl handling", which accidentally got reverted. Origignal changelog: This fixes the ioctl function of the i2o_block driver, which has multiple problems: * The BLKI2OSRSTRAT and BLKI2OSWSTRAT commands always return -ENOTTY on success, where they should return 0. * Support for 32 bit compat is missing * The driver should use the .ioctl function and because .locked_ioctl is going away. The use of the big kernel lock remains for now, but gets made explictit in the ioctl function. Signed-off-by: Arnd Bergmann <[email protected]> Signed-off-by: Jens Axboe <[email protected]>
2010-08-07block: push down BKL into .open and .releaseArnd Bergmann1-0/+5
The open and release block_device_operations are currently called with the BKL held. In order to change that, we must first make sure that all drivers that currently rely on this have no regressions. This blindly pushes the BKL into all .open and .release operations for all block drivers to prepare for the next step. The drivers can subsequently replace the BKL with their own locks or remove it completely when it can be shown that it is not needed. The functions blkdev_get and blkdev_put are the only remaining users of the big kernel lock in the block layer, besides a few uses in the ioctl code, none of which need to serialize with blkdev_{get,put}. Most of these two functions is also under the protection of bdev->bd_mutex, including the actual calls to ->open and ->release, and the common code does not access any global data structures that need the BKL. Signed-off-by: Arnd Bergmann <[email protected]> Acked-by: Christoph Hellwig <[email protected]> Signed-off-by: Jens Axboe <[email protected]>
2010-08-07block: push down BKL into .locked_ioctlArnd Bergmann1-17/+5
As a preparation for the removal of the big kernel lock in the block layer, this removes the BKL from the common ioctl handling code, moving it into every single driver still using it. Signed-off-by: Arnd Bergmann <[email protected]> Acked-by: Christoph Hellwig <[email protected]> Signed-off-by: Jens Axboe <[email protected]>
2010-08-07scsi/i2o_block: cleanup ioctl handlingArnd Bergmann1-6/+18
This fixes the ioctl function of the i2o_block driver, which has multiple problems: * The BLKI2OSRSTRAT and BLKI2OSWSTRAT commands always return -ENOTTY on success, where they should return 0. * Support for 32 bit compat is missing * The driver should use the .ioctl function and because .locked_ioctl is going away. The use of the big kernel lock remains for now, but gets made explictit in the ioctl function. Signed-off-by: Arnd Bergmann <[email protected]> Signed-off-by: Jens Axboe <[email protected]>
2010-08-07block: remove wrappers for request type/flagsChristoph Hellwig1-1/+1
Remove all the trivial wrappers for the cmd_type and cmd_flags fields in struct requests. This allows much easier grepping for different request types instead of unwinding through macros. Signed-off-by: Christoph Hellwig <[email protected]> Signed-off-by: Jens Axboe <[email protected]>
2010-05-27drivers/message/i2o/i2o_config.c: use memdup_userJulia Lawall1-8/+3
Use memdup_user when user data is immediately copied into the allocated region. The semantic patch that makes this change is as follows: (http://coccinelle.lip6.fr/) // <smpl> @@ expression from,to,size,flag; position p; identifier l1,l2; @@ - to = \(kmalloc@p\|kzalloc@p\)(size,flag); + to = memdup_user(from,size); if ( - to==NULL + IS_ERR(to) || ...) { <+... when != goto l1; - -ENOMEM + PTR_ERR(to) ...+> } - if (copy_from_user(to, from, size) != 0) { - <+... when != goto l2; - -EFAULT - ...+> - } // </smpl> Signed-off-by: Julia Lawall <[email protected]> Signed-off-by: Andrew Morton <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
2010-04-26i2o: cleanup some exit pathsDan Carpenter1-10/+6
This is just a cleanup and doesn't change how the code works. The original code had a mix of returns and gotos so I changed everything to just return directly. Signed-off-by: Dan Carpenter <[email protected]> Reviewed-by: Christoph Lameter <[email protected]> Signed-off-by: Jiri Kosina <[email protected]>
2010-03-30include cleanup: Update gfp.h and slab.h includes to prepare for breaking ↵Tejun Heo5-0/+5
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 <[email protected]> Guess-its-ok-by: Christoph Lameter <[email protected]> Cc: Ingo Molnar <[email protected]> Cc: Lee Schermerhorn <[email protected]>
2010-03-08Merge branch 'for-next' into for-linusJiri Kosina1-1/+1
Conflicts: Documentation/filesystems/proc.txt arch/arm/mach-u300/include/mach/debug-macro.S drivers/net/qlge/qlge_ethtool.c drivers/net/qlge/qlge_main.c drivers/net/typhoon.c
2010-03-02Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-next-2.6Linus Torvalds1-8/+3
* git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-next-2.6: (1341 commits) virtio_net: remove forgotten assignment be2net: fix tx completion polling sis190: fix cable detect via link status poll net: fix protocol sk_buff field bridge: Fix build error when IGMP_SNOOPING is not enabled bnx2x: Tx barriers and locks scm: Only support SCM_RIGHTS on unix domain sockets. vhost-net: restart tx poll on sk_sndbuf full vhost: fix get_user_pages_fast error handling vhost: initialize log eventfd context pointer vhost: logging thinko fix wireless: convert to use netdev_for_each_mc_addr ethtool: do not set some flags, if others failed ipoib: returned back addrlen check for mc addresses netlink: Adding inode field to /proc/net/netlink axnet_cs: add new id bridge: Make IGMP snooping depend upon BRIDGE. bridge: Add multicast count/interval sysfs entries bridge: Add hash elasticity/max sysfs entries bridge: Add multicast_snooping sysfs toggle ... Trivial conflicts in Documentation/feature-removal-schedule.txt
2010-02-26block: Consolidate phys_segment and hw_segment limitsMartin K. Petersen1-2/+1
Except for SCSI no device drivers distinguish between physical and hardware segment limits. Consolidate the two into a single segment limit. Signed-off-by: Martin K. Petersen <[email protected]> Signed-off-by: Jens Axboe <[email protected]>
2010-02-26block: Rename blk_queue_max_sectors to blk_queue_max_hw_sectorsMartin K. Petersen1-1/+1
The block layer calling convention is blk_queue_<limit name>. blk_queue_max_sectors predates this practice, leading to some confusion. Rename the function to appropriately reflect that its intended use is to set max_hw_sectors. Also introduce a temporary wrapper for backwards compability. This can be removed after the merge window is closed. Signed-off-by: Martin K. Petersen <[email protected]> Signed-off-by: Jens Axboe <[email protected]>
2010-02-05tree-wide: fix typos "ammount" -> "amount"Uwe Kleine-König1-1/+1
Signed-off-by: Uwe Kleine-König <[email protected]> Signed-off-by: Jiri Kosina <[email protected]>
2010-01-23Merge branch 'master' of ↵David S. Miller1-7/+6
master.kernel.org:/pub/scm/linux/kernel/git/davem/net-2.6
2010-01-07drivers/message/i2o/i2o_proc.c: use %pM to show MAC addressH Hartley Sweeten1-8/+3
Use the %pM kernel extension to display the MAC address. Signed-off-by: H Hartley Sweeten <[email protected]> Signed-off-by: David S. Miller <[email protected]>
2010-01-04i2o: propogate the BKL down into the ioctl methodAlan Cox1-7/+6
Nobody seems to want to own I2O patches so sending this one directly. Signed-off-by: Alan Cox <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
2009-12-04tree-wide: fix assorted typos all over the placeAndré Goddard Rosa2-3/+3
That is "success", "unknown", "through", "performance", "[re|un]mapping" , "access", "default", "reasonable", "[con]currently", "temperature" , "channel", "[un]used", "application", "example","hierarchy", "therefore" , "[over|under]flow", "contiguous", "threshold", "enough" and others. Signed-off-by: André Goddard Rosa <[email protected]> Signed-off-by: Jiri Kosina <[email protected]>
2009-09-22const: make block_device_operations constAlexey Dobriyan1-1/+1
Signed-off-by: Alexey Dobriyan <[email protected]> Signed-off-by: Andrew Morton <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
2009-05-22block: Do away with the notion of hardsect_sizeMartin K. Petersen1-2/+3
Until now we have had a 1:1 mapping between storage device physical block size and the logical block sized used when addressing the device. With SATA 4KB drives coming out that will no longer be the case. The sector size will be 4KB but the logical block size will remain 512-bytes. Hence we need to distinguish between the physical block size and the logical ditto. This patch renames hardsect_size to logical_block_size. Signed-off-by: Martin K. Petersen <[email protected]> Signed-off-by: Jens Axboe <[email protected]>
2009-05-11block: implement and enforce request peek/start/fetchTejun Heo1-3/+3
Till now block layer allowed two separate modes of request execution. A request is always acquired from the request queue via elv_next_request(). After that, drivers are free to either dequeue it or process it without dequeueing. Dequeue allows elv_next_request() to return the next request so that multiple requests can be in flight. Executing requests without dequeueing has its merits mostly in allowing drivers for simpler devices which can't do sg to deal with segments only without considering request boundary. However, the benefit this brings is dubious and declining while the cost of the API ambiguity is increasing. Segment based drivers are usually for very old or limited devices and as converting to dequeueing model isn't difficult, it doesn't justify the API overhead it puts on block layer and its more modern users. Previous patches converted all block low level drivers to dequeueing model. This patch completes the API transition by... * renaming elv_next_request() to blk_peek_request() * renaming blkdev_dequeue_request() to blk_start_request() * adding blk_fetch_request() which is combination of peek and start * disallowing completion of queued (not started) requests * applying new API to all LLDs Renamings are for consistency and to break out of tree code so that it's apparent that out of tree drivers need updating. [ Impact: block request issue API cleanup, no functional change ] Signed-off-by: Tejun Heo <[email protected]> Cc: Rusty Russell <[email protected]> Cc: James Bottomley <[email protected]> Cc: Mike Miller <[email protected]> Cc: unsik Kim <[email protected]> Cc: Paul Clements <[email protected]> Cc: Tim Waugh <[email protected]> Cc: Geert Uytterhoeven <[email protected]> Cc: David S. Miller <[email protected]> Cc: Laurent Vivier <[email protected]> Cc: Jeff Garzik <[email protected]> Cc: Jeremy Fitzhardinge <[email protected]> Cc: Grant Likely <[email protected]> Cc: Adrian McMenamin <[email protected]> Cc: Stephen Rothwell <[email protected]> Cc: Bartlomiej Zolnierkiewicz <[email protected]> Cc: Borislav Petkov <[email protected]> Cc: Sergei Shtylyov <[email protected]> Cc: Alex Dubov <[email protected]> Cc: Pierre Ossman <[email protected]> Cc: David Woodhouse <[email protected]> Cc: Markus Lidel <[email protected]> Cc: Stefan Weinhuber <[email protected]> Cc: Martin Schwidefsky <[email protected]> Cc: Pete Zaitcev <[email protected]> Cc: FUJITA Tomonori <[email protected]> Signed-off-by: Jens Axboe <[email protected]>
2009-05-11block: convert to dequeueing model (easy ones)Tejun Heo1-2/+4
plat-omap/mailbox, floppy, viocd, mspro_block, i2o_block and mmc/card/queue are already pretty close to dequeueing model and can be converted with simple changes. Convert them. While at it, * xen-blkfront: !fs check moved downwards to share dequeue call with normal path. * mspro_block: __blk_end_request(..., blk_rq_cur_byte()) converted to __blk_end_request_cur() * mmc/card/queue: loop of __blk_end_request() converted to __blk_end_request_all() [ Impact: dequeue in-flight request ] Signed-off-by: Tejun Heo <[email protected]> Cc: Rusty Russell <[email protected]> Cc: Jeremy Fitzhardinge <[email protected]> Cc: Stephen Rothwell <[email protected]> Cc: Alex Dubov <[email protected]> Cc: Markus Lidel <[email protected]> Cc: Pierre Ossman <[email protected]> Signed-off-by: Jens Axboe <[email protected]>
2009-05-11block: blk_rq_[cur_]_{sectors|bytes}() usage cleanupTejun Heo1-12/+4
With the previous changes, the followings are now guaranteed for all requests in any valid state. * blk_rq_sectors() == blk_rq_bytes() >> 9 * blk_rq_cur_sectors() == blk_rq_cur_bytes() >> 9 Clean up accessor usages. Notable changes are * nbd,i2o_block: end_all used instead of explicit byte count * scsi_lib: unnecessary conditional on request type removed [ Impact: cleanup ] Signed-off-by: Tejun Heo <[email protected]> Cc: Paul Clements <[email protected]> Cc: Pete Zaitcev <[email protected]> Cc: Alex Dubov <[email protected]> Cc: Markus Lidel <[email protected]> Cc: David Woodhouse <[email protected]> Cc: James Bottomley <[email protected]> Cc: Boaz Harrosh <[email protected]> Signed-off-by: Jens Axboe <[email protected]>
2009-05-11block: cleanup rq->data_len usagesTejun Heo1-1/+1
With recent unification of fields, it's now guaranteed that rq->data_len always equals blk_rq_bytes(). Convert all non-IDE direct users to accessors. IDE will be converted in a separate patch. Boaz: spotted incorrect data_len/resid_len conversion in osd. [ Impact: convert direct rq->data_len usages to blk_rq_bytes() ] Signed-off-by: Tejun Heo <[email protected]> Acked-by: Sergei Shtylyov <[email protected]> Cc: Pete Zaitcev <[email protected]> Cc: Eric Moore <[email protected]> Cc: Markus Lidel <[email protected]> Cc: Darrick J. Wong <[email protected]> Cc: James Bottomley <[email protected]> Cc: Eric Moore <[email protected]> Cc: Boaz Harrosh <[email protected]> Cc: FUJITA Tomonori <[email protected]> Signed-off-by: Jens Axboe <[email protected]>
2009-05-11block: convert to pos and nr_sectors accessorsTejun Heo1-9/+11
With recent cleanups, there is no place where low level driver directly manipulates request fields. This means that the 'hard' request fields always equal the !hard fields. Convert all rq->sectors, nr_sectors and current_nr_sectors references to accessors. While at it, drop superflous blk_rq_pos() < 0 test in swim.c. [ Impact: use pos and nr_sectors accessors ] Signed-off-by: Tejun Heo <[email protected]> Acked-by: Geert Uytterhoeven <[email protected]> Tested-by: Grant Likely <[email protected]> Acked-by: Grant Likely <[email protected]> Tested-by: Adrian McMenamin <[email protected]> Acked-by: Adrian McMenamin <[email protected]> Acked-by: Mike Miller <[email protected]> Cc: James Bottomley <[email protected]> Cc: Bartlomiej Zolnierkiewicz <[email protected]> Cc: Borislav Petkov <[email protected]> Cc: Sergei Shtylyov <[email protected]> Cc: Eric Moore <[email protected]> Cc: Alan Stern <[email protected]> Cc: FUJITA Tomonori <[email protected]> Cc: Pete Zaitcev <[email protected]> Cc: Stephen Rothwell <[email protected]> Cc: Paul Clements <[email protected]> Cc: Tim Waugh <[email protected]> Cc: Jeff Garzik <[email protected]> Cc: Jeremy Fitzhardinge <[email protected]> Cc: Alex Dubov <[email protected]> Cc: David Woodhouse <[email protected]> Cc: Martin Schwidefsky <[email protected]> Cc: Dario Ballabio <[email protected]> Cc: David S. Miller <[email protected]> Cc: Rusty Russell <[email protected]> Cc: unsik Kim <[email protected]> Cc: Laurent Vivier <[email protected]> Signed-off-by: Jens Axboe <[email protected]>
2009-05-11block: implement blk_rq_pos/[cur_]sectors() and convert obvious onesTejun Heo1-1/+1
Implement accessors - blk_rq_pos(), blk_rq_sectors() and blk_rq_cur_sectors() which return rq->hard_sector, rq->hard_nr_sectors and rq->hard_cur_sectors respectively and convert direct references of the said fields to the accessors. This is in preparation of request data length handling cleanup. Geert : suggested adding const to struct request * parameter to accessors Sergei : spotted error in patch description [ Impact: cleanup ] Signed-off-by: Tejun Heo <[email protected]> Acked-by: Geert Uytterhoeven <[email protected]> Acked-by: Stephen Rothwell <[email protected]> Tested-by: Grant Likely <[email protected]> Acked-by: Grant Likely <[email protected]> Ackec-by: Sergei Shtylyov <[email protected]> Cc: Bartlomiej Zolnierkiewicz <[email protected]> Cc: Borislav Petkov <[email protected]> Cc: James Bottomley <[email protected]> Signed-off-by: Jens Axboe <[email protected]>
2009-04-28block: replace end_request() with [__]blk_end_request_cur()Tejun Heo1-1/+1
end_request() has been kept around for backward compatibility; however, it's about time for it to go away. * There aren't too many users left. * Its use of @updtodate is pretty confusing. * In some cases, newer code ends up using mixture of end_request() and [__]blk_end_request[_all](), which is way too confusing. So, add [__]blk_end_request_cur() and replace end_request() with it. Most conversions are straightforward. Noteworthy ones are... * paride/pcd: next_request() updated to take 0/-errno instead of 1/0. * paride/pf: pf_end_request() and next_request() updated to take 0/-errno instead of 1/0. * xd: xd_readwrite() updated to return 0/-errno instead of 1/0. * mtd/mtd_blkdevs: blktrans_discard_request() updated to return 0/-errno instead of 1/0. Unnecessary local variable res initialization removed from mtd_blktrans_thread(). [ Impact: cleanup ] Signed-off-by: Tejun Heo <[email protected]> Acked-by: Joerg Dorchain <[email protected]> Acked-by: Geert Uytterhoeven <[email protected]> Acked-by: Grant Likely <[email protected]> Acked-by: Laurent Vivier <[email protected]> Cc: Tim Waugh <[email protected]> Cc: Stephen Rothwell <[email protected]> Cc: Paul Mackerras <[email protected]> Cc: Jeremy Fitzhardinge <[email protected]> Cc: Markus Lidel <[email protected]> Cc: David Woodhouse <[email protected]> Cc: Pete Zaitcev <[email protected]> Cc: unsik Kim <[email protected]>
2009-04-07dma-mapping: replace all DMA_32BIT_MASK macro with DMA_BIT_MASK(32)Yang Hongyang2-2/+2
Replace all DMA_32BIT_MASK macro with DMA_BIT_MASK(32) Signed-off-by: Yang Hongyang<[email protected]> Signed-off-by: Andrew Morton <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
2009-04-07dma-mapping: replace all DMA_64BIT_MASK macro with DMA_BIT_MASK(64)Yang Hongyang2-3/+3
Replace all DMA_64BIT_MASK macro with DMA_BIT_MASK(64) Signed-off-by: Yang Hongyang<[email protected]> Signed-off-by: Andrew Morton <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
2009-03-31proc 2/2: remove struct proc_dir_entry::ownerAlexey Dobriyan1-2/+0
Setting ->owner as done currently (pde->owner = THIS_MODULE) is racy as correctly noted at bug #12454. Someone can lookup entry with NULL ->owner, thus not pinning enything, and release it later resulting in module refcount underflow. We can keep ->owner and supply it at registration time like ->proc_fops and ->data. But this leaves ->owner as easy-manipulative field (just one C assignment) and somebody will forget to unpin previous/pin current module when switching ->owner. ->proc_fops is declared as "const" which should give some thoughts. ->read_proc/->write_proc were just fixed to not require ->owner for protection. rmmod'ed directories will be empty and return "." and ".." -- no harm. And directories with tricky enough readdir and lookup shouldn't be modular. We definitely don't want such modular code. Removing ->owner will also make PDE smaller. So, let's nuke it. Kudos to Jeff Layton for reminding about this, let's say, oversight. http://bugzilla.kernel.org/show_bug.cgi?id=12454 Signed-off-by: Alexey Dobriyan <[email protected]>
2009-01-07Merge branch 'for-linus' of ↵Linus Torvalds1-1/+1
git://git.kernel.org/pub/scm/linux/kernel/git/jikos/trivial * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jikos/trivial: (24 commits) trivial: chack -> check typo fix in main Makefile trivial: Add a space (and a comma) to a printk in 8250 driver trivial: Fix misspelling of "firmware" in docs for ncr53c8xx/sym53c8xx trivial: Fix misspelling of "firmware" in powerpc Makefile trivial: Fix misspelling of "firmware" in usb.c trivial: Fix misspelling of "firmware" in qla1280.c trivial: Fix misspelling of "firmware" in a100u2w.c trivial: Fix misspelling of "firmware" in megaraid.c trivial: Fix misspelling of "firmware" in ql4_mbx.c trivial: Fix misspelling of "firmware" in acpi_memhotplug.c trivial: Fix misspelling of "firmware" in ipw2100.c trivial: Fix misspelling of "firmware" in atmel.c trivial: Fix misspelled firmware in Kconfig trivial: fix an -> a typos in documentation and comments trivial: fix then -> than typos in comments and documentation trivial: update Jesper Juhl CREDITS entry with new email trivial: fix singal -> signal typo trivial: Fix incorrect use of "loose" in event.c trivial: printk: fix indentation of new_text_line declaration trivial: rtc-stk17ta8: fix sparse warning ...
2009-01-06Merge git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/driver-core-2.6Linus Torvalds3-6/+6
* git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/driver-core-2.6: (60 commits) uio: make uio_info's name and version const UIO: Documentation for UIO ioport info handling UIO: Pass information about ioports to userspace (V2) UIO: uio_pdrv_genirq: allow custom irq_flags UIO: use pci_ioremap_bar() in drivers/uio arm: struct device - replace bus_id with dev_name(), dev_set_name() libata: struct device - replace bus_id with dev_name(), dev_set_name() avr: struct device - replace bus_id with dev_name(), dev_set_name() block: struct device - replace bus_id with dev_name(), dev_set_name() chris: struct device - replace bus_id with dev_name(), dev_set_name() dmi: struct device - replace bus_id with dev_name(), dev_set_name() gadget: struct device - replace bus_id with dev_name(), dev_set_name() gpio: struct device - replace bus_id with dev_name(), dev_set_name() gpu: struct device - replace bus_id with dev_name(), dev_set_name() hwmon: struct device - replace bus_id with dev_name(), dev_set_name() i2o: struct device - replace bus_id with dev_name(), dev_set_name() IA64: struct device - replace bus_id with dev_name(), dev_set_name() i7300_idle: struct device - replace bus_id with dev_name(), dev_set_name() infiniband: struct device - replace bus_id with dev_name(), dev_set_name() ISDN: struct device - replace bus_id with dev_name(), dev_set_name() ...
2009-01-06i2o: remove extraneous kernel-docRandy Dunlap2-3/+0
Remove excess kernel-doc function parameter notation from i2o/. Warning(drivers/message/i2o/iop.c:64): Excess function parameter 'msg' description in 'i2o_msg_get_wait' Warning(drivers/message/i2o/device.c:62): Excess function parameter 'drv' description in 'i2o_device_claim' Warning(drivers/message/i2o/device.c:95): Excess function parameter 'drv' description in 'i2o_device_claim_release' Warning(drivers/message/i2o/driver.c:186): Excess function parameter 'msg' description in 'i2o_driver_dispatch' Signed-off-by: Randy Dunlap <[email protected]> Signed-off-by: Andrew Morton <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
2009-01-06i2o: struct device - replace bus_id with dev_name(), dev_set_name()Kay Sievers3-6/+6
Signed-off-by: Kay Sievers <[email protected]> Signed-off-by: Greg Kroah-Hartman <[email protected]>
2009-01-06trivial: fix then -> than typos in comments and documentationFrederik Schwarzer1-1/+1
- (better, more, bigger ...) then -> (...) than Signed-off-by: Frederik Schwarzer <[email protected]> Signed-off-by: Jiri Kosina <[email protected]>
2009-01-05i2o: Update my addressAlan Cox4-4/+4
Signed-off-by: Alan Cox <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
2008-12-05drivers/message/i2o/iop.c: cleanup kerneldocQinghuang Feng1-1/+0
no argument named @msg in i2o_msg_get_wait(), remove it. Signed-off-by: Qinghuang Feng <[email protected]> Signed-off-by: Alan Cox <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
2008-12-05Fix incorrect use of loose in i2o_block.cNick Andrew1-1/+1
Fix incorrect use of loose in i2o_block.c It should be 'lose', not 'loose'. Signed-off-by: Nick Andrew <[email protected]> Signed-off-by: Alan Cox <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
2008-11-01saner FASYNC handling on file closeAl Viro1-16/+5
As it is, all instances of ->release() for files that have ->fasync() need to remember to evict file from fasync lists; forgetting that creates a hole and we actually have a bunch that *does* forget. So let's keep our lives simple - let __fput() check FASYNC in file->f_flags and call ->fasync() there if it's been set. And lose that crap in ->release() instances - leaving it there is still valid, but we don't have to bother anymore. Signed-off-by: Al Viro <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
2008-10-30i2o: fix kernel-doc warningsRandy Dunlap1-6/+6
Fixup i2o kernel-doc warnings: Warning(linux-next-20081022//drivers/message/i2o/i2o_block.c:579): No description found for parameter 'bdev' Warning(linux-next-20081022//drivers/message/i2o/i2o_block.c:579): No description found for parameter 'mode' Warning(linux-next-20081022//drivers/message/i2o/i2o_block.c:608): No description found for parameter 'disk' Warning(linux-next-20081022//drivers/message/i2o/i2o_block.c:608): No description found for parameter 'mode' Warning(linux-next-20081022//drivers/message/i2o/i2o_block.c:657): No description found for parameter 'bdev' Warning(linux-next-20081022//drivers/message/i2o/i2o_block.c:657): No description found for parameter 'mode' Signed-off-by: Randy Dunlap <[email protected]> Cc: Al Viro <[email protected]> Signed-off-by: Andrew Morton <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
2008-10-21[PATCH] switch i2oAl Viro1-9/+8
Signed-off-by: Al Viro <[email protected]>
2008-10-21[PATCH] beginning of methods conversionAl Viro1-3/+3
To keep the size of changesets sane we split the switch by drivers; to keep the damn thing bisectable we do the following: 1) rename the affected methods, add ones with correct prototypes, make (few) callers handle both. That's this changeset. 2) for each driver convert to new methods. *ALL* drivers are converted in this series. 3) kill the old (renamed) methods. Note that it _is_ a flagday; all in-tree drivers are converted and by the end of this series no trace of old methods remain. The only reason why we do that this way is to keep the damn thing bisectable and allow per-driver debugging if anything goes wrong. New methods: open(bdev, mode) release(disk, mode) ioctl(bdev, mode, cmd, arg) /* Called without BKL */ compat_ioctl(bdev, mode, cmd, arg) locked_ioctl(bdev, mode, cmd, arg) /* Called with BKL, legacy */ Signed-off-by: Al Viro <[email protected]>
2008-10-16i2o: Fix 32/64bit DMA lockingAlan Cox7-31/+339
The I2O ioctls assume 32bits. In itself that is fine as they are old cards and nobody uses 64bit. However on LKML it was noted this assumption is also made for allocated memory and is unsafe on 64bit systems. Fixing this is a mess. It turns out there is tons of crap buried in a header file that does racy 32/64bit filtering on the masks. So we: - Verify all callers of the racy code can sleep (i2o_dma_[re]alloc) - Move the code into a new i2o/memory.c file - Remove the gfp_mask argument so nobody can try and misuse the function - Wrap a mutex around the problem area (a single mutex is easy to do and none of this is performance relevant) - Switch the remaining problem kmalloc holdout to use i2o_dma_alloc Cc: Markus Lidel <[email protected]> Cc: Vasily Averin <[email protected]> Signed-off-by: Andrew Morton <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
2008-07-24I2O: handle sysfs_create_link() failuresWang Chen1-12/+42
Compile warning: ignoring return value of `sysfs_create_link', declared with attribute warn_unused_result. If sysfs_create_link failed, take care of the return value and do some error handle after the failure. Since sysfs_remove_link() will check whether a link exists, when removing the link in error path, we don't need to care whether a link was created. Signed-off-by: Wang Chen <[email protected]> Cc: Markus Lidel <[email protected]> Cc: Jens Axboe <[email protected]> Signed-off-by: Andrew Morton <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
2008-07-02i2o: fasync BKL pushdownJonathan Corbet1-4/+6
This driver appears to really need the BKL to protect open_files. Signed-off-by: Jonathan Corbet <[email protected]>
2008-06-20message-i2o-i2o_config: BKL pushdownArnd Bergmann1-0/+2
Signed-off-by: Arnd Bergmann <[email protected]>
2008-04-29Remove duplicated unlikely() in IS_ERR()Hirofumi Nakagawa1-1/+1
Some drivers have duplicated unlikely() macros. IS_ERR() already has unlikely() in itself. This patch cleans up such pointless code. Signed-off-by: Hirofumi Nakagawa <[email protected]> Acked-by: David S. Miller <[email protected]> Acked-by: Jeff Garzik <[email protected]> Cc: Paul Clements <[email protected]> Cc: Richard Purdie <[email protected]> Cc: Alessandro Zummo <[email protected]> Cc: David Brownell <[email protected]> Cc: James Bottomley <[email protected]> Cc: Michael Halcrow <[email protected]> Cc: Anton Altaparmakov <[email protected]> Cc: Al Viro <[email protected]> Cc: Carsten Otte <[email protected]> Cc: Patrick McHardy <[email protected]> Cc: Paul Mundt <[email protected]> Cc: Jaroslav Kysela <[email protected]> Cc: Takashi Iwai <[email protected]> Acked-by: Mike Frysinger <[email protected]> Signed-off-by: Andrew Morton <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
2008-04-29drivers: use non-racy method for proc entries creation (2)Denis V. Lunev1-4/+2
Use proc_create()/proc_create_data() to make sure that ->proc_fops and ->data be setup before gluing PDE to main tree. Signed-off-by: Denis V. Lunev <[email protected]> Cc: Greg Kroah-Hartman <[email protected]> Cc: Alexey Dobriyan <[email protected]> Cc: "Eric W. Biederman" <[email protected]> Cc: Peter Osterlund <[email protected]> Cc: Bartlomiej Zolnierkiewicz <[email protected]> Cc: Dmitry Torokhov <[email protected]> Cc: Neil Brown <[email protected]> Cc: Mauro Carvalho Chehab <[email protected]> Cc: Bjorn Helgaas <[email protected]> Cc: Alessandro Zummo <[email protected]> Signed-off-by: Andrew Morton <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
2008-02-03drivers/message/: Spelling fixesJoe Perches1-1/+1
Signed-off-by: Joe Perches <[email protected]> Signed-off-by: Adrian Bunk <[email protected]>
2008-01-28blk_end_request: changing i2o_block (take 4)Kiyoshi Ueda1-12/+8
This patch converts i2o_block to use blk_end_request interfaces. Related 'uptodate' arguments are converted to 'error'. As a result, the interface of internal function, i2o_block_end_request(), is changed. Cc: Markus Lidel <[email protected]> Signed-off-by: Kiyoshi Ueda <[email protected]> Signed-off-by: Jun'ichi Nomura <[email protected]> Signed-off-by: Jens Axboe <[email protected]>
2008-01-23[SCSI] replace sizeof sense_buffer with SCSI_SENSE_BUFFERSIZEFUJITA Tomonori1-1/+1
This replaces sizeof sense_buffer with SCSI_SENSE_BUFFERSIZE in several LLDs. It's a preparation for the future changes to remove sense_buffer array in scsi_cmnd structure. Signed-off-by: FUJITA Tomonori <[email protected]> Signed-off-by: James Bottomley <[email protected]>