staging: r8188eu: merge _rtw_enqueue_cmd into its caller
authorMartin Kaiser <martin@kaiser.cx>
Sat, 11 Feb 2023 16:50:45 +0000 (17:50 +0100)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 16 Feb 2023 12:54:38 +0000 (13:54 +0100)
commitda8b09464c59c7c09f7ca880b607b5d8d0cc90fe
tree3b73048e600e9499ac859334ee84ca7d13e37d33
parenteec8ccab1b5760ae2221bc8235c09eb05a1132c6
staging: r8188eu: merge _rtw_enqueue_cmd into its caller

The _rtw_enqueue_cmd function is called only by rtw_enqueue_cmd.

When _rtw_enqueue_cmd is called, the caller has already checked that the
obj parameter is not NULL. _rtw_enqueue_cmd returns _SUCCESS in any case.

We can merge the two functions and simplify the error handling.

Signed-off-by: Martin Kaiser <martin@kaiser.cx>
Tested-by: Philipp Hortmann <philipp.g.hortmann@gmail.com> # Edimax N150
Link: https://lore.kernel.org/r/20230211165045.414424-1-martin@kaiser.cx
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/staging/r8188eu/core/rtw_cmd.c