diff options
author | Tomas Bortoli <tomasbortoli@gmail.com> | 2018-08-11 10:42:53 -0400 |
---|---|---|
committer | Dominique Martinet <dominique.martinet@cea.fr> | 2018-09-07 12:39:47 -0400 |
commit | 43cbcbee9938b17f77cf34f1bc12d302f456810f (patch) | |
tree | 6ac611f448e0a6d257a8cf454862eab6835584fd | |
parent | 91a76be37ff89795526c452a6799576b03bec501 (diff) |
9p: rename p9_free_req() function
In sight of the next patch to add a refcount in p9_req_t, rename
the p9_free_req() function in p9_release_req().
In the next patch the actual kfree will be moved to another function.
Link: http://lkml.kernel.org/r/20180811144254.23665-1-tomasbortoli@gmail.com
Signed-off-by: Tomas Bortoli <tomasbortoli@gmail.com>
Acked-by: Jun Piao <piaojun@huawei.com>
Signed-off-by: Dominique Martinet <dominique.martinet@cea.fr>
-rw-r--r-- | net/9p/client.c | 100 |
1 files changed, 50 insertions, 50 deletions
diff --git a/net/9p/client.c b/net/9p/client.c index f3dff8758ed7..96c105841075 100644 --- a/net/9p/client.c +++ b/net/9p/client.c | |||
@@ -341,13 +341,13 @@ struct p9_req_t *p9_tag_lookup(struct p9_client *c, u16 tag) | |||
341 | EXPORT_SYMBOL(p9_tag_lookup); | 341 | EXPORT_SYMBOL(p9_tag_lookup); |
342 | 342 | ||
343 | /** | 343 | /** |
344 | * p9_free_req - Free a request. | 344 | * p9_tag_remove - Remove a tag. |
345 | * @c: Client session. | 345 | * @c: Client session. |
346 | * @r: Request to free. | 346 | * @r: Request of reference. |
347 | * | 347 | * |
348 | * Context: Any context. | 348 | * Context: Any context. |
349 | */ | 349 | */ |
350 | static void p9_free_req(struct p9_client *c, struct p9_req_t *r) | 350 | static void p9_tag_remove(struct p9_client *c, struct p9_req_t *r) |
351 | { | 351 | { |
352 | unsigned long flags; | 352 | unsigned long flags; |
353 | u16 tag = r->tc.tag; | 353 | u16 tag = r->tc.tag; |
@@ -376,7 +376,7 @@ static void p9_tag_cleanup(struct p9_client *c) | |||
376 | rcu_read_lock(); | 376 | rcu_read_lock(); |
377 | idr_for_each_entry(&c->reqs, req, id) { | 377 | idr_for_each_entry(&c->reqs, req, id) { |
378 | pr_info("Tag %d still in use\n", id); | 378 | pr_info("Tag %d still in use\n", id); |
379 | p9_free_req(c, req); | 379 | p9_tag_remove(c, req); |
380 | } | 380 | } |
381 | rcu_read_unlock(); | 381 | rcu_read_unlock(); |
382 | } | 382 | } |
@@ -644,7 +644,7 @@ static int p9_client_flush(struct p9_client *c, struct p9_req_t *oldreq) | |||
644 | if (c->trans_mod->cancelled) | 644 | if (c->trans_mod->cancelled) |
645 | c->trans_mod->cancelled(c, oldreq); | 645 | c->trans_mod->cancelled(c, oldreq); |
646 | 646 | ||
647 | p9_free_req(c, req); | 647 | p9_tag_remove(c, req); |
648 | return 0; | 648 | return 0; |
649 | } | 649 | } |
650 | 650 | ||
@@ -678,7 +678,7 @@ static struct p9_req_t *p9_client_prepare_req(struct p9_client *c, | |||
678 | trace_9p_client_req(c, type, req->tc.tag); | 678 | trace_9p_client_req(c, type, req->tc.tag); |
679 | return req; | 679 | return req; |
680 | reterr: | 680 | reterr: |
681 | p9_free_req(c, req); | 681 | p9_tag_remove(c, req); |
682 | return ERR_PTR(err); | 682 | return ERR_PTR(err); |
683 | } | 683 | } |
684 | 684 | ||
@@ -688,7 +688,7 @@ reterr: | |||
688 | * @type: type of request | 688 | * @type: type of request |
689 | * @fmt: protocol format string (see protocol.c) | 689 | * @fmt: protocol format string (see protocol.c) |
690 | * | 690 | * |
691 | * Returns request structure (which client must free using p9_free_req) | 691 | * Returns request structure (which client must free using p9_tag_remove) |
692 | */ | 692 | */ |
693 | 693 | ||
694 | static struct p9_req_t * | 694 | static struct p9_req_t * |
@@ -764,7 +764,7 @@ recalc_sigpending: | |||
764 | if (!err) | 764 | if (!err) |
765 | return req; | 765 | return req; |
766 | reterr: | 766 | reterr: |
767 | p9_free_req(c, req); | 767 | p9_tag_remove(c, req); |
768 | return ERR_PTR(safe_errno(err)); | 768 | return ERR_PTR(safe_errno(err)); |
769 | } | 769 | } |
770 | 770 | ||
@@ -779,7 +779,7 @@ reterr: | |||
779 | * @hdrlen: reader header size, This is the size of response protocol data | 779 | * @hdrlen: reader header size, This is the size of response protocol data |
780 | * @fmt: protocol format string (see protocol.c) | 780 | * @fmt: protocol format string (see protocol.c) |
781 | * | 781 | * |
782 | * Returns request structure (which client must free using p9_free_req) | 782 | * Returns request structure (which client must free using p9_tag_remove) |
783 | */ | 783 | */ |
784 | static struct p9_req_t *p9_client_zc_rpc(struct p9_client *c, int8_t type, | 784 | static struct p9_req_t *p9_client_zc_rpc(struct p9_client *c, int8_t type, |
785 | struct iov_iter *uidata, | 785 | struct iov_iter *uidata, |
@@ -846,7 +846,7 @@ recalc_sigpending: | |||
846 | if (!err) | 846 | if (!err) |
847 | return req; | 847 | return req; |
848 | reterr: | 848 | reterr: |
849 | p9_free_req(c, req); | 849 | p9_tag_remove(c, req); |
850 | return ERR_PTR(safe_errno(err)); | 850 | return ERR_PTR(safe_errno(err)); |
851 | } | 851 | } |
852 | 852 | ||
@@ -949,7 +949,7 @@ static int p9_client_version(struct p9_client *c) | |||
949 | 949 | ||
950 | error: | 950 | error: |
951 | kfree(version); | 951 | kfree(version); |
952 | p9_free_req(c, req); | 952 | p9_tag_remove(c, req); |
953 | 953 | ||
954 | return err; | 954 | return err; |
955 | } | 955 | } |
@@ -1091,7 +1091,7 @@ struct p9_fid *p9_client_attach(struct p9_client *clnt, struct p9_fid *afid, | |||
1091 | err = p9pdu_readf(&req->rc, clnt->proto_version, "Q", &qid); | 1091 | err = p9pdu_readf(&req->rc, clnt->proto_version, "Q", &qid); |
1092 | if (err) { | 1092 | if (err) { |
1093 | trace_9p_protocol_dump(clnt, &req->rc); | 1093 | trace_9p_protocol_dump(clnt, &req->rc); |
1094 | p9_free_req(clnt, req); | 1094 | p9_tag_remove(clnt, req); |
1095 | goto error; | 1095 | goto error; |
1096 | } | 1096 | } |
1097 | 1097 | ||
@@ -1100,7 +1100,7 @@ struct p9_fid *p9_client_attach(struct p9_client *clnt, struct p9_fid *afid, | |||
1100 | 1100 | ||
1101 | memmove(&fid->qid, &qid, sizeof(struct p9_qid)); | 1101 | memmove(&fid->qid, &qid, sizeof(struct p9_qid)); |
1102 | 1102 | ||
1103 | p9_free_req(clnt, req); | 1103 | p9_tag_remove(clnt, req); |
1104 | return fid; | 1104 | return fid; |
1105 | 1105 | ||
1106 | error: | 1106 | error: |
@@ -1148,10 +1148,10 @@ struct p9_fid *p9_client_walk(struct p9_fid *oldfid, uint16_t nwname, | |||
1148 | err = p9pdu_readf(&req->rc, clnt->proto_version, "R", &nwqids, &wqids); | 1148 | err = p9pdu_readf(&req->rc, clnt->proto_version, "R", &nwqids, &wqids); |
1149 | if (err) { | 1149 | if (err) { |
1150 | trace_9p_protocol_dump(clnt, &req->rc); | 1150 | trace_9p_protocol_dump(clnt, &req->rc); |
1151 | p9_free_req(clnt, req); | 1151 | p9_tag_remove(clnt, req); |
1152 | goto clunk_fid; | 1152 | goto clunk_fid; |
1153 | } | 1153 | } |
1154 | p9_free_req(clnt, req); | 1154 | p9_tag_remove(clnt, req); |
1155 | 1155 | ||
1156 | p9_debug(P9_DEBUG_9P, "<<< RWALK nwqid %d:\n", nwqids); | 1156 | p9_debug(P9_DEBUG_9P, "<<< RWALK nwqid %d:\n", nwqids); |
1157 | 1157 | ||
@@ -1226,7 +1226,7 @@ int p9_client_open(struct p9_fid *fid, int mode) | |||
1226 | fid->iounit = iounit; | 1226 | fid->iounit = iounit; |
1227 | 1227 | ||
1228 | free_and_error: | 1228 | free_and_error: |
1229 | p9_free_req(clnt, req); | 1229 | p9_tag_remove(clnt, req); |
1230 | error: | 1230 | error: |
1231 | return err; | 1231 | return err; |
1232 | } | 1232 | } |
@@ -1271,7 +1271,7 @@ int p9_client_create_dotl(struct p9_fid *ofid, const char *name, u32 flags, u32 | |||
1271 | ofid->iounit = iounit; | 1271 | ofid->iounit = iounit; |
1272 | 1272 | ||
1273 | free_and_error: | 1273 | free_and_error: |
1274 | p9_free_req(clnt, req); | 1274 | p9_tag_remove(clnt, req); |
1275 | error: | 1275 | error: |
1276 | return err; | 1276 | return err; |
1277 | } | 1277 | } |
@@ -1316,7 +1316,7 @@ int p9_client_fcreate(struct p9_fid *fid, const char *name, u32 perm, int mode, | |||
1316 | fid->iounit = iounit; | 1316 | fid->iounit = iounit; |
1317 | 1317 | ||
1318 | free_and_error: | 1318 | free_and_error: |
1319 | p9_free_req(clnt, req); | 1319 | p9_tag_remove(clnt, req); |
1320 | error: | 1320 | error: |
1321 | return err; | 1321 | return err; |
1322 | } | 1322 | } |
@@ -1350,7 +1350,7 @@ int p9_client_symlink(struct p9_fid *dfid, const char *name, | |||
1350 | qid->type, (unsigned long long)qid->path, qid->version); | 1350 | qid->type, (unsigned long long)qid->path, qid->version); |
1351 | 1351 | ||
1352 | free_and_error: | 1352 | free_and_error: |
1353 | p9_free_req(clnt, req); | 1353 | p9_tag_remove(clnt, req); |
1354 | error: | 1354 | error: |
1355 | return err; | 1355 | return err; |
1356 | } | 1356 | } |
@@ -1370,7 +1370,7 @@ int p9_client_link(struct p9_fid *dfid, struct p9_fid *oldfid, const char *newna | |||
1370 | return PTR_ERR(req); | 1370 | return PTR_ERR(req); |
1371 | 1371 | ||
1372 | p9_debug(P9_DEBUG_9P, "<<< RLINK\n"); | 1372 | p9_debug(P9_DEBUG_9P, "<<< RLINK\n"); |
1373 | p9_free_req(clnt, req); | 1373 | p9_tag_remove(clnt, req); |
1374 | return 0; | 1374 | return 0; |
1375 | } | 1375 | } |
1376 | EXPORT_SYMBOL(p9_client_link); | 1376 | EXPORT_SYMBOL(p9_client_link); |
@@ -1394,7 +1394,7 @@ int p9_client_fsync(struct p9_fid *fid, int datasync) | |||
1394 | 1394 | ||
1395 | p9_debug(P9_DEBUG_9P, "<<< RFSYNC fid %d\n", fid->fid); | 1395 | p9_debug(P9_DEBUG_9P, "<<< RFSYNC fid %d\n", fid->fid); |
1396 | 1396 | ||
1397 | p9_free_req(clnt, req); | 1397 | p9_tag_remove(clnt, req); |
1398 | 1398 | ||
1399 | error: | 1399 | error: |
1400 | return err; | 1400 | return err; |
@@ -1429,7 +1429,7 @@ again: | |||
1429 | 1429 | ||
1430 | p9_debug(P9_DEBUG_9P, "<<< RCLUNK fid %d\n", fid->fid); | 1430 | p9_debug(P9_DEBUG_9P, "<<< RCLUNK fid %d\n", fid->fid); |
1431 | 1431 | ||
1432 | p9_free_req(clnt, req); | 1432 | p9_tag_remove(clnt, req); |
1433 | error: | 1433 | error: |
1434 | /* | 1434 | /* |
1435 | * Fid is not valid even after a failed clunk | 1435 | * Fid is not valid even after a failed clunk |
@@ -1463,7 +1463,7 @@ int p9_client_remove(struct p9_fid *fid) | |||
1463 | 1463 | ||
1464 | p9_debug(P9_DEBUG_9P, "<<< RREMOVE fid %d\n", fid->fid); | 1464 | p9_debug(P9_DEBUG_9P, "<<< RREMOVE fid %d\n", fid->fid); |
1465 | 1465 | ||
1466 | p9_free_req(clnt, req); | 1466 | p9_tag_remove(clnt, req); |
1467 | error: | 1467 | error: |
1468 | if (err == -ERESTARTSYS) | 1468 | if (err == -ERESTARTSYS) |
1469 | p9_client_clunk(fid); | 1469 | p9_client_clunk(fid); |
@@ -1490,7 +1490,7 @@ int p9_client_unlinkat(struct p9_fid *dfid, const char *name, int flags) | |||
1490 | } | 1490 | } |
1491 | p9_debug(P9_DEBUG_9P, "<<< RUNLINKAT fid %d %s\n", dfid->fid, name); | 1491 | p9_debug(P9_DEBUG_9P, "<<< RUNLINKAT fid %d %s\n", dfid->fid, name); |
1492 | 1492 | ||
1493 | p9_free_req(clnt, req); | 1493 | p9_tag_remove(clnt, req); |
1494 | error: | 1494 | error: |
1495 | return err; | 1495 | return err; |
1496 | } | 1496 | } |
@@ -1542,7 +1542,7 @@ p9_client_read(struct p9_fid *fid, u64 offset, struct iov_iter *to, int *err) | |||
1542 | "D", &count, &dataptr); | 1542 | "D", &count, &dataptr); |
1543 | if (*err) { | 1543 | if (*err) { |
1544 | trace_9p_protocol_dump(clnt, &req->rc); | 1544 | trace_9p_protocol_dump(clnt, &req->rc); |
1545 | p9_free_req(clnt, req); | 1545 | p9_tag_remove(clnt, req); |
1546 | break; | 1546 | break; |
1547 | } | 1547 | } |
1548 | if (rsize < count) { | 1548 | if (rsize < count) { |
@@ -1552,7 +1552,7 @@ p9_client_read(struct p9_fid *fid, u64 offset, struct iov_iter *to, int *err) | |||
1552 | 1552 | ||
1553 | p9_debug(P9_DEBUG_9P, "<<< RREAD count %d\n", count); | 1553 | p9_debug(P9_DEBUG_9P, "<<< RREAD count %d\n", count); |
1554 | if (!count) { | 1554 | if (!count) { |
1555 | p9_free_req(clnt, req); | 1555 | p9_tag_remove(clnt, req); |
1556 | break; | 1556 | break; |
1557 | } | 1557 | } |
1558 | 1558 | ||
@@ -1562,7 +1562,7 @@ p9_client_read(struct p9_fid *fid, u64 offset, struct iov_iter *to, int *err) | |||
1562 | offset += n; | 1562 | offset += n; |
1563 | if (n != count) { | 1563 | if (n != count) { |
1564 | *err = -EFAULT; | 1564 | *err = -EFAULT; |
1565 | p9_free_req(clnt, req); | 1565 | p9_tag_remove(clnt, req); |
1566 | break; | 1566 | break; |
1567 | } | 1567 | } |
1568 | } else { | 1568 | } else { |
@@ -1570,7 +1570,7 @@ p9_client_read(struct p9_fid *fid, u64 offset, struct iov_iter *to, int *err) | |||
1570 | total += count; | 1570 | total += count; |
1571 | offset += count; | 1571 | offset += count; |
1572 | } | 1572 | } |
1573 | p9_free_req(clnt, req); | 1573 | p9_tag_remove(clnt, req); |
1574 | } | 1574 | } |
1575 | return total; | 1575 | return total; |
1576 | } | 1576 | } |
@@ -1614,7 +1614,7 @@ p9_client_write(struct p9_fid *fid, u64 offset, struct iov_iter *from, int *err) | |||
1614 | *err = p9pdu_readf(&req->rc, clnt->proto_version, "d", &count); | 1614 | *err = p9pdu_readf(&req->rc, clnt->proto_version, "d", &count); |
1615 | if (*err) { | 1615 | if (*err) { |
1616 | trace_9p_protocol_dump(clnt, &req->rc); | 1616 | trace_9p_protocol_dump(clnt, &req->rc); |
1617 | p9_free_req(clnt, req); | 1617 | p9_tag_remove(clnt, req); |
1618 | break; | 1618 | break; |
1619 | } | 1619 | } |
1620 | if (rsize < count) { | 1620 | if (rsize < count) { |
@@ -1624,7 +1624,7 @@ p9_client_write(struct p9_fid *fid, u64 offset, struct iov_iter *from, int *err) | |||
1624 | 1624 | ||
1625 | p9_debug(P9_DEBUG_9P, "<<< RWRITE count %d\n", count); | 1625 | p9_debug(P9_DEBUG_9P, "<<< RWRITE count %d\n", count); |
1626 | 1626 | ||
1627 | p9_free_req(clnt, req); | 1627 | p9_tag_remove(clnt, req); |
1628 | iov_iter_advance(from, count); | 1628 | iov_iter_advance(from, count); |
1629 | total += count; | 1629 | total += count; |
1630 | offset += count; | 1630 | offset += count; |
@@ -1658,7 +1658,7 @@ struct p9_wstat *p9_client_stat(struct p9_fid *fid) | |||
1658 | err = p9pdu_readf(&req->rc, clnt->proto_version, "wS", &ignored, ret); | 1658 | err = p9pdu_readf(&req->rc, clnt->proto_version, "wS", &ignored, ret); |
1659 | if (err) { | 1659 | if (err) { |
1660 | trace_9p_protocol_dump(clnt, &req->rc); | 1660 | trace_9p_protocol_dump(clnt, &req->rc); |
1661 | p9_free_req(clnt, req); | 1661 | p9_tag_remove(clnt, req); |
1662 | goto error; | 1662 | goto error; |
1663 | } | 1663 | } |
1664 | 1664 | ||
@@ -1675,7 +1675,7 @@ struct p9_wstat *p9_client_stat(struct p9_fid *fid) | |||
1675 | from_kgid(&init_user_ns, ret->n_gid), | 1675 | from_kgid(&init_user_ns, ret->n_gid), |
1676 | from_kuid(&init_user_ns, ret->n_muid)); | 1676 | from_kuid(&init_user_ns, ret->n_muid)); |
1677 | 1677 | ||
1678 | p9_free_req(clnt, req); | 1678 | p9_tag_remove(clnt, req); |
1679 | return ret; | 1679 | return ret; |
1680 | 1680 | ||
1681 | error: | 1681 | error: |
@@ -1711,7 +1711,7 @@ struct p9_stat_dotl *p9_client_getattr_dotl(struct p9_fid *fid, | |||
1711 | err = p9pdu_readf(&req->rc, clnt->proto_version, "A", ret); | 1711 | err = p9pdu_readf(&req->rc, clnt->proto_version, "A", ret); |
1712 | if (err) { | 1712 | if (err) { |
1713 | trace_9p_protocol_dump(clnt, &req->rc); | 1713 | trace_9p_protocol_dump(clnt, &req->rc); |
1714 | p9_free_req(clnt, req); | 1714 | p9_tag_remove(clnt, req); |
1715 | goto error; | 1715 | goto error; |
1716 | } | 1716 | } |
1717 | 1717 | ||
@@ -1736,7 +1736,7 @@ struct p9_stat_dotl *p9_client_getattr_dotl(struct p9_fid *fid, | |||
1736 | ret->st_ctime_nsec, ret->st_btime_sec, ret->st_btime_nsec, | 1736 | ret->st_ctime_nsec, ret->st_btime_sec, ret->st_btime_nsec, |
1737 | ret->st_gen, ret->st_data_version); | 1737 | ret->st_gen, ret->st_data_version); |
1738 | 1738 | ||
1739 | p9_free_req(clnt, req); | 1739 | p9_tag_remove(clnt, req); |
1740 | return ret; | 1740 | return ret; |
1741 | 1741 | ||
1742 | error: | 1742 | error: |
@@ -1805,7 +1805,7 @@ int p9_client_wstat(struct p9_fid *fid, struct p9_wstat *wst) | |||
1805 | 1805 | ||
1806 | p9_debug(P9_DEBUG_9P, "<<< RWSTAT fid %d\n", fid->fid); | 1806 | p9_debug(P9_DEBUG_9P, "<<< RWSTAT fid %d\n", fid->fid); |
1807 | 1807 | ||
1808 | p9_free_req(clnt, req); | 1808 | p9_tag_remove(clnt, req); |
1809 | error: | 1809 | error: |
1810 | return err; | 1810 | return err; |
1811 | } | 1811 | } |
@@ -1837,7 +1837,7 @@ int p9_client_setattr(struct p9_fid *fid, struct p9_iattr_dotl *p9attr) | |||
1837 | goto error; | 1837 | goto error; |
1838 | } | 1838 | } |
1839 | p9_debug(P9_DEBUG_9P, "<<< RSETATTR fid %d\n", fid->fid); | 1839 | p9_debug(P9_DEBUG_9P, "<<< RSETATTR fid %d\n", fid->fid); |
1840 | p9_free_req(clnt, req); | 1840 | p9_tag_remove(clnt, req); |
1841 | error: | 1841 | error: |
1842 | return err; | 1842 | return err; |
1843 | } | 1843 | } |
@@ -1865,7 +1865,7 @@ int p9_client_statfs(struct p9_fid *fid, struct p9_rstatfs *sb) | |||
1865 | &sb->files, &sb->ffree, &sb->fsid, &sb->namelen); | 1865 | &sb->files, &sb->ffree, &sb->fsid, &sb->namelen); |
1866 | if (err) { | 1866 | if (err) { |
1867 | trace_9p_protocol_dump(clnt, &req->rc); | 1867 | trace_9p_protocol_dump(clnt, &req->rc); |
1868 | p9_free_req(clnt, req); | 1868 | p9_tag_remove(clnt, req); |
1869 | goto error; | 1869 | goto error; |
1870 | } | 1870 | } |
1871 | 1871 | ||
@@ -1876,7 +1876,7 @@ int p9_client_statfs(struct p9_fid *fid, struct p9_rstatfs *sb) | |||
1876 | sb->blocks, sb->bfree, sb->bavail, sb->files, sb->ffree, | 1876 | sb->blocks, sb->bfree, sb->bavail, sb->files, sb->ffree, |
1877 | sb->fsid, (long int)sb->namelen); | 1877 | sb->fsid, (long int)sb->namelen); |
1878 | 1878 | ||
1879 | p9_free_req(clnt, req); | 1879 | p9_tag_remove(clnt, req); |
1880 | error: | 1880 | error: |
1881 | return err; | 1881 | return err; |
1882 | } | 1882 | } |
@@ -1904,7 +1904,7 @@ int p9_client_rename(struct p9_fid *fid, | |||
1904 | 1904 | ||
1905 | p9_debug(P9_DEBUG_9P, "<<< RRENAME fid %d\n", fid->fid); | 1905 | p9_debug(P9_DEBUG_9P, "<<< RRENAME fid %d\n", fid->fid); |
1906 | 1906 | ||
1907 | p9_free_req(clnt, req); | 1907 | p9_tag_remove(clnt, req); |
1908 | error: | 1908 | error: |
1909 | return err; | 1909 | return err; |
1910 | } | 1910 | } |
@@ -1934,7 +1934,7 @@ int p9_client_renameat(struct p9_fid *olddirfid, const char *old_name, | |||
1934 | p9_debug(P9_DEBUG_9P, "<<< RRENAMEAT newdirfid %d new name %s\n", | 1934 | p9_debug(P9_DEBUG_9P, "<<< RRENAMEAT newdirfid %d new name %s\n", |
1935 | newdirfid->fid, new_name); | 1935 | newdirfid->fid, new_name); |
1936 | 1936 | ||
1937 | p9_free_req(clnt, req); | 1937 | p9_tag_remove(clnt, req); |
1938 | error: | 1938 | error: |
1939 | return err; | 1939 | return err; |
1940 | } | 1940 | } |
@@ -1971,10 +1971,10 @@ struct p9_fid *p9_client_xattrwalk(struct p9_fid *file_fid, | |||
1971 | err = p9pdu_readf(&req->rc, clnt->proto_version, "q", attr_size); | 1971 | err = p9pdu_readf(&req->rc, clnt->proto_version, "q", attr_size); |
1972 | if (err) { | 1972 | if (err) { |
1973 | trace_9p_protocol_dump(clnt, &req->rc); | 1973 | trace_9p_protocol_dump(clnt, &req->rc); |
1974 | p9_free_req(clnt, req); | 1974 | p9_tag_remove(clnt, req); |
1975 | goto clunk_fid; | 1975 | goto clunk_fid; |
1976 | } | 1976 | } |
1977 | p9_free_req(clnt, req); | 1977 | p9_tag_remove(clnt, req); |
1978 | p9_debug(P9_DEBUG_9P, "<<< RXATTRWALK fid %d size %llu\n", | 1978 | p9_debug(P9_DEBUG_9P, "<<< RXATTRWALK fid %d size %llu\n", |
1979 | attr_fid->fid, *attr_size); | 1979 | attr_fid->fid, *attr_size); |
1980 | return attr_fid; | 1980 | return attr_fid; |
@@ -2008,7 +2008,7 @@ int p9_client_xattrcreate(struct p9_fid *fid, const char *name, | |||
2008 | goto error; | 2008 | goto error; |
2009 | } | 2009 | } |
2010 | p9_debug(P9_DEBUG_9P, "<<< RXATTRCREATE fid %d\n", fid->fid); | 2010 | p9_debug(P9_DEBUG_9P, "<<< RXATTRCREATE fid %d\n", fid->fid); |
2011 | p9_free_req(clnt, req); | 2011 | p9_tag_remove(clnt, req); |
2012 | error: | 2012 | error: |
2013 | return err; | 2013 | return err; |
2014 | } | 2014 | } |
@@ -2071,11 +2071,11 @@ int p9_client_readdir(struct p9_fid *fid, char *data, u32 count, u64 offset) | |||
2071 | if (non_zc) | 2071 | if (non_zc) |
2072 | memmove(data, dataptr, count); | 2072 | memmove(data, dataptr, count); |
2073 | 2073 | ||
2074 | p9_free_req(clnt, req); | 2074 | p9_tag_remove(clnt, req); |
2075 | return count; | 2075 | return count; |
2076 | 2076 | ||
2077 | free_and_error: | 2077 | free_and_error: |
2078 | p9_free_req(clnt, req); | 2078 | p9_tag_remove(clnt, req); |
2079 | error: | 2079 | error: |
2080 | return err; | 2080 | return err; |
2081 | } | 2081 | } |
@@ -2106,7 +2106,7 @@ int p9_client_mknod_dotl(struct p9_fid *fid, const char *name, int mode, | |||
2106 | (unsigned long long)qid->path, qid->version); | 2106 | (unsigned long long)qid->path, qid->version); |
2107 | 2107 | ||
2108 | error: | 2108 | error: |
2109 | p9_free_req(clnt, req); | 2109 | p9_tag_remove(clnt, req); |
2110 | return err; | 2110 | return err; |
2111 | 2111 | ||
2112 | } | 2112 | } |
@@ -2137,7 +2137,7 @@ int p9_client_mkdir_dotl(struct p9_fid *fid, const char *name, int mode, | |||
2137 | (unsigned long long)qid->path, qid->version); | 2137 | (unsigned long long)qid->path, qid->version); |
2138 | 2138 | ||
2139 | error: | 2139 | error: |
2140 | p9_free_req(clnt, req); | 2140 | p9_tag_remove(clnt, req); |
2141 | return err; | 2141 | return err; |
2142 | 2142 | ||
2143 | } | 2143 | } |
@@ -2170,7 +2170,7 @@ int p9_client_lock_dotl(struct p9_fid *fid, struct p9_flock *flock, u8 *status) | |||
2170 | } | 2170 | } |
2171 | p9_debug(P9_DEBUG_9P, "<<< RLOCK status %i\n", *status); | 2171 | p9_debug(P9_DEBUG_9P, "<<< RLOCK status %i\n", *status); |
2172 | error: | 2172 | error: |
2173 | p9_free_req(clnt, req); | 2173 | p9_tag_remove(clnt, req); |
2174 | return err; | 2174 | return err; |
2175 | 2175 | ||
2176 | } | 2176 | } |
@@ -2205,7 +2205,7 @@ int p9_client_getlock_dotl(struct p9_fid *fid, struct p9_getlock *glock) | |||
2205 | "proc_id %d client_id %s\n", glock->type, glock->start, | 2205 | "proc_id %d client_id %s\n", glock->type, glock->start, |
2206 | glock->length, glock->proc_id, glock->client_id); | 2206 | glock->length, glock->proc_id, glock->client_id); |
2207 | error: | 2207 | error: |
2208 | p9_free_req(clnt, req); | 2208 | p9_tag_remove(clnt, req); |
2209 | return err; | 2209 | return err; |
2210 | } | 2210 | } |
2211 | EXPORT_SYMBOL(p9_client_getlock_dotl); | 2211 | EXPORT_SYMBOL(p9_client_getlock_dotl); |
@@ -2231,7 +2231,7 @@ int p9_client_readlink(struct p9_fid *fid, char **target) | |||
2231 | } | 2231 | } |
2232 | p9_debug(P9_DEBUG_9P, "<<< RREADLINK target %s\n", *target); | 2232 | p9_debug(P9_DEBUG_9P, "<<< RREADLINK target %s\n", *target); |
2233 | error: | 2233 | error: |
2234 | p9_free_req(clnt, req); | 2234 | p9_tag_remove(clnt, req); |
2235 | return err; | 2235 | return err; |
2236 | } | 2236 | } |
2237 | EXPORT_SYMBOL(p9_client_readlink); | 2237 | EXPORT_SYMBOL(p9_client_readlink); |