From patchwork Fri Nov 20 16:01:15 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Eric Farman X-Patchwork-Id: 11921193 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-11.6 required=3.0 tests=BAYES_00,DKIM_INVALID, DKIM_SIGNED,HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_PATCH,MAILING_LIST_MULTI, SPF_HELO_NONE,SPF_PASS,USER_AGENT_GIT autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id BE706C2D0E4 for ; Fri, 20 Nov 2020 16:09:55 +0000 (UTC) Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 32CE02245F for ; Fri, 20 Nov 2020 16:09:54 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=fail reason="signature verification failed" (2048-bit key) header.d=ibm.com header.i=@ibm.com header.b="oiSwy1Dd" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 32CE02245F Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=linux.ibm.com Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=qemu-devel-bounces+qemu-devel=archiver.kernel.org@nongnu.org Received: from localhost ([::1]:45180 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1kg8yv-0006nW-Qf for qemu-devel@archiver.kernel.org; Fri, 20 Nov 2020 11:09:53 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]:56486) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1kg8rU-000680-Ck; Fri, 20 Nov 2020 11:02:12 -0500 Received: from mx0b-001b2d01.pphosted.com ([148.163.158.5]:48514 helo=mx0a-001b2d01.pphosted.com) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1kg8rN-0000jP-Nn; Fri, 20 Nov 2020 11:02:12 -0500 Received: from pps.filterd (m0098416.ppops.net [127.0.0.1]) by mx0b-001b2d01.pphosted.com (8.16.0.42/8.16.0.42) with SMTP id 0AKG1rJe140987; Fri, 20 Nov 2020 11:02:04 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ibm.com; h=from : to : cc : subject : date : message-id; s=pp1; bh=S6TqT6rqhHbfWydvXDvRjLApjJDsk+CqFuhbpeIGKus=; b=oiSwy1DdB0EGKUB8iVlch+GL7KATbumlewSScw3I7NOfQ0lDeFWvBaPs2/w51Iea9zRF ZTY/zKTtObgQOPQEEZxMhqa52plp74fm7xeFH4TR3txIlkpdiGHyKRsWux9W5gQb+gWc KvYB/iDXsV3kFLJkC6Ub599afuaL4vIqvrJxQdVr7s+NoUFEzDIvN2RaQSSeajLUvC6d 4L34OPaYZjMJr/tGtsv9loPvy/QyUnoEfA3lSAsvawRJabBQNqHQPCz451T/LRmAZPNK z8wjn9F8FHINB6ouLCYCnw7KGfq3r8chYSvRti/stTlNZlPIDxE8VBRa0wdttUuIzTgp Ww== Received: from pps.reinject (localhost [127.0.0.1]) by mx0b-001b2d01.pphosted.com with ESMTP id 34xeptd9ud-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Fri, 20 Nov 2020 11:02:03 -0500 Received: from m0098416.ppops.net (m0098416.ppops.net [127.0.0.1]) by pps.reinject (8.16.0.36/8.16.0.36) with SMTP id 0AKG22ej141630; Fri, 20 Nov 2020 11:02:02 -0500 Received: from ppma03fra.de.ibm.com (6b.4a.5195.ip4.static.sl-reverse.com [149.81.74.107]) by mx0b-001b2d01.pphosted.com with ESMTP id 34xeptd991-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Fri, 20 Nov 2020 11:02:02 -0500 Received: from pps.filterd (ppma03fra.de.ibm.com [127.0.0.1]) by ppma03fra.de.ibm.com (8.16.0.42/8.16.0.42) with SMTP id 0AKFvxY4004065; Fri, 20 Nov 2020 16:01:21 GMT Received: from b06cxnps4076.portsmouth.uk.ibm.com (d06relay13.portsmouth.uk.ibm.com [9.149.109.198]) by ppma03fra.de.ibm.com with ESMTP id 34t6v83b3s-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Fri, 20 Nov 2020 16:01:21 +0000 Received: from d06av24.portsmouth.uk.ibm.com (d06av24.portsmouth.uk.ibm.com [9.149.105.60]) by b06cxnps4076.portsmouth.uk.ibm.com (8.14.9/8.14.9/NCO v10.0) with ESMTP id 0AKG1IpU59310510 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Fri, 20 Nov 2020 16:01:18 GMT Received: from d06av24.portsmouth.uk.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id 3E9044203F; Fri, 20 Nov 2020 16:01:18 +0000 (GMT) Received: from d06av24.portsmouth.uk.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id 2C1004204B; Fri, 20 Nov 2020 16:01:18 +0000 (GMT) Received: from tuxmaker.boeblingen.de.ibm.com (unknown [9.152.85.9]) by d06av24.portsmouth.uk.ibm.com (Postfix) with ESMTPS; Fri, 20 Nov 2020 16:01:18 +0000 (GMT) Received: by tuxmaker.boeblingen.de.ibm.com (Postfix, from userid 4958) id D3A0CE23B0; Fri, 20 Nov 2020 17:01:17 +0100 (CET) From: Eric Farman To: Thomas Huth , Cornelia Huck Subject: [PATCH v2 0/2] pc-bios/s390 fixes for reboot-to-vfio-ccw Date: Fri, 20 Nov 2020 17:01:15 +0100 Message-Id: <20201120160117.59366-1-farman@linux.ibm.com> X-Mailer: git-send-email 2.17.1 X-TM-AS-GCONF: 00 X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10434:6.0.312, 18.0.737 definitions=2020-11-20_07:2020-11-20, 2020-11-20 signatures=0 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 adultscore=0 mlxscore=0 priorityscore=1501 phishscore=0 spamscore=0 mlxlogscore=999 impostorscore=0 malwarescore=0 suspectscore=0 bulkscore=0 lowpriorityscore=0 clxscore=1015 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.12.0-2009150000 definitions=main-2011200106 Received-SPF: pass client-ip=148.163.158.5; envelope-from=farman@linux.ibm.com; helo=mx0a-001b2d01.pphosted.com X-Spam_score_int: -19 X-Spam_score: -2.0 X-Spam_bar: -- X-Spam_report: (-2.0 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, RCVD_IN_MSPIKE_H2=-0.001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Jason Herne , Eric Farman , Janosch Frank , Matthew Rosato , qemu-devel@nongnu.org, Christian Borntraeger , qemu-s390x@nongnu.org Errors-To: qemu-devel-bounces+qemu-devel=archiver.kernel.org@nongnu.org Sender: "Qemu-devel" Thomas, Conny, Here is the updated series for the re-IPL fixes mentioned yesterday [1] I've updated the reviews/acks to Patch 1 (Thank you Conny, Janosch!), and implemented Thomas' suggestion to clear out the memory where S390EP exists early in our processing. This both preserves the delicate balance we have today, and fixes the scenario I've been wrestling with. For this second patch, I opted to #define the address x10008 and use it in both the new memset and existing memcmp, rather than having the address used directly in two places. I put this definition in s390-arch.h as it's shared by both files, even though it's not strictly an "s390 architecture" thing. Considering its importance, it seems like a reasonable fit. Tested with my permutations of virtio/vfio/chreipl/install things, but surely missing some others that I don't have readily configured. [1] https://lore.kernel.org/qemu-devel/20201119165729.63351-1-farman@linux.ibm.com/ Eric Farman (2): pc-bios: s390x: Ensure Read IPL memory is clean pc-bios: s390x: Clear out leftover S390EP string pc-bios/s390-ccw/dasd-ipl.c | 3 +++ pc-bios/s390-ccw/jump2ipl.c | 2 +- pc-bios/s390-ccw/main.c | 6 ++++++ pc-bios/s390-ccw/s390-arch.h | 3 +++ 4 files changed, 13 insertions(+), 1 deletion(-)