Hi Gabe, Just had a look at specifications. You are right, it is definitely a bug.
Giacomo ________________________________ From: gem5-dev <[email protected]> on behalf of Gabe Black <[email protected]> Sent: 19 August 2019 07:03 To: gem5 Developer List <[email protected]>; Chun-Chen TK Hsu <[email protected]> Subject: [gem5-dev] Setting the CNTFRQ register in the ARM bootloader Hi ARM folks. We're trying to make sure we're setting up the CNTFRQ register properly in a fast model CPU we're hooking up to gem5, and I believe we have the simulator part of that set up properly. We have the input for the non core components of the model running at a fixed frequency, and during initialization we set the CNTFRQ register of each context to that frequency before starting the guest software My colleague TK noticed, however, that the ARM bootloader writes a compiled in value into the CNTFRQ register, and that will clobber the value we put there. In gem5, writing to the register CNTFRQ actually configures the frequency of that timer. That is not in line with what the documentation says, where CNTFRQ is supposed to be a read-only type register which just reports the frequency to software and doesn't do anything to control that frequency. Should gem5 be doing that? Is that how the generic system timer should be configured? Why was it done that way? Can we change it so gem5 sets it up like we do with the fast model, where the frequency is set outside of the host software and the CNTFRQ register just has a value jammed into it for software to discover? Gabe _______________________________________________ gem5-dev mailing list [email protected] http://m5sim.org/mailman/listinfo/gem5-dev IMPORTANT NOTICE: The contents of this email and any attachments are confidential and may also be privileged. If you are not the intended recipient, please notify the sender immediately and do not disclose the contents to any other person, use it for any purpose, or store or copy the information in any medium. Thank you. _______________________________________________ gem5-dev mailing list [email protected] http://m5sim.org/mailman/listinfo/gem5-dev
