xfs
[Top] [All Lists]

[PATCH 2/3] XFS: Print error when xfs_ialloc_ag_select fails to find con

To: xfs@xxxxxxxxxxx
Subject: [PATCH 2/3] XFS: Print error when xfs_ialloc_ag_select fails to find continuous free space.
From: raghu.prabhu13@xxxxxxxxx
Date: Wed, 12 Sep 2012 03:43:23 +0530
Cc: david@xxxxxxxxxxxxx, Raghavendra D Prabhu <rprabhu@xxxxxxxxxxx>, Ben Myers <bpm@xxxxxxx> (supporter:XFS FILESYSTEM), Alex Elder <elder@xxxxxxxxxx> (supporter:XFS FILESYSTEM), linux-kernel@xxxxxxxxxxxxxxx (open list)
Dkim-signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=from:to:cc:subject:date:message-id:x-mailer:in-reply-to:references :in-reply-to:references; bh=YVcrsi5eaW/Tp1Jpga3OoQ4NKjI1Bvrk6BUe1IMjEFE=; b=hdzV7EGgCk8hhU+KiW5ElqjOMhbBjl+82oMwbhhBk+3N2qBi0RtgAj2MLcbzYVrD6E mx2v4A20M2OhJABbeUHZgM/++rCTlKXQaXoJk4VrctPkyzclHuVUnohxxUCLY/UAlSCH pFmmSyve2IOVt1KuJ27ZRK0JjBwNp9Xn+4nuc5w+YSQJg7Zrm+9k4E5TwH+hyxTZc5Qg nnFCCPMfNfPcWgpzvblhnYDEZldz+hMlQ8Q66lJ6WYN6tZBWvwlHxMGEVfqs1O5bymJk HXrFX6DfGtqKeDm3FjtzlQeDCP3CMJRqMqGipDZNpJKTqfi1iIgoNQVsQ8L/emlw1+o/ 2GVw==
In-reply-to: <cover.1347396641.git.rprabhu@xxxxxxxxxxx>
In-reply-to: <cover.1347396641.git.rprabhu@xxxxxxxxxxx>
References: <cover.1347396641.git.rprabhu@xxxxxxxxxxx>
References: <cover.1347396641.git.rprabhu@xxxxxxxxxxx>
From: Raghavendra D Prabhu <rprabhu@xxxxxxxxxxx>

When xfs_ialloc_ag_select fails to find any AG with continuous free blocks
required for inode allocation, printk the error in ratelimited manner.

Signed-off-by: Raghavendra D Prabhu <rprabhu@xxxxxxxxxxx>
---
 fs/xfs/xfs_ialloc.c | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

diff --git a/fs/xfs/xfs_ialloc.c b/fs/xfs/xfs_ialloc.c
index 5aceb3f..e75a39d 100644
--- a/fs/xfs/xfs_ialloc.c
+++ b/fs/xfs/xfs_ialloc.c
@@ -539,8 +539,11 @@ nextag:
                if (agno >= agcount)
                        agno = 0;
                if (agno == pagno) {
-                       if (flags == 0)
+                       if (flags == 0) {
+                               xfs_err_ratelimited(mp,
+                                       "Out of continuous free blocks for 
inode allocation");
                                return NULLAGNUMBER;
+                       }
                        flags = 0;
                }
        }
-- 
1.7.12

<Prev in Thread] Current Thread [Next in Thread>