diff options
author | Leonardo Brás <leobras.c@gmail.com> | 2018-08-07 21:28:29 -0300 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2018-08-08 14:23:16 +0200 |
commit | 333c7b940526be12b8a831b08f948a07e0955271 (patch) | |
tree | 7d464195f6dbdcfcb81b984e1fbab0a3821b18b4 /drivers/staging/fbtft/fbtft-core.c | |
parent | 0b1533c6c6f63bca9807fd6f295d769b6f4b5a11 (diff) |
staging: fbtft: Fixes some alignment issues - Style
Fixes (most) alignment issues pointed by checkpatch.pl.
Signed-off-by: Leonardo Brás <leobras.c@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/staging/fbtft/fbtft-core.c')
-rw-r--r-- | drivers/staging/fbtft/fbtft-core.c | 39 |
1 files changed, 21 insertions, 18 deletions
diff --git a/drivers/staging/fbtft/fbtft-core.c b/drivers/staging/fbtft/fbtft-core.c index 731e47149af8..a03d8adf3f9a 100644 --- a/drivers/staging/fbtft/fbtft-core.c +++ b/drivers/staging/fbtft/fbtft-core.c @@ -137,8 +137,8 @@ static int fbtft_request_gpios(struct fbtft_par *par) flags = fbtft_request_gpios_match(par, gpio); if (flags != FBTFT_GPIO_NO_MATCH) { ret = devm_gpio_request_one(par->info->device, - gpio->gpio, flags, - par->info->device->driver->name); + gpio->gpio, flags, + par->info->device->driver->name); if (ret < 0) { dev_err(par->info->device, "%s: gpio_request_one('%s'=%d) failed with %d\n", @@ -249,8 +249,8 @@ static int fbtft_backlight_update_status(struct backlight_device *bd) bool polarity = par->polarity; fbtft_par_dbg(DEBUG_BACKLIGHT, par, - "%s: polarity=%d, power=%d, fb_blank=%d\n", - __func__, polarity, bd->props.power, bd->props.fb_blank); + "%s: polarity=%d, power=%d, fb_blank=%d\n", + __func__, polarity, bd->props.power, bd->props.fb_blank); if ((bd->props.power == FB_BLANK_UNBLANK) && (bd->props.fb_blank == FB_BLANK_UNBLANK)) @@ -372,7 +372,7 @@ static void fbtft_update_display(struct fbtft_par *par, unsigned int start_line, if (start_line > par->info->var.yres - 1 || end_line > par->info->var.yres - 1) { dev_warn(par->info->device, - "%s: start_line=%u or end_line=%u is larger than max=%d. Shouldn't happen, will do full display update\n", + "%s: start_line=%u or end_line=%u is larger than max=%d. Shouldn't happen, will do full display update\n", __func__, start_line, end_line, par->info->var.yres - 1); start_line = 0; @@ -817,8 +817,8 @@ struct fb_info *fbtft_framebuffer_alloc(struct fbtft_display *display, info->pseudo_palette = par->pseudo_palette; if (par->gamma.curves && gamma) { - if (fbtft_gamma_parse_str(par, - par->gamma.curves, gamma, strlen(gamma))) + if (fbtft_gamma_parse_str(par, par->gamma.curves, gamma, + strlen(gamma))) goto alloc_fail; } @@ -1045,8 +1045,8 @@ static int fbtft_init_display_dt(struct fbtft_par *par) while (p && !(val & 0xFFFF0000)) { if (i > 63) { dev_err(par->info->device, - "%s: Maximum register values exceeded\n", - __func__); + "%s: Maximum register values exceeded\n", + __func__); return -EINVAL; } buf[i++] = val; @@ -1166,8 +1166,8 @@ int fbtft_init_display(struct fbtft_par *par) while (par->init_sequence[i] >= 0) { if (j > 63) { dev_err(par->info->device, - "%s: Maximum register values exceeded\n", - __func__); + "%s: Maximum register values exceeded\n", + __func__); return -EINVAL; } buf[j++] = par->init_sequence[i++]; @@ -1193,7 +1193,8 @@ int fbtft_init_display(struct fbtft_par *par) case -2: i++; fbtft_par_dbg(DEBUG_INIT_DISPLAY, par, - "init: mdelay(%d)\n", par->init_sequence[i]); + "init: mdelay(%d)\n", + par->init_sequence[i]); mdelay(par->init_sequence[i++]); break; default: @@ -1225,8 +1226,8 @@ static int fbtft_verify_gpios(struct fbtft_par *par) fbtft_par_dbg(DEBUG_VERIFY_GPIOS, par, "%s()\n", __func__); - if (pdata->display.buswidth != 9 && par->startbyte == 0 && - par->gpio.dc < 0) { + if (pdata->display.buswidth != 9 && par->startbyte == 0 && + par->gpio.dc < 0) { dev_err(par->info->device, "Missing info about 'dc' gpio. Aborting.\n"); return -EINVAL; @@ -1321,7 +1322,8 @@ static struct fbtft_platform_data *fbtft_probe_dt(struct device *dev) * Return: 0 if successful, negative if error */ int fbtft_probe_common(struct fbtft_display *display, - struct spi_device *sdev, struct platform_device *pdev) + struct spi_device *sdev, + struct platform_device *pdev) { struct device *dev; struct fb_info *info; @@ -1393,11 +1395,12 @@ int fbtft_probe_common(struct fbtft_display *display, par->spi->bits_per_word = 9; } else { dev_warn(&par->spi->dev, - "9-bit SPI not available, emulating using 8-bit.\n"); + "9-bit SPI not available, emulating using 8-bit.\n"); /* allocate buffer with room for dc bits */ par->extra = devm_kzalloc(par->info->device, - par->txbuf.len + (par->txbuf.len / 8) + 8, - GFP_KERNEL); + par->txbuf.len + + (par->txbuf.len / 8) + 8, + GFP_KERNEL); if (!par->extra) { ret = -ENOMEM; goto out_release; |