summaryrefslogtreecommitdiffstats
path: root/drivers/spi/spi-butterfly.c
Commit message (Collapse)AuthorAgeFilesLines
* spi: add flags parameter to txrx_word function pointersLorenzo Bianconi2018-08-011-2/+2
| | | | | | | | | | Add the capability to specify the flag parameter used in bitbang_txrx_be_cpha{0,1} through the txrx_word function pointers of spi_bitbang data structure. That feature will be used to add spi-3wire support to the spi-gpio controller Signed-off-by: Lorenzo Bianconi <lorenzo.bianconi@redhat.com> Signed-off-by: Mark Brown <broonie@kernel.org>
* spi: butterfly: use new parport device modelSudip Mukherjee2015-12-021-4/+6
| | | | | | | Modify spi-butterfly driver to use the new parallel port device model. Signed-off-by: Sudip Mukherjee <sudip@vectorindia.org> Signed-off-by: Mark Brown <broonie@kernel.org>
* spi: butterfly: correct alignmentSudip Mukherjee2015-12-021-6/+5Star
| | | | | | | checkpatch complains about the allignment with open parenthesis. Signed-off-by: Sudip Mukherjee <sudip@vectorindia.org> Signed-off-by: Mark Brown <broonie@kernel.org>
* spi: butterfly: remove cast to voidSudip Mukherjee2015-12-021-2/+2
| | | | | | | | checkpatch was complaining about space after cast. But the cast to void is not required at that place. Signed-off-by: Sudip Mukherjee <sudip@vectorindia.org> Signed-off-by: Mark Brown <broonie@kernel.org>
* spi: butterfly: remove multiple blank linesSudip Mukherjee2015-12-021-9/+0Star
| | | | | | | checkpatch complains about multiple blank lines. Signed-off-by: Sudip Mukherjee <sudip@vectorindia.org> Signed-off-by: Mark Brown <broonie@kernel.org>
* spi: Remove FSF mailing addressesJarkko Nikula2014-12-221-4/+0Star
| | | | | Signed-off-by: Jarkko Nikula <jarkko.nikula@linux.intel.com> Signed-off-by: Mark Brown <broonie@kernel.org>
* spi: bitbang: Make spi_bitbang_stop() return voidAxel Lin2014-03-291-2/+1Star
| | | | | | | spi_bitbang_stop() never fails, so make it return void. Signed-off-by: Axel Lin <axel.lin@ingics.com> Signed-off-by: Mark Brown <broonie@linaro.org>
* Merge remote-tracking branch 'spi/topic/butterfly' into spi-nextMark Brown2013-10-251-7/+6Star
|\
| * spi: butterfly: Fix checkpatch issueJingoo Han2013-10-151-7/+6Star
| | | | | | | | | | | | | | | | | | | | | | | | | | Fix the following checkpatch errors and warnings. ERROR: space required before the open brace '{' ERROR: space required after that close brace '}' ERROR: space required before the open parenthesis '(' ERROR: do not use C99 // comments WARNING: sizeof *pp should be sizeof(*pp) Signed-off-by: Jingoo Han <jg1.han@samsung.com> Signed-off-by: Mark Brown <broonie@linaro.org>
* | spi: bitbang: Let spi_bitbang_start() take a reference to masterAxel Lin2013-09-171-1/+1
|/ | | | | | | | | | | | | | | | | | | | | | | | | | | | Many drivers that use bitbang library have a leak on probe error paths. This is because once a spi_master_get() call succeeds, we need an additional spi_master_put() call to free the memory. Fix this issue by moving the code taking a reference to master to spi_bitbang_start(), so spi_bitbang_start() will take a reference to master on success. With this change, the caller is responsible for calling spi_bitbang_stop() to decrement the reference and spi_master_put() as counterpart of spi_alloc_master() to prevent a memory leak. So now we have below patten for drivers using bitbang library: probe: spi_alloc_master -> Init reference count to 1 spi_bitbang_start -> Increment reference count remove: spi_bitbang_stop -> Decrement reference count spi_master_put -> Decrement reference count (reference count reaches 0) Fixup all users accordingly. Signed-off-by: Axel Lin <axel.lin@ingics.com> Suggested-by: Uwe Kleine-Koenig <u.kleine-koenig@pengutronix.de> Acked-by: Uwe Kleine-Koenig <u.kleine-koenig@pengutronix.de> Signed-off-by: Mark Brown <broonie@linaro.org>
* spi: Add module.h to implicit users in drivers/spiPaul Gortmaker2011-11-011-0/+1
| | | | | | | | We are clipping down the presence of module.h, since it was everywhere. If you really need it, you better call it out, as per this changeset. Signed-off-by: Paul Gortmaker <paul.gortmaker@windriver.com>
* spi: reorganize driversGrant Likely2011-06-061-0/+356
Sort the SPI makefile and enforce the naming convention spi_*.c for spi drivers. This change also rolls the contents of atmel_spi.h into the .c file since there is only one user of that particular include file. v2: - Use 'spi-' prefix instead of 'spi_' to match what seems to be be the predominant pattern for subsystem prefixes. - Clean up filenames in Kconfig and header comment blocks Signed-off-by: Grant Likely <grant.likely@secretlab.ca> Acked-by: Wolfram Sang <w.sang@pengutronix.de> Acked-by: Linus Walleij <linus.walleij@linaro.org>