All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] ARM: exynos_defconfig: Enable WiFi-Ex as a module instead built-in
@ 2015-09-29 12:42 ` Javier Martinez Canillas
  0 siblings, 0 replies; 14+ messages in thread
From: Javier Martinez Canillas @ 2015-09-29 12:42 UTC (permalink / raw)
  To: linux-kernel
  Cc: Mauro Carvalho Chehab, Javier Martinez Canillas, Kukjin Kim,
	Thierry Reding, Anand Moon, Russell King, linux-samsung-soc,
	Krzysztof Kozlowski, Andreas Faerber, Lukasz Majewski,
	linux-arm-kernel

The Marvell WiFi-Ex driver tries to load a firmware on probe. So if the
driver is built-in and probed before a firmware is available, this is
not loaded and the chip does not work.

This happens for example if an initramfs isn't used since the driver is
probed before the root filesystem is mounted.

Change the default config since the driver isn't needed for machines to
boot and is more convenient to have it enabled as a module to avoid
requiring an initramfs or to have the firmware built into the kernel.

Signed-off-by: Javier Martinez Canillas <javier@osg.samsung.com>

---

 arch/arm/configs/exynos_defconfig | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/arch/arm/configs/exynos_defconfig b/arch/arm/configs/exynos_defconfig
index d4f6063d8a72..5aad617f02c7 100644
--- a/arch/arm/configs/exynos_defconfig
+++ b/arch/arm/configs/exynos_defconfig
@@ -64,8 +64,8 @@ CONFIG_SMSC911X=y
 CONFIG_USB_USBNET=y
 CONFIG_USB_NET_SMSC75XX=y
 CONFIG_USB_NET_SMSC95XX=y
-CONFIG_MWIFIEX=y
-CONFIG_MWIFIEX_SDIO=y
+CONFIG_MWIFIEX=m
+CONFIG_MWIFIEX_SDIO=m
 CONFIG_INPUT_EVDEV=y
 CONFIG_KEYBOARD_GPIO=y
 CONFIG_KEYBOARD_CROS_EC=y
-- 
2.4.3


^ permalink raw reply related	[flat|nested] 14+ messages in thread

* [PATCH] ARM: exynos_defconfig: Enable WiFi-Ex as a module instead built-in
@ 2015-09-29 12:42 ` Javier Martinez Canillas
  0 siblings, 0 replies; 14+ messages in thread
From: Javier Martinez Canillas @ 2015-09-29 12:42 UTC (permalink / raw)
  To: linux-arm-kernel

The Marvell WiFi-Ex driver tries to load a firmware on probe. So if the
driver is built-in and probed before a firmware is available, this is
not loaded and the chip does not work.

This happens for example if an initramfs isn't used since the driver is
probed before the root filesystem is mounted.

Change the default config since the driver isn't needed for machines to
boot and is more convenient to have it enabled as a module to avoid
requiring an initramfs or to have the firmware built into the kernel.

Signed-off-by: Javier Martinez Canillas <javier@osg.samsung.com>

---

 arch/arm/configs/exynos_defconfig | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/arch/arm/configs/exynos_defconfig b/arch/arm/configs/exynos_defconfig
index d4f6063d8a72..5aad617f02c7 100644
--- a/arch/arm/configs/exynos_defconfig
+++ b/arch/arm/configs/exynos_defconfig
@@ -64,8 +64,8 @@ CONFIG_SMSC911X=y
 CONFIG_USB_USBNET=y
 CONFIG_USB_NET_SMSC75XX=y
 CONFIG_USB_NET_SMSC95XX=y
-CONFIG_MWIFIEX=y
-CONFIG_MWIFIEX_SDIO=y
+CONFIG_MWIFIEX=m
+CONFIG_MWIFIEX_SDIO=m
 CONFIG_INPUT_EVDEV=y
 CONFIG_KEYBOARD_GPIO=y
 CONFIG_KEYBOARD_CROS_EC=y
-- 
2.4.3

^ permalink raw reply related	[flat|nested] 14+ messages in thread

* Re: [PATCH] ARM: exynos_defconfig: Enable WiFi-Ex as a module instead built-in
  2015-09-29 12:42 ` Javier Martinez Canillas
@ 2015-09-29 13:20   ` Andreas Färber
  -1 siblings, 0 replies; 14+ messages in thread
