aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDave Chinner <dchinner@redhat.com>2010-04-13 01:06:46 -0400
committerAlex Elder <aelder@sgi.com>2010-05-19 10:58:10 -0400
commit9abbc539bf7f299819ad0a235064a1b643ab6407 (patch)
tree0c15d4f4933bce3a1a1db19509f4993ce2e46286
parente6b1f27370fc67ac9868b2dbe2c22bc26952900e (diff)
xfs: add log item recovery tracing
Currently there is no tracing in log recovery, so it is difficult to determine what is going on when something goes wrong. Add tracing for log item recovery to provide visibility into the log recovery process. The tracing added shows regions being extracted from the log transactions and added to the transaction hash forming recovery items, followed by the reordering, cancelling and finally recovery of the items. Signed-off-by: Dave Chinner <dchinner@redhat.com> Reviewed-by: Christoph Hellwig <hch@lst.de>
-rw-r--r--fs/xfs/linux-2.6/xfs_trace.c3
-rw-r--r--fs/xfs/linux-2.6/xfs_trace.h138
-rw-r--r--fs/xfs/xfs_buf_item.h2
-rw-r--r--fs/xfs/xfs_log_recover.c44
-rw-r--r--fs/xfs/xfs_trans.h9
5 files changed, 187 insertions, 9 deletions
diff --git a/fs/xfs/linux-2.6/xfs_trace.c b/fs/xfs/linux-2.6/xfs_trace.c
index 5a107601e969..2a460581308f 100644
--- a/fs/xfs/linux-2.6/xfs_trace.c
+++ b/fs/xfs/linux-2.6/xfs_trace.c
@@ -50,6 +50,9 @@
50#include "xfs_aops.h" 50#include "xfs_aops.h"
51#include "quota/xfs_dquot_item.h" 51#include "quota/xfs_dquot_item.h"
52#include "quota/xfs_dquot.h" 52#include "quota/xfs_dquot.h"
53#include "xfs_log_recover.h"
54#include "xfs_buf_item.h"
55#include "xfs_inode_item.h"
53 56
54/* 57/*
55 * We include this last to have the helpers above available for the trace 58 * We include this last to have the helpers above available for the trace
diff --git a/fs/xfs/linux-2.6/xfs_trace.h b/fs/xfs/linux-2.6/xfs_trace.h
index 65371859c753..33f7d2b7afeb 100644
--- a/fs/xfs/linux-2.6/xfs_trace.h
+++ b/fs/xfs/linux-2.6/xfs_trace.h
@@ -32,6 +32,10 @@ struct xfs_da_node_entry;
32struct xfs_dquot; 32struct xfs_dquot;
33struct xlog_ticket; 33struct xlog_ticket;
34struct log; 34struct log;
35struct xlog_recover;
36struct xlog_recover_item;
37struct xfs_buf_log_format;
38struct xfs_inode_log_format;
35 39
36DECLARE_EVENT_CLASS(xfs_attr_list_class, 40DECLARE_EVENT_CLASS(xfs_attr_list_class,
37 TP_PROTO(struct xfs_attr_list_context *ctx), 41 TP_PROTO(struct xfs_attr_list_context *ctx),
@@ -1502,6 +1506,140 @@ DEFINE_EVENT(xfs_swap_extent_class, name, \
1502DEFINE_SWAPEXT_EVENT(xfs_swap_extent_before); 1506DEFINE_SWAPEXT_EVENT(xfs_swap_extent_before);
1503DEFINE_SWAPEXT_EVENT(xfs_swap_extent_after); 1507DEFINE_SWAPEXT_EVENT(xfs_swap_extent_after);
1504 1508
1509DECLARE_EVENT_CLASS(xfs_log_recover_item_class,
1510 TP_PROTO(struct log *log, struct xlog_recover *trans,
1511 struct xlog_recover_item *item, int pass),
1512 TP_ARGS(log, trans, item, pass),
1513 TP_STRUCT__entry(
1514 __field(dev_t, dev)
1515 __field(unsigned long, item)
1516 __field(xlog_tid_t, tid)
1517 __field(int, type)
1518 __field(int, pass)
1519 __field(int, count)
1520 __field(int, total)
1521 ),
1522 TP_fast_assign(
1523 __entry->dev = log->l_mp->m_super->s_dev;
1524 __entry->item = (unsigned long)item;
1525 __entry->tid = trans->r_log_tid;
1526 __entry->type = ITEM_TYPE(item);
1527 __entry->pass = pass;
1528 __entry->count = item->ri_cnt;
1529 __entry->total = item->ri_total;
1530 ),
1531 TP_printk("dev %d:%d trans 0x%x, pass %d, item 0x%p, item type %s "
1532 "item region count/total %d/%d",
1533 MAJOR(__entry->dev), MINOR(__entry->dev),
1534 __entry->tid,
1535 __entry->pass,
1536 (void *)__entry->item,
1537 __print_symbolic(__entry->type, XFS_LI_TYPE_DESC),
1538 __entry->count,
1539 __entry->total)
1540)
1541
1542#define DEFINE_LOG_RECOVER_ITEM(name) \
1543DEFINE_EVENT(xfs_log_recover_item_class, name, \
1544 TP_PROTO(struct log *log, struct xlog_recover *trans, \
1545 struct xlog_recover_item *item, int pass), \
1546 TP_ARGS(log, trans, item, pass))
1547
1548DEFINE_LOG_RECOVER_ITEM(xfs_log_recover_item_add);
1549DEFINE_LOG_RECOVER_ITEM(xfs_log_recover_item_add_cont);
1550DEFINE_LOG_RECOVER_ITEM(xfs_log_recover_item_reorder_head);
1551DEFINE_LOG_RECOVER_ITEM(xfs_log_recover_item_reorder_tail);
1552DEFINE_LOG_RECOVER_ITEM(xfs_log_recover_item_recover);
1553
1554DECLARE_EVENT_CLASS(xfs_log_recover_buf_item_class,
1555 TP_PROTO(struct log *log, struct xfs_buf_log_format *buf_f),
1556 TP_ARGS(log, buf_f),
1557 TP_STRUCT__entry(
1558 __field(dev_t, dev)
1559 __field(__int64_t, blkno)
1560 __field(unsigned short, len)
1561 __field(unsigned short, flags)
1562 __field(unsigned short, size)
1563 __field(unsigned int, map_size)
1564 ),
1565 TP_fast_assign(
1566 __entry->dev = log->l_mp->m_super->s_dev;
1567 __entry->blkno = buf_f->blf_blkno;
1568 __entry->len = buf_f->blf_len;
1569 __entry->flags = buf_f->blf_flags;
1570 __entry->size = buf_f->blf_size;
1571 __entry->map_size = buf_f->blf_map_size;
1572 ),
1573 TP_printk("dev %d:%d blkno 0x%llx, len %u, flags 0x%x, size %d, "
1574 "map_size %d",
1575 MAJOR(__entry->dev), MINOR(__entry->dev),
1576 __entry->blkno,
1577 __entry->len,
1578 __entry->flags,
1579 __entry->size,
1580 __entry->map_size)
1581)
1582
1583#define DEFINE_LOG_RECOVER_BUF_ITEM(name) \
1584DEFINE_EVENT(xfs_log_recover_buf_item_class, name, \
1585 TP_PROTO(struct log *log, struct xfs_buf_log_format *buf_f), \
1586 TP_ARGS(log, buf_f))
1587
1588DEFINE_LOG_RECOVER_BUF_ITEM(xfs_log_recover_buf_not_cancel);
1589DEFINE_LOG_RECOVER_BUF_ITEM(xfs_log_recover_buf_cancel);
1590DEFINE_LOG_RECOVER_BUF_ITEM(xfs_log_recover_buf_cancel_add);
1591DEFINE_LOG_RECOVER_BUF_ITEM(xfs_log_recover_buf_cancel_ref_inc);
1592DEFINE_LOG_RECOVER_BUF_ITEM(xfs_log_recover_buf_recover);
1593DEFINE_LOG_RECOVER_BUF_ITEM(xfs_log_recover_buf_inode_buf);
1594DEFINE_LOG_RECOVER_BUF_ITEM(xfs_log_recover_buf_reg_buf);
1595DEFINE_LOG_RECOVER_BUF_ITEM(xfs_log_recover_buf_dquot_buf);
1596
1597DECLARE_EVENT_CLASS(xfs_log_recover_ino_item_class,
1598 TP_PROTO(struct log *log, struct xfs_inode_log_format *in_f),
1599 TP_ARGS(log, in_f),
1600 TP_STRUCT__entry(
1601 __field(dev_t, dev)
1602 __field(xfs_ino_t, ino)
1603 __field(unsigned short, size)
1604 __field(int, fields)
1605 __field(unsigned short, asize)
1606 __field(unsigned short, dsize)
1607 __field(__int64_t, blkno)
1608 __field(int, len)
1609 __field(int, boffset)
1610 ),
1611 TP_fast_assign(
1612 __entry->dev = log->l_mp->m_super->s_dev;
1613 __entry->ino = in_f->ilf_ino;
1614 __entry->size = in_f->ilf_size;
1615 __entry->fields = in_f->ilf_fields;
1616 __entry->asize = in_f->ilf_asize;
1617 __entry->dsize = in_f->ilf_dsize;
1618 __entry->blkno = in_f->ilf_blkno;
1619 __entry->len = in_f->ilf_len;
1620 __entry->boffset = in_f->ilf_boffset;
1621 ),
1622 TP_printk("dev %d:%d ino 0x%llx, size %u, fields 0x%x, asize %d, "
1623 "dsize %d, blkno 0x%llx, len %d, boffset %d",
1624 MAJOR(__entry->dev), MINOR(__entry->dev),
1625 __entry->ino,
1626 __entry->size,
1627 __entry->fields,
1628 __entry->asize,
1629 __entry->dsize,
1630 __entry->blkno,
1631 __entry->len,
1632 __entry->boffset)
1633)
1634#define DEFINE_LOG_RECOVER_INO_ITEM(name) \
1635DEFINE_EVENT(xfs_log_recover_ino_item_class, name, \
1636 TP_PROTO(struct log *log, struct xfs_inode_log_format *in_f), \
1637 TP_ARGS(log, in_f))
1638
1639DEFINE_LOG_RECOVER_INO_ITEM(xfs_log_recover_inode_recover);
1640DEFINE_LOG_RECOVER_INO_ITEM(xfs_log_recover_inode_cancel);
1641DEFINE_LOG_RECOVER_INO_ITEM(xfs_log_recover_inode_skip);
1642
1505#endif /* _TRACE_XFS_H */ 1643#endif /* _TRACE_XFS_H */
1506 1644
1507#undef TRACE_INCLUDE_PATH 1645#undef TRACE_INCLUDE_PATH
diff --git a/fs/xfs/xfs_buf_item.h b/fs/xfs/xfs_buf_item.h
index 217f34af00cb..df4454511f73 100644
--- a/fs/xfs/xfs_buf_item.h
+++ b/fs/xfs/xfs_buf_item.h
@@ -26,7 +26,7 @@ extern kmem_zone_t *xfs_buf_item_zone;
26 * have been logged. 26 * have been logged.
27 * For 6.2 and beyond, this is XFS_LI_BUF. We use this to log everything. 27 * For 6.2 and beyond, this is XFS_LI_BUF. We use this to log everything.
28 */ 28 */
29typedef struct xfs_buf_log_format_t { 29typedef struct xfs_buf_log_format {
30 unsigned short blf_type; /* buf log item type indicator */ 30 unsigned short blf_type; /* buf log item type indicator */
31 unsigned short blf_size; /* size of this item */ 31 unsigned short blf_size; /* size of this item */
32 ushort blf_flags; /* misc state */ 32 ushort blf_flags; /* misc state */
diff --git a/fs/xfs/xfs_log_recover.c b/fs/xfs/xfs_log_recover.c
index 22e6efdc17ea..f21eb8ad2d97 100644
--- a/fs/xfs/xfs_log_recover.c
+++ b/fs/xfs/xfs_log_recover.c
@@ -1408,6 +1408,7 @@ xlog_recover_add_item(
1408 1408
1409STATIC int 1409STATIC int
1410xlog_recover_add_to_cont_trans( 1410xlog_recover_add_to_cont_trans(
1411 struct log *log,
1411 xlog_recover_t *trans, 1412 xlog_recover_t *trans,
1412 xfs_caddr_t dp, 1413 xfs_caddr_t dp,
1413 int len) 1414 int len)
@@ -1434,6 +1435,7 @@ xlog_recover_add_to_cont_trans(
1434 memcpy(&ptr[old_len], dp, len); /* d, s, l */ 1435 memcpy(&ptr[old_len], dp, len); /* d, s, l */
1435 item->ri_buf[item->ri_cnt-1].i_len += len; 1436 item->ri_buf[item->ri_cnt-1].i_len += len;
1436 item->ri_buf[item->ri_cnt-1].i_addr = ptr; 1437 item->ri_buf[item->ri_cnt-1].i_addr = ptr;
1438 trace_xfs_log_recover_item_add_cont(log, trans, item, 0);
1437 return 0; 1439 return 0;
1438} 1440}
1439 1441
@@ -1452,6 +1454,7 @@ xlog_recover_add_to_cont_trans(
1452 */ 1454 */
1453STATIC int 1455STATIC int
1454xlog_recover_add_to_trans( 1456xlog_recover_add_to_trans(
1457 struct log *log,
1455 xlog_recover_t *trans, 1458 xlog_recover_t *trans,
1456 xfs_caddr_t dp, 1459 xfs_caddr_t dp,
1457 int len) 1460 int len)
@@ -1510,6 +1513,7 @@ xlog_recover_add_to_trans(
1510 item->ri_buf[item->ri_cnt].i_addr = ptr; 1513 item->ri_buf[item->ri_cnt].i_addr = ptr;
1511 item->ri_buf[item->ri_cnt].i_len = len; 1514 item->ri_buf[item->ri_cnt].i_len = len;
1512 item->ri_cnt++; 1515 item->ri_cnt++;
1516 trace_xfs_log_recover_item_add(log, trans, item, 0);
1513 return 0; 1517 return 0;
1514} 1518}
1515 1519
@@ -1521,7 +1525,9 @@ xlog_recover_add_to_trans(
1521 */ 1525 */
1522STATIC int 1526STATIC int
1523xlog_recover_reorder_trans( 1527xlog_recover_reorder_trans(
1524 xlog_recover_t *trans) 1528 struct log *log,
1529 xlog_recover_t *trans,
1530 int pass)
1525{ 1531{
1526 xlog_recover_item_t *item, *n; 1532 xlog_recover_item_t *item, *n;
1527 LIST_HEAD(sort_list); 1533 LIST_HEAD(sort_list);
@@ -1535,6 +1541,8 @@ xlog_recover_reorder_trans(
1535 switch (ITEM_TYPE(item)) { 1541 switch (ITEM_TYPE(item)) {
1536 case XFS_LI_BUF: 1542 case XFS_LI_BUF:
1537 if (!(buf_f->blf_flags & XFS_BLI_CANCEL)) { 1543 if (!(buf_f->blf_flags & XFS_BLI_CANCEL)) {
1544 trace_xfs_log_recover_item_reorder_head(log,
1545 trans, item, pass);
1538 list_move(&item->ri_list, &trans->r_itemq); 1546 list_move(&item->ri_list, &trans->r_itemq);
1539 break; 1547 break;
1540 } 1548 }
@@ -1543,6 +1551,8 @@ xlog_recover_reorder_trans(
1543 case XFS_LI_QUOTAOFF: 1551 case XFS_LI_QUOTAOFF:
1544 case XFS_LI_EFD: 1552 case XFS_LI_EFD:
1545 case XFS_LI_EFI: 1553 case XFS_LI_EFI:
1554 trace_xfs_log_recover_item_reorder_tail(log,
1555 trans, item, pass);
1546 list_move_tail(&item->ri_list, &trans->r_itemq); 1556 list_move_tail(&item->ri_list, &trans->r_itemq);
1547 break; 1557 break;
1548 default: 1558 default:
@@ -1592,8 +1602,10 @@ xlog_recover_do_buffer_pass1(
1592 /* 1602 /*
1593 * If this isn't a cancel buffer item, then just return. 1603 * If this isn't a cancel buffer item, then just return.
1594 */ 1604 */
1595 if (!(flags & XFS_BLI_CANCEL)) 1605 if (!(flags & XFS_BLI_CANCEL)) {
1606 trace_xfs_log_recover_buf_not_cancel(log, buf_f);
1596 return; 1607 return;
1608 }
1597 1609
1598 /* 1610 /*
1599 * Insert an xfs_buf_cancel record into the hash table of 1611 * Insert an xfs_buf_cancel record into the hash table of
@@ -1627,6 +1639,7 @@ xlog_recover_do_buffer_pass1(
1627 while (nextp != NULL) { 1639 while (nextp != NULL) {
1628 if (nextp->bc_blkno == blkno && nextp->bc_len == len) { 1640 if (nextp->bc_blkno == blkno && nextp->bc_len == len) {
1629 nextp->bc_refcount++; 1641 nextp->bc_refcount++;
1642 trace_xfs_log_recover_buf_cancel_ref_inc(log, buf_f);
1630 return; 1643 return;
1631 } 1644 }
1632 prevp = nextp; 1645 prevp = nextp;
@@ -1640,6 +1653,7 @@ xlog_recover_do_buffer_pass1(
1640 bcp->bc_refcount = 1; 1653 bcp->bc_refcount = 1;
1641 bcp->bc_next = NULL; 1654 bcp->bc_next = NULL;
1642 prevp->bc_next = bcp; 1655 prevp->bc_next = bcp;
1656 trace_xfs_log_recover_buf_cancel_add(log, buf_f);
1643} 1657}
1644 1658
1645/* 1659/*
@@ -1779,6 +1793,8 @@ xlog_recover_do_inode_buffer(
1779 unsigned int *data_map = NULL; 1793 unsigned int *data_map = NULL;
1780 unsigned int map_size = 0; 1794 unsigned int map_size = 0;
1781 1795
1796 trace_xfs_log_recover_buf_inode_buf(mp->m_log, buf_f);
1797
1782 switch (buf_f->blf_type) { 1798 switch (buf_f->blf_type) {
1783 case XFS_LI_BUF: 1799 case XFS_LI_BUF:
1784 data_map = buf_f->blf_data_map; 1800 data_map = buf_f->blf_data_map;
@@ -1874,6 +1890,7 @@ xlog_recover_do_inode_buffer(
1874/*ARGSUSED*/ 1890/*ARGSUSED*/
1875STATIC void 1891STATIC void
1876xlog_recover_do_reg_buffer( 1892xlog_recover_do_reg_buffer(
1893 struct xfs_mount *mp,
1877 xlog_recover_item_t *item, 1894 xlog_recover_item_t *item,
1878 xfs_buf_t *bp, 1895 xfs_buf_t *bp,
1879 xfs_buf_log_format_t *buf_f) 1896 xfs_buf_log_format_t *buf_f)
@@ -1885,6 +1902,8 @@ xlog_recover_do_reg_buffer(
1885 unsigned int map_size = 0; 1902 unsigned int map_size = 0;
1886 int error; 1903 int error;
1887 1904
1905 trace_xfs_log_recover_buf_reg_buf(mp->m_log, buf_f);
1906
1888 switch (buf_f->blf_type) { 1907 switch (buf_f->blf_type) {
1889 case XFS_LI_BUF: 1908 case XFS_LI_BUF:
1890 data_map = buf_f->blf_data_map; 1909 data_map = buf_f->blf_data_map;
@@ -2083,6 +2102,8 @@ xlog_recover_do_dquot_buffer(
2083{ 2102{
2084 uint type; 2103 uint type;
2085 2104
2105 trace_xfs_log_recover_buf_dquot_buf(log, buf_f);
2106
2086 /* 2107 /*
2087 * Filesystems are required to send in quota flags at mount time. 2108 * Filesystems are required to send in quota flags at mount time.
2088 */ 2109 */
@@ -2103,7 +2124,7 @@ xlog_recover_do_dquot_buffer(
2103 if (log->l_quotaoffs_flag & type) 2124 if (log->l_quotaoffs_flag & type)
2104 return; 2125 return;
2105 2126
2106 xlog_recover_do_reg_buffer(item, bp, buf_f); 2127 xlog_recover_do_reg_buffer(mp, item, bp, buf_f);
2107} 2128}
2108 2129
2109/* 2130/*
@@ -2164,9 +2185,11 @@ xlog_recover_do_buffer_trans(
2164 */ 2185 */
2165 cancel = xlog_recover_do_buffer_pass2(log, buf_f); 2186 cancel = xlog_recover_do_buffer_pass2(log, buf_f);
2166 if (cancel) { 2187 if (cancel) {
2188 trace_xfs_log_recover_buf_cancel(log, buf_f);
2167 return 0; 2189 return 0;
2168 } 2190 }
2169 } 2191 }
2192 trace_xfs_log_recover_buf_recover(log, buf_f);
2170 switch (buf_f->blf_type) { 2193 switch (buf_f->blf_type) {
2171 case XFS_LI_BUF: 2194 case XFS_LI_BUF:
2172 blkno = buf_f->blf_blkno; 2195 blkno = buf_f->blf_blkno;
@@ -2204,7 +2227,7 @@ xlog_recover_do_buffer_trans(
2204 (XFS_BLI_UDQUOT_BUF|XFS_BLI_PDQUOT_BUF|XFS_BLI_GDQUOT_BUF)) { 2227 (XFS_BLI_UDQUOT_BUF|XFS_BLI_PDQUOT_BUF|XFS_BLI_GDQUOT_BUF)) {
2205 xlog_recover_do_dquot_buffer(mp, log, item, bp, buf_f); 2228 xlog_recover_do_dquot_buffer(mp, log, item, bp, buf_f);
2206 } else { 2229 } else {
2207 xlog_recover_do_reg_buffer(item, bp, buf_f); 2230 xlog_recover_do_reg_buffer(mp, item, bp, buf_f);
2208 } 2231 }
2209 if (error) 2232 if (error)
2210 return XFS_ERROR(error); 2233 return XFS_ERROR(error);
@@ -2284,8 +2307,10 @@ xlog_recover_do_inode_trans(
2284 if (xlog_check_buffer_cancelled(log, in_f->ilf_blkno, 2307 if (xlog_check_buffer_cancelled(log, in_f->ilf_blkno,
2285 in_f->ilf_len, 0)) { 2308 in_f->ilf_len, 0)) {
2286 error = 0; 2309 error = 0;
2310 trace_xfs_log_recover_inode_cancel(log, in_f);
2287 goto error; 2311 goto error;
2288 } 2312 }
2313 trace_xfs_log_recover_inode_recover(log, in_f);
2289 2314
2290 bp = xfs_buf_read(mp->m_ddev_targp, in_f->ilf_blkno, in_f->ilf_len, 2315 bp = xfs_buf_read(mp->m_ddev_targp, in_f->ilf_blkno, in_f->ilf_len,
2291 XBF_LOCK); 2316 XBF_LOCK);
@@ -2337,6 +2362,7 @@ xlog_recover_do_inode_trans(
2337 /* do nothing */ 2362 /* do nothing */
2338 } else { 2363 } else {
2339 xfs_buf_relse(bp); 2364 xfs_buf_relse(bp);
2365 trace_xfs_log_recover_inode_skip(log, in_f);
2340 error = 0; 2366 error = 0;
2341 goto error; 2367 goto error;
2342 } 2368 }
@@ -2758,11 +2784,12 @@ xlog_recover_do_trans(
2758 int error = 0; 2784 int error = 0;
2759 xlog_recover_item_t *item; 2785 xlog_recover_item_t *item;
2760 2786
2761 error = xlog_recover_reorder_trans(trans); 2787 error = xlog_recover_reorder_trans(log, trans, pass);
2762 if (error) 2788 if (error)
2763 return error; 2789 return error;
2764 2790
2765 list_for_each_entry(item, &trans->r_itemq, ri_list) { 2791 list_for_each_entry(item, &trans->r_itemq, ri_list) {
2792 trace_xfs_log_recover_item_recover(log, trans, item, pass);
2766 switch (ITEM_TYPE(item)) { 2793 switch (ITEM_TYPE(item)) {
2767 case XFS_LI_BUF: 2794 case XFS_LI_BUF:
2768 error = xlog_recover_do_buffer_trans(log, item, pass); 2795 error = xlog_recover_do_buffer_trans(log, item, pass);
@@ -2919,8 +2946,9 @@ xlog_recover_process_data(
2919 error = xlog_recover_unmount_trans(trans); 2946 error = xlog_recover_unmount_trans(trans);
2920 break; 2947 break;
2921 case XLOG_WAS_CONT_TRANS: 2948 case XLOG_WAS_CONT_TRANS:
2922 error = xlog_recover_add_to_cont_trans(trans, 2949 error = xlog_recover_add_to_cont_trans(log,
2923 dp, be32_to_cpu(ohead->oh_len)); 2950 trans, dp,
2951 be32_to_cpu(ohead->oh_len));
2924 break; 2952 break;
2925 case XLOG_START_TRANS: 2953 case XLOG_START_TRANS:
2926 xlog_warn( 2954 xlog_warn(
@@ -2930,7 +2958,7 @@ xlog_recover_process_data(
2930 break; 2958 break;
2931 case 0: 2959 case 0:
2932 case XLOG_CONTINUE_TRANS: 2960 case XLOG_CONTINUE_TRANS:
2933 error = xlog_recover_add_to_trans(trans, 2961 error = xlog_recover_add_to_trans(log, trans,
2934 dp, be32_to_cpu(ohead->oh_len)); 2962 dp, be32_to_cpu(ohead->oh_len));
2935 break; 2963 break;
2936 default: 2964 default:
diff --git a/fs/xfs/xfs_trans.h b/fs/xfs/xfs_trans.h
index 82574ef36580..c62beee0921e 100644
--- a/fs/xfs/xfs_trans.h
+++ b/fs/xfs/xfs_trans.h
@@ -49,6 +49,15 @@ typedef struct xfs_trans_header {
49#define XFS_LI_DQUOT 0x123d 49#define XFS_LI_DQUOT 0x123d
50#define XFS_LI_QUOTAOFF 0x123e 50#define XFS_LI_QUOTAOFF 0x123e
51 51
52#define XFS_LI_TYPE_DESC \
53 { XFS_LI_EFI, "XFS_LI_EFI" }, \
54 { XFS_LI_EFD, "XFS_LI_EFD" }, \
55 { XFS_LI_IUNLINK, "XFS_LI_IUNLINK" }, \
56 { XFS_LI_INODE, "XFS_LI_INODE" }, \
57 { XFS_LI_BUF, "XFS_LI_BUF" }, \
58 { XFS_LI_DQUOT, "XFS_LI_DQUOT" }, \
59 { XFS_LI_QUOTAOFF, "XFS_LI_QUOTAOFF" }
60
52/* 61/*
53 * Transaction types. Used to distinguish types of buffers. 62 * Transaction types. Used to distinguish types of buffers.
54 */ 63 */