s390/sthyi: Fix machine name validity indication
authorJanosch Frank <frankja@linux.ibm.com>
Tue, 2 Oct 2018 08:57:52 +0000 (10:57 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Tue, 13 Nov 2018 19:14:52 +0000 (11:14 -0800)
commitec5c7c48925ca01c19c47133a3e3c35de0a4aaaf
treeee56393fe34641c7378dd50ac9978ef7749d330f
parent11d9f6e44a38a7096e39f8ed293746be29cb7715
s390/sthyi: Fix machine name validity indication

[ Upstream commit b5130dc2224d1881f24224c0590c6d97f2168d6a ]

When running as a level 3 guest with no host provided sthyi support
sclp_ocf_cpc_name_copy() will only return zeroes. Zeroes are not a
valid group name, so let's not indicate that the group name field is
valid.

Also the group name is not dependent on stsi, let's not return based
on stsi before setting it.

Fixes: 95ca2cb57985 ("KVM: s390: Add sthyi emulation")
Signed-off-by: Janosch Frank <frankja@linux.ibm.com>
Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
arch/s390/kvm/sthyi.c