<feed xmlns='http://www.w3.org/2005/Atom'>
<title>kernel.git/arch/m68k/Makefile, branch linux-5.13.y</title>
<subtitle>Hosts the 0x221E linux distro kernel.
</subtitle>
<id>https://git.0xinfinity.dev/distro/kernel.git/atom?h=linux-5.13.y</id>
<link rel='self' href='https://git.0xinfinity.dev/distro/kernel.git/atom?h=linux-5.13.y'/>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/'/>
<updated>2021-05-05T16:49:13Z</updated>
<entry>
<title>arch: use cross_compiling to check whether it is a cross build or not</title>
<updated>2021-05-05T16:49:13Z</updated>
<author>
<name>Masahiro Yamada</name>
</author>
<published>2021-05-01T17:24:36Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=23243c1ace9fb4eae2f75e0fe0ece8e3219fb4f3'/>
<id>urn:sha1:23243c1ace9fb4eae2f75e0fe0ece8e3219fb4f3</id>
<content type='text'>
'cross_compiling' is defined by the top Makefile and available for
arch Makefiles to check whether it is a cross build or not. A good
thing is the variable name 'cross_compiling' is self-documenting.

This is a simple replacement for m68k, mips, sh, for which $(ARCH)
and $(SRCARCH) always match.

No functional change is intended for xtensa, either.

This is rather a fix for parisc because arch/parisc/Makefile defines
UTS_MATCHINE depending on CONFIG_64BIT, therefore cc-cross-prefix
is not working in Kconfig time.

