diff options
author | Takashi Iwai <tiwai@suse.de> | 2015-05-29 02:00:06 -0400 |
---|---|---|
committer | Takashi Iwai <tiwai@suse.de> | 2015-05-29 02:00:06 -0400 |
commit | 3270f0dd1a35d6b785bf39e1ed7ed6e1e43c8ebb (patch) | |
tree | 0f79ee6172635ebe58c79a4bd011d54e4b89d717 | |
parent | 52262b4a5d7c3d3549985a47d96fe7d661220162 (diff) |
ALSA: pci: Drop superfluous ifdef CONFIG_PROC_FS
The compiler can optimize the unused code away, so we can drop
ifdefs.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
-rw-r--r-- | sound/pci/ak4531_codec.c | 6 | ||||
-rw-r--r-- | sound/pci/atiixp.c | 4 | ||||
-rw-r--r-- | sound/pci/atiixp_modem.c | 4 | ||||
-rw-r--r-- | sound/pci/cmipci.c | 5 | ||||
-rw-r--r-- | sound/pci/ice1712/quartet.c | 7 | ||||
-rw-r--r-- | sound/pci/intel8x0.c | 4 | ||||
-rw-r--r-- | sound/pci/intel8x0m.c | 5 | ||||
-rw-r--r-- | sound/pci/oxygen/oxygen_lib.c | 4 |
8 files changed, 1 insertions, 38 deletions
diff --git a/sound/pci/ak4531_codec.c b/sound/pci/ak4531_codec.c index 3bf0dc53360a..2fb1fbba3e5e 100644 --- a/sound/pci/ak4531_codec.c +++ b/sound/pci/ak4531_codec.c | |||
@@ -35,11 +35,7 @@ MODULE_DESCRIPTION("Universal routines for AK4531 codec"); | |||
35 | MODULE_LICENSE("GPL"); | 35 | MODULE_LICENSE("GPL"); |
36 | */ | 36 | */ |
37 | 37 | ||
38 | #ifdef CONFIG_PROC_FS | ||
39 | static void snd_ak4531_proc_init(struct snd_card *card, struct snd_ak4531 *ak4531); | 38 | static void snd_ak4531_proc_init(struct snd_card *card, struct snd_ak4531 *ak4531); |
40 | #else | ||
41 | #define snd_ak4531_proc_init(card,ak) | ||
42 | #endif | ||
43 | 39 | ||
44 | /* | 40 | /* |
45 | * | 41 | * |
@@ -466,7 +462,6 @@ void snd_ak4531_resume(struct snd_ak4531 *ak4531) | |||
466 | } | 462 | } |
467 | #endif | 463 | #endif |
468 | 464 | ||
469 | #ifdef CONFIG_PROC_FS | ||
470 | /* | 465 | /* |
471 | * /proc interface | 466 | * /proc interface |
472 | */ | 467 | */ |
@@ -491,4 +486,3 @@ snd_ak4531_proc_init(struct snd_card *card, struct snd_ak4531 *ak4531) | |||
491 | if (! snd_card_proc_new(card, "ak4531", &entry)) | 486 | if (! snd_card_proc_new(card, "ak4531", &entry)) |
492 | snd_info_set_text_ops(entry, ak4531, snd_ak4531_proc_read); | 487 | snd_info_set_text_ops(entry, ak4531, snd_ak4531_proc_read); |
493 | } | 488 | } |
494 | #endif | ||
diff --git a/sound/pci/atiixp.c b/sound/pci/atiixp.c index 42a20c806b39..1028fc8bdff5 100644 --- a/sound/pci/atiixp.c +++ b/sound/pci/atiixp.c | |||
@@ -1530,7 +1530,6 @@ static SIMPLE_DEV_PM_OPS(snd_atiixp_pm, snd_atiixp_suspend, snd_atiixp_resume); | |||
1530 | #endif /* CONFIG_PM_SLEEP */ | 1530 | #endif /* CONFIG_PM_SLEEP */ |
1531 | 1531 | ||
1532 | 1532 | ||
1533 | #ifdef CONFIG_PROC_FS | ||
1534 | /* | 1533 | /* |
1535 | * proc interface for register dump | 1534 | * proc interface for register dump |
1536 | */ | 1535 | */ |
@@ -1552,9 +1551,6 @@ static void snd_atiixp_proc_init(struct atiixp *chip) | |||
1552 | if (! snd_card_proc_new(chip->card, "atiixp", &entry)) | 1551 | if (! snd_card_proc_new(chip->card, "atiixp", &entry)) |
1553 | snd_info_set_text_ops(entry, chip, snd_atiixp_proc_read); | 1552 | snd_info_set_text_ops(entry, chip, snd_atiixp_proc_read); |
1554 | } | 1553 | } |
1555 | #else /* !CONFIG_PROC_FS */ | ||
1556 | #define snd_atiixp_proc_init(chip) | ||
1557 | #endif | ||
1558 | 1554 | ||
1559 | 1555 | ||
1560 | /* | 1556 | /* |
diff --git a/sound/pci/atiixp_modem.c b/sound/pci/atiixp_modem.c index 0a38e08164ab..27ed678a46df 100644 --- a/sound/pci/atiixp_modem.c +++ b/sound/pci/atiixp_modem.c | |||
@@ -1156,7 +1156,6 @@ static SIMPLE_DEV_PM_OPS(snd_atiixp_pm, snd_atiixp_suspend, snd_atiixp_resume); | |||
1156 | #define SND_ATIIXP_PM_OPS NULL | 1156 | #define SND_ATIIXP_PM_OPS NULL |
1157 | #endif /* CONFIG_PM_SLEEP */ | 1157 | #endif /* CONFIG_PM_SLEEP */ |
1158 | 1158 | ||
1159 | #ifdef CONFIG_PROC_FS | ||
1160 | /* | 1159 | /* |
1161 | * proc interface for register dump | 1160 | * proc interface for register dump |
1162 | */ | 1161 | */ |
@@ -1178,9 +1177,6 @@ static void snd_atiixp_proc_init(struct atiixp_modem *chip) | |||
1178 | if (! snd_card_proc_new(chip->card, "atiixp-modem", &entry)) | 1177 | if (! snd_card_proc_new(chip->card, "atiixp-modem", &entry)) |
1179 | snd_info_set_text_ops(entry, chip, snd_atiixp_proc_read); | 1178 | snd_info_set_text_ops(entry, chip, snd_atiixp_proc_read); |
1180 | } | 1179 | } |
1181 | #else | ||
1182 | #define snd_atiixp_proc_init(chip) | ||
1183 | #endif | ||
1184 | 1180 | ||
1185 | 1181 | ||
1186 | /* | 1182 | /* |
diff --git a/sound/pci/cmipci.c b/sound/pci/cmipci.c index 6cf464d9043d..24cdcba06d27 100644 --- a/sound/pci/cmipci.c +++ b/sound/pci/cmipci.c | |||
@@ -2772,7 +2772,6 @@ static int snd_cmipci_mixer_new(struct cmipci *cm, int pcm_spdif_device) | |||
2772 | * proc interface | 2772 | * proc interface |
2773 | */ | 2773 | */ |
2774 | 2774 | ||
2775 | #ifdef CONFIG_PROC_FS | ||
2776 | static void snd_cmipci_proc_read(struct snd_info_entry *entry, | 2775 | static void snd_cmipci_proc_read(struct snd_info_entry *entry, |
2777 | struct snd_info_buffer *buffer) | 2776 | struct snd_info_buffer *buffer) |
2778 | { | 2777 | { |
@@ -2798,10 +2797,6 @@ static void snd_cmipci_proc_init(struct cmipci *cm) | |||
2798 | if (! snd_card_proc_new(cm->card, "cmipci", &entry)) | 2797 | if (! snd_card_proc_new(cm->card, "cmipci", &entry)) |
2799 | snd_info_set_text_ops(entry, cm, snd_cmipci_proc_read); | 2798 | snd_info_set_text_ops(entry, cm, snd_cmipci_proc_read); |
2800 | } | 2799 | } |
2801 | #else /* !CONFIG_PROC_FS */ | ||
2802 | static inline void snd_cmipci_proc_init(struct cmipci *cm) {} | ||
2803 | #endif | ||
2804 | |||
2805 | 2800 | ||
2806 | static const struct pci_device_id snd_cmipci_ids[] = { | 2801 | static const struct pci_device_id snd_cmipci_ids[] = { |
2807 | {PCI_VDEVICE(CMEDIA, PCI_DEVICE_ID_CMEDIA_CM8338A), 0}, | 2802 | {PCI_VDEVICE(CMEDIA, PCI_DEVICE_ID_CMEDIA_CM8338A), 0}, |
diff --git a/sound/pci/ice1712/quartet.c b/sound/pci/ice1712/quartet.c index 6f55e02e5c84..7c387b04067e 100644 --- a/sound/pci/ice1712/quartet.c +++ b/sound/pci/ice1712/quartet.c | |||
@@ -203,7 +203,6 @@ static const char * const ext_clock_names[3] = {"IEC958 In", "Word Clock 1xFS", | |||
203 | #define AK4620_DEEMVOL_REG 0x03 | 203 | #define AK4620_DEEMVOL_REG 0x03 |
204 | #define AK4620_SMUTE (1<<7) | 204 | #define AK4620_SMUTE (1<<7) |
205 | 205 | ||
206 | #ifdef CONFIG_PROC_FS | ||
207 | /* | 206 | /* |
208 | * Conversion from int value to its binary form. Used for debugging. | 207 | * Conversion from int value to its binary form. Used for debugging. |
209 | * The output buffer must be allocated prior to calling the function. | 208 | * The output buffer must be allocated prior to calling the function. |
@@ -228,7 +227,6 @@ static char *get_binary(char *buffer, int value) | |||
228 | buffer[pos] = '\0'; | 227 | buffer[pos] = '\0'; |
229 | return buffer; | 228 | return buffer; |
230 | } | 229 | } |
231 | #endif /* CONFIG_PROC_FS */ | ||
232 | 230 | ||
233 | /* | 231 | /* |
234 | * Initial setup of the conversion array GPIO <-> rate | 232 | * Initial setup of the conversion array GPIO <-> rate |
@@ -486,7 +484,7 @@ static void set_cpld(struct snd_ice1712 *ice, unsigned int val) | |||
486 | reg_write(ice, GPIO_CPLD_CSN, val); | 484 | reg_write(ice, GPIO_CPLD_CSN, val); |
487 | spec->cpld = val; | 485 | spec->cpld = val; |
488 | } | 486 | } |
489 | #ifdef CONFIG_PROC_FS | 487 | |
490 | static void proc_regs_read(struct snd_info_entry *entry, | 488 | static void proc_regs_read(struct snd_info_entry *entry, |
491 | struct snd_info_buffer *buffer) | 489 | struct snd_info_buffer *buffer) |
492 | { | 490 | { |
@@ -507,9 +505,6 @@ static void proc_init(struct snd_ice1712 *ice) | |||
507 | if (!snd_card_proc_new(ice->card, "quartet", &entry)) | 505 | if (!snd_card_proc_new(ice->card, "quartet", &entry)) |
508 | snd_info_set_text_ops(entry, ice, proc_regs_read); | 506 | snd_info_set_text_ops(entry, ice, proc_regs_read); |
509 | } | 507 | } |
510 | #else /* !CONFIG_PROC_FS */ | ||
511 | static void proc_init(struct snd_ice1712 *ice) {} | ||
512 | #endif | ||
513 | 508 | ||
514 | static int qtet_mute_get(struct snd_kcontrol *kcontrol, | 509 | static int qtet_mute_get(struct snd_kcontrol *kcontrol, |
515 | struct snd_ctl_elem_value *ucontrol) | 510 | struct snd_ctl_elem_value *ucontrol) |
diff --git a/sound/pci/intel8x0.c b/sound/pci/intel8x0.c index b120925223ae..42bcbac801a3 100644 --- a/sound/pci/intel8x0.c +++ b/sound/pci/intel8x0.c | |||
@@ -2900,7 +2900,6 @@ static int intel8x0_in_clock_list(struct intel8x0 *chip) | |||
2900 | return 1; | 2900 | return 1; |
2901 | } | 2901 | } |
2902 | 2902 | ||
2903 | #ifdef CONFIG_PROC_FS | ||
2904 | static void snd_intel8x0_proc_read(struct snd_info_entry * entry, | 2903 | static void snd_intel8x0_proc_read(struct snd_info_entry * entry, |
2905 | struct snd_info_buffer *buffer) | 2904 | struct snd_info_buffer *buffer) |
2906 | { | 2905 | { |
@@ -2942,9 +2941,6 @@ static void snd_intel8x0_proc_init(struct intel8x0 *chip) | |||
2942 | if (! snd_card_proc_new(chip->card, "intel8x0", &entry)) | 2941 | if (! snd_card_proc_new(chip->card, "intel8x0", &entry)) |
2943 | snd_info_set_text_ops(entry, chip, snd_intel8x0_proc_read); | 2942 | snd_info_set_text_ops(entry, chip, snd_intel8x0_proc_read); |
2944 | } | 2943 | } |
2945 | #else | ||
2946 | #define snd_intel8x0_proc_init(x) | ||
2947 | #endif | ||
2948 | 2944 | ||
2949 | static int snd_intel8x0_dev_free(struct snd_device *device) | 2945 | static int snd_intel8x0_dev_free(struct snd_device *device) |
2950 | { | 2946 | { |
diff --git a/sound/pci/intel8x0m.c b/sound/pci/intel8x0m.c index 7577f31cd504..1bc98c867133 100644 --- a/sound/pci/intel8x0m.c +++ b/sound/pci/intel8x0m.c | |||
@@ -1065,7 +1065,6 @@ static SIMPLE_DEV_PM_OPS(intel8x0m_pm, intel8x0m_suspend, intel8x0m_resume); | |||
1065 | #define INTEL8X0M_PM_OPS NULL | 1065 | #define INTEL8X0M_PM_OPS NULL |
1066 | #endif /* CONFIG_PM_SLEEP */ | 1066 | #endif /* CONFIG_PM_SLEEP */ |
1067 | 1067 | ||
1068 | #ifdef CONFIG_PROC_FS | ||
1069 | static void snd_intel8x0m_proc_read(struct snd_info_entry * entry, | 1068 | static void snd_intel8x0m_proc_read(struct snd_info_entry * entry, |
1070 | struct snd_info_buffer *buffer) | 1069 | struct snd_info_buffer *buffer) |
1071 | { | 1070 | { |
@@ -1093,10 +1092,6 @@ static void snd_intel8x0m_proc_init(struct intel8x0m *chip) | |||
1093 | if (! snd_card_proc_new(chip->card, "intel8x0m", &entry)) | 1092 | if (! snd_card_proc_new(chip->card, "intel8x0m", &entry)) |
1094 | snd_info_set_text_ops(entry, chip, snd_intel8x0m_proc_read); | 1093 | snd_info_set_text_ops(entry, chip, snd_intel8x0m_proc_read); |
1095 | } | 1094 | } |
1096 | #else /* !CONFIG_PROC_FS */ | ||
1097 | #define snd_intel8x0m_proc_init(chip) | ||
1098 | #endif /* CONFIG_PROC_FS */ | ||
1099 | |||
1100 | 1095 | ||
1101 | static int snd_intel8x0m_dev_free(struct snd_device *device) | 1096 | static int snd_intel8x0m_dev_free(struct snd_device *device) |
1102 | { | 1097 | { |
diff --git a/sound/pci/oxygen/oxygen_lib.c b/sound/pci/oxygen/oxygen_lib.c index ffff3b25fd73..b4ef5804212d 100644 --- a/sound/pci/oxygen/oxygen_lib.c +++ b/sound/pci/oxygen/oxygen_lib.c | |||
@@ -196,7 +196,6 @@ static void oxygen_gpio_changed(struct work_struct *work) | |||
196 | chip->model.gpio_changed(chip); | 196 | chip->model.gpio_changed(chip); |
197 | } | 197 | } |
198 | 198 | ||
199 | #ifdef CONFIG_PROC_FS | ||
200 | static void oxygen_proc_read(struct snd_info_entry *entry, | 199 | static void oxygen_proc_read(struct snd_info_entry *entry, |
201 | struct snd_info_buffer *buffer) | 200 | struct snd_info_buffer *buffer) |
202 | { | 201 | { |
@@ -250,9 +249,6 @@ static void oxygen_proc_init(struct oxygen *chip) | |||
250 | if (!snd_card_proc_new(chip->card, "oxygen", &entry)) | 249 | if (!snd_card_proc_new(chip->card, "oxygen", &entry)) |
251 | snd_info_set_text_ops(entry, chip, oxygen_proc_read); | 250 | snd_info_set_text_ops(entry, chip, oxygen_proc_read); |
252 | } | 251 | } |
253 | #else | ||
254 | #define oxygen_proc_init(chip) | ||
255 | #endif | ||
256 | 252 | ||
257 | static const struct pci_device_id * | 253 | static const struct pci_device_id * |
258 | oxygen_search_pci_id(struct oxygen *chip, const struct pci_device_id ids[]) | 254 | oxygen_search_pci_id(struct oxygen *chip, const struct pci_device_id ids[]) |