Re: 2.4.18-rc4-aa1 XFS oopses caused by cpio

From: Stephen Lord (lord@sgi.com)
Date: Fri Mar 08 2002 - 10:59:05 EST


Stephen Lord wrote:

>>
> Ah, so you ran growfs on the filesystem, thats the key here. It looks
> like the new code
> does not handle growfs correctly, the structure which is null is not
> allocated in the
> expansion case. I should have a fix shortly.
>
> Steve

Hi,

Can you try and repeat with this patch, it should apply reasonably
cleanly to the aa tree.

Steve


===========================================================================
Index: linux/fs/xfs/xfs_alloc.c
===========================================================================

2234a2235,2236
> pag->pagb_list = kmem_zalloc(XFS_PAGB_NUM_SLOTS *
> sizeof(xfs_perag_busy_t), KM_SLEEP);

===========================================================================
Index: linux/fs/xfs/xfs_mount.c
===========================================================================

151,152c151,153
< kmem_free(mp->m_perag[agno].pagb_list,
< sizeof(xfs_perag_busy_t) * XFS_PAGB_NUM_SLOTS);

---
> 			if (mp->m_perag[agno].pagb_list)
> 				kmem_free(mp->m_perag[agno].pagb_list,
> 				  sizeof(xfs_perag_busy_t) * XFS_PAGB_NUM_SLOTS);
877,881d877
< 	for (agno = 0; agno < sbp->sb_agcount; agno++) {
< 		mp->m_perag[agno].pagb_count = 0;
< 		mp->m_perag[agno].pagb_list = kmem_zalloc(XFS_PAGB_NUM_SLOTS *
< 					sizeof(xfs_perag_busy_t), KM_SLEEP);
< 	}
1066,1067c1062,1064
< 		kmem_free(mp->m_perag[agno].pagb_list,
< 		  sizeof(xfs_perag_busy_t) * XFS_PAGB_NUM_SLOTS);
---
> 		if (mp->m_perag[agno].pagb_list)
> 			kmem_free(mp->m_perag[agno].pagb_list,
> 			  sizeof(xfs_perag_busy_t) * XFS_PAGB_NUM_SLOTS);

- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/



This archive was generated by hypermail 2b29 : Fri Mar 15 2002 - 22:00:08 EST