The PRV field of DCSR is updated wrongly
Created by: shetalani
Apparently, executing dret to return from debug mode, that the hart has entered due to ebreak instruction with forced entry, brings the hart to M mode instead of U mode.
As in the following counter example, the whole dcsr is not updated for an ebreak instruction with a forced entry into debug mode (ebreaku is set in dcsr), thus, dret ends up moving the hart back wrongly to M mode.
Same case happens when debug mode is entered due to a debug request while the hart is operating in U mode.
Product: OneSpin 360 DV-Verify App: RVV Tool's version: 2019.2.1