[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [PATCH v1 03/14] xen/riscv: add <asm/riscv_encoding.h header


  • To: Oleksii Kurochko <oleksii.kurochko@xxxxxxxxx>
  • From: Jan Beulich <jbeulich@xxxxxxxx>
  • Date: Mon, 23 Jan 2023 14:52:17 +0100
  • Arc-authentication-results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=suse.com; dmarc=pass action=none header.from=suse.com; dkim=pass header.d=suse.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=pD5i5hhY1nZSOzoKHijR6N4P0OTNGI2TYPx9edKEDWk=; b=hQD10UDNfIaJ6jVTXUSGj8AZ3sNq/O0N7FdTPKtwpBZvo+mf8gAS2yg/CiNhRDQ4s2eW2X3TxHfjXInLHTPVKK4iooYL6HizGQma3qfIvu2EZEvKOgY+o5qatKJCMoo76ZETyPzK0z+J8zu1Y0jCalgcStG6OutGZvcAygunBrdjT0U6RKZPCP4TDazwemWy/VsxJOHQVosik4BLdUDgJMpQUztDH+AUh8WmZjCxddXlB740Qk+Ww4zxAkgibuLLEj4B70BlusiEZoGIGDMGEMC/WHKwMmYhQ6yFIF9lqFN9fKk+aht5cgMwxGLtlbtkGlwiKvGet+lZTEKQD9Q4nQ==
  • Arc-seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=MzRPmFS/2z5ZrfRukGIkXifvvRYhSn7SaS31/q8FytEtKeXhUxawzA5+Wpes/Ys4tqC+jrFox4hEXrOhWMMIsyaix4BdqW4f2S+7GVVajpah//Z0QXZprr1VizV6PWXanmYGW3ijjJSfyIVCjPOQ4vAvmD+Qpd6ZcU1mfINXoX+XExNkW89sKUXlHKcs8C5q27DbwZHXvw/aXlmdbIMrct8Ea5tMDoI5CfWK5DDgXxv26XUSVPxoYZwYhzEdQkKTmJR2d4SiH8fZDtJ3PjetV7iXDwwPRnBnMeTcKF5AlysXOZMz04RLJ9Gak1ghpQLLCAr3JmMrtrVdyxdQsdyT5w==
  • Authentication-results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=suse.com;
  • Cc: Andrew Cooper <andrew.cooper3@xxxxxxxxxx>, Stefano Stabellini <sstabellini@xxxxxxxxxx>, Gianluca Guida <gianluca@xxxxxxxxxxxx>, Bob Eshleman <bobbyeshleman@xxxxxxxxx>, Alistair Francis <alistair.francis@xxxxxxx>, Connor Davis <connojdavis@xxxxxxxxx>, xen-devel@xxxxxxxxxxxxxxxxxxxx
  • Delivery-date: Mon, 23 Jan 2023 13:53:05 +0000
  • List-id: Xen developer discussion <xen-devel.lists.xenproject.org>

On 20.01.2023 15:59, Oleksii Kurochko wrote:
> Signed-off-by: Oleksii Kurochko <oleksii.kurochko@xxxxxxxxx>

I was about to commit this, but ...

> --- /dev/null
> +++ b/xen/arch/riscv/include/asm/riscv_encoding.h
> @@ -0,0 +1,945 @@
> +/* SPDX-License-Identifier: (GPL-2.0-or-later OR BSD-2-Clause) */
> +/*
> + * Copyright (c) 2019 Western Digital Corporation or its affiliates.
> + *
> + * Authors:
> + *   Anup Patel <anup.patel@xxxxxxx>

... this raises a patch authorship question: Are you missing her/his
S-o-b: and/or From:? 

> + * The source has been largely adapted from OpenSBI:
> + * include/sbi/riscv_encodnig.h

Nit: Typo.

> + * 

Nit: trailing blank.

There also look to be hard tabs in the file. This is fine if the file
is being imported (almost) verbatim from elsewhere, but then the origin
wants stating in an Origin: tag (see docs/process/sending-patches.pandoc).

>[...]
> +#define IMM_I(insn)                  ((s32)(insn) >> 20)
> +#define IMM_S(insn)                  (((s32)(insn) >> 25 << 5) | \
> +                                      (s32)(((insn) >> 7) & 0x1f))

Please can you avoid introducing new instances of s<N> or u<N>? See
./CODING_STYLE.

Jan



 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.