linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Alexander Holler <holler@ahsoftware.de>
To: linux-kernel@vger.kernel.org
Cc: linux-arm-kernel@lists.infradead.org, devicetree@vger.kernel.org,
	Greg KH <gregkh@linuxfoundation.org>,
	Russel King <linux@arm.linux.org.uk>,
	Andrew Morton <akpm@linux-foundation.org>,
	Grant Likely <grant.likely@linaro.org>,
	Tomeu Vizoso <tomeu.vizoso@collabora.com>
Subject: deps: update in regard to parallel initialization of static linked drivers
Date: Fri, 4 Sep 2015 11:18:18 +0200	[thread overview]
Message-ID: <55E961DA.5040009@ahsoftware.de> (raw)
In-Reply-To: <1440592108-3740-1-git-send-email-holler@ahsoftware.de>

Am 26.08.2015 um 14:28 schrieb Alexander Holler:
> Hello,

(...)

> Some numbers (5 boots on each board, without and with ordering drivers),
> all times are seconds.

(...)

> imx6q (armv7):
>
> unordered:
> 3.451998 3.418864 3.446952 3.429974 3.440996 (3.4377568)
> ordered:
> 3.538312 3.549019 3.538105 3.515916 3.555715 (3.5394134)

(...)

> Further improvements could be to initialize drivers in parallel (using
> multiple cores) and/or to use this stuff on x86 (ACPI) too (e.g. by using a
> minimal DT which just includes dependencies).

I've now made a quick implementation which uses multiple threads to 
initialize annotated drivers in parallel. It worked out of the box.

Here are the times (dmesg | grep Freeing) I've now measured on the imx6q 
(4 cores):

3.388273 3.399892 3.411615 3.410523 3.388802 (3.399821)

So it's now at least as fast as without ordering the drivers. Even on 
the one system where ordering didn't help without parallel 
initialization (likely because the unordered sequence of initcalls is 
already quiet good on that system, in comparison to the other systems 
I've tested).

And my current implementation for the parallel stuff is far from being 
perfect and can be optimized much more (enough to not post a patch 
here). In addition I've added another driver to my config since I 
measure the old times, so the new times are including one more 
initialization of a driver (it now calls 30 annotated (static linked) 
drivers at boot, most stuff is still in modules (and some not annotated 
static linked drivers) on that system).

Maybe this helps raising interest enough that someone else will test and 
maybe give some (reasonable, not about style) feedback on my patches.

> Regards,
>
> Alexander Holler


  parent reply	other threads:[~2015-09-04  9:18 UTC|newest]

Thread overview: 30+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-08-26 12:28 [PATCH 00/16] deps: deterministic driver initialization order Alexander Holler
2015-08-26 12:28 ` [PATCH 01/16] deps: dtc: Automatically add new property 'dependencies' which contains a list of referenced phandles Alexander Holler
2015-08-26 12:28 ` [PATCH 02/16] deps: dtc: Add option to print initialization order Alexander Holler
2015-08-26 12:28 ` [PATCH 03/16] deps: dtc: Add option to print dependency graph as dot (Graphviz) Alexander Holler
2015-08-26 12:28 ` [PATCH 04/16] deps: dtc: introduce new (virtual) property no-dependencies Alexander Holler
2015-08-26 12:28 ` [PATCH 05/16] deps: introduce initcalls annotated with a struct device_driver Alexander Holler
2015-08-26 12:28 ` [PATCH 06/16] deps: deterministic driver initialization sequence based on dependencies from the DT Alexander Holler
2015-08-26 12:28 ` [PATCH 07/16] deps: add debug configuration options Alexander Holler
2015-08-26 12:28 ` [PATCH 08/16] deps: dts: kirkwood: dockstar: add dependency ehci -> usb power regulator Alexander Holler
2015-08-26 12:28 ` [PATCH 09/16] deps: dts: imx6q: make some remote-endpoints non-dependencies Alexander Holler
2015-08-26 12:28 ` [PATCH 10/16] deps: dts: omap: beagle: " Alexander Holler
2015-08-26 12:28 ` [PATCH 11/16] deps: WIP: generic: annotate some initcalls Alexander Holler
2015-08-26 12:28 ` [PATCH 12/16] deps: WIP: imx: " Alexander Holler
2015-08-26 12:28 ` [PATCH 13/16] deps: WIP: omap: " Alexander Holler
2015-08-26 12:28 ` [PATCH 14/16] deps: WIP: kirkwood: " Alexander Holler
2015-08-26 12:28 ` [PATCH 15/16] mtd: mtdcore: fix initcall level Alexander Holler
2015-09-01 21:19   ` Brian Norris
2015-09-02  5:34     ` Alexander Holler
2015-09-04  4:00       ` Alexander Holler
2015-09-08 19:36         ` Alexander Holler
2015-08-26 12:28 ` [PATCH 16/16] phy: phy-core: " Alexander Holler
2015-09-18  6:16   ` Kishon Vijay Abraham I
2015-09-18  6:59     ` Alexander Holler
2015-08-27 19:01 ` [PATCH 00/16] deps: deterministic driver initialization order Alexander Holler
2015-08-27 19:15   ` Alexander Holler
2015-09-04  9:18 ` Alexander Holler [this message]
2015-09-09 18:35   ` [PATCH 0/2] deps: parallel initialization of (device-)drivers Alexander Holler
2015-09-09 18:35     ` [PATCH 1/2] " Alexander Holler
2015-09-09 18:35     ` [PATCH 2/2] deps: avoid multiple calls to memmove by just setting duplicates to 0 Alexander Holler
2015-09-14 19:53     ` [PATCH 0/2] deps: parallel initialization of (device-)drivers Alexander Holler

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=55E961DA.5040009@ahsoftware.de \
    --to=holler@ahsoftware.de \
    --cc=akpm@linux-foundation.org \
    --cc=devicetree@vger.kernel.org \
    --cc=grant.likely@linaro.org \
    --cc=gregkh@linuxfoundation.org \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux@arm.linux.org.uk \
    --cc=tomeu.vizoso@collabora.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).