Received: by 2002:a05:7412:3b8b:b0:fc:a2b0:25d7 with SMTP id nd11csp1225714rdb; Fri, 9 Feb 2024 14:37:13 -0800 (PST) X-Forwarded-Encrypted: i=3; AJvYcCXQDbAveBkEqzQrlodqy4A8qCSGe1Ie3sVE659XLLUHB34ZNz45yamBKFfv/7sFBjJkr+h2/Xf5LrC9dQhS7rKEfnBVpvfWkactvUEgYQ== X-Google-Smtp-Source: AGHT+IEcviHa7OMtBg4uoC6iFOJjEgPi8JZXEXbR6NsR/0kW4S1vdyKc9DpETiTHV9ryHTO0Z3HS X-Received: by 2002:a17:907:2da9:b0:a38:66be:9797 with SMTP id gt41-20020a1709072da900b00a3866be9797mr2438126ejc.34.1707518233798; Fri, 09 Feb 2024 14:37:13 -0800 (PST) X-Forwarded-Encrypted: i=3; AJvYcCWNLrISp2smMRu6MIE6a+F1BEPOQNhwl7t2Vd+ramvKN2bQBKycDqdmjSxk4CHBCWi4uoyOohPQMP3W7MS2glOVeAXfcJzDnrjP22LPgQ== Return-Path: Received: from am.mirrors.kernel.org (am.mirrors.kernel.org. [147.75.80.249]) by mx.google.com with ESMTPS id v24-20020a170906565800b00a3c2be72abesi10192ejr.736.2024.02.09.14.37.13 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 09 Feb 2024 14:37:13 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-60117-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.80.249 as permitted sender) client-ip=147.75.80.249; Authentication-Results: mx.google.com; dkim=pass header.i=@oracle.com header.s=corp-2023-11-20 header.b=IMstcmY7; dkim=pass header.i=@oracle.onmicrosoft.com header.s=selector2-oracle-onmicrosoft-com header.b=yf79AFKP; arc=fail (signature failed); spf=pass (google.com: domain of linux-kernel+bounces-60117-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.80.249 as permitted sender) smtp.mailfrom="linux-kernel+bounces-60117-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=oracle.com Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by am.mirrors.kernel.org (Postfix) with ESMTPS id 69E091F22E54 for ; Fri, 9 Feb 2024 22:36:16 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 12D7B39FEB; Fri, 9 Feb 2024 22:34:20 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=oracle.com header.i=@oracle.com header.b="IMstcmY7"; dkim=pass (1024-bit key) header.d=oracle.onmicrosoft.com header.i=@oracle.onmicrosoft.com header.b="yf79AFKP" Received: from mx0b-00069f02.pphosted.com (mx0b-00069f02.pphosted.com [205.220.177.32]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id D102239AD4 for ; Fri, 9 Feb 2024 22:34:16 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=fail smtp.client-ip=205.220.177.32 ARC-Seal:i=2; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1707518058; cv=fail; b=E6o8rYeHzLgs8r8rlI9ZrEl+YtR9DtAI4Xg5luMgzJqUyfDl9I5gzEHpjspNC3sn4/fvMyuRMZ5TR7CGNkETo4uAOuLVKYPS2KzVhe+SKDV0dDB3l/eQHLsuJS2ZAAHuDZJRQJul3QUecvHq58ky9famh7MWb+tXEZuO9yjLmMU= ARC-Message-Signature:i=2; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1707518058; c=relaxed/simple; bh=ig+7d3FElg8ZebiigSJc/+WutL6ehcT262RTX7c7oAA=; h=Message-ID:Date:Subject:To:Cc:References:From:In-Reply-To: Content-Type:MIME-Version; b=R7RcdI4+Jj/DJ0eP+zDGeQtX04oo1GTz5foZTaOK+/TYw8KzxhaPx1B2+Poj4SGe13VLOoJJZiUw/BXXveEJblJ/YjjFJ93q1zbYasCwA+dmhovDMIlO+6g1j11zYOupOMEsc3hV2qMgz52BlzWMp5n0FLQuMtJ9/SeITOj6T/A= ARC-Authentication-Results:i=2; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=oracle.com; spf=pass smtp.mailfrom=oracle.com; dkim=pass (2048-bit key) header.d=oracle.com header.i=@oracle.com header.b=IMstcmY7; dkim=pass (1024-bit key) header.d=oracle.onmicrosoft.com header.i=@oracle.onmicrosoft.com header.b=yf79AFKP; arc=fail smtp.client-ip=205.220.177.32 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=oracle.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=oracle.com Received: from pps.filterd (m0246632.ppops.net [127.0.0.1]) by mx0b-00069f02.pphosted.com (8.17.1.19/8.17.1.19) with ESMTP id 419MQgU5005187; Fri, 9 Feb 2024 22:34:13 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=oracle.com; h=message-id : date : subject : to : cc : references : from : in-reply-to : content-type : content-transfer-encoding : mime-version; s=corp-2023-11-20; bh=SQxutcVTcVqLAZr01rlRr/xxA4oJMaJWpQbJrdR/pHw=; b=IMstcmY7lB0Wo37Yup+xOcB6be01kFuGF2LYAvLOVgmaY+ggBVQVutkCKCBhBJxjiHtj pVvrrSq/+uOvMsbyPiXvNnhxLIiW4nhZS262YwkT0Vs50bShZXpI9z4UR9dbQmzRiOpD hClaSdqkQ3eZjreaI6gxNvsQbwBVHbSm9nAPLd56XyM84NgVoj/YpeEsLxKIOukGhFXD lI1eoLa0g2BBerA4z1OG0zpH/QveOshWuwtd2S87KDjcRPnoKamsbMiXQL+ry0mb3SPD Rn81I0QX7MLvAoZXhm2OIzSBxHlLeqA5BdOmkdZjUXC2m5/tAclApxiiG3F0H7t29QOv pw== Received: from iadpaimrmta02.imrmtpd1.prodappiadaev1.oraclevcn.com (iadpaimrmta02.appoci.oracle.com [147.154.18.20]) by mx0b-00069f02.pphosted.com (PPS) with ESMTPS id 3w5snr0eu2-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Fri, 09 Feb 2024 22:34:12 +0000 Received: from pps.filterd (iadpaimrmta02.imrmtpd1.prodappiadaev1.oraclevcn.com [127.0.0.1]) by iadpaimrmta02.imrmtpd1.prodappiadaev1.oraclevcn.com (8.17.1.19/8.17.1.19) with ESMTP id 419M2lBO038395; Fri, 9 Feb 2024 22:34:12 GMT Received: from nam04-bn8-obe.outbound.protection.outlook.com (mail-bn8nam04lp2041.outbound.protection.outlook.com [104.47.74.41]) by iadpaimrmta02.imrmtpd1.prodappiadaev1.oraclevcn.com (PPS) with ESMTPS id 3w1bxckhvs-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Fri, 09 Feb 2024 22:34:12 +0000 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=K7xRlfOL79ESGVp5RuzF+Lb9aLrP3+h9kHKs2TvqR12GLK6+l5OakyShgbLTFuF4NtkPmkTCfpZgDnJ+ZdRWHIIUdi+JmzEbwwy/K69qxTwzz1ArHqeWnfB/suo3zUpLf0zo6+FJ31xGrg3Rr9i04UopkCorFPBthPDVnFnwFrLV0LwSnPlkAWRL/djOaNRI3LjKNxYz3f3Zuc+28cNZAH6UDMssmSfXpU27N8cjvxWvyo8UEecMgjy0SPysiS+VBuycBru6Vrh2nJFesm0vJvtdW9TG7+ooYo8XAO3LdL8XoU/Ad9WiwgPbMeCvue8GNsI2dV+dE6CgVUxoiU4U1A== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=SQxutcVTcVqLAZr01rlRr/xxA4oJMaJWpQbJrdR/pHw=; b=VBktXzpMyBPy4nQjePd5EK0iUhha4IrJlDfyUz67vj9KdzpUQmjCRSp85hMsJ/rpxgtd6wQr1Ni5eCZAKy2cU9MdZpZGPIrbDYt4LXXbuCFT/R6VOHtUnIJAzHs0gXhDdrltc9sUkKUyfXrzPAAOXOKqfVdQ3ynEuDB+syxhPKDmM2zXpxkBgACoYLrIEK1wZU0D1hI87CvwtUMAHvlKptTKLn2BerqyPUCa3xO6/qSa/ELihRG93VMQ9TGqaelNuyBvOjFFGt2i7cMUF8IQ0s6vuoz9l+H1FH8nN2lvfdGgctYb73h1xra/cINK/HQ2xaXhv3VqzY8mGUUThfESYA== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=oracle.com; dmarc=pass action=none header.from=oracle.com; dkim=pass header.d=oracle.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=oracle.onmicrosoft.com; s=selector2-oracle-onmicrosoft-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=SQxutcVTcVqLAZr01rlRr/xxA4oJMaJWpQbJrdR/pHw=; b=yf79AFKP66oVt17dK/tvyrcfP2fxyossQXQ0b4IgAiKUc1jYNi2YHmpWU54tofPrp+SVjqy4DcBAkbHLt2tv/pL5BUtmKlgApmlH2HPYTHkuV85KKZhrqubs+4regwiLktdv5rBX2fn+aRqb0p1WjWkVE+S3NIius71be/4eXhk= Received: from SA2PR10MB4684.namprd10.prod.outlook.com (2603:10b6:806:119::14) by MW4PR10MB6584.namprd10.prod.outlook.com (2603:10b6:303:226::6) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.7249.38; Fri, 9 Feb 2024 22:34:09 +0000 Received: from SA2PR10MB4684.namprd10.prod.outlook.com ([fe80::c3ce:7c28:7db1:656b]) by SA2PR10MB4684.namprd10.prod.outlook.com ([fe80::c3ce:7c28:7db1:656b%6]) with mapi id 15.20.7270.025; Fri, 9 Feb 2024 22:34:09 +0000 Message-ID: Date: Fri, 9 Feb 2024 17:34:06 -0500 User-Agent: Mozilla Thunderbird Subject: Re: [PATCH V1] vdpa_sim: reset must not run Content-Language: en-US To: Stefano Garzarella , Eugenio Perez Martin Cc: virtualization@lists.linux-foundation.org, linux-kernel@vger.kernel.org, "Michael S. Tsirkin" , Jason Wang , Si-Wei Liu References: <1705519403-255169-1-git-send-email-steven.sistare@oracle.com> From: Steven Sistare Organization: Oracle Corporation In-Reply-To: Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-ClientProxiedBy: SJ0PR03CA0122.namprd03.prod.outlook.com (2603:10b6:a03:33c::7) To SA2PR10MB4684.namprd10.prod.outlook.com (2603:10b6:806:119::14) Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: SA2PR10MB4684:EE_|MW4PR10MB6584:EE_ X-MS-Office365-Filtering-Correlation-Id: 57fb2194-1c1a-400a-2839-08dc29bf3ba7 X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: LJEySLECOEzU/S9MbQkVwEUZRO3DfYNQdEnG5y80E0s/TANpRxca7G/V/oBA9g+UyF6o857AFWFu3V1LfBBe/6zfZ+P9TJBx6W8GW53ygfLnne2Ulkxbz/vFnsSpftWfjuLbJyTG+029jp7Qr0PYo0fx0aOPQm/UvCCByNOm/Zl8494d46P7YK4ZkldQ5WO4oB6Ygpue0686dwYlqm/q1Af+5NoHPJzggdGwBauENh4ekbBY2+dypjs1oF8ftNKsy4G8BsKX2W0oZcOeWYW+BHg0gHZzBAilc+ZNN85L+tXf21cGNYk0KAZk1VntddTXufsErBBB4gAkHspimlEM88gFkmjibTIYFCK8h3NKNXrS/3cDQ8s1bXHd2FPJ6djJCkaLG12I2lntY9xi3f/rTgCKUz+GS/NA9hnaDsf/azoGidNobOTylj6O8Y3wF3hfS94ElcX76RfSdMPEb44lTVbeloPmZeKuRleh8oIAV/Rx43JQWCxXXlVwcXhsahcka+GjHZn9HpncgOz7yWoNn/V+F5/fFh74ojoKAi+yEIysmWtuC8SKM6YLMpFkOx5/ X-Forefront-Antispam-Report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:SA2PR10MB4684.namprd10.prod.outlook.com;PTR:;CAT:NONE;SFS:(13230031)(39860400002)(396003)(366004)(376002)(136003)(346002)(230922051799003)(451199024)(64100799003)(1800799012)(186009)(41300700001)(83380400001)(2906002)(4326008)(8936002)(44832011)(26005)(5660300002)(36916002)(6512007)(6666004)(6506007)(8676002)(53546011)(478600001)(36756003)(6486002)(2616005)(107886003)(316002)(66946007)(110136005)(66556008)(66476007)(54906003)(31696002)(86362001)(66574015)(31686004)(38100700002);DIR:OUT;SFP:1101; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: =?utf-8?B?TWk2NGhQVm1vMXd6cFRKb2lrRUhZdmdzVW5oODdkQ2prMzdvZGtReDZaQTlR?= =?utf-8?B?WStSWXozUnVsYTR2am9TejIwdnNEL2w5RE84TWlCbVVObk05Q0ZXY2MxK0Np?= =?utf-8?B?bzVtRWNHZlVEWHN3MlpEWUFIYTFqR3RMYklPd25JSWZvRjNyays4V1VOTzBo?= =?utf-8?B?dENscVFTZERQQUNiblZ5akNYaHpDUVdUOFZwY1IvUVk0NTVKWjZacUJZVnN2?= =?utf-8?B?UUlrelM1WWQ5NmFoMzBnUm9oVjV6VU0xc1VZT3RpTUw3Mkp6OVF4aUdONmxU?= =?utf-8?B?YThEWG5Vakc2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YV3dIOExi?= =?utf-8?B?MVMzWUpUbi9pQ3ZjanJWQXB1UEZmUWYrdlBVVmp1Zmg1S3NhUm81YVZTVXJI?= =?utf-8?B?S2c9PQ==?= X-MS-Exchange-AntiSpam-ExternalHop-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-ExternalHop-MessageData-0: HhUPlM5pfDEti31qMhWWjs+2MG3ZJxx5ei2nc5FE5hSP+XYe6tI5fkIVCECu2I0TnKprUcNmhWH6oat4sop314+ApluocGSeicmv8lyNukjmDSOYkiPEHzqFi7E4HLdfnSyXbJXjE7bdGiWe3eADRFUHHwXrmmb5nvmL2tVpnB1zJ/gtqCPNYscG8Mdrg6Kt+p0d+FiG1Zw3HjJVrn7ZyKIaqtj7lXCy76hCh1HaQdziB5eb5EwyKYw766+Rwgh9cjQ4NXuGSJCk5jq/vLt0PImcqqEMyXLSqAce4LHJlXWMa/1tIFvrzlt7IPDibJaWw4bHo3C1t9hdBKybNh3tkgUFUQUFpq2n8GlLg0nAZhr843hYDNwTSs0dBj/fxhKVURDKR/q3TwpN2n6ce6KWTZI66etKvVlogxA7TeJpH0BGfXwu/o5KW2rn3MQnHjoqsk6Ao3JHqdAdPBemNoT5WZBF9CRNSGFHcCjIGxKEBZB1B+OI8dM7V46kvqHZo7yZTT+wXwetEOXygPDcK91EitAhnDRk85GZU6rfUhkghPaw4j4Ob5g3wY4PFuIO8uLUEorxbOhKtXIBhJqTmySLosa9b9XC0WZQvxbcJNjS3B8= X-OriginatorOrg: oracle.com X-MS-Exchange-CrossTenant-Network-Message-Id: 57fb2194-1c1a-400a-2839-08dc29bf3ba7 X-MS-Exchange-CrossTenant-AuthSource: SA2PR10MB4684.namprd10.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 09 Feb 2024 22:34:09.7508 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 4e2c6054-71cb-48f1-bd6c-3a9705aca71b X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: CyPaW2EgWs0EYXw2fBJgSNgN2bSUEMpf2lGiaW7T5eJNSNg3ovjjWwHGsnaSmumeIslLAZWggJA+Kbu0pbWdLFX1dN4nCWfHz6sEu2w8NXg= X-MS-Exchange-Transport-CrossTenantHeadersStamped: MW4PR10MB6584 X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.272,Aquarius:18.0.1011,Hydra:6.0.619,FMLib:17.11.176.26 definitions=2024-02-09_18,2024-02-08_01,2023-05-22_02 X-Proofpoint-Spam-Details: rule=notspam policy=default score=0 malwarescore=0 spamscore=0 mlxlogscore=999 bulkscore=0 mlxscore=0 phishscore=0 adultscore=0 suspectscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.12.0-2311290000 definitions=main-2402090165 X-Proofpoint-ORIG-GUID: K36OVJO6aaPNwH-HJEvesQhkah7APHhL X-Proofpoint-GUID: K36OVJO6aaPNwH-HJEvesQhkah7APHhL On 1/22/2024 5:59 AM, Stefano Garzarella wrote: > On Mon, Jan 22, 2024 at 11:47:22AM +0100, Eugenio Perez Martin wrote: >> On Mon, Jan 22, 2024 at 11:22 AM Stefano Garzarella wrote: >>> >>> On Wed, Jan 17, 2024 at 11:23:23AM -0800, Steve Sistare wrote: >>> >vdpasim_do_reset sets running to true, which is wrong, as it allows >>> >vdpasim_kick_vq to post work requests before the device has been >>> >configured.  To fix, do not set running until VIRTIO_CONFIG_S_FEATURES_OK >>> >is set. >>> > >>> >Fixes: 0c89e2a3a9d0 ("vdpa_sim: Implement suspend vdpa op") >>> >Signed-off-by: Steve Sistare >>> >Reviewed-by: Eugenio Pérez >>> >--- >>> > drivers/vdpa/vdpa_sim/vdpa_sim.c | 3 ++- >>> > 1 file changed, 2 insertions(+), 1 deletion(-) >>> > >>> >diff --git a/drivers/vdpa/vdpa_sim/vdpa_sim.c b/drivers/vdpa/vdpa_sim/vdpa_sim.c >>> >index be2925d0d283..6304cb0b4770 100644 >>> >--- a/drivers/vdpa/vdpa_sim/vdpa_sim.c >>> >+++ b/drivers/vdpa/vdpa_sim/vdpa_sim.c >>> >@@ -160,7 +160,7 @@ static void vdpasim_do_reset(struct vdpasim *vdpasim, u32 flags) >>> >               } >>> >       } >>> > >>> >-      vdpasim->running = true; >>> >+      vdpasim->running = false; >>> >       spin_unlock(&vdpasim->iommu_lock); >>> > >>> >       vdpasim->features = 0; >>> >@@ -483,6 +483,7 @@ static void vdpasim_set_status(struct vdpa_device *vdpa, u8 status) >>> > >>> >       mutex_lock(&vdpasim->mutex); >>> >       vdpasim->status = status; >>> >+      vdpasim->running = (status & VIRTIO_CONFIG_S_FEATURES_OK) != 0; >>> >       mutex_unlock(&vdpasim->mutex); >>> >>> Should we do something similar also in vdpasim_resume() ? >>> >>> I mean something like this: >>> >>> diff --git a/drivers/vdpa/vdpa_sim/vdpa_sim.c b/drivers/vdpa/vdpa_sim/vdpa_sim.c >>> index be2925d0d283..55e4633d5442 100644 >>> --- a/drivers/vdpa/vdpa_sim/vdpa_sim.c >>> +++ b/drivers/vdpa/vdpa_sim/vdpa_sim.c >>> @@ -520,7 +520,7 @@ static int vdpasim_resume(struct vdpa_device *vdpa) >>>          int i; >>> >>>          mutex_lock(&vdpasim->mutex); >>> -       vdpasim->running = true; >>> +       vdpasim->running = (vdpasim->status & VIRTIO_CONFIG_S_FEATURES_OK) != 0; >>> >>>          if (vdpasim->pending_kick) { >>>                  /* Process pending descriptors */ >>> >>> Thanks, >>> Stefano >>> >> >> The suspend and resume operation should not be called before >> DRIVER_OK, so maybe we should add that protection at >> drivers/vhost/vdpa.c actually? > > Yeah, I think so! > > Anyway, IMHO we should at least return an error in vdpa_sim if vdpasim_suspend/resume are called before DRIVER_OK (in another patch of course). I submitted "vdpa: suspend and resume require DRIVER_OK" to check this in vdpa.c so there is no need to check it in the leaf drivers. I also submitted V2 of this patch, "vdpa_sim: reset must not run". It checks for DRIVER_OK, instead of FEATURES_OK. - Steve