From: Greg Kroah-Hartman Date: Fri, 7 Aug 2020 11:10:29 +0000 (+0200) Subject: 5.7-stable patches X-Git-Tag: v4.19.139~37 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=d3da171c6b53bf93b6d880f4cd69c1696cef4862;p=thirdparty%2Fkernel%2Fstable-queue.git 5.7-stable patches added patches: scsi-ufs-fix-and-simplify-setup_xfer_req-variant-operation.patch usb-serial-qcserial-add-em7305-qdl-product-id.patch --- diff --git a/queue-5.7/scsi-ufs-fix-and-simplify-setup_xfer_req-variant-operation.patch b/queue-5.7/scsi-ufs-fix-and-simplify-setup_xfer_req-variant-operation.patch new file mode 100644 index 00000000000..3693412c2f1 --- /dev/null +++ b/queue-5.7/scsi-ufs-fix-and-simplify-setup_xfer_req-variant-operation.patch @@ -0,0 +1,55 @@ +From 6edfdcfe285e499994b94a0f93e1f46ab2398162 Mon Sep 17 00:00:00 2001 +From: Stanley Chu +Date: Mon, 6 Jul 2020 14:07:07 +0800 +Subject: scsi: ufs: Fix and simplify setup_xfer_req variant operation + +From: Stanley Chu + +commit 6edfdcfe285e499994b94a0f93e1f46ab2398162 upstream. + +Add missing setup_xfer_req() call in ufshcd_issue_devman_upiu_cmd() in +ufs-bsg path. Relocate existing setup_xfer_req() calls to a common place, +i.e., ufshcd_send_command(), to simplify the driver. + +Link: https://lore.kernel.org/r/20200706060707.32608-3-stanley.chu@mediatek.com +Acked-by: Avri Altman +Signed-off-by: Stanley Chu +Signed-off-by: Martin K. Petersen +Signed-off-by: Greg Kroah-Hartman + +--- + drivers/scsi/ufs/ufshcd.c | 9 +++++---- + 1 file changed, 5 insertions(+), 4 deletions(-) + +--- a/drivers/scsi/ufs/ufshcd.c ++++ b/drivers/scsi/ufs/ufshcd.c +@@ -1908,8 +1908,11 @@ static void ufshcd_clk_scaling_update_bu + static inline + void ufshcd_send_command(struct ufs_hba *hba, unsigned int task_tag) + { +- hba->lrb[task_tag].issue_time_stamp = ktime_get(); +- hba->lrb[task_tag].compl_time_stamp = ktime_set(0, 0); ++ struct ufshcd_lrb *lrbp = &hba->lrb[task_tag]; ++ ++ lrbp->issue_time_stamp = ktime_get(); ++ lrbp->compl_time_stamp = ktime_set(0, 0); ++ ufshcd_vops_setup_xfer_req(hba, task_tag, (lrbp->cmd ? true : false)); + ufshcd_add_command_trace(hba, task_tag, "send"); + ufshcd_clk_scaling_start_busy(hba); + __set_bit(task_tag, &hba->outstanding_reqs); +@@ -2519,7 +2522,6 @@ static int ufshcd_queuecommand(struct Sc + + /* issue command to the controller */ + spin_lock_irqsave(hba->host->host_lock, flags); +- ufshcd_vops_setup_xfer_req(hba, tag, true); + ufshcd_send_command(hba, tag); + out_unlock: + spin_unlock_irqrestore(hba->host->host_lock, flags); +@@ -2706,7 +2708,6 @@ static int ufshcd_exec_dev_cmd(struct uf + /* Make sure descriptors are ready before ringing the doorbell */ + wmb(); + spin_lock_irqsave(hba->host->host_lock, flags); +- ufshcd_vops_setup_xfer_req(hba, tag, false); + ufshcd_send_command(hba, tag); + spin_unlock_irqrestore(hba->host->host_lock, flags); + diff --git a/queue-5.7/usb-serial-qcserial-add-em7305-qdl-product-id.patch b/queue-5.7/usb-serial-qcserial-add-em7305-qdl-product-id.patch new file mode 100644 index 00000000000..09916194c9a --- /dev/null +++ b/queue-5.7/usb-serial-qcserial-add-em7305-qdl-product-id.patch @@ -0,0 +1,44 @@ +From d2a4309c1ab6df424b2239fe2920d6f26f808d17 Mon Sep 17 00:00:00 2001 +From: Erik Ekman +Date: Fri, 17 Jul 2020 20:51:18 +0200 +Subject: USB: serial: qcserial: add EM7305 QDL product ID + +From: Erik Ekman + +commit d2a4309c1ab6df424b2239fe2920d6f26f808d17 upstream. + +When running qmi-firmware-update on the Sierra Wireless EM7305 in a Toshiba +laptop, it changed product ID to 0x9062 when entering QDL mode: + +usb 2-4: new high-speed USB device number 78 using xhci_hcd +usb 2-4: New USB device found, idVendor=1199, idProduct=9062, bcdDevice= 0.00 +usb 2-4: New USB device strings: Mfr=1, Product=2, SerialNumber=0 +usb 2-4: Product: EM7305 +usb 2-4: Manufacturer: Sierra Wireless, Incorporated + +The upgrade could complete after running + # echo 1199 9062 > /sys/bus/usb-serial/drivers/qcserial/new_id + +qcserial 2-4:1.0: Qualcomm USB modem converter detected +usb 2-4: Qualcomm USB modem converter now attached to ttyUSB0 + +Signed-off-by: Erik Ekman +Link: https://lore.kernel.org/r/20200717185118.3640219-1-erik@kryo.se +Cc: stable@vger.kernel.org +Signed-off-by: Johan Hovold +Signed-off-by: Greg Kroah-Hartman + +--- + drivers/usb/serial/qcserial.c | 1 + + 1 file changed, 1 insertion(+) + +--- a/drivers/usb/serial/qcserial.c ++++ b/drivers/usb/serial/qcserial.c +@@ -155,6 +155,7 @@ static const struct usb_device_id id_tab + {DEVICE_SWI(0x1199, 0x9056)}, /* Sierra Wireless Modem */ + {DEVICE_SWI(0x1199, 0x9060)}, /* Sierra Wireless Modem */ + {DEVICE_SWI(0x1199, 0x9061)}, /* Sierra Wireless Modem */ ++ {DEVICE_SWI(0x1199, 0x9062)}, /* Sierra Wireless EM7305 QDL */ + {DEVICE_SWI(0x1199, 0x9063)}, /* Sierra Wireless EM7305 */ + {DEVICE_SWI(0x1199, 0x9070)}, /* Sierra Wireless MC74xx */ + {DEVICE_SWI(0x1199, 0x9071)}, /* Sierra Wireless MC74xx */