* [PATCH 0/2] Minor misc. cleanups for TI K3 SoCs
@ 2021-07-27 23:24 Suman Anna
2021-07-27 23:24 ` [PATCH 1/2] firmware: ti_sci: Include linux/err.h in ti_sci_protocol.h Suman Anna
2021-07-27 23:24 ` [PATCH 2/2] arm: mach-k3: common: Add a release_resources_for_core_shutdown() stub Suman Anna
0 siblings, 2 replies; 7+ messages in thread
From: Suman Anna @ 2021-07-27 23:24 UTC (permalink / raw)
To: Lokesh Vutla; +Cc: Praneeth Bajjuri, u-boot, Suman Anna
Hi Lokesh,
The following are two minor cleanups/fixes that I ran into
while doing some development work on a newer SoC due to
different Kconfig symbols.
Following is the patch summary:
- Patch #1 makes the ti_sci_protocol.h self-contained
when CONFIG_TI_SCI_PROTOCOL is not defined.
- Patch #2 defines a release_resources_for_core_shutdown()
stub. This function is used in the common code, but yet is
expected to be implemented in a SoC-specific source file.
regards
Suman
Suman Anna (2):
firmware: ti_sci: Include linux/err.h in ti_sci_protocol.h
arm: mach-k3: common: Add a release_resources_for_core_shutdown() stub
arch/arm/mach-k3/common.c | 5 +++++
include/linux/soc/ti/ti_sci_protocol.h | 4 +++-
2 files changed, 8 insertions(+), 1 deletion(-)
--
2.32.0
^ permalink raw reply [flat|nested] 7+ messages in thread
* [PATCH 1/2] firmware: ti_sci: Include linux/err.h in ti_sci_protocol.h
2021-07-27 23:24 [PATCH 0/2] Minor misc. cleanups for TI K3 SoCs Suman Anna
@ 2021-07-27 23:24 ` Suman Anna
2021-08-27 15:52 ` Nishanth Menon
2021-09-17 22:53 ` Tom Rini
2021-07-27 23:24 ` [PATCH 2/2] arm: mach-k3: common: Add a release_resources_for_core_shutdown() stub Suman Anna
1 sibling, 2 replies; 7+ messages in thread
From: Suman Anna @ 2021-07-27 23:24 UTC (permalink / raw)
To: Lokesh Vutla; +Cc: Praneeth Bajjuri, u-boot, Suman Anna
The common TI SCI header file uses some macros from err.h and these
get exercised when CONFIG_TI_SCI_PROTOCOL is not defined. Include
the linux/err.h header file in this header file directly rather
than relying on source files to include it to eliminate any
potential build errors.
While at this, reorder the existing header file include to the
beginning of the file.
Signed-off-by: Suman Anna <s-anna@ti.com>
---
include/linux/soc/ti/ti_sci_protocol.h | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/include/linux/soc/ti/ti_sci_protocol.h b/include/linux/soc/ti/ti_sci_protocol.h
index 794737923cf1..7f9941894cdf 100644
--- a/include/linux/soc/ti/ti_sci_protocol.h
+++ b/include/linux/soc/ti/ti_sci_protocol.h
@@ -11,6 +11,9 @@
#ifndef __TISCI_PROTOCOL_H
#define __TISCI_PROTOCOL_H
+#include <linux/bitops.h>
+#include <linux/err.h>
+
/**
* struct ti_sci_version_info - version information structure
* @abi_major: Major ABI version. Change here implies risk of backward
@@ -20,7 +23,6 @@
* @firmware_revision: Firmware revision (not usually used).
* @firmware_description: Firmware description (not usually used).
*/
-#include <linux/bitops.h>
struct ti_sci_version_info {
u8 abi_major;
u8 abi_minor;
--
2.32.0
^ permalink raw reply related [flat|nested] 7+ messages in thread* Re: [PATCH 1/2] firmware: ti_sci: Include linux/err.h in ti_sci_protocol.h
2021-07-27 23:24 ` [PATCH 1/2] firmware: ti_sci: Include linux/err.h in ti_sci_protocol.h Suman Anna
@ 2021-08-27 15:52 ` Nishanth Menon
2021-09-17 22:53 ` Tom Rini
1 sibling, 0 replies; 7+ messages in thread
From: Nishanth Menon @ 2021-08-27 15:52 UTC (permalink / raw)
To: Suman Anna; +Cc: Lokesh Vutla, Praneeth Bajjuri, u-boot
On 18:24-20210727, Suman Anna wrote:
> The common TI SCI header file uses some macros from err.h and these
> get exercised when CONFIG_TI_SCI_PROTOCOL is not defined. Include
> the linux/err.h header file in this header file directly rather
> than relying on source files to include it to eliminate any
> potential build errors.
>
> While at this, reorder the existing header file include to the
> beginning of the file.
>
> Signed-off-by: Suman Anna <s-anna@ti.com>
> ---
> include/linux/soc/ti/ti_sci_protocol.h | 4 +++-
> 1 file changed, 3 insertions(+), 1 deletion(-)
>
> diff --git a/include/linux/soc/ti/ti_sci_protocol.h b/include/linux/soc/ti/ti_sci_protocol.h
> index 794737923cf1..7f9941894cdf 100644
> --- a/include/linux/soc/ti/ti_sci_protocol.h
> +++ b/include/linux/soc/ti/ti_sci_protocol.h
> @@ -11,6 +11,9 @@
> #ifndef __TISCI_PROTOCOL_H
> #define __TISCI_PROTOCOL_H
>
> +#include <linux/bitops.h>
> +#include <linux/err.h>
> +
> /**
> * struct ti_sci_version_info - version information structure
> * @abi_major: Major ABI version. Change here implies risk of backward
> @@ -20,7 +23,6 @@
> * @firmware_revision: Firmware revision (not usually used).
> * @firmware_description: Firmware description (not usually used).
> */
> -#include <linux/bitops.h>
> struct ti_sci_version_info {
> u8 abi_major;
> u8 abi_minor;
Reviewed-by: Nishanth Menon <nm@ti.com>
--
Regards,
Nishanth Menon
Key (0xDDB5849D1736249D) / Fingerprint: F8A2 8693 54EB 8232 17A3 1A34 DDB5 849D 1736 249D
^ permalink raw reply [flat|nested] 7+ messages in thread* Re: [PATCH 1/2] firmware: ti_sci: Include linux/err.h in ti_sci_protocol.h
2021-07-27 23:24 ` [PATCH 1/2] firmware: ti_sci: Include linux/err.h in ti_sci_protocol.h Suman Anna
2021-08-27 15:52 ` Nishanth Menon
@ 2021-09-17 22:53 ` Tom Rini
1 sibling, 0 replies; 7+ messages in thread
From: Tom Rini @ 2021-09-17 22:53 UTC (permalink / raw)
To: Suman Anna; +Cc: Lokesh Vutla, Praneeth Bajjuri, u-boot
[-- Attachment #1: Type: text/plain, Size: 597 bytes --]
On Tue, Jul 27, 2021 at 06:24:39PM -0500, Suman Anna wrote:
> The common TI SCI header file uses some macros from err.h and these
> get exercised when CONFIG_TI_SCI_PROTOCOL is not defined. Include
> the linux/err.h header file in this header file directly rather
> than relying on source files to include it to eliminate any
> potential build errors.
>
> While at this, reorder the existing header file include to the
> beginning of the file.
>
> Signed-off-by: Suman Anna <s-anna@ti.com>
> Reviewed-by: Nishanth Menon <nm@ti.com>
Applied to u-boot/master, thanks!
--
Tom
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 659 bytes --]
^ permalink raw reply [flat|nested] 7+ messages in thread
* [PATCH 2/2] arm: mach-k3: common: Add a release_resources_for_core_shutdown() stub
2021-07-27 23:24 [PATCH 0/2] Minor misc. cleanups for TI K3 SoCs Suman Anna
2021-07-27 23:24 ` [PATCH 1/2] firmware: ti_sci: Include linux/err.h in ti_sci_protocol.h Suman Anna
@ 2021-07-27 23:24 ` Suman Anna
2021-08-27 17:07 ` Nishanth Menon
2021-09-17 22:53 ` Tom Rini
1 sibling, 2 replies; 7+ messages in thread
From: Suman Anna @ 2021-07-27 23:24 UTC (permalink / raw)
To: Lokesh Vutla; +Cc: Praneeth Bajjuri, u-boot, Suman Anna
Add a weak release_resources_for_core_shutdown() stub implementation
that can be overridden by actual implementation if a SoC supports that
function.
Signed-off-by: Suman Anna <s-anna@ti.com>
---
arch/arm/mach-k3/common.c | 5 +++++
1 file changed, 5 insertions(+)
diff --git a/arch/arm/mach-k3/common.c b/arch/arm/mach-k3/common.c
index bb0f64194f4e..08b7344df749 100644
--- a/arch/arm/mach-k3/common.c
+++ b/arch/arm/mach-k3/common.c
@@ -193,6 +193,11 @@ int load_firmware(char *name_fw, char *name_loadaddr, u32 *loadaddr)
}
#endif
+__weak void release_resources_for_core_shutdown(void)
+{
+ debug("%s not implemented...\n", __func__);
+}
+
void __noreturn jump_to_image_no_args(struct spl_image_info *spl_image)
{
typedef void __noreturn (*image_entry_noargs_t)(void);
--
2.32.0
^ permalink raw reply related [flat|nested] 7+ messages in thread* Re: [PATCH 2/2] arm: mach-k3: common: Add a release_resources_for_core_shutdown() stub
2021-07-27 23:24 ` [PATCH 2/2] arm: mach-k3: common: Add a release_resources_for_core_shutdown() stub Suman Anna
@ 2021-08-27 17:07 ` Nishanth Menon
2021-09-17 22:53 ` Tom Rini
1 sibling, 0 replies; 7+ messages in thread
From: Nishanth Menon @ 2021-08-27 17:07 UTC (permalink / raw)
To: Suman Anna; +Cc: Lokesh Vutla, Praneeth Bajjuri, u-boot
On 18:24-20210727, Suman Anna wrote:
> Add a weak release_resources_for_core_shutdown() stub implementation
> that can be overridden by actual implementation if a SoC supports that
> function.
>
> Signed-off-by: Suman Anna <s-anna@ti.com>
> ---
> arch/arm/mach-k3/common.c | 5 +++++
> 1 file changed, 5 insertions(+)
>
> diff --git a/arch/arm/mach-k3/common.c b/arch/arm/mach-k3/common.c
> index bb0f64194f4e..08b7344df749 100644
> --- a/arch/arm/mach-k3/common.c
> +++ b/arch/arm/mach-k3/common.c
> @@ -193,6 +193,11 @@ int load_firmware(char *name_fw, char *name_loadaddr, u32 *loadaddr)
> }
> #endif
>
> +__weak void release_resources_for_core_shutdown(void)
> +{
> + debug("%s not implemented...\n", __func__);
> +}
> +
> void __noreturn jump_to_image_no_args(struct spl_image_info *spl_image)
> {
> typedef void __noreturn (*image_entry_noargs_t)(void);
Reviewed-by: Nishanth Menon <nm@ti.com>
--
Regards,
Nishanth Menon
Key (0xDDB5849D1736249D) / Fingerprint: F8A2 8693 54EB 8232 17A3 1A34 DDB5 849D 1736 249D
^ permalink raw reply [flat|nested] 7+ messages in thread* Re: [PATCH 2/2] arm: mach-k3: common: Add a release_resources_for_core_shutdown() stub
2021-07-27 23:24 ` [PATCH 2/2] arm: mach-k3: common: Add a release_resources_for_core_shutdown() stub Suman Anna
2021-08-27 17:07 ` Nishanth Menon
@ 2021-09-17 22:53 ` Tom Rini
1 sibling, 0 replies; 7+ messages in thread
From: Tom Rini @ 2021-09-17 22:53 UTC (permalink / raw)
To: Suman Anna; +Cc: Lokesh Vutla, Praneeth Bajjuri, u-boot
[-- Attachment #1: Type: text/plain, Size: 363 bytes --]
On Tue, Jul 27, 2021 at 06:24:40PM -0500, Suman Anna wrote:
> Add a weak release_resources_for_core_shutdown() stub implementation
> that can be overridden by actual implementation if a SoC supports that
> function.
>
> Signed-off-by: Suman Anna <s-anna@ti.com>
> Reviewed-by: Nishanth Menon <nm@ti.com>
Applied to u-boot/master, thanks!
--
Tom
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 659 bytes --]
^ permalink raw reply [flat|nested] 7+ messages in thread
end of thread, other threads:[~2021-09-17 22:54 UTC | newest]
Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2021-07-27 23:24 [PATCH 0/2] Minor misc. cleanups for TI K3 SoCs Suman Anna
2021-07-27 23:24 ` [PATCH 1/2] firmware: ti_sci: Include linux/err.h in ti_sci_protocol.h Suman Anna
2021-08-27 15:52 ` Nishanth Menon
2021-09-17 22:53 ` Tom Rini
2021-07-27 23:24 ` [PATCH 2/2] arm: mach-k3: common: Add a release_resources_for_core_shutdown() stub Suman Anna
2021-08-27 17:07 ` Nishanth Menon
2021-09-17 22:53 ` Tom Rini
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox