Commit graph

9716 commits

Author SHA1 Message Date
Aaro Koskinen d2de85c5da staging: xgifb: delete IF_DEF_VideoCapture
Delete already disabled code paths.

Signed-off-by: Aaro Koskinen <aaro.koskinen@iki.fi>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2011-09-06 11:42:13 -07:00
Aaro Koskinen 11fbdcde54 staging: xgifb: delete duplicated timing data
Delete redundant timing data tables. Replace as follows:

	EnlargeTap4Timing	==> xgifb_tap4_timing
	NoScaleTap4Timing	==> xgifb_tap4_timing
	NTSCTap4Timing		==> xgifb_ntsc_525_tap4_timing
	YPbPr525iTap4Timing	==> xgifb_ntsc_525_tap4_timing
	YPbPr525pTap4Timing	==> xgifb_ntsc_525_tap4_timing

Signed-off-by: Aaro Koskinen <aaro.koskinen@iki.fi>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2011-09-06 11:42:13 -07:00
Aaro Koskinen 0c23b6d2fe staging: xgifb: delete duplicated TV data tables
Delete redundant TV data tables. Replace as follows:

	XGI_EPLCHTVDataPtr	==> xgifb_chrontel_tv
	XGI_EPLCHTVRegPtr	==> xgifb_chrontel_tv

Signed-off-by: Aaro Koskinen <aaro.koskinen@iki.fi>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2011-09-06 11:42:13 -07:00
Aaro Koskinen cc5c2aeb23 staging: xgifb: delete duplicated LCD table
XGI_EPLLCDCRT1Ptr_H and XGI_EPLLCDCRT1Ptr_V tables are identical. Replace
as follows:

	XGI_EPLLCDCRT1Ptr_H	==> xgifb_epllcd_crt1
	XGI_EPLLCDCRT1Ptr_V	==> xgifb_epllcd_crt1

Signed-off-by: Aaro Koskinen <aaro.koskinen@iki.fi>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2011-09-06 11:42:12 -07:00
Aaro Koskinen ada2bda145 staging: xgifb: delete duplicated LCD data
Delete duplicated LCD data tables. Replace as follows:

	XGI_ExtLCD1400x1050Data		==> xgifb_lcd_1400x1050
	XGI_StLCD1400x1050Data		==> xgifb_lcd_1400x1050
	XGI_ExtLCD1280x1024x75Data	==> xgifb_lcd_1280x1024x75
	XGI_StLCD1280x1024x75Data	==> xgifb_lcd_1280x1024x75
	XGI_ExtLCDDes1400x1050Data	==> xgifb_lcddes_1400x1050
	XGI_StLCDDes1400x1050Data	==> xgifb_lcddes_1400x1050
	XGI_ExtLCDDLDes1400x1050Data	==> xgifb_lcddldes_1400x1050
	XGI_StLCDDLDes1400x1050Data	==> xgifb_lcddldes_1400x1050
	XGI_ExtLCDDes1024x768x75Data	==> xgifb_lcddes_1024x768x75
	XGI_StLCDDes1024x768x75Data	==> xgifb_lcddes_1024x768x75
	XGI_ExtLCDDes1280x1024x75Data	==> xgifb_lcddes_1280x1024x75
	XGI_StLCDDes1280x1024x75Data	==> xgifb_lcddes_1280x1024x75
	XGI_ExtLCDDLDes1280x1024x75Data ==> xgifb_lcddldes_1280x1024x75
	XGI_StLCDDLDes1280x1024x75Data	==> xgifb_lcddldes_1280x1024x75

Signed-off-by: Aaro Koskinen <aaro.koskinen@iki.fi>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2011-09-06 11:42:12 -07:00
Aaro Koskinen 2555e9458f staging: xgifb: delete duplicated YFilter1 data
PAL-M and PAL-N "YFilter1" tables are identical. Replace as follows:

	PALMYFilter1	==> xgifb_palmn_yfilter1
	PALNYFilter1	==> xgifb_palmn_yfilter1

Signed-off-by: Aaro Koskinen <aaro.koskinen@iki.fi>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2011-09-06 11:42:11 -07:00
Aaro Koskinen 80f86f8f26 staging: xgifb: delete duplicated YFilter2 data
All four "YFilter2" tables are identical. Replace as follows:

	NTSCYFilter2	==> xgifb_yfilter2;
	PALMYFilter2	==> xgifb_yfilter2;
	PALNYFilter2	==> xgifb_yfilter2;
	PALYFilter2	==> xgifb_yfilter2;

Signed-off-by: Aaro Koskinen <aaro.koskinen@iki.fi>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2011-09-06 11:42:10 -07:00
Aaro Koskinen 3825b38e59 staging: xgifb: do not initialize static data to 0
Remove redundant initializations.

Signed-off-by: Aaro Koskinen <aaro.koskinen@iki.fi>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2011-09-06 11:42:10 -07:00
Aaro Koskinen 800d67cf9f staging: xgifb: eliminate #ifdef Tap4
Eliminate #define Tap4 and related checks.

Signed-off-by: Aaro Koskinen <aaro.koskinen@iki.fi>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2011-09-06 11:42:09 -07:00
Aaro Koskinen c071906146 staging: xgifb: delete commented-out routines
Delete routines which have been commented out.

Signed-off-by: Aaro Koskinen <aaro.koskinen@iki.fi>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2011-09-06 11:42:09 -07:00
Aaro Koskinen 64db29f5f6 staging: xgifb: refactor XGI_SetXG21LVDSPara() and XGI_SetXG27LVDSPara()
The code is almost the same for XG21 and XG27, a single routine can
cover both.

Signed-off-by: Aaro Koskinen <aaro.koskinen@iki.fi>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2011-09-06 11:42:09 -07:00
Aaro Koskinen 105d8d0d90 staging: xgifb: refactor XGI_SetXG21LCD() and XGI_SetXG27LCD()
The code is almost the same for XG21 and XG27, a single routine can
cover both.

Signed-off-by: Aaro Koskinen <aaro.koskinen@iki.fi>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2011-09-06 11:42:08 -07:00
Aaro Koskinen 160b006ae9 staging: xgifb: delete redundant Chrontel TV data
Delete redundant Chrontel TV data.

Signed-off-by: Aaro Koskinen <aaro.koskinen@iki.fi>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2011-09-06 11:42:08 -07:00
Aaro Koskinen 83f76a9d7e staging: xgifb: delete support for Chrontel 7007 TV output
IF_DEF_CH7007 is hard-coded to 0, so this is all just dead code that
can be deleted.

Signed-off-by: Aaro Koskinen <aaro.koskinen@iki.fi>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2011-09-06 11:42:07 -07:00
Aaro Koskinen 4c14bfd41d staging: xgifb: delete support for Chrontel 7005 TV output
IF_DEF_CH7005 is hard-coded to 0, so this is all just dead code that
can be deleted.

Signed-off-by: Aaro Koskinen <aaro.koskinen@iki.fi>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2011-09-06 11:42:07 -07:00
Aaro Koskinen a35cd0ba7f staging: xgifb: delete support for Chrontel 7017 TV output
IF_DEF_CH7017 is hard-coded to 0, so this is all just dead code that
can be deleted.

Signed-off-by: Aaro Koskinen <aaro.koskinen@iki.fi>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2011-09-06 11:42:06 -07:00
Aaro Koskinen 9f52fc9a2d staging: xgifb: delete XGI_OpenCRTC()
Delete redundant function. Also eliminates the following sparse warning:

drivers/staging/xgifb/vb_setmode.c:8033:6: warning: symbol 'XGI_OpenCRTC' was not declared. Should it be static?

Signed-off-by: Aaro Koskinen <aaro.koskinen@iki.fi>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2011-09-06 11:42:06 -07:00
Aaro Koskinen b0a7928180 staging: xgifb: use common init for module and built-in
Use a common init function for module and built-in driver.

Signed-off-by: Aaro Koskinen <aaro.koskinen@iki.fi>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2011-09-06 11:41:26 -07:00
Aaro Koskinen 47c92d5f5f stating: xgifb: update module parameter descriptions
Remove incorrect/misleading text from parameter descriptions.

Signed-off-by: Aaro Koskinen <aaro.koskinen@iki.fi>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2011-09-06 11:41:26 -07:00
Aaro Koskinen c32283089c staging: xgifb: delete all references to mode "none"
Delete all references to mode "none". It should be handled like any
other invalid mode.

Signed-off-by: Aaro Koskinen <aaro.koskinen@iki.fi>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2011-09-06 11:41:25 -07:00
Aaro Koskinen 44d0244021 staging: xgifb: correct the default mode comment
According to the comment, the default mode should be 800x600x8 while
the index points actually to 800x600x16. Change the comment and move
the definition instead of changing the current behaviour.

Signed-off-by: Aaro Koskinen <aaro.koskinen@iki.fi>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2011-09-06 11:41:25 -07:00
Aaro Koskinen c8bec1f067 staging: xgifb: simplify default mode setup
The default mode is the same regardless of the display type, except for
XG21/LCD which is determined dynamically.

Signed-off-by: Aaro Koskinen <aaro.koskinen@iki.fi>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2011-09-06 11:41:24 -07:00
Aaro Koskinen de736dbb22 staging: xgifb: fail the probe if no supported LCD video mode found
Fail the probe if the LCD resolution described in card firmware does
not match any of the supported modes.

