diff mbox series

[05/16] libceph: remove unused last_piece out parameter from ceph_msg_data_next()

Message ID 20200421131850.443228-6-rpenyaev@suse.de (mailing list archive)
State New, archived
Headers show
Series libceph: messenger: send/recv data at one go | expand

Commit Message

Roman Penyaev April 21, 2020, 1:18 p.m. UTC
Remove it as it is not used anywhere.

Signed-off-by: Roman Penyaev <rpenyaev@suse.de>
---
 net/ceph/messenger.c | 10 +++-------
 1 file changed, 3 insertions(+), 7 deletions(-)
diff mbox series

Patch

diff --git a/net/ceph/messenger.c b/net/ceph/messenger.c
index 8f35ed01a576..08786d75b990 100644
--- a/net/ceph/messenger.c
+++ b/net/ceph/messenger.c
@@ -1137,11 +1137,9 @@  static void ceph_msg_data_cursor_init(struct ceph_msg *msg, size_t length)
 /*
  * Return the page containing the next piece to process for a given
  * data item, and supply the page offset and length of that piece.
- * Indicate whether this is the last piece in this data item.
  */
 static struct page *ceph_msg_data_next(struct ceph_msg_data_cursor *cursor,
-					size_t *page_offset, size_t *length,
-					bool *last_piece)
+					size_t *page_offset, size_t *length)
 {
 	struct page *page;
 
@@ -1170,8 +1168,6 @@  static struct page *ceph_msg_data_next(struct ceph_msg_data_cursor *cursor,
 	BUG_ON(*page_offset + *length > PAGE_SIZE);
 	BUG_ON(!*length);
 	BUG_ON(*length > cursor->resid);
-	if (last_piece)
-		*last_piece = cursor->last_piece;
 
 	return page;
 }
@@ -1589,7 +1585,7 @@  static int write_partial_message_data(struct ceph_connection *con)
 			continue;
 		}
 
-		page = ceph_msg_data_next(cursor, &page_offset, &length, NULL);
+		page = ceph_msg_data_next(cursor, &page_offset, &length);
 		if (length == cursor->total_resid)
 			more = MSG_MORE;
 		ret = ceph_tcp_sendpage(con->sock, page, page_offset, length,
@@ -2336,7 +2332,7 @@  static int read_partial_msg_data(struct ceph_connection *con)
 			continue;
 		}
 
-		page = ceph_msg_data_next(cursor, &page_offset, &length, NULL);
+		page = ceph_msg_data_next(cursor, &page_offset, &length);
 		ret = ceph_tcp_recvpage(con->sock, page, page_offset, length);
 		if (ret <= 0) {
 			if (do_datacrc)