Skip to content
This repository

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse code

software/memtest: fix bandwidth computation

  • Loading branch information...
commit 525c32976b7161fabb8e4a85a94d3948124065a9 1 parent 7e3b84a
Sébastien Bourdeauducq authored

Showing 1 changed file with 3 additions and 3 deletions. Show diff stats Hide diff stats

  1. 6  software/memtest/main.c
6  software/memtest/main.c
@@ -20,9 +20,9 @@ static void membw_service(void)
20 20
 		nr = lasmicon_bandwidth_nreads_read();
21 21
 		nw = lasmicon_bandwidth_nwrites_read();
22 22
 		f = identifier_frequency_read();
23  
-		rdb = nr*f >> (24 - 7);
24  
-		wrb = nw*f >> (24 - 7);
25  
-		printf("read:%4dMbps  write:%4dMbps  all:%4dMbps\n", rdb/1000000, wrb/1000000, (rdb + wrb)/1000000);
  23
+		rdb = (nr*f >> (24 - 7))/1000000ULL;
  24
+		wrb = (nw*f >> (24 - 7))/1000000ULL;
  25
+		printf("read:%5dMbps  write:%5dMbps  all:%5dMbps\n", rdb, wrb, rdb + wrb);
26 26
 	}
27 27
 }
28 28
 

0 notes on commit 525c329

Please sign in to comment.
Something went wrong with that request. Please try again.