[TEXTSEARCH]: fix sparse gfp nocast warnings
authorRandy Dunlap <rdunlap@xenotime.net>
Wed, 5 Oct 2005 05:45:14 +0000 (22:45 -0700)
committerDavid S. Miller <davem@davemloft.net>
Wed, 5 Oct 2005 05:45:14 +0000 (22:45 -0700)
Fix nocast sparse warnings:
include/linux/textsearch.h:165:57: warning: implicit cast to nocast type

Signed-off-by: Randy Dunlap <rdunlap@xenotime.net>
Signed-off-by: David S. Miller <davem@davemloft.net>
include/linux/textsearch.h
lib/ts_bm.c
lib/ts_fsm.c
lib/ts_kmp.c

index 941f45ac117a41363fb0758243950d382d16a919..1a4990e448e9074a7c8a030b56c52271eff1221a 100644 (file)
@@ -158,7 +158,8 @@ extern unsigned int textsearch_find_continuous(struct ts_config *,
 #define TS_PRIV_ALIGNTO        8
 #define TS_PRIV_ALIGN(len) (((len) + TS_PRIV_ALIGNTO-1) & ~(TS_PRIV_ALIGNTO-1))
 
-static inline struct ts_config *alloc_ts_config(size_t payload, int gfp_mask)
+static inline struct ts_config *alloc_ts_config(size_t payload,
+                                               unsigned int __nocast gfp_mask)
 {
        struct ts_config *conf;
 
index 2cc79112ecc39fc2c945047b67e1c1ac4e67723f..1b61fceef77764c1c7e8ba2f4764358ea1cd4e58 100644 (file)
@@ -127,7 +127,7 @@ static void compute_prefix_tbl(struct ts_bm *bm, const u8 *pattern,
 }
 
 static struct ts_config *bm_init(const void *pattern, unsigned int len,
-                                int gfp_mask)
+                                unsigned int __nocast gfp_mask)
 {
        struct ts_config *conf;
        struct ts_bm *bm;
index d27c0a072940457deb3681642c607ff043b1dc50..ef9779e005062d79de05f00cff7c0aa1ee3a24a3 100644 (file)
@@ -258,7 +258,7 @@ found_match:
 }
 
 static struct ts_config *fsm_init(const void *pattern, unsigned int len,
-                                    int gfp_mask)
+                                    unsigned int __nocast gfp_mask)
 {
        int i, err = -EINVAL;
        struct ts_config *conf;
index 73266b97558587a183c0ed0059b0b8b797bca9bb..e45f0f0c2379683104c43cc16c01b5564bc941cf 100644 (file)
@@ -87,7 +87,7 @@ static inline void compute_prefix_tbl(const u8 *pattern, unsigned int len,
 }
 
 static struct ts_config *kmp_init(const void *pattern, unsigned int len,
-                                 int gfp_mask)
+                                 unsigned int __nocast gfp_mask)
 {
        struct ts_config *conf;
        struct ts_kmp *kmp;