Signed-off-by: Masahiro Yamada &lt;masahiroy@kernel.org&gt;
Acked-by: Geert Uytterhoeven &lt;geert@linux-m68k.org&gt;
Acked-by: Helge Deller &lt;deller@gmx.de&gt;  # parisc
Acked-by: Max Filippov &lt;jcmvbkbc@gmail.com&gt; # xtensa
</content>
</entry>
<entry>
<title>kbuild: preprocess module linker script</title>
<updated>2020-09-24T15:36:41Z</updated>
<author>
<name>Masahiro Yamada</name>
</author>
<published>2020-09-08T04:27:08Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=596b0474d3d9b1242eab713f84d8873f9887d980'/>
<id>urn:sha1:596b0474d3d9b1242eab713f84d8873f9887d980</id>
<content type='text'>
There was a request to preprocess the module linker script like we
do for the vmlinux one. (https://lkml.org/lkml/2020/8/21/512)

The difference between vmlinux.lds and module.lds is that the latter
is needed for external module builds, thus must be cleaned up by
'make mrproper' instead of 'make clean'. Also, it must be created
by 'make modules_prepare'.

You cannot put it in arch/$(SRCARCH)/kernel/, which is cleaned up by
'make clean'. I moved arch/$(SRCARCH)/kernel/module.lds to
arch/$(SRCARCH)/include/asm/module.lds.h, which is included from
scripts/module.lds.S.

scripts/module.lds is fine because 'make clean' keeps all the
build artifacts under scripts/.

You can add arch-specific sections in &lt;asm/module.lds.h&gt;.

Signed-off-by: Masahiro Yamada &lt;masahiroy@kernel.org&gt;
Tested-by: Jessica Yu &lt;jeyu@kernel.org&gt;
Acked-by: Will Deacon &lt;will@kernel.org&gt;
Acked-by: Geert Uytterhoeven &lt;geert@linux-m68k.org&gt;
Acked-by: Palmer Dabbelt &lt;palmerdabbelt@google.com&gt;
Reviewed-by: Kees Cook &lt;keescook@chromium.org&gt;
Acked-by: Jessica Yu &lt;jeyu@kernel.org&gt;
</content>
</entry>
<entry>
<title>m68k: Use CLEAN_FILES to clean up files</title>
<updated>2020-07-13T09:39:13Z</updated>
<author>
<name>Masahiro Yamada</name>
</author>
<published>2020-06-17T03:11:53Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=e3a549487f08f6326b24e92b3d87f9683f1d74a4'/>
<id>urn:sha1:e3a549487f08f6326b24e92b3d87f9683f1d74a4</id>
<content type='text'>
The log of 'make ARCH=m68k clean' does not look nice.

$ make ARCH=m68k clean
  CLEAN   arch/m68k/kernel
  [ snip ]
  CLEAN   usr
rm -f vmlinux.gz vmlinux.bz2
  CLEAN   vmlinux.symvers modules.builtin modules.builtin.modinfo

Use CLEAN_FILES to simplify the code, and beautify the log.

Signed-off-by: Masahiro Yamada &lt;masahiroy@kernel.org&gt;
Link: https://lore.kernel.org/r/20200617031153.85858-1-masahiroy@kernel.org
Signed-off-by: Geert Uytterhoeven &lt;geert@linux-m68k.org&gt;
</content>
</entry>
<entry>
<title>m68k: Pass -D options to KBUILD_CPPFLAGS instead of KBUILD_{A,C}FLAGS</title>
<updated>2020-07-13T09:39:13Z</updated>
<author>
<name>Masahiro Yamada</name>
</author>
<published>2020-05-26T12:38:10Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=40b13fd7fd6e1ec295230cc114c6c9309e15784a'/>
<id>urn:sha1:40b13fd7fd6e1ec295230cc114c6c9309e15784a</id>
<content type='text'>
Precisely, -D is a preprocessor option.

KBUILD_CPPFLAGS is passed for compiling .c and .S files too.

Signed-off-by: Masahiro Yamada &lt;masahiroy@kernel.org&gt;
Acked-by: Greg Ungerer &lt;gerg@linux-m68k.org&gt;
Link: https://lore.kernel.org/r/20200526123810.301667-4-masahiroy@kernel.org
Signed-off-by: Geert Uytterhoeven &lt;geert@linux-m68k.org&gt;
</content>
</entry>
<entry>
<title>m68k: Optimize cc-option calls for cpuflags-y</title>
<updated>2020-07-13T09:39:13Z</updated>
<author>
<name>Masahiro Yamada</name>
</author>
<published>2020-05-26T12:38:09Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=2367b0264294a50cd2cd9d4c1270a9393f32038c'/>
<id>urn:sha1:2367b0264294a50cd2cd9d4c1270a9393f32038c</id>
<content type='text'>
arch/m68k/Makefile computes lots of unneeded cc-option calls.

For example, if CONFIG_M5441x is not defined, there is not point in
evaluating the following compiler flag.

 cpuflags-$(CONFIG_M5441x)      := $(call cc-option,-mcpu=54455,-mcfv4e)

The result is set to cpuflags-, then thrown away.

The right hand side of ':=' is immediately expanded. Hence, all of the
16 calls for cc-option are evaluated. This is expensive since cc-option
invokes the compiler. This occurs even if you are not attempting to
build anything, like 'make ARCH=m68k help'.

Use '=' to expand the value _lazily_. The evaluation for cc-option is
delayed until $(cpuflags-y) is expanded. So, the cc-option test happens
just once at most.

This commit mimics tune-y of arch/arm/Makefile.

Signed-off-by: Masahiro Yamada &lt;masahiroy@kernel.org&gt;
Acked-by: Greg Ungerer &lt;gerg@linux-m68k.org&gt;
Link: https://lore.kernel.org/r/20200526123810.301667-3-masahiroy@kernel.org
Signed-off-by: Geert Uytterhoeven &lt;geert@linux-m68k.org&gt;
</content>
</entry>
<entry>
<title>m68k: Add arch/m68k/Kbuild</title>
<updated>2020-07-13T09:39:12Z</updated>
<author>
<name>Masahiro Yamada</name>
</author>
<published>2020-05-26T12:38:07Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=028a342ec8e128c5d71548d1210f1dba1ae95332'/>
<id>urn:sha1:028a342ec8e128c5d71548d1210f1dba1ae95332</id>
<content type='text'>
Use the standard obj-y form to specify the sub-directories under
arch/m68k/. No functional change intended.

Signed-off-by: Masahiro Yamada &lt;masahiroy@kernel.org&gt;
Acked-by: Greg Ungerer &lt;gerg@linux-m68k.org&gt;
Link: https://lore.kernel.org/r/20200526123810.301667-1-masahiroy@kernel.org
Signed-off-by: Geert Uytterhoeven &lt;geert@linux-m68k.org&gt;
</content>
</entry>
<entry>
<title>kbuild: fix broken builds because of GZIP,BZIP2,LZOP variables</title>
<updated>2020-06-11T11:14:41Z</updated>
<author>
<name>Denis Efremov</name>
</author>
<published>2020-06-08T09:59:44Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=e4a42c82e943b97ce124539fcd7a47445b43fa0d'/>
<id>urn:sha1:e4a42c82e943b97ce124539fcd7a47445b43fa0d</id>
<content type='text'>
Redefine GZIP, BZIP2, LZOP variables as KGZIP, KBZIP2, KLZOP resp.
GZIP, BZIP2, LZOP env variables are reserved by the tools. The original
attempt to redefine them internally doesn't work in makefiles/scripts
intercall scenarios, e.g., "make GZIP=gzip bindeb-pkg" and results in
broken builds. There can be other broken build commands because of this,
so the universal solution is to use non-reserved env variables for the
compression tools.

Fixes: 8dfb61dcbace ("kbuild: add variables for compression tools")
Signed-off-by: Denis Efremov &lt;efremov@linux.com&gt;
Tested-by: Guenter Roeck &lt;linux@roeck-us.net&gt;
Signed-off-by: Masahiro Yamada &lt;masahiroy@kernel.org&gt;
</content>
</entry>
<entry>
<title>kbuild: add variables for compression tools</title>
<updated>2020-06-06T14:42:01Z</updated>
<author>
<name>Denis Efremov</name>
</author>
<published>2020-06-05T07:39:55Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=8dfb61dcbaceb19a5ded5e9c9dcf8d05acc32294'/>
<id>urn:sha1:8dfb61dcbaceb19a5ded5e9c9dcf8d05acc32294</id>
<content type='text'>
Allow user to use alternative implementations of compression tools,
such as pigz, pbzip2, pxz. For example, multi-threaded tools to
speed up the build:
$ make GZIP=pigz BZIP2=pbzip2

Variables _GZIP, _BZIP2, _LZOP are used internally because original env
vars are reserved by the tools. The use of GZIP in gzip tool is obsolete
since 2015. However, alternative implementations (e.g., pigz) still rely
on it. BZIP2, BZIP, LZOP vars are not obsolescent.

The credit goes to @grsecurity.

As a sidenote, for multi-threaded lzma, xz compression one can use:
$ export XZ_OPT="--threads=0"

Signed-off-by: Denis Efremov &lt;efremov@linux.com&gt;
Signed-off-by: Masahiro Yamada &lt;masahiroy@kernel.org&gt;
</content>
</entry>
<entry>
<title>kbuild: rebuild modules when module linker scripts are updated</title>
<updated>2019-08-21T12:05:21Z</updated>
<author>
<name>Masahiro Yamada</name>
</author>
<published>2019-08-14T16:06:22Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=10df063855822fcea3c0f51dbf534ad643d3cb1b'/>
<id>urn:sha1:10df063855822fcea3c0f51dbf534ad643d3cb1b</id>
<content type='text'>
Currently, the timestamp of module linker scripts are not checked.
Add them to the dependency of modules so they are correctly rebuilt.

Signed-off-by: Masahiro Yamada &lt;yamada.masahiro@socionext.com&gt;
</content>
</entry>
<entry>
<title>m68k: Add -ffreestanding to CFLAGS</title>
<updated>2019-01-21T09:36:53Z</updated>
<author>
<name>Finn Thain</name>
</author>
<published>2019-01-16T05:23:24Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=28713169d879b67be2ef2f84dcf54905de238294'/>
<id>urn:sha1:28713169d879b67be2ef2f84dcf54905de238294</id>
<content type='text'>
This patch fixes a build failure when using GCC 8.1:

/usr/bin/ld: block/partitions/ldm.o: in function `ldm_parse_tocblock':
block/partitions/ldm.c:153: undefined reference to `strcmp'

This is caused by a new optimization which effectively replaces a
strncmp() call with a strcmp() call. This affects a number of strncmp()
call sites in the kernel.

The entire class of optimizations is avoided with -fno-builtin, which
gets enabled by -ffreestanding. This may avoid possible future build
failures in case new optimizations appear in future compilers.

I haven't done any performance measurements with this patch but I did
count the function calls in a defconfig build. For example, there are now
23 more sprintf() calls and 39 fewer strcpy() calls. The effect on the
other libc functions is smaller.

If this harms performance we can tackle that regression by optimizing
the call sites, ideally using semantic patches. That way, clang and ICC
builds might benfit too.

Cc: stable@vger.kernel.org
Reference: https://marc.info/?l=linux-m68k&amp;m=154514816222244&amp;w=2
Signed-off-by: Finn Thain &lt;fthain@telegraphics.com.au&gt;
Signed-off-by: Geert Uytterhoeven &lt;geert@linux-m68k.org&gt;
</content>
</entry>
</feed>
