<feed xmlns='http://www.w3.org/2005/Atom'>
<title>linux-toradex.git/drivers/scsi/hpsa_cmd.h, branch v4.1.26</title>
<subtitle>Linux kernel for Apalis and Colibri modules</subtitle>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/'/>
<entry>
<title>hpsa: do not use a void pointer for scsi_cmd field of struct CommandList</title>
<updated>2015-02-02T17:57:43+00:00</updated>
<author>
<name>Stephen Cameron</name>
<email>stephenmcameron@gmail.com</email>
</author>
<published>2015-01-23T22:44:30+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=7fa3030c655b7479940487b01a20f7332cf68c00'/>
<id>7fa3030c655b7479940487b01a20f7332cf68c00</id>
<content type='text'>
There's no reason for it to be a void *, it should be a struct scsi_cmnd *

Reviewed-by: Scott Teel &lt;scott.teel@pmcs.com&gt;
Signed-off-by: Don Brace &lt;don.brace@pmcs.com&gt;
Signed-off-by: Christoph Hellwig &lt;hch@lst.de&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
There's no reason for it to be a void *, it should be a struct scsi_cmnd *

Reviewed-by: Scott Teel &lt;scott.teel@pmcs.com&gt;
Signed-off-by: Don Brace &lt;don.brace@pmcs.com&gt;
Signed-off-by: Christoph Hellwig &lt;hch@lst.de&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>hpsa: fix race between abort handler and main i/o path</title>
<updated>2015-02-02T17:57:40+00:00</updated>
<author>
<name>Webb Scales</name>
<email>webbnh@hp.com</email>
</author>
<published>2015-01-23T22:43:35+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=281a7fd03ea37c979bbba4d8376595c0288e3252'/>
<id>281a7fd03ea37c979bbba4d8376595c0288e3252</id>
<content type='text'>
This means changing the allocator to reference count commands.
The reference count is now the authoritative indicator of whether a
command is allocated or not.  The h-&gt;cmd_pool_bits bitmap is now
only a heuristic hint to speed up the allocation process, it is no
longer the authoritative record of allocated commands.

Since we changed the command allocator to use reference counting
as the authoritative indicator of whether a command is allocated,
fail_all_outstanding_cmds needs to use the reference count not
h-&gt;cmd_pool_bits for this purpose.

Fix hpsa_drain_accel_commands to use the reference count as the
authoritative indicator of whether a command is allocated instead of
the h-&gt;cmd_pool_bits bitmap.

Reviewed-by: Scott Teel &lt;scott.teel@pmcs.com&gt;
Signed-off-by: Don Brace &lt;don.brace@pmcs.com&gt;
Signed-off-by: Christoph Hellwig &lt;hch@lst.de&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This means changing the allocator to reference count commands.
The reference count is now the authoritative indicator of whether a
command is allocated or not.  The h-&gt;cmd_pool_bits bitmap is now
only a heuristic hint to speed up the allocation process, it is no
longer the authoritative record of allocated commands.

Since we changed the command allocator to use reference counting
as the authoritative indicator of whether a command is allocated,
fail_all_outstanding_cmds needs to use the reference count not
h-&gt;cmd_pool_bits for this purpose.

Fix hpsa_drain_accel_commands to use the reference count as the
authoritative indicator of whether a command is allocated instead of
the h-&gt;cmd_pool_bits bitmap.

Reviewed-by: Scott Teel &lt;scott.teel@pmcs.com&gt;
Signed-off-by: Don Brace &lt;don.brace@pmcs.com&gt;
Signed-off-by: Christoph Hellwig &lt;hch@lst.de&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>hpsa: honor queue depth of physical devices</title>
<updated>2015-02-02T17:57:40+00:00</updated>
<author>
<name>Don Brace</name>
<email>don.brace@pmcs.com</email>
</author>
<published>2015-01-23T22:43:30+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=03383736348bb73a45f8460afca3c5f5bd1be172'/>
<id>03383736348bb73a45f8460afca3c5f5bd1be172</id>
<content type='text'>
When using the ioaccel submission methods, requests destined for RAID volumes
are sometimes diverted to physical devices.  The OS has no or limited
knowledge of these physical devices, so it is up to the driver to avoid
pushing the device too hard.  It is better to honor the physical device queue
limit rather than making the device spew zillions of TASK SET FULL responses.

