From 6a63ad04d2052627a9413c35443110fdb0bb2e59 Mon Sep 17 00:00:00 2001 From: Kip Macsai-Goren Date: Mon, 7 Jun 2021 17:02:31 -0400 Subject: [PATCH] regression working partially done page mask --- wally-pipelined/src/mmu/physicalpagemask.sv | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/wally-pipelined/src/mmu/physicalpagemask.sv b/wally-pipelined/src/mmu/physicalpagemask.sv index b64fac08..be44941f 100644 --- a/wally-pipelined/src/mmu/physicalpagemask.sv +++ b/wally-pipelined/src/mmu/physicalpagemask.sv @@ -32,15 +32,15 @@ module physicalpagemask #(parameter BITS = 20, parameter HIGH_SEGMENT_BITS = 10) ( - input [BITS-1:0] **** VirtualAddress, - input [BITS-1:0] *** PPN, + input [BITS-1:0] VirtualAddress, //*** + input [BITS-1:0] PPN, //*** input [1:0] PageType, input [`SVMODE_BITS-1:0] SvMode, - output [BITS-1:0]*** PhysicalAddress + output [BITS-1:0] PhysicalAddress //*** ); - logic [***] OffsetMask; + logic [34:0] OffsetMask; generate if (`XLEN == 32) begin @@ -57,6 +57,7 @@ module physicalpagemask #(parameter BITS = 20, 2: OffsetMask = 56'hFFFFFFC0000000; // gigapage: 26 bits of PPN, 30 bits of offset 3: OffsetMask = 56'hFFFF8000000000; // terapage: 17 bits of PPN, 39 bits of offset endcase + end endgenerate // merge low bits of the virtual address containing the offset with high bits of the PPN