[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Bug#749688: linux: add mips64 and mips64el support



Control: tag -1 moreinfo

On Thu, 2014-05-29 at 13:24 +0800, Yunqiang Su wrote:
> Package: src:linux
> Version: 3.15~rc7-1~exp1
> Control: user debian-mips@lists.debian.org
> Control: usertags -1 + mips-port
> Control: usertags -1 + mips-patch
> Control: stop
> 
> This patch, I add mips64 and mips64el support, with udebs built.
> In this patch, octeon for little endian (mipsel, mips64el are also
> added.)
> 
> It build successfully, while I haven't test the build result really.
> I built it with gcc-4.9, if anyone'd like  to help test it, you can
> get them from:
> 
> http://mips.wicp.net:9998/mips2/pool/main/l/linux/

If you built with gcc-4.9, why does this patch not specify that?

> diff -Nru linux-3.15~rc7/debian/config/defines linux-3.15~rc7/debian/config/defines
> --- linux-3.15~rc7/debian/config/defines        2014-05-14 15:41:05.000000000 +0000
> +++ linux-3.15~rc7/debian/config/defines        2014-05-29 04:59:28.000000000 +0000
> @@ -14,6 +14,8 @@
>   m68k
>   mips
>   mipsel
> + mips64
> + mips64el
>   or1k
>   powerpc
>   powerpcspe
> diff -Nru linux-3.15~rc7/debian/config/mips64/config linux-3.15~rc7/debian/config/mips64/config
> --- linux-3.15~rc7/debian/config/mips64/config  1970-01-01 00:00:00.000000000 +0000
> +++ linux-3.15~rc7/debian/config/mips64/config  2014-05-03 08:46:13.000000000 +0000
> @@ -0,0 +1,14 @@
> +##
> +## file: arch/mips/Kconfig
> +##
> +## choice: Endianness selection
> +CONFIG_CPU_BIG_ENDIAN=y
> +# CONFIG_CPU_LITTLE_ENDIAN is not set
> +## end choice
> +CONFIG_KEXEC=y
> +# CONFIG_RAPIDIO is not set
> +
> +##
> +## file: arch/mips/Kconfig.debug
> +##
> +CONFIG_EARLY_PRINTK=y

This is a copy of debian/config/mips/config.  Don't copy it, move it to
something like debian/config/kernelarch-mips/config-big-endian.

I just moved some common configuration from
debian/config/mips{,el}/config to debian/config/kernelarch-mips/config
so now they only contain the endianness selection.

> diff -Nru linux-3.15~rc7/debian/config/mips64/defines linux-3.15~rc7/debian/config/mips64/defines
> --- linux-3.15~rc7/debian/config/mips64/defines 1970-01-01 00:00:00.000000000 +0000
> +++ linux-3.15~rc7/debian/config/mips64/defines 2014-05-29 00:26:03.000000000 +0000
> @@ -0,0 +1,50 @@
> +[base]
> +flavours:
> + r4k-ip22
> + r5k-ip32
> + sb1-bcm91250a
> + 5kc-malta
> + octeon

I don't think we should build such a large number of flavours for a new
architecture.  Most of those machines are obsolete by now.

> +kernel-arch: mips
> +
> +[build]
> +image-file: vmlinux
> +
> +[image]
> +initramfs: false

All new architectures must use an initramfs.  The 32-bit MIPS
architectures still don't, but they really should as this deviation is a
long-running annoyance.

> --- linux-3.15~rc7/debian/config/mips64el/config        1970-01-01 00:00:00.000000000 +0000
> +++ linux-3.15~rc7/debian/config/mips64el/config        2014-05-03 08:46:13.000000000 +0000
[...]
> --- linux-3.15~rc7/debian/config/mips64el/config.loongson-2e    1970-01-01 00:00:00.000000000 +0000
> +++ linux-3.15~rc7/debian/config/mips64el/config.loongson-2e    2014-05-03 08:46:13.000000000 +0000
[...]
> --- linux-3.15~rc7/debian/config/mips64el/config.loongson-2f    1970-01-01 00:00:00.000000000 +0000
> +++ linux-3.15~rc7/debian/config/mips64el/config.loongson-2f    2014-05-03 08:46:13.000000000 +0000
[...]
> --- linux-3.15~rc7/debian/config/mips64el/config.loongson-3     1970-01-01 00:00:00.000000000 +0000
> +++ linux-3.15~rc7/debian/config/mips64el/config.loongson-3     2014-05-06 09:37:03.000000000 +0000
[...]

More copied files that should not be.

> diff -Nru linux-3.15~rc7/debian/config/mipsel/defines linux-3.15~rc7/debian/config/mipsel/defines
> --- linux-3.15~rc7/debian/config/mipsel/defines 2014-05-06 09:37:03.000000000 +0000
> +++ linux-3.15~rc7/debian/config/mipsel/defines 2014-05-29 00:27:04.000000000 +0000

This patch does a little more than the subject says!

> @@ -6,6 +6,7 @@
>   loongson-2e
>   loongson-2f
>   loongson-3
> + octeon

Is it useful to run Octeon on little-endian mode?

[...]
> diff -Nru linux-3.15~rc7/debian/installer/mips64/modules/mips64/btrfs-modules linux-3.15~rc7/debian/installer/mips64/modules/mips64/btrfs-modules
> --- linux-3.15~rc7/debian/installer/mips64/modules/mips64/btrfs-modules 1970-01-01 00:00:00.000000000 +0000
> +++ linux-3.15~rc7/debian/installer/mips64/modules/mips64/btrfs-modules 2014-05-29 02:20:50.000000000 +0000
> @@ -0,0 +1 @@
> +#include <btrfs-modules>
[...]

All the installer modules configuration files should be copied *by
reference* from mips or mipsel, either using a relative #include or a
directory symlink.

Ben.

-- 
Ben Hutchings
Any smoothly functioning technology is indistinguishable from a rigged demo.

Attachment: signature.asc
Description: This is a digitally signed message part


Reply to: