--- /dev/null
+From ebe9f6f19d80d8978d16078dff3d5bd93ad8d102 Mon Sep 17 00:00:00 2001
+From: Dan Williams <dan.j.williams@intel.com>
+Date: Thu, 7 Feb 2019 14:56:50 -0800
+Subject: acpi/nfit: Fix bus command validation
+
+From: Dan Williams <dan.j.williams@intel.com>
+
+commit ebe9f6f19d80d8978d16078dff3d5bd93ad8d102 upstream.
+
+Commit 11189c1089da "acpi/nfit: Fix command-supported detection" broke
+ND_CMD_CALL for bus-level commands. The "func = cmd" assumption is only
+valid for:
+
+ ND_CMD_ARS_CAP
+ ND_CMD_ARS_START
+ ND_CMD_ARS_STATUS
+ ND_CMD_CLEAR_ERROR
+
+The function number otherwise needs to be pulled from the command
+payload for:
+
+ NFIT_CMD_TRANSLATE_SPA
+ NFIT_CMD_ARS_INJECT_SET
+ NFIT_CMD_ARS_INJECT_CLEAR
+ NFIT_CMD_ARS_INJECT_GET
+
+Update cmd_to_func() for the bus case and call it in the common path.
+
+Fixes: 11189c1089da ("acpi/nfit: Fix command-supported detection")
+Cc: <stable@vger.kernel.org>
+Reviewed-by: Vishal Verma <vishal.l.verma@intel.com>
+Reported-by: Grzegorz Burzynski <grzegorz.burzynski@intel.com>
+Tested-by: Jeff Moyer <jmoyer@redhat.com>
+Signed-off-by: Dan Williams <dan.j.williams@intel.com>
+Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+
+
+---
+ drivers/acpi/nfit/core.c | 24 +++++++++++++-----------
+ 1 file changed, 13 insertions(+), 11 deletions(-)
+
+--- a/drivers/acpi/nfit/core.c
++++ b/drivers/acpi/nfit/core.c
+@@ -214,7 +214,7 @@ static int cmd_to_func(struct nfit_mem *
+ if (call_pkg) {
+ int i;
+
+- if (nfit_mem->family != call_pkg->nd_family)
++ if (nfit_mem && nfit_mem->family != call_pkg->nd_family)
+ return -ENOTTY;
+
+ for (i = 0; i < ARRAY_SIZE(call_pkg->nd_reserved2); i++)
+@@ -223,6 +223,10 @@ static int cmd_to_func(struct nfit_mem *
+ return call_pkg->nd_command;
+ }
+
++ /* In the !call_pkg case, bus commands == bus functions */
++ if (!nfit_mem)
++ return cmd;
++
+ /* Linux ND commands == NVDIMM_FAMILY_INTEL function numbers */
+ if (nfit_mem->family == NVDIMM_FAMILY_INTEL)
+ return cmd;
+@@ -238,6 +242,7 @@ int acpi_nfit_ctl(struct nvdimm_bus_desc
+ unsigned int cmd, void *buf, unsigned int buf_len, int *cmd_rc)
+ {
+ struct acpi_nfit_desc *acpi_desc = to_acpi_nfit_desc(nd_desc);
++ struct nfit_mem *nfit_mem = nvdimm_provider_data(nvdimm);
+ union acpi_object in_obj, in_buf, *out_obj;
+ const struct nd_cmd_desc *desc = NULL;
+ struct device *dev = acpi_desc->dev;
+@@ -252,18 +257,18 @@ int acpi_nfit_ctl(struct nvdimm_bus_desc
+ if (cmd_rc)
+ *cmd_rc = -EINVAL;
+
++ if (cmd == ND_CMD_CALL)
++ call_pkg = buf;
++ func = cmd_to_func(nfit_mem, cmd, call_pkg);
++ if (func < 0)
++ return func;
++
+ if (nvdimm) {
+- struct nfit_mem *nfit_mem = nvdimm_provider_data(nvdimm);
+ struct acpi_device *adev = nfit_mem->adev;
+
+ if (!adev)
+ return -ENOTTY;
+
+- if (cmd == ND_CMD_CALL)
+- call_pkg = buf;
+- func = cmd_to_func(nfit_mem, cmd, call_pkg);
+- if (func < 0)
+- return func;
+ dimm_name = nvdimm_name(nvdimm);
+ cmd_name = nvdimm_cmd_name(cmd);
+ cmd_mask = nvdimm_cmd_mask(nvdimm);
+@@ -274,12 +279,9 @@ int acpi_nfit_ctl(struct nvdimm_bus_desc
+ } else {
+ struct acpi_device *adev = to_acpi_dev(acpi_desc);
+
+- func = cmd;
+ cmd_name = nvdimm_bus_cmd_name(cmd);
+ cmd_mask = nd_desc->cmd_mask;
+- dsm_mask = cmd_mask;
+- if (cmd == ND_CMD_CALL)
+- dsm_mask = nd_desc->bus_dsm_mask;
++ dsm_mask = nd_desc->bus_dsm_mask;
+ desc = nd_cmd_bus_desc(cmd);
+ guid = to_nfit_uuid(NFIT_DEV_BUS);
+ handle = adev->handle;
--- /dev/null
+From 61cf61d81e326163ce1557ceccfca76e11d0e57c Mon Sep 17 00:00:00 2001
+From: Arun KS <arunks@codeaurora.org>
+Date: Tue, 30 Apr 2019 16:05:04 +0530
+Subject: arm64: Fix size of __early_cpu_boot_status
+
+From: Arun KS <arunks@codeaurora.org>
+
+commit 61cf61d81e326163ce1557ceccfca76e11d0e57c upstream.
+
+__early_cpu_boot_status is of type long. Use quad
+assembler directive to allocate proper size.
+
+Acked-by: Mark Rutland <mark.rutland@arm.com>
+Signed-off-by: Arun KS <arunks@codeaurora.org>
+Signed-off-by: Will Deacon <will.deacon@arm.com>
+Signed-off-by: Lee Jones <lee.jones@linaro.org>
+Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+
+---
+ arch/arm64/kernel/head.S | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+--- a/arch/arm64/kernel/head.S
++++ b/arch/arm64/kernel/head.S
+@@ -558,7 +558,7 @@ ENTRY(__boot_cpu_mode)
+ * with MMU turned off.
+ */
+ ENTRY(__early_cpu_boot_status)
+- .long 0
++ .quad 0
+
+ .popsection
+
--- /dev/null
+From 21ea4b62e1f3dc258001a68da98c9663a9dbd6c7 Mon Sep 17 00:00:00 2001
+From: Taniya Das <tdas@codeaurora.org>
+Date: Wed, 8 May 2019 23:54:53 +0530
+Subject: clk: qcom: rcg: Return failure for RCG update
+
+From: Taniya Das <tdas@codeaurora.org>
+
+commit 21ea4b62e1f3dc258001a68da98c9663a9dbd6c7 upstream.
+
+In case of update config failure, return -EBUSY, so that consumers could
+handle the failure gracefully.
+
+Signed-off-by: Taniya Das <tdas@codeaurora.org>
+Link: https://lkml.kernel.org/r/1557339895-21952-2-git-send-email-tdas@codeaurora.org
+Signed-off-by: Stephen Boyd <sboyd@kernel.org>
+Signed-off-by: Lee Jones <lee.jones@linaro.org>
+Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+
+---
+ drivers/clk/qcom/clk-rcg2.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+--- a/drivers/clk/qcom/clk-rcg2.c
++++ b/drivers/clk/qcom/clk-rcg2.c
+@@ -112,7 +112,7 @@ static int update_config(struct clk_rcg2
+ }
+
+ WARN(1, "%s: rcg didn't update its configuration.", name);
+- return 0;
++ return -EBUSY;
+ }
+
+ static int clk_rcg2_set_parent(struct clk_hw *hw, u8 index)
--- /dev/null
+From 0036bc73ccbe7e600a3468bf8e8879b122252274 Mon Sep 17 00:00:00 2001
+From: Rob Clark <robdclark@chromium.org>
+Date: Sun, 30 Jun 2019 05:47:22 -0700
+Subject: drm/msm: stop abusing dma_map/unmap for cache
+
+From: Rob Clark <robdclark@chromium.org>
+
+commit 0036bc73ccbe7e600a3468bf8e8879b122252274 upstream.
+
+Recently splats like this started showing up:
+
+ WARNING: CPU: 4 PID: 251 at drivers/iommu/dma-iommu.c:451 __iommu_dma_unmap+0xb8/0xc0
+ Modules linked in: ath10k_snoc ath10k_core fuse msm ath mac80211 uvcvideo cfg80211 videobuf2_vmalloc videobuf2_memops vide
+ CPU: 4 PID: 251 Comm: kworker/u16:4 Tainted: G W 5.2.0-rc5-next-20190619+ #2317
+ Hardware name: LENOVO 81JL/LNVNB161216, BIOS 9UCN23WW(V1.06) 10/25/2018
+ Workqueue: msm msm_gem_free_work [msm]
+ pstate: 80c00005 (Nzcv daif +PAN +UAO)
+ pc : __iommu_dma_unmap+0xb8/0xc0
+ lr : __iommu_dma_unmap+0x54/0xc0
+ sp : ffff0000119abce0
+ x29: ffff0000119abce0 x28: 0000000000000000
+ x27: ffff8001f9946648 x26: ffff8001ec271068
+ x25: 0000000000000000 x24: ffff8001ea3580a8
+ x23: ffff8001f95ba010 x22: ffff80018e83ba88
+ x21: ffff8001e548f000 x20: fffffffffffff000
+ x19: 0000000000001000 x18: 00000000c00001fe
+ x17: 0000000000000000 x16: 0000000000000000
+ x15: ffff000015b70068 x14: 0000000000000005
+ x13: 0003142cc1be1768 x12: 0000000000000001
+ x11: ffff8001f6de9100 x10: 0000000000000009
+ x9 : ffff000015b78000 x8 : 0000000000000000
+ x7 : 0000000000000001 x6 : fffffffffffff000
+ x5 : 0000000000000fff x4 : ffff00001065dbc8
+ x3 : 000000000000000d x2 : 0000000000001000
+ x1 : fffffffffffff000 x0 : 0000000000000000
+ Call trace:
+ __iommu_dma_unmap+0xb8/0xc0
+ iommu_dma_unmap_sg+0x98/0xb8
+ put_pages+0x5c/0xf0 [msm]
+ msm_gem_free_work+0x10c/0x150 [msm]
+ process_one_work+0x1e0/0x330
+ worker_thread+0x40/0x438
+ kthread+0x12c/0x130
+ ret_from_fork+0x10/0x18
+ ---[ end trace afc0dc5ab81a06bf ]---
+
+Not quite sure what triggered that, but we really shouldn't be abusing
+dma_{map,unmap}_sg() for cache maint.
+
+Cc: Stephen Boyd <sboyd@kernel.org>
+Tested-by: Stephen Boyd <swboyd@chromium.org>
+Reviewed-by: Jordan Crouse <jcrouse@codeaurora.org>
+Signed-off-by: Rob Clark <robdclark@chromium.org>
+Signed-off-by: Sean Paul <seanpaul@chromium.org>
+Link: https://patchwork.freedesktop.org/patch/msgid/20190630124735.27786-1-robdclark@gmail.com
+Signed-off-by: Lee Jones <lee.jones@linaro.org>
+Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+
+---
+ drivers/gpu/drm/msm/msm_gem.c | 4 ++--
+ 1 file changed, 2 insertions(+), 2 deletions(-)
+
+--- a/drivers/gpu/drm/msm/msm_gem.c
++++ b/drivers/gpu/drm/msm/msm_gem.c
+@@ -108,7 +108,7 @@ static struct page **get_pages(struct dr
+ * because display controller, GPU, etc. are not coherent:
+ */
+ if (msm_obj->flags & (MSM_BO_WC|MSM_BO_UNCACHED))
+- dma_map_sg(dev->dev, msm_obj->sgt->sgl,
++ dma_sync_sg_for_device(dev->dev, msm_obj->sgt->sgl,
+ msm_obj->sgt->nents, DMA_BIDIRECTIONAL);
+ }
+
+@@ -138,7 +138,7 @@ static void put_pages(struct drm_gem_obj
+ * GPU, etc. are not coherent:
+ */
+ if (msm_obj->flags & (MSM_BO_WC|MSM_BO_UNCACHED))
+- dma_unmap_sg(obj->dev->dev, msm_obj->sgt->sgl,
++ dma_sync_sg_for_cpu(obj->dev->dev, msm_obj->sgt->sgl,
+ msm_obj->sgt->nents,
+ DMA_BIDIRECTIONAL);
+
--- /dev/null
+From a4c30a4861c54af78c4eb8b7855524c1a96d9f80 Mon Sep 17 00:00:00 2001
+From: Hans Verkuil <hans.verkuil@cisco.com>
+Date: Mon, 27 Aug 2018 10:07:42 +0200
+Subject: drm_dp_mst_topology: fix broken drm_dp_sideband_parse_remote_dpcd_read()
+
+From: Hans Verkuil <hans.verkuil@cisco.com>
+
+commit a4c30a4861c54af78c4eb8b7855524c1a96d9f80 upstream.
+
+When parsing the reply of a DP_REMOTE_DPCD_READ DPCD command the
+result is wrong due to a missing idx increment.
+
+This was never noticed since DP_REMOTE_DPCD_READ is currently not
+used, but if you enable it, then it is all wrong.
+
+Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
+Reviewed-by: Lyude Paul <lyude@redhat.com>
+Acked-by: Alex Deucher <alexander.deucher@amd.com>
+Link: https://patchwork.freedesktop.org/patch/msgid/e72ddac2-1dc0-100a-d816-9ac98ac009dd@xs4all.nl
+Signed-off-by: Lee Jones <lee.jones@linaro.org>
+Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+
+---
+ drivers/gpu/drm/drm_dp_mst_topology.c | 1 +
+ 1 file changed, 1 insertion(+)
+
+--- a/drivers/gpu/drm/drm_dp_mst_topology.c
++++ b/drivers/gpu/drm/drm_dp_mst_topology.c
+@@ -433,6 +433,7 @@ static bool drm_dp_sideband_parse_remote
+ if (idx > raw->curlen)
+ goto fail_len;
+ repmsg->u.remote_dpcd_read_ack.num_bytes = raw->msg[idx];
++ idx++;
+ if (idx > raw->curlen)
+ goto fail_len;
+
--- /dev/null
+From f0beb4ba9b185d497c8efe7b349363700092aee0 Mon Sep 17 00:00:00 2001
+From: Chris Lew <clew@codeaurora.org>
+Date: Fri, 27 Jul 2018 17:47:27 +0530
+Subject: rpmsg: glink: Remove chunk size word align warning
+
+From: Chris Lew <clew@codeaurora.org>
+
+commit f0beb4ba9b185d497c8efe7b349363700092aee0 upstream.
+
+It is possible for the chunk sizes coming from the non RPM remote procs
+to not be word aligned. Remove the alignment warning and continue to
+read from the FIFO so execution is not stalled.
+
+Signed-off-by: Chris Lew <clew@codeaurora.org>
+Signed-off-by: Arun Kumar Neelakantam <aneela@codeaurora.org>
+Signed-off-by: Bjorn Andersson <bjorn.andersson@linaro.org>
+Signed-off-by: Lee Jones <lee.jones@linaro.org>
+Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+
+---
+ drivers/rpmsg/qcom_glink_native.c | 3 ---
+ 1 file changed, 3 deletions(-)
+
+--- a/drivers/rpmsg/qcom_glink_native.c
++++ b/drivers/rpmsg/qcom_glink_native.c
+@@ -811,9 +811,6 @@ static int qcom_glink_rx_data(struct qco
+ return -EAGAIN;
+ }
+
+- if (WARN(chunk_size % 4, "Incoming data must be word aligned\n"))
+- return -EINVAL;
+-
+ rcid = le16_to_cpu(hdr.msg.param1);
+ spin_lock_irqsave(&glink->idr_lock, flags);
+ channel = idr_find(&glink->rcids, rcid);
bluetooth-rfcomm-fix-odebug-bug-in-rfcomm_dev_ioctl.patch
rdma-cm-update-num_paths-in-cma_resolve_iboe_route-error-flow.patch
fbcon-fix-null-ptr-deref-in-fbcon_switch.patch
+acpi-nfit-fix-bus-command-validation.patch
+clk-qcom-rcg-return-failure-for-rcg-update.patch
+drm-msm-stop-abusing-dma_map-unmap-for-cache.patch
+arm64-fix-size-of-__early_cpu_boot_status.patch
+rpmsg-glink-remove-chunk-size-word-align-warning.patch
+usb-dwc3-don-t-set-gadget-is_otg-flag.patch
+drm_dp_mst_topology-fix-broken-drm_dp_sideband_parse_remote_dpcd_read.patch
--- /dev/null
+From c09b73cfac2a9317f1104169045c519c6021aa1d Mon Sep 17 00:00:00 2001
+From: Roger Quadros <rogerq@ti.com>
+Date: Mon, 26 Aug 2019 16:10:58 +0300
+Subject: usb: dwc3: don't set gadget->is_otg flag
+
+From: Roger Quadros <rogerq@ti.com>
+
+commit c09b73cfac2a9317f1104169045c519c6021aa1d upstream.
+
+This reverts
+commit 6a4290cc28be1 ("usb: dwc3: gadget: set the OTG flag in dwc3 gadget driver.")
+
+We don't yet support any of the OTG mechanisms (HNP/SRP/ADP)
+and are not setting gadget->otg_caps, so don't set gadget->is_otg
+flag.
+
+If we do then we end up publishing a OTG1.0 descriptor in
+the gadget descriptor which causes device enumeration to fail
+if we are connected to a host with CONFIG_USB_OTG enabled.
+
+Host side log without this patch
+
+[ 96.720453] usb 1-1: new high-speed USB device number 2 using xhci-hcd
+[ 96.901391] usb 1-1: Dual-Role OTG device on non-HNP port
+[ 96.907552] usb 1-1: set a_alt_hnp_support failed: -32
+[ 97.060447] usb 1-1: new high-speed USB device number 3 using xhci-hcd
+[ 97.241378] usb 1-1: Dual-Role OTG device on non-HNP port
+[ 97.247536] usb 1-1: set a_alt_hnp_support failed: -32
+[ 97.253606] usb usb1-port1: attempt power cycle
+[ 97.960449] usb 1-1: new high-speed USB device number 4 using xhci-hcd
+[ 98.141383] usb 1-1: Dual-Role OTG device on non-HNP port
+[ 98.147540] usb 1-1: set a_alt_hnp_support failed: -32
+[ 98.300453] usb 1-1: new high-speed USB device number 5 using xhci-hcd
+[ 98.481391] usb 1-1: Dual-Role OTG device on non-HNP port
+[ 98.487545] usb 1-1: set a_alt_hnp_support failed: -32
+[ 98.493532] usb usb1-port1: unable to enumerate USB device
+
+Signed-off-by: Roger Quadros <rogerq@ti.com>
+Signed-off-by: Felipe Balbi <felipe.balbi@linux.intel.com>
+Signed-off-by: Lee Jones <lee.jones@linaro.org>
+Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+---
+ drivers/usb/dwc3/gadget.c | 1 -
+ 1 file changed, 1 deletion(-)
+
+--- a/drivers/usb/dwc3/gadget.c
++++ b/drivers/usb/dwc3/gadget.c
+@@ -3257,7 +3257,6 @@ int dwc3_gadget_init(struct dwc3 *dwc)
+ dwc->gadget.speed = USB_SPEED_UNKNOWN;
+ dwc->gadget.sg_supported = true;
+ dwc->gadget.name = "dwc3-gadget";
+- dwc->gadget.is_otg = dwc->dr_mode == USB_DR_MODE_OTG;
+
+ /*
+ * FIXME We might be setting max_speed to <SUPER, however versions