diff --git a/kernel/mars_server.c b/kernel/mars_server.c index 0a1eab2b..e47fe431 100644 --- a/kernel/mars_server.c +++ b/kernel/mars_server.c @@ -389,7 +389,6 @@ int handler_thread(void *data) prev = make_brick_all( brick->global, NULL, - true, _set_server_bio_params, NULL, path, @@ -738,7 +737,7 @@ static int _server_thread(void *data) MARS_DBG("got new connection #%d\n", handler_socket.s_debug_nr); - brick = (void*)mars_make_brick(&server_global, NULL, true, &server_brick_type, "handler", "handler"); + brick = (void*)mars_make_brick(&server_global, NULL, &server_brick_type, "handler", "handler"); if (!brick) { MARS_ERR("cannot create server instance\n"); mars_shutdown_socket(&handler_socket); diff --git a/kernel/sy_old/mars_light.c b/kernel/sy_old/mars_light.c index f22906ca..adb7ab90 100644 --- a/kernel/sy_old/mars_light.c +++ b/kernel/sy_old/mars_light.c @@ -1168,7 +1168,6 @@ int __make_copy( aio = make_brick_all(global, NULL, - false, _set_bio_params, &clc[i], NULL, @@ -1193,7 +1192,6 @@ int __make_copy( copy = make_brick_all(global, belongs, - false, _set_copy_params, &cc, cc.fullpath[1], @@ -2220,7 +2218,6 @@ int make_log_init(void *buf, struct mars_dent *dent) aio_brick = make_brick_all(global, aio_dent, - false, _set_aio_params, NULL, aio_path, @@ -2271,7 +2268,6 @@ int make_log_init(void *buf, struct mars_dent *dent) trans_brick = make_brick_all(global, dent, - false, _set_trans_params, NULL, aio_path, @@ -2659,7 +2655,6 @@ void _rotate_trans(struct mars_rotate *rot) rot->next_relevant_brick = make_brick_all(rot->global, rot->next_relevant_log, - false, _set_aio_params, NULL, rot->next_relevant_log->d_path, @@ -2773,7 +2768,6 @@ int _start_trans(struct mars_rotate *rot) rot->relevant_brick = make_brick_all(rot->global, rot->relevant_log, - false, _set_aio_params, NULL, rot->relevant_log->d_path, @@ -3068,7 +3062,6 @@ int make_bio(void *buf, struct mars_dent *dent) brick = make_brick_all(global, dent, - false, _set_bio_params, NULL, dent->d_path, @@ -3192,7 +3185,6 @@ int make_dev(void *buf, struct mars_dent *dent) dev_brick = make_brick_all(global, dent, - false, _set_if_params, rot, dent->d_argv[0], @@ -3271,7 +3263,6 @@ static int _make_direct(void *buf, struct mars_dent *dent) brick = make_brick_all(global, dent, - false, _set_bio_params, NULL, src_path, @@ -3292,7 +3283,6 @@ static int _make_direct(void *buf, struct mars_dent *dent) brick = make_brick_all(global, dent, - false, _set_if_params, NULL, dent->d_argv[1], diff --git a/kernel/sy_old/strategy.h b/kernel/sy_old/strategy.h index 5fba6e9b..d1b072f3 100644 --- a/kernel/sy_old/strategy.h +++ b/kernel/sy_old/strategy.h @@ -94,7 +94,7 @@ extern void mars_free_dent_all(struct mars_global *global, struct list_head *anc // low-level brick instantiation extern struct mars_brick *mars_find_brick(struct mars_global *global, const void *brick_type, const char *path); -extern struct mars_brick *mars_make_brick(struct mars_global *global, struct mars_dent *belongs, bool is_server, const void *_brick_type, const char *path, const char *name); +extern struct mars_brick *mars_make_brick(struct mars_global *global, struct mars_dent *belongs, const void *_brick_type, const char *path, const char *name); extern int mars_free_brick(struct mars_brick *brick); extern int mars_kill_brick(struct mars_brick *brick); extern int mars_kill_brick_all(struct mars_global *global, struct list_head *anchor, bool use_dent_link); @@ -121,7 +121,6 @@ extern struct mars_brick *path_find_brick(struct mars_global *global, const void extern struct mars_brick *make_brick_all( struct mars_global *global, struct mars_dent *belongs, - bool is_server, int (*setup_fn)(struct mars_brick *brick, void *private), void *private, const char *new_name, diff --git a/kernel/sy_old/sy_generic.c b/kernel/sy_old/sy_generic.c index 01c22210..837a71f4 100644 --- a/kernel/sy_old/sy_generic.c +++ b/kernel/sy_old/sy_generic.c @@ -1090,7 +1090,7 @@ done: } EXPORT_SYMBOL_GPL(mars_free_brick); -struct mars_brick *mars_make_brick(struct mars_global *global, struct mars_dent *belongs, bool is_server, const void *_brick_type, const char *path, const char *_name) +struct mars_brick *mars_make_brick(struct mars_global *global, struct mars_dent *belongs, const void *_brick_type, const char *path, const char *_name) { const char *name = brick_strdup(_name); const char *names[] = { name, NULL }; @@ -1448,7 +1448,6 @@ EXPORT_SYMBOL_GPL(_sio_brick_type); struct mars_brick *make_brick_all( struct mars_global *global, struct mars_dent *belongs, - bool is_server, int (*setup_fn)(struct mars_brick *brick, void *private), void *private, const char *new_name, @@ -1565,7 +1564,7 @@ struct mars_brick *make_brick_all( remote++; MARS_DBG("substitute by remote brick '%s' on peer '%s'\n", new_name, remote); - brick = mars_make_brick(global, belongs, is_server, _client_brick_type, new_path, new_name); + brick = mars_make_brick(global, belongs, _client_brick_type, new_path, new_name); if (brick) { struct client_brick *_brick = (void*)brick; _brick->max_flying = 10000; @@ -1589,7 +1588,7 @@ struct mars_brick *make_brick_all( // create it... if (!brick) - brick = mars_make_brick(global, belongs, is_server, new_brick_type, new_path, new_name); + brick = mars_make_brick(global, belongs, new_brick_type, new_path, new_name); if (unlikely(!brick)) { MARS_ERR("creation failed '%s' '%s'\n", new_path, new_name); goto err;