OSDN Git Service

bus: arm-cci: Fix use of smp_processor_id() in preemptible context
authorMarc Zyngier <marc.zyngier@arm.com>
Tue, 3 Oct 2017 17:14:13 +0000 (18:14 +0100)
committerPawel Moll <pawel.moll@arm.com>
Mon, 4 Dec 2017 16:56:43 +0000 (16:56 +0000)
commit4608af8aa53e7f3922ddee695d023b7bcd5cb35b
treecb83385efc4205ba08196961b4d9e35283d41974
parentb18c2b9487d8e797fc0a757e57ac3645348c5fba
bus: arm-cci: Fix use of smp_processor_id() in preemptible context

The ARM CCI driver seem to be using smp_processor_id() in a
preemptible context, which is likely to make a DEBUG_PREMPT
kernel scream at boot time.

Turn this into a get_cpu()/put_cpu() that extends over the CPU
hotplug registration, making sure that we don't race against
a CPU down operation.

Signed-off-by: Marc Zyngier <marc.zyngier@arm.com>
Acked-by: Mark Rutland <mark.rutland@arm.com>
Cc: stable@vger.kernel.org # 4.2+
Signed-off-by: Pawel Moll <pawel.moll@arm.com>
drivers/bus/arm-cci.c