Linux-ARM-Kernel Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: Shaokun Zhang <zhangshaokun@hisilicon.com>
To: Will Deacon <will@kernel.org>
Cc: Catalin Marinas <catalin.marinas@arm.com>,
	linux-arm-kernel@lists.infradead.org
Subject: Re: [PATCH] arm64: mm: Remove unused header file
Date: Wed, 27 Jan 2021 15:23:40 +0800	[thread overview]
Message-ID: <02fb1522-06f1-2b3a-c9e6-549e883ad748@hisilicon.com> (raw)
In-Reply-To: <20210126123940.GA29702@willie-the-truck>

Hi Will,

在 2021/1/26 20:39, Will Deacon 写道:
> On Tue, Jan 26, 2021 at 08:24:44PM +0800, Shaokun Zhang wrote:
>> Many header files are never used, let's remove them directly.
>>
>> Cc: Catalin Marinas <catalin.marinas@arm.com>
>> Cc: Will Deacon <will@kernel.org>
>> Signed-off-by: Shaokun Zhang <zhangshaokun@hisilicon.com>
>> ---
>>  arch/arm64/mm/mmap.c | 14 ++------------
>>  1 file changed, 2 insertions(+), 12 deletions(-)
>>
>> diff --git a/arch/arm64/mm/mmap.c b/arch/arm64/mm/mmap.c
>> index 07937b49cb88..c66b3878712c 100644
>> --- a/arch/arm64/mm/mmap.c
>> +++ b/arch/arm64/mm/mmap.c
>> @@ -5,20 +5,10 @@
>>   * Copyright (C) 2012 ARM Ltd.
>>   */
>>  
>> -#include <linux/elf.h>
>> -#include <linux/fs.h>
>>  #include <linux/memblock.h>
>> -#include <linux/mm.h>
>> -#include <linux/mman.h>
>> -#include <linux/export.h>
>> -#include <linux/shm.h>
>> -#include <linux/sched/signal.h>
>> -#include <linux/sched/mm.h>
>> -#include <linux/io.h>
>> -#include <linux/personality.h>
>> -#include <linux/random.h>
>> +#include <linux/types.h>
>>  
>> -#include <asm/cputype.h>
>> +#include <asm/page.h>
> 
> How did you determine that these are safe to remove?
> 

To be honest, it is done by observation when I dig my devmem failure.
I checked this file changed much and some header files are not necessary.

I did devmem test and it worked when I changed these.
Apologies that the io.h is still needed for the previous prototype.

Thanks,
Shaokun

> Will
> .
> 

_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

  reply	other threads:[~2021-01-27  7:25 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-01-26 12:24 [PATCH] arm64: mm: Remove unused header file Shaokun Zhang
2021-01-26 12:39 ` Will Deacon
2021-01-27  7:23   ` Shaokun Zhang [this message]
2021-01-26 23:39 ` Will Deacon

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=02fb1522-06f1-2b3a-c9e6-549e883ad748@hisilicon.com \
    --to=zhangshaokun@hisilicon.com \
    --cc=catalin.marinas@arm.com \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=will@kernel.org \
    /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