public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Mike Travis <travis@sgi.com>
To: Jaswinder Singh Rajput <jaswinder@infradead.org>
Cc: Ingo Molnar <mingo@redhat.com>,
	Rusty Russell <rusty@rustcorp.com.au>,
	"H. Peter Anvin" <hpa@zytor.com>,
	Thomas Gleixner <tglx@linutronix.de>,
	Linus Torvalds <torvalds@linux-foundation.org>,
	Jack Steiner <steiner@sgi.com>,
	LKML <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH 04/11] x86: cleanup remaining cpumask_t ops in smpboot code
Date: Tue, 06 Jan 2009 06:02:02 -0800	[thread overview]
Message-ID: <4963645A.1040201@sgi.com> (raw)
In-Reply-To: <1231223480.3235.22.camel@jaswinder.satnam>

Jaswinder Singh Rajput wrote:
> Hello Mike,
> 
> On Sun, Jan 4, 2009 at 6:48 PM, Mike Travis <travis@sgi.com> wrote:
>> --- linux-2.6-for-ingo.orig/arch/x86/include/asm/smp.h
>> +++ linux-2.6-for-ingo/arch/x86/include/asm/smp.h
>> @@ -18,9 +18,26 @@
>>  #include <asm/pda.h>
>>  #include <asm/thread_info.h>
>>  
>> +#ifdef CONFIG_X86_64
>> +
>> +extern cpumask_var_t cpu_callin_mask;
>> +extern cpumask_var_t cpu_callout_mask;
>> +extern cpumask_var_t cpu_initialized_mask;
>> +extern cpumask_var_t cpu_sibling_setup_mask;
>> +
>> +#else /* CONFIG_X86_32 */
>> +
>> +extern cpumask_t cpu_callin_map;
> 
> 
> I am not able to understand, why you choose asm/smp.h
> 
> You know that asm/smp.h should only be included for CONFIG_SMP

Hi Jaswinder,

I'll look closer but I had assumed that these masks would not be
used for UP configurations (it did not get any compile errors
with the allnoconfig).  In fact, any access to these masks for
UP would be unnecessary since there are no callouts, the boot
cpu is assumed initialized, and it has no siblings.  So the
masks are specific to SMP.

But as I said, I'll verify this.

Thanks,
Mike
> 
> ----- linux/smp.h -----
> #ifdef CONFIG_SMP
> 
> #include <asm/smp.h>
> 
> #endif /* !SMP */
> 
> -----------------------
> 
> If someday this will happen:
> 
> ----- asm/smp.h -----
> #ifndef _ASM_X86_SMP_H
> #define _ASM_X86_SMP_H
> #ifndef __ASSEMBLY__
> #ifdef CONFIG_SMP
> ...
> #else /* CONFIG_SMP */
> #error "Including wrong file, why you need smp.h for uniprocesor"
> #endif /* CONFIG_SMP */
> #endif /* __ASSEMBLY__ */
> #endif /* _ASM_X86_SMP_H */
> 
> -----------------------
> 
> Then ;-)
> 
> Are you planning to make some new file for this or you think some other file will be suitable for this.
> 
> If you have some future plans, please let me know.
> 
> Thanks
> --
> JSR


  reply	other threads:[~2009-01-06 14:02 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <1231222512.3235.6.camel@jaswinder.satnam>
2009-01-06  6:31 ` [PATCH 04/11] x86: cleanup remaining cpumask_t ops in smpboot code Jaswinder Singh Rajput
2009-01-06 14:02   ` Mike Travis [this message]
2009-01-06 14:28     ` Jaswinder Singh Rajput
2009-01-06 15:25       ` Mike Travis
2009-01-04 13:17 [PATCH 00/11] x86: cpumask: some more cpumask cleanups Mike Travis
2009-01-04 13:18 ` [PATCH 04/11] x86: cleanup remaining cpumask_t ops in smpboot code Mike Travis

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=4963645A.1040201@sgi.com \
    --to=travis@sgi.com \
    --cc=hpa@zytor.com \
    --cc=jaswinder@infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mingo@redhat.com \
    --cc=rusty@rustcorp.com.au \
    --cc=steiner@sgi.com \
    --cc=tglx@linutronix.de \
    --cc=torvalds@linux-foundation.org \
    /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