Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1520204 > unrolled thread

[PATCH 1/1 linux-next] ALSA: rawmidi: don't opencode IS_REACHABLE()

Started byFabian Frederick <fabf@skynet.be>
First post2016-11-12 09:40 +0100
Last post2016-11-12 10:20 +0100
Articles 2 — 2 participants

Back to article view | Back to linux.kernel


Contents

  [PATCH 1/1 linux-next] ALSA: rawmidi: don't opencode IS_REACHABLE() Fabian Frederick <fabf@skynet.be> - 2016-11-12 09:40 +0100
    Re: [PATCH 1/1 linux-next] ALSA: rawmidi: don't opencode IS_REACHABLE() Takashi Iwai <tiwai@suse.de> - 2016-11-12 10:20 +0100

#1520204 — [PATCH 1/1 linux-next] ALSA: rawmidi: don't opencode IS_REACHABLE()

FromFabian Frederick <fabf@skynet.be>
Date2016-11-12 09:40 +0100
Subject[PATCH 1/1 linux-next] ALSA: rawmidi: don't opencode IS_REACHABLE()
Message-ID<sCC0W-82Y-3@gated-at.bofh.it>
Signed-off-by: Fabian Frederick <fabf@skynet.be>
---
 sound/core/rawmidi.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/sound/core/rawmidi.c b/sound/core/rawmidi.c
index b450a27..2096bb0 100644
--- a/sound/core/rawmidi.c
+++ b/sound/core/rawmidi.c
@@ -1610,7 +1610,7 @@ static int snd_rawmidi_dev_free(struct snd_device *device)
 	return snd_rawmidi_free(rmidi);
 }
 
-#if defined(CONFIG_SND_SEQUENCER) || (defined(MODULE) && defined(CONFIG_SND_SEQUENCER_MODULE))
+#if IS_REACHABLE(CONFIG_SND_SEQUENCER)
 static void snd_rawmidi_dev_seq_free(struct snd_seq_device *device)
 {
 	struct snd_rawmidi *rmidi = device->private_data;
@@ -1691,7 +1691,7 @@ static int snd_rawmidi_dev_register(struct snd_device *device)
 		}
 	}
 	rmidi->proc_entry = entry;
-#if defined(CONFIG_SND_SEQUENCER) || (defined(MODULE) && defined(CONFIG_SND_SEQUENCER_MODULE))
+#if IS_REACHABLE(CONFIG_SND_SEQUENCER)
 	if (!rmidi->ops || !rmidi->ops->dev_register) { /* own registration mechanism */
 		if (snd_seq_device_new(rmidi->card, rmidi->device, SNDRV_SEQ_DEV_ID_MIDISYNTH, 0, &rmidi->seq_dev) >= 0) {
 			rmidi->seq_dev->private_data = rmidi;
-- 
2.7.4

[toc] | [next] | [standalone]


#1520212

FromTakashi Iwai <tiwai@suse.de>
Date2016-11-12 10:20 +0100
Message-ID<sCCDE-8uX-9@gated-at.bofh.it>
In reply to#1520204
On Sat, 12 Nov 2016 09:34:49 +0100,
Fabian Frederick wrote:
> 
> Signed-off-by: Fabian Frederick <fabf@skynet.be>

Applied, thanks.


Takashi


> ---
>  sound/core/rawmidi.c | 4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)
> 
> diff --git a/sound/core/rawmidi.c b/sound/core/rawmidi.c
> index b450a27..2096bb0 100644
> --- a/sound/core/rawmidi.c
> +++ b/sound/core/rawmidi.c
> @@ -1610,7 +1610,7 @@ static int snd_rawmidi_dev_free(struct snd_device *device)
>  	return snd_rawmidi_free(rmidi);
>  }
>  
> -#if defined(CONFIG_SND_SEQUENCER) || (defined(MODULE) && defined(CONFIG_SND_SEQUENCER_MODULE))
> +#if IS_REACHABLE(CONFIG_SND_SEQUENCER)
>  static void snd_rawmidi_dev_seq_free(struct snd_seq_device *device)
>  {
>  	struct snd_rawmidi *rmidi = device->private_data;
> @@ -1691,7 +1691,7 @@ static int snd_rawmidi_dev_register(struct snd_device *device)
>  		}
>  	}
>  	rmidi->proc_entry = entry;
> -#if defined(CONFIG_SND_SEQUENCER) || (defined(MODULE) && defined(CONFIG_SND_SEQUENCER_MODULE))
> +#if IS_REACHABLE(CONFIG_SND_SEQUENCER)
>  	if (!rmidi->ops || !rmidi->ops->dev_register) { /* own registration mechanism */
>  		if (snd_seq_device_new(rmidi->card, rmidi->device, SNDRV_SEQ_DEV_ID_MIDISYNTH, 0, &rmidi->seq_dev) >= 0) {
>  			rmidi->seq_dev->private_data = rmidi;
> -- 
> 2.7.4
> 

[toc] | [prev] | [standalone]


Back to top | Article view | linux.kernel


csiph-web