]> git.baikalelectronics.ru Git - kernel.git/commit
vfio/ccw: Do not change FSM state in subchannel event
authorEric Farman <farman@linux.ibm.com>
Thu, 7 Jul 2022 13:57:29 +0000 (15:57 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 17 Aug 2022 12:24:06 +0000 (14:24 +0200)
commit5934f604e7bf9d6ec263560c96a1e5a7e193d20d
treea7b6a87b0da0f9010a5d294033cb92de469c2d1c
parentc83bd8e9bd1febdd029dd314e33f360f63d0a4d8
vfio/ccw: Do not change FSM state in subchannel event

[ Upstream commit b0e6895db0a7ef594ea88f95803c2b15e90f1fc3 ]

The routine vfio_ccw_sch_event() is tasked with handling subchannel events,
specifically machine checks, on behalf of vfio-ccw. It correctly calls
cio_update_schib(), and if that fails (meaning the subchannel is gone)
it makes an FSM event call to mark the subchannel Not Operational.

If that worked, however, then it decides that if the FSM state was already
Not Operational (implying the subchannel just came back), then it should
simply change the FSM to partially- or fully-open.

Remove this trickery, since a subchannel returning will require more
probing than simply "oh all is well again" to ensure it works correctly.

Fixes: 14c50d87bb535 ("vfio: ccw: introduce a finite state machine")
Signed-off-by: Eric Farman <farman@linux.ibm.com>
Reviewed-by: Matthew Rosato <mjrosato@linux.ibm.com>
Link: https://lore.kernel.org/r/20220707135737.720765-4-farman@linux.ibm.com
Signed-off-by: Alex Williamson <alex.williamson@redhat.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/s390/cio/vfio_ccw_drv.c