[Sound-open-firmware] [PATCH_V2 3/7] cnl-interrupt: refine interrupt setting for change in irq_desc

Liam Girdwood liam.r.girdwood at linux.intel.com
Tue May 8 09:38:26 CEST 2018


On Tue, 2018-05-08 at 14:23 +0800, Rander Wang wrote:
> diff --git a/src/platform/cannonlake/include/platform/platform.h
> b/src/platform/cannonlake/include/platform/platform.h
> index dc9a963..d157daa 100644
> --- a/src/platform/cannonlake/include/platform/platform.h
> +++ b/src/platform/cannonlake/include/platform/platform.h
> @@ -43,6 +43,8 @@ struct sof;
>  #define PLATFORM_SSP_COUNT 3
>  #define MAX_GPDMA_COUNT 2
>  
> +#define MAX_CORE_COUNT 4
> +
>  /* Host page size */
>  #define HOST_PAGE_SIZE         4096
>  #define PLATFORM_PAGE_TABLE_SIZE       256
> @@ -126,6 +128,14 @@ struct sof;
>  
>  extern struct timer *platform_timer;
>  
> +static inline int platform_get_core_id(void)
> +{
> +       int prid;
> +
> +       __asm__("rsr.prid %0" : "=a"(prid));
> +       return prid;
> +}
> +


Best to put this in src/arch/xtensa/include/arch/cpu.h

and rename to cpu_get_id()

Liam


More information about the Sound-open-firmware mailing list