aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/staging/fbtft/fb_agm1264k-fl.c (follow)
AgeCommit message (Collapse)AuthorFilesLines
2019-04-02staging: fbtft: fb_agm1264k-fl.c: Replace bit shifting with BIT macroPayal Kshirsagar1-1/+1
Challenge suggested by coccinelle. Prefer using BIT and replace bit shifting with the BIT(x) macro. Signed-off-by: Payal Kshirsagar <payal.s.kshirsagar.98@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-03-18staging: fbtft: fixed format-string errors.Jeremy Sowden1-1/+1
Added __printf attribute to declaration of fbtft_dbg_hex and fixed mismatches between format-specifiers and arguments in several function calls. Signed-off-by: Jeremy Sowden <jeremy@azazel.net> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-01-18Staging: fbtft: Switch to the gpio descriptor interfaceNishad Kamdar1-26/+26
This switches the fbtft driver to use GPIO descriptors rather than numerical gpios: Utilize the GPIO library's intrinsic handling of OF GPIOs and polarity. If the line is flagged active low, gpiolib will deal with this. Remove gpios from platform device structure. Neither assign statically numbers to gpios in platform device nor allow gpios to be parsed as module parameters. Signed-off-by: Nishad Kamdar <nishadkamdar@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2018-01-15staging: fbtft: remove redundant license textGreg Kroah-Hartman1-10/+0
Now that the SPDX tag is in all fbtft files, that identifies the license in a specific and legally-defined manner. So the extra GPL text wording can be removed as it is no longer needed at all. This is done on a quest to remove the 700+ different ways that files in the kernel describe the GPL license text. And there's unneeded stuff like the address (sometimes incorrect) for the FSF which is never needed. No copyright headers or other non-license-description text was removed. Cc: Thomas Petazzoni <thomas.petazzoni@free-electrons.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2018-01-15staging: fbtft: add SPDX identifiersGreg Kroah-Hartman1-0/+1
It's good to have SPDX identifiers in all files to make it easier to audit the kernel tree for correct licenses. Fix up the all of the staging fbtft drivers to have a proper SPDX identifier, based on the license text in the file itself. The SPDX identifier is a legally binding shorthand, which can be used instead of the full boiler plate text. This work is based on a script and data from Thomas Gleixner, Philippe Ombredanne, and Kate Stewart. Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Kate Stewart <kstewart@linuxfoundation.org> Cc: Philippe Ombredanne <pombredanne@nexb.com> Cc: Thomas Petazzoni <thomas.petazzoni@free-electrons.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2017-05-15Staging: fbtft: Fix unbalanced braces around else statementLaurence Rochfort1-2/+2
Balance if/else braces as recommended by checkpatch.pl Signed-off-by: Laurence Rochfort <laurence.rochfort@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2017-03-23staging: fbtft: Replace a bit shift by a use of BIT.Arushi Singhal1-1/+1
This patch replaces bit shifting on 1 with the BIT(x) macro. This was done with coccinelle: @@ constant c; @@ -1 << c +BIT(c) Signed-off-by: Arushi Singhal <arushisinghal19971997@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2017-01-03staging: fbtft: fix code alignment with open parenthesisScott Matheina1-8/+10
These changes where identified by checkpatch.pl as needed changes to align the code with the linux development coding style. The several lines of text where aligned with the precending parenthesis. Signed-off-by: Scott Matheina <scott@matheina.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2016-10-16Staging: fbtft: Fix too many leading tabs warningGustavo A. R. Silva1-31/+37
This is a patch to the fb_agm1264k-fl.c file that fixes up the following issue: WARNING: Too many leading tabs - consider code refactoring Add new function iterate_diffusion_matrix() to refactor a piece of code inside write_vmem(). Signed-off-by: Gustavo A. R. Silva <garsilva@embeddedor.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2016-08-21staging: fbtft: This patch fixes the checkpatch.pl warningPrit Raj1-2/+2
WARNING: Statements should start on a tabstop Signed-off-by: Prit Raj <prit.adra@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2016-03-28Staging: fbtft: fb_agm1264k-fl: No space is necessary after cast.Sandhya Bankar1-1/+1
No space is necessary after cast.This problem is found by checkpatch.pl script. Signed-off-by: Sandhya Bankar <bankarsandhya512@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2016-03-11staging: fbtft: Use kmalloc_arrayBhaktipriya Shridhar1-2/+2
Use kmalloc_array instead of kmalloc for arrays to prevent integer overflows. This was done using Coccinelle: @@ expression e1, e2; constant C; type t; @@ ( - kmalloc( + kmalloc_array( e2 - * + , sizeof(e1), C) | - kmalloc( + kmalloc_array( e1 - * + , sizeof(t), C) | - kmalloc( + kmalloc_array( - sizeof(e1) - * e2 + , + sizeof(e1) , C) | - kmalloc( + kmalloc_array( - sizeof(t) - * e1 + , + sizeof(t) , C) ) Signed-off-by: Bhaktipriya Shridhar <bhaktipriya96@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-10-16Staging: fbtft: fb_agm1264k-fl: Remove unnecessary castShivani Bhardwaj1-1/+1
Remove explicit typecast from variables as compiler can typecast implicitly. Semantic patch used: @@ type T; T e; identifier x; @@ * T x = (T)e; Signed-off-by: Shivani Bhardwaj <shivanib134@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-10-13staging: fbtft: use alternate screen pointerLars Svensson1-1/+1
Member screen_base in struct fb_info is declared with __iomem qualifier causing sparse warnings when used as a regular ponter. To avoid the warnings, instead use alternate non-__iomem pointer, screen_buffer, troughout the driver. Signed-off-by: Lars Svensson <lars1.svensson@sonymobile.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-10-02Staging: fbtft: Remove debug messages related to DEBUG_WRITE_VMEMShraddha Barke1-2/+0
Remove debug messages related to fbtft_par_dbg(DEBUG_WRITE_VMEM.. ) as this info can be obtained using kernel function tracer Signed-off-by: Shraddha Barke <shraddha.6596@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-09-21Staging: fbtft: Remove debug messagesShraddha Barke1-2/+0
Remove debug messages related to fbtft_par_dbg(DEBUG_INIT_DISPLAY.. ) as this info can be obtained using kernel function tracer Signed-off-by: Shraddha Barke <shraddha.6596@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-09-12staging/fbtft : Fix multiple/missing blank line issuesAnish Bhatt1-2/+1
Remove or add blank lines as recommended by checkpatch.pl Signed-off-by: Anish Bhatt <anish@chelsio.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-09-12staging/fbtft : Remove unicode charactersAnish Bhatt1-1/+1
Remove stray unicode quotes around name Signed-off-by: Anish Bhatt <anish@chelsio.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-09-12staging/fbtft : Remove repeated set_addr_win debug messagesAnish Bhatt1-4/+0
fbtft_par_dbg(DEBUG_SET_ADDR_WIN.. ) is repeated in every set_addr_win() handler, this could be replicated by using the kernel function tracer instead. Signed-off-by: Anish Bhatt <anish@chelsio.com> Suggested-by: Greg KH <gregkh@linuxfoundation.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-06-08staging: fbtft: replace fbtft_dev_dbg with standard dev_dbg callMadhusudhanan Ravindran1-3/+3
This patch attempts to simplify the debugging using standard dev_dbg call so that individual debug prints can be enabled or disbled by dynamic debugging rather than using module params. Signed-off-by: Madhusudhanan Ravindran <mravindr@visteon.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-03-26staging: fbtft: Fix typo in fbtftMasanari Iida1-3/+3
This patch fix spelling typo in comment and printk within fbtft Signed-off-by: Masanari Iida <standby24x7@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-03-20staging: fbtft: Fix potential null dereferenceRavindran, Madhusudhanan (M.)1-0/+3
This error is found by smatch tool. Signed-off-by: Madhusudhanan Ravindran <mravindr@visteon.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-03-15staging: fbtft: fb_agm1264k-fl.c: remove extra parentheses around function argumentsAya Mahfouz1-1/+1
Removes extra parentheses around function arguments. Issue detected and resolved using the following coccinelle script: @@ expression e; identifier f; @@ f(..., -( e -) ,...) Signed-off-by: Aya Mahfouz <mahfouz.saif.elyazal@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-03-06Staging: fbtft: clean dev_err() loggingHaneen Mohammed1-8/+8
This patch removes __func__ from dev_err. dev_err includes information about: (devcice, driver, specific instance of device, etc) in the log printout. This was done using Coccinelle, with the following semantic patch: @a@ expression E, R; expression msg; @@ dev_err(E, msg, __func__, R); @script:python b@ e << a.msg; y; @@ if(e.find("%s: ") == True): m = e.replace("%s: ", "", 1); coccinelle.y = m; elif(e.find("%s ") == True): m = e.replace("%s ", "", 1); coccinelle.y = m; elif(e.find("%s:") == True): m = e.replace("%s:", "", 1); coccinelle.y = m; else: m = e.replace("%s", "",1); coccinelle.y = m; @c@ expression a.E, a.msg, a.R; identifier b.y; @@ - dev_err(E, msg, __func__, R); + dev_err(E, y, R); Signed-off-by: Haneen Mohammed <hamohammed.sa@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-01-25staging: fbtft: fix allyesconfig buildDan Carpenter1-1/+1
There are two functions call reset() so the allyesconfig breaks. Let's make this one static. Reported-by: Jim Davis <jim.epost@gmail.com> Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Tested-by: Jim Davis <jim.epost@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-01-17staging: fbtft: add fb_agm1264k-fl driverThomas Petazzoni1-0/+462
This commit adds the fb_agm1264k-fl driver from the fbtft project at https://github.com/notro/fbtft. Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com> Signed-off-by: Noralf Tronnes <notro@tronnes.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>