Patch "[PATCH] Revert "usb: gadget: composite: always set ep->mult to a" has been added to the 4.4-stable tree

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



This is a note to let you know that I've just added the patch titled

    [PATCH] Revert "usb: gadget: composite: always set ep->mult to a

to the 4.4-stable tree which can be found at:
    http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary

The filename of the patch is:
     revert-usb-gadget-composite-always-set-ep-mult-to-a.patch
and it can be found in the queue-4.4 subdirectory.

If you, or anyone else, feels it should not be added to the stable tree,
please let <stable@xxxxxxxxxxxxxxx> know about it.


>From bb4c8316e09d3d44378c77a5868882d70e393e91 Mon Sep 17 00:00:00 2001
From: Greg Kroah-Hartman <gregkh@xxxxxxxxxxxxxxxxxxx>
Date: Thu, 12 Jan 2017 08:54:43 +0100
Subject: [PATCH] Revert "usb: gadget: composite: always set ep->mult to a
 sensible value"

This reverts commit c53af76d5de1af844a71e673ae4a02f1786c1b9c which is
commit eaa496ffaaf19591fe471a36cef366146eeb9153 upstream as it was
incorrect.

Reported-by: Bin Liu <b-liu@xxxxxx>
Cc: Felipe Balbi <balbi@xxxxxxxxxx>
Signed-off-by: Greg Kroah-Hartman <gregkh@xxxxxxxxxxxxxxxxxxx>

---
 drivers/usb/gadget/composite.c          |    9 ++-------
 drivers/usb/gadget/function/uvc_video.c |    2 +-
 2 files changed, 3 insertions(+), 8 deletions(-)

--- a/drivers/usb/gadget/composite.c
+++ b/drivers/usb/gadget/composite.c
@@ -148,12 +148,7 @@ ep_found:
 	_ep->desc = chosen_desc;
 	_ep->comp_desc = NULL;
 	_ep->maxburst = 0;
-	_ep->mult = 1;
-
-	if (g->speed == USB_SPEED_HIGH && (usb_endpoint_xfer_isoc(_ep->desc) ||
-				usb_endpoint_xfer_int(_ep->desc)))
-		_ep->mult = usb_endpoint_maxp(_ep->desc) & 0x7ff;
-
+	_ep->mult = 0;
 	if (!want_comp_desc)
 		return 0;
 
