mirror of
https://github.com/hardkernel/linux.git
synced 2026-06-05 18:41:58 +09:00
9p/xen: fix init sequence
[ Upstream commit 7ef3ae82a6ebbf4750967d1ce43bcdb7e44ff74b ]
Large amount of mount hangs observed during hotplugging of 9pfs devices. The
9pfs Xen driver attempts to initialize itself more than once, causing the
frontend and backend to disagree: the backend listens on a channel that the
frontend does not send on, resulting in stalled processing.
Only allow initialization of 9p frontend once.
Fixes: c15fe55d14 ("9p/xen: fix connection sequence")
Signed-off-by: Alex Zenla <alex@edera.dev>
Signed-off-by: Alexander Merritt <alexander@edera.dev>
Signed-off-by: Ariadne Conill <ariadne@ariadne.space>
Reviewed-by: Juergen Gross <jgross@suse.com>
Message-ID: <20241119211633.38321-1-alexander@edera.dev>
Signed-off-by: Dominique Martinet <asmadeus@codewreck.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
This commit is contained in:
committed by
Greg Kroah-Hartman
parent
c375804cf5
commit
91b4763da3
@@ -465,6 +465,7 @@ static int xen_9pfs_front_init(struct xenbus_device *dev)
|
|||||||
goto error;
|
goto error;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
xenbus_switch_state(dev, XenbusStateInitialised);
|
||||||
return 0;
|
return 0;
|
||||||
|
|
||||||
error_xenbus:
|
error_xenbus:
|
||||||
@@ -512,8 +513,10 @@ static void xen_9pfs_front_changed(struct xenbus_device *dev,
|
|||||||
break;
|
break;
|
||||||
|
|
||||||
case XenbusStateInitWait:
|
case XenbusStateInitWait:
|
||||||
if (!xen_9pfs_front_init(dev))
|
if (dev->state != XenbusStateInitialising)
|
||||||
xenbus_switch_state(dev, XenbusStateInitialised);
|
break;
|
||||||
|
|
||||||
|
xen_9pfs_front_init(dev);
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case XenbusStateConnected:
|
case XenbusStateConnected:
|
||||||
|
|||||||
Reference in New Issue
Block a user