public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Borislav Petkov <bp@alien8.de>
To: Tony Luck <tony.luck@intel.com>
Cc: Qiuxu Zhuo <qiuxu.zhuo@intel.com>,
	Aristeu Rozanski <aris@redhat.com>,
	Mauro Carvalho Chehab <mchehab@s-opensource.com>,
	Kan Liang <kan.liang@linux.intel.com>,
	linux-edac@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH 2/4] EDAC, skx_edac: Delete the duplicated codes
Date: Tue, 29 Jan 2019 18:12:24 +0100	[thread overview]
Message-ID: <20190129171224.GE27037@zn.tnic> (raw)
In-Reply-To: <20190125195902.17109-3-tony.luck@intel.com>

On Fri, Jan 25, 2019 at 11:59:00AM -0800, Tony Luck wrote:
> From: Qiuxu Zhuo <qiuxu.zhuo@intel.com>
> 
> Part of the skx_edac driver codes are carved to the skx_comm_edac.c
> file, which are used by both skx_edac driver and i10nm_edac driver.
> Delete the duplicated codes from the skx_edac.c file and rename
> skx_edac.c to skx_base.c. Update the Makefile to build the skx_edac
> driver from skx_base.c plux skx_comm_edac.c
> 
> Co-developed-by: Tony Luck <tony.luck@intel.com>
> Signed-off-by: Qiuxu Zhuo <qiuxu.zhuo@intel.com>
> Signed-off-by: Tony Luck <tony.luck@intel.com>
> ---
>  drivers/edac/Makefile   |    4 +-
>  drivers/edac/skx_base.c |  673 +++++++++++++++++++
>  drivers/edac/skx_edac.c | 1358 ---------------------------------------
>  3 files changed, 676 insertions(+), 1359 deletions(-)
>  create mode 100644 drivers/edac/skx_base.c
>  delete mode 100644 drivers/edac/skx_edac.c

Please integrate scripts/checkpatch.pl into your patch creation
workflow. Some of the warnings/errors *actually* make sense.

Sensible warnings:

WARNING: Missing or malformed SPDX-License-Identifier tag in line 1
#65: FILE: drivers/edac/skx_base.c:1:
+/*

WARNING: Use #include <linux/processor.h> instead of <asm/processor.h>
#97: FILE: drivers/edac/skx_base.c:33:
+#include <asm/processor.h>

> diff --git a/drivers/edac/Makefile b/drivers/edac/Makefile
> index 716096d08ea0..1764b7ed05db 100644
> --- a/drivers/edac/Makefile
> +++ b/drivers/edac/Makefile
> @@ -30,7 +30,6 @@ obj-$(CONFIG_EDAC_I5400)		+= i5400_edac.o
>  obj-$(CONFIG_EDAC_I7300)		+= i7300_edac.o
>  obj-$(CONFIG_EDAC_I7CORE)		+= i7core_edac.o
>  obj-$(CONFIG_EDAC_SBRIDGE)		+= sb_edac.o
> -obj-$(CONFIG_EDAC_SKX)			+= skx_edac.o
>  obj-$(CONFIG_EDAC_PND2)			+= pnd2_edac.o
>  obj-$(CONFIG_EDAC_E7XXX)		+= e7xxx_edac.o
>  obj-$(CONFIG_EDAC_E752X)		+= e752x_edac.o
> @@ -58,6 +57,9 @@ obj-$(CONFIG_EDAC_MPC85XX)		+= mpc85xx_edac_mod.o
>  layerscape_edac_mod-y			:= fsl_ddr_edac.o layerscape_edac.o
>  obj-$(CONFIG_EDAC_LAYERSCAPE)		+= layerscape_edac_mod.o
>  
> +skx_edac-y				:= skx_comm_edac.o skx_base.o
> +obj-$(CONFIG_EDAC_SKX)			+= skx_edac.o
> +
>  obj-$(CONFIG_EDAC_MV64X60)		+= mv64x60_edac.o
>  obj-$(CONFIG_EDAC_CELL)			+= cell_edac.o
>  obj-$(CONFIG_EDAC_PPC4XX)		+= ppc4xx_edac.o
> diff --git a/drivers/edac/skx_base.c b/drivers/edac/skx_base.c
> new file mode 100644
> index 000000000000..4aa53c15b89b
> --- /dev/null
> +++ b/drivers/edac/skx_base.c
> @@ -0,0 +1,673 @@
> +/*
> + * EDAC driver for Intel(R) Xeon(R) Skylake processors
> + * Copyright (c) 2016, Intel Corporation.
> + *
> + * This program is free software; you can redistribute it and/or modify it
> + * under the terms and conditions of the GNU General Public License,
> + * version 2, as published by the Free Software Foundation.
> + *
> + * This program is distributed in the hope it will be useful, but WITHOUT
> + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
> + * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License for
> + * more details.
> + */

First patch adds SPDX headers - this one has the old licensing thing. Pls fix.


> +
> +#include <linux/module.h>
> +#include <linux/init.h>
> +#include <linux/acpi.h>
> +#include <linux/dmi.h>
> +#include <linux/pci.h>
> +#include <linux/pci_ids.h>
> +#include <linux/slab.h>
> +#include <linux/delay.h>
> +#include <linux/edac.h>
> +#include <linux/mmzone.h>
> +#include <linux/smp.h>
> +#include <linux/bitmap.h>
> +#include <linux/math64.h>
> +#include <linux/mod_devicetable.h>
> +#include <linux/adxl.h>
> +#include <acpi/nfit.h>
> +#include <asm/cpu_device_id.h>
> +#include <asm/intel-family.h>
> +#include <asm/processor.h>
> +#include <asm/mce.h>

*all* those includes are needed?!

> +
> +#include "edac_module.h"
> +#include "skx_comm_edac.h"

This one has some of the above includes too.

...

-- 
Regards/Gruss,
    Boris.

Good mailing practices for 400: avoid top-posting and trim the reply.

  reply	other threads:[~2019-01-29 17:12 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-01-25 19:58 [PATCH 0/4] EDAC driver for Jacobsville microserver Tony Luck
2019-01-25 19:58 ` [PATCH 1/4] EDAC, skx_comm_edac: Separate common codes from the skx_edac driver Tony Luck
2019-01-29 16:09   ` Borislav Petkov
2019-01-25 19:59 ` [PATCH 2/4] EDAC, skx_edac: Delete the duplicated codes Tony Luck
2019-01-29 17:12   ` Borislav Petkov [this message]
2019-01-25 19:59 ` [PATCH 3/4] x86: intel-family.h: Add Atom Tremont (Jacobsville) Tony Luck
2019-01-29 15:48   ` [tip:x86/urgent] x86/cpu: " tip-bot for Kan Liang
2019-01-25 19:59 ` [PATCH 4/4] EDAC, i10nm_edac: Add EDAC driver for Intel 10nm server processors Tony Luck

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20190129171224.GE27037@zn.tnic \
    --to=bp@alien8.de \
    --cc=aris@redhat.com \
    --cc=kan.liang@linux.intel.com \
    --cc=linux-edac@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mchehab@s-opensource.com \
    --cc=qiuxu.zhuo@intel.com \
    --cc=tony.luck@intel.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox