- 30 Mar, 2010 1 commit
-
-
Tejun Heo authored
include cleanup: Update gfp.h and slab.h includes to prepare for breaking 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>
-
- 19 Mar, 2010 1 commit
-
-
Greg Kroah-Hartman authored
This fixes a sysfs lockdep warning in the infiniband code. Cc: Yinghai Lu <yinghai@kernel.org> Cc: Eric Biederman <ebiederm@xmission.com> Signed-off-by:
Greg Kroah-Hartman <gregkh@suse.de>
-
- 12 Mar, 2010 1 commit
-
-
Chien Tung authored
Commit 09124e19 ("RDMA/nes: Add support for KR device id 0x0110") took out too much code and broke CX4 link detection in back-to-back configuration. Put back the code that does the link check. Signed-off-by:
Chien Tung <chien.tin.tung@intel.com> Signed-off-by:
Roland Dreier <rolandd@cisco.com>
-
- 11 Mar, 2010 6 commits
-
-
Chien Tung authored
Clear the stall bit to drop any incoming packets while destroying NIC QP. This will prevent a chip resource leak. Signed-off-by:
Chien Tung <chien.tin.tung@intel.com> Signed-off-by:
Roland Dreier <rolandd@cisco.com>
-
Faisal Latif authored
Set assume_aligned_header bit in QP context as requested by hardware group. Signed-off-by:
Faisal Latif <faisal.latif@intel.com> Signed-off-by:
Roland Dreier <rolandd@cisco.com>
-
Steve Wise authored
During a hot-plug LLD removal event or an EEH error event, iw_cxgb3 must ensure that any/all threads that might be in a cxgb3 exported function must return from the function before iw_cxgb3 returns from its event processing. Do this by calling synchronize_net(). Signed-off-by:
Steve Wise <swise@opengridcomputing.com> Signed-off-by:
Roland Dreier <rolandd@cisco.com>
-
Steve Wise authored
When an iWARP device is unloaded, the ib_mad module logs errors. It should be ignoring iWARP devices on device removal just like it does on device add. Signed-off-by:
Steve Wise <swise@opengridcomputing.com> Acked-by:
Sean Hefty <sean.hefty@intel.com> Signed-off-by:
Roland Dreier <rolandd@cisco.com>
-
Or Gerlitz authored
Print the return code of ib_post_send() if it fails to make these debugging messages more useful. Signed-off-by:
Or Gerlitz <ogerlitz@voltaire.com> Signed-off-by:
Roland Dreier <rolandd@cisco.com>
-
Eli Cohen authored
The IPoIB UD QP reports send completions to priv->send_cq, which is usually left unarmed; it only gets armed when the number of outstanding send requests reaches the size of the TX queue. This arming is done only in the send path for the UD QP. However, when sending CM packets, the net queue may be stopped for the same reasons but no measures are taken to recover the UD path from a lockup. Consider this scenario: a host sends high rate of both CM and UD packets, with a TX queue length of N. If at some time the number of outstanding UD packets is more than N/2 and the overall outstanding packets is N-1, and CM sends a packet (making the number of outstanding sends equal N), the TX queue will be stopped. When all the CM packets complete, the number of outstanding packets will still be higher than N/2 so the TX queue will not be restarted. Fix this by calling ib_req_notify_cq() when the queue is stopped in the CM path. Signed-off-by:
Eli Cohen <eli@mellanox.co.il> Signed-off-by:
Roland Dreier <rolandd@cisco.com>
-
- 08 Mar, 2010 3 commits
-
-
Emese Revfy authored
Constify struct sysfs_ops. This is part of the ops structure constification effort started by Arjan van de Ven et al. Benefits of this constification: * prevents modification of data that is shared (referenced) by many other structure instances at runtime * detects/prevents accidental (but not intentional) modification attempts on archs that enforce read-only kernel data at runtime * potentially better optimized code as the compiler can assume that the const data cannot be changed * the compiler/linker move const data into .rodata and therefore exclude them from false sharing Signed-off-by:
Emese Revfy <re.emese@gmail.com> Acked-by:
David Teigland <teigland@redhat.com> Acked-by:
Matt Domsch <Matt_Domsch@dell.com> Acked-by:
Maciej Sosnowski <maciej.sosnowski@intel.com> Acked-by:
Hans J. Koch <hjk@linutronix.de> Acked-by:
Pekka Enberg <penberg@cs.helsinki.fi> Acked-by:
Jens Axboe <jens.axboe@oracle.com> Acked-by:
Stephen Hemminger <shemminger@vyatta.com> Signed-off-by:
Greg Kroah-Hartman <gregkh@suse.de>
-
Andi Kleen authored
Convert some drivers who export a single string as class attribute to the new class_attr_string functions. This removes redundant code all over. Signed-off-by:
Andi Kleen <ak@linux.intel.com> Signed-off-by:
Greg Kroah-Hartman <gregkh@suse.de>
-
Andi Kleen authored
Passing the attribute to the low level IO functions allows all kinds of cleanups, by sharing low level IO code without requiring an own function for every piece of data. Also drivers can extend the attributes with own data fields and use that in the low level function. This makes the class attributes the same as sysdev_class attributes and plain attributes. This will allow further cleanups in drivers. Full tree sweep converting all users. Signed-off-by:
Andi Kleen <ak@linux.intel.com> Signed-off-by:
Greg Kroah-Hartman <gregkh@suse.de>
-
- 06 Mar, 2010 1 commit
-
-
Akinobu Mita authored
Replace open-coded loop with for_each_set_bit(). Signed-off-by:
Akinobu Mita <akinobu.mita@gmail.com> Acked-by:
Roland Dreier <rolandd@cisco.com> Cc: Sean Hefty <sean.hefty@intel.com> Cc: Hal Rosenstock <hal.rosenstock@gmail.com> Signed-off-by:
Andrew Morton <akpm@linux-foundation.org> Signed-off-by:
Linus Torvalds <torvalds@linux-foundation.org>
-
- 03 Mar, 2010 2 commits
-
-
Al Viro authored
Signed-off-by:
Al Viro <viro@zeniv.linux.org.uk>
-
Jayamohan Kallickal authored
The iscsi_eh_target_reset has been modified to attempt target reset only. If it fails, then iscsi_eh_session_reset will be called. Signed-off-by:
Mike Christie <michaelc@cs.wisc.edu> Signed-off-by:
Jayamohan Kallickal <jayamohank@serverengines.com> Signed-off-by:
James Bottomley <James.Bottomley@suse.de>
-
- 02 Mar, 2010 2 commits
-
-
Roland Dreier authored
Instead of repeating the error unwinding steps in each place an error can be detected, use the common idiom of gotos into an error flow. Signed-off-by:
Roland Dreier <rolandd@cisco.com>
-
Bart Van Assche authored
We can reduce the number of IB interrupts from two interrupts per srp_queuecommand() call to one by using separate CQs for send and receive completions and processing send completions by polling every time a TX IU is allocated. Receive completion events still trigger an interrupt. Signed-off-by:
Bart Van Assche <bart.vanassche@gmail.com> Signed-off-by:
Roland Dreier <rolandd@cisco.com>
-
- 28 Feb, 2010 1 commit
-
-
Jiri Pirko authored
Apparently bogus mc address can break IPOIB multicast processing. Therefore returning the check for addrlen back until this is resolved in bonding (I don't see any other point from where mc address with non-dev->addr_len length can came from). Signed-off-by:
Jiri Pirko <jpirko@redhat.com> Signed-off-by:
David S. Miller <davem@davemloft.net>
-
- 26 Feb, 2010 1 commit
-
-
Jiri Pirko authored
Due to the loop complexicity in nes_nic.c, I'm using char* to copy mc addresses to it. Signed-off-by:
Jiri Pirko <jpirko@redhat.com> Signed-off-by:
David S. Miller <davem@davemloft.net>
-
- 25 Feb, 2010 2 commits
-
-
Chien Tung authored
Add support for KR device id 0x0110. While at it, cleanup nes_init_phy() by splitting it into nes_init_1g_phy() and nes_init_2025_phy(). Remove support for NES_PHY_TYPE_IRIS, which was used on an XFP board that was only manufactured in small quantities and given out for evals in even smaller quantities. Signed-off-by:
Chien Tung <chien.tin.tung@intel.com> Signed-off-by:
Roland Dreier <rolandd@cisco.com>
-
Roland Dreier authored
The anon_inodes interface has been split to allow creating a bare (non-installed) file pointer and also extended to allow specifying O_RDONLY in the flags. This makes it a suitable replacement for the private "infinibandeventfs" pseudo-filesystem used by uverbs, and this replacement saves a small chunk of boilerplate code. Signed-off-by:
Roland Dreier <rolandd@cisco.com>
-
- 24 Feb, 2010 19 commits
-
-
Eli Cohen authored
ib_ud_header_init() first clears header and then fills up the various fields. Later on, it tests header->immediate_present, which it has already cleared, so the condition is always false. Fix this by adding an immediate_present parameter and setting header->immediate_present as is done with grh_present. Also remove unused calculation of header_len. Signed-off-by:
Eli Cohen <eli@mellanox.co.il> Signed-off-by:
Roland Dreier <rolandd@cisco.com>
-
Steve Wise authored
If cxgb3 calls the iw_cxgb3 t3cclient remove function due to a device removal event, then the iwch device must be marked with CXIO_ERROR_FATAL since the device below us is going away. Otherwise, we can get stuck in a deadlock as RDMA ULPs try and deallocate objects (like MRs, QPs, etc). So always mark the device with CXIO_ERROR_FATAL when removing. Signed-off-by:
Steve Wise <swise@opengridcomputing.com> Signed-off-by:
Roland Dreier <rolandd@cisco.com>
-
Steve Wise authored
Only kernel mode CQs need the SW queue memory allocated. The SW queue for user mode CQs is allocated in userspace by libcxgb3. Signed-off-by:
Steve Wise <swise@opengridcomputing.com> Signed-off-by:
Roland Dreier <rolandd@cisco.com>
-
Steve Wise authored
Signed-off-by:
Steve Wise <swise@opengridcomputing.com> Signed-off-by:
Roland Dreier <rolandd@cisco.com>
-
Steve Wise authored
T3 hardware doorbell FIFO overflows can cause application stalls due to lost doorbell ring events. This has been seen when running large NP IMB alltoall MPI jobs. The T3 hardware supports an xon/xoff-type flow control mechanism to help avoid overflowing the HW doorbell FIFO. This patch uses these interrupts to disable RDMA QP doorbell rings when we near an overflow condition, and then turn them back on (and ring all the active QP doorbells) when when the doorbell FIFO empties out. In addition if an doorbell ring is dropped by the hardware, the code will now recover. Design: cxgb3: - enable these DB interrupts - in the interrupt handler, schedule work tasks to call the ULPs event handlers with the new events. - ring all the qset txqs when an overflow is detected. iw_cxgb3: - disable db ringing on all active qps when we get the DB_FULL event - enable db ringing on all active qps and ring all active dbs when we get the DB_EMPTY event - On DB_DROP event: - disable db rings in the event handler - delay-schedule a work task which rings and enables the dbs on all active qps. - in post_send and post_recv logic, don't ring the db if it's disabled. Signed-off-by:
Steve Wise <swise@opengridcomputing.com> Signed-off-by:
Roland Dreier <rolandd@cisco.com>
-
Alexander Chiang authored
As shown when 'let c_space_errors=1' is set in vim. Signed-off-by:
Alex Chiang <achiang@hp.com> Signed-off-by:
Roland Dreier <rolandd@cisco.com>
-
Alexander Chiang authored
Some large systems may support more than IB_UCM_MAX_DEVICES (currently 32). This change allows us to support more devices in a backwards-compatible manner. the first IB_UCM_MAX_DEVICES keep the same major/minor device numbers they've always had. If there are more than IB_UCM_MAX_DEVICES, then we dynamically request a new major device number (new minors start at 0). Signed-off-by:
Alex Chiang <achiang@hp.com> Signed-off-by:
Roland Dreier <rolandd@cisco.com>
-
Alexander Chiang authored
This change is not useful by itself, but sets us up for a future change that allows us to support more than IB_UCM_MAX_DEVICES. Signed-off-by:
Alex Chiang <achiang@hp.com> Signed-off-by:
Roland Dreier <rolandd@cisco.com>
-
Alexander Chiang authored
This change is not useful by itself, but sets us up for a future change that allows us to dynamically allocate device numbers in case we have more than IB_UCM_MAX_DEVICES in the system. Signed-off-by:
Alex Chiang <achiang@hp.com> Signed-off-by:
Roland Dreier <rolandd@cisco.com>
-
Alexander Chiang authored
Clean errors as shown when 'let c_space_errors=1' is set in vim. Signed-off-by:
Alex Chiang <achiang@hp.com> Signed-off-by:
Roland Dreier <rolandd@cisco.com>
-
Alexander Chiang authored
Some large systems may support more than IB_UMAD_MAX_PORTS (currently 64). This change allows us to support more ports in a backwards-compatible manner. The first IB_UMAD_MAX_PORTS keep the same major/minor device numbers they've always had. If there are more than IB_UMAD_MAX_PORTS, we then dynamically request a new major device number (new minors start at 0). Signed-off-by:
Alex Chiang <achiang@hp.com> Signed-off-by:
Roland Dreier <rolandd@cisco.com>
-
Alexander Chiang authored
This change is not useful by itself, but sets us up for a future change that allows us to support more than IB_UMAD_MAX_PORTS in a system. Signed-off-by:
Alex Chiang <achiang@hp.com> Signed-off-by:
Roland Dreier <rolandd@cisco.com>
-
Alexander Chiang authored
This change is not useful by itself, but sets us up for a future change that allows us to dynamically allocate device numbers in case we have more than IB_UMAD_MAX_PORTS in the system. Signed-off-by:
Alex Chiang <achiang@hp.com> Signed-off-by:
Roland Dreier <rolandd@cisco.com>
-
Alexander Chiang authored
We no longer need this data structure, as it was used to associate an inode back to a struct ib_umad_port during ->open(). But now that we're embedding a struct cdev in struct ib_umad_port, we can use the container_of() macro to go from the inode back to the device instead. Signed-off-by:
Alex Chiang <achiang@hp.com> Signed-off-by:
Roland Dreier <rolandd@cisco.com>
-
Alexander Chiang authored
Instead of storing pointers to cdev and sm_cdev, embed the full structures instead. This change allows us to use the container_of() macro in ib_umad_open() and ib_umad_sm_open() in a future patch. This change increases the size of struct ib_umad_port to 320 bytes from 128. Signed-off-by:
Alex Chiang <achiang@hp.com> Signed-off-by:
Roland Dreier <rolandd@cisco.com>
-
Alexander Chiang authored
Clean up the errors as shown when 'let c_space_errors=1' is set in vim. Signed-off-by:
Alex Chiang <achiang@hp.com> Signed-off-by:
Roland Dreier <rolandd@cisco.com>
-
Alexander Chiang authored
Eliminate some padding in the structure by rearranging the members. sizeof(struct ib_uverbs_event_file) is now 72 bytes (from 80) and more members now fit in the first cacheline. Signed-off-by:
Alex Chiang <achiang@hp.com> Signed-off-by:
Roland Dreier <rolandd@cisco.com>
-
Alexander Chiang authored
Some large systems may support more than IB_UVERBS_MAX_DEVICES (currently 32). This change allows us to support more devices in a backwards-compatible manner. The first IB_UVERBS_MAX_DEVICES keep the same major/minor device numbers that they've always had. If there are more than IB_UVERBS_MAX_DEVICES, we then dynamically request a new major device number (new minors start at 0). This change increases the maximum number of HCAs to 64 (from 32). Signed-off-by:
Alex Chiang <achiang@hp.com> Signed-off-by:
Roland Dreier <rolandd@cisco.com>
-
Alexander Chiang authored
This change is not useful by itself, but sets us up for a future change that allows us to support more than IB_UVERBS_MAX_DEVICES in a system. Signed-off-by:
Alex Chiang <achiang@hp.com> Signed-off-by:
Roland Dreier <rolandd@cisco.com>
-