Skip to content

Commit a0890b7

Browse files
krzkgregkh
authored andcommitted
bus: firewall: Fix missing static inline annotations for stubs
commit 66db876 upstream. Stubs in the header file for !CONFIG_STM32_FIREWALL case should be both static and inline, because they do not come with earlier declaration and should be inlined in every unit including the header. Cc: Patrice Chotard <patrice.chotard@foss.st.com> Cc: stable@vger.kernel.org Fixes: 5c9668c ("firewall: introduce stm32_firewall framework") Link: https://lore.kernel.org/r/20250507092121.95121-2-krzysztof.kozlowski@linaro.org Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
1 parent 1c71f3c commit a0890b7

File tree

1 file changed

+9
-6
lines changed

1 file changed

+9
-6
lines changed

include/linux/bus/stm32_firewall_device.h

Lines changed: 9 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -114,27 +114,30 @@ void stm32_firewall_release_access_by_id(struct stm32_firewall *firewall, u32 su
114114

115115
#else /* CONFIG_STM32_FIREWALL */
116116

117-
int stm32_firewall_get_firewall(struct device_node *np, struct stm32_firewall *firewall,
118-
unsigned int nb_firewall)
117+
static inline int stm32_firewall_get_firewall(struct device_node *np,
118+
struct stm32_firewall *firewall,
119+
unsigned int nb_firewall)
119120
{
120121
return -ENODEV;
121122
}
122123

123-
int stm32_firewall_grant_access(struct stm32_firewall *firewall)
124+
static inline int stm32_firewall_grant_access(struct stm32_firewall *firewall)
124125
{
125126
return -ENODEV;
126127
}
127128

128-
void stm32_firewall_release_access(struct stm32_firewall *firewall)
129+
static inline void stm32_firewall_release_access(struct stm32_firewall *firewall)
129130
{
130131
}
131132

132-
int stm32_firewall_grant_access_by_id(struct stm32_firewall *firewall, u32 subsystem_id)
133+
static inline int stm32_firewall_grant_access_by_id(struct stm32_firewall *firewall,
134+
u32 subsystem_id)
133135
{
134136
return -ENODEV;
135137
}
136138

137-
void stm32_firewall_release_access_by_id(struct stm32_firewall *firewall, u32 subsystem_id)
139+
static inline void stm32_firewall_release_access_by_id(struct stm32_firewall *firewall,
140+
u32 subsystem_id)
138141
{
139142
}
140143

0 commit comments

Comments
 (0)