@@ -170,7 +165,7 @@ ep_found:
 		switch (usb_endpoint_type(_ep->desc)) {
 		case USB_ENDPOINT_XFER_ISOC:
 			/* mult: bits 1:0 of bmAttributes */
-			_ep->mult = (comp_desc->bmAttributes & 0x3) + 1;
+			_ep->mult = comp_desc->bmAttributes & 0x3;
 		case USB_ENDPOINT_XFER_BULK:
 		case USB_ENDPOINT_XFER_INT:
 			_ep->maxburst = comp_desc->bMaxBurst + 1;
--- a/drivers/usb/gadget/function/uvc_video.c
+++ b/drivers/usb/gadget/function/uvc_video.c
@@ -243,7 +243,7 @@ uvc_video_alloc_requests(struct uvc_vide
 
 	req_size = video->ep->maxpacket
 		 * max_t(unsigned int, video->ep->maxburst, 1)
-		 * (video->ep->mult);
+		 * (video->ep->mult + 1);
 
 	for (i = 0; i < UVC_NUM_REQUESTS; ++i) {
 		video->req_buffer[i] = kmalloc(req_size, GFP_KERNEL);


Patches currently in stable-queue which might be from gregkh@xxxxxxxxxxxxxxxxxxx are

queue-4.4/kvm-mips-flush-kvm-entry-code-from-icache-globally.patch
queue-4.4/net-vxge-avoid-unused-function-warnings.patch
queue-4.4/hwmon-ds620-fix-overflows-seen-when-writing-temperature-limits.patch
queue-4.4/mei-bus-fix-mei_cldev_enable-kdoc.patch
queue-4.4/cred-userns-define-current_user_ns-as-a-function.patch
queue-4.4/usb-dummy-hcd-fix-bug-in-stop_activity-handle-ep0.patch
queue-4.4/usb-host-xhci-fix-possible-wild-pointer-when-handling-abort-command.patch
queue-4.4/usb-serial-io_ti-fix-i-o-after-disconnect.patch
queue-4.4/xhci-workaround-for-hosts-missing-cas-bit.patch
queue-4.4/usb-hub-move-hub_port_disable-to-fix-warning-if-pm-is-disabled.patch
queue-4.4/usb-dwc3-core-avoid-overflow-events.patch
queue-4.4/asoc-samsung-i2s-fixup-last-irq-unsafe-spin-lock-call.patch
queue-4.4/usb-gadgetfs-fix-use-after-free-bug.patch
queue-4.4/alsa-hda-fix-up-gpio-for-asus-rog-ranger.patch
queue-4.4/crypto-arm64-aes-neon-fix-for-big-endian.patch
queue-4.4/usb-musb-blackfin-add-bfin_fifo_offset-in-bfin_ops.patch
queue-4.4/usb-musb-dsps-implement-clear_ep_rxintr-callback.patch
queue-4.4/alsa-hda-apply-asus-mode8-fixup-to-asus-x71sl.patch
queue-4.4/usb-serial-ti_usb_3410_5052-fix-null-deref-at-open.patch
queue-4.4/hwmon-amc6821-sign-extension-temperature.patch
queue-4.4/mmc-mmc_test-uninitialized-return-value.patch
queue-4.4/pm-wakeirq-fix-dedicated-wakeirq-for-drivers-not-using-autosuspend.patch
queue-4.4/usb-gadget-composite-test-get_alt-presence-instead-of-set_alt.patch
queue-4.4/stable-fixup-hotplug-fix-unused-function-warning.patch
queue-4.4/usb-serial-kl5kusb105-abort-on-open-exception-path.patch
queue-4.4/xhci-handle-command-completion-and-timeout-race.patch
queue-4.4/xhci-use-delayed_work-instead-of-timer-for-command-timeout.patch
queue-4.4/usb-serial-kobil_sct-fix-null-deref-in-write.patch
queue-4.4/usb-serial-spcp8x5-fix-null-deref-at-open.patch
queue-4.4/crypto-arm64-ghash-ce-fix-for-big-endian.patch
queue-4.4/scsi-mvsas-fix-command_active-typo.patch
queue-4.4/usb-serial-mos7720-fix-parallel-probe.patch
queue-4.4/usb-xhci-fix-possible-wild-pointer.patch
queue-4.4/crypto-arm64-aes-ce-fix-for-big-endian.patch
queue-4.4/staging-comedi-dt282x-tidy-up-register-bit-defines.patch
queue-4.4/irqchip-bcm7038-l1-implement-irq_cpu_offline-callback.patch
queue-4.4/alsa-usb-audio-fix-bogus-error-return-in-snd_usb_create_stream.patch
queue-4.4/xhci-free-xhci-virtual-devices-with-leaf-nodes-first.patch
queue-4.4/iommu-vt-d-fix-pasid-table-size-encoding.patch
queue-4.4/usb-dwc3-ep0-explicitly-call-dwc3_ep0_prepare_one_trb.patch
queue-4.4/clk-clk-wm831x-fix-a-logic-error.patch
queue-4.4/usb-phy-am335x-control-fix-device-and-of_node-leaks.patch
queue-4.4/usb-serial-io_ti-bind-to-interface-after-fw-download.patch
queue-4.4/drm-radeon-always-store-crtc-relative-radeon_crtc-cursor_x-y-values.patch
queue-4.4/usb-serial-cyberjack-fix-null-deref-at-open.patch
queue-4.4/usb-serial-mos7720-fix-null-deref-at-open.patch
queue-4.4/crypto-arm64-aes-xts-ce-fix-for-big-endian.patch
queue-4.4/usb-serial-garmin_gps-fix-memory-leak-on-failed-urb-submit.patch
queue-4.4/usb-serial-io_ti-fix-null-deref-at-open.patch
queue-4.4/usb-gadgetfs-restrict-upper-bound-on-device-configuration-size.patch
queue-4.4/md-md_recovery_needed-is-set-for-mddev-recovery.patch
queue-4.4/usb-gadgetfs-fix-checks-of-wtotallength-in-config-descriptors.patch
queue-4.4/mac80211-initialize-fast-xmit-info-later.patch
queue-4.4/clk-imx31-fix-rewritten-input-argument-of-mx31_clocks_init.patch
queue-4.4/target-iscsi-fix-double-free-in-lio_target_tiqn_addtpg.patch
queue-4.4/powerpc-pci-rpadlpar-fix-device-reference-leaks.patch
queue-4.4/hwmon-scpi-fix-module-autoload.patch
queue-4.4/arm-davinci-da850-don-t-add-emac-clock-to-lookup-table-twice.patch
queue-4.4/usb-serial-pl2303-fix-null-deref-at-open.patch
queue-4.4/xhci-fix-race-related-to-abort-operation.patch
queue-4.4/usb-serial-quatech2-fix-sleep-while-atomic-in-close.patch
queue-4.4/usb-xhci-fix-return-value-of-xhci_setup_device.patch
queue-4.4/usb-dwc3-gadget-always-unmap-ep0-requests.patch
queue-4.4/usb-serial-iuu_phoenix-fix-null-deref-at-open.patch
queue-4.4/usb-serial-oti6858-fix-null-deref-at-open.patch
queue-4.4/s390-crypto-unlock-on-error-in-prng_tdes_read.patch
queue-4.4/hwmon-nct7802-fix-overflows-seen-when-writing-into-limit-attributes.patch
queue-4.4/revert-usb-gadget-composite-always-set-ep-mult-to-a.patch
queue-4.4/usb-musb-core-add-clear_ep_rxintr-to-musb_platform_ops.patch
queue-4.4/cx23885-dvb-move-initialization-of-a8293_pdata.patch
queue-4.4/usb-serial-io_edgeport-fix-null-deref-at-open.patch
queue-4.4/usb-serial-mos7720-fix-parport-use-after-free-on-probe-errors.patch
queue-4.4/usb-serial-mos7720-fix-use-after-free-on-probe-errors.patch
queue-4.4/kvm-x86-reset-mmu-on-kvm_set_vcpu_events.patch
queue-4.4/arm-dts-r8a7794-correct-hsusb-parent-clock.patch
queue-4.4/iommu-vt-d-flush-old-iommu-caches-for-kdump-when-the-device-gets-context-mapped.patch
queue-4.4/usb-musb-fix-trying-to-free-already-free-irq-4.patch
queue-4.4/net-ti-cpmac-fix-compiler-warning-due-to-type-confusion.patch
queue-4.4/usb-xhci-mem-use-passed-in-gfp-flags-instead-of-gfp_kernel.patch
queue-4.4/iommu-amd-missing-error-code-in-amd_iommu_init_device.patch
queue-4.4/usb-xhci-apply-xhci_pme_stuck_quirk-to-intel-apollo-lake.patch
queue-4.4/usb-fix-problems-with-duplicate-endpoint-addresses.patch
queue-4.4/usb-dwc3-ep0-add-dwc3_ep0_prepare_one_trb.patch
queue-4.4/usb-xhci-hold-lock-over-xhci_abort_cmd_ring.patch
queue-4.4/usb-serial-mos7840-fix-null-deref-at-open.patch
queue-4.4/crypto-arm-aes-ce-fix-for-big-endian.patch
queue-4.4/crypto-arm64-aes-ccm-ce-fix-for-big-endian.patch
queue-4.4/crypto-arm64-sha2-ce-fix-for-big-endian.patch
queue-4.4/usb-storage-unusual_uas-add-jmicron-jms56x-to-unusual-device.patch
queue-4.4/alsa-usb-audio-fix-irq-process-data-synchronization.patch
queue-4.4/staging-iio-ad7606-fix-improper-setting-of-oversampling-pins.patch
queue-4.4/cris-only-build-flash-rescue-image-if-config_etrax_axisflashmap-is-selected.patch
queue-4.4/hwmon-g762-fix-overflows-and-crash-seen-when-writing-limit-attributes.patch
queue-4.4/ath10k-use-the-right-length-of-background.patch
queue-4.4/usb-serial-omninet-fix-null-derefs-at-open-and-disconnect.patch
queue-4.4/usb-dwc3-pci-add-intel-gemini-lake-pci-id.patch
queue-4.4/usb-gadgetfs-fix-unbounded-memory-allocation-bug.patch
queue-4.4/tick-broadcast-prevent-null-pointer-dereference.patch
queue-4.4/crypto-arm64-sha1-ce-fix-for-big-endian.patch
queue-4.4/usb-serial-keyspan_pda-verify-endpoints-at-probe.patch
queue-4.4/usb-serial-io_ti-fix-another-null-deref-at-open.patch
queue-4.4/iommu-amd-fix-the-left-value-check-of-cmd-buffer.patch
--
To unsubscribe from this list: send the line "unsubscribe stable" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html



[Index of Archives]     [Linux Kernel]     [Kernel Development Newbies]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite Hiking]     [Linux Kernel]     [Linux SCSI]