<feed xmlns='http://www.w3.org/2005/Atom'>
<title>lwn.git/drivers/scsi/osst.c, branch v3.12</title>
<subtitle>Linux kernel documentation tree maintained by Jonathan Corbet</subtitle>
<id>http://mirrors.hust.edu.cn/git/lwn.git/atom?h=v3.12</id>
<link rel='self' href='http://mirrors.hust.edu.cn/git/lwn.git/atom?h=v3.12'/>
<link rel='alternate' type='text/html' href='http://mirrors.hust.edu.cn/git/lwn.git/'/>
<updated>2012-03-28T17:30:03+00:00</updated>
<entry>
<title>Remove all #inclusions of asm/system.h</title>
<updated>2012-03-28T17:30:03+00:00</updated>
<author>
<name>David Howells</name>
<email>dhowells@redhat.com</email>
</author>
<published>2012-03-28T17:30:03+00:00</published>
<link rel='alternate' type='text/html' href='http://mirrors.hust.edu.cn/git/lwn.git/commit/?id=9ffc93f203c18a70623f21950f1dd473c9ec48cd'/>
<id>urn:sha1:9ffc93f203c18a70623f21950f1dd473c9ec48cd</id>
<content type='text'>
Remove all #inclusions of asm/system.h preparatory to splitting and killing
it.  Performed with the following command:

perl -p -i -e 's!^#\s*include\s*&lt;asm/system[.]h&gt;.*\n!!' `grep -Irl '^#\s*include\s*&lt;asm/system[.]h&gt;' *`

Signed-off-by: David Howells &lt;dhowells@redhat.com&gt;
</content>
</entry>
<entry>
<title>[SCSI] osst: fix warning</title>
<updated>2011-05-24T17:09:41+00:00</updated>
<author>
<name>Andrew Morton</name>
<email>akpm@linux-foundation.org</email>
</author>
<published>2011-05-23T22:29:13+00:00</published>
<link rel='alternate' type='text/html' href='http://mirrors.hust.edu.cn/git/lwn.git/commit/?id=6e2037b0fd4d4ad9be941a3520d21945bc031a20'/>
<id>urn:sha1:6e2037b0fd4d4ad9be941a3520d21945bc031a20</id>
<content type='text'>
drivers/scsi/osst.c: In function '__os_scsi_tape_open':
drivers/scsi/osst.c:4705: warning: ISO C90 forbids mixed declarations and code

Signed-off-by: Andrew Morton &lt;akpm@linux-foundation.org&gt;
Signed-off-by: James Bottomley &lt;jbottomley@parallels.com&gt;
</content>
</entry>
<entry>
<title>[SCSI] osst: wrong index used in inner loop</title>
<updated>2011-05-24T17:08:57+00:00</updated>
<author>
<name>Roel Kluin</name>
<email>roel.kluin@gmail.com</email>
</author>
<published>2011-05-23T22:29:12+00:00</published>
<link rel='alternate' type='text/html' href='http://mirrors.hust.edu.cn/git/lwn.git/commit/?id=a061f57d662ac2b19a1ff1955349adce7a282a5d'/>
<id>urn:sha1:a061f57d662ac2b19a1ff1955349adce7a282a5d</id>
<content type='text'>
Index i was already used in the outer loop.  Fixes a potentially-infinite
loop.

[akpm@linux-foundation.org: coding-style fixes]
Signed-off-by: Roel Kluin &lt;roel.kluin@gmail.com&gt;
Cc: Willem Riede &lt;osst@riede.org&gt;
Signed-off-by: Andrew Morton &lt;akpm@linux-foundation.org&gt;
Signed-off-by: James Bottomley &lt;jbottomley@parallels.com&gt;
</content>
</entry>
<entry>
<title>Fix common misspellings</title>
<updated>2011-03-31T14:26:23+00:00</updated>
<author>
<name>Lucas De Marchi</name>
<email>lucas.demarchi@profusion.mobi</email>
</author>
<published>2011-03-31T01:57:33+00:00</published>
<link rel='alternate' type='text/html' href='http://mirrors.hust.edu.cn/git/lwn.git/commit/?id=25985edcedea6396277003854657b5f3cb31a628'/>
<id>urn:sha1:25985edcedea6396277003854657b5f3cb31a628</id>
<content type='text'>
Fixes generated by 'codespell' and manually reviewed.

