staging: r8188eu: fix rtw_alloc_hwxmits error detection for now
Phillip Potter authored
[ Upstream commit 5b7419ae ]

In _rtw_init_xmit_priv, we use the res variable to store the error
return from the newly converted rtw_alloc_hwxmits function. Sadly, the
calling function interprets res using _SUCCESS and _FAIL still, meaning
we change the semantics of the variable, even in the success case.

This leads to the following on boot:
r8188eu 1-2:1.0: _rtw_init_xmit_priv failed

In the long term, we should reverse these semantics, but for now, this
fixes the driver. Also, inside rtw_alloc_hwxmits remove the if blocks,
as HWXMIT_ENTRY is always 4.

Fixes: f94b47c6

 ("staging: r8188eu: add check for kzalloc")
Signed-off-by: default avatarPhillip Potter <phil@philpotter.co.uk>
Link: https://lore.kernel.org/r/20220521204741.921-1-phil@philpotter.co.uk

Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Signed-off-by: default avatarSasha Levin <sashal@kernel.org>
d56bc9e8
Name Last commit Last update
Documentation x86/speculation/mmio: Add sysfs reporting for Processor MMIO Stale Data
LICENSES LICENSES/dual/CC-BY-4.0: Git rid of "smart quotes"
arch powerpc/kasan: Silence KASAN warnings in __get_wchan()
block block: make bioset_exit() fully resilient against being called twice
certs certs: Add support for using elliptic curve keys for signing modules
crypto crypto: cryptd - Protect per-CPU resource by disabling BH.
drivers staging: r8188eu: fix rtw_alloc_hwxmits error detection for now
fs quota: Prevent memory allocation recursion while holding dq_lock
include x86/speculation/mmio: Add sysfs reporting for Processor MMIO Stale Data
init Kconfig: Add option for asm goto w/ tied outputs to workaround clang-13 bug
ipc ipc/mqueue: use get_tree_nodev() in mqueue_get_tree()
kernel dma-debug: make things less spammy under memory pressure
lib iov_iter: fix build issue due to possible type mis-match
mm mm/memremap: fix missing call to untrack_pfn() in pagemap_range()
net ipv6: Fix signed integer overflow in l2tp_ip6_sendmsg
samples samples/landlock: Format with clang-format
scripts scripts/gdb: change kernel config dumping method
security KEYS: trusted: tpm2: Fix migratable logic
sound ALSA: hda/realtek - Add HW8326 support
tools KVM: x86/speculation: Disable Fill buffer clear within guests
usr usr/include/Makefile: add linux/nfc.h to the compile-test coverage
virt KVM: avoid NULL pointer dereference in kvm_dirty_ring_push
.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 .gitattributes: use 'dts' diff driver for dts files
.gitignore .gitignore: ignore only top-level modules.builtin
.mailmap mailmap: add Andrej Shadura
COPYING COPYING: state that all contributions really are covered by this file
CREDITS MAINTAINERS: Move Daniel Drake to credits
Kbuild kbuild: rename hostprogs-y/always to hostprogs/always-y
Kconfig kbuild: ensure full rebuild when the compiler is updated
MAINTAINERS MAINTAINERS: add git tree for random.c
Makefile gcc-12: disable '-Wdangling-pointer' warning for now
README Drop all 00-INDEX files from Documentation/
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.