[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH v2 3/3] xen/riscv: disable fpu
- To: Oleksii Kurochko <oleksii.kurochko@xxxxxxxxx>, xen-devel@xxxxxxxxxxxxxxxxxxxx
- From: Andrew Cooper <andrew.cooper3@xxxxxxxxxx>
- Date: Thu, 2 Mar 2023 14:20:06 +0000
- Arc-authentication-results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=citrix.com; dmarc=pass action=none header.from=citrix.com; dkim=pass header.d=citrix.com; arc=none
- 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=coRTInJ5pmJPcv4PnlCTTNmIBDb9Je+S0OzPefYTrl4=; b=MzdHYnkwZuSW1ArjlnPRydiG5UrPTHKSRHQI1LSBwZHIdDjk6cV4Np9bQBG30tcjRj3Rzr9wPzNx5TlPH5sXpSoT+gWfjrI+BNE9Dd8GdAdjqbgB4Bran5UzC+3cwUSu+uWu2MbPGRk8esFemBLi+EfayQTq+9j7p7rFd7UVbu58l8bVZLzeiWhNrWP+pHHEEPD2PviZ8sKWhOxhPStPHWsfzzB21WjFanxX1/eFCBIR2+azcRvEfSXs0p5ZwXKOLfingXYd1WG2XIwW0jBwx94bU5tQttOUzd0jYUT30W4Yp1Ep1Ls3J+fooEGPtLOryWvESqqUjMqNFCdl35hXRA==
- Arc-seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=aiY0GBZknLmVVgSsBbcB+ZpH19zX8N60fCtZTIYbKDF0LpXs7C81PYwb7OvKZdQ6tVKLkzDNYnZCHEotDOnDy89b8q87szhonBYXkgcEdVqneaHJ+eWYRQWQmZvZZJkcVRxmjkNUe28h4+RheN56B6Fdxf9uCY94GF3m5WqR1oWWxgUL7nQuqmIXgHg3Vbwq3QcUMg8p8mGEz9wFfRdCKwHjPQQkx8xwn+QmbkVqd5G/bvqYgobo2aldAtttTxKO3U5ToWdQ4XGceViGBuI0bW7aP6FXPPVeihci8Rwv83WCSlQejsxRkVSFeJBMdDwrRzmjY6HWzUQ5SgyAayIvoA==
- Authentication-results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=citrix.com;
- Cc: Jan Beulich <jbeulich@xxxxxxxx>, Stefano Stabellini <sstabellini@xxxxxxxxxx>, Gianluca Guida <gianluca@xxxxxxxxxxxx>, Bob Eshleman <bobbyeshleman@xxxxxxxxx>, Alistair Francis <alistair.francis@xxxxxxx>, Connor Davis <connojdavis@xxxxxxxxx>
- Delivery-date: Thu, 02 Mar 2023 14:20:39 +0000
- Ironport-data: A9a23:6oAMFahK0Pu3NCiCZsDByODwX1611REKZh0ujC45NGQN5FlHY01je htvC2yFPqqMZWuhKt5wYNnn9UgP6MXUn4dqG1ZppSs1ECob9cadCdqndUqhZCn6wu8v7q5Ex 55HNoSfdpBcolv0/ErF3m3J9CEkvU2wbuOgTrWCYmYpHlUMpB4J0XpLg/Q+jpNjne+3CgaMv cKai8DEMRqu1iUc3lg8sspvkzsy+qWi0N8klgZmP6sT5weEzyN94K83fsldEVOpGuG4IcbiL wrz5OnR1n/U+R4rFuSknt7TGqHdauePVeQmoiM+t5mK2nCulARrukoIHKN0hXNsoyeIh7hMJ OBl7vRcf+uL0prkw4zxWzEAe8130DYvFLXveRBTuuTLp6HKnueFL1yDwyjaMKVBktubD12i+ tQpBwI3YhLe29i0wbWlbdtXqfwlIePkadZ3VnFIlVk1DN4AaLWaGeDgw48d2z09wMdTAfzZe swVLyJ1awjNaAFOPVFRD48imOCvhT/0dDgwRFC9/PJrpTSMilEsluGybrI5efTTLSlRtm+eq njL4CLSBRYCOcbE4TGE7mitlqnEmiaTtIc6Re3lqKM60Qb7Kmo7Nw0cTVnmvqSAiWGzQOB1E 309qnIkov1nnKCsZpynN/Gim1aDuhMfQNtRVe4n8gaGyqnTywmcD2kACDVGbbQOpMIwADAny FKNt9foHiB09q2YT2qH8bWZpi/0PjIaRUcAbyIZSQoO4/H4vZo+yBnIS75LC7Wph9f4HTXxx TGiryUkgbgXy8kR2M2T8lHOhTaxrZHhVA8r4R7WWGnj5QR8DKavYIai+FXA7fJNKY+fZlaEt XkA3cOZ6YgmBJWMjzCEQf9LEqug4f2EKxXDjVUpFJ4knxym/HileoJc6S9/P29mN88FfXniZ 0q7hO9KzJpaPX/vZ6knZYu0Up4u1fK5SoqjUe3IZN1TZJQ3bBWA4CxleU+X2SbqjVQolqY8f 5ycdK5AEEonNEiu9xLuL8917FPh7nlWKb/7LXwj8yma7A==
- Ironport-hdrordr: A9a23:X6dm4Kl77pm2ysAShiUYe5jR4dPpDfIi3DAbv31ZSRFFG/Fw9v rDoB1/73TJYVkqN03I9ervBEDjexPhHO9OgLX5VI3KNGOKhILCFvAA0WKN+UyEJwTOssJbyK d8Y+xfJbTLfDxHZB/BkWuFL+o=
- List-id: Xen developer discussion <xen-devel.lists.xenproject.org>
On 02/03/2023 1:23 pm, Oleksii Kurochko wrote:
> Disable FPU to detect illegal usage of floating point in kernel
> space.
>
> Signed-off-by: Oleksii Kurochko <oleksii.kurochko@xxxxxxxxx>
> ---
> Changes since v1:
> * Rebase on top of two previous patches.
> ---
Apologies - I meant to ask these on the previous series, but didn't get
around to it.
Why do we disable interrupts at the very start of start(), but only
disable the FPU at the start of C ?
To start with, doesn't OpenSBI have a starting ABI spec? What does that
say on the matter of the enablement of these features on entry into the
environment?
Either way, my gut feeling is that these disables (if necessary to begin
with) should be together, rather than split like this.
That aside, while I can see the value of checking this now, won't we
have to delete this again in order to allow for context switching a
vCPUs FPU register state?
~Andrew
|