This is so that hpsa based devices support /sys/block/sdNN/device/queue_type
of simple, which lets the SCSI midlayer automatically adjust the queue_depth
based on TASK SET FULL and GOOD status.

Adjust the queue depth for a new device after it is created based on the
maximum queue depths of the physical devices that constitute the
device. This drops the maximum queue depth from .can_queue of 1024 to
something like 174 for single-drive RAID-0, 348 for two-drive RAID-1, etc.
It also adjusts for the ratio of data to parity drives.

Reviewed-by: Scott Teel &lt;scott.teel@pmcs.com&gt;
Signed-off-by: Webb Scales &lt;webbnh@hp.com&gt;
Signed-off-by: Don Brace &lt;don.brace@pmcs.com&gt;
Signed-off-by: Christoph Hellwig &lt;hch@lst.de&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
When using the ioaccel submission methods, requests destined for RAID volumes
are sometimes diverted to physical devices.  The OS has no or limited
knowledge of these physical devices, so it is up to the driver to avoid
pushing the device too hard.  It is better to honor the physical device queue
limit rather than making the device spew zillions of TASK SET FULL responses.

This is so that hpsa based devices support /sys/block/sdNN/device/queue_type
of simple, which lets the SCSI midlayer automatically adjust the queue_depth
based on TASK SET FULL and GOOD status.

Adjust the queue depth for a new device after it is created based on the
maximum queue depths of the physical devices that constitute the
device. This drops the maximum queue depth from .can_queue of 1024 to
something like 174 for single-drive RAID-0, 348 for two-drive RAID-1, etc.
It also adjusts for the ratio of data to parity drives.

Reviewed-by: Scott Teel &lt;scott.teel@pmcs.com&gt;
Signed-off-by: Webb Scales &lt;webbnh@hp.com&gt;
Signed-off-by: Don Brace &lt;don.brace@pmcs.com&gt;
Signed-off-by: Christoph Hellwig &lt;hch@lst.de&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>hpsa: use workqueue to resubmit failed ioaccel commands</title>
<updated>2015-02-02T17:57:40+00:00</updated>
<author>
<name>Don Brace</name>
<email>don.brace@pmcs.com</email>
</author>
<published>2015-01-23T22:43:25+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=080ef1cc7fdf5d0800775c8626718da807e7ba99'/>
<id>080ef1cc7fdf5d0800775c8626718da807e7ba99</id>
<content type='text'>
Instead of kicking the commands all the way back to the mid
layer, use a work queue.  This enables having a mechanism for
the driver to be able to resubmit the commands down the "normal"
raid path without turning off the ioaccel feature entirely
whenever an error is encountered on the ioaccel path, and
prevent excessive rescanning of devices.

Reviewed-by: Scott Teel &lt;scott.teel@pmcs.com&gt;
Signed-off-by: Don Brace &lt;don.brace@pmcs.com&gt;
Signed-off-by: Christoph Hellwig &lt;hch@lst.de&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Instead of kicking the commands all the way back to the mid
layer, use a work queue.  This enables having a mechanism for
the driver to be able to resubmit the commands down the "normal"
raid path without turning off the ioaccel feature entirely
whenever an error is encountered on the ioaccel path, and
prevent excessive rescanning of devices.

Reviewed-by: Scott Teel &lt;scott.teel@pmcs.com&gt;
Signed-off-by: Don Brace &lt;don.brace@pmcs.com&gt;
Signed-off-by: Christoph Hellwig &lt;hch@lst.de&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>hpsa: do not queue commands internally in driver</title>
<updated>2015-02-02T17:57:39+00:00</updated>
<author>
<name>Don Brace</name>
<email>don.brace@pmcs.com</email>
</author>
<published>2015-01-23T22:43:09+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=f2405db8b4605732c8f0224c33b9d206e37b68c5'/>
<id>f2405db8b4605732c8f0224c33b9d206e37b68c5</id>
<content type='text'>
By not doing maintaining a list of queued commands, we can eliminate some spin
locking in the main i/o path and gain significant improvement in IOPS.  Remove
the queuing code and the code that calls it; remove now-unused interrupt code;
remove DIRECT_LOOKUP_BIT.

