24 Jun, 2012
1 commit
-
On x86-64, the standard ABI requires alignment to 16 bytes. However,
this is not actually necessary in the kernel (we don't do SSE except
in very controlled ways); and furthermore, the standard kernel entry
on x86-64 actually leaves the stack on an odd 8-byte boundary, which
means that gcc will generate extra instructions to keep the stack
*mis*aligned!gcc 4.8 adds an -mpreferred-stack-boundary=3 option to override this
and lets us save some stack space and a handful of instructions.Note that this causes us to pass -mno-sse twice; this is redundant,
but necessary since the cc-option test will fail unless -mno-sse is
passed on the same command line.[ hpa: rewrote the patch description ]
Signed-off-by: H.J. Lu
Link: http://lkml.kernel.org/r/CAMe9rOqPfy3JcZRLaUeCjBe9BVY-P6e0uaSbMi5hvS-6WwQueg@mail.gmail.com
Signed-off-by: H. Peter Anvin
24 May, 2012
2 commits
-
Pull md updates from NeilBrown:
"It's been a busy cycle for md - lots of fun stuff here.. if you like
this kind of thing :-)Main features:
- RAID10 arrays can be reshaped - adding and removing devices and
changing chunks (not 'far' array though)
- allow RAID5 arrays to be reshaped with a backup file (not tested
yet, but the priciple works fine for RAID10).
- arrays can be reshaped while a bitmap is present - you no longer
need to remove it first
- SSSE3 support for RAID6 syndrome calculationsand of course a number of minor fixes etc."
* tag 'md-3.5' of git://neil.brown.name/md: (56 commits)
md/bitmap: record the space available for the bitmap in the superblock.
md/raid10: Remove extras after reshape to smaller number of devices.
md/raid5: improve removal of extra devices after reshape.
md: check the return of mddev_find()
MD RAID1: Further conditionalize 'fullsync'
DM RAID: Use md_error() in place of simply setting Faulty bit
DM RAID: Record and handle missing devices
DM RAID: Set recovery flags on resume
md/raid5: Allow reshape while a bitmap is present.
md/raid10: resize bitmap when required during reshape.
md: allow array to be resized while bitmap is present.
md/bitmap: make sure reshape request are reflected in superblock.
md/bitmap: add bitmap_resize function to allow bitmap resizing.
md/bitmap: use DIV_ROUND_UP instead of open-code
md/bitmap: create a 'struct bitmap_counts' substructure of 'struct bitmap'
md/bitmap: make bitmap bitops atomic.
md/bitmap: make _page_attr bitops atomic.
md/bitmap: merge bitmap_file_unmap and bitmap_file_put.
md/bitmap: remove async freeing of bitmap file.
md/bitmap: convert some spin_lock_irqsave to spin_lock_irq
... -
Pull x86/urgent branch from Ingo Molnar:
"These are the fixes left over from the very end of the v3.4
stabilization cycle, plus one more fix."Ugh. Those KERN_CONT additions are just pointless. I think they came
as a reaction to some of the early (broken) printk() work - but that was
fixed before it was merged.* 'x86-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip:
x86, relocs: Build clean fix
x86, printk: Add missing KERN_CONT to NMI selftest
x86: Fix boot on Twinhead H12Y
22 May, 2012
3 commits
-
Optimize RAID5 xor checksumming by taking advantage of
256-bit YMM registers introduced in AVX.Signed-off-by: Jim Kukunas
Signed-off-by: NeilBrown -
Pull smp hotplug cleanups from Thomas Gleixner:
"This series is merily a cleanup of code copied around in arch/* and
not changing any of the real cpu hotplug horrors yet. I wish I'd had
something more substantial for 3.5, but I underestimated the lurking
horror..."Fix up trivial conflicts in arch/{arm,sparc,x86}/Kconfig and
arch/sparc/include/asm/thread_info_32.h* 'smp-hotplug-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip: (79 commits)
um: Remove leftover declaration of alloc_task_struct_node()
task_allocator: Use config switches instead of magic defines
sparc: Use common threadinfo allocator
score: Use common threadinfo allocator
sh-use-common-threadinfo-allocator
mn10300: Use common threadinfo allocator
powerpc: Use common threadinfo allocator
mips: Use common threadinfo allocator
hexagon: Use common threadinfo allocator
m32r: Use common threadinfo allocator
frv: Use common threadinfo allocator
cris: Use common threadinfo allocator
x86: Use common threadinfo allocator
c6x: Use common threadinfo allocator
fork: Provide kmemcache based thread_info allocator
tile: Use common threadinfo allocator
fork: Provide weak arch_release_[task_struct|thread_info] functions
fork: Move thread info gfp flags to header
fork: Remove the weak insanity
sh: Remove cpu_idle_wait()
... -
relocs was not cleaned up when "make clean" is issued. This
patch fixes the issue.Signed-off-by: Jarkko Sakkinen
Link: http://lkml.kernel.org/r/1337622684-6834-1-git-send-email-jarkko.sakkinen@intel.com
Signed-off-by: H. Peter Anvin
Cc: v3.4
19 May, 2012
1 commit
-
A new option is added to the relocs tool called '--realmode'.
This option causes the generation of 16-bit segment relocations
and 32-bit linear relocations for the real-mode code. When
the real-mode code is moved to the low-memory during kernel
initialization, these relocation entries can be used to
relocate the code properly.In the assembly code 16-bit segment relocations must be relative
to the 'real_mode_seg' absolute symbol. Linear relocations must be
relative to a symbol prefixed with 'pa_'.16-bit segment relocation is used to load cs:ip in 16-bit code.
Linear relocations are used in the 32-bit code for relocatable
data references. They are declared in the linker script of the
real-mode code.The relocs tool is moved to arch/x86/tools/relocs.c, and added new
target archscripts that can be used to build scripts needed building
an architecture. be compiled before building the arch/x86 tree.[ hpa: accelerating this because it detects invalid absolute
relocations, a serious bug in binutils 2.22.52.0.x which currently
produces bad kernels. ]Signed-off-by: H. Peter Anvin
Link: http://lkml.kernel.org/r/1336501366-28617-2-git-send-email-jarkko.sakkinen@intel.com
Signed-off-by: Jarkko Sakkinen
Signed-off-by: H. Peter Anvin
Cc:
05 May, 2012
1 commit
-
Same code. Use the generic version. The special Makefile treatment is
pointless anyway as init_task.o contains only data which is handled by
the linker script. So no point on being treated like head text.Signed-off-by: Thomas Gleixner
Link: http://lkml.kernel.org/r/20120503085035.739963562@linutronix.de
Cc: x86@kernel.org
31 Mar, 2012
1 commit
-
On gccs that support AVX it's a good idea to disable that too, similar to
how SSE2, SSE1 etc. are already disabled. This prevents the compiler
from generating AVX ever implicitely.No failure observed, just from review.
[ hpa: Marking this for urgent and stable, simply because the patch
will either have absolutely no effect *or* it will avoid potentially
very hard to debug failures. ]Signed-off-by: Andi Kleen
Link: http://lkml.kernel.org/r/1332960678-11879-1-git-send-email-andi@firstfloor.org
Signed-off-by: H. Peter Anvin
Cc:
28 Feb, 2012
2 commits
-
Fix:
arch/x86/Makefile:96: *** recipe commences before first target. Stop.
Cc: H. Peter Anvin
Cc: H. J. Lu
Link: http://lkml.kernel.org/r/1329696488-16970-1-git-send-email-hpa@zytor.com
Signed-off-by: Ingo Molnar -
If X32 is enabled in .config, but the binutils can't build it, issue a
warning and disable the feature rather than erroring out.In order to support this, have CONFIG_X86_X32 be the option set in
Kconfig, and CONFIG_X86_X32_ABI be the option set by the Makefile when
it is enabled and binutils has been found to be functional.Requested-by: Ingo Molnar
Signed-off-by: H. Peter Anvin
Cc: H. J. Lu
Link: http://lkml.kernel.org/r/1329696488-16970-1-git-send-email-hpa@zytor.com
18 Nov, 2011
1 commit
-
Generate system call tables and unistd_*.h automatically from the
tables in arch/x86/syscalls. All other information, like NR_syscalls,
is auto-generated, some of which is in asm-offsets_*.c.This allows us to keep all the system call information in one place,
and allows for kernel space and user space to see different
information; this is currently used for the ia32 system call numbers
when building the 64-bit kernel, but will be used by the x32 ABI in
the near future.This also removes some gratuitious differences between i386, x86-64
and ia32; in particular, now all system call tables are generated with
the same mechanism.Cc: H. J. Lu
Cc: Sam Ravnborg
Cc: Michal Marek
Signed-off-by: H. Peter Anvin
22 Oct, 2010
1 commit
-
* 'x86-asm-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip:
x86-64, asm: If the assembler supports fxsave64, use it
i386: Make kernel_execve() suitable for stack unwinding
14 Oct, 2010
1 commit
-
Kbuild allows for us to probe for the existence of specific constructs
in the assembler, use them to find out if we can use fxsave64 and
permit the compiler to generate better code.Signed-off-by: H. Peter Anvin
14 Sep, 2010
1 commit
-
The arch/x86/Makefile uses scripts/gcc-x86_$(BITS)-has-stack-protector.sh
to check if cc1 supports -fstack-protector. When -fPIE is passed to cc1,
these scripts fail causing stack protection to be disabled even when it
is available.This fix is similar to commit c47efe5548abbf53c2f66e06dcb46183b11d6b22
Reported-by: Kai Dietrich
Signed-off-by: Magnus Granberg
LKML-Reference:
Signed-off-by: Anthony G. Basile
Cc: Andrew Morton
Signed-off-by: H. Peter Anvin
14 May, 2010
1 commit
-
The newer assemblers support the .cfi_sections directive so we can put
the CFI from .S files into the .debug_frame section that is preserved
in unstripped vmlinux and in separate debuginfo, rather than the
.eh_frame section that is now discarded by vmlinux.lds.S.Signed-off-by: Roland McGrath
LKML-Reference:
Signed-off-by: H. Peter Anvin
17 Feb, 2010
1 commit
-
For some reason the 64-bit tree was doing this differently and
I can't see why it would need to.This correct behaviour when you have two GPUs plugged in and
32-bit put the console in one place and 64-bit in another.Signed-off-by: Dave Airlie
LKML-Reference:
Signed-off-by: H. Peter Anvin
17 Nov, 2009
1 commit
-
Resolved merge conflict in tools/perf/Makefile
Merge reason: we want to queue up a dependent patch.
Signed-off-by: Ingo Molnar
23 Oct, 2009
1 commit
-
STACKPROTECTOR_ALL has a really high overhead (runtime and stack
footprint) and is not really worth it protection wise (the
normal STACKPROTECTOR is in effect for all functions with
buffers already), so lets just remove the option entirely.Reported-by: Dave Jones
Reported-by: Chuck Ebbert
Signed-off-by: Arjan van de Ven
Cc: Eric Sandeen
LKML-Reference:
Signed-off-by: Ingo Molnar
17 Oct, 2009
1 commit
-
Conflicts:
kernel/trace/trace_event_profile.cMerge reason: update to -rc5 and resolve conflict.
Signed-off-by: Ingo Molnar
24 Sep, 2009
1 commit
-
Conflicts:
kernel/trace/Makefile
kernel/trace/trace.h
kernel/trace/trace_event_types.h
kernel/trace/trace_export.cMerge reason:
Sync with latest significant tracing core changes.
20 Sep, 2009
1 commit
-
Replace the use of CROSS_COMPILE to select a customized
installkernel script with the possibility to set INSTALLKERNEL
to select a custom installkernel script when running make:make INSTALLKERNEL=arm-installkernel install
With this patch we are now more consistent across
different architectures - they did not all support use
of CROSS_COMPILE.The use of CROSS_COMPILE was a hack as this really belongs
to gcc/binutils and the installkernel script does not change
just because we change toolchain.The use of CROSS_COMPILE caused troubles with an upcoming patch
that saves CROSS_COMPILE when a kernel is built - it would no
longer be installable.
[Thanks to Peter Z. for this hint]This patch undos what Ian did in commit:
0f8e2d62fa04441cd12c08ce521e84e5bd3f8a46
("use ${CROSS_COMPILE}installkernel in arch/*/boot/install.sh")The patch has been lightly tested on x86 only - but all changes
looks obvious.Acked-by: Peter Zijlstra
Acked-by: Mike Frysinger [blackfin]
Acked-by: Russell King [arm]
Acked-by: Paul Mundt [sh]
Acked-by: "H. Peter Anvin" [x86]
Cc: Ian Campbell
Cc: Tony Luck [ia64]
Cc: Fenghua Yu [ia64]
Cc: Hirokazu Takata [m32r]
Cc: Geert Uytterhoeven [m68k]
Cc: Kyle McMartin [parisc]
Cc: Benjamin Herrenschmidt [powerpc]
Cc: Martin Schwidefsky [s390]
Cc: Thomas Gleixner [x86]
Cc: Ingo Molnar [x86]
Signed-off-by: Sam Ravnborg
14 Sep, 2009
2 commits
-
…/git/tip/linux-2.6-tip
* 'x86-kbuild-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip:
x86: Simplify the Makefile in a minor way through use of cc-ifversion -
* 'x86-cpu-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip: (22 commits)
x86: Fix code patching for paravirt-alternatives on 486
x86, msr: change msr-reg.o to obj-y, and export its symbols
x86: Use hard_smp_processor_id() to get apic id for AMD K8 cpus
x86, sched: Workaround broken sched domain creation for AMD Magny-Cours
x86, mcheck: Use correct cpumask for shared bank4
x86, cacheinfo: Fixup L3 cache information for AMD multi-node processors
x86: Fix CPU llc_shared_map information for AMD Magny-Cours
x86, msr: Fix msr-reg.S compilation with gas 2.16.1, on 32-bit too
x86: Move kernel_fpu_using to irq_fpu_usable in asm/i387.h
x86, msr: fix msr-reg.S compilation with gas 2.16.1
x86, msr: Export the register-setting MSR functions via /dev/*/msr
x86, msr: Create _on_cpu helpers for {rw,wr}msr_safe_regs()
x86, msr: Have the _safe MSR functions return -EIO, not -EFAULT
x86, msr: CFI annotations, cleanups for msr-reg.S
x86, asm: Make _ASM_EXTABLE() usable from assembly code
x86, asm: Add 32-bit versions of the combined CFI macros
x86, AMD: Disable wrongly set X86_FEATURE_LAHF_LM CPUID bit
x86, msr: Rewrite AMD rd/wrmsr variants
x86, msr: Add rd/wrmsr interfaces with preset registers
x86: add specific support for Intel Atom architecture
...
31 Aug, 2009
1 commit
-
Stack protector support was not detected when building with
ARCH=i386 on x86_64 systems:arch/x86/Makefile:80: stack protector enabled but no compiler support
The "-m32" argument needs to be passed to the detection script.
Signed-off-by: Michal Schmidt
Cc: Tejun Heo
Cc: Jeremy Fitzhardinge
Cc: Arjan van de Ven
LKML-Reference:
Signed-off-by: Ingo Molnar
--
27 Aug, 2009
1 commit
-
Add a user-space selftest of x86 instruction decoder at kernel build
time.
When CONFIG_X86_DECODER_SELFTEST=y, Kbuild builds a test harness of x86
instruction decoder and performs it after building vmlinux.
The test compares the results of objdump and x86 instruction decoder
code and check there are no differences.Signed-off-by: Masami Hiramatsu
Signed-off-by: Jim Keniston
Cc: Ananth N Mavinakayanahalli
Cc: Avi Kivity
Cc: Andi Kleen
Cc: Christoph Hellwig
Cc: Frank Ch. Eigler
Cc: H. Peter Anvin
Cc: Ingo Molnar
Cc: Jason Baron
Cc: K.Prasad
Cc: Lai Jiangshan
Cc: Li Zefan
Cc: Przemysław Pawełczyk
Cc: Roland McGrath
Cc: Sam Ravnborg
Cc: Srikar Dronamraju
Cc: Steven Rostedt
Cc: Tom Zanussi
Cc: Vegard Nossum
LKML-Reference:
Signed-off-by: Frederic Weisbecker
23 Aug, 2009
1 commit
-
Add another option when selecting CPU family so the kernel can be
optimized for Intel Atom CPUs. If GCC supports tuning options for
Intel Atom they will be used.Signed-off-by: Tobias Doerffel
Signed-off-by: H. Peter Anvin
LKML-Reference:
Signed-off-by: Ingo Molnar
04 Aug, 2009
1 commit
-
Signed-off-by: Frans Pop
Acked-by: Sam Ravnborg
Reviewed-by: WANG Cong
LKML-Reference:
Signed-off-by: Ingo Molnar
13 Jun, 2009
1 commit
-
General description: kmemcheck is a patch to the linux kernel that
detects use of uninitialized memory. It does this by trapping every
read and write to memory that was allocated dynamically (e.g. using
kmalloc()). If a memory address is read that has not previously been
written to, a message is printed to the kernel log.Thanks to Andi Kleen for the set_memory_4k() solution.
Andrew Morton suggested documenting the shadow member of struct page.
Signed-off-by: Vegard Nossum
Signed-off-by: Pekka Enberg[export kmemcheck_mark_initialized]
[build fix for setup_max_cpus]
Signed-off-by: Ingo Molnar[rebased for mainline inclusion]
Signed-off-by: Vegard Nossum
11 Jun, 2009
1 commit
-
…/git/tip/linux-2.6-tip
* 'x86-kbuild-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip: (46 commits)
x86, boot: add new generated files to the appropriate .gitignore files
x86, boot: correct the calculation of ZO_INIT_SIZE
x86-64: align __PHYSICAL_START, remove __KERNEL_ALIGN
x86, boot: correct sanity checks in boot/compressed/misc.c
x86: add extension fields for bootloader type and version
x86, defconfig: update kernel position parameters
x86, defconfig: update to current, no material changes
x86: make CONFIG_RELOCATABLE the default
x86: default CONFIG_PHYSICAL_START and CONFIG_PHYSICAL_ALIGN to 16 MB
x86: document new bzImage fields
x86, boot: make kernel_alignment adjustable; new bzImage fields
x86, boot: remove dead code from boot/compressed/head_*.S
x86, boot: use LOAD_PHYSICAL_ADDR on 64 bits
x86, boot: make symbols from the main vmlinux available
x86, boot: determine compressed code offset at compile time
x86, boot: use appropriate rep string for move and clear
x86, boot: zero EFLAGS on 32 bits
x86, boot: set up the decompression stack as early as possible
x86, boot: straighten out ranges to copy/zero in compressed/head*.S
x86, boot: stylistic cleanups for boot/compressed/head_64.S
...Fixed trivial conflict in arch/x86/configs/x86_64_defconfig manually
18 Apr, 2009
1 commit
-
It is common to use "make install" in restricted environments which
differ from the one which was actually used to build the kernel. In
such environments it is highly undesirable to trigger a rebuild of any
part of the system. Worse, the rebuild may be spurious, triggered by
differences in the environment.Signed-off-by: H. Peter Anvin
Cc: Sam Ravnborg
LKML-Reference:
17 Apr, 2009
1 commit
-
Introducing this Kbuild file allow us to:
make arch/x86/
And thus building all the core part of x86.
Signed-off-by: Sam Ravnborg
Cc: Jaswinder Singh Rajput
Signed-off-by: Ingo Molnar
13 Mar, 2009
2 commits
-
Impact: cleanup
Instead of using CLEAN_FILES in arch/x86/Makefile, add generated files
to targets in arch/x86/boot/Makefile, so they will get naturally
cleaned up by "make clean".Cc: Sam Ravnborg
Signed-off-by: H. Peter Anvin -
Impact: cleanup
Remove targets that were used for zImage only, and Makefile
infrastructure that was there to support the zImage/bzImage split.Reported-by: Paul Bolle
LKML-Reference:
Signed-off-by: H. Peter Anvin
13 Feb, 2009
1 commit
10 Feb, 2009
1 commit
-
Impact: no default -fno-stack-protector if stackp is enabled, cleanup
Stackprotector make rules had the following problems.
* cc support test and warning are scattered across makefile and
kernel/panic.c.* -fno-stack-protector was always added regardless of configuration.
Update such that cc support test and warning are contained in makefile
and -fno-stack-protector is added iff stackp is turned off. While at
it, prepare for 32bit support.Signed-off-by: Tejun Heo
Signed-off-by: Ingo Molnar
29 Jan, 2009
2 commits
-
Remove the 32-bit subarchitecture support code.
All subarchitectures but Voyager have been converted. Voyager will be
done later or will be removed.Signed-off-by: Ingo Molnar
-
Remove remaining bits of the subarchitecture code. Now that all the
special platforms are runtime probed and runtime handled, we can remove
these facilities.Signed-off-by: Ingo Molnar
31 Dec, 2008
1 commit
-
Conflicts:
arch/x86/include/asm/pda.h
kernel/fork.c
23 Oct, 2008
1 commit
-
Signed-off-by: Al Viro
Signed-off-by: H. Peter Anvin