Signed-off-by: Aaro Koskinen <aaro.koskinen@iki.fi>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2011-09-06 11:41:24 -07:00
Aaro Koskinen 35c064da1b staging: xgifb: delete duplicated default video mode setup code
The code for determining the default video mode is unnecessarily
duplicated in XGIfb_search_mode() and XGIfb_search_vesamode() functions.

Signed-off-by: Aaro Koskinen <aaro.koskinen@iki.fi>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2011-09-06 11:41:23 -07:00
Aaro Koskinen 69a1869861 staging: xgifb: assume the default video mode also when module
The same default video mode should be assumed regardless if the driver
is a module or not. This won't change the current behaviour, but it will
simplify further changes.

Signed-off-by: Aaro Koskinen <aaro.koskinen@iki.fi>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2011-09-06 11:41:23 -07:00
Aaro Koskinen a952cc9057 staging: xgifb: XGIfb_search_mode(): delete unreachable code
XGIfb_search_mode() is always called with a valid string pointer.

Signed-off-by: Aaro Koskinen <aaro.koskinen@iki.fi>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2011-09-06 11:41:22 -07:00
Aaro Koskinen dfbdf80579 staging: xgifb: search video mode later in probe
When searching the video mode, some HW details needs to be
known. Therefore it's not possible to do that reliably before probe().

Signed-off-by: Aaro Koskinen <aaro.koskinen@iki.fi>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2011-09-06 11:41:22 -07:00
Aaro Koskinen 009adf2d4b staging: xgifb: fix LVDS LCD resolution data setup
If the driver fails to get LVDS LCD data from the firmware, it falls
back to using driver's hardcoded values. However, this is done too
early in the probe. The selected video mode index is not yet known,
and also in some cases it could be defaulting to -1 resulting in a read
outside the array. Fix this by moving the array lookup after the video
mode validation.

Signed-off-by: Aaro Koskinen <aaro.koskinen@iki.fi>
Reported-by: Dan Carpenter <error27@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2011-09-06 11:41:22 -07:00
Aaro Koskinen d27c6bc9f4 staging: xgifb: check and report invalid option values
Check option values with kstrtoul(). This will also eliminate some
checkpatch warnings about simple_strtoul() usage.

Signed-off-by: Aaro Koskinen <aaro.koskinen@iki.fi>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2011-09-06 11:41:21 -07:00
Aaro Koskinen 7b0a95f89c staging: xgifb: XGIfb_setup(): delete redundant assignment
The global data is already initialized to zero.

Signed-off-by: Aaro Koskinen <aaro.koskinen@iki.fi>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2011-09-06 11:41:21 -07:00
Aaro Koskinen 79bea04cc9 staging: xgifb: XGIfb_setup(): clean up driver messages
Print options only if they are given. Delete other messages.

Signed-off-by: Aaro Koskinen <aaro.koskinen@iki.fi>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2011-09-06 11:41:21 -07:00
Aaro Koskinen 87c8b8b346 staging: xgifb: delete "off" option handling
It's possible to disable the built-in xgifb driver with the kernel
command line option:

	video=xgifb:off

This is already handled by the generic framebuffer layer (fb_get_options()
will return TRUE resulting in init failure), so no need to process the
option in the driver.

Signed-off-by: Aaro Koskinen <aaro.koskinen@iki.fi>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2011-09-06 11:41:20 -07:00
Aaro Koskinen 20fc30b941 staging: xgifb: delete duplicated code
Delete redundant branches for "mode" and "vesa" options.

Signed-off-by: Aaro Koskinen <aaro.koskinen@iki.fi>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2011-09-06 11:41:20 -07:00
Aaro Koskinen 3f5042dfb4 staging: xgifb: fix ypan disable option
Setting any of the FB options will disable ypan as a side effect. It
should be disabled only by the "noypan" option.

Signed-off-by: Aaro Koskinen <aaro.koskinen@iki.fi>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2011-09-06 11:41:20 -07:00
Aaro Koskinen e1b7f9155e staging: xgifb: delete unused module parameters and options
Delete parameters which have no effect.

Signed-off-by: Aaro Koskinen <aaro.koskinen@iki.fi>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2011-09-06 11:41:20 -07:00
Bill Pemberton 7cbf3c7cd5 staging: serqt_usb2: remove ssu100 from supported devices
The serqt_usb2 driver will not work properly with the ssu100 device
even though it claims to support it.  The ssu100 is supported by the
ssu100 driver in mainline so there is no need to have it claimed by
serqt_usb2.

Signed-off-by: Bill Pemberton <wfp5p@virginia.edu>
Cc: stable <stable@kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2011-08-29 11:20:11 -07:00
Alexey Khoroshilov 22f88fcf40 staging/easycap: fix mismatch in easycap_poll() mutex lock-unlock
In case if condition (kd != isdongle(peasycap)) becomes true,
easycap_poll() returns without releasing easycapdc60_dongle[kd].mutex_video.
The patch adds mutex_unlock() before that return.

