scheduler context

2013-04-17 Thread ratheesh kannoth
I would like to understand on linux scheduler context. I have read a
lot in websites and i could find
contradictory statement. There are so many mailing list also ,but with
less info. I would really appreciate
if anybody could spend some time answering my question.

1. Which context scheduler run ? ( process context or interrupt context ).
2. scheduler is the guy  who picks up the next candidate to run.  if
it gets interrupted by hardirq, what will happen ?
3. if scheduler run in process context , how bottom half are scheduled ?
4. In smp, schedule() function may be called  simultaneously. How it
is handled ?
5. When a bottom half is interrupted  by hard irq, how softirq kernel
thread saves the state and restart it later ? ...what i mean is , an
   hardirq came and its isr executed. bottom half enabled and bottom
half gets scheduled . Before bottom half is completed , next irq
   came and it enables bottom half , and the new bottom half is
scheduled So here , what will happen to old bottom half , will it
again
   run later ?


Thanks,
Ratheesh

___
Kernelnewbies mailing list
Kernelnewbies@kernelnewbies.org
http://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies


Re: net_device: limit rate ot tx packets

2013-04-17 Thread christian+kn
> 
> How to figure this out for yourself:
> 
> Look at net/sched/sch_plug.c, which is a pretty simple qdisc
> (transmit packets until a plug request is recieved, then queue until
> unplugged). In particular, look at plug_enqueue() to see what happens
> when q->limit is exceeded, and plug_init() to see where q->limit is
> set.
> 
> Then look at the definition of qdisc_reshape_fail() in
> include/net/sch_generic.h to figure out what the qdisc returns if
> q->limit is exceeded.
> 
> Then go look at net/core/dev.c, in function __dev_xmit_skb(), and
> watch the variable 'rc'.
> 
> Now go find the caller of __dev_xmit_skb() and see what it does with
> that return value.
> 
> Hope that helps...
> 

Thank You very much, Michi and Vladis!
With Your help, I could figure it out.

I tried it out, and as Michi stated:
  If the tx_queue_len is small, send() will not sleep
  If the tx_queue_len is large, send() will sleep at some point

___
Kernelnewbies mailing list
Kernelnewbies@kernelnewbies.org
http://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies


Re: Build error in linux-3.8.7

2013-04-17 Thread Sarbojit Ganguly
On 17 April 2013 15:38, Giridhara RP (grp)  wrote:

>  Thanks guys J. Finally I have a successful build.
>

Sorry, checked late, do share the reason and solution. It might help others
who are facing similar problem.



> 
>
> Giri
>
> ** **
>
> *From:* kernelnewbies-boun...@kernelnewbies.org [mailto:
> kernelnewbies-boun...@kernelnewbies.org] *On Behalf Of *Giridhara RP (grp)
> *Sent:* Wednesday, April 17, 2013 1:42 PM
>
> *To:* Sarbojit Ganguly
> *Cc:* kernelnewbies@kernelnewbies.org
> *Subject:* RE: Build error in linux-3.8.7
>
>  ** **
>
> Hi,
>
> ** **
>
> I am getting error in firmware. Any pointer will be helpful. Segmetation
> fault is gone after changning to gcc-4.5
>
> ** **
>
> make-3.79.1-p7[1]: Nothing to be done for `all'.
>
>   CHK include/generated/uapi/linux/version.h
>
> make-3.79.1-p7[1]: Nothing to be done for `relocs'.
>
>   CHK include/generated/utsrelease.h
>
>   CALLscripts/checksyscalls.sh
>
> *make-3.79.1-p7[1]: *** No rule to make target `|', needed by
> `firmware/bnx2/bnx2-mips-09-6.2.1a.fw.gen.S'.  Stop.*
>
> *make-3.79.1-p7: *** [firmware] Error 2*
>
> make-3.79.1-p7: *** Waiting for unfinished jobs
>
>   CHK include/generated/compile.h
>
>   PASYMS  arch/x86/realmode/rm/pasyms.h
>
>   VDSOSYM arch/x86/vdso/vdso32-int80-syms.lds
>
>   LDS arch/x86/realmode/rm/realmode.lds
>
>   LD  arch/x86/realmode/rm/realmode.elf
>
>   RELOCS  arch/x86/realmode/rm/realmode.relocs
>
>   OBJCOPY arch/x86/realmode/rm/realmode.bin
>
>   VDSOSYM arch/x86/vdso/vdso32-sysenter-syms.lds
>
>   AS  arch/x86/realmode/rmpiggy.o
>
>   VDSOSYM arch/x86/vdso/vdso32-syms.lds
>
>   LD  arch/x86/realmode/built-in.o
>
>   LD  arch/x86/vdso/built-in.o
>
>   LD  arch/x86/built-in.o
>
> make-3.79.1-p7: *** wait: No child processes.  Stop.
>
> bash-3.00$
>
> ** **
>
> Thanks
>
> Giri
>
> ** **
>
> *From:* kernelnewbies-boun...@kernelnewbies.org [
> mailto:kernelnewbies-boun...@kernelnewbies.org]
> *On Behalf Of *Giridhara RP (grp)
> *Sent:* Wednesday, April 17, 2013 12:33 PM
> *To:* Sarbojit Ganguly
> *Cc:* kernelnewbies@kernelnewbies.org
> *Subject:* RE: Build error in linux-3.8.7
>
> ** **
>
> Hi Sarbojit,
>
> ** **
>
> Using gcc4.2.1 the compilation error disaappered, but now linker (ld) is
> crashing. Any workaround to overcome this?
>
> ** **
>
> CHK include/generated/uapi/linux/version.h
>
> CHK include/generated/utsrelease.h
>
> CALLscripts/checksyscalls.sh
>
> CHK include/generated/compile.h
>
> LD  arch/x86/kernel/built-in.o
>
> /bin/sh: line 1: 17454 Segmentation fault  ld -m elf_i386 -r -o
> arch/x86/kernel/built-in.o arch/x86/kernel/process_32.o
> arch/x86/kernel/signal.o arch/x86/kernel/entry_32.o arch/x86/kernel/traps.o
> arch/x86/kernel/irq.o arch/x86/kernel/irq_32.o
> arch/x86/kernel/dumpstack_32.o arch/x86/kernel/time.o
> arch/x86/kernel/ioport.o arch/x86/kernel/ldt.o arch/x86/kernel/dumpstack.o
> arch/x86/kernel/nmi.o arch/x86/kernel/setup.o arch/x86/kernel/x86_init.o
> arch/x86/kernel/i8259.o arch/x86/kernel/irqinit.o
> arch/x86/kernel/jump_label.o arch/x86/kernel/irq_work.o
> arch/x86/kernel/probe_roms.o arch/x86/kernel/i386_ksyms_32.o
> arch/x86/kernel/syscall_32.o arch/x86/kernel/bootflag.o
> arch/x86/kernel/e820.o arch/x86/kernel/pci-dma.o arch/x86/kernel/quirks.o
> arch/x86/kernel/topology.o arch/x86/kernel/kdebugfs.o
> arch/x86/kernel/alternative.o arch/x86/kernel/i8253.o
> arch/x86/kernel/pci-nommu.o arch/x86/kernel/hw_breakpoint.o
> arch/x86/kernel/tsc.o arch/x86/kernel/io_delay.o arch/x86/kernel/rtc.o
> arch/x86/kernel/pci-iommu_table.o arch/x86/kernel/resource.o
> arch/x86/kernel/process.o arch/x86/kernel/i387.o arch/x86/kernel/xsave.o
> arch/x86/kernel/ptrace.o arch/x86/kernel/tls.o arch/x86/kernel/step.o
> arch/x86/kernel/i8237.o arch/x86/kernel/stacktrace.o
> arch/x86/kernel/cpu/built-in.o arch/x86/kernel/acpi/built-in.o
> arch/x86/kernel/reboot.o arch/x86/kernel/msr.o arch/x86/kernel/cpuid.o
> arch/x86/kernel/early-quirks.o arch/x86/kernel/smp.o
> arch/x86/kernel/smpboot.o arch/x86/kernel/tsc_sync.o
> arch/x86/kernel/setup_percpu.o arch/x86/kernel/mpparse.o
> arch/x86/kernel/apic/built-in.o arch/x86/kernel/reboot_fixups_32.o
> arch/x86/kernel/trace_clock.o arch/x86/kernel/machine_kexec_32.o
> arch/x86/kernel/relocate_kernel_32.o arch/x86/kernel/crash.o
> arch/x86/kernel/crash_dump_32.o arch/x86/kernel/kprobes.o
> arch/x86/kernel/kprobes-opt.o arch/x86/kernel/module.o
> arch/x86/kernel/doublefault_32.o arch/x86/kernel/vm86_32.o
> arch/x86/kernel/early_printk.o arch/x86/kernel/hpet.o
> arch/x86/kernel/amd_nb.o arch/x86/kernel/pcspeaker.o
> arch/x86/kernel/microcode.o arch/x86/kernel/check.o
> arch/x86/kernel/perf_regs.o
>
> make-3.79.1-p7[2]: *** [arch/x86/kernel/built-in.o] Error 139
>
> make-3.79.1-p7[1]: *** [arch/x86/kernel] Error 2
>
> make-3.79.1-p7: *** [arc

Handling MSI interrupts

2013-04-17 Thread Matti Vaittinen
Hello!

I am working with an asic that is controlled by CPU. With our current board
this asic sends interrupts to processor via single interrupt line. CPU sees
level active interrupt, and reads the reason(s) from asic's register. When
handler(s) have executed, the read interrupts are acked to asic, and if no
more interrupt(s) have ocurred on asic, this interrupt line is brought in
inactive state. If new (different type of) interrupts have occurred on
asic, the acking wont clean all interrupts from asic's register and asic
keeps the interrupt line activated. Thus CPU is interrupted again && this
process is done again && all interrupts are handled.

Now there is plans to make this asic to use PCIe, and MSI interrupts. Also
we hope to utilize the same driver(s) for this asic. So first idea would be
to implement this as:

1. asic generates irq
2. MSI interrupt is sent (to PCIe controller) and CPU is interrupted
3. CPU acks interrupt to PCIe controller.
4. isr reads the interrupt reason(s) from asic and handles interrupt(s)
5. isr acks the interrupts.

So is there a problem if new interrupt is generated between steps 4 and 5.
Do we lose this new interrupt because the isr is still running? So when the
isr acks interrupts to asic, it does not ack this new one because it had
not happened when the reasons were read at step 4?

I have read the MSI-HOWTO.txt and genirq guides, and even tried to read
some sources. However I have not found out solid answer. Is there some
de-facto method to do this so it works reliably?

Following section may contain errors, it is what I have guessed by reading
the sources - please kick me if it sounds stupid.

By reading the sources I have figured that the "interrupt-controller" for
MSI interrupts on processor does used handle_simple_irq as flow handler. If
I am correct, this does not "queue" interrupts in same fashion the
handle_edge_irq would do.

Does this mean that my fear is correct?

Br

Matti Vaittinen
___
Kernelnewbies mailing list
Kernelnewbies@kernelnewbies.org
http://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies


RE: Build error in linux-3.8.7

2013-04-17 Thread Giridhara RP (grp)
Thanks guys :). Finally I have a successful build.
Giri

From: kernelnewbies-boun...@kernelnewbies.org 
[mailto:kernelnewbies-boun...@kernelnewbies.org] On Behalf Of Giridhara RP (grp)
Sent: Wednesday, April 17, 2013 1:42 PM
To: Sarbojit Ganguly
Cc: kernelnewbies@kernelnewbies.org
Subject: RE: Build error in linux-3.8.7

Hi,

I am getting error in firmware. Any pointer will be helpful. Segmetation fault 
is gone after changning to gcc-4.5

make-3.79.1-p7[1]: Nothing to be done for `all'.
  CHK include/generated/uapi/linux/version.h
make-3.79.1-p7[1]: Nothing to be done for `relocs'.
  CHK include/generated/utsrelease.h
  CALLscripts/checksyscalls.sh
make-3.79.1-p7[1]: *** No rule to make target `|', needed by 
`firmware/bnx2/bnx2-mips-09-6.2.1a.fw.gen.S'.  Stop.
make-3.79.1-p7: *** [firmware] Error 2
make-3.79.1-p7: *** Waiting for unfinished jobs
  CHK include/generated/compile.h
  PASYMS  arch/x86/realmode/rm/pasyms.h
  VDSOSYM arch/x86/vdso/vdso32-int80-syms.lds
  LDS arch/x86/realmode/rm/realmode.lds
  LD  arch/x86/realmode/rm/realmode.elf
  RELOCS  arch/x86/realmode/rm/realmode.relocs
  OBJCOPY arch/x86/realmode/rm/realmode.bin
  VDSOSYM arch/x86/vdso/vdso32-sysenter-syms.lds
  AS  arch/x86/realmode/rmpiggy.o
  VDSOSYM arch/x86/vdso/vdso32-syms.lds
  LD  arch/x86/realmode/built-in.o
  LD  arch/x86/vdso/built-in.o
  LD  arch/x86/built-in.o
make-3.79.1-p7: *** wait: No child processes.  Stop.
bash-3.00$

Thanks
Giri

From: 
kernelnewbies-boun...@kernelnewbies.org
 [mailto:kernelnewbies-boun...@kernelnewbies.org] On Behalf Of Giridhara RP 
