mtd: rawnand: tmio: Do not abuse nand_controller->wq
authorBoris Brezillon <boris.brezillon@bootlin.com>
Tue, 20 Nov 2018 10:57:17 +0000 (11:57 +0100)
committerMiquel Raynal <miquel.raynal@bootlin.com>
Tue, 5 Feb 2019 14:39:40 +0000 (15:39 +0100)
commita0916c94e9143e8aa0a1fe2a64794041657e99ac
treef462e510eade4ad73c180755e2fc6893c6d4f70c
parentb5c2defc026148c4d1e936e3bf26e49bd7e02dce
mtd: rawnand: tmio: Do not abuse nand_controller->wq

nand_controller->wq has never been meant to be used by NAND controller
drivers. This waitqueue is used by the framework to serialize accesses
to a NAND controller, and messing up with its state is a really bad
idea.

Declare a completion object in tmio_nand and use it to wait for RB
transitions.

Signed-off-by: Boris Brezillon <boris.brezillon@bootlin.com>
Signed-off-by: Miquel Raynal <miquel.raynal@bootlin.com>
drivers/mtd/nand/raw/tmio_nand.c