diff options
author | Russell King <rmk+kernel@arm.linux.org.uk> | 2012-01-16 09:31:47 +0000 |
---|---|---|
committer | Russell King <rmk+kernel@arm.linux.org.uk> | 2012-02-09 15:34:14 +0000 |
commit | 6ad1b614007c556129989b9f6b020d0d2e058121 (patch) | |
tree | d146b694cad7d3134b3166f56f401b203e073811 /drivers/pcmcia | |
parent | 710455201f6690841e9a40bedba09ddd0a7e0620 (diff) | |
download | lwn-6ad1b614007c556129989b9f6b020d0d2e058121.tar.gz lwn-6ad1b614007c556129989b9f6b020d0d2e058121.zip |
ARM: sa11x0: neponset: provide function to manipulate NCR_0
Rather than having direct register accesses to NCR_0 scattered amongst
the code, provide a function instead. This contains the necessary
race protection for this platform, ensuring that updates to this
register are safe.
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
Diffstat (limited to 'drivers/pcmcia')
-rw-r--r-- | drivers/pcmcia/sa1100_neponset.c | 7 |
1 files changed, 1 insertions, 6 deletions
diff --git a/drivers/pcmcia/sa1100_neponset.c b/drivers/pcmcia/sa1100_neponset.c index c95639b5f2a0..4300a7fb3edb 100644 --- a/drivers/pcmcia/sa1100_neponset.c +++ b/drivers/pcmcia/sa1100_neponset.c @@ -94,12 +94,7 @@ neponset_pcmcia_configure_socket(struct soc_pcmcia_socket *skt, const socket_sta ret = sa1111_pcmcia_configure_socket(skt, state); if (ret == 0) { - unsigned long flags; - - local_irq_save(flags); - NCR_0 = (NCR_0 & ~ncr_mask) | ncr_set; - - local_irq_restore(flags); + neponset_ncr_frob(ncr_mask, ncr_set); sa1111_set_io(s->dev, pa_dwr_mask, pa_dwr_set); } |