common/octeontx2: fix crash on running procinfo
authorHarman Kalra <hkalra@marvell.com>
Mon, 29 Jun 2020 13:26:05 +0000 (18:56 +0530)
committerFerruh Yigit <ferruh.yigit@intel.com>
Tue, 7 Jul 2020 21:38:26 +0000 (23:38 +0200)
commit43330c4de3c768f6eedbc544f410ccff06b531a2
tree817e27e3bc3b354b9d2753c08e24fa1dcd0aba62
parent1feb8e3f4e5c69071e5c461132a8b1bad05609af
common/octeontx2: fix crash on running procinfo

Segmentation fault has been observed while running procinfo
with reset options i.e. --stats-reset and --xstats-reset.
Reason is procinfo runs as a secondary process and tries to
hold a lock which is part of struct mdev, which was not
allocated as part of shared memory.

Fixes: 5ca59711f771 ("common/octeontx2: add mailbox base support infra")
Cc: stable@dpdk.org
Signed-off-by: Harman Kalra <hkalra@marvell.com>
Acked-by: Jerin Jacob <jerinj@marvell.com>
drivers/common/octeontx2/otx2_mbox.c