No description
Find a file
Zheng Wang be53cbc855 scsi: message: mptlan: Fix use after free bug in mptlan_remove() due to race condition
[ Upstream commit f486893288 ]

mptlan_probe() calls mpt_register_lan_device() which initializes the
&priv->post_buckets_task workqueue. A call to
mpt_lan_wake_post_buckets_task() will subsequently start the work.

During driver unload in mptlan_remove() the following race may occur:

CPU0                  CPU1

                    |mpt_lan_post_receive_buckets_work()
mptlan_remove()     |
  free_netdev()     |
    kfree(dev);     |
                    |
                    | dev->mtu
                    |   //use

Fix this by finishing the work prior to cleaning up in mptlan_remove().

[mkp: we really should remove mptlan instead of attempting to fix it]

Signed-off-by: Zheng Wang <zyytlz.wz@163.com>
Link: https://lore.kernel.org/r/20230318081635.796479-1-zyytlz.wz@163.com
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2023-06-06 18:39:30 +08:00
arch arm64: dts: qcom: msm8996: Add missing DWC3 quirks 2023-06-06 18:39:27 +08:00
block blk-crypto: make blk_crypto_evict_key() more robust 2023-06-06 18:34:51 +08:00
certs certs/blacklist_hashes.c: fix const confusion in certs blacklist 2023-04-19 17:50:34 +08:00
crypto crypto: engine - fix crypto_queue backlog handling 2023-06-06 18:37:47 +08:00
Documentation riscv: Move early dtb mapping into the fixmap region 2023-06-06 18:19:52 +08:00
drivers scsi: message: mptlan: Fix use after free bug in mptlan_remove() due to race condition 2023-06-06 18:39:30 +08:00
fs ext2: Check block size validity during mount 2023-06-06 18:39:29 +08:00
include firmware: arm_sdei: Fix sleep from invalid context BUG 2023-06-06 18:39:28 +08:00
init kbuild: Add CONFIG_PAHOLE_VERSION 2023-04-19 17:59:33 +08:00
io_uring io_uring: avoid null-ptr-deref in io_arm_poll_handler 2023-04-19 18:00:57 +08:00
ipc ipc/sem: Fix dangling sem_array access in semtimedop race 2023-04-19 17:56:54 +08:00
kernel bpf: Annotate data races in bpf_local_storage 2023-06-06 18:39:29 +08:00
lib lib: cpu_rmap: Avoid use after free on rmap->obj array entries 2023-06-06 18:39:29 +08:00
LICENSES LICENSES/dual/CC-BY-4.0: Git rid of "smart quotes" 2021-07-15 06:31:24 -06:00
mm writeback, cgroup: fix null-ptr-deref write in bdi_split_work_to_wbs 2023-06-06 18:34:53 +08:00
net net: Catch invalid index in XPS mapping 2023-06-06 18:39:29 +08:00
samples samples: vfio-mdev: Fix missing pci_disable_device() in mdpy_fb_probe() 2023-04-19 17:57:46 +08:00
scripts scripts/gdb: fix lx-timerlist for Python3 2023-06-06 18:37:32 +08:00
security selinux: ensure av_permissions.h is built when needed 2023-06-06 18:37:04 +08:00
sound ASoC: soc-pcm.c: call __soc_pcm_close() in soc_pcm_close() 2023-06-06 18:37:51 +08:00
tools perf stat: Separate bperf from bpf_profiler 2023-06-06 18:37:47 +08:00
usr usr/include/Makefile: add linux/nfc.h to the compile-test coverage 2023-04-19 17:44:58 +08:00
virt KVM: fix memoryleak in kvm_init() 2023-04-19 18:00:47 +08:00
.clang-format clang-format: Update with the latest for_each macro list 2021-05-12 23:32:39 +02:00
.cocciconfig
.get_maintainer.ignore
.gitattributes
.gitignore .gitignore: ignore only top-level modules.builtin 2021-05-02 00:43:35 +09:00
.mailmap mailmap: add Andrej Shadura 2021-10-18 20:22:03 -10:00
COPYING COPYING: state that all contributions really are covered by this file 2020-02-10 13:32:20 -08:00
CREDITS MAINTAINERS: Move Daniel Drake to credits 2021-09-21 08:34:58 +03:00
Kbuild kbuild: rename hostprogs-y/always to hostprogs/always-y 2020-02-04 01:53:07 +09:00
Kconfig kbuild: ensure full rebuild when the compiler is updated 2020-05-12 13:28:33 +09:00
MAINTAINERS counter: Internalize sysfs interface code 2023-06-06 18:05:09 +08:00
Makefile Linux 5.15.112 2023-06-06 18:39:17 +08:00
README

Linux kernel
============

There are several guides for kernel developers and users. These guides can
be rendered in a number of formats, like HTML and PDF. Please read
Documentation/admin-guide/README.rst first.

In order to build the documentation, use ``make htmldocs`` or
``make pdfdocs``.  The formatted documentation can also be read online at:

    https://www.kernel.org/doc/html/latest/

There are various text files in the Documentation/ subdirectory,
several of them using the Restructured Text markup notation.

Please read the Documentation/process/changes.rst file, as it contains the
requirements for building and running the kernel, and information about
the problems which may result by upgrading your kernel.