// SPDX-License-Identifier: GPL-2.0+ /* * Copyright (C) 2023 Loongson Technology Corporation Limited */ #include "lsdc_drv.h" #include "lsdc_probe.h" /* * Processor ID (implementation) values for bits 15:8 of the PRID register. */ #define LOONGSON_CPU_IMP_MASK … #define LOONGSON_CPU_IMP_SHIFT … #define LOONGARCH_CPU_IMP_LS2K1000 … #define LOONGARCH_CPU_IMP_LS2K2000 … #define LOONGARCH_CPU_IMP_LS3A5000 … #define LOONGSON_CPU_MIPS_IMP_LS2K … /* * Particular Revision values for bits 7:0 of the PRID register. */ #define LOONGSON_CPU_REV_MASK … #define LOONGARCH_CPUCFG_PRID_REG … /* * We can achieve fine-grained control with the information about the host. */ unsigned int loongson_cpu_get_prid(u8 *imp, u8 *rev) { … }