(grp)
Sent: Wednesday, April 17, 2013 12:33 PM
To: Sarbojit Ganguly
Cc: kernelnewbies@kernelnewbies.org
Subject: RE: Build error in linux-3.8.7

Hi Sarbojit,

Using gcc4.2.1 the compilation error disaappered, but now linker (ld) is 
crashing. Any workaround to overcome this?

CHK include/generated/uapi/linux/version.h
CHK include/generated/utsrelease.h
CALLscripts/checksyscalls.sh
CHK include/generated/compile.h
LD  arch/x86/kernel/built-in.o
/bin/sh: line 1: 17454 Segmentation fault  ld -m elf_i386 -r -o 
arch/x86/kernel/built-in.o arch/x86/kernel/process_32.o 
arch/x86/kernel/signal.o arch/x86/kernel/entry_32.o arch/x86/kernel/traps.o 
arch/x86/kernel/irq.o arch/x86/kernel/irq_32.o arch/x86/kernel/dumpstack_32.o 
arch/x86/kernel/time.o arch/x86/kernel/ioport.o arch/x86/kernel/ldt.o 
arch/x86/kernel/dumpstack.o arch/x86/kernel/nmi.o arch/x86/kernel/setup.o 
arch/x86/kernel/x86_init.o arch/x86/kernel/i8259.o arch/x86/kernel/irqinit.o 
arch/x86/kernel/jump_label.o arch/x86/kernel/irq_work.o 
arch/x86/kernel/probe_roms.o arch/x86/kernel/i386_ksyms_32.o 
arch/x86/kernel/syscall_32.o arch/x86/kernel/bootflag.o arch/x86/kernel/e820.o 
arch/x86/kernel/pci-dma.o arch/x86/kernel/quirks.o arch/x86/kernel/topology.o 
arch/x86/kernel/kdebugfs.o arch/x86/kernel/alternative.o 
arch/x86/kernel/i8253.o arch/x86/kernel/pci-nommu.o 
arch/x86/kernel/hw_breakpoint.o arch/x86/kernel/tsc.o 
arch/x86/kernel/io_delay.o arch/x86/kernel/rtc.o 
arch/x86/kernel/pci-iommu_table.o arch/x86/kernel/resource.o 
arch/x86/kernel/process.o arch/x86/kernel/i387.o arch/x86/kernel/xsave.o 
arch/x86/kernel/ptrace.o arch/x86/kernel/tls.o arch/x86/kernel/step.o 
arch/x86/kernel/i8237.o arch/x86/kernel/stacktrace.o 
arch/x86/kernel/cpu/built-in.o arch/x86/kernel/acpi/built-in.o 
arch/x86/kernel/reboot.o arch/x86/kernel/msr.o arch/x86/kernel/cpuid.o 
arch/x86/kernel/early-quirks.o arch/x86/kernel/smp.o arch/x86/kernel/smpboot.o 
arch/x86/kernel/tsc_sync.o arch/x86/kernel/setup_percpu.o 
arch/x86/kernel/mpparse.o arch/x86/kernel/apic/built-in.o 
arch/x86/kernel/reboot_fixups_32.o arch/x86/kernel/trace_clock.o 
arch/x86/kernel/machine_kexec_32.o arch/x86/kernel/relocate_kernel_32.o 
arch/x86/kernel/crash.o arch/x86/kernel/crash_dump_32.o 
arch/x86/kernel/kprobes.o arch/x86/kernel/kprobes-opt.o 
arch/x86/kernel/module.o arch/x86/kernel/doublefault_32.o 
arch/x86/kernel/vm86_32.o arch/x86/kernel/early_printk.o arch/x86/kernel/hpet.o 
arch/x86/kernel/amd_nb.o arch/x86/kernel/pcspeaker.o 
arch/x86/kernel/microcode.o arch/x86/kernel/check.o arch/x86/kernel/perf_regs.o
make-3.79.1-p7[2]: *** [arch/x86/kernel/built-in.o] Error 139
make-3.79.1-p7[1]: *** [arch/x86/kernel] Error 2
make-3.79.1-p7: *** [arch/x86] Error 2

bash-3.00$ uname -a
Linux sam-build01.cisco.com 2.6.9-89.ELsmp #1 SMP Mon Jun 22 12:32:43 EDT 2009 
i686 i686 i386 GNU/Linux

bash-3.00$ ld --version
GNU ld version 2.15.92.0.2 20040927
Copyright 2002 Free Software Foundation, Inc.
This program is free software; you may redistribute it under the terms of
the GNU General Public License.  This program has absolutely no warranty.

From: 
kernelnewbies-boun...@kernelnewbies.org
 [mailto:kernelnewbies-boun...@kernelnewbies.org] On Behalf Of Giridhara RP 
(grp)

How to debug kernel on ARM with gdb

2013-04-17 Thread Woody Wu
Hi,

I am working on an embedded ARM board (s3c2416) and I can already
debug its boot loader (u-boot) with arm-linux-gdb, which talks to
a GDB server provided from J-Link.

Now I want to debug the kernel.  The problem is that how can I get
the correct symbol table for listing source lines in gdb.

I checked the symbols in my compiled vmlinux, it starts from 0xC0008000.
I think this is the final runtime address and should be a virtual
address after MMU enabled. When kernel getting loaded into RAM, the
virtual address probably not exists. On the other hand, the zImage
loaded by boot loader is not vmlinux actually, it should be head.S which
then carries vmlinux as piggy.

So, with these complexities, how can I correctly debug Linux kernel
starting from it's first instruction in head.S?

Who have experience on this? Thanks in advance.

-- 
woody
I can't go back to yesterday - because I was a different person then.

___
Kernelnewbies mailing list
Kernelnewbies@kernelnewbies.org
http://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies


RE: Build error in linux-3.8.7

2013-04-17 Thread Giridhara RP (grp)
Hi,

I am getting error in firmware. Any pointer will be helpful. Segmetation fault 
is gone after changning to gcc-4.5

make-3.79.1-p7[1]: Nothing to be done for `all'.
  CHK include/generated/uapi/linux/version.h
make-3.79.1-p7[1]: Nothing to be done for `relocs'.
  CHK include/generated/utsrelease.h
  CALLscripts/checksyscalls.sh
make-3.79.1-p7[1]: *** No rule to make target `|', needed by 
`firmware/bnx2/bnx2-mips-09-6.2.1a.fw.gen.S'.  Stop.
make-3.79.1-p7: *** [firmware] Error 2
make-3.79.1-p7: *** Waiting for unfinished jobs
  CHK include/generated/compile.h
  PASYMS  arch/x86/realmode/rm/pasyms.h
  VDSOSYM arch/x86/vdso/vdso32-int80-syms.lds
  LDS arch/x86/realmode/rm/realmode.lds
  LD  arch/x86/realmode/rm/realmode.elf
  RELOCS  arch/x86/realmode/rm/realmode.relocs
  OBJCOPY arch/x86/realmode/rm/realmode.bin
  VDSOSYM arch/x86/vdso/vdso32-sysenter-syms.lds
  AS  arch/x86/realmode/rmpiggy.o
  VDSOSYM arch/x86/vdso/vdso32-syms.lds
  LD  arch/x86/realmode/built-in.o
  LD  arch/x86/vdso/built-in.o
  LD  arch/x86/built-in.o
make-3.79.1-p7: *** wait: No child processes.  Stop.
bash-3.00$

Thanks
Giri

From: kernelnewbies-boun...@kernelnewbies.org 
[mailto:kernelnewbies-boun...@kernelnewbies.org] On Behalf Of Giridhara RP (grp)
Sent: Wednesday, April 17, 2013 12:33 PM
To: Sarbojit Ganguly
Cc: kernelnewbies@kernelnewbies.org
Subject: RE: Build error in linux-3.8.7

Hi Sarbojit,

Using gcc4.2.1 the compilation error disaappered, but now linker (ld) is 
crashing. Any workaround to overcome this?

