Skip to content

Commit b81565b

Browse files
Alex ElderPaolo Abeni
authored andcommitted
net: ipa: make ipa_table_hash_support() a real function
With the exception of ipa_table_hash_support(), nothing defined in "ipa_table.h" requires the full definition of the IPA structure. Change that function to be a "real" function rather than an inline, to avoid requring the IPA structure to be defined. Signed-off-by: Alex Elder <[email protected]> Signed-off-by: Paolo Abeni <[email protected]>
1 parent 5043d6b commit b81565b

File tree

2 files changed

+9
-6
lines changed

2 files changed

+9
-6
lines changed

drivers/net/ipa/ipa_table.c

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
// SPDX-License-Identifier: GPL-2.0
22

33
/* Copyright (c) 2012-2018, The Linux Foundation. All rights reserved.
4-
* Copyright (C) 2018-2023 Linaro Ltd.
4+
* Copyright (C) 2018-2024 Linaro Ltd.
55
*/
66

77
#include <linux/bitops.h>
@@ -158,6 +158,12 @@ ipa_table_mem(struct ipa *ipa, bool filter, bool hashed, bool ipv6)
158158
return ipa_mem_find(ipa, mem_id);
159159
}
160160

161+
/* Return true if hashed tables are supported */
162+
bool ipa_table_hash_support(struct ipa *ipa)
163+
{
164+
return ipa->version != IPA_VERSION_4_2;
165+
}
166+
161167
bool ipa_filtered_valid(struct ipa *ipa, u64 filtered)
162168
{
163169
struct device *dev = ipa->dev;

drivers/net/ipa/ipa_table.h

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
/* SPDX-License-Identifier: GPL-2.0 */
22

33
/* Copyright (c) 2012-2018, The Linux Foundation. All rights reserved.
4-
* Copyright (C) 2019-2022 Linaro Ltd.
4+
* Copyright (C) 2019-2024 Linaro Ltd.
55
*/
66
#ifndef _IPA_TABLE_H_
77
#define _IPA_TABLE_H_
@@ -23,10 +23,7 @@ bool ipa_filtered_valid(struct ipa *ipa, u64 filtered);
2323
* ipa_table_hash_support() - Return true if hashed tables are supported
2424
* @ipa: IPA pointer
2525
*/
26-
static inline bool ipa_table_hash_support(struct ipa *ipa)
27-
{
28-
return ipa->version != IPA_VERSION_4_2;
29-
}
26+
bool ipa_table_hash_support(struct ipa *ipa);
3027

3128
/**
3229
* ipa_table_reset() - Reset filter and route tables entries to "none"

0 commit comments

Comments
 (0)