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 X-Spam-Level: X-Spam-Status: No, score=-6.8 required=3.0 tests=DKIMWL_WL_HIGH,DKIM_SIGNED, DKIM_VALID,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,SIGNED_OFF_BY, 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 272F4FC6195 for ; Fri, 8 Nov 2019 18:55:02 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id E70B7222C9 for ; Fri, 8 Nov 2019 18:55:01 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1573239302; bh=8p8jZg3yN5igrYUTflVjMBoMf3YS9M66ksHw9gzGKIQ=; h=From:To:Cc:Subject:Date:In-Reply-To:References:List-ID:From; b=KaXT55VZ/PQxGiISBjPgyzLyh0XvuJfOMCCnzdJ1W6ao92T/8CafyRvYw49ALa+KR tGaDXXr93zXqRpZCdxFjFQXr+ZRMfMOIv+el9L9qo80JiMdnU5qRVnRErxOu4sIngZ Qhsq9xRjCKlyC/KFZTdi3uSkfiWRJeUjdneaiAk8= Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1733210AbfKHSzA (ORCPT ); Fri, 8 Nov 2019 13:55:00 -0500 Received: from mail.kernel.org ([198.145.29.99]:52146 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1731291AbfKHSy7 (ORCPT ); Fri, 8 Nov 2019 13:54:59 -0500 Received: from localhost (83-86-89-107.cable.dynamic.v4.ziggo.nl [83.86.89.107]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id E77FD214DB; Fri, 8 Nov 2019 18:54:57 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1573239298; bh=8p8jZg3yN5igrYUTflVjMBoMf3YS9M66ksHw9gzGKIQ=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=XqHU1e8b1gCM23Oaif2AoOU9Qb0FaLpqQj/qFiOIck8JMtbdW5jx5YYdeITiPl1t+ sgUQiN2ngZsc8Ecp8KtjsnRABsv2qqeEPl2NL6IKwAR0W8Ntz138NnFLEip8rnFvZY PsEnUrU8upvSdubZxHzkdY4YZLkqpDQhNEzug8FA= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org, stable@vger.kernel.org Cc: Greg Kroah-Hartman , David Binderman , Julien Thierry , Russell King , "David A. Long" , Sasha Levin , Ard Biesheuvel Subject: [PATCH 4.4 66/75] ARM: 8810/1: vfp: Fix wrong assignement to ufp_exc Date: Fri, 8 Nov 2019 19:50:23 +0100 Message-Id: <20191108174808.089975969@linuxfoundation.org> X-Mailer: git-send-email 2.24.0 In-Reply-To: <20191108174708.135680837@linuxfoundation.org> References: <20191108174708.135680837@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Sender: stable-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: stable@vger.kernel.org From: Julien Thierry Commit 5df7a99bdd0de4a0480320264c44c04543c29d5a upstream. In vfp_preserve_user_clear_hwstate, ufp_exc->fpinst2 gets assigned to itself. It should actually be hwstate->fpinst2 that gets assigned to the ufp_exc field. Fixes commit 3aa2df6ec2ca6bc143a65351cca4266d03a8bc41 ("ARM: 8791/1: vfp: use __copy_to_user() when saving VFP state"). Reported-by: David Binderman Signed-off-by: Julien Thierry Signed-off-by: Russell King Signed-off-by: David A. Long Reviewed-by: Julien Thierry Signed-off-by: Sasha Levin Signed-off-by: Ard Biesheuvel Signed-off-by: Greg Kroah-Hartman --- arch/arm/vfp/vfpmodule.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) --- a/arch/arm/vfp/vfpmodule.c +++ b/arch/arm/vfp/vfpmodule.c @@ -583,7 +583,7 @@ int vfp_preserve_user_clear_hwstate(stru */ ufp_exc->fpexc = hwstate->fpexc; ufp_exc->fpinst = hwstate->fpinst; - ufp_exc->fpinst2 = ufp_exc->fpinst2; + ufp_exc->fpinst2 = hwstate->fpinst2; /* Ensure that VFP is disabled. */ vfp_flush_hwstate(thread);