From 9ea3c498962bc63748e92c31c874169ab0726324 Mon Sep 17 00:00:00 2001 From: Martlin Ettl Date: Thu, 5 Jul 2012 17:58:46 +0100 Subject: backlight: fix memory leak on obscure error path Dredged out of bugzilla Reported-by: Martlin Ettl Resolves-bug: https://bugzilla.kernel.org/show_bug.cgi?id=15492 Signed-off-by: Alan Cox Signed-off-by: Jiri Kosina --- drivers/video/backlight/88pm860x_bl.c | 1 + 1 file changed, 1 insertion(+) (limited to 'drivers/video') diff --git a/drivers/video/backlight/88pm860x_bl.c b/drivers/video/backlight/88pm860x_bl.c index f49181c..f75da87 100644 --- a/drivers/video/backlight/88pm860x_bl.c +++ b/drivers/video/backlight/88pm860x_bl.c @@ -228,6 +228,7 @@ static int pm860x_backlight_probe(struct platform_device *pdev) data->port = pdata->flags; if (data->port < 0) { dev_err(&pdev->dev, "wrong platform data is assigned"); + kfree(data); return -EINVAL; } -- cgit v1.1 From 39012f68058e845b63b98fc07f37cf631dddbed3 Mon Sep 17 00:00:00 2001 From: Alan Cox Date: Wed, 11 Jul 2012 14:22:56 +0100 Subject: via: Remove bogus if check Reported-by: Signed-off-by: Alan Cox Resolves-bug: https://bugzilla.kernel.org/show_bug.cgi?id=44331 Signed-off-by: Jiri Kosina --- drivers/video/sis/init.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'drivers/video') diff --git a/drivers/video/sis/init.c b/drivers/video/sis/init.c index 66de8323..f082ae5 100644 --- a/drivers/video/sis/init.c +++ b/drivers/video/sis/init.c @@ -2628,7 +2628,8 @@ SiS_SetVCLKState(struct SiS_Private *SiS_Pr, unsigned short ModeNo, else if(VCLK >= 135) data = 0x02; if(SiS_Pr->ChipType == SIS_540) { - if((VCLK == 203) || (VCLK < 234)) data = 0x02; + /* Was == 203 or < 234 which made no sense */ + if (VCLK < 234) data = 0x02; } if(SiS_Pr->ChipType < SIS_315H) { -- cgit v1.1 From 90b24cfb42fc5c0366a0555fd5236e9f84f86d2c Mon Sep 17 00:00:00 2001 From: Steve Glendinning Date: Mon, 16 Apr 2012 12:13:29 +0100 Subject: Change email address for Steve Glendinning I no longer have a mailbox at smsc.com, and I've had two reports that that email address now bounces from people trying to contact me. This patch updates all references to that invalid address to one that I can be contacted on more permanently. This patch also updates the maintainer status to reflect the fact I'm no longer directly paid to maintain these drivers. Signed-off-by: Steve Glendinning Signed-off-by: Jiri Kosina --- drivers/video/smscufx.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'drivers/video') diff --git a/drivers/video/smscufx.c b/drivers/video/smscufx.c index ccbfef5..2e4c249 100644 --- a/drivers/video/smscufx.c +++ b/drivers/video/smscufx.c @@ -1,7 +1,7 @@ /* * smscufx.c -- Framebuffer driver for SMSC UFX USB controller * - * Copyright (C) 2011 Steve Glendinning + * Copyright (C) 2011 Steve Glendinning * Copyright (C) 2009 Roberto De Ioris * Copyright (C) 2009 Jaya Kumar * Copyright (C) 2009 Bernie Thompson @@ -1972,6 +1972,6 @@ MODULE_PARM_DESC(console, "Allow fbcon to be used on this display"); module_param(fb_defio, bool, S_IWUSR | S_IRUSR | S_IWGRP | S_IRGRP); MODULE_PARM_DESC(fb_defio, "Enable fb_defio mmap support"); -MODULE_AUTHOR("Steve Glendinning "); +MODULE_AUTHOR("Steve Glendinning "); MODULE_DESCRIPTION("SMSC UFX kernel framebuffer driver"); MODULE_LICENSE("GPL"); -- cgit v1.1 From ff0c26424c1d993d8d1e04f72f1d428e935798da Mon Sep 17 00:00:00 2001 From: Masanari Iida Date: Sun, 22 Jul 2012 00:23:15 +0900 Subject: video: Fix typo in drivers/video Correct spelling typo in debug messages and comments within drivers/video. Signed-off-by: Masanari Iida Signed-off-by: Jiri Kosina --- drivers/video/arcfb.c | 4 ++-- drivers/video/atmel_lcdfb.c | 2 +- drivers/video/aty/atyfb_base.c | 2 +- drivers/video/aty/radeon_base.c | 2 +- drivers/video/bfin_adv7393fb.c | 2 +- drivers/video/cirrusfb.c | 2 +- drivers/video/exynos/exynos_dp_reg.c | 2 +- drivers/video/exynos/exynos_mipi_dsi.c | 2 +- drivers/video/i740fb.c | 6 +++--- drivers/video/s3c-fb.c | 2 +- drivers/video/savage/savagefb_driver.c | 6 +++--- drivers/video/smscufx.c | 4 ++-- drivers/video/sunxvr500.c | 2 +- 13 files changed, 19 insertions(+), 19 deletions(-) (limited to 'drivers/video') diff --git a/drivers/video/arcfb.c b/drivers/video/arcfb.c index c22e8d3..a1d58e9 100644 --- a/drivers/video/arcfb.c +++ b/drivers/video/arcfb.c @@ -336,8 +336,8 @@ static void arcfb_lcd_update_horiz(struct arcfb_par *par, unsigned int left, } /* - * here we start the process of spliting out the fb update into - * individual blocks of pixels. we end up spliting into 64x64 blocks + * here we start the process of splitting out the fb update into + * individual blocks of pixels. we end up splitting into 64x64 blocks * and finally down to 64x8 pages. */ static void arcfb_lcd_update(struct arcfb_par *par, unsigned int dx, diff --git a/drivers/video/atmel_lcdfb.c b/drivers/video/atmel_lcdfb.c index d99505b..1505539 100644 --- a/drivers/video/atmel_lcdfb.c +++ b/drivers/video/atmel_lcdfb.c @@ -939,7 +939,7 @@ static int __init atmel_lcdfb_probe(struct platform_device *pdev) * up a splash image. */ } else { - /* alocate memory buffer */ + /* allocate memory buffer */ ret = atmel_lcdfb_alloc_video_memory(sinfo); if (ret < 0) { dev_err(dev, "cannot allocate framebuffer: %d\n", ret); diff --git a/drivers/video/aty/atyfb_base.c b/drivers/video/aty/atyfb_base.c index 622f12b..3f2e8c1 100644 --- a/drivers/video/aty/atyfb_base.c +++ b/drivers/video/aty/atyfb_base.c @@ -863,7 +863,7 @@ static int aty_var_to_crtc(const struct fb_info *info, if ((xres > 1600) || (yres > 1200)) { FAIL("MACH64 chips are designed for max 1600x1200\n" - "select anoter resolution."); + "select another resolution."); } h_sync_strt = h_disp + var->right_margin; h_sync_end = h_sync_strt + var->hsync_len; diff --git a/drivers/video/aty/radeon_base.c b/drivers/video/aty/radeon_base.c index ce1506b..9e279ee 100644 --- a/drivers/video/aty/radeon_base.c +++ b/drivers/video/aty/radeon_base.c @@ -2018,7 +2018,7 @@ static void radeon_identify_vram(struct radeonfb_info *rinfo) if ((rinfo->family == CHIP_FAMILY_RS100) || (rinfo->family == CHIP_FAMILY_RS200)) { /* This is to workaround the asic bug for RMX, some versions - of BIOS dosen't have this register initialized correctly. + of BIOS doesn't have this register initialized correctly. */ OUTREGP(CRTC_MORE_CNTL, CRTC_H_CUTOFF_ACTIVE_EN, ~CRTC_H_CUTOFF_ACTIVE_EN); diff --git a/drivers/video/bfin_adv7393fb.c b/drivers/video/bfin_adv7393fb.c index 1a268a2..633e9fe 100644 --- a/drivers/video/bfin_adv7393fb.c +++ b/drivers/video/bfin_adv7393fb.c @@ -58,7 +58,7 @@ static const unsigned short ppi_pins[] = { */ static struct bfin_adv7393_fb_par { - /* structure holding blackfin / adv7393 paramters when + /* structure holding blackfin / adv7393 parameters when screen is blanked */ struct { u8 Mode; /* ntsc/pal/? */ diff --git a/drivers/video/cirrusfb.c b/drivers/video/cirrusfb.c index 738c8ce..bc67d05 100644 --- a/drivers/video/cirrusfb.c +++ b/drivers/video/cirrusfb.c @@ -1611,7 +1611,7 @@ static void init_vgachip(struct fb_info *info) /* ext. display controls: ext.adr. wrap */ vga_wcrt(cinfo->regbase, CL_CRT1B, 0x02); - /* Set/Reset registes: - */ + /* Set/Reset registers: - */ vga_wgfx(cinfo->regbase, VGA_GFX_SR_VALUE, 0x00); /* Set/Reset enable: - */ vga_wgfx(cinfo->regbase, VGA_GFX_SR_ENABLE, 0x00); diff --git a/drivers/video/exynos/exynos_dp_reg.c b/drivers/video/exynos/exynos_dp_reg.c index 6548afa..7ddd67d 100644 --- a/drivers/video/exynos/exynos_dp_reg.c +++ b/drivers/video/exynos/exynos_dp_reg.c @@ -717,7 +717,7 @@ int exynos_dp_read_bytes_from_i2c(struct exynos_dp_device *dp, /* * If Rx sends defer, Tx sends only reads - * request without sending addres + * request without sending address */ if (!defer) retval = exynos_dp_select_i2c_device(dp, diff --git a/drivers/video/exynos/exynos_mipi_dsi.c b/drivers/video/exynos/exynos_mipi_dsi.c index 557091d..115e1b0 100644 --- a/drivers/video/exynos/exynos_mipi_dsi.c +++ b/drivers/video/exynos/exynos_mipi_dsi.c @@ -104,7 +104,7 @@ static void exynos_mipi_update_cfg(struct mipi_dsim_device *dsim) /* * data from Display controller(FIMD) is transferred in video mode - * but in case of command mode, all settigs is updated to registers. + * but in case of command mode, all settings are updated to registers. */ exynos_mipi_dsi_stand_by(dsim, 1); } diff --git a/drivers/video/i740fb.c b/drivers/video/i740fb.c index fe574d8..ff3f880 100644 --- a/drivers/video/i740fb.c +++ b/drivers/video/i740fb.c @@ -497,7 +497,7 @@ static int i740fb_decode_var(const struct fb_var_screeninfo *var, mem = vxres * vyres * ((bpp + 1) / 8); if (mem > info->screen_size) { - dev_err(info->device, "not enough video memory (%d KB requested, %ld KB avaliable)\n", + dev_err(info->device, "not enough video memory (%d KB requested, %ld KB available)\n", mem >> 10, info->screen_size >> 10); return -ENOMEM; } @@ -728,7 +728,7 @@ static void vga_protect(struct i740fb_par *par) i740outreg_mask(par, VGA_SEQ_I, VGA_SEQ_CLOCK_MODE, 0x20, 0x20); i740inb(par, 0x3DA); - i740outb(par, VGA_ATT_W, 0x00); /* enable pallete access */ + i740outb(par, VGA_ATT_W, 0x00); /* enable palette access */ } static void vga_unprotect(struct i740fb_par *par) @@ -737,7 +737,7 @@ static void vga_unprotect(struct i740fb_par *par) i740outreg_mask(par, VGA_SEQ_I, VGA_SEQ_CLOCK_MODE, 0, 0x20); i740inb(par, 0x3DA); - i740outb(par, VGA_ATT_W, 0x20); /* disable pallete access */ + i740outb(par, VGA_ATT_W, 0x20); /* disable palette access */ } static int i740fb_set_par(struct fb_info *info) diff --git a/drivers/video/s3c-fb.c b/drivers/video/s3c-fb.c index f310516..e5331fc 100644 --- a/drivers/video/s3c-fb.c +++ b/drivers/video/s3c-fb.c @@ -189,7 +189,7 @@ struct s3c_fb_vsync { /** * struct s3c_fb - overall hardware state of the hardware - * @slock: The spinlock protection for this data sturcture. + * @slock: The spinlock protection for this data sturucture. * @dev: The device that we bound to, for printing, etc. * @bus_clk: The clk (hclk) feeding our interface and possibly pixclk. * @lcd_clk: The clk (sclk) feeding pixclk. diff --git a/drivers/video/savage/savagefb_driver.c b/drivers/video/savage/savagefb_driver.c index cee7803..b4c2e21 100644 --- a/drivers/video/savage/savagefb_driver.c +++ b/drivers/video/savage/savagefb_driver.c @@ -662,7 +662,7 @@ static void savage_get_default_par(struct savagefb_par *par, struct savage_reg * vga_out8(0x3c4, 0x18, par); reg->SR18 = vga_in8(0x3c5, par); - /* Save flat panel expansion regsters. */ + /* Save flat panel expansion registers. */ if (par->chip == S3_SAVAGE_MX) { int i; @@ -815,7 +815,7 @@ static void savage_set_default_par(struct savagefb_par *par, vga_out8(0x3c4, 0x18, par); vga_out8(0x3c5, reg->SR18, par); - /* Save flat panel expansion regsters. */ + /* Save flat panel expansion registers. */ if (par->chip == S3_SAVAGE_MX) { int i; @@ -1318,7 +1318,7 @@ static void savagefb_set_par_int(struct savagefb_par *par, struct savage_reg *r vga_out8(0x3c4, 0x15, par); vga_out8(0x3c5, reg->SR15, par); - /* Restore flat panel expansion regsters. */ + /* Restore flat panel expansion registers. */ if (par->chip == S3_SAVAGE_MX) { int i; diff --git a/drivers/video/smscufx.c b/drivers/video/smscufx.c index 2e4c249..538e5ef 100644 --- a/drivers/video/smscufx.c +++ b/drivers/video/smscufx.c @@ -1002,7 +1002,7 @@ static int ufx_ops_ioctl(struct fb_info *info, unsigned int cmd, /* TODO: Help propose a standard fb.h ioctl to report mmap damage */ if (cmd == UFX_IOCTL_REPORT_DAMAGE) { /* If we have a damage-aware client, turn fb_defio "off" - * To avoid perf imact of unecessary page fault handling. + * To avoid perf imact of unnecessary page fault handling. * Done by resetting the delay for this fb_info to a very * long period. Pages will become writable and stay that way. * Reset to normal value when all clients have closed this fb. @@ -1466,7 +1466,7 @@ static int ufx_read_edid(struct ufx_data *dev, u8 *edid, int edid_len) /* all FF's in the first 16 bytes indicates nothing is connected */ for (i = 0; i < 16; i++) { if (edid[i] != 0xFF) { - pr_debug("edid data read succesfully"); + pr_debug("edid data read successfully"); return EDID_LENGTH; } } diff --git a/drivers/video/sunxvr500.c b/drivers/video/sunxvr500.c index b9c2b94..eb931b8 100644 --- a/drivers/video/sunxvr500.c +++ b/drivers/video/sunxvr500.c @@ -12,7 +12,7 @@ #include -/* XXX This device has a 'dev-comm' property which aparently is +/* XXX This device has a 'dev-comm' property which apparently is * XXX a pointer into the openfirmware's address space which is * XXX a shared area the kernel driver can use to keep OBP * XXX informed about the current resolution setting. The idea -- cgit v1.1