Subject: [PATCH V2 3/3] ath6kl: Remove deadcode in main.c

In ath6kl_reset_device(), since control can never reach switch..case
when the target_type is neither TARGET_TYPE_AR6003 nor TARGET_TYPE_AR6004,
remove the default option of switch statement.

Signed-off-by: Vasanthakumar Thiagarajan <[email protected]>
---
V2 -- Remove the hunk which removes dead code in
ie length validation. That would be fixed in
a different patch.

drivers/net/wireless/ath/ath6kl/main.c | 3 ---
1 files changed, 0 insertions(+), 3 deletions(-)

diff --git a/drivers/net/wireless/ath/ath6kl/main.c b/drivers/net/wireless/ath/ath6kl/main.c
index eea3c74..4b20abd 100644
--- a/drivers/net/wireless/ath/ath6kl/main.c
+++ b/drivers/net/wireless/ath/ath6kl/main.c
@@ -347,9 +347,6 @@ void ath6kl_reset_device(struct ath6kl *ar, u32 target_type,
case TARGET_TYPE_AR6004:
address = AR6004_RESET_CONTROL_ADDRESS;
break;
- default:
- address = AR6003_RESET_CONTROL_ADDRESS;
- break;
}

status = ath6kl_diag_write32(ar, address, data);
--
1.7.0.4



2012-01-09 10:45:16

by Kalle Valo

[permalink] [raw]
Subject: Re: [PATCH V2 3/3] ath6kl: Remove deadcode in main.c

On 01/03/2012 11:49 AM, Vasanthakumar Thiagarajan wrote:
> In ath6kl_reset_device(), since control can never reach switch..case
> when the target_type is neither TARGET_TYPE_AR6003 nor TARGET_TYPE_AR6004,
> remove the default option of switch statement.
>
> Signed-off-by: Vasanthakumar Thiagarajan <[email protected]>

Thanks, applied.

Kalle