Now that the passthru commands share the same command pool as
the main i/o path, and the total size of the pool is less than
or equal to the number of commands that will fit in the hardware
fifo, there is no need to check to see if we are exceeding the
hardware fifo's depth.

Reviewed-by: Scott Teel &lt;scott.teel@pmcs.com&gt;
Reviewed-by: Robert Elliott &lt;elliott@hp.com&gt;
Signed-off-by: Don Brace &lt;don.brace@pmcs.com&gt;
Signed-off-by: Christoph Hellwig &lt;hch@lst.de&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
By not doing maintaining a list of queued commands, we can eliminate some spin
locking in the main i/o path and gain significant improvement in IOPS.  Remove
the queuing code and the code that calls it; remove now-unused interrupt code;
remove DIRECT_LOOKUP_BIT.

Now that the passthru commands share the same command pool as
the main i/o path, and the total size of the pool is less than
or equal to the number of commands that will fit in the hardware
fifo, there is no need to check to see if we are exceeding the
hardware fifo's depth.

Reviewed-by: Scott Teel &lt;scott.teel@pmcs.com&gt;
Reviewed-by: Robert Elliott &lt;elliott@hp.com&gt;
Signed-off-by: Don Brace &lt;don.brace@pmcs.com&gt;
Signed-off-by: Christoph Hellwig &lt;hch@lst.de&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>hpsa: correct endian sparse warnings</title>
<updated>2015-02-02T17:57:35+00:00</updated>
<author>
<name>Don Brace</name>
<email>don.brace@pmcs.com</email>
</author>
<published>2015-01-23T22:41:09+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=2b08b3e9d9dad982466d3452e410d5e398e55503'/>
<id>2b08b3e9d9dad982466d3452e410d5e398e55503</id>
<content type='text'>
Correct endiness issues reported by sparse. SA controllers are
little endian. This patch ensures endiness correctness.

Signed-off-by: Don Brace &lt;don.brace@pmcs.com&gt;
Reviewed-by: Scott Teel &lt;scott.teel@pmcs.com&gt;
Reviewed-by: Webb Scales &lt;webbnh@hp.com&gt;
Signed-off-by: Christoph Hellwig &lt;hch@lst.de&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Correct endiness issues reported by sparse. SA controllers are
little endian. This patch ensures endiness correctness.

Signed-off-by: Don Brace &lt;don.brace@pmcs.com&gt;
Reviewed-by: Scott Teel &lt;scott.teel@pmcs.com&gt;
Reviewed-by: Webb Scales &lt;webbnh@hp.com&gt;
Signed-off-by: Christoph Hellwig &lt;hch@lst.de&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>hpsa: get rid of type/attribute/direction bit field where possible</title>
<updated>2014-11-20T08:11:25+00:00</updated>
<author>
<name>Stephen M. Cameron</name>
<email>stephenmcameron@gmail.com</email>
</author>
<published>2014-11-14T23:27:04+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=a505b86fde5903944828fa04f775e79a6636791d'/>
<id>a505b86fde5903944828fa04f775e79a6636791d</id>
<content type='text'>
Using bit fields for hardware command fields isn't portable and
relies on assumptions about how the compiler lays out the bits.
We can fix this in the driver's internal command structure, but the
ioctl interface we can't change because it is part of the
userland ABI.

Signed-off-by: Don Brace &lt;don.brace@pmcs.com&gt;
Reviewed-by: Webb Scales &lt;webb.scales@hp.com&gt;
Signed-off-by: Christoph Hellwig &lt;hch@lst.de&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Using bit fields for hardware command fields isn't portable and
relies on assumptions about how the compiler lays out the bits.
We can fix this in the driver's internal command structure, but the
ioctl interface we can't change because it is part of the
userland ABI.

Signed-off-by: Don Brace &lt;don.brace@pmcs.com&gt;
Reviewed-by: Webb Scales &lt;webb.scales@hp.com&gt;
Signed-off-by: Christoph Hellwig &lt;hch@lst.de&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>hpsa: fix endianness issue with scatter gather elements</title>
<updated>2014-11-20T08:11:24+00:00</updated>
<author>
<name>Stephen M. Cameron</name>
<email>stephenmcameron@gmail.com</email>
</author>
<published>2014-11-14T23:26:59+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=50a0decf75b66480aa5b076d4e1bca11bc202efe'/>
<id>50a0decf75b66480aa5b076d4e1bca11bc202efe</id>
<content type='text'>
The hardware needs little endian scatter gather addresses and
lengths but we were not bothering to convert from cpu byte
order as we should have been.  On Intel, this is all just
a bunch of no-ops macros, but it makes the code endian-clean(er).