From: Andreas Färber @ 2015-09-29 13:20 UTC (permalink / raw)
  To: Javier Martinez Canillas, linux-kernel
  Cc: Mauro Carvalho Chehab, Kukjin Kim, Thierry Reding, Anand Moon,
	Russell King, linux-samsung-soc, Krzysztof Kozlowski,
	Lukasz Majewski, linux-arm-kernel

Am 29.09.2015 um 14:42 schrieb Javier Martinez Canillas:
> diff --git a/arch/arm/configs/exynos_defconfig b/arch/arm/configs/exynos_defconfig
> index d4f6063d8a72..5aad617f02c7 100644
> --- a/arch/arm/configs/exynos_defconfig
> +++ b/arch/arm/configs/exynos_defconfig
> @@ -64,8 +64,8 @@ CONFIG_SMSC911X=y
>  CONFIG_USB_USBNET=y
>  CONFIG_USB_NET_SMSC75XX=y
>  CONFIG_USB_NET_SMSC95XX=y
> -CONFIG_MWIFIEX=y
> -CONFIG_MWIFIEX_SDIO=y
> +CONFIG_MWIFIEX=m
> +CONFIG_MWIFIEX_SDIO=m
>  CONFIG_INPUT_EVDEV=y
>  CONFIG_KEYBOARD_GPIO=y
>  CONFIG_KEYBOARD_CROS_EC=y

Makes sense,

Reviewed-by: Andreas Färber <afaerber@suse.de>

What about multi_v7?

Cheers,
Andreas

-- 
SUSE Linux GmbH, Maxfeldstr. 5, 90409 Nürnberg, Germany
GF: Felix Imendörffer, Jane Smithard, Graham Norton; HRB 21284 (AG Nürnberg)

^ permalink raw reply	[flat|nested] 14+ messages in thread

* [PATCH] ARM: exynos_defconfig: Enable WiFi-Ex as a module instead built-in
@ 2015-09-29 13:20   ` Andreas Färber
  0 siblings, 0 replies; 14+ messages in thread
From: Andreas Färber @ 2015-09-29 13:20 UTC (permalink / raw)
  To: linux-arm-kernel

Am 29.09.2015 um 14:42 schrieb Javier Martinez Canillas:
> diff --git a/arch/arm/configs/exynos_defconfig b/arch/arm/configs/exynos_defconfig
> index d4f6063d8a72..5aad617f02c7 100644
> --- a/arch/arm/configs/exynos_defconfig
> +++ b/arch/arm/configs/exynos_defconfig
> @@ -64,8 +64,8 @@ CONFIG_SMSC911X=y
>  CONFIG_USB_USBNET=y
>  CONFIG_USB_NET_SMSC75XX=y
>  CONFIG_USB_NET_SMSC95XX=y
> -CONFIG_MWIFIEX=y
> -CONFIG_MWIFIEX_SDIO=y
> +CONFIG_MWIFIEX=m
> +CONFIG_MWIFIEX_SDIO=m
>  CONFIG_INPUT_EVDEV=y
>  CONFIG_KEYBOARD_GPIO=y
>  CONFIG_KEYBOARD_CROS_EC=y

Makes sense,

Reviewed-by: Andreas F?rber <afaerber@suse.de>

What about multi_v7?

Cheers,
Andreas

-- 
SUSE Linux GmbH, Maxfeldstr. 5, 90409 N?rnberg, Germany
GF: Felix Imend?rffer, Jane Smithard, Graham Norton; HRB 21284 (AG N?rnberg)

^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: [PATCH] ARM: exynos_defconfig: Enable WiFi-Ex as a module instead built-in
  2015-09-29 13:20   ` Andreas Färber
