You've already forked linux-rockchip
mirror of
https://github.com/armbian/linux-rockchip.git
synced 2026-01-06 11:08:10 -08:00
scsi: ufs: Optimize host lock on transfer requests send/compl paths
Current UFS IRQ handler is completely wrapped by host lock, and because ufshcd_send_command() is also protected by host lock, when IRQ handler fires, not only the CPU running the IRQ handler cannot send new requests, the rest CPUs can neither. Move the host lock wrapping the IRQ handler into specific branches, i.e., ufshcd_uic_cmd_compl(), ufshcd_check_errors(), ufshcd_tmc_handler() and ufshcd_transfer_req_compl(). Meanwhile, to further reduce occpuation of host lock in ufshcd_transfer_req_compl(), host lock is no longer required to call __ufshcd_transfer_req_compl(). As per test, the optimization can bring considerable gain to random read/write performance. Link: https://lore.kernel.org/r/1621845419-14194-3-git-send-email-cang@codeaurora.org Cc: Stanley Chu <stanley.chu@mediatek.com> Reported-by: kernel test robot <lkp@intel.com> Reviewed-by: Bean Huo <beanhuo@micron.com> Reviewed-by: Stanley Chu <stanley.chu@mediatek.com> Co-developed-by: Asutosh Das <asutoshd@codeaurora.org> Signed-off-by: Asutosh Das <asutoshd@codeaurora.org> Signed-off-by: Can Guo <cang@codeaurora.org> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
This commit is contained in:
committed by
Martin K. Petersen
parent
1cca0c3fdc
commit
a45f937110
File diff suppressed because it is too large
Load Diff
@@ -193,7 +193,6 @@ struct ufs_pm_lvl_states {
|
||||
* @crypto_key_slot: the key slot to use for inline crypto (-1 if none)
|
||||
* @data_unit_num: the data unit number for the first block for inline crypto
|
||||
* @req_abort_skip: skip request abort task flag
|
||||
* @in_use: indicates that this lrb is still in use
|
||||
*/
|
||||
struct ufshcd_lrb {
|
||||
struct utp_transfer_req_desc *utr_descriptor_ptr;
|
||||
@@ -223,7 +222,6 @@ struct ufshcd_lrb {
|
||||
#endif
|
||||
|
||||
bool req_abort_skip;
|
||||
bool in_use;
|
||||
};
|
||||
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user