diff options
author | José Pekkarinen <jose.pekkarinen@nokia.com> | 2016-04-11 10:41:07 +0300 |
---|---|---|
committer | José Pekkarinen <jose.pekkarinen@nokia.com> | 2016-04-13 08:17:18 +0300 |
commit | e09b41010ba33a20a87472ee821fa407a5b8da36 (patch) | |
tree | d10dc367189862e7ca5c592f033dc3726e1df4e3 /kernel/drivers/staging/fbtft/fb_ili9341.c | |
parent | f93b97fd65072de626c074dbe099a1fff05ce060 (diff) |
These changes are the raw update to linux-4.4.6-rt14. Kernel sources
are taken from kernel.org, and rt patch from the rt wiki download page.
During the rebasing, the following patch collided:
Force tick interrupt and get rid of softirq magic(I70131fb85).
Collisions have been removed because its logic was found on the
source already.
Change-Id: I7f57a4081d9deaa0d9ccfc41a6c8daccdee3b769
Signed-off-by: José Pekkarinen <jose.pekkarinen@nokia.com>
Diffstat (limited to 'kernel/drivers/staging/fbtft/fb_ili9341.c')
-rw-r--r-- | kernel/drivers/staging/fbtft/fb_ili9341.c | 20 |
1 files changed, 3 insertions, 17 deletions
diff --git a/kernel/drivers/staging/fbtft/fb_ili9341.c b/kernel/drivers/staging/fbtft/fb_ili9341.c index 709492e56..dcee0aff5 100644 --- a/kernel/drivers/staging/fbtft/fb_ili9341.c +++ b/kernel/drivers/staging/fbtft/fb_ili9341.c @@ -18,10 +18,6 @@ * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. */ #include <linux/module.h> @@ -38,11 +34,8 @@ #define DEFAULT_GAMMA "1F 1A 18 0A 0F 06 45 87 32 0A 07 02 07 05 00\n" \ "00 25 27 05 10 09 3A 78 4D 05 18 0D 38 3A 1F" - static int init_display(struct fbtft_par *par) { - fbtft_par_dbg(DEBUG_INIT_DISPLAY, par, "%s()\n", __func__); - par->fbtftops.reset(par); /* startup sequence for MI0283QT-9A */ @@ -82,9 +75,6 @@ static int init_display(struct fbtft_par *par) static void set_addr_win(struct fbtft_par *par, int xs, int ys, int xe, int ye) { - fbtft_par_dbg(DEBUG_SET_ADDR_WIN, par, - "%s(xs=%d, ys=%d, xe=%d, ye=%d)\n", __func__, xs, ys, xe, ye); - /* Column address set */ write_reg(par, 0x2A, (xs >> 8) & 0xFF, xs & 0xFF, (xe >> 8) & 0xFF, xe & 0xFF); @@ -105,15 +95,13 @@ static void set_addr_win(struct fbtft_par *par, int xs, int ys, int xe, int ye) #define MEM_BGR (3) /* RGB-BGR Order */ static int set_var(struct fbtft_par *par) { - fbtft_par_dbg(DEBUG_INIT_DISPLAY, par, "%s()\n", __func__); - switch (par->info->var.rotate) { case 0: write_reg(par, 0x36, (1 << MEM_X) | (par->bgr << MEM_BGR)); break; case 270: write_reg(par, 0x36, - (1<<MEM_V) | (1 << MEM_L) | (par->bgr << MEM_BGR)); + (1 << MEM_V) | (1 << MEM_L) | (par->bgr << MEM_BGR)); break; case 180: write_reg(par, 0x36, (1 << MEM_Y) | (par->bgr << MEM_BGR)); @@ -132,13 +120,11 @@ static int set_var(struct fbtft_par *par) Positive: Par1 Par2 [...] Par15 Negative: Par1 Par2 [...] Par15 */ -#define CURVE(num, idx) curves[num*par->gamma.num_values + idx] +#define CURVE(num, idx) curves[num * par->gamma.num_values + idx] static int set_gamma(struct fbtft_par *par, unsigned long *curves) { int i; - fbtft_par_dbg(DEBUG_INIT_DISPLAY, par, "%s()\n", __func__); - for (i = 0; i < par->gamma.num_curves; i++) write_reg(par, 0xE0 + i, CURVE(i, 0), CURVE(i, 1), CURVE(i, 2), @@ -151,7 +137,6 @@ static int set_gamma(struct fbtft_par *par, unsigned long *curves) } #undef CURVE - static struct fbtft_display display = { .regwidth = 8, .width = WIDTH, @@ -167,6 +152,7 @@ static struct fbtft_display display = { .set_gamma = set_gamma, }, }; + FBTFT_REGISTER_DRIVER(DRVNAME, "ilitek,ili9341", &display); MODULE_ALIAS("spi:" DRVNAME); |