diff options
Diffstat (limited to 'lib/scatterlist.c')
-rw-r--r-- | lib/scatterlist.c | 6 |
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, | |||
203 | } | 203 | } |
204 | 204 | ||
205 | table->orig_nents -= sg_size; | 205 | table->orig_nents -= sg_size; |
206 | if (!skip_first_chunk) { | 206 | if (skip_first_chunk) |
207 | free_fn(sgl, alloc_size); | ||
208 | skip_first_chunk = false; | 207 | skip_first_chunk = false; |
209 | } | 208 | else |
209 | free_fn(sgl, alloc_size); | ||
210 | sgl = next; | 210 | sgl = next; |
211 | } | 211 | } |
212 | 212 | ||