24 Aug, 2017
1 commit
-
amba_id are not supposed to change at runtime. All functions
working with const amba_id. So mark the non-const structs as const.Signed-off-by: Arvind Yadav
Signed-off-by: Mark Brown
06 Apr, 2017
1 commit
-
The num-cs property is a required property according to the binding
documentation. However, if it is not present, the driver currently
simply uses random junk from the stack for the num-cs since the variable
whose pointer is passed to of_property_read_u32() is not initialized.Signed-off-by: Rabin Vincent
Signed-off-by: Mark Brown
17 Feb, 2016
1 commit
-
These structure members were removed in 2012 by the commit ffbbdd21329f
("spi: create a message queueing infrastructure").Signed-off-by: Jarkko Nikula
Signed-off-by: Mark Brown
23 Nov, 2015
1 commit
-
Handle EPROBE_DEFER explicitly so that we ensure that we get the DMA
channel specified in the device tree, instead of depending on the DMA
controller getting probed before us.Signed-off-by: Rabin Vincent
Signed-off-by: Mark Brown
12 Apr, 2015
1 commit
-
…pi/topic/pl022', 'spi/topic/pm' and 'spi/topic/pxa2xx' into spi-next
07 Mar, 2015
4 commits
-
Commit fd316941c ("spi/pl022: disable port when unused") introduced a race,
which leads to possible driver lock up (easily reproducible on SMP).The problem happens in giveback() function where the completion of the transfer
is signalled to SPI subsystem and then the HW SPI controller is disabled. Another
transfer might be setup in between, which brings driver in locked-up state.Exact event sequence on SMP:
core0 core1
=> pump_transfers()
/* message->state == STATE_DONE */
=> giveback()
=> spi_finalize_current_message()=> pl022_unprepare_transfer_hardware()
=> pl022_transfer_one_message
=> flush()
=> do_interrupt_dma_transfer()
=> set_up_next_transfer()
/* Enable SSP, turn on interrupts */
writew((readw(SSP_CR1(pl022->virtbase)) |
SSP_CR1_MASK_SSE), SSP_CR1(pl022->virtbase));...
=> pl022_interrupt_handler()
=> readwriter()/* disable the SPI/SSP operation */
=> writew((readw(SSP_CR1(pl022->virtbase)) &
(~SSP_CR1_MASK_SSE)), SSP_CR1(pl022->virtbase));Lockup! SPI controller is disabled and the data will never be received. Whole
SPI subsystem is waiting for transfer ACK and blocked.So, only signal transfer completion after disabling the controller.
Fixes: fd316941c (spi/pl022: disable port when unused)
Signed-off-by: Alexander Sverdlin
Signed-off-by: Mark Brown
Cc: stable@vger.kernel.org -
"flag" variable does nothing, remove it.
Signed-off-by: Alexander Sverdlin
Signed-off-by: Mark Brown -
PL022 Programmers model explicitely states "do not modify undefined register
bits". Correct the "all enable" interrupt mask so that it only enables defined
ones.Signed-off-by: Alexander Sverdlin
Signed-off-by: Mark Brown -
According to PL022 specification, TNF bit states for "Transmit FIFO Not full".
So the logic here is inverted. But "Receive Overrun Interrupt", which is handled
here, is only triggered on Rx errors. So instead of fixing the if statement,
remove the whole message.Signed-off-by: Alexander Sverdlin
Signed-off-by: Mark Brown
04 Dec, 2014
1 commit
-
The SET_PM_RUNTIME_PM_OPS() and SET_RUNTIME_PM_OPS() macros are
identical except that one of them is not empty for CONFIG_PM set,
while the other one is not empty for CONFIG_PM_RUNTIME set,
respectively.However, after commit b2b49ccbdd54 (PM: Kconfig: Set PM_RUNTIME if
PM_SLEEP is selected) PM_RUNTIME is always set if PM is set, so one
of these macros is now redundant.For this reason, replace SET_PM_RUNTIME_PM_OPS() with
SET_RUNTIME_PM_OPS() everywhere and redefine the SET_PM_RUNTIME_PM_OPS
symbol as SET_RUNTIME_PM_OPS in case new code is starting to use the
macro being removed here.Reviewed-by: Ulf Hansson
Acked-by: Kevin Hilman
Signed-off-by: Rafael J. Wysocki
13 Oct, 2014
1 commit
-
When mapped RX DMA entries are unmapped in an error condition when DMA
is firstly configured in the driver, the number of TX DMA entries was
passed in, which is incorrectSigned-off-by: Ray Jui
Signed-off-by: Mark Brown
Cc: stable@vger.kernel.org
03 Oct, 2014
1 commit
-
…/rspi', 'spi/topic/sh-msiof' and 'spi/topic/sirf' into spi-next
24 Sep, 2014
1 commit
-
Add support for a extended PL022 which has an extra register for controlling up
to five chip select signals. This controller is found on the AXM5516 SoC.
Unfortunately the PrimeCell identification registers are identical to a
standard ARM PL022. To work around this, the peripheral ID must be overridden
in the device tree using the "arm,primecell-periphid" property with the value
0x000b6022.Signed-off-by: Anders Berg
Acked-by: Linus Walleij
Acked-by: Russell King
Signed-off-by: Mark Brown
19 Sep, 2014
1 commit
-
Currently this driver is missing a check on the return value of devm_kzalloc,
which would cause a NULL pointer dereference in a OOM situation.This patch adds a missing check.
Signed-off-by: Kiran Padwal
Signed-off-by: Mark Brown
09 Sep, 2014
1 commit
-
This patch fixes an error message typo ("not" missing).
Signed-off-by: Roland Stigge
Signed-off-by: Mark Brown
02 Aug, 2014
1 commit
-
When building on 64 bit architectures the use of bitwise negation generates
constants larger than 32 bits which won't fit in u32s used to represent
32 bit register values on the device. Explicitly cast to let the compiler
know that the higher bits are not significant and can be discarded.Signed-off-by: Mark Brown
30 Apr, 2014
1 commit
-
The site-specific OOM messages are unnecessary, because they
duplicate the MM subsystem generic OOM message.Signed-off-by: Jingoo Han
Signed-off-by: Mark Brown
30 Mar, 2014
1 commit
-
…i/topic/omap2', 'spi/topic/orion', 'spi/topic/pl022', 'spi/topic/qup', 'spi/topic/rspi' and 'spi/topic/s3c24xx' into spi-next
06 Mar, 2014
2 commits
-
Previously only the resources controlled by the driver were put into
low power state at system suspend. Both the amba bus and a potential
power domain were ignored.Moreover, while putting the device into low power state we first
brought it back to full power, but for no particular reason.To handle both issues above, use pm_runtime_force_suspend|resume() from
the system suspend|resume callbacks.Signed-off-by: Ulf Hansson
Signed-off-by: Mark Brown -
Convert to the SET_PM_RUNTIME_PM macro while defining the runtime PM
callbacks. This means the callbacks becomes available for both
CONFIG_PM_SLEEP and CONFIG_PM_RUNTIME, which is needed to handle the
combinations of these scenarios.Signed-off-by: Ulf Hansson
Signed-off-by: Mark Brown
23 Feb, 2014
1 commit
-
Signed-off-by: Axel Lin
Signed-off-by: Mark Brown
05 Feb, 2014
2 commits
-
The driver core is now taking care of putting our pins into default
state at probe. Thus we can remove the redundant call for it in probe.Signed-off-by: Ulf Hansson
Signed-off-by: Mark Brown -
Make use of clk_prepare_enable and clk_disable_unprepare to simplify
code. No functional change.Signed-off-by: Ulf Hansson
Signed-off-by: Mark Brown
03 Feb, 2014
1 commit
-
When the driver was converted to clk_prepare() the suspend path didn't
have any changes made so the clock remains prepared throughout the runtime
of the driver. Unprepare it when suspended so that any savings that can be
made as a result are made.Signed-off-by: Mark Brown
Acked-by: Linus Walleij
25 Oct, 2013
1 commit
15 Oct, 2013
1 commit
-
Change raw printk() call to dev_info() to provide a better message
to userspace so it can properly identify the device.Signed-off-by: Jingoo Han
Acked-by: Linus Walleij
Signed-off-by: Mark Brown
26 Sep, 2013
1 commit
-
Use devm_spi_register_master() to make cleanup paths simpler.
Signed-off-by: Jingoo Han
Acked-by: Linus Walleij
Signed-off-by: Mark Brown
17 Sep, 2013
2 commits
-
The driver core clears the driver data to NULL after device_release
or on probe failure. Thus, it is not needed to manually clear the
device driver data to NULL.Signed-off-by: Jingoo Han
Signed-off-by: Mark Brown -
'break' immediately after return has no effect.
Signed-off-by: Sachin Kamat
Acked-by: Linus Walleij
Signed-off-by: Mark Brown
01 Sep, 2013
2 commits
29 Aug, 2013
1 commit
-
Use the wrapper function for retrieving the platform data instead of
accessing dev->platform_data directly.Signed-off-by: Jingoo Han
Signed-off-by: Mark Brown
22 Aug, 2013
1 commit
-
When CONFIG_ARM_LPAE=y the following build warning is generated:
drivers/spi/spi-pl022.c:2178:9: warning: format '%x' expects argument of type 'unsigned int', but argument 2 has type 'resource_size_t' [-Wformat]
According to Documentation/printk-formats.txt '%pa' can be used to properly
print 'resource_size_t'.Reported-by: Kevin Hilman
Signed-off-by: Fabio Estevam
Signed-off-by: Mark Brown
30 Jul, 2013
1 commit
-
Signed-off-by: Mark Brown
Reviewed-by: Linus Walleij
04 Jul, 2013
1 commit
-
…/linusw/linux-pinctrl
Pull pin control changes from Linus Walleij:
- A large slew of improvements of the Genric pin configuration support,
and deployment in four different platforms: Rockchip, Super-H PFC,
ABx500 and TZ1090. Support BIAS_BUS_HOLD, get device tree parsing
and debugfs support into shape.- We also have device tree support with generic naming conventions for
the generic pin configuration.- Delete the unused and confusing direct pinconf API. Now state
transitions is *the* way to control pins and multiplexing.- New drivers for Rockchip, TZ1090, and TZ1090 PDC.
- Two pin control states related to power management are now handled in
the device core: "sleep" and "idle", removing a lot of boilerplate
code in drivers. We do not yet know if this is the final word for
pin PM, but it already make things a lot easier to handle.- Handle sparse GPIO ranges passing a list of disparate pins, and
utilize these in the new BayTrail (x86 Atom SoC) driver.- Make the sunxi (AllWinner) driver handle external interrupts.
- Make it possible for pinctrl-single to handle the case where several
pins are managed by a single register, and augment it to handle sleep
modes.- Cleanups and improvements for the abx500 drivers.
- Move Sirf pin control drivers to their own directory, support
save/restore of context and add support for the SiRFatlas6 SoC.- PMU muxing for the Dove pinctrl driver.
- Finalization and support for VF610 in the i.MX6 pinctrl driver.
- Smoothen out various Exynos rough edges.
- Generic cleanups of various kinds.
* tag 'pinctrl-for-v3.11-1' of git://git.kernel.org/pub/scm/linux/kernel/git/linusw/linux-pinctrl: (82 commits)
pinctrl: vt8500: wmt: remove redundant dev_err call in wmt_pinctrl_probe()
pinctrl: remove bindings for pinconf options needing more thought
pinctrl: remove slew-rate parameter from tz1090
pinctrl: set unit for debounce time pinconfig to usec
pinctrl: more clarifications for generic pull configs
pinctrl: rip out the direct pinconf API
pinctrl-tz1090-pdc: add TZ1090 PDC pinctrl driver
pinctrl-tz1090: add TZ1090 pinctrl driver
pinctrl: samsung: Staticize drvdata_list
pinctrl: rockchip: Add missing irq_gc_unlock() call before return error
pinctrl: abx500: rework error path
pinctrl: abx500: suppress hardcoded value
pinctrl: abx500: factorize code
pinctrl: abx500: fix abx500_gpio_get()
pinctrl: abx500: fix abx500_pin_config_set()
pinctrl: abx500: Add device tree support
sh-pfc: Guard DT parsing with #ifdef CONFIG_OF
pinctrl: add Intel BayTrail GPIO/pinctrl support
pinctrl: fix pinconf_ops::pin_config_dbg_parse_modify kerneldoc
pinctrl: Staticize local symbols
...Conflicts:
drivers/net/ethernet/ti/davinci_mdio.c
drivers/pinctrl/Makefile
18 Jun, 2013
1 commit
-
Removes the warnings:
drivers/spi/spi-pl022.c: In function 'pl022_suspend_resources':
drivers/spi/spi-pl022.c:2322:24: warning: unused variable 'pins_state' [-Wunused-variable]
drivers/spi/spi-pl022.c:2321:6: warning: unused variable 'ret' [-Wunused-variable]
drivers/spi/spi-pl022.c: In function 'pl022_resume_resources':
drivers/spi/spi-pl022.c:2334:6: warning: unused variable 'ret' [-Wunused-variable]introduced in:
f1c9cf0 spi: pl022: use pinctrl PM helpers
Signed-off-by: Fabio Baltieri
Acked-by: Mark Brown
Signed-off-by: Linus Walleij
17 Jun, 2013
1 commit
-
In the past we controlled the selection of DMA for a certain
host by a boolean switch in the platform data. Currently
there is no way to enable DMA on a PL022 probed from the
device tree. Let's default to trying to obtain DMA channels
in the DT case, and then we can always fail (and thus fall
back to PIO mode).Signed-off-by: Linus Walleij
16 Jun, 2013
1 commit
-
This utilize the new pinctrl core PM helpers to transition
the driver to "sleep" and "idle" states, cutting away some
boilerplate code.Cc: Hebbar Gururaja
Cc: Dmitry Torokhov
Cc: Kevin Hilman
Cc: Greg Kroah-Hartman
Cc: Stephen Warren
Cc: Wolfram Sang
Acked-by: Mark Brown
Signed-off-by: Linus Walleij
13 Mar, 2013
1 commit
-
With the new OF DMA binding, it is possible to completely avoid the
need for platform_data for configuring a DMA channel. In cases where the
platform has already been converted, calling dma_request_slave_channel
should get all the necessary information from the device tree.Like the patch that converts the dw_dma controller, this is completely
untested and is looking for someone to try it out.Signed-off-by: Arnd Bergmann
Acked-by: Grant Likely
Acked-by: Mark Brown
Acked-by: Linus Walleij
Cc: spi-devel-general@lists.sourceforge.net
Cc: Viresh Kumar
Cc: Andy Shevchenko
Cc: Vinod Koul
Cc: devicetree-discuss@lists.ozlabs.org
Cc: linux-arm-kernel@lists.infradead.org
08 Dec, 2012
1 commit
-
CONFIG_HOTPLUG is going away as an option. As result the __dev*
markings will be going away.Remove use of __devinit, __devexit_p, __devinitdata, __devinitconst,
and __devexit.Bill Pemberton has done most of the legwork on this series. I've used
his script to purge the attributes from the drivers/gpio tree.Reported-by: Bill Pemberton
Signed-off-by: Grant Likely