12 Oct, 2007

2 commits

  • arch/s390/Kconfig tells us that CONFIG_APPLDATA_BASE is bool and hence can
    never be built modular. Given this, defining appldata_exit() function is
    pointless (and wasteful, actually). Remove all that.

    Previous patch annotated appldata_offline_cpu() as __cpuexit, but now with the
    __exit function appldata_exit() gone, the only callsite that references it is
    __cpuinit, so this function can also be __cpuinit, thereby saving space when
    HOTPLUG_CPU=n.

    Signed-off-by: Satyam Sharma
    Cc: Heiko Carstens
    Signed-off-by: Andrew Morton
    Signed-off-by: Martin Schwidefsky

    Satyam Sharma
     
  • appldata_offline_cpu() is only called from __cpuinit-marked hotplug
    notifier callback and from the __exit-marked module_exit function,
    therefore candidate for __cpuexit.

    BTW the __exit module_exit function appldata_exit() of this driver fails to
    unregister_hotcpu_notifier() the notifier_block that was registered by
    appldata_init() during module startup. This will lead to oops if hotplug
    notification comes after module has been unloaded. Let's fix this by
    unregistering the notifier appropriately (before appldata_offline_cpu()'ing
    the CPUs).

    Signed-off-by: Satyam Sharma
    Cc: Heiko Carstens
    Signed-off-by: Andrew Morton
    Signed-off-by: Martin Schwidefsky

    Satyam Sharma
     

11 Oct, 2007

1 commit

  • This patch makes most of the generic device layer network
    namespace safe. This patch makes dev_base_head a
    network namespace variable, and then it picks up
    a few associated variables. The functions:
    dev_getbyhwaddr
    dev_getfirsthwbytype
    dev_get_by_flags
    dev_get_by_name
    __dev_get_by_name
    dev_get_by_index
    __dev_get_by_index
    dev_ioctl
    dev_ethtool
    dev_load
    wireless_process_ioctl

    were modified to take a network namespace argument, and
    deal with it.

    vlan_ioctl_set and brioctl_set were modified so their
    hooks will receive a network namespace argument.

    So basically anthing in the core of the network stack that was
    affected to by the change of dev_base was modified to handle
    multiple network namespaces. The rest of the network stack was
    simply modified to explicitly use &init_net the initial network
    namespace. This can be fixed when those components of the network
    stack are modified to handle multiple network namespaces.

    For now the ifindex generator is left global.

    Fundametally ifindex numbers are per namespace, or else
    we will have corner case problems with migration when
    we get that far.

    At the same time there are assumptions in the network stack
    that the ifindex of a network device won't change. Making
    the ifindex number global seems a good compromise until
    the network stack can cope with ifindex changes when
    you change namespaces, and the like.

    Signed-off-by: Eric W. Biederman
    Signed-off-by: David S. Miller

    Eric W. Biederman
     

27 Jul, 2007

1 commit


19 Jun, 2007

1 commit

  • WARNING: arch/s390/kernel/built-in.o(.text+0xb92a):
    Section mismatch: reference to .init.text:start_secondary
    (between 'restart_addr' and 'stack_overflow')
    WARNING: arch/s390/appldata/built-in.o(.data+0xdc):
    Section mismatch: reference to .init.text:
    (between 'appldata_nb' and 'appldata_timer_lock')

    Signed-off-by: Heiko Carstens
    Signed-off-by: Martin Schwidefsky

    Heiko Carstens
     

10 May, 2007

1 commit

  • Since nonboot CPUs are now disabled after tasks and devices have been
    frozen and the CPU hotplug infrastructure is used for this purpose, we need
    special CPU hotplug notifications that will help the CPU-hotplug-aware
    subsystems distinguish normal CPU hotplug events from CPU hotplug events
    related to a system-wide suspend or resume operation in progress. This
    patch introduces such notifications and causes them to be used during
    suspend and resume transitions. It also changes all of the
    CPU-hotplug-aware subsystems to take these notifications into consideration
    (for now they are handled in the same way as the corresponding "normal"
    ones).

    [oleg@tv-sign.ru: cleanups]
    Signed-off-by: Rafael J. Wysocki
    Cc: Gautham R Shenoy
    Cc: Pavel Machek
    Signed-off-by: Oleg Nesterov
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Rafael J. Wysocki
     

