arch: k210: Fix k210 timer on QEMU 6.1 or later

Summary:
- I noticed that 'sleep 1' on nsh took 10 seconds on QEMU-6.1,
  though the old version (e.g. QEMU-5.2) works correctly.
- I think we should implement PLL for the QEMU environment.
  However, this fix works as a tentative solution.

Impact:
- K210 on QEMU only

Tested
- Tested with QEMU-7.1

Signed-off-by: Masayuki Ishikawa <Masayuki.Ishikawa@jp.sony.com>
This commit is contained in:
Masayuki Ishikawa 2023-04-06 08:31:48 +09:00 committed by David Sidrane
parent 8be8aab9bb
commit 5e7d48f4b0
1 changed files with 1 additions and 1 deletions

View File

@ -45,7 +45,7 @@
****************************************************************************/
#ifdef CONFIG_K210_WITH_QEMU
#define MTIMER_FREQ 10000000
#define MTIMER_FREQ 1000000
#else
#define MTIMER_FREQ (k210_get_cpuclk() / 50)
#endif