@ 2015-09-29 13:57     ` Javier Martinez Canillas
  -1 siblings, 0 replies; 14+ messages in thread
From: Javier Martinez Canillas @ 2015-09-29 13:57 UTC (permalink / raw)
  To: Andreas Färber, linux-kernel
  Cc: Mauro Carvalho Chehab, Kukjin Kim, Thierry Reding, Anand Moon,
	Russell King, linux-samsung-soc, Krzysztof Kozlowski,
	Lukasz Majewski, linux-arm-kernel

Hello Andreas,

On 09/29/2015 03:20 PM, Andreas Färber wrote:
> Am 29.09.2015 um 14:42 schrieb Javier Martinez Canillas:
>> diff --git a/arch/arm/configs/exynos_defconfig b/arch/arm/configs/exynos_defconfig
>> index d4f6063d8a72..5aad617f02c7 100644
>> --- a/arch/arm/configs/exynos_defconfig
>> +++ b/arch/arm/configs/exynos_defconfig
>> @@ -64,8 +64,8 @@ CONFIG_SMSC911X=y
>>  CONFIG_USB_USBNET=y
>>  CONFIG_USB_NET_SMSC75XX=y
>>  CONFIG_USB_NET_SMSC95XX=y
>> -CONFIG_MWIFIEX=y
>> -CONFIG_MWIFIEX_SDIO=y
>> +CONFIG_MWIFIEX=m
>> +CONFIG_MWIFIEX_SDIO=m
>>  CONFIG_INPUT_EVDEV=y
>>  CONFIG_KEYBOARD_GPIO=y
>>  CONFIG_KEYBOARD_CROS_EC=y
> 
> Makes sense,
> 
> Reviewed-by: Andreas Färber <afaerber@suse.de>
> 

Thanks.

> What about multi_v7?
>

Already enables these options as a module.
 
> Cheers,
> Andreas
> 

Best regards,
-- 
Javier Martinez Canillas
Open Source Group
Samsung Research America

^ permalink raw reply	[flat|nested] 14+ messages in thread

* [PATCH] ARM: exynos_defconfig: Enable WiFi-Ex as a module instead built-in
@ 2015-09-29 13:57     ` Javier Martinez Canillas
  0 siblings, 0 replies; 14+ messages in thread
From: Javier Martinez Canillas @ 2015-09-29 13:57 UTC (permalink / raw)
  To: linux-arm-kernel

Hello Andreas,

On 09/29/2015 03:20 PM, Andreas F?rber wrote:
> Am 29.09.2015 um 14:42 schrieb Javier Martinez Canillas:
>> diff --git a/arch/arm/configs/exynos_defconfig b/arch/arm/configs/exynos_defconfig
>> index d4f6063d8a72..5aad617f02c7 100644
>> --- a/arch/arm/configs/exynos_defconfig
>> +++ b/arch/arm/configs/exynos_defconfig
>> @@ -64,8 +64,8 @@ CONFIG_SMSC911X=y
>>  CONFIG_USB_USBNET=y
>>  CONFIG_USB_NET_SMSC75XX=y
>>  CONFIG_USB_NET_SMSC95XX=y
>> -CONFIG_MWIFIEX=y
>> -CONFIG_MWIFIEX_SDIO=y
>> +CONFIG_MWIFIEX=m
>> +CONFIG_MWIFIEX_SDIO=m
>>  CONFIG_INPUT_EVDEV=y
>>  CONFIG_KEYBOARD_GPIO=y
>>  CONFIG_KEYBOARD_CROS_EC=y
> 
> Makes sense,
> 
> Reviewed-by: Andreas F?rber <afaerber@suse.de>
> 

Thanks.

> What about multi_v7?
>

Already enables these options as a module.
 
> Cheers,
> Andreas
> 

Best regards,
-- 
Javier Martinez Canillas
Open Source Group
Samsung Research America

^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: [PATCH] ARM: exynos_defconfig: Enable WiFi-Ex as a module instead built-in
  2015-09-29 12:42 ` Javier Martinez Canillas
@ 2015-09-30  0:36   ` Krzysztof Kozlowski
  -1 siblings, 0 replies; 14+ messages in thread
From: Krzysztof Kozlowski @ 2015-09-30  0:36 UTC (permalink / raw)
  To: Javier Martinez Canillas, linux-kernel
  Cc: Mauro Carvalho Chehab, Kukjin Kim, Thierry Reding, Anand Moon,
	Russell King, linux-samsung-soc, Andreas Faerber,
	Lukasz Majewski, linux-arm-kernel

On 29.09.2015 21:42, Javier Martinez Canillas wrote:
> The Marvell WiFi-Ex driver tries to load a firmware on probe. So if the
> driver is built-in and probed before a firmware is available, this is
> not loaded and the chip does not work.
> 
> This happens for example if an initramfs isn't used since the driver is
> probed before the root filesystem is mounted.
> 
> Change the default config since the driver isn't needed for machines to
> boot and is more convenient to have it enabled as a module to avoid
> requiring an initramfs or to have the firmware built into the kernel.
> 
> Signed-off-by: Javier Martinez Canillas <javier@osg.samsung.com>
> 
> ---
> 
>  arch/arm/configs/exynos_defconfig | 4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)

