From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mx0b-0031df01.pphosted.com (mx0b-0031df01.pphosted.com [205.220.180.131]) (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 3FEDFAD49; Mon, 11 Mar 2024 05:38:59 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=205.220.180.131 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1710135541; cv=none; b=E9qmuBQ1hxvWxoU+bX7C3Gy1EbhAXePj5Ec4teFDhMXuVBBHPttGLgwvbEaK4sXNAVwedd4gYM9s1ZZXXuhF+Cf4ZJvExc79RXpDuOqwoIiKLP+Cw1ALZAPjq6u8GqHHwZDb3y8Q4FC9MTzt/hdav0MmQ3R0UTeeX7764xdyRzk= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1710135541; c=relaxed/simple; bh=AkZOu/ycQo26JPSpSdfiirIzKGaBHAYTDhkZtYbOcP8=; h=Date:From:To:CC:Subject:Message-ID:References:MIME-Version: Content-Type:Content-Disposition:In-Reply-To; b=JRe8bjhTiJp008djhFe5IO6FbSs24j3DKWCyE9Nv7V7cR14miGmTMwR4y198MQqnCuCX7NmwVpq97J2Ke20xotcE8hCeCAt81PwXIjHI+177zx8IDJdQMxS5n1N84zA9mKV4/KpAMUo0bKoSgol/yLYglnIfy7NdXosO5KfSOaA= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=quicinc.com; spf=pass smtp.mailfrom=quicinc.com; dkim=pass (2048-bit key) header.d=quicinc.com header.i=@quicinc.com header.b=gWmz9m3l; arc=none smtp.client-ip=205.220.180.131 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=quicinc.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=quicinc.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=quicinc.com header.i=@quicinc.com header.b="gWmz9m3l" Received: from pps.filterd (m0279870.ppops.net [127.0.0.1]) by mx0a-0031df01.pphosted.com (8.17.1.24/8.17.1.24) with ESMTP id 42B2wdRm021309; Mon, 11 Mar 2024 05:38:46 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=quicinc.com; h= date:from:to:cc:subject:message-id:reply-to:references :mime-version:content-type:in-reply-to; s=qcppdkim1; bh=9OLuA8Ie YGL+Fum93bhaJGG103DUqkeXo08bOEEnbog=; b=gWmz9m3lruXBdT0mRKeTS+EN zX1PS4/dSNCYlMEo8+fFRvLoK5PCPlVXyV5yB9LCR+BqVX1zrva3JRaNmGnxTNpz 8dJIpHN2EpoSSRK2i/fjEsJ2aNXNRRPSKSXI6IzItlxo3vGtVDRW8gKMZ/QvBxC2 ZoEHg5vOdXkDVZFDkrQ+PnqMYbQwV81Sew9lPmE9lVIyHRqCbsOufV6snZMhhy19 I9JWHw0l4jDt5Y04xDO7XQE0SPvNp1zoguAuL+76aA7Y6yOv0JxTDK5dG4qMd9En VdQ81asQ930/4GLhJJ8bagZsoc1bdEvhgBxz+ttKcASR8x7h0tkiE7MCvueZDg== Received: from nalasppmta05.qualcomm.com (Global_NAT1.qualcomm.com [129.46.96.20]) by mx0a-0031df01.pphosted.com (PPS) with ESMTPS id 3wrfuxtrgx-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Mon, 11 Mar 2024 05:38:46 +0000 (GMT) Received: from nalasex01b.na.qualcomm.com (nalasex01b.na.qualcomm.com [10.47.209.197]) by NALASPPMTA05.qualcomm.com (8.17.1.5/8.17.1.5) with ESMTPS id 42B5cihL009180 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Mon, 11 Mar 2024 05:38:44 GMT Received: from quicinc.com (10.80.80.8) by nalasex01b.na.qualcomm.com (10.47.209.197) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.1118.40; Sun, 10 Mar 2024 22:38:37 -0700 Date: Mon, 11 Mar 2024 11:08:34 +0530 From: Srivatsa Vaddagiri To: Elliot Berman CC: Alex Elder , Srinivas Kandagatla , Murali Nalajal , Trilok Soni , Carl van Schaik , Philip Derrin , Prakruthi Deepak Heragu , Jonathan Corbet , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Catalin Marinas , Will Deacon , Konrad Dybcio , Bjorn Andersson , Dmitry Baryshkov , "Fuad Tabba" , Sean Christopherson , "Andrew Morton" , , , , , , Subject: Re: [PATCH v17 10/35] gunyah: vm_mgr: Add VM start/stop Message-ID: <20240311053834.GM440762@quicinc.com> Reply-To: Srivatsa Vaddagiri References: <20240222-gunyah-v17-0-1e9da6763d38@quicinc.com> <20240222-gunyah-v17-10-1e9da6763d38@quicinc.com> Precedence: bulk X-Mailing-List: linux-arm-msm@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Disposition: inline In-Reply-To: <20240222-gunyah-v17-10-1e9da6763d38@quicinc.com> X-ClientProxiedBy: nasanex01b.na.qualcomm.com (10.46.141.250) To nalasex01b.na.qualcomm.com (10.47.209.197) X-QCInternal: smtphost X-Proofpoint-Virus-Version: vendor=nai engine=6200 definitions=5800 signatures=585085 X-Proofpoint-ORIG-GUID: yamRmtGTnTw21zM-rmeSozSVsMIm2_AU X-Proofpoint-GUID: yamRmtGTnTw21zM-rmeSozSVsMIm2_AU 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-03-11_02,2024-03-06_01,2023-05-22_02 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 phishscore=0 mlxlogscore=867 suspectscore=0 malwarescore=0 mlxscore=0 spamscore=0 bulkscore=0 adultscore=0 impostorscore=0 priorityscore=1501 clxscore=1015 lowpriorityscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.19.0-2402120000 definitions=main-2403110041 * Elliot Berman [2024-02-22 15:16:33]: > Add ioctl to trigger the start of a Gunyah virtual machine. Subsequent > commits will provide memory to the virtual machine and add ability to > interact with the resources (capabilities) of the virtual machine. > Although start of the virtual machine can be done implicitly on the > first vCPU run for proxy-schedule virtual machines, there is a > non-trivial number of calls to Gunyah: a more precise error can be given > to userspace which calls VM_START without looking at kernel logs because > userspace can detect that the VM start failed instead of "couldn't run > the vCPU". > > Co-developed-by: Prakruthi Deepak Heragu > Signed-off-by: Prakruthi Deepak Heragu > Signed-off-by: Elliot Berman Minor nit below. LGTM otherwise. Reviewed-by: Srivatsa Vaddagiri > +static int gunyah_vm_start(struct gunyah_vm *ghvm) > +{ .. > +err: > + /* gunyah_vm_free will handle releasing resources and reclaiming memory */ s/gunyah_vm_free/gunyah_vm_release > + up_write(&ghvm->status_lock); > + return ret; > +} From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id B5F8BC5475B for ; Mon, 11 Mar 2024 05:39:13 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:Reply-To:List-Subscribe:List-Help: List-Post:List-Archive:List-Unsubscribe:List-Id:In-Reply-To:MIME-Version: References:Message-ID:Subject:CC:To:From:Date:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=Srj8+z84G5E98p2yXXujtyu3X1B7Vv8T7opTEsSM9zU=; b=p0f4ljeJTeHPj9 P3nbiEffzkb5XZnMm5VFfCRFEebKkOdjHvp+Atd+BBjXWAy2C+ZRUmtC61ML7vuniikB//lBduyw/ UwFlJAuZmgFbpYum1pr/EHVU2fjcwHsHO19a2MwakFbQM3KW3YCLTgIjLPZEURVyU6TrhE3aRWyMU G7ASbZ5v7VUwscQjgGNuGn2YXmKUCJvobSkXGAvrHQdVXxROtM7pvKs6mHxLBHZk+7uQUmnvjNgQE pUkXNJP7jP58bhnx4BNXE6gpEoOzbnWlHIuI5G0SNt5Cn20hNlOpa9Ov2Ogu7w4/yhlPRPWKzUlWw FpXU37j4QkRVSuATrZBw==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.97.1 #2 (Red Hat Linux)) id 1rjYNI-00000000GvB-1ZXK; Mon, 11 Mar 2024 05:39:00 +0000 Received: from mx0b-0031df01.pphosted.com ([205.220.180.131]) by bombadil.infradead.org with esmtps (Exim 4.97.1 #2 (Red Hat Linux)) id 1rjYNE-00000000GtI-3pO3 for linux-arm-kernel@lists.infradead.org; Mon, 11 Mar 2024 05:38:58 +0000 Received: from pps.filterd (m0279870.ppops.net [127.0.0.1]) by mx0a-0031df01.pphosted.com (8.17.1.24/8.17.1.24) with ESMTP id 42B2wdRm021309; Mon, 11 Mar 2024 05:38:46 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=quicinc.com; h= date:from:to:cc:subject:message-id:reply-to:references :mime-version:content-type:in-reply-to; s=qcppdkim1; bh=9OLuA8Ie YGL+Fum93bhaJGG103DUqkeXo08bOEEnbog=; b=gWmz9m3lruXBdT0mRKeTS+EN zX1PS4/dSNCYlMEo8+fFRvLoK5PCPlVXyV5yB9LCR+BqVX1zrva3JRaNmGnxTNpz 8dJIpHN2EpoSSRK2i/fjEsJ2aNXNRRPSKSXI6IzItlxo3vGtVDRW8gKMZ/QvBxC2 ZoEHg5vOdXkDVZFDkrQ+PnqMYbQwV81Sew9lPmE9lVIyHRqCbsOufV6snZMhhy19 I9JWHw0l4jDt5Y04xDO7XQE0SPvNp1zoguAuL+76aA7Y6yOv0JxTDK5dG4qMd9En VdQ81asQ930/4GLhJJ8bagZsoc1bdEvhgBxz+ttKcASR8x7h0tkiE7MCvueZDg== Received: from nalasppmta05.qualcomm.com (Global_NAT1.qualcomm.com [129.46.96.20]) by mx0a-0031df01.pphosted.com (PPS) with ESMTPS id 3wrfuxtrgx-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Mon, 11 Mar 2024 05:38:46 +0000 (GMT) Received: from nalasex01b.na.qualcomm.com (nalasex01b.na.qualcomm.com [10.47.209.197]) by NALASPPMTA05.qualcomm.com (8.17.1.5/8.17.1.5) with ESMTPS id 42B5cihL009180 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Mon, 11 Mar 2024 05:38:44 GMT Received: from quicinc.com (10.80.80.8) by nalasex01b.na.qualcomm.com (10.47.209.197) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.1118.40; Sun, 10 Mar 2024 22:38:37 -0700 Date: Mon, 11 Mar 2024 11:08:34 +0530 From: Srivatsa Vaddagiri To: Elliot Berman CC: Alex Elder , Srinivas Kandagatla , Murali Nalajal , Trilok Soni , Carl van Schaik , Philip Derrin , Prakruthi Deepak Heragu , Jonathan Corbet , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Catalin Marinas , Will Deacon , Konrad Dybcio , Bjorn Andersson , Dmitry Baryshkov , "Fuad Tabba" , Sean Christopherson , "Andrew Morton" , , , , , , Subject: Re: [PATCH v17 10/35] gunyah: vm_mgr: Add VM start/stop Message-ID: <20240311053834.GM440762@quicinc.com> References: <20240222-gunyah-v17-0-1e9da6763d38@quicinc.com> <20240222-gunyah-v17-10-1e9da6763d38@quicinc.com> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: <20240222-gunyah-v17-10-1e9da6763d38@quicinc.com> X-Originating-IP: [10.80.80.8] X-ClientProxiedBy: nasanex01b.na.qualcomm.com (10.46.141.250) To nalasex01b.na.qualcomm.com (10.47.209.197) X-QCInternal: smtphost X-Proofpoint-Virus-Version: vendor=nai engine=6200 definitions=5800 signatures=585085 X-Proofpoint-ORIG-GUID: yamRmtGTnTw21zM-rmeSozSVsMIm2_AU X-Proofpoint-GUID: yamRmtGTnTw21zM-rmeSozSVsMIm2_AU 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-03-11_02,2024-03-06_01,2023-05-22_02 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 phishscore=0 mlxlogscore=867 suspectscore=0 malwarescore=0 mlxscore=0 spamscore=0 bulkscore=0 adultscore=0 impostorscore=0 priorityscore=1501 clxscore=1015 lowpriorityscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.19.0-2402120000 definitions=main-2403110041 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20240310_223857_111712_48ECBD16 X-CRM114-Status: GOOD ( 13.99 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: Srivatsa Vaddagiri Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org * Elliot Berman [2024-02-22 15:16:33]: > Add ioctl to trigger the start of a Gunyah virtual machine. Subsequent > commits will provide memory to the virtual machine and add ability to > interact with the resources (capabilities) of the virtual machine. > Although start of the virtual machine can be done implicitly on the > first vCPU run for proxy-schedule virtual machines, there is a > non-trivial number of calls to Gunyah: a more precise error can be given > to userspace which calls VM_START without looking at kernel logs because > userspace can detect that the VM start failed instead of "couldn't run > the vCPU". > > Co-developed-by: Prakruthi Deepak Heragu > Signed-off-by: Prakruthi Deepak Heragu > Signed-off-by: Elliot Berman Minor nit below. LGTM otherwise. Reviewed-by: Srivatsa Vaddagiri > +static int gunyah_vm_start(struct gunyah_vm *ghvm) > +{ .. > +err: > + /* gunyah_vm_free will handle releasing resources and reclaiming memory */ s/gunyah_vm_free/gunyah_vm_release > + up_write(&ghvm->status_lock); > + return ret; > +} _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel