Re: [PATCH 1/2] gpio: mediatek: add driver for MT7621

2018-06-08 Thread Sergio Paracuellos
On Fri, Jun 8, 2018 at 1:59 PM, Linus Walleij wrote: > Hi Sergio! > > Thanks for your patch! Hi Linus, First of all, thanks for your feedback and effort reviewing this. > > On Sat, Jun 2, 2018 at 9:30 AM, Sergio Paracuellos > wrote: > >> Add driver support for gpio of MT7621 SoC. >> >>

Re: [PATCH] staging: fwserial: fix checkpatch alignment check

2018-06-08 Thread Abdul Rauf
On Mon, Jun 4, 2018 at 10:18 PM Dan Carpenter wrote: > > On Sun, Jan 01, 2017 at 01:00:59AM +, Abdul Rauf wrote: > > Fix the following checks: > > Alignment should match open parenthesis. > > > > Signed-off-by: Abdul Rauf > > --- > > drivers/staging/fwserial/fwserial.c | 5 +++-- > > 1 file

Re: [PATCH] Fixed coding style problems.

2018-06-08 Thread Dan Carpenter
The subject should be: [PATCH] staging: comedi: shorten a long line or something. You need the subsystem prefix. Try not to be vague. On Fri, Jun 08, 2018 at 08:52:37PM +0200, Chris Opperman wrote: > This patch fixes a coding style problem in drivers/staging/comedi/drivers.c > and is

[PATCH v5] Drivers: HV: Send one page worth of kmsg dump over Hyper-V during panic

2018-06-08 Thread Sunil Muthuswamy
In the VM mode on Hyper-V, currently, when the kernel panics, an error code and few register values are populated in an MSR and the Hypervisor notified. This information is collected on the host. The amount of information currently collected is found to be limited and not very actionable. To

[PATCH] Fixed coding style problems.

2018-06-08 Thread Chris Opperman
This patch fixes a coding style problem in drivers/staging/comedi/drivers.c and is submitted for task 10 of the eudyptula challenge. Signed-off-by: Chris Opperman --- drivers/staging/comedi/drivers.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git

[PATCH v7 8/8] staging: rtl8192e: remove unnecessary parentheses - Coding Style

2018-06-08 Thread John Whitmore
Remove unneccessary parentheses, and removed unnecessary (void *) cast Signed-off-by: John Whitmore --- drivers/staging/rtl8192u/ieee80211/rtl819x_HTProc.c | 12 ++-- 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/drivers/staging/rtl8192u/ieee80211/rtl819x_HTProc.c

Re: [PATCH v6 8/8] staging: rtl8192e: remove unnecessary parentheses - Coding Style

2018-06-08 Thread John Whitmore
On Fri, Jun 08, 2018 at 03:18:51PM +0300, Dan Carpenter wrote: > On Wed, Jun 06, 2018 at 12:40:03PM +0100, John Whitmore wrote: > > @@ -1072,10 +1072,10 @@ void HTInitializeHTInfo(struct ieee80211_device > > *ieee) > > pHTInfo->CurrentAMPDUFactor = pHTInfo->AMPDU_Factor; > > > > //

Re: [PATCH v6 8/8] staging: rtl8192e: remove unnecessary parentheses - Coding Style

2018-06-08 Thread Dan Carpenter
On Wed, Jun 06, 2018 at 12:40:03PM +0100, John Whitmore wrote: > @@ -1072,10 +1072,10 @@ void HTInitializeHTInfo(struct ieee80211_device *ieee) > pHTInfo->CurrentAMPDUFactor = pHTInfo->AMPDU_Factor; > > // Initialize all of the parameters related to 11n > - memset((void

[PATCH v2 11/18] staging: mt7621-pinctrl: make use of pinctrl_utils_free_map

2018-06-08 Thread Sergio Paracuellos
There was a custom 'rt2880_pinctrl_dt_free_map' function which it was doing the same as pinctrl_utils_free_map defined in 'pinctrl-utils.h' header file. Use it instead avoiding code duplications. Signed-off-by: Sergio Paracuellos --- drivers/staging/mt7621-pinctrl/pinctrl-rt2880.c | 16

Re: [PATCH 1/2] gpio: mediatek: add driver for MT7621

