All of lore.kernel.org
 help / color / mirror / Atom feed
From: Markos Chandras <Markos.Chandras@imgtec.com>
To: Joshua Kinard <kumba@gentoo.org>, Ralf Baechle <ralf@linux-mips.org>
Cc: Linux MIPS List <linux-mips@linux-mips.org>
Subject: Re: [PATCH v2] MIPS: Display CPU byteorder in /proc/cpuinfo
Date: Wed, 21 Jan 2015 11:34:05 +0000	[thread overview]
Message-ID: <54BF8EAD.6030403@imgtec.com> (raw)
In-Reply-To: <54BF8E2B.3010904@gentoo.org>

On 01/21/2015 11:31 AM, Joshua Kinard wrote:
> From: Joshua Kinard <kumba@gentoo.org>
> 
> This is a small patch to display the CPU byteorder that the kernel was compiled
> with in /proc/cpuinfo.
> 
> Signed-off-by: Joshua Kinard <kumba@gentoo.org>
> ---
>  arch/mips/kernel/proc.c |    4 ++++
>  1 file changed, 4 insertions(+)
> 
> This version of the patches replaces the #ifdefs with proper conditionals.
> 
> linux-mips-proc-cpuinfo-byteorder.patch
> diff --git a/arch/mips/kernel/proc.c b/arch/mips/kernel/proc.c
> index 097fc8d..22ef4c9 100644
> --- a/arch/mips/kernel/proc.c
> +++ b/arch/mips/kernel/proc.c
> @@ -65,6 +65,10 @@ static int show_cpuinfo(struct seq_file *m, void *v)
>  	seq_printf(m, "BogoMIPS\t\t: %u.%02u\n",
>  		      cpu_data[n].udelay_val / (500000/HZ),
>  		      (cpu_data[n].udelay_val / (5000/HZ)) % 100);
> +	if (config_enabled(CONFIG_CPU_BIG_ENDIAN))
> +		seq_printf(m, "byteorder\t\t: big endian\n");
> +	else
> +		seq_printf(m, "byteorder\t\t: little endian\n");
>  	seq_printf(m, "wait instruction\t: %s\n", cpu_wait ? "yes" : "no");
>  	seq_printf(m, "microsecond timers\t: %s\n",
>  		      cpu_has_counter ? "yes" : "no");
> 
> 
fwiw that looks ok to me

Reviewed-by: Markos Chandras <markos.chandras@imgtec.com>

-- 
markos

      reply	other threads:[~2015-01-21 11:34 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-01-21 11:31 [PATCH v2] MIPS: Display CPU byteorder in /proc/cpuinfo Joshua Kinard
2015-01-21 11:34 ` Markos Chandras [this message]

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=54BF8EAD.6030403@imgtec.com \
    --to=markos.chandras@imgtec.com \
    --cc=kumba@gentoo.org \
    --cc=linux-mips@linux-mips.org \
    --cc=ralf@linux-mips.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.