04 May, 2007

1 commit

  • Cleanup of dev_base list use, with the aim to simplify making device
    list per-namespace. In almost every occasion, use of dev_base variable
    and dev->next pointer could be easily replaced by for_each_netdev
    loop. A few most complicated places were converted to using
    first_netdev()/next_netdev().

    Signed-off-by: Pavel Emelianov
    Acked-by: Kirill Korotaev
    Signed-off-by: David S. Miller

    Pavel Emelianov
     

29 Apr, 2007

1 commit


28 Apr, 2007

1 commit

  • * master.kernel.org:/pub/scm/linux/kernel/git/davem/net-2.6: (448 commits)
    [IPV4] nl_fib_lookup: Initialise res.r before fib_res_put(&res)
    [IPV6]: Fix thinko in ipv6_rthdr_rcv() changes.
    [IPV4]: Add multipath cached to feature-removal-schedule.txt
    [WIRELESS] cfg80211: Clarify locking comment.
    [WIRELESS] cfg80211: Fix locking in wiphy_new.
    [WEXT] net_device: Don't include wext bits if not required.
    [WEXT]: Misc code cleanups.
    [WEXT]: Reduce inline abuse.
    [WEXT]: Move EXPORT_SYMBOL statements where they belong.
    [WEXT]: Cleanup early ioctl call path.
    [WEXT]: Remove options.
    [WEXT]: Remove dead debug code.
    [WEXT]: Clean up how wext is called.
    [WEXT]: Move to net/wireless
    [AFS]: Eliminate cmpxchg() usage in vlocation code.
    [RXRPC]: Fix pointers passed to bitops.
    [RXRPC]: Remove bogus atomic_* overrides.
    [AFS]: Fix u64 printing in debug logging.
    [AFS]: Add "directory write" support.
    [AFS]: Implement the CB.InitCallBackState3 operation.
    ...

    Linus Torvalds
     

27 Apr, 2007

1 commit

  • arch/s390/appldata/appldata_base.c has some confusing debugging code left
    over to allow compiling it as a module. In practice, it cannot be configured
    as module and there is no need to keep that code.

    Signed-off-by: Gerald Schaefer
    Signed-off-by: Martin Schwidefsky

    Martin Schwidefsky
     

26 Apr, 2007

1 commit

  • Network drivers which keep stats allocate their own stats structure
    then write a get_stats() function to return them. It would be nice if
    this were done by default.

    1) Add a new "stats" field to "struct net_device".
    2) Add a new feature field to say "this driver uses the internal one"
    3) Have a default "get_stats" which returns NULL if that feature not set.
    4) Change callers to check result of get_stats call for NULL, not if
    ->get_stats is set.

    This should not break backwards compatibility with older drivers, yet
    allow modern drivers to shed some boilerplate code.

    Lightly tested: works for a modified lguest network driver.

    Signed-off-by: Rusty Russell
    Signed-off-by: David S. Miller

    Rusty Russell
     

15 Mar, 2007

1 commit


15 Feb, 2007

3 commits

  • The semantic effect of insert_at_head is that it would allow new registered
    sysctl entries to override existing sysctl entries of the same name. Which is
    pain for caching and the proc interface never implemented.

    I have done an audit and discovered that none of the current users of
    register_sysctl care as (excpet for directories) they do not register
    duplicate sysctl entries.

    So this patch simply removes the support for overriding existing entries in
    the sys_sysctl interface since no one uses it or cares and it makes future
    enhancments harder.

    Signed-off-by: Eric W. Biederman
    Acked-by: Ralf Baechle
    Acked-by: Martin Schwidefsky
    Cc: Russell King
    Cc: David Howells
    Cc: "Luck, Tony"
    Cc: Ralf Baechle
    Cc: Paul Mackerras
    Cc: Martin Schwidefsky
    Cc: Andi Kleen
    Cc: Jens Axboe
    Cc: Corey Minyard
    Cc: Neil Brown
    Cc: "John W. Linville"
    Cc: James Bottomley
    Cc: Jan Kara
    Cc: Trond Myklebust
    Cc: Mark Fasheh
    Cc: David Chinner
    Cc: "David S. Miller"
    Cc: Patrick McHardy
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Eric W. Biederman
     
  • Signed-off-by: Eric W. Biederman
    Acked-by: Martin Schwidefsky
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Eric W. Biederman
     
  • We need to have the the definition of all top level sysctl directories
    registers in sysctl.h so we don't conflict by accident and cause abi problems.

    Signed-off-by: Eric W. Biederman
    Acked-by: Martin Schwidefsky
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Eric W. Biederman
     