The user-space can always initiate re-probing of device - just re-bind
it. However I assume that driver cannot work without firmware?

Best regards,
Krzysztof

> 
> diff --git a/arch/arm/configs/exynos_defconfig b/arch/arm/configs/exynos_defconfig
> index d4f6063d8a72..5aad617f02c7 100644
> --- a/arch/arm/configs/exynos_defconfig
> +++ b/arch/arm/configs/exynos_defconfig
> @@ -64,8 +64,8 @@ CONFIG_SMSC911X=y
>  CONFIG_USB_USBNET=y
>  CONFIG_USB_NET_SMSC75XX=y
>  CONFIG_USB_NET_SMSC95XX=y
> -CONFIG_MWIFIEX=y
> -CONFIG_MWIFIEX_SDIO=y
> +CONFIG_MWIFIEX=m
> +CONFIG_MWIFIEX_SDIO=m
>  CONFIG_INPUT_EVDEV=y
>  CONFIG_KEYBOARD_GPIO=y
>  CONFIG_KEYBOARD_CROS_EC=y
> 


^ permalink raw reply	[flat|nested] 14+ messages in thread

* [PATCH] ARM: exynos_defconfig: Enable WiFi-Ex as a module instead built-in
@ 2015-09-30  0:36   ` Krzysztof Kozlowski
  0 siblings, 0 replies; 14+ messages in thread
From: Krzysztof Kozlowski @ 2015-09-30  0:36 UTC (permalink / raw)
  To: linux-arm-kernel

On 29.09.2015 21:42, Javier Martinez Canillas wrote:
> The Marvell WiFi-Ex driver tries to load a firmware on probe. So if the
> driver is built-in and probed before a firmware is available, this is
> not loaded and the chip does not work.
> 
> This happens for example if an initramfs isn't used since the driver is
> probed before the root filesystem is mounted.
> 
> Change the default config since the driver isn't needed for machines to
> boot and is more convenient to have it enabled as a module to avoid
> requiring an initramfs or to have the firmware built into the kernel.
> 
> Signed-off-by: Javier Martinez Canillas <javier@osg.samsung.com>
> 
> ---
> 
>  arch/arm/configs/exynos_defconfig | 4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)

The user-space can always initiate re-probing of device - just re-bind
it. However I assume that driver cannot work without firmware?

Best regards,
Krzysztof

> 
> diff --git a/arch/arm/configs/exynos_defconfig b/arch/arm/configs/exynos_defconfig
> index d4f6063d8a72..5aad617f02c7 100644
> --- a/arch/arm/configs/exynos_defconfig
> +++ b/arch/arm/configs/exynos_defconfig
> @@ -64,8 +64,8 @@ CONFIG_SMSC911X=y
>  CONFIG_USB_USBNET=y
>  CONFIG_USB_NET_SMSC75XX=y
>  CONFIG_USB_NET_SMSC95XX=y
> -CONFIG_MWIFIEX=y
> -CONFIG_MWIFIEX_SDIO=y
> +CONFIG_MWIFIEX=m
> +CONFIG_MWIFIEX_SDIO=m
>  CONFIG_INPUT_EVDEV=y
>  CONFIG_KEYBOARD_GPIO=y
>  CONFIG_KEYBOARD_CROS_EC=y
> 

^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: [PATCH] ARM: exynos_defconfig: Enable WiFi-Ex as a module instead built-in
  2015-09-30  0:36   ` Krzysztof Kozlowski
