Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 273301
b: refs/heads/master
c: 4fad809
h: refs/heads/master
i:
  273299: 9929ddb
v: v3
  • Loading branch information
Sedat Dilek authored and Mauro Carvalho Chehab committed Nov 1, 2011
1 parent 08f4755 commit 6b7fe4e
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 3 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: 535e9c78e1a80946283cecc742b687b3a5ff5109
refs/heads/master: 4fad8098bc3cc9dfe711b10b07df821ea30e6879
7 changes: 5 additions & 2 deletions trunk/drivers/edac/i7core_edac.c
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,7 @@
#include <linux/smp.h>
#include <asm/mce.h>
#include <asm/processor.h>
#include <asm/div64.h>

#include "edac_core.h"

Expand Down Expand Up @@ -2102,7 +2103,8 @@ static int set_sdram_scrub_rate(struct mem_ctl_info *mci, u32 new_bw)
* program the corresponding register value.
*/
scrub_interval = (unsigned long long)freq_dclk_mhz *
cache_line_size * 1000000 / new_bw;
cache_line_size * 1000000;
do_div(scrub_interval, new_bw);

if (!scrub_interval || scrub_interval > SCRUBINTERVAL_MASK)
return -EINVAL;
Expand Down Expand Up @@ -2153,7 +2155,8 @@ static int get_sdram_scrub_rate(struct mem_ctl_info *mci)

/* Calculate scrub rate value into byte/sec bandwidth */
scrub_rate = (unsigned long long)freq_dclk_mhz *
1000000 * cache_line_size / scrubval;
1000000 * cache_line_size;
do_div(scrub_rate, scrubval);
return (int)scrub_rate;
}

Expand Down

0 comments on commit 6b7fe4e

Please sign in to comment.