summaryrefslogtreecommitdiffstats
path: root/drivers/staging/rts5208/spi.c
Commit message (Collapse)AuthorAgeFilesLines
* staging: rts5208: Change fixed function names with "%s: ", __func__Gaurav Pathak2017-07-301-3/+5
| | | | | | | | staging: rts5208: Fix coding style issue caught by checkpatch.pl related to function name in debug print Signed-off-by: Gaurav Pathak <gauravpathak129@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* staging: rts5208: spi.c: Alignment fixesWayne Porter2016-10-161-65/+65
| | | | | | | Lining up code with open parantheses found by checkpatch Signed-off-by: Wayne Porter <wporter82@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* staging: rts5208: spi.c: Remove unnecessary parenthesisWayne Porter2016-10-161-7/+7
| | | | | | | Style warnings found by checkpatch Signed-off-by: Wayne Porter <wporter82@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* staging: rts5208: fix line style warnings in spi.cSergio Paracuellos2016-09-251-1/+2
| | | | | | | | This patch fixes the following checkpatch.pl warning in spi.c: WARNING: line over 80 characters Signed-off-by: Sergio Paracuellos <sergio.paracuellos@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* staging: rts5208: simplify NULL testsEva Rachel Retuya2016-03-121-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Replace direct comparisons to NULL i.e. 'x == NULL' with '!x' for consistency. Coccinelle semantic patch used: @@ identifier func; expression x; statement Z; @@ x = func(...); if ( ( + ! x - == NULL | + ! - NULL == x ) ) Z Signed-off-by: Eva Rachel Retuya <eraretuya@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* staging: rts5208: Removed blank linesAnjali Menon2016-02-081-2/+0Star
| | | | | | | | | | Removed multiple blank lines to avoid the check detected by checkpatch.pl. CHECK: Please don't use multiple blank lines Signed-off-by: Anjali Menon <cse.anjalimenon@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* staging: rts5208: Remove RTSX_READ_REG and RTSX_WRITE_REG macrosJoe Perches2015-03-261-20/+97
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Macros with hidden flow control are bad form as the code path taken can be unexpected for the reader. Expand these in-place and remove the macros. Done with coccinelle script: @@ expression chip; expression arg1; expression arg2; expression arg3; @@ - RTSX_WRITE_REG(chip, arg1, arg2, arg3); + retval = rtsx_write_register(chip, arg1, arg2, arg3); + if (retval) { + rtsx_trace(chip); + return retval; + } @@ expression chip; expression arg1; expression arg2; @@ - RTSX_READ_REG(chip, arg1, arg2); + retval = rtsx_read_register(chip, arg1, arg2); + if (retval) { + rtsx_trace(chip); + return retval; + } Signed-off-by: Joe Perches <joe@perches.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* staging: rts5208: Remove TRACE_RET and TRACE_GOTO macrosJoe Perches2015-03-261-87/+168
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Remove these flow hiding macros. Miscellanea: o Add a macro and function to replace a large inline o Simplify #includes o Add trace.c and update Makefile o Remove static inline filename function and use kbasename instead This reduces object size quite a lot: ~350KB (x86-64 allyesconfig) $ size drivers/staging/rts5208/built-in.o* text data bss dec hex filename 248385 36728 77888 363001 589f9 drivers/staging/rts5208/built-in.o.new 506691 83352 115896 705939 ac593 drivers/staging/rts5208/built-in.o.old Done via coccinelle script and some typing. @@ expression chip; expression ret; @@ - TRACE_RET(chip, ret); + rtsx_trace(chip); + return ret; @@ expression chip; identifier label; @@ - TRACE_GOTO(chip, label); + rtsx_trace(chip); + goto label; Signed-off-by: Joe Perches <joe@perches.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* Staging: rts5208: Replace custom macro with dev_dbgFabio Falzoi2014-07-311-3/+4
| | | | | | | Use dev_dbg macro to control tracing verbosity through dynamic debug facility. Signed-off-by: Fabio Falzoi <fabio.falzoi84@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* staging: rts5208: add support for rts5208 and rts5288Micky Ching2013-11-251-0/+877
There are still many rts5208/5288 card readers being used, but no drivers are supported them in kernel now. This driver can make a great convenience for people who use them. Many other rts-series card reader are supported by mfd driver, but due to much difference with others, rts5208/5288 can not add into mfd driver pretty now, so we provide a separated driver here to support the device. Signed-off-by: Micky Ching <micky_ching@realsil.com.cn> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>