diff mbox series

[net] r8169: add missing conditional compiling for call to r8169_remove_leds

Message ID d080038c-eb6b-45ac-9237-b8c1cdd7870f@gmail.com (mailing list archive)
State Accepted
Commit 97e176fcbbf3c0f2bd410c9b241177c051f57176
Delegated to: Netdev Maintainers
Headers show
Series [net] r8169: add missing conditional compiling for call to r8169_remove_leds | expand

Checks

Context Check Description
netdev/series_format success Single patches do not need cover letters
netdev/tree_selection success Clearly marked for net
netdev/ynl success Generated files up to date; no warnings/errors; no diff in generated;
netdev/fixes_present success Fixes tag present in non-next series
netdev/header_inline success No static functions without inline keyword in header files
netdev/build_32bit success Errors and warnings before: 942 this patch: 942
netdev/build_tools success No tools touched, skip
netdev/cc_maintainers fail 1 blamed authors not CCed: andrew@lunn.ch; 1 maintainers not CCed: andrew@lunn.ch
netdev/build_clang success Errors and warnings before: 953 this patch: 953
netdev/verify_signedoff success Signed-off-by tag matches author and committer
netdev/deprecated_api success None detected
netdev/check_selftest success No net selftest shell script
netdev/verify_fixes success Fixes tag looks correct
netdev/build_allmodconfig_warn success Errors and warnings before: 953 this patch: 953
netdev/checkpatch success total: 0 errors, 0 warnings, 0 checks, 9 lines checked
netdev/build_clang_rust success No Rust files in patch. Skipping build
netdev/kdoc success Errors and warnings before: 0 this patch: 0
netdev/source_inline success Was 0 now: 0
netdev/contest success net-next-2024-04-11--00-00 (tests: 959)

Commit Message

Heiner Kallweit April 10, 2024, 1:11 p.m. UTC
Add missing dependency on CONFIG_R8169_LEDS. As-is a link error occurs
if config option CONFIG_R8169_LEDS isn't enabled.

Fixes: 19fa4f2a85d7 ("r8169: fix LED-related deadlock on module removal")
Reported-by: Venkat Rao Bagalkote <venkat88@linux.vnet.ibm.com>
Signed-off-by: Heiner Kallweit <hkallweit1@gmail.com>
---
 drivers/net/ethernet/realtek/r8169_main.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

Comments

Venkat Rao Bagalkote April 10, 2024, 6:39 p.m. UTC | #1
Applied the patch and verified the reported issue.

Kernel compilation is successful on PowerPC with this patch.


Tested-By: Venkat Rao Bagalkote <venkat88@linux.vnet.ibm.com>

On 10/04/24 6:41 pm, Heiner Kallweit wrote:
> Add missing dependency on CONFIG_R8169_LEDS. As-is a link error occurs
> if config option CONFIG_R8169_LEDS isn't enabled.
>
> Fixes: 19fa4f2a85d7 ("r8169: fix LED-related deadlock on module removal")
> Reported-by: Venkat Rao Bagalkote <venkat88@linux.vnet.ibm.com>
> Signed-off-by: Heiner Kallweit <hkallweit1@gmail.com>
> ---
>   drivers/net/ethernet/realtek/r8169_main.c | 3 ++-
>   1 file changed, 2 insertions(+), 1 deletion(-)
>
> diff --git a/drivers/net/ethernet/realtek/r8169_main.c b/drivers/net/ethernet/realtek/r8169_main.c
> index 06631a0d6..746ef4f34 100644
> --- a/drivers/net/ethernet/realtek/r8169_main.c
> +++ b/drivers/net/ethernet/realtek/r8169_main.c
> @@ -5046,7 +5046,8 @@ static void rtl_remove_one(struct pci_dev *pdev)
>
>   	cancel_work_sync(&tp->wk.work);
>
> -	r8169_remove_leds(tp->leds);
> +	if (IS_ENABLED(CONFIG_R8169_LEDS))
> +		r8169_remove_leds(tp->leds);
>
>   	unregister_netdev(tp->dev);
>
patchwork-bot+netdevbpf@kernel.org April 11, 2024, 2 a.m. UTC | #2
Hello:

This patch was applied to netdev/net.git (main)
by Jakub Kicinski <kuba@kernel.org>:

On Wed, 10 Apr 2024 15:11:28 +0200 you wrote:
> Add missing dependency on CONFIG_R8169_LEDS. As-is a link error occurs
> if config option CONFIG_R8169_LEDS isn't enabled.
> 
> Fixes: 19fa4f2a85d7 ("r8169: fix LED-related deadlock on module removal")
> Reported-by: Venkat Rao Bagalkote <venkat88@linux.vnet.ibm.com>
> Signed-off-by: Heiner Kallweit <hkallweit1@gmail.com>
> 
> [...]

Here is the summary with links:
  - [net] r8169: add missing conditional compiling for call to r8169_remove_leds
    https://git.kernel.org/netdev/net/c/97e176fcbbf3

You are awesome, thank you!
diff mbox series

Patch

diff --git a/drivers/net/ethernet/realtek/r8169_main.c b/drivers/net/ethernet/realtek/r8169_main.c
index 06631a0d6..746ef4f34 100644
--- a/drivers/net/ethernet/realtek/r8169_main.c
+++ b/drivers/net/ethernet/realtek/r8169_main.c
@@ -5046,7 +5046,8 @@  static void rtl_remove_one(struct pci_dev *pdev)
 
 	cancel_work_sync(&tp->wk.work);
 
-	r8169_remove_leds(tp->leds);
+	if (IS_ENABLED(CONFIG_R8169_LEDS))
+		r8169_remove_leds(tp->leds);
 
 	unregister_netdev(tp->dev);