[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <684e0db2-cf7c-d5e0-97dc-668d471e37e9@infradead.org>
Date: Wed, 12 Jul 2023 08:02:05 -0700
From: Randy Dunlap <rdunlap@...radead.org>
To: huzhi001@...suo.com, tglx@...utronix.de, mingo@...hat.com,
bp@...en8.de, dave.hansen@...ux.intel.com, x86@...nel.org
Cc: hpa@...or.com, linux-kernel@...r.kernel.org
Subject: Re: [PATCH] x86/amd_nb: Fix warnings in amd_nb.h
On 7/12/23 06:02, huzhi001@...suo.com wrote:
> The following checkpatch warnings are removed:
> WARNING: function definition argument 'int' should also-
> -have an identifier name
> WARNING: function definition argument 'int' should also-
> -have an identifier name
It appears that checkpatch should be modified to say that function
definition arguments should have a meaningful or useful name,
not just an identifier name.
> WARNING: function definition argument 'unsigned long'-
> -should also have an identifier name
> WARNING: Prefer 'unsigned int' to bare use of 'unsigned'
>
> Signed-off-by: ZhiHu <huzhi001@...suo.com>
> ---
> arch/x86/include/asm/amd_nb.h | 6 +++---
> 1 file changed, 3 insertions(+), 3 deletions(-)
>
> diff --git a/arch/x86/include/asm/amd_nb.h b/arch/x86/include/asm/amd_nb.h
> index ed0eaf65c437..73a70daa919d 100644
> --- a/arch/x86/include/asm/amd_nb.h
> +++ b/arch/x86/include/asm/amd_nb.h
> @@ -18,14 +18,14 @@ extern bool early_is_amd_nb(u32 value);
> extern struct resource *amd_get_mmconfig_range(struct resource *res);
> extern void amd_flush_garts(void);
> extern int amd_numa_init(void);
> -extern int amd_get_subcaches(int);
> -extern int amd_set_subcaches(int, unsigned long);
> +extern int amd_get_subcaches(int value1);
> +extern int amd_set_subcaches(int value2, unsigned long value3);
>
> extern int amd_smn_read(u16 node, u32 address, u32 *value);
> extern int amd_smn_write(u16 node, u32 address, u32 value);
>
> struct amd_l3_cache {
> - unsigned indices;
> + unsigned int indices;
> u8 subcaches[4];
> };
--
~Randy
Powered by blists - more mailing lists