summaryrefslogtreecommitdiff
path: root/drivers/staging/most
AgeCommit message (Collapse)Author
2015-10-29staging: most: remove exclusive wait_queueChristian Gromm
This patch removes the unnecessary wait_queue that has exclusively been used for the poll function and its poll_table. Instead, an already existing one is used. Signed-off-by: Christian Gromm <christian.gromm@microchip.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-10-29staging: most: hdm-dim2: use min_t()Christian Gromm
This patch replaces the usage of min() by min_t(). Signed-off-by: Christian Gromm <christian.gromm@microchip.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-10-24staging: most: hdm-usb: Use setup_timerMuhammad Falak R Wani
Use the timer API function setup_timer instead of init_timer, removing the structure field assignments. <smpl> @timer@ expression e1,e2,e3,fn_ptr; @@ -init_timer(&e1); +setup_timer(&e1, fn_ptr, e2); ... when != fn_ptr = e3 -e1.function = fn_ptr; -e1.data = e2; </smpl> Signed-off-by: Muhammad Falak R Wani <falakreyaz@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-10-24staging: most: remove comparison to NULLChristian Gromm
Signed-off-by: Christian Gromm <christian.gromm@microchip.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-10-24staging: most: use preferred kzalloc parametersChristian Gromm
This patch uses the preferred call to kzalloc. It replaces kzalloc(sizeof(struct aim_fh)...) by kzalloc(sizeof(*fh)...). Signed-off-by: Christian Gromm <christian.gromm@microchip.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-10-24staging: most: use preferred kernel typesChristian Gromm
This patch makes use of the preferred kernel types such as u16, u32. Signed-off-by: Christian Gromm <christian.gromm@microchip.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-10-24staging: most: fix logical operator positionChristian Gromm
This patch puts logical continuations on the previous line to meet coding style. Signed-off-by: Christian Gromm <christian.gromm@microchip.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-10-24staging: most: remove unnecessary parenthesesChristian Gromm
This patch simply removes unnecessary parentheses. Signed-off-by: Christian Gromm <christian.gromm@microchip.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-10-24staging: most: use blank line after declarationsChristian Gromm
This patch fixes style violation regarding blank lines after function/struct/union/enum declarations. Signed-off-by: Christian Gromm <christian.gromm@microchip.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-10-24staging: most: use braces on all arms of statementChristian Gromm
This patch fixes style issues regarding braces on all arms of a statement. Signed-off-by: Christian Gromm <christian.gromm@microchip.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-10-24staging: most: make alignment match open parenthesisChristian Gromm
This patch fixes coding style violations by making alignments match open parenthesis. Signed-off-by: Christian Gromm <christian.gromm@microchip.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-10-24staging: most: remove multiple assignmentChristian Gromm
This patch removes multiple assignments as specified in coding style. Signed-off-by: Christian Gromm <christian.gromm@microchip.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-10-24staging: most: removed redundant codeChristian Gromm
This patch removes redundant code. Signed-off-by: Christian Gromm <christian.gromm@microchip.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-10-24staging: most: put spaces around operatorChristian Gromm
This patch puts spaces around the asterisk operator. It is needed to prevent checkpatch from reporting an issue. Signed-off-by: Christian Gromm <christian.gromm@microchip.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-10-24staging: most: remove multiple blank linesChristian Gromm
This patch removes the usage of multiple blank lines from driver modules. Signed-off-by: Christian Gromm <christian.gromm@microchip.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-10-16staging: most: fix line-over-80-characters violationsChristian Gromm
This patch prevents code from crossing the 80 character margin. Signed-off-by: Christian Gromm <christian.gromm@microchip.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-10-16staging: most: change parameter descriptionChristian Gromm
This patch changes the description of a function parameter for a better understanding. Signed-off-by: Christian Gromm <christian.gromm@microchip.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-10-16staging: most: replace memcpy by ether_addr_copyChristian Gromm
This patch replaces memcpy() by the preferred function ether_addr_copy(). Signed-off-by: Christian Gromm <christian.gromm@microchip.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-10-16staging: most: fix misplaced constants in comparisonsChristian Gromm
This patch removes and fixes constants being misplaced in comparisons. Signed-off-by: Christian Gromm <christian.gromm@microchip.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-10-16staging: most: make hdm-usb follow the coding styleChristian Gromm
This patch fixes a couple of issues of the hdm-usb module found by checkpatch.pl. Signed-off-by: Christian Gromm <christian.gromm@microchip.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-10-16staging: most: fix checkpatch issues of hdm i2cChristian Gromm
This patch fixes the issues of HDM module i2c found by checkpatch.pl Signed-off-by: Christian Gromm <christian.gromm@microchip.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-10-16staging: most: remove constants from comparisonsChristian Gromm
This patch removes constants from comparisons and fixes checkpatch warnings about constants being put in the wrong place inside a comparison. Signed-off-by: Christian Gromm <christian.gromm@microchip.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-10-16staging: most: correct coding style breachesChristian Gromm
This patch fixes line-over-80-characters violation and removes the splitting of quoted strings. Signed-off-by: Christian Gromm <christian.gromm@microchip.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-10-16Staging: most: cdev: Remove useless checkShivani Bhardwaj
The variable mbo is already NULL tested so, check on it should be removed. Semantic patch used: @@ expression E; statement S; @@ if(E==NULL) {... return ...;} - if(E) S Signed-off-by: Shivani Bhardwaj <shivanib134@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-10-16Staging: most: fix style issue in aim-cdev/cdev.cGavin Thomas Claugus
Fix 80+ character line in cdev.c to stop checkpatch from whining. Signed-off-by: Gavin Thomas Claugus <gclaugus@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-10-16Staging: most: Remove unnecessary cast on void pointerShraddha Barke
void pointers do not need to be cast to other pointer types. The semantic patch used to find this: @r@ expression x; void* e; type T; identifier f; @@ ( *((T *)e) | ((T *)x)[...] | ((T *)x)->f | - (T *) e ) Signed-off-by: Shraddha Barke <shraddha.6596@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-10-13Staging: most: Remove exceptional & on function nameShraddha Barke
In this file, function names are otherwise used as pointers without &. A simplified version of the Coccinelle semantic patch that makes this change is as follows: // <smpl> @r@ identifier f; @@ f(...) { ... } @@ identifier r.f; @@ - &f + f // </smpl> Signed-off-by: Shraddha Barke <shraddha.6596@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-10-12Staging: most: hdm-i2c: Drop owner assignment from i2c driverShraddha Barke
i2c_driver does not need to set an owner because core will set it Signed-off-by: Shraddha Barke <shraddha.6596@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-10-12Staging: most: Fix typo in staging/mostMasanari Iida
This patch fix spelling typo found in most Signed-off-by: Masanari Iida <standby24x7@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-10-04Staging: most: Use module_platform_driverShraddha Barke
Use module_platform_driver for drivers whose init and exit functions only register and unregister, respectively. Thus remove some boilerplate code. A simplified version of Coccinelle patch - @a@ identifier f, x; @@ -static f(...) { return platform_driver_register(&x); } @b depends on a@ identifier e, a.x; @@ -static e(...) { platform_driver_unregister(&x); } @c depends on a && b@ identifier a.f; declarer name module_init; @@ -module_init(f); @d depends on a && b && c@ identifier b.e, a.x; declarer name module_exit; declarer name module_platform_driver; @@ -module_exit(e); +module_platform_driver(x); Signed-off-by: Shraddha Barke <shraddha.6596@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-09-29Staging: most: Use module_i2c_driverShraddha Barke
Macro module_i2c_driver is used for drivers whose init and exit paths does only register and unregister to i2c API. Remove some boilerplate code by using module_i2c_driver. Problem found using Coccinelle. Signed-off-by: Shraddha Barke <shraddha.6596@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-09-29staging: most: fix pcm_write input/output errorChristian Gromm
This patch keeps the process from sleeping after the PCM middle layer has stopped playback by calling the pcm trigger callback. The patch is needed to prevent aplay from causing a pcm_write Input/Output error. Signed-off-by: Christian Gromm <christian.gromm@microchip.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-09-29staging: most: add poll syscall to AIM cdevChristian Gromm
This patch adds the implementation of the poll syscall to the AIM cdev. To have the full functionality, a helper function is needed in the core module to retrieve the instantaneous availability of tx buffers. Signed-off-by: Christian Gromm <christian.gromm@microchip.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-09-29staging: most: remove audio resolution format checkChristian Gromm
This patch removes the audio format cross-check, because the definitions are not compatible. Signed-off-by: Christian Gromm <christian.gromm@microchip.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-09-29staging: most: fix style problemsChristian Gromm
This patch simply corrects style violations. Signed-off-by: Christian Gromm <christian.gromm@microchip.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-09-29staging: most: move initialization codeChristian Gromm
This pathch moves the initialization of the PCM middle layer hardware parameters to function audio_set_hw_params(). Signed-off-by: Christian Gromm <christian.gromm@microchip.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-09-29staging: most: rename functionChristian Gromm
This patch renames the function audio_set_pcm_format(). Since the function doesn't only set the PCM format anymore and to guard against misunderstandings, its name needs to be changed. Signed-off-by: Christian Gromm <christian.gromm@microchip.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-09-29staging: most: add missing channel initializationChristian Gromm
This patch adds missing initialization of channel count for 8-bit mono audio resolution. Signed-off-by: Christian Gromm <christian.gromm@microchip.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-09-29staging: most: purge unecessary variableChristian Gromm
This patch purges a temp. variable to store the functions return value. Since the content is never being evaluated, it can safely be removed. Signed-off-by: Christian Gromm <christian.gromm@microchip.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-09-29staging: most: squash AIM soundChristian Gromm
This patch removes debug messages and prevents the sound AIM from being noisy in kernel log. Signed-off-by: Christian Gromm <christian.gromm@microchip.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-09-29staging: most: make hardware parameters channel exclusiveChristian Gromm
Since the PCM interface's hardware parameters are channel/substream exclusive, the struct snd_pcm_hardware needs to be embedded in the channel structure. Signed-off-by: Christian Gromm <christian.gromm@microchip.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-09-29staging: most: include vendor in audio card's shortnameChristian Gromm
This patch adds Microchip as vendor to the audio card's shortname to be displayed, when playback and capture devices are queried. Signed-off-by: Christian Gromm <christian.gromm@microchip.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-09-29staging: most: add multi channel support to sound AIMChristian Gromm
This patch adds 5.1 surround configuration with subbuffer cross-check, when establishing a link to the core. For the sake of simplicity, only one specific channel configuration is allowed. Signed-off-by: Christian Gromm <christian.gromm@microchip.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-09-29staging: most: refactor channel structureChristian Gromm
The struct most_c_obj has the same set of attributes for each of two AIMs. This patch cleans up the code by introducing the new struct most_c_aim_obj hat contains those fields. Signed-off-by: Christian Gromm <christian.gromm@microchip.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-09-29staging: most: add fair buffer distributionChristian Gromm
This patch ensures a fair distribution of buffers, when two AIMs share a single channel. The AIMs then won't be able to use more than half of all pre-allocated buffers of the linked channel. However, in case the channel is not shared, the AIM can exclusively use all available buffers. Signed-off-by: Andrey Shvetsov <andrey.shvetsov@k2l.de> Signed-off-by: Christian Gromm <christian.gromm@microchip.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-09-29staging: most: consolidate codeChristian Gromm
The function drci_rd_reg() always delivers little endian representation of the 16-bit DCI register. The value returned by this function must always be carefully converted from __le16 to u16 type. This patch moves all those conversions to the function itself. Signed-off-by: Andrey Shvetsov <andrey.shvetsov@k2l.de> Signed-off-by: Christian Gromm <christian.gromm@microchip.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-09-29staging: most: prevent DMA on stackChristian Gromm
This patch is needed to avoid having DMA on the stack. Signed-off-by: Andrey Shvetsov <andrey.shvetsov@k2l.de> Signed-off-by: Christian Gromm <christian.gromm@microchip.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-09-29staging: most: simplify codeChristian Gromm
This patch simply rearranges code for better readability. Signed-off-by: Andrey Shvetsov <andrey.shvetsov@k2l.de> Signed-off-by: Christian Gromm <christian.gromm@microchip.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-09-29staging: most: fix MAC address representationChristian Gromm
This patch fixes the representation of the MAC address within the HDM USB module. Signed-off-by: Andrey Shvetsov <andrey.shvetsov@k2l.de> Signed-off-by: Christian Gromm <christian.gromm@microchip.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-09-29staging: most: fix buffer size for DIM2Christian Gromm
This patch reduces the DBR buffer size to prevent an overflow in the DIM2 module. It is needed, because the MediaLB hardware has problems with DBR buffers that exceed the size of 255 messages. Signed-off-by: Andrey Shvetsov <andrey.shvetsov@k2l.de> Signed-off-by: Christian Gromm <christian.gromm@microchip.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>