@ 2015-09-30  7:22     ` Javier Martinez Canillas
  -1 siblings, 0 replies; 14+ messages in thread
From: Javier Martinez Canillas @ 2015-09-30  7:22 UTC (permalink / raw)
  To: Krzysztof Kozlowski, linux-kernel
  Cc: Mauro Carvalho Chehab, Kukjin Kim, Thierry Reding, Anand Moon,
	Russell King, linux-samsung-soc, Andreas Faerber,
	Lukasz Majewski, linux-arm-kernel

Hello Krzysztof,

On 09/30/2015 02:36 AM, Krzysztof Kozlowski wrote:
> On 29.09.2015 21:42, Javier Martinez Canillas wrote:
>> The Marvell WiFi-Ex driver tries to load a firmware on probe. So if the
>> driver is built-in and probed before a firmware is available, this is
>> not loaded and the chip does not work.
>>
>> This happens for example if an initramfs isn't used since the driver is
>> probed before the root filesystem is mounted.
>>
>> Change the default config since the driver isn't needed for machines to
>> boot and is more convenient to have it enabled as a module to avoid
>> requiring an initramfs or to have the firmware built into the kernel.
>>
>> Signed-off-by: Javier Martinez Canillas <javier@osg.samsung.com>
>>
>> ---
>>
>>  arch/arm/configs/exynos_defconfig | 4 ++--
>>  1 file changed, 2 insertions(+), 2 deletions(-)
> 
> The user-space can always initiate re-probing of device - just re-bind

It is true that you can force a re-probing from user-space by doing:

$ echo "mmc2:0001:1" > /sys/bus/sdio/drivers/mwifiex_sdio/unbind
$ echo "mmc2:0001:1" > /sys/bus/sdio/drivers/mwifiex_sdio/bind

but:

a) This is not obvious. In fact, I didn't think that possibility
before you mentioned and I've been using Linux for many years :)

b) This is not something that isn't done automatically by init systems.

So what users will see is that the driver was probed successfully but
the firmware fails to load later (since the driver users the async
request_firmware_nowait function to request the firmware).

> it. However I assume that driver cannot work without firmware?
>

Yes, it doesn't. I explained this in the commit message. Do you
think it should be made more clear?
 
> Best regards,
> Krzysztof
> 

Best regards,
-- 
Javier Martinez Canillas
Open Source Group
Samsung Research America

^ permalink raw reply	[flat|nested] 14+ messages in thread

* [PATCH] ARM: exynos_defconfig: Enable WiFi-Ex as a module instead built-in
@ 2015-09-30  7:22     ` Javier Martinez Canillas
  0 siblings, 0 replies; 14+ messages in thread
From: Javier Martinez Canillas @ 2015-09-30  7:22 UTC (permalink / raw)
  To: linux-arm-kernel

Hello Krzysztof,

On 09/30/2015 02:36 AM, Krzysztof Kozlowski wrote:
> On 29.09.2015 21:42, Javier Martinez Canillas wrote:
>> The Marvell WiFi-Ex driver tries to load a firmware on probe. So if the
>> driver is built-in and probed before a firmware is available, this is
>> not loaded and the chip does not work.
>>
>> This happens for example if an initramfs isn't used since the driver is
>> probed before the root filesystem is mounted.
>>
>> Change the default config since the driver isn't needed for machines to
>> boot and is more convenient to have it enabled as a module to avoid
>> requiring an initramfs or to have the firmware built into the kernel.
>>
>> Signed-off-by: Javier Martinez Canillas <javier@osg.samsung.com>
>>
>> ---
>>
>>  arch/arm/configs/exynos_defconfig | 4 ++--
>>  1 file changed, 2 insertions(+), 2 deletions(-)
> 
> The user-space can always initiate re-probing of device - just re-bind

It is true that you can force a re-probing from user-space by doing:

$ echo "mmc2:0001:1" > /sys/bus/sdio/drivers/mwifiex_sdio/unbind
$ echo "mmc2:0001:1" > /sys/bus/sdio/drivers/mwifiex_sdio/bind

but:

a) This is not obvious. In fact, I didn't think that possibility
before you mentioned and I've been using Linux for many years :)

b) This is not something that isn't done automatically by init systems.

So what users will see is that the driver was probed successfully but
the firmware fails to load later (since the driver users the async
request_firmware_nowait function to request the firmware).

> it. However I assume that driver cannot work without firmware?
>

Yes, it doesn't. I explained this in the commit message. Do you
think it should be made more clear?
 
> Best regards,
> Krzysztof
> 

Best regards,
-- 
Javier Martinez Canillas
Open Source Group
Samsung Research America

^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: [PATCH] ARM: exynos_defconfig: Enable WiFi-Ex as a module instead built-in
  2015-09-30  7:22     ` Javier Martinez Canillas
@ 2015-09-30  7:37       ` Krzysztof Kozlowski
  -1 siblings, 0 replies; 14+ messages in thread
From: Krzysztof Kozlowski @ 2015-09-30  7:37 UTC (permalink / raw)
  To: Javier Martinez Canillas, linux-kernel
  Cc: Mauro Carvalho Chehab, Kukjin Kim, Thierry Reding, Anand Moon,
	Russell King, linux-samsung-soc, Andreas Faerber,
	Lukasz Majewski, linux-arm-kernel

