Fix nocast sparse warnings: include/linux/textsearch.h:165:57: warning: implicit cast to nocast type
Unified · Split
| @@ -158,7 +158,8 @@ extern unsigned int textsearch_find_continuous(struct ts_config *, · 157 unmodified lines | ||
| 158 | 158 | #define TS_PRIV_ALIGNTO 8 |
| 159 | 159 | #define TS_PRIV_ALIGN(len) (((len) + TS_PRIV_ALIGNTO-1) & ~(TS_PRIV_ALIGNTO-1)) |
| 160 | 160 | |
| 161 | −static inline struct ts_config *alloc_ts_config(size_t payload, int gfp_mask) | |
| 161 | +static inline struct ts_config *alloc_ts_config(size_t payload, | |
| 162 | + unsigned int __nocast gfp_mask) | |
| 162 | 163 | { |
| 163 | 164 | struct ts_config *conf; |
| 164 | 165 | |
| @@ -127,7 +127,7 @@ static void compute_prefix_tbl(struct ts_bm *bm, const u8 *pattern, · 126 unmodified lines | ||
| 127 | 127 | } |
| 128 | 128 | |
| 129 | 129 | static struct ts_config *bm_init(const void *pattern, unsigned int len, |
| 130 | − int gfp_mask) | |
| 130 | + unsigned int __nocast gfp_mask) | |
| 131 | 131 | { |
| 132 | 132 | struct ts_config *conf; |
| 133 | 133 | struct ts_bm *bm; |
| @@ -258,7 +258,7 @@ found_match: · 257 unmodified lines | ||
| 258 | 258 | } |
| 259 | 259 | |
| 260 | 260 | static struct ts_config *fsm_init(const void *pattern, unsigned int len, |
| 261 | − int gfp_mask) | |
| 261 | + unsigned int __nocast gfp_mask) | |
| 262 | 262 | { |
| 263 | 263 | int i, err = -EINVAL; |
| 264 | 264 | struct ts_config *conf; |
| @@ -87,7 +87,7 @@ static inline void compute_prefix_tbl(const u8 *pattern, unsigned int len, · 86 unmodified lines | ||
| 87 | 87 | } |
| 88 | 88 | |
| 89 | 89 | static struct ts_config *kmp_init(const void *pattern, unsigned int len, |
| 90 | − int gfp_mask) | |
| 90 | + unsigned int __nocast gfp_mask) | |
| 91 | 91 | { |
| 92 | 92 | struct ts_config *conf; |
| 93 | 93 | struct ts_kmp *kmp; |