Bart Van Assche
369d76eff4
Eliminated two more forward declarations.
...
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@3070 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2010-12-15 12:09:47 +00:00
Bart Van Assche
849c9ec801
Eliminated two more forward declarations.
...
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@3069 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2010-12-15 12:01:41 +00:00
Bart Van Assche
cf2a3182aa
Aligned array data in columns and updated a comment.
...
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@3067 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2010-12-15 10:45:31 +00:00
Bart Van Assche
a82024cdc0
Moved sysfs root object implementation near the end of source file scst_sysfs.c.
...
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@3066 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2010-12-15 10:35:15 +00:00
Bart Van Assche
a0fdf96c73
Converted function-local constant definitions from #defines into enums.
...
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@3065 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2010-12-15 10:27:51 +00:00
Bart Van Assche
fbb98f4333
Moved definition of scst_read_trace_tbl() too.
...
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@3064 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2010-12-15 10:23:40 +00:00
Bart Van Assche
d12d45dd79
Eliminated two forward declarations by rearranging the function order.
...
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@3063 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2010-12-15 10:16:49 +00:00
Bart Van Assche
d5cda9519f
Converted kmalloc() + strcpy() into kstrdup().
...
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@3056 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2010-12-14 12:09:47 +00:00
Bart Van Assche
fac989f319
Added ADD_MODULES variable to initd.debian.
...
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@3055 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2010-12-14 12:04:36 +00:00
Bart Van Assche
3583bbf2cb
Added ADD_MODULES variable to initd.redhat.
...
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@3054 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2010-12-14 12:03:06 +00:00
Bart Van Assche
110991b976
Removed incorrect references to /etc/init.d/scst.
...
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@3053 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2010-12-14 11:00:37 +00:00
Bart Van Assche
5ea14dfbe5
Rewrote two comments blocks.
...
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@3045 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2010-12-13 13:31:57 +00:00
Bart Van Assche
a0e87fb779
Don't read uninitialized variables (was introduced in r2867).
...
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@3030 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2010-12-12 12:42:30 +00:00
Bart Van Assche
3d707844b0
put_page_callback-2.6.37.patch: diff minimizing / added a missing file.
...
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@3029 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2010-12-12 12:22:10 +00:00
Bart Van Assche
49e8bb1aea
Fixed a <=2.6.29 compiler warning.
...
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@3020 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2010-12-11 11:14:11 +00:00
Bart Van Assche
cd984c6f82
ib_srpt: Fix a procfs-only compiler warning.
...
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@3017 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2010-12-11 09:58:37 +00:00
Mark Buechler
f55ccbe2cd
- Small cleanup of issueLip().
...
- Issue a LIP on any changes which might effect initiators.
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@3011 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2010-12-10 16:08:52 +00:00
Bart Van Assche
c1fc45ee25
Updated kernel versions.
...
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@3004 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2010-12-10 09:49:24 +00:00
Bart Van Assche
8e0e19c9de
ib_srpt (sysfs): Converted login_info from a device attribute into a tgt attribute.
...
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@3003 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2010-12-10 09:47:29 +00:00
Bart Van Assche
d1f587ef29
Builds now on kernel 2.6.37 too.
...
(svn merge -c2972 https://scst.svn.sourceforge.net/svnroot/scst/branches/sysfs-tree-changes )
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@3002 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2010-12-10 09:13:03 +00:00
Mark Buechler
8f8dffd91b
- Exit 0 and issue warning on empty config file.
...
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@2979 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2010-12-08 15:01:48 +00:00
Mark Buechler
b12f90f23f
- Fix init script for CentOS/RedHat. Patch by fzago@systemfabricworks.com
...
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@2978 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2010-12-08 14:57:48 +00:00
Bart Van Assche
fe247fde3b
Get rid of sparse errors on sk_buff.protocol.
...
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@2970 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2010-12-07 18:51:37 +00:00
Mark Buechler
faa2e13cb6
- Properly detect when SCST isn't loaded.
...
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@2969 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2010-12-07 17:49:15 +00:00
Mark Buechler
42e623f994
- Hopefully fix all remaining exit code issues.
...
- Better fix for empty groups - don't write empty braces.
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@2968 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2010-12-07 17:40:16 +00:00
Bart Van Assche
3fb6b9e6e7
scst_disk builds again on kernel 2.6.30 and before (was broken by r2836).
...
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@2965 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2010-12-07 17:30:09 +00:00
Bart Van Assche
17cb105213
Made sure that srpt_release() doesn't oops if srpt_add_one() fails after
...
having registered the target and before the srpt_post_recv() loop started.
Reported-by: Frank Zago <fzago@systemfabricworks.com >.
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@2963 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2010-12-07 16:59:19 +00:00
Bart Van Assche
7631a26bc9
Removed two unused variables.
...
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@2954 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2010-12-07 10:16:14 +00:00
Bart Van Assche
4afc6e1713
Fixed a bug that could cause scstadmin -write_config to generate an invalid
...
configuration file, e.g.
...
GROUP a }
...
Reported-by: Frank Zago <fzago@systemfabricworks.com >
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@2952 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2010-12-07 09:35:18 +00:00
Bart Van Assche
1fe5da1dea
ib_srpt: Source code formatting cleanup.
...
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@2951 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2010-12-07 09:25:23 +00:00
Bart Van Assche
7e158b0c68
Handle iWARP devices graciously - ib_srpt does not work with at least Intel
...
iWARP devices.
Reported-by: Frank Zago <fzago@systemfabricworks.com >.
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@2950 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2010-12-07 09:21:16 +00:00
Bart Van Assche
c81d1ed573
Converted kmalloc() + sprintf() calls into a kasprintf() call and converted
...
kmalloc() + strcpy() calls into a kstrdup() call. (Merged r2986, r2897 and
r2901 from the sysfs-changes branch.)
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@2944 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2010-12-06 10:56:45 +00:00
Bart Van Assche
c75f68247a
Reverted r2748 because it might offend some people.
...
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@2917 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2010-12-04 09:22:00 +00:00
Bart Van Assche
d0547fe613
scst/scst_vdisk: Made error handling in bi_end_io function IRQ-safe since
...
bi_end_io functions must be IRQ-safe.
A quote from a discussion between Alan Cox, Mikulas Patocka and Jens Axboe
(http://lkml.org/lkml/2008/7/2/69 ):
> >Right, that wont work of course. Completions are typically done through
> >a softirq, so it is not currently done with hard interrupts disabled.
>
> I thought, from hardirq - that's what IDE is doing. And they are called
> with interrupts disabled (maybe unless you specify unmaskirq, which is not
> default). What block driver does completions with softirq? ... and why?
The key word is 'typically', the old IDE driver really isn't used very
much. The SCSI layer and eg cciss uses the block layer softirq
completions, so that is what 99% of the uses will be.
The patch itself was provided by Arne Redlich.
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@2913 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2010-12-03 11:35:31 +00:00
Bart Van Assche
1d520654cb
ib_srpt: Pass correct atomic context information to scst_rx_cmd().
...
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@2912 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2010-12-03 11:29:47 +00:00
Bart Van Assche
8773b01fde
Fixed scst_suspend_activity() lockdep annotations.
...
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@2888 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2010-12-01 09:56:32 +00:00
Vladislav Bolkhovitin
d83c11c1a3
Fix rarely possible race between scst_free_session() and scst_check_reassign_sess()
...
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@2867 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2010-11-29 17:12:53 +00:00
Vladislav Bolkhovitin
f9ca99c4da
This patch simplifies the SCST sysfs code a little bit by
...
introducing the functions sysfs_create_files() and sysfs_remove_files().
These functions have been introduced in kernel 2.6.34 via commit
1c205ae18db53ff72985dd79f3baaf2dbaba6db7. An implementation of these
functions has been included for older kernels.
Signed-off-by: Bart Van Assche <bvanassche@acm.org >
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@2861 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2010-11-27 19:35:21 +00:00
Vladislav Bolkhovitin
b330889bf4
This patch fixes a class of race conditions in the ..._sysfs_del()
...
functions: the kobject_put() calls should come after all kobject_del() calls
because as long as the last kobject_del() call hasn't been invoked, a sysfs
.show() or .store() callback may still be in progress that needs one of
these kobjects.
Signed-off-by: Bart Van Assche <bvanassche@acm.org >
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@2860 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2010-11-27 19:22:43 +00:00
Bart Van Assche
d144966a53
scst: Lock annotation corrections.
...
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@2846 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2010-11-27 10:21:03 +00:00
Joe Eykholt
8e0e14b5e0
My previous commit failed to include 2 critical patches, plus
...
had the wrong version of 22-lport-notify. This corrects that.
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@2845 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2010-11-26 21:40:59 +00:00
Vladislav Bolkhovitin
bef485b20f
Simplify scst_free_session() by invoking wake_up_all() while scst_mutex is held.
...
Signed-off-by: Bart Van Assche <bvanassche@acm.org >
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@2844 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2010-11-26 21:28:38 +00:00
Vladislav Bolkhovitin
bd60cf5505
Minor improvement
...
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@2843 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2010-11-26 20:53:33 +00:00
Vladislav Bolkhovitin
308aca8883
Fix memory leak in __blk_rq_map_kern_sg() reported by "Hauser, Stefan" <stefan.hauser@bdt.de>
...
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@2840 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2010-11-26 15:07:35 +00:00
Bart Van Assche
f4da51e7b7
Follow-up for r2837: fixed a typo.
...
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@2838 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2010-11-26 14:42:24 +00:00
Vladislav Bolkhovitin
515fda68cf
This patch simplifies the string duplication code in
...
scst_sysfs.c and scst_vdisk.c. Code for duplicating '\0'-terminated
strings has been replaced by a call to kstrdup() and code for
duplicating fixed-length strings has been replaced by a call to
kasprintf(GFP_KERNEL, "%.*s", (int)size, buf).
Signed-off-by: Bart Van Assche <bvanassche@acm.org >
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@2837 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2010-11-26 14:05:29 +00:00
Vladislav Bolkhovitin
2935a05765
Use queue's max_hw_sectors instead of host->max_sectors as reported by "Hauser, Stefan" <stefan.hauser@bdt.de>
...
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@2836 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2010-11-26 14:03:39 +00:00
Bart Van Assche
db35095aa1
Fixed a recently introduced sparse warning that was triggered against kernel 2.6.28 and before.
...
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@2833 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2010-11-26 08:46:16 +00:00
Vladislav Bolkhovitin
2170d47abc
This patch makes it possible for lockdep to recognize activity suspending and
...
resuming.
Signed-off-by: Bart Van Assche <bvanassche@acm.org >
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@2832 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2010-11-25 20:41:53 +00:00
Bart Van Assche
69c9e393e5
Fixed recently introduced checkpatch complaints about whitespace.
...
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@2828 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2010-11-25 09:58:09 +00:00