On 30.09.2015 16:22, Javier Martinez Canillas wrote:
> Hello Krzysztof,
> 
> On 09/30/2015 02:36 AM, Krzysztof Kozlowski wrote:
>> On 29.09.2015 21:42, Javier Martinez Canillas wrote:
>>> The Marvell WiFi-Ex driver tries to load a firmware on probe. So if the
>>> driver is built-in and probed before a firmware is available, this is
>>> not loaded and the chip does not work.
>>>
>>> This happens for example if an initramfs isn't used since the driver is
>>> probed before the root filesystem is mounted.
>>>
>>> Change the default config since the driver isn't needed for machines to
>>> boot and is more convenient to have it enabled as a module to avoid
>>> requiring an initramfs or to have the firmware built into the kernel.
>>>
>>> Signed-off-by: Javier Martinez Canillas <javier@osg.samsung.com>
>>>
>>> ---
>>>
>>>  arch/arm/configs/exynos_defconfig | 4 ++--
>>>  1 file changed, 2 insertions(+), 2 deletions(-)
>>
>> The user-space can always initiate re-probing of device - just re-bind
> 
> It is true that you can force a re-probing from user-space by doing:
> 
> $ echo "mmc2:0001:1" > /sys/bus/sdio/drivers/mwifiex_sdio/unbind
> $ echo "mmc2:0001:1" > /sys/bus/sdio/drivers/mwifiex_sdio/bind

I suppose the unbind won't be needed, because device aborted the
probe... so only one another bind.

> 
> but:
> 
> a) This is not obvious. In fact, I didn't think that possibility
> before you mentioned and I've been using Linux for many years :)

Eh, questionable. Obvious for me :)

> 
> b) This is not something that isn't done automatically by init systems.

Right.

> 
> So what users will see is that the driver was probed successfully but
> the firmware fails to load later (since the driver users the async
> request_firmware_nowait function to request the firmware).

Okay.

> 
>> it. However I assume that driver cannot work without firmware?
>>
> 
> Yes, it doesn't. I explained this in the commit message. Do you
> think it should be made more clear?

No, its OK, I agree.

Reviewed-by: Krzysztof Kozlowski <k.kozlowski@samsung.com>

Best regards,
Krzysztof

^ permalink raw reply	[flat|nested] 14+ messages in thread

* [PATCH] ARM: exynos_defconfig: Enable WiFi-Ex as a module instead built-in
@ 2015-09-30  7:37       ` Krzysztof Kozlowski
  0 siblings, 0 replies; 14+ messages in thread
From: Krzysztof Kozlowski @ 2015-09-30  7:37 UTC (permalink / raw)
  To: linux-arm-kernel

On 30.09.2015 16:22, Javier Martinez Canillas wrote:
> Hello Krzysztof,
> 
> On 09/30/2015 02:36 AM, Krzysztof Kozlowski wrote:
>> On 29.09.2015 21:42, Javier Martinez Canillas wrote:
>>> The Marvell WiFi-Ex driver tries to load a firmware on probe. So if the
>>> driver is built-in and probed before a firmware is available, this is
>>> not loaded and the chip does not work.
>>>
>>> This happens for example if an initramfs isn't used since the driver is
>>> probed before the root filesystem is mounted.
>>>
>>> Change the default config since the driver isn't needed for machines to
>>> boot and is more convenient to have it enabled as a module to avoid
>>> requiring an initramfs or to have the firmware built into the kernel.
>>>
>>> Signed-off-by: Javier Martinez Canillas <javier@osg.samsung.com>
>>>
>>> ---
>>>
>>>  arch/arm/configs/exynos_defconfig | 4 ++--
>>>  1 file changed, 2 insertions(+), 2 deletions(-)
>>
>> The user-space can always initiate re-probing of device - just re-bind
> 
> It is true that you can force a re-probing from user-space by doing:
> 
> $ echo "mmc2:0001:1" > /sys/bus/sdio/drivers/mwifiex_sdio/unbind
> $ echo "mmc2:0001:1" > /sys/bus/sdio/drivers/mwifiex_sdio/bind

I suppose the unbind won't be needed, because device aborted the
probe... so only one another bind.

> 
> but:
> 
> a) This is not obvious. In fact, I didn't think that possibility
> before you mentioned and I've been using Linux for many years :)

Eh, questionable. Obvious for me :)

> 
> b) This is not something that isn't done automatically by init systems.

Right.

> 
> So what users will see is that the driver was probed successfully but
> the firmware fails to load later (since the driver users the async
> request_firmware_nowait function to request the firmware).

Okay.

> 
>> it. However I assume that driver cannot work without firmware?
>>
> 
> Yes, it doesn't. I explained this in the commit message. Do you
> think it should be made more clear?

No, its OK, I agree.

Reviewed-by: Krzysztof Kozlowski <k.kozlowski@samsung.com>

Best regards,
Krzysztof

^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: [PATCH] ARM: exynos_defconfig: Enable WiFi-Ex as a module instead built-in
  2015-09-30  7:37       ` Krzysztof Kozlowski
