Re: [systemd-devel] Slow firmware timeouts again (Re: [3.11 regression?] iwlwifi firmware takes two minutes to load)

2013-08-05 Thread Kay Sievers
On Fri, Aug 2, 2013 at 6:28 PM, Zbigniew Jędrzejewski-Szmek
zbys...@in.waw.pl wrote:
 On Fri, Aug 02, 2013 at 09:04:44AM -0700, Andy Lutomirski wrote:
 CONFIG_FW_LOADER_USER_HELPER=y
 Do you need this? Unsetting this should help.

 This option enables / disables the invocation of user-helper
 (e.g. udev) for loading firmware files as a fallback after the
 direct file loading in kernel fails. The user-mode helper is
 no longer required unless you have a special firmware file that
 resides in a non-standard path.

On recent systems, if the kernel configures
CONFIG_FW_LOADER_USER_HELPER=y and a firmware is not found by the
kernel, the kernel will issue a request which is ignored by userspace
and will block in that for 60 seconds.

Udev is no longer in the game of firmware loading, not even as a
fallback, it will just completely ignore all kernel firmware class
events.

The source code in udev to handle firmware requests is disabled by
default, currently still kept around for old kernels without the
in-kernel firmware loader, but it will be deleted in the near future.

Any issues with firmware timeouts should be addressed in the kernel by
disabling CONFIG_FW_LOADER_USER_HELPER or by removing the fallback
code from the in-kernel loader.

Kay
___
systemd-devel mailing list
systemd-devel@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/systemd-devel


Re: [systemd-devel] Slow firmware timeouts again (Re: [3.11 regression?] iwlwifi firmware takes two minutes to load)

2013-08-05 Thread Andy Lutomirski
On Mon, Aug 5, 2013 at 4:18 AM, Kay Sievers k...@vrfy.org wrote:
 On Fri, Aug 2, 2013 at 6:28 PM, Zbigniew Jędrzejewski-Szmek
 zbys...@in.waw.pl wrote:
 On Fri, Aug 02, 2013 at 09:04:44AM -0700, Andy Lutomirski wrote:
 CONFIG_FW_LOADER_USER_HELPER=y
 Do you need this? Unsetting this should help.

 This option enables / disables the invocation of user-helper
 (e.g. udev) for loading firmware files as a fallback after the
 direct file loading in kernel fails. The user-mode helper is
 no longer required unless you have a special firmware file that
 resides in a non-standard path.

 On recent systems, if the kernel configures
 CONFIG_FW_LOADER_USER_HELPER=y and a firmware is not found by the
 kernel, the kernel will issue a request which is ignored by userspace
 and will block in that for 60 seconds.

 Udev is no longer in the game of firmware loading, not even as a
 fallback, it will just completely ignore all kernel firmware class
 events.

 The source code in udev to handle firmware requests is disabled by
 default, currently still kept around for old kernels without the
 in-kernel firmware loader, but it will be deleted in the near future.

Any chance you'd consider a less regression-inducing path to getting
rid of this feature?  For example, have udev warn and immediate fail
firmware loading requests for a few releases, then just warn, then
drop support?

Meanwhile, CONFIG_FW_LOADER_USER_HELPER is still default y (!), so
udev has introduced massive bootup delays into the default
configuration with no warning.  It might be nice to change it to
default n, get rid of everything that selects it, and possible even
rename it to something with LEGACY or OBSOLETE in the name so that
make oldconfig will prompt.

--Andy


 Any issues with firmware timeouts should be addressed in the kernel by
 disabling CONFIG_FW_LOADER_USER_HELPER or by removing the fallback
 code from the in-kernel loader.

 Kay



-- 
Andy Lutomirski
AMA Capital Management, LLC
___
systemd-devel mailing list
systemd-devel@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/systemd-devel


[systemd-devel] Slow firmware timeouts again (Re: [3.11 regression?] iwlwifi firmware takes two minutes to load)

2013-08-02 Thread Andy Lutomirski
[cc: linux-kernel, linux-hotplug, and systemd-devel.  This is 3.11-rc3+]

On Fri, Aug 2, 2013 at 12:38 AM, Johannes Berg
johan...@sipsolutions.net wrote:
 On Thu, 2013-08-01 at 21:38 -0700, Andy Lutomirski wrote:
 At boot, I get:
 [   12.537108] iwlwifi :03:00.0: irq 51 for MSI/MSI-X
 ...
 [  132.676781] iwlwifi :03:00.0: loaded firmware version 9.221.4.1
 build 25532 op_mode iwldvm

 This sounds familiar, but wasn't it fixed awhile ago?

 It wasn't exactly fixed and it's really more of a userspace problem - we
 probably request firmware version 8, and then it takes 30 seconds to
 time out for each of 8,7,6,5, after which the next request for 4 is
 successful.

Why's it requesting those firmwares?  They don't seem to exist on
intellinuxwireless.org.

I have:

CONFIG_FW_LOADER=y
# CONFIG_FIRMWARE_IN_KERNEL is not set
CONFIG_EXTRA_FIRMWARE=
CONFIG_FW_LOADER_USER_HELPER=y



 I don't know why your userspace isn't behaving differently though.

 johannes




-- 
Andy Lutomirski
AMA Capital Management, LLC
___
systemd-devel mailing list
systemd-devel@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/systemd-devel


Re: [systemd-devel] Slow firmware timeouts again (Re: [3.11 regression?] iwlwifi firmware takes two minutes to load)

2013-08-02 Thread Andy Lutomirski
On Fri, Aug 2, 2013 at 9:21 AM, Johannes Berg johan...@sipsolutions.net wrote:
 On Fri, 2013-08-02 at 09:04 -0700, Andy Lutomirski wrote:

  It wasn't exactly fixed and it's really more of a userspace problem - we
  probably request firmware version 8, and then it takes 30 seconds to
  time out for each of 8,7,6,5, after which the next request for 4 is
  successful.

 Why's it requesting those firmwares?  They don't seem to exist on
 intellinuxwireless.org.

 Well for one you've never even mentioned what device you have, and then
 also it's not requesting 8/7 only 6,5,4 -- I guess the timeout was
 increased to 60 seconds (or I'm remembering wrong and it always was? I
 thought it was 30s)

I have an Ultimate-N 6300 (rev 35).  It's requesting at least
versions 6 and 5 (I saw them in udevadm monitor).  It looks like the
g2a and g2b variants have -5 and -6 versions, but 6000-4 appears to be
the only relevant version for my hardware.
___
systemd-devel mailing list
systemd-devel@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/systemd-devel


Re: [systemd-devel] Slow firmware timeouts again (Re: [3.11 regression?] iwlwifi firmware takes two minutes to load)

2013-08-02 Thread Zbigniew Jędrzejewski-Szmek
On Fri, Aug 02, 2013 at 09:04:44AM -0700, Andy Lutomirski wrote:
 CONFIG_FW_LOADER_USER_HELPER=y
Do you need this? Unsetting this should help.

This option enables / disables the invocation of user-helper
(e.g. udev) for loading firmware files as a fallback after the
direct file loading in kernel fails. The user-mode helper is
no longer required unless you have a special firmware file that
resides in a non-standard path.

Zbyszek
-- 
they are not broken. they are refucktored
   -- alxchk
___
systemd-devel mailing list
systemd-devel@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/systemd-devel