From 4a7bccfc175509cb74ca118b10f8dfcd38538dda Mon Sep 17 00:00:00 2001 From: kalpak <kalpak> Date: Wed, 17 Oct 2007 21:48:48 +0000 Subject: [PATCH] b=13454 i=adilger, johann Fix bugs in jbd-stats patches spotted by coverity. --- lustre/ChangeLog | 2 +- lustre/kernel_patches/patches/jbd-stats-2.6-rhel5.patch | 4 ++-- lustre/kernel_patches/patches/jbd-stats-2.6-sles10.patch | 4 ++-- lustre/kernel_patches/patches/jbd-stats-2.6.5.patch | 4 ++-- lustre/kernel_patches/patches/jbd-stats-2.6.9.patch | 4 ++-- 5 files changed, 9 insertions(+), 9 deletions(-) diff --git a/lustre/ChangeLog b/lustre/ChangeLog index 6bfea6df9b..17b8ca197d 100644 --- a/lustre/ChangeLog +++ b/lustre/ChangeLog @@ -84,7 +84,7 @@ Details : llapi_semantic_traverse() modifies the "path" argument by Severity : normal Bugzilla : 13454 -Description: Add jbd statistics patch for RHEL5 and 2.6.18-vanilla +Description: Add jbd statistics patch for RHEL5 and 2.6.18-vanilla. Severity : normal Bugzilla : 11673 diff --git a/lustre/kernel_patches/patches/jbd-stats-2.6-rhel5.patch b/lustre/kernel_patches/patches/jbd-stats-2.6-rhel5.patch index 50fb6f5a87..e7c178dae8 100644 --- a/lustre/kernel_patches/patches/jbd-stats-2.6-rhel5.patch +++ b/lustre/kernel_patches/patches/jbd-stats-2.6-rhel5.patch @@ -269,7 +269,7 @@ Index: linux-2.6.18-8.1.8/fs/jbd/journal.c + return -EIO; + size = sizeof(struct transaction_stats_s) * journal->j_history_max; + s->stats = kmalloc(size, GFP_KERNEL); -+ if (s == NULL) { ++ if (s->stats == NULL) { + kfree(s); + return -EIO; + } @@ -369,7 +369,7 @@ Index: linux-2.6.18-8.1.8/fs/jbd/journal.c + return -EIO; + size = sizeof(struct transaction_stats_s); + s->stats = kmalloc(size, GFP_KERNEL); -+ if (s == NULL) { ++ if (s->stats == NULL) { + kfree(s); + return -EIO; + } diff --git a/lustre/kernel_patches/patches/jbd-stats-2.6-sles10.patch b/lustre/kernel_patches/patches/jbd-stats-2.6-sles10.patch index 2660339bd0..acd81f8c28 100644 --- a/lustre/kernel_patches/patches/jbd-stats-2.6-sles10.patch +++ b/lustre/kernel_patches/patches/jbd-stats-2.6-sles10.patch @@ -269,7 +269,7 @@ Index: linux-2.6.16.46-0.14/fs/jbd/journal.c + return -EIO; + size = sizeof(struct transaction_stats_s) * journal->j_history_max; + s->stats = kmalloc(size, GFP_KERNEL); -+ if (s == NULL) { ++ if (s->stats == NULL) { + kfree(s); + return -EIO; + } @@ -369,7 +369,7 @@ Index: linux-2.6.16.46-0.14/fs/jbd/journal.c + return -EIO; + size = sizeof(struct transaction_stats_s); + s->stats = kmalloc(size, GFP_KERNEL); -+ if (s == NULL) { ++ if (s->stats == NULL) { + kfree(s); + return -EIO; + } diff --git a/lustre/kernel_patches/patches/jbd-stats-2.6.5.patch b/lustre/kernel_patches/patches/jbd-stats-2.6.5.patch index b2abf46e03..4873794e12 100644 --- a/lustre/kernel_patches/patches/jbd-stats-2.6.5.patch +++ b/lustre/kernel_patches/patches/jbd-stats-2.6.5.patch @@ -459,7 +459,7 @@ Index: linux-2.6.5-7.201/fs/jbd/journal.c + return -EIO; + size = sizeof(struct transaction_stats_s) * journal->j_history_max; + s->stats = kmalloc(size, GFP_KERNEL); -+ if (s == NULL) { ++ if (s->stats == NULL) { + kfree(s); + return -EIO; + } @@ -578,7 +578,7 @@ Index: linux-2.6.5-7.201/fs/jbd/journal.c + return -EIO; + size = sizeof(struct transaction_stats_s); + s->stats = kmalloc(size, GFP_KERNEL); -+ if (s == NULL) { ++ if (s->stats == NULL) { + kfree(s); + return -EIO; + } diff --git a/lustre/kernel_patches/patches/jbd-stats-2.6.9.patch b/lustre/kernel_patches/patches/jbd-stats-2.6.9.patch index 3847e1e499..0140efdb19 100644 --- a/lustre/kernel_patches/patches/jbd-stats-2.6.9.patch +++ b/lustre/kernel_patches/patches/jbd-stats-2.6.9.patch @@ -460,7 +460,7 @@ Index: linux-2.6.9/fs/jbd/journal.c + return -EIO; + size = sizeof(struct transaction_stats_s) * journal->j_history_max; + s->stats = kmalloc(size, GFP_KERNEL); -+ if (s == NULL) { ++ if (s->stats == NULL) { + kfree(s); + return -EIO; + } @@ -560,7 +560,7 @@ Index: linux-2.6.9/fs/jbd/journal.c + return -EIO; + size = sizeof(struct transaction_stats_s); + s->stats = kmalloc(size, GFP_KERNEL); -+ if (s == NULL) { ++ if (s->stats == NULL) { + kfree(s); + return -EIO; + } -- GitLab