@ 2015-09-30  7:54         ` Javier Martinez Canillas
  -1 siblings, 0 replies; 14+ messages in thread
From: Javier Martinez Canillas @ 2015-09-30  7:54 UTC (permalink / raw)
  To: Krzysztof Kozlowski, linux-kernel
  Cc: Mauro Carvalho Chehab, Kukjin Kim, Thierry Reding, Anand Moon,
	Russell King, linux-samsung-soc, Andreas Faerber,
	Lukasz Majewski, linux-arm-kernel

Hello Krzysztof,

On 09/30/2015 09:37 AM, Krzysztof Kozlowski wrote:
> On 30.09.2015 16:22, Javier Martinez Canillas wrote:
>> Hello Krzysztof,
>>
>> On 09/30/2015 02:36 AM, Krzysztof Kozlowski wrote:
>>> On 29.09.2015 21:42, Javier Martinez Canillas wrote:
>>>> The Marvell WiFi-Ex driver tries to load a firmware on probe. So if the
>>>> driver is built-in and probed before a firmware is available, this is
>>>> not loaded and the chip does not work.
>>>>
>>>> This happens for example if an initramfs isn't used since the driver is
>>>> probed before the root filesystem is mounted.
>>>>
>>>> Change the default config since the driver isn't needed for machines to
>>>> boot and is more convenient to have it enabled as a module to avoid
>>>> requiring an initramfs or to have the firmware built into the kernel.
>>>>
>>>> Signed-off-by: Javier Martinez Canillas <javier@osg.samsung.com>
>>>>
>>>> ---
>>>>
>>>>  arch/arm/configs/exynos_defconfig | 4 ++--
>>>>  1 file changed, 2 insertions(+), 2 deletions(-)
>>>
>>> The user-space can always initiate re-probing of device - just re-bind
>>
>> It is true that you can force a re-probing from user-space by doing:
>>
>> $ echo "mmc2:0001:1" > /sys/bus/sdio/drivers/mwifiex_sdio/unbind
>> $ echo "mmc2:0001:1" > /sys/bus/sdio/drivers/mwifiex_sdio/bind
> 
> I suppose the unbind won't be needed, because device aborted the
> probe... so only one another bind.
>

Right, only the bind is needed indeed since the device is unbind
after the firmware loading fails. I just wanted to confirm that
I understood what you said before correctly.
 
>>
>> but:
>>
>> a) This is not obvious. In fact, I didn't think that possibility
>> before you mentioned and I've been using Linux for many years :)
> 
> Eh, questionable. Obvious for me :)
>

Fair enough, maybe is just me then :)
 
>>
>> b) This is not something that isn't done automatically by init systems.
>
> Right.

err, I wanted to say "is not something that is done automatically" but
fortunately you understood what I meant.

> 
>>
>> So what users will see is that the driver was probed successfully but
>> the firmware fails to load later (since the driver users the async
>> request_firmware_nowait function to request the firmware).
> 
> Okay.
> 
>>
>>> it. However I assume that driver cannot work without firmware?
>>>
>>
>> Yes, it doesn't. I explained this in the commit message. Do you
>> think it should be made more clear?
> 
> No, its OK, I agree.
> 
> Reviewed-by: Krzysztof Kozlowski <k.kozlowski@samsung.com>
>

Great, thanks a lot for your feedback and review!
 
> Best regards,
> Krzysztof

Best regards,
-- 
Javier Martinez Canillas
Open Source Group
Samsung Research America

^ permalink raw reply	[flat|nested] 14+ messages in thread

* [PATCH] ARM: exynos_defconfig: Enable WiFi-Ex as a module instead built-in
@ 2015-09-30  7:54         ` Javier Martinez Canillas
  0 siblings, 0 replies; 14+ messages in thread