CHK include/generated/uapi/linux/version.h
CHK include/generated/utsrelease.h
CALLscripts/checksyscalls.sh
CHK include/generated/compile.h
LD  arch/x86/kernel/built-in.o
/bin/sh: line 1: 17454 Segmentation fault  ld -m elf_i386 -r -o 
arch/x86/kernel/built-in.o arch/x86/kernel/process_32.o 
arch/x86/kernel/signal.o arch/x86/kernel/entry_32.o arch/x86/kernel/traps.o 
arch/x86/kernel/irq.o arch/x86/kernel/irq_32.o arch/x86/kernel/dumpstack_32.o 
arch/x86/kernel/time.o arch/x86/kernel/ioport.o arch/x86/kernel/ldt.o 
arch/x86/kernel/dumpstack.o arch/x86/kernel/nmi.o arch/x86/kernel/setup.o 
arch/x86/kernel/x86_init.o arch/x86/kernel/i8259.o arch/x86/kernel/irqinit.o 
arch/x86/kernel/jump_label.o arch/x86/kernel/irq_work.o 
arch/x86/kernel/probe_roms.o arch/x86/kernel/i386_ksyms_32.o 
arch/x86/kernel/syscall_32.o arch/x86/kernel/bootflag.o arch/x86/kernel/e820.o 
arch/x86/kernel/pci-dma.o arch/x86/kernel/quirks.o arch/x86/kernel/topology.o 
arch/x86/kernel/kdebugfs.o arch/x86/kernel/alternative.o 
arch/x86/kernel/i8253.o arch/x86/kernel/pci-nommu.o 
arch/x86/kernel/hw_breakpoint.o arch/x86/kernel/tsc.o 
arch/x86/kernel/io_delay.o arch/x86/kernel/rtc.o 
arch/x86/kernel/pci-iommu_table.o arch/x86/kernel/resource.o 
arch/x86/kernel/process.o arch/x86/kernel/i387.o arch/x86/kernel/xsave.o 
arch/x86/kernel/ptrace.o arch/x86/kernel/tls.o arch/x86/kernel/step.o 
arch/x86/kernel/i8237.o arch/x86/kernel/stacktrace.o 
arch/x86/kernel/cpu/built-in.o arch/x86/kernel/acpi/built-in.o 
arch/x86/kernel/reboot.o arch/x86/kernel/msr.o arch/x86/kernel/cpuid.o 
arch/x86/kernel/early-quirks.o arch/x86/kernel/smp.o arch/x86/kernel/smpboot.o 
arch/x86/kernel/tsc_sync.o arch/x86/kernel/setup_percpu.o 
arch/x86/kernel/mpparse.o arch/x86/kernel/apic/built-in.o 
arch/x86/kernel/reboot_fixups_32.o arch/x86/kernel/trace_clock.o 
arch/x86/kernel/machine_kexec_32.o arch/x86/kernel/relocate_kernel_32.o 
arch/x86/kernel/crash.o arch/x86/kernel/crash_dump_32.o 
arch/x86/kernel/kprobes.o arch/x86/kernel/kprobes-opt.o 
arch/x86/kernel/module.o arch/x86/kernel/doublefault_32.o 
arch/x86/kernel/vm86_32.o arch/x86/kernel/early_printk.o arch/x86/kernel/hpet.o 
arch/x86/kernel/amd_nb.o arch/x86/kernel/pcspeaker.o 
arch/x86/kernel/microcode.o arch/x86/kernel/check.o arch/x86/kernel/perf_regs.o
make-3.79.1-p7[2]: *** [arch/x86/kernel/built-in.o] Error 139
make-3.79.1-p7[1]: *** [arch/x86/kernel] Error 2
make-3.79.1-p7: *** [arch/x86] Error 2

bash-3.00$ uname -a
Linux sam-build01.cisco.com 2.6.9-89.ELsmp #1 SMP Mon Jun 22 12:32:43 EDT 2009 
i686 i686 i386 GNU/Linux

bash-3.00$ ld --version
GNU ld version 2.15.92.0.2 20040927
Copyright 2002 Free Software Foundation, Inc.
This program is free software; you may redistribute it under the terms of
the GNU General Public License.  This program has absolutely no warranty.

From: 
kernelnewbies-boun...@kernelnewbies.org
 [mailto:kernelnewbies-boun...@kernelnewbies.org] On Behalf Of Giridhara RP 
(grp)
Sent: Wednesday, April 17, 2013 11:35 AM
To: Sarbojit Ganguly
Cc: kernelnewbies@kernelnewbies.org
Subject: RE: Build error in linux-3.8.7

Hi Sarbojit,

My gcc is 3.4.6-11. Sure, I will try 3.8.8

bash-3.00$ gcc --version
gcc (GCC) 3.4.6 20060404 (Red Hat 3.4.6-11)
Copyright (C) 2006 Free Software Foundation, Inc.
This is free software; see the source for copying conditi

RE: Build error in linux-3.8.7

2013-04-17 Thread Giridhara RP (grp)
Hi Sarbojit,

Using gcc4.2.1 the compilation error disaappered, but now linker (ld) is 
crashing. Any workaround to overcome this?