Signed-off-by: Lucas De Marchi &lt;lucas.demarchi@profusion.mobi&gt;
</content>
</entry>
<entry>
<title>scsi: Remove unnecessary casts of void ptr returning alloc function return values</title>
<updated>2011-01-19T14:26:40+00:00</updated>
<author>
<name>Jesper Juhl</name>
<email>jj@chaosbits.net</email>
</author>
<published>2010-11-08T23:09:25+00:00</published>
<link rel='alternate' type='text/html' href='http://mirrors.hust.edu.cn/git/lwn.git/commit/?id=2099973abfb96f98290d52de24940561e29bbeea'/>
<id>urn:sha1:2099973abfb96f98290d52de24940561e29bbeea</id>
<content type='text'>
The [vk][cmz]alloc(_node) family of functions return void pointers which
it's completely unnecessary/pointless to cast to other pointer types since
that happens implicitly.

This patch removes such casts from drivers/scsi/

Signed-off-by: Jesper Juhl &lt;jj@chaosbits.net&gt;
Signed-off-by: Jiri Kosina &lt;jkosina@suse.cz&gt;
</content>
</entry>
<entry>
<title>scsi: autoconvert trivial BKL users to private mutex</title>
<updated>2010-09-15T19:00:45+00:00</updated>
<author>
<name>Arnd Bergmann</name>
<email>arnd@arndb.de</email>
</author>
<published>2010-06-02T12:28:52+00:00</published>
<link rel='alternate' type='text/html' href='http://mirrors.hust.edu.cn/git/lwn.git/commit/?id=c45d15d24eb2b49bf734e1e5e7e103befb76b19b'/>
<id>urn:sha1:c45d15d24eb2b49bf734e1e5e7e103befb76b19b</id>
<content type='text'>
All these files use the big kernel lock in a trivial
way to serialize their private file operations,
typically resulting from an earlier semi-automatic
pushdown from VFS.

None of these drivers appears to want to lock against
other code, and they all use the BKL as the top-level
lock in their file operations, meaning that there
is no lock-order inversion problem.

Consequently, we can remove the BKL completely,
replacing it with a per-file mutex in every case.
Using a scripted approach means we can avoid
typos.

file=$1
name=$2
if grep -q lock_kernel ${file} ; then
    if grep -q 'include.*linux.mutex.h' ${file} ; then
            sed -i '/include.*&lt;linux\/smp_lock.h&gt;/d' ${file}
    else
            sed -i 's/include.*&lt;linux\/smp_lock.h&gt;.*$/include &lt;linux\/mutex.h&gt;/g' ${file}
    fi
    sed -i ${file} \
        -e "/^#include.*linux.mutex.h/,$ {
                1,/^\(static\|int\|long\)/ {
                     /^\(static\|int\|long\)/istatic DEFINE_MUTEX(${name}_mutex);

} }"  \
    -e "s/\(un\)*lock_kernel\&gt;[ ]*()/mutex_\1lock(\&amp;${name}_mutex)/g" \
    -e '/[      ]*cycle_kernel_lock();/d'
else
    sed -i -e '/include.*\&lt;smp_lock.h\&gt;/d' ${file}  \
                -e '/cycle_kernel_lock()/d'
fi

Signed-off-by: Arnd Bergmann &lt;arnd@arndb.de&gt;
Cc: linux-scsi@vger.kernel.org
Cc: "James E.J. Bottomley" &lt;James.Bottomley@suse.de&gt;
</content>
</entry>
<entry>
<title>osst: fix read buffer overflow</title>
<updated>2010-08-11T15:58:59+00:00</updated>
<author>
<name>Roel Kluin</name>
<email>roel.kluin@gmail.com</email>
</author>
<published>2010-08-11T01:01:10+00:00</published>
<link rel='alternate' type='text/html' href='http://mirrors.hust.edu.cn/git/lwn.git/commit/?id=ef3f7cc41280e9611a837df1fedf3f6d4d921a75'/>
<id>urn:sha1:ef3f7cc41280e9611a837df1fedf3f6d4d921a75</id>
<content type='text'>
Check whether index is within bounds before testing the element.