06 Feb, 2007

1 commit


08 Dec, 2006

1 commit

  • There was lots of #ifdef noise in the kernel due to hotcpu_notifier(fn,
    prio) not correctly marking 'fn' as used in the !HOTPLUG_CPU case, and thus
    generating compiler warnings of unused symbols, hence forcing people to add
    #ifdefs.

    the compiler can skip truly unused functions just fine:

    text data bss dec hex filename
    1624412 728710 3674856 6027978 5bfaca vmlinux.before
    1624412 728710 3674856 6027978 5bfaca vmlinux.after

    [akpm@osdl.org: topology.c fix]
    Signed-off-by: Ingo Molnar
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Ingo Molnar
     

06 Dec, 2006

1 commit


27 Oct, 2006

1 commit


11 Oct, 2006

1 commit

  • Remove the last few places where a pointer to pt_regs gets passed.
    Also make sure we call set_irq_regs() before irq_enter() and after
    irq_exit(). This doesn't fix anything but makes sure s390 looks the
    same like all other architectures.

    Signed-off-by: Heiko Carstens
    Signed-off-by: Martin Schwidefsky

    Heiko Carstens
     

30 Sep, 2006

1 commit

  • Convert s390 page handling macros to functions. In particular this fixes a
    problem with s390's SetPageUptodate macro which uses its input parameter
    twice which again can cause subtle bugs.

    [akpm@osdl.org: build fix]
    Cc: Martin Schwidefsky
    Signed-off-by: Heiko Carstens
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Heiko Carstens
     

28 Sep, 2006

1 commit


26 Sep, 2006

1 commit


20 Sep, 2006

1 commit


08 Aug, 2006

1 commit


01 Aug, 2006

1 commit


01 Jul, 2006

4 commits

  • * git://git.kernel.org/pub/scm/linux/kernel/git/bunk/trivial:
    Remove obsolete #include
    remove obsolete swsusp_encrypt
    arch/arm26/Kconfig typos
    Documentation/IPMI typos
    Kconfig: Typos in net/sched/Kconfig
    v9fs: do not include linux/version.h
    Documentation/DocBook/mtdnand.tmpl: typo fixes
    typo fixes: specfic -> specific
    typo fixes in Documentation/networking/pktgen.txt
    typo fixes: occuring -> occurring
    typo fixes: infomation -> information
    typo fixes: disadvantadge -> disadvantage
    typo fixes: aquire -> acquire
    typo fixes: mecanism -> mechanism
    typo fixes: bandwith -> bandwidth
    fix a typo in the RTC_CLASS help text
    smb is no longer maintained

    Manually merged trivial conflict in arch/um/kernel/vmlinux.lds.S

    Linus Torvalds
     
  • The remaining counters in page_state after the zoned VM counter patches
    have been applied are all just for show in /proc/vmstat. They have no
    essential function for the VM.

    We use a simple increment of per cpu variables. In order to avoid the most
    severe races we disable preempt. Preempt does not prevent the race between
    an increment and an interrupt handler incrementing the same statistics
    counter. However, that race is exceedingly rare, we may only loose one
    increment or so and there is no requirement (at least not in kernel) that
    the vm event counters have to be accurate.

    In the non preempt case this results in a simple increment for each
    counter. For many architectures this will be reduced by the compiler to a
    single instruction. This single instruction is atomic for i386 and x86_64.
    And therefore even the rare race condition in an interrupt is avoided for
    both architectures in most cases.

    The patchset also adds an off switch for embedded systems that allows a
    building of linux kernels without these counters.

    The implementation of these counters is through inline code that hopefully
    results in only a single instruction increment instruction being emitted
    (i386, x86_64) or in the increment being hidden though instruction
    concurrency (EPIC architectures such as ia64 can get that done).

    Benefits:
    - VM event counter operations usually reduce to a single inline instruction
    on i386 and x86_64.
    - No interrupt disable, only preempt disable for the preempt case.
    Preempt disable can also be avoided by moving the counter into a spinlock.
    - Handling is similar to zoned VM counters.
    - Simple and easily extendable.
    - Can be omitted to reduce memory use for embedded use.

    References:

    RFC http://marc.theaimsgroup.com/?l=linux-kernel&m=113512330605497&w=2
    RFC http://marc.theaimsgroup.com/?l=linux-kernel&m=114988082814934&w=2
    local_t http://marc.theaimsgroup.com/?l=linux-kernel&m=114991748606690&w=2
    V2 http://marc.theaimsgroup.com/?t=115014808400007&r=1&w=2
    V3 http://marc.theaimsgroup.com/?l=linux-kernel&m=115024767022346&w=2
    V4 http://marc.theaimsgroup.com/?l=linux-kernel&m=115047968808926&w=2

    Signed-off-by: Christoph Lameter
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Christoph Lameter
     
  • Currently a single atomic variable is used to establish the size of the page
    cache in the whole machine. The zoned VM counters have the same method of
    implementation as the nr_pagecache code but also allow the determination of
    the pagecache size per zone.

    Remove the special implementation for nr_pagecache and make it a zoned counter
    named NR_FILE_PAGES.

    Updates of the page cache counters are always performed with interrupts off.
    We can therefore use the __ variant here.

    Signed-off-by: Christoph Lameter
    Cc: Trond Myklebust
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Christoph Lameter
     
  • Signed-off-by: Jörn Engel
    Signed-off-by: Adrian Bunk

    Jörn Engel
     

29 Jun, 2006

3 commits


28 Jun, 2006

1 commit


26 Apr, 2006

1 commit

  • Few of the notifier_chain_register() callers use __devinitdata in the
    definition of notifier_block data structure. It is incorrect as the
    data structure should be available after the initializations (they do
    not unregister them during initializations).

    This was leading to an oops when notifier_chain_register() call is
    invoked for those callback chains after initialization.

    This patch fixes all such usages to _not_ have the notifier_block data
    structure in the init data section.

    Signed-off-by: Chandra Seetharaman
    Signed-off-by: Linus Torvalds

    Chandra Seetharaman
     

24 Mar, 2006

1 commit


07 Jan, 2006

2 commits

  • Sanitize some s390 Kconfig options. We have ARCH_S390, ARCH_S390X,
    ARCH_S390_31, 64BIT, S390_SUPPORT and COMPAT. Replace these 6 options by
    S390, 64BIT and COMPAT.

    Signed-off-by: Martin Schwidefsky
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Martin Schwidefsky
     
  • There are some more places where the use of cputime_t instead of an integer
    type and the associated macros is necessary for the virtual cputime accounting
    on s390. Affected are the s390 specific appldata code and BSD process
    accounting.

    Signed-off-by: Martin Schwidefsky
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Martin Schwidefsky
     

09 Nov, 2005

1 commit

  • You could open the /proc/sys/net/ipv4/conf// file, then
    wait for interface to go away, try to grab as much memory as possible in
    hope to hit the (kfreed) ctl_table. Then fill it with pointers to your
    function. Then do read from file you've opened and if you are lucky,
    you'll get it called as ->proc_handler() in kernel mode.

    So this is at least an Oops and possibly more. It does depend on an
    interface going away though, so less of a security risk than it would
    otherwise be.

    Signed-off-by: Greg Kroah-Hartman
    Signed-off-by: Linus Torvalds

    Al Viro
     

30 Jul, 2005

1 commit