aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/block/zram/zcomp.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/block/zram/zcomp.c')
-rw-r--r--drivers/block/zram/zcomp.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/drivers/block/zram/zcomp.c b/drivers/block/zram/zcomp.c
index 5647d8fe1dc1..b0e7592c44d8 100644
--- a/drivers/block/zram/zcomp.c
+++ b/drivers/block/zram/zcomp.c
@@ -153,7 +153,7 @@ static void zcomp_strm_multi_release(struct zcomp *comp, struct zcomp_strm *zstr
153} 153}
154 154
155/* change max_strm limit */ 155/* change max_strm limit */
156static int zcomp_strm_multi_set_max_streams(struct zcomp *comp, int num_strm) 156static bool zcomp_strm_multi_set_max_streams(struct zcomp *comp, int num_strm)
157{ 157{
158 struct zcomp_strm_multi *zs = comp->stream; 158 struct zcomp_strm_multi *zs = comp->stream;
159 struct zcomp_strm *zstrm; 159 struct zcomp_strm *zstrm;
@@ -172,7 +172,7 @@ static int zcomp_strm_multi_set_max_streams(struct zcomp *comp, int num_strm)
172 zs->avail_strm--; 172 zs->avail_strm--;
173 } 173 }
174 spin_unlock(&zs->strm_lock); 174 spin_unlock(&zs->strm_lock);
175 return 0; 175 return true;
176} 176}
177 177
178static void zcomp_strm_multi_destroy(struct zcomp *comp) 178static void zcomp_strm_multi_destroy(struct zcomp *comp)
@@ -232,10 +232,10 @@ static void zcomp_strm_single_release(struct zcomp *comp,
232 mutex_unlock(&zs->strm_lock); 232 mutex_unlock(&zs->strm_lock);
233} 233}
234 234
235static int zcomp_strm_single_set_max_streams(struct zcomp *comp, int num_strm) 235static bool zcomp_strm_single_set_max_streams(struct zcomp *comp, int num_strm)
236{ 236{
237 /* zcomp_strm_single support only max_comp_streams == 1 */ 237 /* zcomp_strm_single support only max_comp_streams == 1 */
238 return -ENOTSUPP; 238 return false;
239} 239}
240 240
241static void zcomp_strm_single_destroy(struct zcomp *comp) 241static void zcomp_strm_single_destroy(struct zcomp *comp)
@@ -284,7 +284,7 @@ ssize_t zcomp_available_show(const char *comp, char *buf)
284 return sz; 284 return sz;
285} 285}
286 286
287int zcomp_set_max_streams(struct zcomp *comp, int num_strm) 287bool zcomp_set_max_streams(struct zcomp *comp, int num_strm)
288{ 288{
289 return comp->set_max_streams(comp, num_strm); 289 return comp->set_max_streams(comp, num_strm);
290} 290}