diff options
Diffstat (limited to 'include/linux/scatterlist.h')
-rw-r--r-- | include/linux/scatterlist.h | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/include/linux/scatterlist.h b/include/linux/scatterlist.h index 416e000dfe81..e3ff21dbac53 100644 --- a/include/linux/scatterlist.h +++ b/include/linux/scatterlist.h | |||
@@ -191,8 +191,8 @@ static inline void sg_chain(struct scatterlist *prv, unsigned int prv_nents, | |||
191 | /* | 191 | /* |
192 | * offset and length are unused for chain entry. Clear them. | 192 | * offset and length are unused for chain entry. Clear them. |
193 | */ | 193 | */ |
194 | prv->offset = 0; | 194 | prv[prv_nents - 1].offset = 0; |
195 | prv->length = 0; | 195 | prv[prv_nents - 1].length = 0; |
196 | 196 | ||
197 | /* | 197 | /* |
198 | * Set lowest bit to indicate a link pointer, and make sure to clear | 198 | * Set lowest bit to indicate a link pointer, and make sure to clear |