1
0
Fork 0
remarkable-linux/drivers
Neil Horman 74026a188f vmxnet3: repair memory leak
[ Upstream commit 848b159835 ]

with the introduction of commit
b0eb57cb97, it appears that rq->buf_info
is improperly handled.  While it is heap allocated when an rx queue is
setup, and freed when torn down, an old line of code in
vmxnet3_rq_destroy was not properly removed, leading to rq->buf_info[0]
being set to NULL prior to its being freed, causing a memory leak, which
eventually exhausts the system on repeated create/destroy operations
(for example, when  the mtu of a vmxnet3 interface is changed
frequently.

Fix is pretty straight forward, just move the NULL set to after the
free.

Tested by myself with successful results

Applies to net, and should likely be queued for stable, please

Signed-off-by: Neil Horman <nhorman@tuxdriver.com>
Reported-By: boyang@redhat.com
CC: boyang@redhat.com
CC: Shrikrishna Khare <skhare@vmware.com>
CC: "VMware, Inc." <pv-drivers@vmware.com>
CC: David S. Miller <davem@davemloft.net>
Acked-by: Shrikrishna Khare <skhare@vmware.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2018-01-31 14:03:49 +01:00
..
accessibility License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
acpi acpi, nfit: fix health event notification 2017-12-29 17:53:45 +01:00
amba License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
android binder: fix proc->files use-after-free 2018-01-02 20:31:15 +01:00
ata libata: apply MAX_SEC_1024 to all LITEON EP1 series devices 2018-01-23 19:58:18 +01:00
atm atm: horizon: Fix irq release error 2017-12-14 09:53:13 +01:00
auxdisplay Update MIPS email addresses 2017-11-03 09:02:30 -07:00
base sysfs/cpu: Add vulnerability folder 2018-01-17 09:45:27 +01:00
bcma License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
block rbd: set max_segments to USHRT_MAX 2018-01-17 09:45:23 +01:00
bluetooth Bluetooth: hci_bcm: Fix setting of irq trigger type 2017-12-25 14:26:27 +01:00
bus sunxi-rsb: Include OF based modalias in device uevent 2018-01-10 09:31:19 +01:00
cdrom License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
char Revert "ipmi_si: fix memory leak on new_smi" 2017-12-29 17:53:49 +01:00
clk clk: sunxi: sun9i-mmc: Implement reset callback for reset controls 2017-12-29 17:53:48 +01:00
clocksource clocksource/drivers/arm_arch_timer: Validate CNTFRQ after enabling frame 2017-12-10 13:40:41 +01:00
connector
cpufreq License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
cpuidle cpuidle: fix broadcast control when broadcast can not be entered 2017-12-25 14:26:30 +01:00
crypto crypto: chelsio - select CRYPTO_GF128MUL 2018-01-10 09:31:18 +01:00
dax dev/dax: fix uninitialized variable build warning 2017-12-20 10:10:34 +01:00
dca
devfreq License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
dio License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
dma dmaengine: ti-dma-crossbar: Correct am335x/am43xx mux value type 2017-12-20 10:10:24 +01:00
dma-buf dma-buf/sw_sync: force signal all unsignaled fences on dying timeline 2017-12-10 13:40:44 +01:00
edac EDAC, sb_edac: Fix missing break in switch 2017-12-10 13:40:41 +01:00
eisa License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
extcon License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
firewire License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
firmware efi/capsule-loader: Reinstate virtual capsule mapping 2018-01-10 09:31:18 +01:00
fmc License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
fpga License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
fsi drivers/fsi/scom: Remove reset before every putscom 2017-08-28 17:15:16 +02:00
gpio gpio: fix "gpio-line-names" property retrieval 2018-01-02 20:31:04 +01:00
gpu drm/vc4: Fix NULL pointer dereference in vc4_save_hang_state() 2018-01-31 14:03:44 +01:00
hid HID: cp2112: fix broken gpio_direction_input callback 2017-12-20 10:10:22 +01:00
hsi License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
hv x86/virt: Add enum for hypervisors to replace x86_hyper 2017-12-25 14:26:20 +01:00
hwmon hwmon: (pmbus/core) Prevent unintentional setting of page to 0xFF 2017-12-10 13:40:40 +01:00
hwspinlock License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
hwtracing License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
i2c i2c: core-smbus: prevent stack corruption on read I2C_BLOCK_DATA 2018-01-23 19:58:17 +01:00
ide ide: ide-atapi: fix compile error with defining macro DEBUG 2017-12-17 15:08:00 +01:00
idle Revert "x86/mm: Stop calling leave_mm() in idle code" 2017-11-04 15:01:50 +01:00
iio iio: st_sensors: add register mask for status register 2017-12-25 14:26:26 +01:00
infiniband {net,ib}/mlx5: Don't disable local loopback multicast traffic when needed 2018-01-31 14:03:46 +01:00
input Input: trackpoint - only expose supported controls for Elan, ALPS and NXP 2018-01-31 14:03:42 +01:00
iommu iommu/arm-smmu-v3: Cope with duplicated Stream IDs 2018-01-10 09:31:21 +01:00
ipack
irqchip irqchip/qcom: Fix u32 comparison with value less than zero 2017-12-14 09:53:05 +01:00
isdn License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
leds leds: pca955x: Don't invert requested value in pca955x_gpio_set_value() 2017-12-25 14:26:27 +01:00
lightnvm lightnvm: pblk: protect line bitmap while submitting meta io 2017-12-20 10:10:38 +01:00
macintosh License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
mailbox mailbox: mailbox-test: don't rely on rx_buffer content to signal data ready 2017-12-14 09:53:12 +01:00
mcb License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
md dm crypt: fix error return code in crypt_ctr() 2018-01-23 19:58:19 +01:00
media media: usbtv: fix brightness and contrast controls 2017-12-20 10:10:29 +01:00
memory License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
memstick License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
message License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
mfd mfd: twl6040: Fix child-node lookup 2017-12-29 17:53:46 +01:00
misc drivers/misc/intel/pti: Rename the header file to free up the namespace 2017-12-25 14:26:20 +01:00
mmc mmc: sdhci-esdhc-imx: Fix i.MX53 eSDHCv3 clock 2018-01-23 19:58:13 +01:00
mtd mtd: nand: pxa3xx: Fix READOOB implementation 2018-01-10 09:31:22 +01:00
mux mux: core: fix double get_device() 2018-01-17 09:45:27 +01:00
net vmxnet3: repair memory leak 2018-01-31 14:03:49 +01:00
nfc License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
ntb
nubus License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
nvdimm libnvdimm, pfn: fix start_pad handling for aligned namespaces 2017-12-29 17:53:49 +01:00
nvme nvme: use kref_get_unless_zero in nvme_find_get_ns 2017-12-20 10:10:31 +01:00
nvmem License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
of License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
oprofile License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
parisc parisc: Hide Diva-built-in serial aux and graphics card 2017-12-29 17:53:47 +01:00
parport License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
pci PCI / PM: Force devices to D0 in pci_pm_thaw_noirq() 2017-12-29 17:53:47 +01:00
pcmcia License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
perf License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
phy phy: work around 'phys' references to usb-nop-xceiv devices 2018-01-23 19:58:16 +01:00
pinctrl pinctrl: cherryview: Mask all interrupts on Intel_Strago based systems 2017-12-29 17:53:48 +01:00
platform platform/x86: wmi: Call acpi_wmi_init() later 2018-01-17 09:45:18 +01:00
pnp License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
power Update MIPS email addresses 2017-11-03 09:02:30 -07:00
powercap
pps drivers/pps: use surrounding "if PPS" to remove numerous dependency checks 2017-09-08 18:26:51 -07:00
ps3
ptp License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
pwm License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
rapidio drivers/rapidio/devices/rio_mport_cdev.c: fix resource leak in error handling path in 'rio_dma_transfer()' 2017-12-14 09:53:08 +01:00
ras License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
regulator License cleanup: add SPDX license identifiers to some files 2017-11-02 10:04:46 -07:00
remoteproc License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
reset License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
rpmsg rpmsg: glink: Initialize the "intent_req_comp" completion variable 2017-12-20 10:10:29 +01:00
rtc rtc: m41t80: remove unneeded checks from m41t80_sqw_set_rate 2018-01-05 15:48:59 +01:00
s390 s390/qeth: fix error handling in checksum cmd callback 2018-01-02 20:31:11 +01:00
sbus License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
scsi scsi: libsas: Disable asynchronous aborts for SATA devices 2018-01-23 19:58:18 +01:00
sfi
sh License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
sn
soc soc: mediatek: pwrap: fix compiler errors 2017-12-20 10:10:34 +01:00
spi spi: a3700: Fix clk prescaling for coefficient over 15 2017-12-29 17:53:47 +01:00
spmi spmi: pmic-arb: Move the ownership check to irq_chip callback 2017-08-28 13:52:22 +02:00
ssb License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
staging staging: android: ashmem: fix a race condition in ASHMEM_SET_SIZE ioctl 2018-01-17 09:45:26 +01:00
target block: fix blk_rq_append_bio 2018-01-02 20:31:05 +01:00
tc
tee optee: fix invalid of_node_put() in optee_driver_init() 2017-12-25 14:26:24 +01:00
thermal thermal/drivers/hisi: Fix multiple alarm interrupts firing 2017-12-25 14:26:31 +01:00
thunderbolt thunderbolt: tb: fix use after free in tb_activate_pcie_devices 2017-12-20 10:10:24 +01:00
tty tty: fix tty_ldisc_receive_buf() documentation 2018-01-02 20:31:17 +01:00
uio License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
usb uas: ignore UAS for Norelsys NS1068(X) chips 2018-01-17 09:45:26 +01:00
uwb License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
vfio vfio/pci: Virtualize Maximum Payload Size 2017-12-25 14:26:29 +01:00
vhost vhost: fix skb leak in handle_rx() 2017-12-17 15:07:56 +01:00
video backlight: pwm_bl: Fix overflow condition 2017-12-25 14:26:24 +01:00
virt virt: Convert to using %pOF instead of full_name 2017-08-29 08:52:51 -05:00
virtio virtio: release virtio index when fail to device_register 2017-12-14 09:52:48 +01:00
vlynq
vme License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
w1 License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
watchdog License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
xen License cleanup: add SPDX license identifiers to some files 2017-11-02 10:04:46 -07:00
zorro License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
Kconfig License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
Makefile License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00