mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: James Hogan <james.hogan@imgtec.com>
To: Paul Burton <paul.burton@imgtec.com>
Cc: <linux-mips@linux-mips.org>, Ralf Baechle <ralf@linux-mips.org>,
	"Matt Redfearn" <matt.redfearn@imgtec.com>,
	<linux-kernel@vger.kernel.org>,
	"Thomas Gleixner" <tglx@linutronix.de>,
	Markos Chandras <markos.chandras@imgtec.com>
Subject: Re: [PATCH 06/15] MIPS: CM: Fix mips_cm_max_vp_width for UP kernels
Date: Wed, 3 Feb 2016 14:58:59 +0000	[thread overview]
Message-ID: <20160203145858.GH5464@jhogan-linux.le.imgtec.org> (raw)
In-Reply-To: <1454469335-14778-7-git-send-email-paul.burton@imgtec.com>

[-- Attachment #1: Type: text/plain, Size: 1446 bytes --]

On Wed, Feb 03, 2016 at 03:15:26AM +0000, Paul Burton wrote:
> Fix mips_cm_max_vp_width for UP kernels where it previously referenced
> smp_num_siblings, which is not declared for UP kernels. This led to
> build errors such as the following:
> 
>   drivers/built-in.o: In function `$L446':
>   irq-mips-gic.c:(.text+0x1994): undefined reference to `smp_num_siblings'
>   drivers/built-in.o:irq-mips-gic.c:(.text+0x199c): more undefined references to `smp_num_siblings' follow
> 
> On UP kernels simply return 1, leaving the reference to smp_num_siblings
> in place only for SMP kernels.
> 
> Signed-off-by: Paul Burton <paul.burton@imgtec.com>

Need tagging for stable v4.3+?

I do wonder if this should be handled in the header files though...

Cheers
James

> ---
> 
>  arch/mips/include/asm/mips-cm.h | 5 ++++-
>  1 file changed, 4 insertions(+), 1 deletion(-)
> 
> diff --git a/arch/mips/include/asm/mips-cm.h b/arch/mips/include/asm/mips-cm.h
> index 1395bbc..3fdb6c9 100644
> --- a/arch/mips/include/asm/mips-cm.h
> +++ b/arch/mips/include/asm/mips-cm.h
> @@ -462,7 +462,10 @@ static inline unsigned int mips_cm_max_vp_width(void)
>  	if (mips_cm_revision() >= CM_REV_CM3)
>  		return read_gcr_sys_config2() & CM_GCR_SYS_CONFIG2_MAXVPW_MSK;
>  
> -	return smp_num_siblings;
> +	if (config_enabled(CONFIG_SMP))
> +		return smp_num_siblings;
> +
> +	return 1;
>  }
>  
>  /**
> -- 
> 2.7.0
> 
> 

[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 819 bytes --]

  reply	other threads:[~2016-02-03 14:59 UTC|newest]

Thread overview: 23+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-02-03  3:15 [PATCH 00/15] Support for MIPSr6 Virtual Processors (multi-threading) Paul Burton
2016-02-03  3:15 ` [PATCH 01/15] MIPS: Detect MIPSr6 Virtual Processor support Paul Burton
2016-02-03  3:15 ` [PATCH 02/15] MIPS: traps: Make sure secondary cores have a sane ebase register Paul Burton
2016-02-03  3:15 ` [PATCH 03/15] MIPS: pm-cps: Avoid offset overflow on MIPSr6 Paul Burton
2016-02-03 14:48   ` James Hogan
2016-02-03  3:15 ` [PATCH 04/15] MIPS: CPC: Add start, stop and running CM3 CPC registers Paul Burton
2016-02-03  3:15 ` [PATCH 05/15] MIPS: CM: Add CM GCR_BEV_BASE accessors Paul Burton
2016-02-03  3:15 ` [PATCH 06/15] MIPS: CM: Fix mips_cm_max_vp_width for UP kernels Paul Burton
2016-02-03 14:58   ` James Hogan [this message]
2016-02-03 15:46     ` Paul Burton
2016-02-03 16:15       ` James Hogan
2016-02-03  3:15 ` [PATCH 07/15] irqchip: mips-gic: Use HW IDs for VPE_OTHER_ADDR Paul Burton
2016-02-18  1:47   ` Jason Cooper
2016-02-03  3:15 ` [PATCH 08/15] irqchip: mips-gic: Provide VP ID accessor Paul Burton
2016-02-18  1:48   ` Jason Cooper
2016-02-03  3:15 ` [PATCH 09/15] MIPS: smp-cps: Ensure our VP ident calculation is correct Paul Burton
2016-02-03  3:15 ` [PATCH 10/15] MIPS: smp-cps: Pull cache init into a function Paul Burton
2016-02-03  3:15 ` [PATCH 11/15] MIPS: smp-cps: Pull boot config retrieval out of mips_cps_boot_vpes Paul Burton
2016-02-03  3:15 ` [PATCH 12/15] MIPS: smp-cps: Skip core setup if coherent Paul Burton
2016-02-03  3:15 ` [PATCH 13/15] MIPS: smp-cps: Support MIPSr6 Virtual Processors Paul Burton
2016-02-03  3:15 ` [PATCH 14/15] MIPS: smp-cps: Add nothreads kernel parameter Paul Burton
2016-02-18  2:40   ` Florian Fainelli
2016-02-03  3:15 ` [PATCH 15/15] MIPS: smp-cps: Stop printing EJTAG exceptions to UART Paul Burton

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20160203145858.GH5464@jhogan-linux.le.imgtec.org \
    --to=james.hogan@imgtec.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mips@linux-mips.org \
    --cc=markos.chandras@imgtec.com \
    --cc=matt.redfearn@imgtec.com \
    --cc=paul.burton@imgtec.com \
    --cc=ralf@linux-mips.org \
    --cc=tglx@linutronix.de \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®