aboutsummaryrefslogtreecommitdiffstats
path: root/lib/scatterlist.c
diff options
context:
space:
mode:
authorThierry Reding <treding@nvidia.com>2014-11-26 09:41:09 +0100
committerThierry Reding <treding@nvidia.com>2014-11-26 09:42:11 +0100
commit7f06dd61248a75668bbb39b6fcca6ff407745df8 (patch)
tree30cefbd6f503d20557e24a1765a027687170a7da /lib/scatterlist.c
parentLinux 3.18-rc1 (diff)
parentpowerpc/iommu: Rename iommu_[un]map_sg functions (diff)
downloadlinux-dev-7f06dd61248a75668bbb39b6fcca6ff407745df8.tar.xz
linux-dev-7f06dd61248a75668bbb39b6fcca6ff407745df8.zip
Merge branch 'core' of git://git.kernel.org/pub/scm/linux/kernel/git/joro/iommu
This branch contains a couple of changes that will conflict with the Tegra SMMU driver rewrite. Since the driver is largely rewritten the conflict resolution is non-trivial.
Diffstat (limited to 'lib/scatterlist.c')
-rw-r--r--lib/scatterlist.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/lib/scatterlist.c b/lib/scatterlist.c
index 9cdf62f8accd..c9f2e8c6ccc9 100644
--- a/lib/scatterlist.c
+++ b/lib/scatterlist.c
@@ -203,10 +203,10 @@ void __sg_free_table(struct sg_table *table, unsigned int max_ents,
}
table->orig_nents -= sg_size;
- if (!skip_first_chunk) {
- free_fn(sgl, alloc_size);
+ if (skip_first_chunk)
skip_first_chunk = false;
- }
+ else
+ free_fn(sgl, alloc_size);
sgl = next;
}