rapidio: update asynchronous discovery initialization
authorAlexandre Bounine <alexandre.bounine@idt.com>
Wed, 10 Oct 2012 22:53:59 +0000 (15:53 -0700)
committerLinus Torvalds <torvalds@linux-foundation.org>
Wed, 10 Oct 2012 23:50:15 +0000 (08:50 +0900)
commit2574740d1fe946803caa6b0c06fbb4bf397af35d
tree50bdf80ba048dd462f3b23f13a7f636401448565
parentf4c9c0e83bdfab6d3de7bc9ad728d99bf6adde92
rapidio: update asynchronous discovery initialization

Update discovery process initialization based on Andrew Morton's comments:
https://lkml.org/lkml/2012/10/3/552.

This update processes all enumerating mports first and schedules discovery
work after that. If the initialization routine fails to allocate resources
needed to execute discovery, it abandons discovery for all ports.

Signed-off-by: Alexandre Bounine <alexandre.bounine@idt.com>
Cc: Matt Porter <mporter@kernel.crashing.org>
Cc: Li Yang <leoli@freescale.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
drivers/rapidio/rio.c