Skip to content

Commit bea8d77

Browse files
committed
Merge tag 'staging-7.1-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/staging
Pull staging driver updates from Greg KH: "Here is the "big" set of staging driver changes for 7.1-rc1. Nothing major in here at all, just lots of little cleanups for the staging drivers, driven by new developers getting their feet wet in kernel development. "Largest" thing in here is the change of some of the octeon variable types into proper kernel ones. Full details are in the shortlog. All of these have been in linux-next for a while with no reported issues" * tag 'staging-7.1-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/staging: (154 commits) staging: rtl8723bs: remove redundant & parentheses staging: most: dim2: replace BUG_ON() in poison_channel() staging: most: dim2: replace BUG_ON() in enqueue() staging: most: dim2: replace BUG_ON() in configure_channel() staging: most: dim2: replace BUG_ON() in service_done_flag() staging: most: dim2: replace BUG_ON() in try_start_dim_transfer() staging: rtl8723bs: remove unused RTL8188E antenna selection macros staging: rtl8723bs: remove redundant blank lines in basic_types.h staging: rtl8723bs: wrap complex macros with parentheses staging: rtl8723bs: remove unused WRITEEF/READEF byte macros staging: rtl8723bs: rename camelCase variable staging: greybus: audio: fix error message for BTN_3 button staging: rtl8723bs: rename variables to snake_case staging: rtl8723bs: fix spelling in comment staging: rtl8723bs: cleanup return in sdio_init() staging: rtl8723bs: use direct returns in sdio_dvobj_init() staging: rtl8723bs: remove unused arg at odm_interface.h greybus: raw: fix use-after-free if write is called after disconnect greybus: raw: fix use-after-free on cdev close staging: rtl8723bs: fix logical continuations in xmit_linux.c ...
2 parents 99ef60d + bf9c95f commit bea8d77

91 files changed

Lines changed: 1719 additions & 2251 deletions

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

drivers/staging/axis-fifo/axis-fifo.c

Lines changed: 19 additions & 40 deletions
Original file line numberDiff line numberDiff line change
@@ -71,8 +71,8 @@ struct axis_fifo {
7171

7272
unsigned int rx_fifo_depth;
7373
unsigned int tx_fifo_depth;
74-
int has_rx_fifo;
75-
int has_tx_fifo;
74+
u32 has_rx_fifo;
75+
u32 has_tx_fifo;
7676

7777
wait_queue_head_t read_queue;
7878
struct mutex read_lock; /* lock for reading */
@@ -392,60 +392,39 @@ static int axis_fifo_parse_dt(struct axis_fifo *fifo)
392392

393393
ret = of_property_read_u32(node, "xlnx,axi-str-rxd-tdata-width",
394394
&value);
395-
if (ret) {
396-
dev_err(fifo->dt_device, "missing xlnx,axi-str-rxd-tdata-width property\n");
397-
goto end;
398-
} else if (value != 32) {
399-
dev_err(fifo->dt_device, "xlnx,axi-str-rxd-tdata-width only supports 32 bits\n");
400-
ret = -EIO;
401-
goto end;
402-
}
395+
if (ret)
396+
return ret;
397+
if (value != 32)
398+
return -EINVAL;
403399

404400
ret = of_property_read_u32(node, "xlnx,axi-str-txd-tdata-width",
405401
&value);
406-
if (ret) {
407-
dev_err(fifo->dt_device, "missing xlnx,axi-str-txd-tdata-width property\n");
408-
goto end;
409-
} else if (value != 32) {
410-
dev_err(fifo->dt_device, "xlnx,axi-str-txd-tdata-width only supports 32 bits\n");
411-
ret = -EIO;
412-
goto end;
413-
}
402+
if (ret)
403+
return ret;
404+
if (value != 32)
405+
return -EINVAL;
414406

415407
ret = of_property_read_u32(node, "xlnx,rx-fifo-depth",
416408
&fifo->rx_fifo_depth);
417-
if (ret) {
418-
dev_err(fifo->dt_device, "missing xlnx,rx-fifo-depth property\n");
419-
ret = -EIO;
420-
goto end;
421-
}
409+
if (ret)
410+
return ret;
422411

423412
ret = of_property_read_u32(node, "xlnx,tx-fifo-depth",
424413
&fifo->tx_fifo_depth);
425-
if (ret) {
426-
dev_err(fifo->dt_device, "missing xlnx,tx-fifo-depth property\n");
427-
ret = -EIO;
428-
goto end;
429-
}
414+
if (ret)
415+
return ret;
430416

431417
ret = of_property_read_u32(node, "xlnx,use-rx-data",
432418
&fifo->has_rx_fifo);
433-
if (ret) {
434-
dev_err(fifo->dt_device, "missing xlnx,use-rx-data property\n");
435-
ret = -EIO;
436-
goto end;
437-
}
419+
if (ret)
420+
return ret;
438421

439422
ret = of_property_read_u32(node, "xlnx,use-tx-data",
440423
&fifo->has_tx_fifo);
441-
if (ret) {
442-
dev_err(fifo->dt_device, "missing xlnx,use-tx-data property\n");
443-
ret = -EIO;
444-
goto end;
445-
}
424+
if (ret)
425+
return ret;
446426

447-
end:
448-
return ret;
427+
return 0;
449428
}
450429

