linux-gbmc: 5.15: fix mctp skb memory leak

Backport upstream commit 64f16b2cfc1b ("mctp: handle skb cleanup on
sock_queue failures") to Linux 5.15 to prevent kernel sk_buff memory leak
when delivering incoming MCTP packets to a socket where sock_queue_rcv_skb
fails (e.g. socket receive buffer is full or socket is shutting down).

Upstream-Status: Backport [https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=64f16b2cfc1b017b2b8d4bb98d407ff5661b173c]

Tested:
- Compiled obmc-phosphor-image with 0 patch fuzz and 0 build errors.
- Verified in QEMU simulation with active MCTP interfaces and mctpd service.
- Deployed signed A/B image to physical lab hardware (ddche15-nfd01). Verified:
  * uname -r: 5.15.167
  * 9 MCTP I2C interfaces (mctpi2c2, mctpi2c4..mctpi2c11) UP/LOWER_UP.
  * mctpd service active and running without leak warnings.
  * /proc/net/protocols: MCTP protocol family 576 active.

Fusion-Link: http://fusion2/ci/kokoro/prod%3Agbmc%2Ffirmware-build%2Ffirmware%2Fredacted_gbmc_platforms/activity/ace1fcb5-15a8-4f37-9492-9a1a5e96b3a4
Google-Bug-Id: 543881748
Change-Id: I17ce42658400de8af561b773521830f682ae25fd
Signed-off-by: Joseph CT Chan <josephctchan@google.com>
2 files changed
tree: e28ed6a40eafda0127dc15f11bc9658ef96f3dfe
  1. classes/
  2. conf/
  3. dynamic-layers/
  4. recipes-benchmark/
  5. recipes-bsp/
  6. recipes-connectivity/
  7. recipes-core/
  8. recipes-devtools/
  9. recipes-extended/
  10. recipes-google/
  11. recipes-kernel/
  12. recipes-phosphor/
  13. recipes-support/
  14. recipes-tpm1/
  15. recipes-tpm2/
  16. recipes-x86/
  17. LICENSE
  18. README.md
README.md

meta-gbmc-staging

This repository contains additions to the openbmc/meta-google layer that are not yet ready for OpenBMC inclusion.

How to use this layer

  1. Clone openbmc/openbmc from GitHub.
  2. Clone this layer from GitHub into a subdirectory of openbmc.