linuxppc-dev.lists.ozlabs.org archive mirror
 help / color / mirror / Atom feed
From: Masahiro Yamada <masahiroy@kernel.org>
To: Christophe Leroy <christophe.leroy@csgroup.eu>
Cc: Linux Kernel Mailing List <linux-kernel@vger.kernel.org>,
	Nicholas Piggin <npiggin@gmail.com>,
	Paul Mackerras <paulus@samba.org>,
	"Aneesh Kumar K.V" <aneesh.kumar@linux.ibm.com>,
	linuxppc-dev <linuxppc-dev@lists.ozlabs.org>,
	Ard Biesheuvel <ardb@kernel.org>
Subject: Re: [PATCH] powerpc: clean vdso32 and vdso64 directories
Date: Wed, 17 Nov 2021 23:58:52 +0900	[thread overview]
Message-ID: <CAK7LNAQ4KD4zG2Me7RhsJNOXrMqDOHpd2YNoSPH4CZ63HXtqpQ@mail.gmail.com> (raw)
In-Reply-To: <0cdd39b2-73f8-e0c1-bfa2-7940d4b788f0@csgroup.eu>

On Wed, Nov 17, 2021 at 12:38 AM Christophe Leroy
<christophe.leroy@csgroup.eu> wrote:
>
> Hi Masahiro,
>
> Le 09/11/2021 à 19:50, Masahiro Yamada a écrit :
> > Since commit bce74491c300 ("powerpc/vdso: fix unnecessary rebuilds of
> > vgettimeofday.o"), "make ARCH=powerpc clean" does not clean up the
> > arch/powerpc/kernel/{vdso32,vdso64} directories.
> >
> > Use the subdir- trick to let "make clean" descend into them.
> >
> > Fixes: bce74491c300 ("powerpc/vdso: fix unnecessary rebuilds of vgettimeofday.o")
> > Signed-off-by: Masahiro Yamada <masahiroy@kernel.org>
> > ---
> >
> >   arch/powerpc/kernel/Makefile | 3 +++
> >   1 file changed, 3 insertions(+)
> >
> > diff --git a/arch/powerpc/kernel/Makefile b/arch/powerpc/kernel/Makefile
> > index 0e3640e14eb1..5fa68c2ef1f8 100644
> > --- a/arch/powerpc/kernel/Makefile
> > +++ b/arch/powerpc/kernel/Makefile
> > @@ -196,3 +196,6 @@ clean-files := vmlinux.lds
> >   # Force dependency (incbin is bad)
> >   $(obj)/vdso32_wrapper.o : $(obj)/vdso32/vdso32.so.dbg
> >   $(obj)/vdso64_wrapper.o : $(obj)/vdso64/vdso64.so.dbg
> > +
> > +# for cleaning
> > +subdir- += vdso32 vdso64
> >
>
> This patch make me think about one thing I would have liked to do, but I
> don't know Makefiles well enough to be able to do it. You could probably
> help me with it.
>
> vdso32 and vdso64 contain a lot of redundant sources. I would like to
> merge them into a new single directory, let say 'vdso', and use the
> files in that directory to build both vdso32.so and vdso64.so. I have a
> feeling that x86 is doing it that way, but I've not been able to figure
> out how to build two objects using the same C/S files.
>
> Thanks
> Christophe

Changing the code as follows might work.

$(obj-vdso32): %-32.o: %.S FORCE
          $(call if_changed_dep,vdso32as)




-- 
Best Regards
Masahiro Yamada

  reply	other threads:[~2021-11-17 15:08 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-11-09 18:50 [PATCH] powerpc: clean vdso32 and vdso64 directories Masahiro Yamada
2021-11-16 15:37 ` Christophe Leroy
2021-11-17 14:58   ` Masahiro Yamada [this message]
2021-11-17 11:23 ` Michael Ellerman

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=CAK7LNAQ4KD4zG2Me7RhsJNOXrMqDOHpd2YNoSPH4CZ63HXtqpQ@mail.gmail.com \
    --to=masahiroy@kernel.org \
    --cc=aneesh.kumar@linux.ibm.com \
    --cc=ardb@kernel.org \
    --cc=christophe.leroy@csgroup.eu \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linuxppc-dev@lists.ozlabs.org \
    --cc=npiggin@gmail.com \
    --cc=paulus@samba.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;
as well as URLs for NNTP newsgroup(s).