Skip to content

Commit 6b8e327

Browse files
nathanchancedavem330
authored andcommitted
net: fddi: skfp: Remove unused function
Clang warns when a variable is assigned to itself. drivers/net/fddi/skfp/pcmplc.c:1257:6: warning: explicitly assigning value of variable of type 'int' to itself [-Wself-assign] phy = phy ; on_off = on_off ; ~~~ ^ ~~~ drivers/net/fddi/skfp/pcmplc.c:1257:21: warning: explicitly assigning value of variable of type 'int' to itself [-Wself-assign] phy = phy ; on_off = on_off ; ~~~~~~ ^ ~~~~~~ 2 warnings generated. Turns out this entire function doesn't actually do anything since SK_UNUSED is just casting the pointer to void. Remove it to silence this Clang warning. Link: ClangBuiltLinux/linux#128 Signed-off-by: Nathan Chancellor <[email protected]> Signed-off-by: David S. Miller <[email protected]>
1 parent 83b4768 commit 6b8e327

File tree

3 files changed

+0
-15
lines changed

3 files changed

+0
-15
lines changed

drivers/net/fddi/skfp/ecm.c

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,6 @@
3030
*
3131
* The following external HW dependent functions are referenced :
3232
* sm_pm_bypass_req()
33-
* sm_pm_ls_latch()
3433
* sm_pm_get_ls()
3534
*
3635
* The following HW dependent events are required :
@@ -356,8 +355,6 @@ static void ecm_fsm(struct s_smc *smc, int cmd)
356355
*/
357356
start_ecm_timer(smc,smc->s.ecm_check_poll,0) ;
358357
smc->e.ecm_line_state = TRUE ; /* flag to pcm: report Q/HLS */
359-
(void) sm_pm_ls_latch(smc,PA,1) ; /* enable line state latch */
360-
(void) sm_pm_ls_latch(smc,PB,1) ; /* enable line state latch */
361358
ACTIONS_DONE() ;
362359
break ;
363360
case EC6_CHECK :

drivers/net/fddi/skfp/h/cmtdef.h

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -513,7 +513,6 @@ void pcm_status_state(struct s_smc *smc, int np, int *type, int *state,
513513
void plc_config_mux(struct s_smc *smc, int mux);
514514
void sm_lem_evaluate(struct s_smc *smc);
515515
void mac_update_counter(struct s_smc *smc);
516-
void sm_pm_ls_latch(struct s_smc *smc, int phy, int on_off);
517516
void sm_ma_control(struct s_smc *smc, int mode);
518517
void sm_mac_check_beacon_claim(struct s_smc *smc);
519518
void config_mux(struct s_smc *smc, int mux);

drivers/net/fddi/skfp/pcmplc.c

Lines changed: 0 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,6 @@
3030
* The following external HW dependent functions are referenced :
3131
* sm_pm_control()
3232
* sm_ph_linestate()
33-
* sm_pm_ls_latch()
3433
*
3534
* The following HW dependent events are required :
3635
* PC_QLS
@@ -1248,16 +1247,6 @@ static void sm_ph_lem_stop(struct s_smc *smc, int np)
12481247
CLEAR(PLC(np,PL_INTR_MASK),PL_LE_CTR) ;
12491248
}
12501249

1251-
/* ARGSUSED */
1252-
void sm_pm_ls_latch(struct s_smc *smc, int phy, int on_off)
1253-
/* int on_off; en- or disable ident. ls */
1254-
{
1255-
SK_UNUSED(smc) ;
1256-
1257-
phy = phy ; on_off = on_off ;
1258-
}
1259-
1260-
12611250
/*
12621251
* PCM pseudo code
12631252
* receive actions are called AFTER the bit n is received,

0 commit comments

Comments
 (0)