mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Russell King - ARM Linux <linux@arm.linux.org.uk>
To: Fan Rong <cinifr@gmail.com>
Cc: coosty@163.com, maxime.ripard@free-electrons.com,
	daniel.lezcano@linaro.org, tglx@linutronix.de,
	linux-arm-kernel@lists.infradead.org,
	linux-kernel@vger.kernel.org, mark.rutland@arm.com,
	pawel.moll@arm.co, rob.herring@calxeda.com,
	linux-sunxi@googlegroups.com
Subject: Re: [PATCH 1/4] Add smp support for Allwinner A20(sunxi 7i).
Date: Thu, 12 Sep 2013 15:40:08 +0100	[thread overview]
Message-ID: <20130912144008.GM12758@n2100.arm.linux.org.uk> (raw)
In-Reply-To: <1378968687-8200-2-git-send-email-cinifr@gmail.com>

Some other comments:

On Thu, Sep 12, 2013 at 02:51:24PM +0800, Fan Rong wrote:
> +    /* L1RSTDISABLE hold low */
> +	pwr_reg = readl(cc_base + AW_CPUCFG_GENCTL);
> +	pwr_reg &= ~(1<<cpu);

If you pass your patch through checkpatch.pl, it will warn about some of
this.  You should have one space each side of <<.

> +    /* step3: clear power-off gating */
> +	pwr_reg = readl(cc_base + AW_CPU1_PWROFF_REG);
> +	pwr_reg &= ~(1);

You don't need the parens here.

> +	pwr_reg = readl(cc_base + AW_CPUCFG_DBGCTL1);
> +	pwr_reg |= (1<<cpu);

Nor here.

> +static int sunxi7i_boot_secondary(unsigned int cpu, struct task_struct *idle)
> +{
> +	pr_debug("[%s] enter cpu %d\n", __func__, cpu);
> +	spin_lock(&boot_lock);
> +	enable_aw_cpu(cpu);
> +	spin_unlock(&boot_lock);

What exactly does this spinlock protect?  The core code already provides
the guarantee that only one CPU will be brought online or taken offline
at a time.

  parent reply	other threads:[~2013-09-12 14:41 UTC|newest]

Thread overview: 31+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-09-12  6:51 [PATCH 0/4] Add smp support for Allwinner A20 and phy arch count timer Fan Rong
2013-09-12  6:51 ` [PATCH 1/4] Add smp support for Allwinner A20(sunxi 7i) Fan Rong
2013-09-12 14:26   ` Mark Rutland
2013-09-12 15:53     ` cinifr
2013-09-12 14:40   ` Russell King - ARM Linux [this message]
2013-09-12  6:51 ` [PATCH 2/4] Add cpuconfig nodes in dts for smp configure Fan Rong
2013-09-14 11:50   ` Maxime Ripard
2013-09-12  6:51 ` [PATCH 3/4] Add physical count arch timer support for clocksource in ARMv7 Fan Rong
2013-09-12 11:24   ` Mark Rutland
2013-09-12 14:33     ` Russell King - ARM Linux
2013-09-12 16:09       ` cinifr
2013-09-12 15:39     ` [linux-sunxi] " Ian Campbell
2013-09-12 16:07     ` cinifr
2013-09-12 16:39       ` Marc Zyngier
2013-09-13  8:49         ` cinifr
2013-09-13  9:30           ` Marc Zyngier
2013-09-13 13:09             ` cinifr
2013-09-13 13:40               ` Marc Zyngier
2013-09-13 14:55                 ` cinifr
2013-09-18  9:03                 ` cinifr
2013-09-14 12:05             ` maxime.ripard
2013-09-16  8:16               ` Marc Zyngier
2013-09-12  6:51 ` [PATCH 4/4] Add arch count timer node in dts for Allwinner A20(sunxi 7i) Fan Rong
2013-09-12 14:57   ` Mark Rutland
2013-09-12 15:44     ` [linux-sunxi] " Ian Campbell
2013-09-12 16:23       ` cinifr
2013-09-12 19:53         ` Henrik Nordström
2013-09-12 14:39 ` [PATCH 0/4] Add smp support for Allwinner A20 and phy arch count timer Mark Rutland
2013-09-12 15:46   ` cinifr
2013-09-13 11:20     ` Mark Rutland
2013-09-13 13:23       ` cinifr

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=20130912144008.GM12758@n2100.arm.linux.org.uk \
    --to=linux@arm.linux.org.uk \
    --cc=cinifr@gmail.com \
    --cc=coosty@163.com \
    --cc=daniel.lezcano@linaro.org \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-sunxi@googlegroups.com \
    --cc=mark.rutland@arm.com \
    --cc=maxime.ripard@free-electrons.com \
    --cc=pawel.moll@arm.co \
    --cc=rob.herring@calxeda.com \
    --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®