17 Oct, 2007

4 commits

  • * git://git.kernel.org/pub/scm/linux/kernel/git/sam/kbuild: (40 commits)
    kbuild: introduce ccflags-y, asflags-y and ldflags-y
    kbuild: enable 'make CPPFLAGS=...' to add additional options to CPP
    kbuild: enable use of AFLAGS and CFLAGS on commandline
    kbuild: enable 'make AFLAGS=...' to add additional options to AS
    kbuild: fix AFLAGS use in h8300 and m68knommu
    kbuild: check for wrong use of CFLAGS
    kbuild: enable 'make CFLAGS=...' to add additional options to CC
    kbuild: fix up CFLAGS usage
    kbuild: make modpost detect unterminated device id lists
    kbuild: call export_report from the Makefile
    kbuild: move Kai Germaschewski to CREDITS
    kconfig/menuconfig: distinguish between selected-by-another options and comments
    kconfig: tristate choices with mixed tristate and boolean values
    include/linux/Kbuild: remove duplicate entries
    kbuild: kill backward compatibility checks
    kbuild: kill EXTRA_ARFLAGS
    kbuild: fix documentation in makefiles.txt
    kbuild: call make once for all targets when O=.. is used
    kbuild: pass -g to assembler under CONFIG_DEBUG_INFO
    kbuild: update _shipped files for kconfig syntax cleanup
    ...

    Fix up conflicts in arch/um/sys-{x86_64,i386}/Makefile manually.

    Linus Torvalds
     
  • Formatting changes in the files which have been changed in the
    tt-removal patchset so far. These include:
    copyright updates
    header file trimming
    style fixes
    adding severity to printks
    indenting Kconfig help according to the predominant kernel style

    These changes should be entirely non-functional.

    Signed-off-by: Jeff Dike
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Jeff Dike
     
  • This patchset throws out tt mode, which has been non-functional for a while.

    This is done in phases, interspersed with code cleanups on the affected files.

    The removal is done as follows:
    remove all code, config options, and files which depend on
    CONFIG_MODE_TT
    get rid of the CHOOSE_MODE macro, which decided whether to
    call tt-mode or skas-mode code, and replace invocations with their
    skas portions
    replace all now-trivial procedures with their skas equivalents

    There are now a bunch of now-redundant pieces of data structures, including
    mode-specific pieces of the thread structure, pt_regs, and mm_context. These
    are all replaced with their skas-specific contents.

    As part of the ongoing style compliance project, I made a style pass over all
    files that were changed. There are three such patches, one for each phase,
    covering the files affected by that phase but no later ones.

    I noticed that we weren't freeing the LDT state associated with a process when
    it exited, so that's fixed in one of the later patches.

    The last patch is a tidying patch which I've had for a while, but which caused
    inexplicable crashes under tt mode. Since that is no longer a problem, this
    can now go in.

    This patch:

    Start getting rid of tt mode support.

    This patch throws out CONFIG_MODE_TT and all config options, code, and files
    which depend on it.

    CONFIG_MODE_SKAS is gone and everything that depends on it is included
    unconditionally.

    The few changed lines are in re-written Kconfig help, lines which needed
    something skas-related removed from them, and a few more which weren't
    strictly deletions.

    Signed-off-by: Jeff Dike
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Jeff Dike
     
  • On some systems, with IPV6 configured, there is a clash between the kernel's
    in6addr_any and the one in libc.

    This is handled in the usual (gross) way of defining the kernel symbol out of
    the way on the gcc command line.

    Signed-off-by: Jeff Dike
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Jeff Dike
     

16 Oct, 2007

1 commit

  • The variable AFLAGS is a wellknown variable and the usage by
    kbuild may result in unexpected behaviour.
    On top of that several people over time has asked for a way to
    pass in additional flags to gcc.

    This patch replace use of AFLAGS with KBUILD_AFLAGS all over
    the tree.

    Patch was tested on following architectures:
    alpha, arm, i386, x86_64, mips, sparc, sparc64, ia64, m68k, s390

    Signed-off-by: Sam Ravnborg

    Sam Ravnborg
     

15 Oct, 2007

1 commit

  • The variable CFLAGS is a wellknown variable and the usage by
    kbuild may result in unexpected behaviour.
    On top of that several people over time has asked for a way to
    pass in additional flags to gcc.

    This patch replace use of CFLAGS with KBUILD_CFLAGS all over the
    tree and enabling one to use:
    make CFLAGS=...
    to specify additional gcc commandline options.

    One usecase is when trying to find gcc bugs but other
    use cases has been requested too.

    Patch was tested on following architectures:
    alpha, arm, i386, x86_64, mips, sparc, sparc64, ia64, m68k

    Test was simple to do a defconfig build, apply the patch and check
    that nothing got rebuild.

    Signed-off-by: Sam Ravnborg

    Sam Ravnborg
     