2018-06-08 Thread Linus Walleij
A second thought: On Fri, Jun 8, 2018 at 1:59 PM, Linus Walleij wrote: >> + select GPIOLIB_IRQCHIP > > You are not using this so I guess remove that line. (...) >> +static int >> +mediatek_gpio_to_irq(struct gpio_chip *chip, unsigned int pin) >> +{ >> + struct mtk_data *gpio_data =

[PATCH v2 07/18] staging: mt7621-pinctrl: avoid lines over 80 chars

2018-06-08 Thread Sergio Paracuellos
This commit silence checkpatch warnings about lines which exceeds 80 chars. Some devm_kzalloc has been modified with dev_kcalloc to get this lines more properly indented. Signed-off-by: Sergio Paracuellos --- drivers/staging/mt7621-pinctrl/pinctrl-rt2880.c | 34 +++-- 1 file

[PATCH v2 14/18] staging: mt7621-dts: use 'function' and 'group' for pinctrl bindings

2018-06-08 Thread Sergio Paracuellos
According to documentation 'pinctrl-bindings.txt' bindings 'group' and 'function' can be used directly. So replace all of them. Signed-off-by: Sergio Paracuellos --- drivers/staging/mt7621-dts/mt7621.dtsi | 48 +- 1 file changed, 24 insertions(+), 24 deletions(-)

[PATCH v2 01/18] staging: mt7621-pinctrl: add SPDX identifier

2018-06-08 Thread Sergio Paracuellos
It's good to have SPDX identifiers in driver files to make it easier to audit the kernel tree for correct licenses. Fix up the one of staging mt7621-pinctrl file to have a proper SPDX identifier, based on the license text in the file itself. The SPDX identifier is a legally binding shorthand,

[PATCH v2 16/18] staging: mt7621-pinctrl: use ternary operator return in rt2880_get_group_name

2018-06-08 Thread Sergio Paracuellos
Trivial change to have only one return in 'rt2880_get_group_name' function using a ternary operator instead of an if statement and two returns. Signed-off-by: Sergio Paracuellos --- drivers/staging/mt7621-pinctrl/pinctrl-rt2880.c | 5 + 1 file changed, 1 insertion(+), 4 deletions(-) diff

[PATCH v2 03/18] staging: mt7621-pinctrl: remove unnecessary 'out of memory' message

2018-06-08 Thread Sergio Paracuellos
Messages when memory allocation fails are not needed at all and checkpatch script complains about them. Remove one in this driver code. Signed-off-by: Sergio Paracuellos --- drivers/staging/mt7621-pinctrl/pinctrl-rt2880.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git

[PATCH v2 05/18] staging: mt7621-pinctrl: avoid space after if condition

2018-06-08 Thread Sergio Paracuellos
Adding spaces between if condition and parenthesis are not needed at all and checkpatch script complains about them. Fix one in driver code. Signed-off-by: Sergio Paracuellos --- drivers/staging/mt7621-pinctrl/pinctrl-rt2880.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git

[PATCH v2 17/18] staging: mt7621-pinctrl: remove 'rt2880_pinctrl_pin_dbg_show' callback

2018-06-08 Thread Sergio Paracuellos
The debug information provided by this function does not make sense at all, so just remove it. Signed-off-by: Sergio Paracuellos --- drivers/staging/mt7621-pinctrl/pinctrl-rt2880.c | 8 1 file changed, 8 deletions(-) diff --git a/drivers/staging/mt7621-pinctrl/pinctrl-rt2880.c

[PATCH v2 13/18] staging: mt7621-pinctrl: make use of pinctrl_utils_reserve_map

2018-06-08 Thread Sergio Paracuellos
Function rt2880_pinctrl_dt_node_to_map was using 'kzalloc' to reserve map memory. There is a 'pinctrl_utils_reserve_map' to do this function. Just use it. Signed-off-by: Sergio Paracuellos --- drivers/staging/mt7621-pinctrl/pinctrl-rt2880.c | 12 +--- 1 file changed, 9 insertions(+), 3

[PATCH v2 18/18] staging: mt7621-pinctrl: replace core_initcall_sync with module_platform_driver

2018-06-08 Thread Sergio Paracuellos
We don't really need initialization of this at such an early stage. Just use module_platform_driver to initialize this driver. Signed-off-by: Sergio Paracuellos --- drivers/staging/mt7621-pinctrl/pinctrl-rt2880.c | 7 +-- 1 file changed, 1 insertion(+), 6 deletions(-) diff --git

[PATCH v2 12/18] staging: mt7621-pinctrl: replace uint8_t type with u8 for 'gpio' field

2018-06-08 Thread Sergio Paracuellos
Struct 'rt2880_priv' contains a field 'gpio' which is defined as uint8_t and should be defined with 'u8' which is preferred. Update some cast along the code related with this new change. Signed-off-by: Sergio Paracuellos --- drivers/staging/mt7621-pinctrl/pinctrl-rt2880.c | 7 +++ 1 file

[PATCH v2 00/18] staging: mt7621-pinctrl: some cleanups

2018-06-08 Thread Sergio Paracuellos
This patch series make some cleanups for this driver: - different checkpatch issues - Avoid code duplication using some stuff from pinctrl utils - Some trivial refactors Neil, I will send bindings documentation for this, but appart of that it would be nice if you could point me out other

[PATCH v2 10/18] staging: mt7621-pinctrl: use tabs instead of spaces in some indentations

2018-06-08 Thread Sergio Paracuellos
Kernel coding style use tabs for indent code instead of spaces. Fix some places where spaces were being used silencing also checkpatch script complains. Signed-off-by: Sergio Paracuellos --- drivers/staging/mt7621-pinctrl/pinctrl-rt2880.c | 6 +++--- 1 file changed, 3 insertions(+), 3

[PATCH v2 15/18] staging: mt7621-pinctrl: refactor rt2880_pinctrl_dt_node_to_map function

2018-06-08 Thread Sergio Paracuellos
Using 'function' and 'group' bindings in the device tree give the posibility of refactor 'rt2880_pinctrl_dt_node_to_map' and simplify it a lot. Make use of 'for_each_node_with_property' function to count number of groups for the node and iterate over the groups using 'of_property_for_each_string'

[PATCH v2 02/18] staging: mt7621-pinctrl: replace 'unsigned' types with 'unsigned int'

2018-06-08 Thread Sergio Paracuellos
This commit replaces all 'unsigned' type declarations along the driver code in favour of the preferred one 'unsigned int'. This also silence checkpatch script warnings about this issue. Signed-off-by: Sergio Paracuellos --- drivers/staging/mt7621-pinctrl/pinctrl-rt2880.c | 27

[PATCH v2 09/18] staging: mt7621-pinctrl: align function parameters in some functions

2018-06-08 Thread Sergio Paracuellos
Function parameters along the code has different alignment styles. Just unify all of them making style consistent. Signed-off-by: Sergio Paracuellos --- drivers/staging/mt7621-pinctrl/pinctrl-rt2880.c | 29 - 1 file changed, 14 insertions(+), 15 deletions(-) diff --git

[PATCH v2 04/18] staging: mt7621-pinctrl: replace ENOSYS with better fitting error code

2018-06-08 Thread Sergio Paracuellos
This commit replaces ENOSYS return with ENOTSUPP silencing the following checkpatch warning: WARNING: ENOSYS means 'invalid syscall nr' and nothing else Signed-off-by: Sergio Paracuellos --- drivers/staging/mt7621-pinctrl/pinctrl-rt2880.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)