451430
static int axis_fifo_probe(struct platform_device *pdev)

drivers/staging/fbtft/Kconfig

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -86,7 +86,11 @@ config FB_TFT_PCD8544
8686
config FB_TFT_RA8875
8787
tristate "FB driver for the RA8875 LCD Controller"
8888
help
89-
Generic Framebuffer support for RA8875
89+
This enables generic framebuffer support for the RAiO RA8875
90+
display controller. The controller is intended for medium size text/graphic
91+
mixed displays with a resolution of up to 800x480 pixels.
92+
93+
Say Y if you have such a display that utilizes this controller.
9094

9195
config FB_TFT_S6D02A1
9296
tristate "FB driver for the S6D02A1 LCD Controller"

drivers/staging/fbtft/README

Lines changed: 7 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -6,27 +6,12 @@ The module 'fbtft' makes writing drivers for some of these displays very easy.
66

77
Development is done on a Raspberry Pi running the Raspbian "wheezy" distribution.
88

9-
INSTALLATION
10-
Download kernel sources
9+
For new hardware support consider using DRM subsystem (see TODO).
1110

12-
From Linux 3.15
13-
cd drivers/video/fbdev/fbtft
14-
git clone https://github.com/notro/fbtft.git
11+
NOTE:
1512

16-
Add to drivers/video/fbdev/Kconfig: source "drivers/video/fbdev/fbtft/Kconfig"
17-
Add to drivers/video/fbdev/Makefile: obj-y += fbtft/
18-
19-
Before Linux 3.15
20-
cd drivers/video
21-
git clone https://github.com/notro/fbtft.git
22-
23-
Add to drivers/video/Kconfig: source "drivers/video/fbtft/Kconfig"
24-
Add to drivers/video/Makefile: obj-y += fbtft/
25-
26-
Enable driver(s) in menuconfig and build the kernel
27-
28-
29-
See wiki for more information: https://github.com/notro/fbtft/wiki
30-
31-
32-
Source: https://github.com/notro/fbtft/
13+
The driver is in maintenance mode, only performance issue or bug fixes
14+
are accepted, which effectively means the patches must be tested on
15+
the real hardware (the patch must be accompanied with the information
16+
what hardware is that). The treewide changes may also be accepted as
17+
an exception.

drivers/staging/fbtft/fb_agm1264k-fl.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -376,7 +376,7 @@ static int write_vmem(struct fbtft_par *par, size_t offset, size_t len)
376376

377377
/* write bitmap */
378378
gpiod_set_value(par->RS, 1); /* RS->1 (data mode) */
379-
par->fbtftops.write(par, buf, len);
379+
ret = par->fbtftops.write(par, buf, len);
380380
if (ret < 0)
381381
dev_err(par->info->device,
382382
"write failed and returned: %d\n",

drivers/staging/fbtft/fb_hx8340bn.c

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -106,13 +106,6 @@ static int init_display(struct fbtft_par *par)
106106
return 0;
107107
}
108108