From: Javier Martinez Canillas @ 2015-09-30  7:54 UTC (permalink / raw)
  To: linux-arm-kernel

Hello Krzysztof,

On 09/30/2015 09:37 AM, Krzysztof Kozlowski wrote:
> On 30.09.2015 16:22, Javier Martinez Canillas wrote:
>> Hello Krzysztof,
>>
>> On 09/30/2015 02:36 AM, Krzysztof Kozlowski wrote:
>>> On 29.09.2015 21:42, Javier Martinez Canillas wrote:
>>>> The Marvell WiFi-Ex driver tries to load a firmware on probe. So if the
>>>> driver is built-in and probed before a firmware is available, this is
>>>> not loaded and the chip does not work.
>>>>
>>>> This happens for example if an initramfs isn't used since the driver is
>>>> probed before the root filesystem is mounted.
>>>>
>>>> Change the default config since the driver isn't needed for machines to
>>>> boot and is more convenient to have it enabled as a module to avoid
>>>> requiring an initramfs or to have the firmware built into the kernel.
>>>>
>>>> Signed-off-by: Javier Martinez Canillas <javier@osg.samsung.com>
>>>>
>>>> ---
>>>>
>>>>  arch/arm/configs/exynos_defconfig | 4 ++--
>>>>  1 file changed, 2 insertions(+), 2 deletions(-)
>>>
>>> The user-space can always initiate re-probing of device - just re-bind
>>
>> It is true that you can force a re-probing from user-space by doing:
>>
>> $ echo "mmc2:0001:1" > /sys/bus/sdio/drivers/mwifiex_sdio/unbind
>> $ echo "mmc2:0001:1" > /sys/bus/sdio/drivers/mwifiex_sdio/bind
> 
> I suppose the unbind won't be needed, because device aborted the
> probe... so only one another bind.
>

Right, only the bind is needed indeed since the device is unbind
after the firmware loading fails. I just wanted to confirm that
I understood what you said before correctly.
 
>>
>> but:
>>
>> a) This is not obvious. In fact, I didn't think that possibility
>> before you mentioned and I've been using Linux for many years :)
> 
> Eh, questionable. Obvious for me :)
>

Fair enough, maybe is just me then :)
 
>>
>> b) This is not something that isn't done automatically by init systems.
>
> Right.

err, I wanted to say "is not something that is done automatically" but
fortunately you understood what I meant.

> 
>>
>> So what users will see is that the driver was probed successfully but
>> the firmware fails to load later (since the driver users the async
>> request_firmware_nowait function to request the firmware).
> 
> Okay.
> 
>>
>>> it. However I assume that driver cannot work without firmware?
>>>
>>
>> Yes, it doesn't. I explained this in the commit message. Do you
>> think it should be made more clear?
> 
> No, its OK, I agree.
> 
> Reviewed-by: Krzysztof Kozlowski <k.kozlowski@samsung.com>
>

Great, thanks a lot for your feedback and review!
 
> Best regards,
> Krzysztof

Best regards,
-- 
Javier Martinez Canillas
Open Source Group
Samsung Research America

^ permalink raw reply	[flat|nested] 14+ messages in thread

end of thread, other threads:[~2015-09-30  7:54 UTC | newest]

Thread overview: 14+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2015-09-29 12:42 [PATCH] ARM: exynos_defconfig: Enable WiFi-Ex as a module instead built-in Javier Martinez Canillas
2015-09-29 12:42 ` Javier Martinez Canillas
2015-09-29 13:20 ` Andreas Färber
2015-09-29 13:20   ` Andreas Färber
2015-09-29 13:57   ` Javier Martinez Canillas
2015-09-29 13:57     ` Javier Martinez Canillas
2015-09-30  0:36 ` Krzysztof Kozlowski
2015-09-30  0:36   ` Krzysztof Kozlowski
2015-09-30  7:22   ` Javier Martinez Canillas
2015-09-30  7:22     ` Javier Martinez Canillas
2015-09-30  7:37     ` Krzysztof Kozlowski
2015-09-30  7:37       ` Krzysztof Kozlowski
2015-09-30  7:54       ` Javier Martinez Canillas
2015-09-30  7:54         ` Javier Martinez Canillas

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.