Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1235503

Re: [PATCH RFC 3/5] powerpc:numa create 1:1 mappaing between chipid and nid

From Raghavendra K T <raghavendra.kt@linux.vnet.ibm.com>
Newsgroups linux.kernel
Subject Re: [PATCH RFC 3/5] powerpc:numa create 1:1 mappaing between chipid and nid
Date 2015-09-29 21:30 +0200
Message-ID <qe8L7-7kd-11@gated-at.bofh.it> (permalink)
References <qdoRX-6G6-3@gated-at.bofh.it> <qdoRX-6G6-9@gated-at.bofh.it> <qdKz8-6dR-11@gated-at.bofh.it>
Organization IBM

Show all headers | View raw


On 09/28/2015 11:05 PM, Nishanth Aravamudan wrote:
> On 27.09.2015 [23:59:11 +0530], Raghavendra K T wrote:
>> Once we have made the distinction between nid and chipid
>> create a 1:1 mapping between them. This makes compacting the
>> nids easy later.
>>
>> No functionality change.
>>
>> Signed-off-by: Raghavendra K T <raghavendra.kt@linux.vnet.ibm.com>
>> ---
>>   arch/powerpc/mm/numa.c | 36 +++++++++++++++++++++++++++++-------
>>   1 file changed, 29 insertions(+), 7 deletions(-)
>>
>> diff --git a/arch/powerpc/mm/numa.c b/arch/powerpc/mm/numa.c
>> index f84ed2f..dd2073b 100644
>> --- a/arch/powerpc/mm/numa.c
>> +++ b/arch/powerpc/mm/numa.c
>> @@ -264,6 +264,17 @@ out:
>>   	return chipid;
>>   }
>>
>> +
>> + /* Return the nid from associativity */
>> +static int associativity_to_nid(const __be32 *associativity)
>> +{
>> +	int nid;
>> +
>> +	nid = associativity_to_chipid(associativity);
>> +	return nid;
>> +}
>
> This is ultimately confusing. You are assigning the semantic return
> value of a chipid to a nid -- is it a nid or a chipid? Shouldn't the
> variable naming be consistent?
>

:( yes. will come up with some consistent naming.

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Back to linux.kernel | Previous | NextPrevious in thread | Find similar | Unroll thread


Thread

[PATCH RFC  3/5] powerpc:numa create 1:1 mappaing between chipid and nid Raghavendra K T <raghavendra.kt@linux.vnet.ibm.com> - 2015-09-27 20:30 +0200
  Re: [PATCH RFC  3/5] powerpc:numa create 1:1 mappaing between chipid  and nid Nishanth Aravamudan <nacc@linux.vnet.ibm.com> - 2015-09-28 19:30 +0200
    Re: [PATCH RFC  3/5] powerpc:numa create 1:1 mappaing between chipid  and nid Raghavendra K T <raghavendra.kt@linux.vnet.ibm.com> - 2015-09-29 20:40 +0200
  Re: [PATCH RFC  3/5] powerpc:numa create 1:1 mappaing between chipid  and nid Nishanth Aravamudan <nacc@linux.vnet.ibm.com> - 2015-09-28 19:40 +0200
    Re: [PATCH RFC  3/5] powerpc:numa create 1:1 mappaing between chipid  and nid Raghavendra K T <raghavendra.kt@linux.vnet.ibm.com> - 2015-09-29 21:30 +0200

csiph-web