109-
static void set_addr_win(struct fbtft_par *par, int xs, int ys, int xe, int ye)
110-
{
111-
write_reg(par, MIPI_DCS_SET_COLUMN_ADDRESS, 0x00, xs, 0x00, xe);
112-
write_reg(par, MIPI_DCS_SET_PAGE_ADDRESS, 0x00, ys, 0x00, ye);
113-
write_reg(par, MIPI_DCS_WRITE_MEMORY_START);
114-
}
115-
116109
static int set_var(struct fbtft_par *par)
117110
{
118111
/* MADCTL - Memory data access control */
@@ -207,7 +200,6 @@ static struct fbtft_display display = {
207200
.gamma = DEFAULT_GAMMA,
208201
.fbtftops = {
209202
.init_display = init_display,
210-
.set_addr_win = set_addr_win,
211203
.set_var = set_var,
212204
.set_gamma = set_gamma,
213205
},

drivers/staging/fbtft/fb_hx8353d.c

Lines changed: 0 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -61,18 +61,6 @@ static int init_display(struct fbtft_par *par)
6161
return 0;
6262
};
6363

64-
static void set_addr_win(struct fbtft_par *par, int xs, int ys, int xe, int ye)
65-
{
66-
/* column address */
67-
write_reg(par, 0x2a, xs >> 8, xs & 0xff, xe >> 8, xe & 0xff);
68-
69-
/* Row address */
70-
write_reg(par, 0x2b, ys >> 8, ys & 0xff, ye >> 8, ye & 0xff);
71-
72-
/* memory write */
73-
write_reg(par, 0x2c);
74-
}
75-
7664
#define my BIT(7)
7765
#define mx BIT(6)
7866
#define mv BIT(5)
@@ -130,7 +118,6 @@ static struct fbtft_display display = {
130118
.gamma = DEFAULT_GAMMA,
131119
.fbtftops = {
132120
.init_display = init_display,
133-
.set_addr_win = set_addr_win,
134121
.set_var = set_var,
135122
.set_gamma = set_gamma,
136123
},

drivers/staging/fbtft/fb_hx8357d.c

Lines changed: 0 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -129,19 +129,6 @@ static int init_display(struct fbtft_par *par)
129129
return 0;
130130
}
131131

132-
static void set_addr_win(struct fbtft_par *par, int xs, int ys, int xe, int ye)
133-
{
134-
write_reg(par, MIPI_DCS_SET_COLUMN_ADDRESS,
135-
xs >> 8, xs & 0xff, /* XSTART */
136-
xe >> 8, xe & 0xff); /* XEND */
137-
138-
write_reg(par, MIPI_DCS_SET_PAGE_ADDRESS,
139-
ys >> 8, ys & 0xff, /* YSTART */
140-
ye >> 8, ye & 0xff); /* YEND */
141-
142-
write_reg(par, MIPI_DCS_WRITE_MEMORY_START);
143-
}
144-
145132
#define HX8357D_MADCTL_MY 0x80
146133
#define HX8357D_MADCTL_MX 0x40
147134
#define HX8357D_MADCTL_MV 0x20
@@ -184,7 +171,6 @@ static struct fbtft_display display = {
184171
.gamma_len = 14,
185172
.fbtftops = {
186173
.init_display = init_display,
187-
.set_addr_win = set_addr_win,
188174
.set_var = set_var,
189175
},
190176
};

drivers/staging/fbtft/fb_ili9163.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,7 @@
6060
* configure to constrain the memory and resolution to a fixed dimension (in
6161
* that case 128x128) but they leaved those pins configured for 128x160 so
6262
* there was several pixel memory addressing problems.
63-
* I solved by setup several parameters that dinamically fix the resolution as
63+
* I solved by setup several parameters that dynamically fix the resolution as
6464
* needit so below the parameters for this display. If you have a strain or a
6565
* correct display (can happen with chinese) you can copy those parameters and
6666
* create setup for different displays.

drivers/staging/fbtft/fb_ili9340.c

Lines changed: 0 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -78,17 +78,6 @@ static int init_display(struct fbtft_par *par)
7878
return 0;
7979
}
8080

81-
static void set_addr_win(struct fbtft_par *par, int xs, int ys, int xe, int ye)
82-
{
83-
write_reg(par, MIPI_DCS_SET_COLUMN_ADDRESS,
84-
xs >> 8, xs & 0xFF, xe >> 8, xe & 0xFF);
85-
86-
write_reg(par, MIPI_DCS_SET_PAGE_ADDRESS,
87-
ys >> 8, ys & 0xFF, ye >> 8, ye & 0xFF);
88-
89-
write_reg(par, MIPI_DCS_WRITE_MEMORY_START);
90-
}
91-
9281
#define ILI9340_MADCTL_MV 0x20
9382
#define ILI9340_MADCTL_MX 0x40
9483
#define ILI9340_MADCTL_MY 0x80
@@ -122,7 +111,6 @@ static struct fbtft_display display = {
122111
.height = HEIGHT,
123112
.fbtftops = {
124113
.init_display = init_display,
125-
.set_addr_win = set_addr_win,
126114
.set_var = set_var,
127115
},
128116
};

drivers/staging/fbtft/fb_ili9341.c

Lines changed: 0 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -65,17 +65,6 @@ static int init_display(struct fbtft_par *par)
6565
return 0;
6666
}
6767

68-
static void set_addr_win(struct fbtft_par *par, int xs, int ys, int xe, int ye)
69-
{
70-
write_reg(par, MIPI_DCS_SET_COLUMN_ADDRESS,
71-
(xs >> 8) & 0xFF, xs & 0xFF, (xe >> 8) & 0xFF, xe & 0xFF);
72-
73-
write_reg(par, MIPI_DCS_SET_PAGE_ADDRESS,
74-
(ys >> 8) & 0xFF, ys & 0xFF, (ye >> 8) & 0xFF, ye & 0xFF);
75-
76-
write_reg(par, MIPI_DCS_WRITE_MEMORY_START);
77-
}
78-
7968
#define MEM_Y BIT(7) /* MY row address order */
8069
#define MEM_X BIT(6) /* MX column address order */
8170
#define MEM_V BIT(5) /* MV row / column exchange */
@@ -139,7 +128,6 @@ static struct fbtft_display display = {
139128
.gamma = DEFAULT_GAMMA,
140129
.fbtftops = {
141130
.init_display = init_display,
142-
.set_addr_win = set_addr_win,
143131
.set_var = set_var,
144132
.set_gamma = set_gamma,
145133
},

0 commit comments

Comments
 (0)