Cannot find the processor family for my powerpc in kernel - Powerpc

This is a discussion on Cannot find the processor family for my powerpc in kernel - Powerpc ; Hi, there, I know this may sound stupid. I am trying to compile a linux kernel for my IBM RS6000 44P-170 machine. I downloaded the 2.6.9 kernel from kernel.org but couldn't figure out where to start. When I do make ...

+ Reply to Thread
Results 1 to 8 of 8

Thread: Cannot find the processor family for my powerpc in kernel

  1. Cannot find the processor family for my powerpc in kernel

    Hi, there,

    I know this may sound stupid. I am trying to compile a linux kernel for my
    IBM RS6000 44P-170 machine. I downloaded the 2.6.9 kernel from kernel.org
    but couldn't figure out where to start. When I do make xconfig or make
    menuconfig, I cannot find the PowerPC or CHRP in the processor family, all I
    have are something like pentium, Atholon, etc. I wonder where can I set my
    CPU type?
    By the way, is this kernel the right one to download? I can see the arch/ppc
    and arch/ppc64 lying there. Maybe I should apply some patch?
    Couldn't find much useful information on this topic by google searching.
    Thanks in advance.

    Shi



  2. Re: Cannot find the processor family for my powerpc in kernel

    "Shi Jin" writes:

    > I know this may sound stupid. I am trying to compile a linux kernel for my
    > IBM RS6000 44P-170 machine. I downloaded the 2.6.9 kernel from kernel.org
    > but couldn't figure out where to start. When I do make xconfig or make
    > menuconfig, I cannot find the PowerPC or CHRP in the processor family, all I
    > have are something like pentium, Atholon, etc. I wonder where can I set my
    > CPU type?


    In the directories such as arch/ppc/configs and arch/ppc64/configs
    there are files such as `ibmchrp_defconfig' (I don't know if this is
    the correct config for your machine, but assume it is). Then, from
    the kernel source directory type:

    make ibmchrp_defconfig

    which will give a lot of text output as it sets the basic options for
    the kernel. Then you can try `make xconfig' to modify the result to
    your taste.

    > By the way, is this kernel the right one to download? I can see the arch/ppc
    > and arch/ppc64 lying there. Maybe I should apply some patch?
    > Couldn't find much useful information on this topic by google searching.


    Yes, the kernel is generic. It is easiest to do the basic setup using
    the default scripts as described above, then do your own
    configuration. One thing to watch for is that when you make the
    kernel the kernel will be called vmlinux, not the compressed image
    used in x86 linux.

    --
    Stephen Harker Stephen.Harker@spme.monash.edu.au
    School of Physics & Materials Engineering
    Monash University

  3. Re: Cannot find the processor family for my powerpc in kernel

    Thank you very much.
    But I think I missed one very important point: I am trying to cross
    compiling it on an X86 linux machine. Sorry about missing that. I took the
    x86 archetecture for too much granted.

    Is there any howto on that?

    I tried to use "make ibmchrp_defconfig" but it gives an error saying that
    arch/i386/configs/ibmchrp_defconfig is not there. Then I made a symbolic
    link from arch/i386/configs to arch/ppc/configs and it can make. But in
    the make xconfig menus I still cannot find powerpc. But this could be
    simply due to I am cross compiling it.

    Can you still help me?
    By the way, I noticed from the machine's mannual, it is a 64-bit machine.
    So shall I compile the ppc64 kernel instead of the ppc one? Thank you
    very much.

    Shi

    On Thu, 28 Oct 2004 08:16:21 +1000,
    Stephen Harker wrote:

    > "Shi Jin" writes:
    >
    >> I know this may sound stupid. I am trying to compile a linux kernel for my
    >> IBM RS6000 44P-170 machine. I downloaded the 2.6.9 kernel from kernel.org
    >> but couldn't figure out where to start. When I do make xconfig or make
    >> menuconfig, I cannot find the PowerPC or CHRP in the processor family, all I
    >> have are something like pentium, Atholon, etc. I wonder where can I set my
    >> CPU type?

    >
    > In the directories such as arch/ppc/configs and arch/ppc64/configs
    > there are files such as `ibmchrp_defconfig' (I don't know if this is
    > the correct config for your machine, but assume it is). Then, from
    > the kernel source directory type:
    >
    > make ibmchrp_defconfig
    >
    > which will give a lot of text output as it sets the basic options for
    > the kernel. Then you can try `make xconfig' to modify the result to
    > your taste.
    >
    >> By the way, is this kernel the right one to download? I can see the arch/ppc
    >> and arch/ppc64 lying there. Maybe I should apply some patch?
    >> Couldn't find much useful information on this topic by google searching.

    >
    > Yes, the kernel is generic. It is easiest to do the basic setup using
    > the default scripts as described above, then do your own
    > configuration. One thing to watch for is that when you make the
    > kernel the kernel will be called vmlinux, not the compressed image
    > used in x86 linux.



  4. Re: Cannot find the processor family for my powerpc in kernel

    Shi Jin writes:

    > Thank you very much.
    > But I think I missed one very important point: I am trying to cross
    > compiling it on an X86 linux machine. Sorry about missing that. I took the
    > x86 archetecture for too much granted.


    Okay, that adds another command you need. If you read the Makefile it
    has the following about cross-compilation:

    # When performing cross compilation for other architectures ARCH shall be set
    # to the target architecture. (See arch/* for the possibilities).
    # ARCH can be set during invocation of make:
    # make ARCH=ia64
    # Another way is to have ARCH set in the environment.
    # The default ARCH is the host where make is executed.

    > Is there any howto on that?


    So you would need something like:

    make ARCH=ppc ibmchrp_defconfig

    > Can you still help me?
    > By the way, I noticed from the machine's mannual, it is a 64-bit machine.
    > So shall I compile the ppc64 kernel instead of the ppc one? Thank you
    > very much.


    I don't know much about the architecture, but according to

    (found by a google search on "linux kernel IBM RS6000 44P-170") the
    author used the standard power3 configuration, which would be obtained
    by the command:

    make ARCH=ppc power3_defconfig

    I assume that this gives 32bit support for the power3 architecture.
    In arch/ppc64/configs/ there are configs: g5_defconfig,
    iSeries_defconfig and pSeries_defconfig. How appropriate any of these
    are I don't know (well the g5 one is definitely not appropriate). You
    could try looking further with google, adding ppc64 to my search gave

    which has a further link to .

    --
    Stephen Harker Stephen.Harker@spme.monash.edu.au
    School of Physics & Materials Engineering
    Monash University

  5. Re: Cannot find the processor family for my powerpc in kernel

    Thank you very much.
    make ARCH=ppc ibmchrp_defconfig
    went fine. But after that in "make xconfig" I still cannot find the CPU
    type. Ignoring this, I tried to "make", but got this shortly:
    CHK include/linux/version.h
    SPLIT include/linux/autoconf.h -> include/config/*
    CC arch/i386/kernel/asm-offsets.s
    In file included from include/asm/thread_info.h:16,
    from include/linux/thread_info.h:21,
    from include/linux/spinlock.h:12,
    from include/linux/capability.h:45,
    from include/linux/sched.h:7,
    from arch/i386/kernel/asm-offsets.c:7:
    include/asm/processor.h:68: error: `CONFIG_X86_L1_CACHE_SHIFT' undeclared here (not in a function)
    include/asm/processor.h:68: error: requested alignment is not a constant
    In file included from include/linux/list.h:7,
    from include/linux/wait.h:23,
    from include/asm/semaphore.h:41,
    from include/linux/sched.h:18,
    from arch/i386/kernel/asm-offsets.c:7:
    include/linux/prefetch.h: In function `prefetch_range':
    include/linux/prefetch.h:64: error: `CONFIG_X86_L1_CACHE_SHIFT' undeclared (first use in this function)
    include/linux/prefetch.h:64: error: (Each undeclared identifier is reported only once
    include/linux/prefetch.h:64: error: for each function it appears in.)
    make[1]: *** [arch/i386/kernel/asm-offsets.s] Error 1
    make: *** [arch/i386/kernel/asm-offsets.s] Error 2

    Is there anything else I should do to cross compile, such as installing
    some packages?

    Thanks again for your kind help.
    Shi



  6. Re: Cannot find the processor family for my powerpc in kernel

    Shi Jin writes:

    > Thank you very much.
    > make ARCH=ppc ibmchrp_defconfig
    > went fine. But after that in "make xconfig" I still cannot find the CPU
    > type.


    I think you need:

    make ARCH=ppc xconfig

    > Ignoring this, I tried to "make", but got this shortly:


    I think you need:

    make ARCH=ppc

    > Is there anything else I should do to cross compile, such as installing
    > some packages?


    The main thing is that make assumes you want to use the same
    architecture as the machine you are on unless you tell it otherwise.
    So, you either add the ARCH=ppc to all uses of make, or set the
    environment variable ARCH=ppc (i.e., something like `ARCH=ppc' then
    `export ARCH' in bash).

    --
    Stephen Harker Stephen.Harker@spme.monash.edu.au
    School of Physics & Materials Engineering
    Monash University

  7. Re: Cannot find the processor family for my powerpc in kernel

    Thanks a lot.
    This time I am able to see the power3 CPU now. That's a big progress for me.
    Thanks.
    But still, when I "make ARCH=ppc", I got errors immediately.
    I wonder if I should install something like cross-compiler and
    cross-libraries.
    There are several articles about installing glibc for cross compilation but
    I am not sure whether that suits my purpose here:
    I want the kernel not the glibc.
    Could you please give some advice?
    Thank you so much.
    Shi

    "Stephen Harker" wrote in message
    news:m3brenmn29.fsf@harker.spme.monash.edu.au...
    > Shi Jin writes:
    >
    > > Thank you very much.
    > > make ARCH=ppc ibmchrp_defconfig
    > > went fine. But after that in "make xconfig" I still cannot find the CPU
    > > type.

    >
    > I think you need:
    >
    > make ARCH=ppc xconfig
    >
    > > Ignoring this, I tried to "make", but got this shortly:

    >
    > I think you need:
    >
    > make ARCH=ppc
    >
    > > Is there anything else I should do to cross compile, such as installing
    > > some packages?

    >
    > The main thing is that make assumes you want to use the same
    > architecture as the machine you are on unless you tell it otherwise.
    > So, you either add the ARCH=ppc to all uses of make, or set the
    > environment variable ARCH=ppc (i.e., something like `ARCH=ppc' then
    > `export ARCH' in bash).
    >
    > --
    > Stephen Harker Stephen.Harker@spme.monash.edu.au
    > School of Physics & Materials Engineering
    > Monash University




  8. Re: Cannot find the processor family for my powerpc in kernel

    "Shi Jin" writes:

    > Thanks a lot.
    > This time I am able to see the power3 CPU now. That's a big progress for me.
    > Thanks.
    > But still, when I "make ARCH=ppc", I got errors immediately.
    > I wonder if I should install something like cross-compiler and
    > cross-libraries.


    I have never tried cross-compilation. I can't really advise you on
    this point. A quick Google search on "linux cross-compilation kernel ppc"
    gave some possible resources:





    One thing that seems to be common is the use of make commands with an
    extra argument beyond ARCH:

    make ARCH=ppc CROSS_COMPILE=powerpc-unknown-linux-gnu

    > There are several articles about installing glibc for cross compilation but
    > I am not sure whether that suits my purpose here:
    > I want the kernel not the glibc.
    > Could you please give some advice?


    I am afraid it is beyond my experience, I can only suggest looking at
    some of the above resources and doing some more searches on the
    net. Good luck.

    --
    Stephen Harker Stephen.Harker@spme.monash.edu.au
    School of Physics & Materials Engineering
    Monash University

+ Reply to Thread