From: Mark Brown <broonie@kernel.org>
To: Tang Bin <tangbin@cmss.chinamobile.com>
Cc: olivier.moysan@foss.st.com, arnaud.pouliquen@foss.st.com,
lgirdwood@gmail.com, perex@perex.cz, tiwai@suse.com,
linux-stm32@st-md-mailman.stormreply.com,
linux-arm-kernel@lists.infradead.org,
linux-kernel@vger.kernel.org,
Zhang Shengju <zhangshengju@cmss.chinamobile.com>
Subject: Re: [PATCH] ASoC: stm32: spdifrx: Delete unnecessary check in the probe function
Date: Wed, 11 Aug 2021 12:58:46 +0100 [thread overview]
Message-ID: <20210811115846.GC4167@sirena.org.uk> (raw)
In-Reply-To: <20210811115523.17232-1-tangbin@cmss.chinamobile.com>
[-- Attachment #1.1: Type: text/plain, Size: 399 bytes --]
On Wed, Aug 11, 2021 at 07:55:23PM +0800, Tang Bin wrote:
> The function stm32_spdifrx_parse_of() is only called by the function
> stm32_spdifrx_probe(), and the probe function is only called with
> an openfirmware platform device. Therefore there is no need to check
> the device_node in probe function.
What is the benefit of not doing the check? It seems like reasonable
defensive programming.
[-- Attachment #1.2: signature.asc --]
[-- Type: application/pgp-signature, Size: 488 bytes --]
[-- Attachment #2: Type: text/plain, Size: 176 bytes --]
_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
WARNING: multiple messages have this Message-ID (diff)
From: Mark Brown <broonie@kernel.org>
To: Tang Bin <tangbin@cmss.chinamobile.com>
Cc: olivier.moysan@foss.st.com, arnaud.pouliquen@foss.st.com,
lgirdwood@gmail.com, perex@perex.cz, tiwai@suse.com,
linux-stm32@st-md-mailman.stormreply.com,
linux-arm-kernel@lists.infradead.org,
linux-kernel@vger.kernel.org,
Zhang Shengju <zhangshengju@cmss.chinamobile.com>
Subject: Re: [PATCH] ASoC: stm32: spdifrx: Delete unnecessary check in the probe function
Date: Wed, 11 Aug 2021 12:58:46 +0100 [thread overview]
Message-ID: <20210811115846.GC4167@sirena.org.uk> (raw)
In-Reply-To: <20210811115523.17232-1-tangbin@cmss.chinamobile.com>
[-- Attachment #1: Type: text/plain, Size: 399 bytes --]
On Wed, Aug 11, 2021 at 07:55:23PM +0800, Tang Bin wrote:
> The function stm32_spdifrx_parse_of() is only called by the function
> stm32_spdifrx_probe(), and the probe function is only called with
> an openfirmware platform device. Therefore there is no need to check
> the device_node in probe function.
What is the benefit of not doing the check? It seems like reasonable
defensive programming.
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 488 bytes --]
next prev parent reply other threads:[~2021-08-11 12:01 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-08-11 11:55 [PATCH] ASoC: stm32: spdifrx: Delete unnecessary check in the probe function Tang Bin
2021-08-11 11:55 ` Tang Bin
2021-08-11 11:58 ` Mark Brown [this message]
2021-08-11 11:58 ` Mark Brown
2021-08-11 12:09 ` [PATCH] ASoC: stm32: spdifrx: Delete unnecessary check in theprobe function tangbin
2021-08-11 12:09 ` tangbin
2021-08-11 12:19 ` Mark Brown
2021-08-11 12:19 ` Mark Brown
2021-08-11 12:28 ` [PATCH] ASoC: stm32: spdifrx: Delete unnecessary check in the probe function tangbin
2021-08-11 12:28 ` tangbin
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=20210811115846.GC4167@sirena.org.uk \
--to=broonie@kernel.org \
--cc=arnaud.pouliquen@foss.st.com \
--cc=lgirdwood@gmail.com \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-stm32@st-md-mailman.stormreply.com \
--cc=olivier.moysan@foss.st.com \
--cc=perex@perex.cz \
--cc=tangbin@cmss.chinamobile.com \
--cc=tiwai@suse.com \
--cc=zhangshengju@cmss.chinamobile.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.