net: dsa: properly check for the bridge_leave methods in dsa_switch_bridge_leave()
Vladimir Oltean authored
commit bcb9928a upstream.

This was not caught because there is no switch driver which implements
the .port_bridge_join but not .port_bridge_leave method, but it should
nonetheless be fixed, as in certain conditions (driver development) it
might lead to NULL pointer dereference.

Fixes: f66a6a69

 ("net: dsa: permit cross-chip bridging between all trees in the system")
Signed-off-by: default avatarVladimir Oltean <vladimir.oltean@nxp.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
d7243e2a
Name Last commit Last update
Documentation dt-bindings: i2c: at91: fix example for scl-gpios
LICENSES LICENSES: Add the CC-BY-4.0 license
arch arm64: dts: marvell: armada-37xx: move firmware node to generic dtsi file
block block: grab a device refcount in disk_uevent
certs Merge tag 'kbuild-v5.13-2' of git://git.kernel.org/pub/scm/linux/kernel/git/masahiroy/linux-kbuild
crypto crypto: sm2 - fix a memory leak in sm2
drivers net: ti: fix UAF in tlan_remove_one
fs f2fs: Show casefolding support only when supported
include net: validate lwtstate->data before returning from skb_tunnel_info()
init sched/core: Initialize the idle task with preemption disabled
ipc ipc/mqueue, msg, sem: avoid relying on a stack reference past its expiry
kernel sched/fair: Fix CFS bandwidth hrtimer expiry type
lib lib/decompress_unlz4.c: correctly handle zero-padding around initrds.
mm mm/userfaultfd: fix uffd-wp special cases for fork()
net net: dsa: properly check for the bridge_leave methods in dsa_switch_bridge_leave()
samples samples/bpf: Fix the error return code of xdp_redirect's main()
scripts kbuild: mkcompile_h: consider timestamp if KBUILD_BUILD_TIMESTAMP is set
security smackfs: restrict bytes count in smk_set_cipso()
sound ALSA: isa: Fix error return code in snd_cmi8330_probe()
tools perf tools: Fix pattern matching for same substring in different PMU type
usr .gitignore: prefix local generated files with a slash
virt KVM: mmio: Fix use-after-free Read in kvm_vm_ioctl_unregister_coalesced_mmio
.clang-format clang-format: Update with the latest for_each macro list
.cocciconfig scripts: add Linux .cocciconfig for coccinelle
.get_maintainer.ignore Opt out of scripts/get_maintainer.pl
.gitattributes
.gitignore
.mailmap
COPYING
CREDITS
Kbuild
Kconfig
MAINTAINERS
Makefile
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.