14 Oct, 2007

1 commit

  • a) include/asm-um/arch can't just point to include/asm-$(SUBARCH) now
    b) arch/{i386,x86_64}/crypto are merged now
    c) subarch-obj needed changes
    d) cpufeature_64.h should pull "cpufeature_32.h", not
    since it can be included from asm-um/cpufeature.h
    e) in case of uml-i386 we need CONFIG_X86_32 for make and gcc, but not
    for Kconfig
    f) sysctl.c shouldn't do vdso_enabled for uml-i386 (actually, that one
    should be registered from corresponding arch/*/kernel/*, with ifdef
    going away; that's a separate patch, though).

    With that and with Stephen's patch ("[PATCH net-2.6] uml: hard_header fix")
    we have uml allmodconfig building both on i386 and amd64.

    Signed-off-by: Al Viro
    Signed-off-by: Linus Torvalds

    Al Viro
     

20 Jul, 2007

1 commit


31 Oct, 2006

1 commit

  • From: Jeff Dike , Paolo Giarrusso

    Make sure that when compiling USER_OBJS the correct compilation options are
    passed; since they are compiled with USER_CFLAGS which is derived from
    CFLAGS, make sure it is a recursively evaluated variable, so that changes
    to CFLAGS done afterwards the inclusion of arch/$(ARCH)/Makefile are
    reflected in USER_CFLAGS.

    For instance, without this patch userspace objects are never compiled with
    debug info active.

    Signed-off-by: Paolo 'Blaisorblade' Giarrusso
    Cc: Jeff Dike
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    akpm@osdl.org
     

04 Oct, 2006

1 commit

  • The patch below corrects multiple occurances of "the the"
    typos across several files, both in source comments and KConfig files.
    There is no actual code changed, only text. Note this only affects the /arch
    directory, and I believe I could find many more elsewhere. :)

    Signed-off-by: Adrian Bunk

    Matt LaPlante
     

02 May, 2006

3 commits

  • Blaisorblade's uml-makefile-nicer makes a V=0 build say SYMLINK where
    what's happening is really a LINK.

    Signed-off-by: Jeff Dike
    Acked-by: Paolo 'Blaisorblade' Giarrusso
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Jeff Dike
     
  • To make some half-assembly stubs compile, disable various "hardened" GCC
    features:

    *) we can't make it build PIC code as we need %ebx to do syscalls and GCC
    wants it free for PIC

    *) we can't leave stack protection as the stub is moved (not relocated!) in
    memory so the RIP-relative access to the canary tries reading from an
    unmapped address and causes a segfault, since we move the stub of various
    megabytes (the exact amount will be decided at runtime) away from the
    link-time address.

    Signed-off-by: Paolo 'Blaisorblade' Giarrusso
    Acked-by: Jeff Dike
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Paolo 'Blaisorblade' Giarrusso
     
  • Move the build of user-offsets to arch/um/sys-$(SUBARCH), where it's located.
    So we can also build it via Kbuild with its dependency tracking rather than by
    hand. While hacking here, fix also a lot of little cosmetic things.

    Signed-off-by: Paolo 'Blaisorblade' Giarrusso
    Acked-by: Jeff Dike
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Paolo 'Blaisorblade' Giarrusso
     

11 Apr, 2006

1 commit


01 Apr, 2006

3 commits

  • ldt-{i386,x86_64}.h is made of two different parts - some code for parsing of
    LDT descriptors, which is arch-dependant, and the code to handle uml_ldt_t (an
    LDT block inside UML), which is mostly arch-independant (among x86 and x86_64,
    at least).

    Join the common part in a single file (ldt.h) and split the rest away
    (host_ldt-{i386,x86_64}.h).

    This is needed because processor.h, with next patches, will start including
    the LDT descriptor parsing macros in host_ldt.h, but it can't include ldt.h
    because it uses semaphores (and to define semaphores one must first include
    processor.h!).

    Signed-off-by: Paolo 'Blaisorblade' Giarrusso
    Acked-by: Jeff Dike
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Paolo 'Blaisorblade' Giarrusso
     
  • no need to add the same file twice to MRPROPER_FILES

    Signed-off-by: Al Viro
    Signed-off-by: Jeff Dike
    Cc: Paolo 'Blaisorblade' Giarrusso
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Al Viro
     
  • kills unmap magic

    Signed-off-by: Al Viro
    Signed-off-by: Jeff Dike
    Cc: Paolo 'Blaisorblade' Giarrusso
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Al Viro
     

06 Mar, 2006

1 commit

  • The kbuild system takes advantage of an incorrect behavior in GNU make.
    Once this behavior is fixed, all files in the kernel rebuild every time,
    even if nothing has changed. This patch ensures kbuild works with both
    the incorrect and correct behaviors of GNU make.

    For more details on the incorrect behavior, see:

    http://lists.gnu.org/archive/html/bug-make/2006-03/msg00003.html

    Changes in this patch:
    - Keep all targets that are to be marked .PHONY in a variable, PHONY.
    - Add .PHONY: $(PHONY) to mark them properly.
    - Remove any $(PHONY) files from the $? list when determining whether
    targets are up-to-date or not.

    Signed-off-by: Paul Smith
    Signed-off-by: Sam Ravnborg

    Paul Smith
     

02 Feb, 2006

2 commits


19 Jan, 2006

1 commit


15 Jan, 2006

1 commit

  • LD .tmp_vmlinux1
    /usr/lib/gcc-lib/i486-linux/3.3.4/../../../libc.a(mktime.o): In function `timelocal':
    : multiple definition of `mktime'
    kernel/built-in.o:kernel/time.c:604: first defined here
    /usr/bin/ld: Warning: size of symbol `mktime' changed from 134 in kernel/built-in.o to 44 in /usr/lib/gcc-lib/i486-linux/3.3.4/../../../libc.a(mktime.o)
    collect2: ld returned 1 exit status

    Signed-off-by: Miklos Szeredi
    Cc: Jeff Dike
    Cc: Paolo 'Blaisorblade' Giarrusso
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Miklos Szeredi
     

12 Jan, 2006

1 commit

  • 2.6.15-mm1 caused kernel-offsets.c to stop compiling with a syntax error in a
    header. The problem was with KBUILD_BASENAME, which didn't get a definition
    with the by-hand compilation in the main UML Makefile.

    This was OK before since the expansion was syntactically the same as the
    KBUILD_BASENAME token. With -mm1, the expansion is now a quote-delimited
    string, so there needs to be a definition of it.

    Since kernel-offsets.c is basically the same as other arches' asm-offsets.c,
    and those seem to build OK, this patch turns kernel-offsets.c into
    asm-offsets.c. kernel-offsets.c is in arch/um/sys-$(SUBARCH), i.e. sys-i386
    and sys-x86_64, while kbuild expects it to be in arch/um/kernel.
    kernel-offsets.c is moved to
    arch/um/include/sysdep-$(SUBARCH)/kernel-offsets.h, which is included by
    arch/um/kernel/asm-offsets.c. With that, include/asm-um/asm-offsets.h is
    generated automatically. kernel-offsets.h continues to exist because it needs
    to be accessible to userspace UML code, and include/asm-um isn't. So, a
    symlink is made from arch/um/include/kernel-offsets.h to
    include/asm-um/asm-offsets.h.

    Signed-off-by: Jeff Dike
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Jeff Dike
     

23 Nov, 2005

1 commit

  • This gives a name to the anonymous union introduced in skas-hold-own-ldt,
    allowing to build on a wider range of gccs.

    It also removes ldt.h, which somehow became real, and replaces it with a
    symlink, and creates ldt-x86_64.h as a copy of ldt-i386.h for now.

    Signed-off-by: Jeff Dike
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Jeff Dike
     

07 Nov, 2005

1 commit

  • A number of fixes to improve behavior when large physical memory sizes
    are specified:

    - libc files need -D_FILE_OFFSET_BITS=64 because there are unavoidable uses
    of non-64 interfaces in libc

    - some %d need to be %u

    Signed-off-by: Jeff Dike
    Cc: Paolo Giarrusso
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Jeff Dike
     

10 Oct, 2005

1 commit


29 Sep, 2005

1 commit

  • UML makefiles sanitized:
    - number of generated headers reduced to 2 (from user-offsets.c and
    kernel-offsets.c resp.). The rest is made constant and simply
    includes those two.
    - mk_... helpers are gone now that we don't need to generate these
    headers
    - arch/um/include2 removed since everything under arch/um/include/sysdep
    is constant now and symlink can point straight to source tree.
    - dependencies seriously simplified.

    Signed-off-by: Al Viro
    Signed-off-by: Linus Torvalds

    Al Viro
     

22 Sep, 2005

1 commit


12 Sep, 2005

1 commit

  • When introducing the generic asm-offsets.h support the dependency
    chain for the prepare targets was changed. All build scripts expecting
    include/asm/asm-offsets.h to be made when using the prepare target would broke.
    With the limited number of prepare targets left in arch Makefiles
    the trivial solution was to introduce a new arch specific target: archprepare

    The dependency chain looks like this now:

    prepare
    |
    +--> prepare0
    |
    +--> archprepare
    |
    +--> scripts_basic
    +--> prepare1
    |
    +---> prepare2
    |
    +--> prepare3

    So prepare 3 is processed before prepare2 etc.
    This guaantees that the asm symlink, version.h, scripts_basic
    are all updated before archprepare is processed.

    prepare0 which build the asm-offsets.h file will need the
    actions performed by archprepare.

    The head target is now named prepare, because users scripts will most
    likely use that target, but prepare-all has been kept for compatibility.
    Updated Documentation/kbuild/makefiles.txt.

    Signed-off-by: Sam Ravnborg

    Sam Ravnborg
     

11 Sep, 2005

1 commit


10 Sep, 2005

1 commit


05 Sep, 2005

2 commits


28 Jul, 2005

1 commit

  • the header file must be build before mk_user_constants. Adding it as a
    direct dep doesnt work for some reason.

    arch/um/os-Linux/util/mk_user_constants.c:2:26: error: user-offsets.h: No such file or directory
    arch/um/os-Linux/util/mk_user_constants.c: In function 'main':
    arch/um/os-Linux/util/mk_user_constants.c:17: error: '__UM_FRAME_SIZE' undeclared (first use in this function)
    arch/um/os-Linux/util/mk_user_constants.c:17: error: (Each undeclared identifier is reported only once
    arch/um/os-Linux/util/mk_user_constants.c:17: error: for each function it appears in.)
    make[1]: *** [arch/um/os-Linux/util/mk_user_constants] Error 1

    Signed-off-by: Olaf Hering
    Cc: Paolo Giarrusso
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Olaf Hering
     

15 Jul, 2005

3 commits

  • This patch makes the command:

    make ARCH=um SUBARCH=i386

    work on x86_64 hosts (with support for building 32-bit binaries). This is
    especially needed since 64-bit UMLs don't support 32-bit emulation for guest
    binaries, currently. This has been tested in all possible cases and works.

    Only exception is that I've built but not tested a 64-bit binary, because I
    hadn't a 64-bit filesystem available.

    Signed-off-by: Paolo 'Blaisorblade' Giarrusso
    Cc: Jeff Dike
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Paolo 'Blaisorblade' Giarrusso
     
  • The pcap support was not working because of some linking problems (expressing
    the construct in Kbuild was a bit difficult) and because there was no user
    request. Now that this has come back, here's the support.

    This has been tested and works on both 32 and 64-bit hosts, even when
    "cross-"building 32-bit binaries.

    Signed-off-by: Paolo 'Blaisorblade' Giarrusso
    Cc: Jeff Dike
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Paolo 'Blaisorblade' Giarrusso
     
  • 1) Cleanup an ugly hyper-nested code in Makefile (now only the arith.
    expression is passed through the host bash).

    2) Fix a problem with GCC 2.95: according to a report from Raphael Bossek,
    .remap_data : { arch/um/sys-SUBARCH/unmap_fin.o (.data .bss) } is expanded
    into: .remap_data : { arch/um/sys-i386 /unmap_fin.o (.data .bss) }

    (because I didn't use ## to join the two tokens), thus stopping linking. Pass
    the whole path from the Makefile as a simple and nice fix.

    Signed-off-by: Paolo 'Blaisorblade' Giarrusso
    Cc: Raphael Bossek
    Cc: Jeff Dike
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Paolo 'Blaisorblade' Giarrusso
     

13 Jul, 2005

1 commit


22 Jun, 2005

1 commit

  • With Al Viro

    To make sure switcheroo() can execute when we remap all the executable
    image, we used a trick to make it use a local copy of errno... this trick
    does not work with NPTL glibc, only with LinuxThreads, so use another
    (simpler) one to make it work anyway.

    Hopefully, a lot improved thanks to merging with the version of Al Viro
    (which had his part of problems, though, i.e. removing a fix to another
    bug and not fixing the problem on i386).

    Signed-off-by: Paolo 'Blaisorblade' Giarrusso
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Paolo 'Blaisorblade' Giarrusso
     

06 May, 2005

1 commit