Found by Linux Driver Verification project (linuxtesting.org).

Signed-off-by: Alexey Khoroshilov <khoroshilov@ispras.ru>
Acked-by: Tomas Winkler <tomas.winkler@intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2011-08-29 11:20:11 -07:00
Mark Einon 0f18f767e5 staging: et131x: Use phy-device, mii_bus and ethtool_ops
Adding some basic ethtool ops and supporting functionality using a phy device.

Signed-off-by: Mark Einon <mark.einon@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2011-08-29 11:20:11 -07:00
Mark Einon fca7737f5c staging: et131x: Remove module_param et131x_speed_set
Manual setting of speed/duplex will be achieved using ethtool.
Remove the driver specific module_param that also does this.

Signed-off-by: Mark Einon <mark.einon@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2011-08-29 11:20:10 -07:00
Mark Einon 694bd60383 staging: et131x: Remove redundant replica loopback code
A mechanism used to set the phy in loopback mode is not present in the driver, making associated checks and variables redundant. Removing them.

Signed-off-by: Mark Einon <mark.einon@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2011-08-29 11:20:10 -07:00
Mark Einon 4a334d898a staging: et131x: Remove unused xcvr_id in struct ce_stats
xcvr_id holds the phy ID which is stored but never used in the driver.

Signed-off-by: Mark Einon <mark.einon@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2011-08-29 11:20:10 -07:00
Mark Einon 6d15059fd0 staging: et131x: Further tidy up of 131x_pci_setup()
* Removed unused bool variable.
* Eliminated mid-function returns, used gotos instead

Signed-off-by: Mark Einon <mark.einon@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2011-08-29 11:20:08 -07:00
Dan Carpenter 7f9615e6f6 Staging: hv: netvsc: return negative error codes
There was a typo here and we changed the -ENOMEM into +ENOMEM.  The
error codes aren't used, so this is just a cleanup.

Signed-off-by: Dan Carpenter <error27@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2011-08-29 11:15:23 -07:00
K. Y. Srinivasan bb5da491ff Staging: hv: mousevsc: Fix checkpatch errors and warnings
Fix checkpatch errors and warnings.

Signed-off-by: K. Y. Srinivasan <kys@microsoft.com>
Signed-off-by: Haiyang Zhang <haiyangz@microsoft.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2011-08-29 11:10:47 -07:00
K. Y. Srinivasan d9add43b48 Staging: hv: vmbus: Fix checkpatch warnings in connection.c
Fix checkpatch warnings in connection.c.

Signed-off-by: K. Y. Srinivasan <kys@microsoft.com>
Signed-off-by: Haiyang Zhang <haiyangz@microsoft.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2011-08-29 11:10:02 -07:00
K. Y. Srinivasan b737b2e00d Staging: hv: vmbus: Fix a checkpatch warning in ring_buffer.c
Fix a checkpatch warning in ring_buffer.c

Signed-off-by: K. Y. Srinivasan <kys@microsoft.com>
Signed-off-by: Haiyang Zhang <haiyangz@microsoft.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2011-08-29 11:10:02 -07:00
K. Y. Srinivasan c2ec81cb3e Staging: hv: vmbus: Get rid of an unnecessary check in vmbus_connect()
Get rid of an unnecessary check in vmbus_connect().

Signed-off-by: K. Y. Srinivasan <kys@microsoft.com>
Signed-off-by: Haiyang Zhang <haiyangz@microsoft.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2011-08-29 11:10:01 -07:00
K. Y. Srinivasan 0bce28b62e Staging: hv: vmbus: Get rid of some dated/redundant comments
Get rid of some dated/redundant comments in vmbus_drv.c

Signed-off-by: K. Y. Srinivasan <kys@microsoft.com>
Signed-off-by: Haiyang Zhang <haiyangz@microsoft.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2011-08-29 11:07:00 -07:00
K. Y. Srinivasan 0a4425b65d Staging: hv: vmbus: Fixup indentation in vmbus_acpi_add()
Fixup indentation in vmbus_acpi_add().

Signed-off-by: K. Y. Srinivasan <kys@microsoft.com>
Signed-off-by: Haiyang Zhang <haiyangz@microsoft.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2011-08-29 11:06:59 -07:00
K. Y. Srinivasan 93511baa06 Staging: hv: vmbus: Do not enable auto eoi
Linux interrupt handling code generates the eoi; don't enable auto eoi.

Signed-off-by: K. Y. Srinivasan <kys@microsoft.com>
Signed-off-by: Haiyang Zhang <haiyangz@microsoft.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2011-08-29 11:06:59 -07:00