IB/mlx4: Fix race condition between catas error reset and aliasguid flows
authorJack Morgenstein <jackm@dev.mellanox.co.il>
Wed, 6 Mar 2019 17:17:56 +0000 (19:17 +0200)
committerJason Gunthorpe <jgg@mellanox.com>
Mon, 18 Mar 2019 00:40:39 +0000 (21:40 -0300)
commit587443e7773e150ae29e643ee8f41a1eed226565
tree851813ef0a0e44fee9e783dcbdad3565121e5045
parent9e98c678c2d6ae3a17cb2de55d17f69dddaa231b
IB/mlx4: Fix race condition between catas error reset and aliasguid flows

Code review revealed a race condition which could allow the catas error
flow to interrupt the alias guid query post mechanism at random points.
Thiis is fixed by doing cancel_delayed_work_sync() instead of
cancel_delayed_work() during the alias guid mechanism destroy flow.

Fixes: a0c64a17aba8 ("mlx4: Add alias_guid mechanism")
Signed-off-by: Jack Morgenstein <jackm@dev.mellanox.co.il>
Signed-off-by: Leon Romanovsky <leonro@mellanox.com>
Signed-off-by: Jason Gunthorpe <jgg@mellanox.com>
drivers/infiniband/hw/mlx4/alias_GUID.c