From: Takashi Iwai <tiwai@suse.de>
To: Chris Rorvick <chris@rorvick.com>
Cc: alsa-devel@alsa-project.org, linux-kernel@vger.kernel.org,
Stefan Hajnoczi <stefanha@gmail.com>
Subject: Re: [PATCH 1/4] ALSA: line6: Add toneport_has_source_select()
Date: Fri, 06 Feb 2015 15:56:15 +0100 [thread overview]
Message-ID: <s5hioffw0kw.wl-tiwai@suse.de> (raw)
In-Reply-To: <1423234272-7348-2-git-send-email-chris@rorvick.com>
At Fri, 6 Feb 2015 08:51:09 -0600,
Chris Rorvick wrote:
>
> Add a predicate for testing if the device supports source selection to
> make the conditional logic around this a bit cleaner.
>
> Signed-off-by: Chris Rorvick <chris@rorvick.com>
> ---
> sound/usb/line6/toneport.c | 32 ++++++++++++++++----------------
> 1 file changed, 16 insertions(+), 16 deletions(-)
>
> diff --git a/sound/usb/line6/toneport.c b/sound/usb/line6/toneport.c
> index b107cf4..de56180a 100644
> --- a/sound/usb/line6/toneport.c
> +++ b/sound/usb/line6/toneport.c
> @@ -343,6 +343,20 @@ static void toneport_remove_leds(struct usb_line6_toneport *toneport)
> }
> }
>
> +static bool toneport_has_source_select(struct usb_line6_toneport *toneport)
> +{
> + switch (toneport->type) {
> + case LINE6_TONEPORT_UX1:
> + case LINE6_TONEPORT_UX2:
> + case LINE6_PODSTUDIO_UX1:
> + case LINE6_PODSTUDIO_UX2:
> + return 1;
> +
> + default:
> + return 0;
Please use true and false.
Takashi
next prev parent reply other threads:[~2015-02-06 14:56 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-02-06 14:51 [PATCH 0/4] More Line 6 cleanup Chris Rorvick
2015-02-06 14:51 ` [PATCH 1/4] ALSA: line6: Add toneport_has_source_select() Chris Rorvick
2015-02-06 14:56 ` Takashi Iwai [this message]
2015-02-06 15:07 ` Chris Rorvick
2015-02-06 14:51 ` [PATCH 2/4] ALSA: line6: Pass toneport pointer to toneport_has_led() Chris Rorvick
2015-02-06 14:56 ` Takashi Iwai
2015-02-06 14:51 ` [PATCH 3/4] ALSA: line6: Pass driver name to line6_probe() Chris Rorvick
2015-02-06 15:04 ` Takashi Iwai
2015-02-06 17:23 ` Takashi Iwai
2015-02-07 16:18 ` Chris Rorvick
2015-02-06 14:51 ` [PATCH 4/4] ALSA: line6: Remove `usb_' prefix from structs Chris Rorvick
2015-02-06 15:11 ` Takashi Iwai
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=s5hioffw0kw.wl-tiwai@suse.de \
--to=tiwai@suse.de \
--cc=alsa-devel@alsa-project.org \
--cc=chris@rorvick.com \
--cc=linux-kernel@vger.kernel.org \
--cc=stefanha@gmail.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®