Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 371683
b: refs/heads/master
c: 422ca86
h: refs/heads/master
i:
  371681: b038575
  371679: 74502a2
v: v3
  • Loading branch information
Arve Hjønnevåg authored and Anton Vorontsov committed Apr 4, 2013
1 parent f5309b5 commit d1b330d
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: c53026722b5e5aaaf434565ddbe4d918c7d2a80d
refs/heads/master: 422ca8608c49d1e9bfed1c58a1ca448a8a38c0ad
3 changes: 2 additions & 1 deletion trunk/fs/pstore/ram_core.c
Original file line number Diff line number Diff line change
Expand Up @@ -187,7 +187,8 @@ static int persistent_ram_init_ecc(struct persistent_ram_zone *prz,
prz->ecc_block_size = 128;
prz->ecc_size = ecc_size;

ecc_blocks = DIV_ROUND_UP(prz->buffer_size, prz->ecc_block_size);
ecc_blocks = DIV_ROUND_UP(prz->buffer_size - prz->ecc_size,
prz->ecc_block_size + prz->ecc_size);
ecc_total = (ecc_blocks + 1) * prz->ecc_size;
if (ecc_total >= prz->buffer_size) {
pr_err("%s: invalid ecc_size %u (total %zu, buffer size %zu)\n",
Expand Down

0 comments on commit d1b330d

Please sign in to comment.