Signed-off-by: Roel Kluin &lt;roel.kluin@gmail.com&gt;
Cc: Willem Riede &lt;osst@riede.org&gt;
Cc: James E.J. Bottomley &lt;James.Bottomley@HansenPartnership.com&gt;
Signed-off-by: Andrew Morton &lt;akpm@linux-foundation.org&gt;
Signed-off-by: Linus Torvalds &lt;torvalds@linux-foundation.org&gt;
</content>
</entry>
<entry>
<title>osst: use noop_llseek() instead of default_llseek()</title>
<updated>2010-05-27T16:12:56+00:00</updated>
<author>
<name>Jan Blunck</name>
<email>jblunck@suse.de</email>
</author>
<published>2010-05-26T21:44:50+00:00</published>
<link rel='alternate' type='text/html' href='http://mirrors.hust.edu.cn/git/lwn.git/commit/?id=889e5fbbc2da4f59d5f1e9b6172c5ff2b92d02c8'/>
<id>urn:sha1:889e5fbbc2da4f59d5f1e9b6172c5ff2b92d02c8</id>
<content type='text'>
__os_scsi_tape_open() suggests that llseek() doesn't work: "We really want
to do nonseekable_open(inode, filp); here, but some versions of tar
incorrectly call lseek on tapes and bail out if that fails.  So we
disallow pread() and pwrite(), but permit lseeks."

Instead of using the fallback default_llseek() the driver should use
noop_llseek() which leaves the file-&gt;f_pos untouched but succeeds.

Signed-off-by: Jan Blunck &lt;jblunck@suse.de&gt;
Cc: Frederic Weisbecker &lt;fweisbec@gmail.com&gt;
Cc: Willem Riede &lt;osst@riede.org&gt;
Cc: James Bottomley &lt;James.Bottomley@HansenPartnership.com&gt;
Signed-off-by: Andrew Morton &lt;akpm@linux-foundation.org&gt;
Signed-off-by: Linus Torvalds &lt;torvalds@linux-foundation.org&gt;
</content>
</entry>
<entry>
<title>osst: update ppos instead of using file-&gt;f_pos</title>
<updated>2010-05-27T16:12:56+00:00</updated>
<author>
<name>Jan Blunck</name>
<email>jblunck@suse.de</email>
</author>
<published>2010-05-26T21:44:44+00:00</published>
<link rel='alternate' type='text/html' href='http://mirrors.hust.edu.cn/git/lwn.git/commit/?id=e1c54b64027b52ba43b86fe6219910a9e9a88b73'/>
<id>urn:sha1:e1c54b64027b52ba43b86fe6219910a9e9a88b73</id>
<content type='text'>
osst_read()/osst_write() modify file-&gt;f_pos directly instead of the ppos
given to them.  The VFS later updates the file-&gt;f_pos and overwrites it
with the value of ppos.

Signed-off-by: Jan Blunck &lt;jblunck@suse.de&gt;
Cc: Frederic Weisbecker &lt;fweisbec@gmail.com&gt;
Cc: Willem Riede &lt;osst@riede.org&gt;
Cc: James Bottomley &lt;James.Bottomley@HansenPartnership.com&gt;
Signed-off-by: Andrew Morton &lt;akpm@linux-foundation.org&gt;
Signed-off-by: Linus Torvalds &lt;torvalds@linux-foundation.org&gt;
</content>
</entry>
<entry>
<title>scsi: Push down BKL into ioctl functions</title>
<updated>2010-05-17T03:27:04+00:00</updated>
<author>
<name>Arnd Bergmann</name>
<email>arnd@arndb.de</email>
</author>
<published>2010-04-26T22:24:01+00:00</published>
<link rel='alternate' type='text/html' href='http://mirrors.hust.edu.cn/git/lwn.git/commit/?id=f4927c45beda9a70e5c3bda0bd9f12b4f713c00b'/>
<id>urn:sha1:f4927c45beda9a70e5c3bda0bd9f12b4f713c00b</id>
<content type='text'>
Push down the bkl into ioctl functions on the scsi layer.

[jkacur: Forward declaration missing ';'.
Conflicting declaraction in megaraid.h changed
Fixed missing inodes declarations]

Signed-off-by: Arnd Bergmann &lt;arnd@arndb.de&gt;
Signed-off-by: John Kacur &lt;jkacur@redhat.com&gt;
Signed-off-by: Frederic Weisbecker &lt;fweisbec@gmail.com&gt;
</content>
</entry>
</feed>
