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 smtp2.osuosl.org (smtp2.osuosl.org [140.211.166.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 AF954C433FE for ; Wed, 24 Nov 2021 13:28:58 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by smtp2.osuosl.org (Postfix) with ESMTP id 26A8F4019C; Wed, 24 Nov 2021 13:28:58 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Received: from smtp2.osuosl.org ([127.0.0.1]) by localhost (smtp2.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 3F5s49ONlTux; Wed, 24 Nov 2021 13:28:57 +0000 (UTC) Received: from lists.linuxfoundation.org (lf-lists.osuosl.org [140.211.9.56]) by smtp2.osuosl.org (Postfix) with ESMTPS id 8D4674014D; Wed, 24 Nov 2021 13:28:56 +0000 (UTC) Received: from lf-lists.osuosl.org (localhost [127.0.0.1]) by lists.linuxfoundation.org (Postfix) with ESMTP id 40459C001E; Wed, 24 Nov 2021 13:28:56 +0000 (UTC) Received: from smtp4.osuosl.org (smtp4.osuosl.org [IPv6:2605:bc80:3010::137]) by lists.linuxfoundation.org (Postfix) with ESMTP id DA8BBC0012 for ; Wed, 24 Nov 2021 13:28:54 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by smtp4.osuosl.org (Postfix) with ESMTP id BB6AF4021B for ; Wed, 24 Nov 2021 13:28:54 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Authentication-Results: smtp4.osuosl.org (amavisd-new); dkim=pass (1024-bit key) header.d=suse.de header.b="ZEJ5PnuB"; dkim=neutral reason="invalid (unsupported algorithm ed25519-sha256)" header.d=suse.de header.b="z67fHxRW" Received: from smtp4.osuosl.org ([127.0.0.1]) by localhost (smtp4.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id KgGR2XaCGKc5 for ; Wed, 24 Nov 2021 13:28:54 +0000 (UTC) X-Greylist: domain auto-whitelisted by SQLgrey-1.8.0 Received: from smtp-out2.suse.de (smtp-out2.suse.de [195.135.220.29]) by smtp4.osuosl.org (Postfix) with ESMTPS id 206A44020B for ; Wed, 24 Nov 2021 13:28:54 +0000 (UTC) Received: from imap2.suse-dmz.suse.de (imap2.suse-dmz.suse.de [192.168.254.74]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-521) server-digest SHA512) (No client certificate requested) by smtp-out2.suse.de (Postfix) with ESMTPS id ADB911FD37; Wed, 24 Nov 2021 13:28:51 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.de; s=susede2_rsa; t=1637760531; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc:cc: mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=kmul1IbP0GnECy1ymvqNlUCJsoqlTASzkS58dvywssg=; b=ZEJ5PnuBiszih5UXgJaGfk48htnkxlak3oSlR+gsJcxUaDIvq/C+QihbR+cSOgBpG+zgd8 +K0SHfJOVuvCZ5p8/tLlFazoWL73VNlxHc0nIKokDCaJgYq3FFrzJdjBvkcNLTPEHdH7Nw dl52rAA+SWMLMAv737DIisN9S0JnLz8= DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=suse.de; s=susede2_ed25519; t=1637760531; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc:cc: mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=kmul1IbP0GnECy1ymvqNlUCJsoqlTASzkS58dvywssg=; b=z67fHxRWZigT6qf7YYjcA3is5C6hHq/rq3j5Mp8klzhWcoWQddC+zDx+5goR1ptD0YeIIc jRvrdCjFrPiJ1ZDw== Received: from imap2.suse-dmz.suse.de (imap2.suse-dmz.suse.de [192.168.254.74]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-521) server-digest SHA512) (No client certificate requested) by imap2.suse-dmz.suse.de (Postfix) with ESMTPS id 175E313F20; Wed, 24 Nov 2021 13:28:51 +0000 (UTC) Received: from dovecot-director2.suse.de ([192.168.254.65]) by imap2.suse-dmz.suse.de with ESMTPSA id fhDpAxM+nmEsRQAAMHmgww (envelope-from ); Wed, 24 Nov 2021 13:28:51 +0000 Date: Wed, 24 Nov 2021 14:28:49 +0100 From: Joerg Roedel To: Michael Sterritt Subject: Re: [PATCH v2] x86/sev-es: Fix SEV-ES INS/OUTS instructions for word, dword, and qword Message-ID: References: <20211119232757.176201-1-sterritt@google.com> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: <20211119232757.176201-1-sterritt@google.com> Cc: Tom Lendacky , x86@kernel.org, kvm@vger.kernel.org, Peter Zijlstra , Dave Hansen , linux-kernel@vger.kernel.org, virtualization@lists.linux-foundation.org, marcorr@google.com, Ingo Molnar , Borislav Petkov , linux-coco@lists.linux.dev, pgonda@google.com, "H. Peter Anvin" , Paolo Bonzini , Thomas Gleixner X-BeenThere: virtualization@lists.linux-foundation.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: Linux virtualization List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Errors-To: virtualization-bounces@lists.linux-foundation.org Sender: "Virtualization" On Fri, Nov 19, 2021 at 03:27:57PM -0800, Michael Sterritt wrote: > Properly type the operands being passed to __put_user()/__get_user(). > Otherwise, these routines truncate data for dependent instructions > (e.g., INSW) and only read/write one byte. > > Tested: Tested by sending a string with `REP OUTSW` to a port and then > reading it back in with `REP INSW` on the same port. Previous behavior > was to only send and receive the first char of the size. For example, > word operations for "abcd" would only read/write "ac". With change, the > full string is now written and read back. > > Fixes: f980f9c31a923 (x86/sev-es: Compile early handler code into kernel image) > Reviewed-by: Paolo Bonzini > Reviewed-by: Marc Orr > Reviewed-by: Peter Gonda > Signed-off-by: Michael Sterritt Reviewed-by: Joerg Roedel _______________________________________________ Virtualization mailing list Virtualization@lists.linux-foundation.org https://lists.linuxfoundation.org/mailman/listinfo/virtualization