[PATCH v2 08/18] staging: mt7621-pinctrl: replace seq_printf with seq_puts

2018-06-08 Thread Sergio Paracuellos
For a constant format without additional arguments, use seq_puts() instead of seq_printf() fixing also the following checkpatch.pl warning: 'Prefer seq_puts to seq_printf' Signed-off-by: Sergio Paracuellos --- drivers/staging/mt7621-pinctrl/pinctrl-rt2880.c | 2 +- 1 file changed, 1

[PATCH v2 06/18] staging: mt7621-pinctrl: add space in function call parameter list

2018-06-08 Thread Sergio Paracuellos
Call to kernel function 'devm_kzalloc' has no space between one of its parameters and checkpatch script complains about. Fix it. Signed-off-by: Sergio Paracuellos --- drivers/staging/mt7621-pinctrl/pinctrl-rt2880.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git

Re: [PATCH 07/18] staging: mt7621-pinctrl: avoid lines over 80 chars

2018-06-08 Thread Sergio Paracuellos
On Fri, Jun 08, 2018 at 02:27:54PM +0300, Dan Carpenter wrote: > Hm... It's sort of a big headache to resend this one. Forget about it. > > Eventually you will want to change to devm_kcalloc() though. I have to send v2 finally because I realized that there are two things that have to be

Re: [PATCH 1/2] gpio: mediatek: add driver for MT7621

2018-06-08 Thread Linus Walleij
Hi Sergio! Thanks for your patch! Given that we have combined pin control and GPIO drivers for almost all Mediatek chips in drivers/pinctrl/mediatek/* I would ideally like to have some input from the Mediatek maintainers (especially Sean Wang) on this, especially: - Is MT7621 a non-pincontrol

Re: [PATCH 07/18] staging: mt7621-pinctrl: avoid lines over 80 chars

2018-06-08 Thread Dan Carpenter
Hm... It's sort of a big headache to resend this one. Forget about it. Eventually you will want to change to devm_kcalloc() though. regards, dan carpenter ___ devel mailing list de...@linuxdriverproject.org

Re: [PATCH 07/18] staging: mt7621-pinctrl: avoid lines over 80 chars

2018-06-08 Thread Sergio Paracuellos
On Fri, Jun 08, 2018 at 02:20:20PM +0300, Dan Carpenter wrote: > On Thu, Jun 07, 2018 at 01:00:48PM +0200, Sergio Paracuellos wrote: > > This commit silence checkpatch warnings about lines which > > exceeds 80 chars. In some cases to improve code redability > > temporal 'size' variable has been

Re: [PATCH 07/18] staging: mt7621-pinctrl: avoid lines over 80 chars

2018-06-08 Thread Dan Carpenter
On Thu, Jun 07, 2018 at 01:00:48PM +0200, Sergio Paracuellos wrote: > This commit silence checkpatch warnings about lines which > exceeds 80 chars. In some cases to improve code redability > temporal 'size' variable has been included and assigned before > allocations. I would argue that it

Re: [PATCH] staging: rtl8192u: remove redundant variables

2018-06-08 Thread Dan Carpenter
On Fri, Jun 08, 2018 at 03:39:06PM +0800, Kenneth Lu wrote: > @@ -1017,7 +1016,6 @@ static void rtl8192_hard_data_xmit(struct sk_buff *skb, > struct net_device *dev, > *(struct net_device **)(skb->cb) = dev; > tcb_desc->bTxEnableFwCalcDur = 1; > skb_push(skb,

Re: [PATCH 2/4] Staging:rtl8192e Fix Comparison to False is error prone

2018-06-08 Thread Dan Carpenter
On Fri, Jun 08, 2018 at 12:33:56AM -0400, Janani Sankara Babu wrote: > This patch removes comparison to False(ie. bool) in the code > > Signed-off-by: Janani Sankara Babu > --- > drivers/staging/rtl8192e/rtl819x_BAProc.c | 10 +- > 1 file changed, 5 insertions(+), 5 deletions(-) > >

[PATCH] staging: rtl8192u: remove redundant variables

2018-06-08 Thread Kenneth Lu
Clean up W=1 warning: variable set but not used. Signed-off-by: Kenneth Lu --- drivers/staging/rtl8192u/ieee80211/ieee80211_rx.c | 2 -- drivers/staging/rtl8192u/r8192U_core.c| 11 +-- drivers/staging/rtl8192u/r8192U_dm.c | 3 +-- 3 files changed, 2

Re: Do Qualcomm drivers use DMA buffers for request_firmware_into_buf()?

2018-06-08 Thread Vlastimil Babka
On 06/07/2018 06:33 PM, Greg Kroah-Hartman wrote: > On Thu, Jun 07, 2018 at 06:23:01PM +0200, Ard Biesheuvel wrote: >> On 7 June 2018 at 18:18, Bjorn Andersson wrote: >>> On Wed 06 Jun 13:32 PDT 2018, Luis R. Rodriguez wrote: >>> On Fri, Jun 01, 2018 at 09:23:46PM +0200, Luis R. Rodriguez