Skip to content

Commit ce7d8f8

Browse files
Colin Ian Kinggregkh
authored andcommitted
misc: rtsx: make several functions static
Several helper functions are local to the source and do not need to be in global scope, so make them static. Cleans up sparse warnings: symbol 'rtsx_pm_power_saving' was not declared. Should it be static? symbol 'rtsx_set_l1off_sub_cfg_d0' was not declared. Should it be static? symbol 'rtsx_pm_full_on' was not declared. Should it be static? symbol 'rtsx_comm_set_ltr_latency' was not declared. Should it be static? symbol 'rtsx_pci_process_ocp' was not declared. Should it be static? symbol 'rtsx_pci_process_ocp_interrupt' was not declared. Should it be static? Signed-off-by: Colin Ian King <colin.king@canonical.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
1 parent c4bcaff commit ce7d8f8

1 file changed

Lines changed: 6 additions & 6 deletions

File tree

‎drivers/misc/cardreader/rtsx_pcr.c‎

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -80,7 +80,7 @@ static inline void rtsx_pci_disable_aspm(struct rtsx_pcr *pcr)
8080
0xFC, 0);
8181
}
8282

83-
int rtsx_comm_set_ltr_latency(struct rtsx_pcr *pcr, u32 latency)
83+
static int rtsx_comm_set_ltr_latency(struct rtsx_pcr *pcr, u32 latency)
8484
{
8585
rtsx_pci_write_register(pcr, MSGTXDATA0,
8686
MASK_8_BIT_DEF, (u8) (latency & 0xFF));
@@ -143,7 +143,7 @@ int rtsx_set_l1off_sub(struct rtsx_pcr *pcr, u8 val)
143143
return 0;
144144
}
145145

146-
void rtsx_set_l1off_sub_cfg_d0(struct rtsx_pcr *pcr, int active)
146+
static void rtsx_set_l1off_sub_cfg_d0(struct rtsx_pcr *pcr, int active)
147147
{
148148
if (pcr->ops->set_l1off_cfg_sub_d0)
149149
pcr->ops->set_l1off_cfg_sub_d0(pcr, active);
@@ -162,7 +162,7 @@ static void rtsx_comm_pm_full_on(struct rtsx_pcr *pcr)
162162
rtsx_set_l1off_sub_cfg_d0(pcr, 1);
163163
}
164164

165-
void rtsx_pm_full_on(struct rtsx_pcr *pcr)
165+
static void rtsx_pm_full_on(struct rtsx_pcr *pcr)
166166
{
167167
if (pcr->ops->full_on)
168168
pcr->ops->full_on(pcr);
@@ -967,13 +967,13 @@ static void rtsx_pci_card_detect(struct work_struct *work)
967967
pcr->slots[RTSX_MS_CARD].p_dev);
968968
}
969969

970-
void rtsx_pci_process_ocp(struct rtsx_pcr *pcr)
970+
static void rtsx_pci_process_ocp(struct rtsx_pcr *pcr)
971971
{
972972
if (pcr->ops->process_ocp)
973973
pcr->ops->process_ocp(pcr);
974974
}
975975

976-
int rtsx_pci_process_ocp_interrupt(struct rtsx_pcr *pcr)
976+
static int rtsx_pci_process_ocp_interrupt(struct rtsx_pcr *pcr)
977977
{
978978
if (pcr->option.ocp_en)
979979
rtsx_pci_process_ocp(pcr);
@@ -1094,7 +1094,7 @@ static void rtsx_comm_pm_power_saving(struct rtsx_pcr *pcr)
10941094
rtsx_enable_aspm(pcr);
10951095
}
10961096

1097-
void rtsx_pm_power_saving(struct rtsx_pcr *pcr)
1097+
static void rtsx_pm_power_saving(struct rtsx_pcr *pcr)
10981098
{
10991099
if (pcr->ops->power_saving)
11001100
pcr->ops->power_saving(pcr);

0 commit comments

Comments
 (0)