Signed-off-by: Don Brace &lt;don.brace@pmcs.com&gt;
Signed-off-by: Robert Elliott &lt;elliott@hp.com&gt;
Reviewed-by: Webb Scales &lt;webbnh@hp.com&gt;
Signed-off-by: Christoph Hellwig &lt;hch@lst.de&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
The hardware needs little endian scatter gather addresses and
lengths but we were not bothering to convert from cpu byte
order as we should have been.  On Intel, this is all just
a bunch of no-ops macros, but it makes the code endian-clean(er).

Signed-off-by: Don Brace &lt;don.brace@pmcs.com&gt;
Signed-off-by: Robert Elliott &lt;elliott@hp.com&gt;
Reviewed-by: Webb Scales &lt;webbnh@hp.com&gt;
Signed-off-by: Christoph Hellwig &lt;hch@lst.de&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>hpsa: fix allocation sizes for CISS_REPORT_LUNs commands</title>
<updated>2014-11-20T08:11:24+00:00</updated>
<author>
<name>Stephen M. Cameron</name>
<email>stephenmcameron@gmail.com</email>
</author>
<published>2014-11-14T23:26:54+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=92084715f4d296c99ac120b3b77cf72d5c194c86'/>
<id>92084715f4d296c99ac120b3b77cf72d5c194c86</id>
<content type='text'>
We were allocating roughly double the amount of memory
we should be due to ReportLUNdata and ExtendedReportLUNdata
containing a non-zero sized array but adding extra memory
to allocate as if the array were zero sized.

Track the logical and physical sizes separately.
Allocate the memory based on the specific data
structure sizes.

Signed-off-by: Don Brace &lt;don.brace@pmcs.com&gt;
Reviewed-by: Webb Scales &lt;webb.scales@hp.com&gt;
Signed-off-by: Christoph Hellwig &lt;hch@lst.de&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
We were allocating roughly double the amount of memory
we should be due to ReportLUNdata and ExtendedReportLUNdata
containing a non-zero sized array but adding extra memory
to allocate as if the array were zero sized.

Track the logical and physical sizes separately.
Allocate the memory based on the specific data
structure sizes.

Signed-off-by: Don Brace &lt;don.brace@pmcs.com&gt;
Reviewed-by: Webb Scales &lt;webb.scales@hp.com&gt;
Signed-off-by: Christoph Hellwig &lt;hch@lst.de&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>hpsa: fix handling of hpsa_volume_offline return value</title>
<updated>2014-06-02T07:55:02+00:00</updated>
<author>
<name>Stephen M. Cameron</name>
<email>scameron@beardog.cce.hp.com</email>
</author>
<published>2014-05-29T15:54:25+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=67955ba36eccb5733fd289839a5a5d1dfc33ccf7'/>
<id>67955ba36eccb5733fd289839a5a5d1dfc33ccf7</id>
<content type='text'>
Make return value an int instead of an unsigned char so that
we do not lose negative error return values.

Signed-off-by: Stephen M. Cameron &lt;scameron@beardog.cce.hp.com&gt;
Reviewed-by: Webb Scales &lt;webb.scales@hp.com&gt;
Reported-by: Dan Carpenter &lt;dan.carpenter@oracle.com&gt;
Signed-off-by: Christoph Hellwig &lt;hch@lst.de&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Make return value an int instead of an unsigned char so that
we do not lose negative error return values.

Signed-off-by: Stephen M. Cameron &lt;scameron@beardog.cce.hp.com&gt;
Reviewed-by: Webb Scales &lt;webb.scales@hp.com&gt;
Reported-by: Dan Carpenter &lt;dan.carpenter@oracle.com&gt;
Signed-off-by: Christoph Hellwig &lt;hch@lst.de&gt;
</pre>
</div>
</content>
</entry>
</feed>