CHK include/generated/uapi/linux/version.h
CHK include/generated/utsrelease.h
CALLscripts/checksyscalls.sh
CHK include/generated/compile.h
LD  arch/x86/kernel/built-in.o
/bin/sh: line 1: 17454 Segmentation fault  ld -m elf_i386 -r -o 
arch/x86/kernel/built-in.o arch/x86/kernel/process_32.o 
arch/x86/kernel/signal.o arch/x86/kernel/entry_32.o arch/x86/kernel/traps.o 
arch/x86/kernel/irq.o arch/x86/kernel/irq_32.o arch/x86/kernel/dumpstack_32.o 
arch/x86/kernel/time.o arch/x86/kernel/ioport.o arch/x86/kernel/ldt.o 
arch/x86/kernel/dumpstack.o arch/x86/kernel/nmi.o arch/x86/kernel/setup.o 
arch/x86/kernel/x86_init.o arch/x86/kernel/i8259.o arch/x86/kernel/irqinit.o 
arch/x86/kernel/jump_label.o arch/x86/kernel/irq_work.o 
arch/x86/kernel/probe_roms.o arch/x86/kernel/i386_ksyms_32.o 
arch/x86/kernel/syscall_32.o arch/x86/kernel/bootflag.o arch/x86/kernel/e820.o 
arch/x86/kernel/pci-dma.o arch/x86/kernel/quirks.o arch/x86/kernel/topology.o 
arch/x86/kernel/kdebugfs.o arch/x86/kernel/alternative.o 
arch/x86/kernel/i8253.o arch/x86/kernel/pci-nommu.o 
arch/x86/kernel/hw_breakpoint.o arch/x86/kernel/tsc.o 
arch/x86/kernel/io_delay.o arch/x86/kernel/rtc.o 
arch/x86/kernel/pci-iommu_table.o arch/x86/kernel/resource.o 
arch/x86/kernel/process.o arch/x86/kernel/i387.o arch/x86/kernel/xsave.o 
arch/x86/kernel/ptrace.o arch/x86/kernel/tls.o arch/x86/kernel/step.o 
arch/x86/kernel/i8237.o arch/x86/kernel/stacktrace.o 
arch/x86/kernel/cpu/built-in.o arch/x86/kernel/acpi/built-in.o 
arch/x86/kernel/reboot.o arch/x86/kernel/msr.o arch/x86/kernel/cpuid.o 
arch/x86/kernel/early-quirks.o arch/x86/kernel/smp.o arch/x86/kernel/smpboot.o 
arch/x86/kernel/tsc_sync.o arch/x86/kernel/setup_percpu.o 
arch/x86/kernel/mpparse.o arch/x86/kernel/apic/built-in.o 
arch/x86/kernel/reboot_fixups_32.o arch/x86/kernel/trace_clock.o 
arch/x86/kernel/machine_kexec_32.o arch/x86/kernel/relocate_kernel_32.o 
arch/x86/kernel/crash.o arch/x86/kernel/crash_dump_32.o 
arch/x86/kernel/kprobes.o arch/x86/kernel/kprobes-opt.o 
arch/x86/kernel/module.o arch/x86/kernel/doublefault_32.o 
arch/x86/kernel/vm86_32.o arch/x86/kernel/early_printk.o arch/x86/kernel/hpet.o 
arch/x86/kernel/amd_nb.o arch/x86/kernel/pcspeaker.o 
arch/x86/kernel/microcode.o arch/x86/kernel/check.o arch/x86/kernel/perf_regs.o
make-3.79.1-p7[2]: *** [arch/x86/kernel/built-in.o] Error 139
make-3.79.1-p7[1]: *** [arch/x86/kernel] Error 2
make-3.79.1-p7: *** [arch/x86] Error 2

bash-3.00$ uname -a
Linux sam-build01.cisco.com 2.6.9-89.ELsmp #1 SMP Mon Jun 22 12:32:43 EDT 2009 
i686 i686 i386 GNU/Linux

bash-3.00$ ld --version
GNU ld version 2.15.92.0.2 20040927
Copyright 2002 Free Software Foundation, Inc.
This program is free software; you may redistribute it under the terms of
the GNU General Public License.  This program has absolutely no warranty.

From: kernelnewbies-boun...@kernelnewbies.org 
[mailto:kernelnewbies-boun...@kernelnewbies.org] On Behalf Of Giridhara RP (grp)
Sent: Wednesday, April 17, 2013 11:35 AM
To: Sarbojit Ganguly
Cc: kernelnewbies@kernelnewbies.org
Subject: RE: Build error in linux-3.8.7

Hi Sarbojit,

My gcc is 3.4.6-11. Sure, I will try 3.8.8

bash-3.00$ gcc --version
gcc (GCC) 3.4.6 20060404 (Red Hat 3.4.6-11)
Copyright (C) 2006 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

From: Sarbojit Ganguly [mailto:unixman.linux...@gmail.com]
Sent: Wednesday, April 17, 2013 11:34 AM
To: Giridhara RP (grp)
Cc: kernelnewbies@kernelnewbies.org
Subject: Re: Build error in linux-3.8.7

