Age | Commit message (Collapse) | Author | Files | Lines |
|
Signed-off-by: Kashyap Desai <[email protected]>
Signed-off-by: Shivasharan S <[email protected]>
Reviewed-by: Hannes Reinecke <[email protected]>
Reviewed-by: Tomas Henzl <[email protected]>
Signed-off-by: Martin K. Petersen <[email protected]>
|
|
value to 2
For RAID1 FastPath writes, driver needs to allocate extra commands
internally to accommodate for the extra peer command being sent.
Currently driver is allocating 2 extra commands for each but only one
extra command is necessary. Set RAID_1_10_RMW_CMDS to 2 and also change
macro name to RAID_1_PEER_CMDS.
Signed-off-by: Kashyap Desai <[email protected]>
Signed-off-by: Shivasharan S <[email protected]>
Reviewed-by: Hannes Reinecke <[email protected]>
Reviewed-by: Tomas Henzl <[email protected]>
Signed-off-by: Martin K. Petersen <[email protected]>
|
|
Fix indentation issues and smatch warning reported by Dan Carpenter
for previous series as discussed below.
http://www.spinics.net/lists/linux-scsi/msg103635.html
http://www.spinics.net/lists/linux-scsi/msg103603.html
Reported-by: Dan Carpenter <[email protected]>
Signed-off-by: Kashyap Desai <[email protected]>
Signed-off-by: Sasikumar Chandrasekaran <[email protected]>
Reviewed-by: Hannes Reinecke <[email protected]>
Reviewed-by: Tomas Henzl <[email protected]>
Signed-off-by: Martin K. Petersen <[email protected]>
|
|
Signed-off-by: Kashyap Desai <[email protected]>
Signed-off-by: Shivasharan S <[email protected]>
Reviewed-by: Hannes Reinecke <[email protected]>
Reviewed-by: Tomas Henzl <[email protected]>
Signed-off-by: Martin K. Petersen <[email protected]>
|
|
Fix - increase internal command pool to 8.
Signed-off-by: Kashyap Desai <[email protected]>
Signed-off-by: Shivasharan S <[email protected]>
Reviewed-by: Hannes Reinecke <[email protected]>
Reviewed-by: Tomas Henzl <[email protected]>
Signed-off-by: Martin K. Petersen <[email protected]>
|
|
FIX - Do not use random delay to synchronize with IRQ. Use kernel API.
Signed-off-by: Kashyap Desai <[email protected]>
Signed-off-by: Shivasharan S <[email protected]>
Reviewed-by: Hannes Reinecke <[email protected]>
Reviewed-by: Tomas Henzl <[email protected]>
Signed-off-by: Martin K. Petersen <[email protected]>
|
|
Error handling: Bail out the driver load if key FW cmds (LD_LIST) are
not return successful. Clean up error handling in megasas_init_fw.
Signed-off-by: Kashyap Desai <[email protected]>
Signed-off-by: Shivasharan S <[email protected]>
Reviewed-by: Hannes Reinecke <[email protected]>
Reviewed-by: Tomas Henzl <[email protected]>
Signed-off-by: Martin K. Petersen <[email protected]>
|
|
Code refactoring to build_mpt_mfi_pass_thru to return void.
Signed-off-by: Kashyap Desai <[email protected]>
Signed-off-by: Shivasharan S <[email protected]>
Reviewed-by: Hannes Reinecke <[email protected]>
Reviewed-by: Tomas Henzl <[email protected]>
Signed-off-by: Martin K. Petersen <[email protected]>
|
|
Error handling: If controller reset is not able to recover, kill HBA and
quit immediately.
Signed-off-by: Kashyap Desai <[email protected]>
Signed-off-by: Shivasharan S <[email protected]>
Reviewed-by: Hannes Reinecke <[email protected]>
Reviewed-by: Tomas Henzl <[email protected]>
Signed-off-by: Martin K. Petersen <[email protected]>
|
|
change fp_possible to bool
FIX - firmware wants non-RW SYS PD IOs to avoid FastPath for better
tracking and other functionalities if the device is task management
capable.
Signed-off-by: Kashyap Desai <[email protected]>
Signed-off-by: Shivasharan S <[email protected]>
Reviewed-by: Hannes Reinecke <[email protected]>
Reviewed-by: Tomas Henzl <[email protected]>
Signed-off-by: Martin K. Petersen <[email protected]>
|
|
Signed-off-by: Kashyap Desai <[email protected]>
Signed-off-by: Shivasharan S <[email protected]>
Reviewed-by: Hannes Reinecke <[email protected]>
Reviewed-by: Tomas Henzl <[email protected]>
Signed-off-by: Martin K. Petersen <[email protected]>
|
|
Memset the IO frame to zero after release.
Signed-off-by: Kashyap Desai <[email protected]>
Signed-off-by: Shivasharan S <[email protected]>
Reviewed-by: Hannes Reinecke <[email protected]>
Reviewed-by: Tomas Henzl <[email protected]>
Signed-off-by: Martin K. Petersen <[email protected]>
|
|
Fix to account for the reply_q_sz not exceeding the maximum commands
that the firmware can support, instance->max_fw_cmds is already
decremented in megasas_fusion_update_can_queue(). Remove the extra
decrement logic in code.
Signed-off-by: Kashyap Desai <[email protected]>
Signed-off-by: Shivasharan S <[email protected]>
Reviewed-by: Hannes Reinecke <[email protected]>
Reviewed-by: Tomas Henzl <[email protected]>
Signed-off-by: Martin K. Petersen <[email protected]>
|
|
Minor Optimization: No need to update HBA can_queue value if the current
max FW commands is equal to earlier value.
Signed-off-by: Kashyap Desai <[email protected]>
Signed-off-by: Shivasharan S <[email protected]>
Reviewed-by: Hannes Reinecke <[email protected]>
Reviewed-by: Tomas Henzl <[email protected]>
Signed-off-by: Martin K. Petersen <[email protected]>
|
|
Since maximum supported FW commands are all defined as u16, change
all local variables referring to max_cmd from u32 to u16.
Signed-off-by: Kashyap Desai <[email protected]>
Signed-off-by: Shivasharan S <[email protected]>
Reviewed-by: Hannes Reinecke <[email protected]>
Reviewed-by: Tomas Henzl <[email protected]>
Signed-off-by: Martin K. Petersen <[email protected]>
|
|
pDevHandle to MR_DEVHANDLE_INVALID
Issue is limited for Syncro firmware where pd_after_lb is not set but is
accidentally used. Not a functional issue, but results in low
performance due to improper load balancing between two LUNs.
Signed-off-by: Kashyap Desai <[email protected]>
Signed-off-by: Shivasharan S <[email protected]>
Reviewed-by: Hannes Reinecke <[email protected]>
Reviewed-by: Tomas Henzl <[email protected]>
Signed-off-by: Martin K. Petersen <[email protected]>
|
|
shutdown DCMD
Fetch the latest controller OCR capability from FW before sending
MR_DCMD_CTRL_SHUTDOWN When application sends a shutdown DCMD
(MR_DCMD_CTRL_SHUTDOWN), driver will fetch latest controller information
from firmware. This is to ensure that driver always has latest OCR
capability of controller before sending the DCMD.
Signed-off-by: Kashyap Desai <[email protected]>
Signed-off-by: Shivasharan S <[email protected]>
Reviewed-by: Hannes Reinecke <[email protected]>
Reviewed-by: Tomas Henzl <[email protected]>
Signed-off-by: Martin K. Petersen <[email protected]>
|
|
Fix kernel warning for accessing unaligned memory access in driver.
Signed-off-by: Shivasharan S <[email protected]>
Signed-off-by: Kashyap Desai <[email protected]>
Reviewed-by: Hannes Reinecke <[email protected]>
Reviewed-by: Tomas Henzl <[email protected]>
Signed-off-by: Martin K. Petersen <[email protected]>
|
|
Fix endiannes fixes for Ventura specific.
Signed-off-by: Shivasharan S <[email protected]>
Signed-off-by: Kashyap Desai <[email protected]>
Reviewed-by: Hannes Reinecke <[email protected]>
Reviewed-by: Tomas Henzl <[email protected]>
Signed-off-by: Martin K. Petersen <[email protected]>
|
|
Fix if RDPQ mode enabled MR FW is deployed on big endian host machine,
driver does not setup reply address correctly.
Signed-off-by: Shivasharan S <[email protected]>
Signed-off-by: Kashyap Desai <[email protected]>
Reviewed-by: Hannes Reinecke <[email protected]>
Reviewed-by: Tomas Henzl <[email protected]>
Signed-off-by: Martin K. Petersen <[email protected]>
|
|
access
Change MR_TargetIdToLdGet return type from u8 to u16.
ld id range check is added at two places in this patch -
@megasas_build_ldio_fusion and @megasas_build_ld_nonrw_fusion. Previous
driver code used different data type for lds TargetId returned from
MR_TargetIdToLdGet. Prior to this change, above two functions was
safeguarded due to function always return u8 and maximum value of ld id
returned was 255.
In below check, fw_supported_vd_count as of today is 64 or 256 and valid
range to support is either 0-63 or 0-255. Ideally want to filter
accessing raid map for ld ids which are not valid. With the u16 change,
invalid ld id value is 0xFFFF and we will see kernel panic due to random
memory access in MR_LdRaidGet. The changes will ensure we do not call
MR_LdRaidGet if ld id is beyond size of ldSpanMap array.
if (ld < instance->fw_supported_vd_count)
>From firmware perspective,ld id 0xFF is invalid and even though current
driver code forward such command, firmware fails with target not
available.
ld target id issue occurs mainly whenever driver loops to populate raid
map (ea. MR_ValidateMapInfo). These are the only two places where we
may see out of range target ids and wants to protect raid map access
based on range provided by Firmware API.
Signed-off-by: Shivasharan S <[email protected]>
Signed-off-by: Kashyap Desai <[email protected]>
Reviewed-by: Tomas Henzl <[email protected]>
Signed-off-by: Martin K. Petersen <[email protected]>
|
|
to cpu format for all lds
On a host, if an ld is deleted there is a hole in the ld array returned
by the FW. But in MR_ValidateMapInfo we are not accounting for holes in
the ld array and traverse only upto index num_lds. This patch takes
care of converting the capability field of all the valid lds in the ld
raid map.
Signed-off-by: Shivasharan S <[email protected]>
Signed-off-by: Kashyap Desai <[email protected]>
Reviewed-by: Hannes Reinecke <[email protected]>
Reviewed-by: Tomas Henzl <[email protected]>
Signed-off-by: Martin K. Petersen <[email protected]>
|
|
fails
Currently fusion context has fixed array load_balance_info. Use dynamic
allocation. In few places, driver do not want physically contigious
memory. Attempt to use vmalloc if physical contiguous memory is not
available.
Signed-off-by: Shivasharan S <[email protected]>
Signed-off-by: Kashyap Desai <[email protected]>
Reviewed-by: Hannes Reinecke <[email protected]>
Reviewed-by: Tomas Henzl <[email protected]>
Signed-off-by: Martin K. Petersen <[email protected]>
|
|
Signed-off-by: Shivasharan S <[email protected]>
Signed-off-by: Kashyap Desai <[email protected]>
Reviewed-by: Hannes Reinecke <[email protected]>
Reviewed-by: Tomas Henzl <[email protected]>
Signed-off-by: Martin K. Petersen <[email protected]>
|
|
Add additional logging from driver in OCR context.
Add debug logs for partial completion of IOs is iodone context.
Signed-off-by: Shivasharan S <[email protected]>
Signed-off-by: Kashyap Desai <[email protected]>
Reviewed-by: Hannes Reinecke <[email protected]>
Reviewed-by: Tomas Henzl <[email protected]>
Signed-off-by: Martin K. Petersen <[email protected]>
|
|
Fixing issue of not setting residual bytes correctly.
Signed-off-by: Shivasharan S <[email protected]>
Signed-off-by: Kashyap Desai <[email protected]>
Reviewed-by: Hannes Reinecke <[email protected]>
Reviewed-by: Tomas Henzl <[email protected]>
Signed-off-by: Martin K. Petersen <[email protected]>
|
|
Avoid Host side PCI bandwidth bottleneck and hint FW to do Write
buffering using RaidFlag MR_RAID_FLAGS_IO_SUB_TYPE_LDIO_BW_LIMIT. Once
IO is landed in FW with MR_RAID_FLAGS_IO_SUB_TYPE_LDIO_BW_LIMIT, it will
do single DMA from host and buffer the Write operation. On back end, FW
will DMA same buffer to the Mirror and Data Arm. This will improve
large block IO performance which bottleneck due to Host side PCI
bandwidth limitation.
Consistent ~4000MB T.P for 256K Block size is expected performance
numbers. IOPS for small Block size should be on par with Disk
performance. (E.g 42 SAS Disk in JBOD mode gives 3700MB T.P. Same
Drive used in R1 WT mode, should give ~1800MB T.P)
Using this patch 24 R1 VDs (HDD) gives below performance for Sequential
Write. Without this patch, we cannot reach above 3200MB (Throughput is
in MB.)
Block Size 50% 256K and 50% 4K 100% 256K
4K 3100 2030
8K 3140 2740
16K 3140 3140
32K 3400 3240
64K 3500 3700
128K 3870 3870
256K 3920 3920
Signed-off-by: Shivasharan S <[email protected]>
Signed-off-by: Kashyap Desai <[email protected]>
Reviewed-by: Hannes Reinecke <[email protected]>
Reviewed-by: Tomas Henzl <[email protected]>
Signed-off-by: Martin K. Petersen <[email protected]>
|
|
This patch provide true fast path IO support. Driver creates PRP for
NVME drives and send Fast Path for performance. Certain h/w requirement
needs to be taken care in driver.
Signed-off-by: Shivasharan S <[email protected]>
Signed-off-by: Kashyap Desai <[email protected]>
Reviewed-by: Hannes Reinecke <[email protected]>
Reviewed-by: Tomas Henzl <[email protected]>
Signed-off-by: Martin K. Petersen <[email protected]>
|
|
This patch fetch true values of NVME property from FW using New DCMD
interface MR_DCMD_DEV_GET_TARGET_PROP
Signed-off-by: Shivasharan S <[email protected]>
Signed-off-by: Kashyap Desai <[email protected]>
Reviewed-by: Hannes Reinecke <[email protected]>
Reviewed-by: Tomas Henzl <[email protected]>
Signed-off-by: Martin K. Petersen <[email protected]>
|
|
Adding detection logic for NVME device attached behind Ventura
controller. Driver set HostPageSize in IOC_INIT frame to inform about
page size for NVME devices. Firmware reports NVME page size to the
driver. PD INFO DCMD provide new interface type NVME_PD. Driver set
property of NVME device.
Signed-off-by: Shivasharan S <[email protected]>
Signed-off-by: Kashyap Desai <[email protected]>
Reviewed-by: Hannes Reinecke <[email protected]>
Reviewed-by: Tomas Henzl <[email protected]>
Signed-off-by: Martin K. Petersen <[email protected]>
|
|
With the changes to remove checks for a valid request descriptor,
issue_dcmd will now always return DCMD_SUCCESS. This patch changes
return type of issue_dcmd to void and change all callers appropriately.
Signed-off-by: Shivasharan S <[email protected]>
Signed-off-by: Kashyap Desai <[email protected]>
Reviewed-by: Hannes Reinecke <[email protected]>
Reviewed-by: Tomas Henzl <[email protected]>
Signed-off-by: Martin K. Petersen <[email protected]>
|
|
No functional change. Code clean up. Removing error code which is not
valid scenario. In megasas_get_request_descriptor we can remove the
error handling which is not required. With fusion controllers, if there
is a valid message frame available, we are guaranteed to get a
corresponding request descriptor.
Signed-off-by: Shivasharan S <[email protected]>
Signed-off-by: Kashyap Desai <[email protected]>
Reviewed-by: Hannes Reinecke <[email protected]>
Reviewed-by: Tomas Henzl <[email protected]>
Signed-off-by: Martin K. Petersen <[email protected]>
|
|
Moving to use DID_REQUEUE return type for reliable unconditional
retries. Driver wants unconditional re-queue, so replace DID_RESET with
DID_REQUEUE
Discussed below -
https://www.spinics.net/lists/linux-scsi/msg102848.html
Signed-off-by: Shivasharan S <[email protected]>
Signed-off-by: Kashyap Desai <[email protected]>
Reviewed-by: Hannes Reinecke <[email protected]>
Reviewed-by: Tomas Henzl <[email protected]>
Signed-off-by: Martin K. Petersen <[email protected]>
|
|
is not set
Signed-off-by: Shivasharan S <[email protected]>
Signed-off-by: Kashyap Desai <[email protected]>
Reviewed-by: Hannes Reinecke <[email protected]>
Reviewed-by: Tomas Henzl <[email protected]>
Signed-off-by: Martin K. Petersen <[email protected]>
|
|
Signed-off-by: Shivasharan S <[email protected]>
Signed-off-by: Kashyap Desai <[email protected]>
Reviewed-by: Hannes Reinecke <[email protected]>
Reviewed-by: Tomas Henzl <[email protected]>
Signed-off-by: Martin K. Petersen <[email protected]>
|
|
No functional change. Code refactor.
megasas_fire_cmd_fusion can always use 32 bit descriptor write for
ventura. No need to pass extra flag. Only IOC INIT required 64 bit
Descriptor write.
Signed-off-by: Shivasharan S <[email protected]>
Signed-off-by: Kashyap Desai <[email protected]>
Reviewed-by: Tomas Henzl <[email protected]>
Reviewed-by: Hannes Reinecke <[email protected]>
Signed-off-by: Martin K. Petersen <[email protected]>
|
|
No functional change. Code refactor.
Remove function megasas_fpio_to_ldio as we never require to convert fpio
to ldio because of frame unavailability. Grab extra frame of raid 1
write fast path before it creates first frame as Fast Path. Removed
is_raid_1_fp_write flag as raid 1 write fast path command is decided
using r1_alt_dev_handle only. Move resetting megasas_cmd_fusion fields
at common function megasas_return_cmd_fusion.
Signed-off-by: Shivasharan S <[email protected]>
Signed-off-by: Kashyap Desai <[email protected]>
Reviewed-by: Hannes Reinecke <[email protected]>
Reviewed-by: Tomas Henzl <[email protected]>
Signed-off-by: Martin K. Petersen <[email protected]>
|
|
No functional change. Code refactor.
Signed-off-by: Shivasharan S <[email protected]>
Signed-off-by: Kashyap Desai <[email protected]>
Reviewed-by: Hannes Reinecke <[email protected]>
Reviewed-by: Tomas Henzl <[email protected]>
Signed-off-by: Martin K. Petersen <[email protected]>
|
|
Threshold Bandwidth"
This reverts commit "3e5eadb1a881" ("scsi: megaraid_sas: Enable or
Disable Fast path based on the PCI Threshold Bandwidth")
This patch was aimed to increase performance of R1 Write operation for
large IO size. Since this method used timer approach, it turn on/off
fast path did not work as expected. Patch 0013 describes new algorithm
and performance number.
Signed-off-by: Shivasharan S <[email protected]>
Signed-off-by: Kashyap Desai <[email protected]>
Reviewed-by: Hannes Reinecke <[email protected]>
Reviewed-by: Tomas Henzl <[email protected]>
Signed-off-by: Martin K. Petersen <[email protected]>
|
|
Instead of masking and setting two bits in the "flags" field
for the mmc_queue, just use two bools named "suspended" and
"new_request".
The masking and setting would likely have race conditions
anyways, it is better to use a simple member like this.
Signed-off-by: Linus Walleij <[email protected]>
Signed-off-by: Ulf Hansson <[email protected]>
|
|
The mmc_active member of struct mmc_queue_req has a very
confusing name: this is certainly not always "active", it is
the asynchronous request associated by the mmc_queue_req
but it is not guaranteed to be "active" in any sense, such
as being running on the host.
Simply rename this member to "areq".
Signed-off-by: Linus Walleij <[email protected]>
Signed-off-by: Ulf Hansson <[email protected]>
|
|
The mmc_blk_rw_start_new() was named after the label inside
mmc_blk_issue_rw_rq() but is really a confusing name for this
function: what it does is to try to restart the latest issued
command on the host and card of the current MMC queue.
So rename it mmc_blk_rw_try_restart() that reflects what it
is doing and at this point also refactore the function to
treat the removed card as an exception and just exit if this
happens and run on in the function if that is not happening.
Signed-off-by: Linus Walleij <[email protected]>
Signed-off-by: Ulf Hansson <[email protected]>
|
|
With the coexisting __mmc_start_request(), mmc_start_request()
and __mmc_start_req() it is a bit confusing that mmc_start_req()
actually does not start a normal request, but an asynchronous
request.
Rename it to mmc_start_areq() to make it explicit what the
function is doing, also fix the kerneldoc for this function
while we're at it.
Signed-off-by: Linus Walleij <[email protected]>
Signed-off-by: Ulf Hansson <[email protected]>
|
|
In the function mmc_blk_issue_rw_rq() the new request coming in
from the block layer is called "rqc" and the old request that
was potentially just returned back from the asynchronous
mechanism is called "req".
This is really confusing when trying to analyze and understand
the code, it becomes a perceptual nightmare to me. Maybe others
have better parserheads but it is not working for me.
Rename "rqc" to "new_req" and "req" to "old_req" to reflect what
is semantically going on into the syntax.
Signed-off-by: Linus Walleij <[email protected]>
Signed-off-by: Ulf Hansson <[email protected]>
|
|
The goto statements sprinkled over the mmc_blk_issue_rw_rq()
function has grown over the years and makes the code pretty hard
to read.
Inline the calls such that:
goto cmd_abort; ->
mmc_blk_rw_cmd_abort(card, req);
mmc_blk_rw_start_new(mq, card, rqc);
return;
goto start_new_req; ->
mmc_blk_rw_start_new(mq, card, rqc);
return;
After this it is more clear how we exit the do {} while
loop in this function, and it gets possible to split the
code apart.
Signed-off-by: Linus Walleij <[email protected]>
Signed-off-by: Ulf Hansson <[email protected]>
|
|
ida code in block.c can be significantly simplified by switching to
the ida_simple_ functions.
Signed-off-by: Heiner Kallweit <[email protected]>
Signed-off-by: Ulf Hansson <[email protected]>
|
|
Fixes: a45c6cb81647 ("[ARM] 5369/1: omap mmc: Add new omap
hsmmc controller for 2430 and 34xx, v3")
when using really large timeout (up to 4*60*1000 ms for bkops)
there is a possibility of data overflow using
unsigned int so use 64 bit unsigned long long.
Signed-off-by: Ravikumar Kattekola <[email protected]>
Signed-off-by: Sekhar Nori <[email protected]>
Signed-off-by: Ulf Hansson <[email protected]>
|
|
commit e2bf08d643a244ccb ("omap_hsmmc: set a large data timeout for
commands with busy signal") sets an arbitrary timeout value (100ms) for
commands like CMD6 (MMC SWITCH). However extended CSD register defined
in the eMMC standard has a field for GENERIC_CMD6_TIME which indicates
the default maximum timeout for a SWITCH command.
Use busy_timeout of cmd structure (populated with GENERIC_CMD6_TIME
in the case of SWITCH command) to program the data timeout value in
omap_hsmmc driver.
SWITCH command to turn the cache on took more than 100ms to complete
with MICRON eMMC card present in AM572x IDK REV 1.3A resulting in
timeout and failed enumeration. It is fixed here by programming the
timeout with the value advertised in GENERIC_CMD6_TIME.
Signed-off-by: Kishon Vijay Abraham I <[email protected]>
Signed-off-by: Sekhar Nori <[email protected]>
Signed-off-by: Ravikumar Kattekola <[email protected]>
Signed-off-by: Ulf Hansson <[email protected]>
|
|
When CEB (command end bit error) occurs
reset CMD line to avoid system ending up in
erroneous state.
While command line is reset for CTO and CCRC errors,
it's not done for CEB error. Fix it here.
Reviewed-by: Kishon Vijay Abraham I <[email protected]>
Signed-off-by: Ravikumar Kattekola <[email protected]>
Signed-off-by: Sekhar Nori <[email protected]>
Signed-off-by: Ulf Hansson <[email protected]>
|
|
We introduced recently a new compatible to deal with the A64 eMMC
controller, let's document its binding.
Signed-off-by: Maxime Ripard <[email protected]>
Acked-by: Chen-Yu Tsai <[email protected]>
Acked-by: Rob Herring <[email protected]>
Signed-off-by: Ulf Hansson <[email protected]>
|