CVE-2022-50728
Description
In the Linux kernel, the following vulnerability has been resolved:
s390/lcs: Fix return type of lcs_start_xmit()
With clang's kernel control flow integrity (kCFI, CONFIG_CFI_CLANG), indirect call targets are validated against the expected function pointer prototype to make sure the call target is valid to help mitigate ROP attacks. If they are not identical, there is a failure at run time, which manifests as either a kernel panic or thread getting killed. A proposed warning in clang aims to catch these at compile time, which reveals:
drivers/s390/net/lcs.c:2090:21: error: incompatible function pointer types initializing 'netdev_tx_t (*)(struct sk_buff *, struct net_device *)' (aka 'enum netdev_tx (*)(struct sk_buff *, struct net_device *)') with an expression of type 'int (struct sk_buff *, struct net_device *)' [-Werror,-Wincompatible-function-pointer-types-strict] .ndo_start_xmit = lcs_start_xmit, ^~~~~~~~~~~~~~ drivers/s390/net/lcs.c:2097:21: error: incompatible function pointer types initializing 'netdev_tx_t (*)(struct sk_buff *, struct net_device *)' (aka 'enum netdev_tx (*)(struct sk_buff *, struct net_device *)') with an expression of type 'int (struct sk_buff *, struct net_device *)' [-Werror,-Wincompatible-function-pointer-types-strict] .ndo_start_xmit = lcs_start_xmit, ^~~~~~~~~~~~~~
->ndo_start_xmit() in 'struct net_device_ops' expects a return type of 'netdev_tx_t', not 'int'. Adjust the return type of lcs_start_xmit() to match the prototype's to resolve the warning and potential CFI failure, should s390 select ARCH_SUPPORTS_CFI_CLANG in the future.
AI Insight
LLM-synthesized narrative grounded in this CVE's description and references.
In the Linux kernel's s390 LCS network driver, lcs_start_xmit() incorrectly returns 'int' instead of 'netdev_tx_t', which can cause Control Flow Integrity (kCFI) panic or thread termination.
Vulnerability
Analysis
In the Linux kernel's s390 LCS (LAN Channel Station) network driver, the function lcs_start_xmit() is declared to return int, but the ndo_start_xmit callback in struct net_device_ops expects a return type of netdev_tx_t (which is an enum). This type mismatch is detected by clang's Control Flow Integrity (kCFI, CONFIG_CFI_CLANG) at runtime, causing a kernel panic or thread termination when the driver is used with kCFI enabled [1].
Attack
Vector and Requirements
No special attacker-triggered exploitation is described. The vulnerability manifests during normal transmission of network packets over an s390 LCS interface when the kernel is compiled with clang kCFI. The issue is not exploitable by an unauthenticated remote attacker directly; it is a correctness flaw that can lead to denial of service (kernel panic) under specific kernel configurations. The bug is a static type mismatch that is only reachable when the driver's transmit function is called by the networking stack [2].
Impact
If the kernel is built with CONFIG_CFI_CLANG (and ARCH_SUPPORTS_CFI_CLANG is selected for s390 in the future), an attempted call to lcs_start_xmit() will fail the indirect call target validation, resulting in one of two outcomes: a kernel panic (system crash) or the offending kernel thread being killed, effectively causing a denial of service for any process relying on network I/O over that interface. No privilege escalation or remote code execution is indicated [3].
Mitigation
The fix adjusts the return type of lcs_start_xmit() from int to netdev_tx_t to match the prototype expected by the kernel's networking subsystem [4]. This resolves the compile-time warning from clang and prevents the potential CFI failure at run time. The patch has been applied to the Linux kernel stable branches. Users should update to a kernel version containing the commit [1][4].
AI Insight generated on May 19, 2026. Synthesized from this CVE's description and the cited reference URLs; citations are validated against the source bundle.
Affected products
1Patches
97b4da3fcd513d49cc2b70571e684215d8a9020022d551f20ebc3c77785dc5ad774fb823c69669820844fcda74cdc280bbb16db839365Vulnerability mechanics
Generated on May 9, 2026. Inputs: CWE entries + fix-commit diffs from this CVE's patches. Citations validated against bundle.
References
9- git.kernel.org/stable/c/20022d551f2064a194d8e0acb6cd7a85094a17b2nvd
- git.kernel.org/stable/c/5ad774fb823c24bbeb21a15a67103ea7a6f5b928nvd
- git.kernel.org/stable/c/69669820844f81a77b6db24b86581320ae4d17afnvd
- git.kernel.org/stable/c/7b4da3fcd513b8e67823eb80da37aad99b3339c1nvd
- git.kernel.org/stable/c/bb16db8393658e0978c3f0d30ae069e878264fa3nvd
- git.kernel.org/stable/c/cda74cdc280ba35c8993e7517bac5c257ff36f18nvd
- git.kernel.org/stable/c/d49cc2b705711fb8fb849e7c660929b2100360b7nvd
- git.kernel.org/stable/c/e684215d8a903752e2b0cc946517fb61e57a880anvd
- git.kernel.org/stable/c/ebc3c77785dc8b5b626309c0032a38fbb139287anvd
News mentions
0No linked articles in our index yet.