Skip to contentSkip to conversation

Patch "[PATCH] Revert "bsg-lib: don't free job in bsg_prepare_job"" has been added to the 4.4-stable tree

PATCH [email protected] 1 participant 1 message Oct 19, 2017

Subsystems (2)
lore
Share & tools
lore

[email protected]

author maintainer Applied
#0 lore raw

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

[PATCH] Revert "bsg-lib: don't free job in bsg_prepare_job"

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-bsg-lib-don-t-free-job-in-bsg_prepare_job.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 <[email protected]> know about it.

Quoted 1 line

From 42fbb07e2e3a338154ee747bf28dc688bc599b81 Mon Sep 17 00:00:00 2001

From: Greg Kroah-Hartman <[email protected]>
Date: Thu, 19 Oct 2017 14:55:29 +0200
Subject: [PATCH] Revert "bsg-lib: don't free job in bsg_prepare_job"

This reverts commit 668cee82cd28d2c38a99f7cbddf3b3fd58f257b9 which was commit f507b54dccfd8000c517d740bc45f20c74532d18 upstream.

Ben reports:
That function doesn't exist here (it was introduced in 4.13). Instead, this backport has modified bsg_create_job(), creating a leak. Please revert this on the 3.18, 4.4 and 4.9 stable branches.

So I'm dropping it from here.

---
 block/bsg-lib.c |    1 +
 1 file changed, 1 insertion(+)
block/bsg-lib.c +1 -0
@@ -147,6 +147,7 @@ static int bsg_create_job(struct device
 failjob_rls_rqst_payload:
 	kfree(job->request_payload.sg_list);
 failjob_rls_job:
+	kfree(job);
 	return -ENOMEM;
 }
 

Patches currently in stable-queue which might be from [email protected] are

queue-4.4/packet-in-packet_do_bind-test-fanout-with-bind_lock-held.patch queue-4.4/isdn-i4l-fetch-the-ppp_write-buffer-in-one-shot.patch queue-4.4/mips-fix-minimum-alignment-requirement-of-irq-stack.patch queue-4.4/l2tp-fix-race-condition-in-l2tp_tunnel_delete.patch queue-4.4/vti-fix-use-after-free-in-vti_tunnel_xmit-vti6_tnl_xmit.patch queue-4.4/percpu-make-this_cpu_generic_read-atomic-w.r.t.-interrupts.patch queue-4.4/revert-bsg-lib-don-t-free-job-in-bsg_prepare_job.patch queue-4.4/net-emac-fix-napi-poll-list-corruption.patch queue-4.4/packet-only-test-po-has_vnet_hdr-once-in-packet_snd.patch queue-4.4/udpv6-fix-the-checksum-computation-when-hw-checksum-does-not-apply.patch queue-4.4/bpf-one-perf-event-close-won-t-free-bpf-program-attached-by-another-perf-event.patch queue-4.4/sctp-potential-read-out-of-bounds-in-sctp_ulpevent_type_enabled.patch queue-4.4/drm-dp-mst-save-vcpi-with-payloads.patch queue-4.4/l2tp-avoid-schedule-while-atomic-in-exit_net.patch queue-4.4/bpf-verifier-reject-bpf_alu64-bpf_end.patch queue-4.4/ip6_gre-skb_push-ipv6hdr-before-packing-the-header-in-ip6gre_header.patch queue-4.4/tipc-use-only-positive-error-codes-in-messages.patch queue-4.4/tun-bail-out-from-tun_get_user-if-the-skb-is-empty.patch queue-4.4/net-set-sk_prot_creator-when-cloning-sockets-to-the-right-proto.patch queue-4.4/packet-hold-bind-lock-when-rebinding-to-fanout-hook.patch