]> git.proxmox.com Git - mirror_ubuntu-hirsute-kernel.git/commitdiff
staging: lustre: Remove cl_2queue_add wrapper
authorShivani Bhardwaj <shivanib134@gmail.com>
Wed, 11 Nov 2015 10:13:28 +0000 (15:43 +0530)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Mon, 21 Dec 2015 23:40:18 +0000 (15:40 -0800)
Remove the wrapper function cl_2queue_add() and replace all its calls in
different files with the function it wrapped. Also, comments are added
wherever necessary to make the working of function clear. Prototype of
the function is also removed from the header file as it is no longer
needed.

Signed-off-by: Shivani Bhardwaj <shivanib134@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/staging/lustre/lustre/include/cl_object.h
drivers/staging/lustre/lustre/llite/rw26.c
drivers/staging/lustre/lustre/llite/vvp_io.c
drivers/staging/lustre/lustre/obdclass/cl_io.c
drivers/staging/lustre/lustre/obdecho/echo_client.c

index 1e7391ac81cce5a4e57c3754c7f5e14300b6e5f4..bd7acc2a121939913a370cc5affcfbd0a85ed8b0 100644 (file)
@@ -3127,7 +3127,6 @@ void cl_page_list_disown (const struct lu_env *env,
                          struct cl_io *io, struct cl_page_list *plist);
 
 void cl_2queue_init     (struct cl_2queue *queue);
-void cl_2queue_add      (struct cl_2queue *queue, struct cl_page *page);
 void cl_2queue_disown   (const struct lu_env *env,
                         struct cl_io *io, struct cl_2queue *queue);
 void cl_2queue_discard  (const struct lu_env *env,
index 3da4c01e2159684faf4e8b63c3d706be08622bf2..39fa13b74cbdac3f82f128aee9837063d253183a 100644 (file)
@@ -298,7 +298,10 @@ ssize_t ll_direct_rw_pages(const struct lu_env *env, struct cl_io *io,
                }
 
                if (likely(do_io)) {
-                       cl_2queue_add(queue, clp);
+                       /*
+                        * Add a page to the incoming page list of 2-queue.
+                        */
+                       cl_page_list_add(&queue->c2_qin, clp);
 
                        /*
                         * Set page clip to tell transfer formation engine
index 346b8a19dacdeb1449b582647f64cbf74ae9ac1f..f68e972886caeb510b53f7704dc7ca85a8f1df90 100644 (file)
@@ -849,7 +849,7 @@ static int vvp_io_read_page(const struct lu_env *env,
         * Add page into the queue even when it is marked uptodate above.
         * this will unlock it automatically as part of cl_page_list_disown().
         */
-       cl_2queue_add(queue, page);
+       cl_page_list_add(&queue->c2_qin, page);
        if (sbi->ll_ra_info.ra_max_pages_per_file &&
            sbi->ll_ra_info.ra_max_pages)
                ll_readahead(env, io, ras,
index 08723a3f2880e5a25e8fe6cd0c0b68f5d269ce6c..63246ba36798d55aa7091b341b1353160e9328c8 100644 (file)
@@ -1211,15 +1211,6 @@ void cl_2queue_init(struct cl_2queue *queue)
 }
 EXPORT_SYMBOL(cl_2queue_init);
 
-/**
- * Add a page to the incoming page list of 2-queue.
- */
-void cl_2queue_add(struct cl_2queue *queue, struct cl_page *page)
-{
-       cl_page_list_add(&queue->c2_qin, page);
-}
-EXPORT_SYMBOL(cl_2queue_add);
-
 /**
  * Disown pages in both lists of a 2-queue.
  */
@@ -1258,7 +1249,10 @@ EXPORT_SYMBOL(cl_2queue_fini);
 void cl_2queue_init_page(struct cl_2queue *queue, struct cl_page *page)
 {
        cl_2queue_init(queue);
-       cl_2queue_add(queue, page);
+       /*
+        * Add a page to the incoming page list of 2-queue.
+        */
+       cl_page_list_add(&queue->c2_qin, page);
 }
 EXPORT_SYMBOL(cl_2queue_init_page);
 
index b3463040c1ed24cba57b0d38d38363997509e48d..7b53f7dd1797c4c6013f0270cb8e407c28d51cfe 100644 (file)
@@ -1228,8 +1228,10 @@ static int cl_echo_object_brw(struct echo_object *eco, int rw, u64 offset,
                        cl_page_put(env, clp);
                        break;
                }
-
-               cl_2queue_add(queue, clp);
+               /*
+                * Add a page to the incoming page list of 2-queue.
+                */
+               cl_page_list_add(&queue->c2_qin, clp);
 
                /* drop the reference count for cl_page_find, so that the page
                 * will be freed in cl_2queue_fini. */