Hello GRP,

Can you post your toolchain (gcc) version? As you're doing this, may I request 
you to try with 3.8.8?

Regards,
Sarbojit

On 17 April 2013 10:20, Giridhara RP (grp) 
mailto:g...@cisco.com>> wrote:
Hi,

I am new to linux kernel buidling. I have download 3.8.7 latest (stable) kernel 
from https://www.kernel.org/. I want build kernel for X86_64.


1.   make x86_64_defconfig (this created .config file)

2.   make
Make failed with below error, please help me in resolving this.

  CC  kernel/power/user.o
  CC  kernel/power/block_io.o
  CC  kernel/power/poweroff.o
  LD  kernel/power/built-in.o
  CC  kernel/sched/core.o
  CC  kernel/sched/clock.o
  CC  kernel/sched/cputime.o
  CC  kernel/sched/idle_task.o
  CC  kernel/sched/fair.o
kernel/sched/fair.c: In function `update_curr':
kernel/sched/fair.c:428: sorry, unimplemented: inlining failed in call to 
'account_cfs_rq_runtime': function body not available
kernel/sched/fair.c:714: sorry, unimplemented: called from here
make-3.79.1-p7[2]: *** [kernel/sched/fair.o] Error 1
make-3.79.1-p7[1]: *** [kernel/sched] Error 2
make-3.79.1-p7: *** [kernel] Error 2
bash-3.00$ pwd

than

Re: Build error in linux-3.8.7

2013-04-17 Thread Sarbojit Ganguly
On 17 April 2013 11:35, Giridhara RP (grp)  wrote:

>  Hi Sarbojit,
>
> ** **
>
> My gcc is 3.4.6-11. Sure, I will try 3.8.8
>
> ** **
>
> bash-3.00$ gcc --version
>
> gcc (GCC) 3.4.6 20060404 (Red Hat 3.4.6-11)
>
> Copyright (C) 2006 Free Software Foundation, Inc.
>
> This is free software; see the source for copying conditions.  There is NO
> 
>
> warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
>
Can you try with latest version of GCC 4.5 or later? It seems your gcc is
quite old.

> 
>
> ** **
>
> *From:* Sarbojit Ganguly [mailto:unixman.linux...@gmail.com]
> *Sent:* Wednesday, April 17, 2013 11:34 AM
> *To:* Giridhara RP (grp)
> *Cc:* kernelnewbies@kernelnewbies.org
> *Subject:* Re: Build error in linux-3.8.7
>
> ** **
>
> Hello GRP,
>
> ** **
>
> Can you post your toolchain (gcc) version? As you're doing this, may I
> request you to try with 3.8.8?
>
> ** **
>
> Regards,
>
> Sarbojit
>
> ** **
>
> On 17 April 2013 10:20, Giridhara RP (grp)  wrote:
>
> Hi,
>
>  
>
> I am new to linux kernel buidling. I have download 3.8.7 latest (stable)
> kernel from https://www.kernel.org/. I want build kernel for X86_64.
>
>  
>
> 1.   make x86_64_defconfig (this created .config file)
>
> 2.   make
>
> Make failed with below error, please help me in resolving this.
>
>  
>
>   CC  kernel/power/user.o
>
>   CC  kernel/power/block_io.o
>
>   CC  kernel/power/poweroff.o
>
>   LD  kernel/power/built-in.o
>
>   CC  kernel/sched/core.o
>
>   CC  kernel/sched/clock.o
>
>   CC  kernel/sched/cputime.o
>
>   CC  kernel/sched/idle_task.o
>
>   CC  kernel/sched/fair.o
>
> kernel/sched/fair.c: In function `update_curr':
>
> kernel/sched/fair.c:428: sorry, unimplemented: inlining failed in call to
> 'account_cfs_rq_runtime': function body not available
>
> kernel/sched/fair.c:714: sorry, unimplemented: called from here
>
> make-3.79.1-p7[2]: *** [kernel/sched/fair.o] Error 1
>
> make-3.79.1-p7[1]: *** [kernel/sched] Error 2
>
> make-3.79.1-p7: *** [kernel] Error 2
>
> bash-3.00$ pwd
>
>  
>
> thanks
>
> Giri
>
>
> ___
> Kernelnewbies mailing list
> Kernelnewbies@kernelnewbies.org
> http://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies
>
>
>
> 
>
> ** **
>
> --
> Regards,
> Sarbojit 
>



-- 
Regards,
Sarbojit
___
Kernelnewbies mailing list
Kernelnewbies@kernelnewbies.org
http://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies