Thread (29 messages) 29 messages, 7 authors, 2020-04-29

Re: [PATCH v2 01/17] remoteproc: add IPA notification to q6v5 driver

From: Alex Elder <hidden>
Date: 2020-03-06 13:30:19
Also in: linux-arm-msm, linux-devicetree, lkml, netdev

On 3/6/20 5:49 AM, Leon Romanovsky wrote:
On Thu, Mar 05, 2020 at 10:28:15PM -0600, Alex Elder wrote:
quoted
Set up a subdev in the q6v5 modem remoteproc driver that generates
event notifications for the IPA driver to use for initialization and
recovery following a modem shutdown or crash.
. . .
quoted
diff --git a/include/linux/remoteproc/qcom_q6v5_ipa_notify.h b/include/linux/remoteproc/qcom_q6v5_ipa_notify.h
new file mode 100644
index 000000000000..0820edc0ab7d
--- /dev/null
+++ b/include/linux/remoteproc/qcom_q6v5_ipa_notify.h
@@ -0,0 +1,82 @@
+/* SPDX-License-Identifier: GPL-2.0 */
+
+/* Copyright (C) 2019 Linaro Ltd. */
+
+#ifndef __QCOM_Q6V5_IPA_NOTIFY_H__
+#define __QCOM_Q6V5_IPA_NOTIFY_H__
+
+#if IS_ENABLED(CONFIG_QCOM_Q6V5_IPA_NOTIFY)
Why don't you put this guard in the places where such include is called?
Or the best variant is to ensure that this include is compiled in only
in CONFIG_QCOM_Q6V5_IPA_NOTIFY flows.
I did it this way so the no-op definitions resided in the same header
file if the config option is not enabled.  And the no-ops were there
so the calling code didn't have to use #ifdef.

I have no objection to what you suggest.  I did a quick scan for other
examples like this for guidance and found lots of examples of doing it
the way I did.

So I'm happy to change it, but would like an additional request to do
so before I do that work.

Thanks.

					-Alex
That is more common way to guard internal header files.

Thanks

_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help