12 Apr, 2008

6 commits


11 Apr, 2008

33 commits

  • git commit 54a015104136974262afa4b8ddd943ea70dec8a2 ("asmlinkage_protect
    replaces prevent_tail_call") causes this build failure on s390:

    AS arch/s390/kernel/entry64.o
    In file included from arch/s390/kernel/entry64.S:14:
    include/linux/linkage.h:34: error: syntax error in macro parameter list
    make[1]: *** [arch/s390/kernel/entry64.o] Error 1
    make: *** [arch/s390/kernel] Error 2

    and some other architectures. The reason is that some architectures add
    the "-traditional" flag to the invocation of $(AS), which disables
    variadic macro argument support.

    So just surround the new define with an #ifndef __ASSEMBLY__ to prevent
    any side effects on asm code.

    Cc: Roland McGrath
    Cc: Martin Schwidefsky
    Signed-off-by: Heiko Carstens
    Signed-off-by: Linus Torvalds

    Heiko Carstens
     
  • * 'i2c-for-linus' of git://jdelvare.pck.nerim.net/jdelvare-2.6:
    i2c-tiny-usb: New VID/PID pair
    i2c-davinci: Fix lost interrupt
    i2c-ibm_iic: Fast mode parm desc fixup

    Linus Torvalds
     
  • * git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-2.6:
    [NETNS][IPV6] tcp - assign the netns for timewait sockets
    [IPV4]: Fix byte value boundary check in do_ip_getsockopt().
    BNX2X: Correct bringing chip out of reset
    [NETFILTER]: nf_nat: autoload IPv4 connection tracking
    [NETFILTER]: xt_hashlimit: fix mask calculation
    [XFRM]: xfrm_user: fix selector family initialization
    rt61pci: rt61pci_beacon_update do not free skb twice
    ssb-mipscore: Fix interrupt vectors
    ssb-pcicore: Fix IRQ TPS flag handling
    mac80211: use short_preamble mode from capability if ERP IE not present
    [NET]: Undo code bloat in hot paths due to print_mac().
    [TCP]: Don't allow FRTO to take place while MTU is being probed
    [TCP]: tcp_simple_retransmit can cause S+L
    [TCP]: Fix NewReno's fast rexmit/recovery problems with GSOed skb
    [TCP]: Restore 2.6.24 mark_head_lost behavior for newreno/fack
    nl80211: fix STA AID bug
    b43legacy: fix bcm4303 crash
    iwlwifi: fix n-band association problem
    ipw2200: set MAC address on radiotap interface
    libertas: fix mode initialization problem

    Linus Torvalds
     
  • * git://git.kernel.org/pub/scm/linux/kernel/git/davem/sparc-2.6:
    [SPARC]: Fix several regset and ptrace bugs.

    Linus Torvalds
     
  • Michael Kerrisk found out that signalfd was not reporting back user data
    pushed using sigqueue:

    http://groups.google.com/group/linux.kernel/msg/9397cab8551e3123

    The following patch makes signalfd report back the ssi_ptr and ssi_int members
    of the signalfd_siginfo structure.

    Signed-off-by: Davide Libenzi
    Acked-by: Michael Kerrisk
    Cc:
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Davide Libenzi
     
  • Increase the PNP "number of devices" limit. We currently use an unsigned
    char, which limits us to 256 devices per protocol. This patch changes that to
    an unsigned int.

    Not all backends can take advantage of this: we limit ISAPNP to 10 devices in
    isapnp_cfg_begin(), and PNPBIOS is limited to 256 devices because the BIOS
    interfaces use a one-byte device node number.

    But there is no limit on the number of PNPACPI devices we may have. Large HP
    Integrity machines have more than 256, which causes the current "unsigned char
    number" to wrap around. This causes errors like this:

    pnp: PnP ACPI init
    kobject_add failed for 00:00 with -EEXIST, don't try to register things with the same name in the same directory.

    Call Trace:
    [] show_stack+0x40/0xa0
    [] dump_stack+0x30/0x60
    [] kobject_add+0x290/0x2c0
    [] device_add+0x160/0x860
    [] device_register+0x30/0x60
    [] __pnp_add_device+0x130/0x180
    [] pnp_add_device+0xb0/0xe0
    [] pnpacpi_add_device+0x510/0x5a0
    [] pnpacpi_add_device_handler+0x50/0x80

    This patch increases the limit to fix this PNPACPI problem. It should not
    have any adverse effect on ISAPNP or PNPBIOS because their limits are still
    enforced in the backends.

    Signed-off-by: Bjorn Helgaas
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Bjorn Helgaas
     
  • If a failure is detected after a parity check operation has been initiated,
    but before it completes handle_parity_checks5 will never quiesce operations on
    the stripe.

    Explicitly handle this case by "canceling" the parity check, i.e. clear the
    STRIPE_OP_CHECK flags and queue the stripe on the handle list again to refresh
    any non-uptodate blocks.

    Kernel versions >= 2.6.23 are susceptible.

    Cc:
    Cc: NeilBrown
    Signed-off-by: Dan Williams
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Dan Williams
     
  • This patch adds the missing include directive to the
    cciss.c source file.   This was discovered by our release team when building
    the kernel for the Alpha architecture.

    Errors were found as references to functions 'sg_init_table' and 'sg_page' do
    not exist without the include for Alpha.

    Signed-off-by: Mike Pagano
    Cc: Jens Axboe
    Cc:
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Mike Pagano
     
  • Since 43cc71eed1250755986da4c0f9898f9a635cb3bf, the platform modalias is
    prefixed with "platform:". Add MODULE_ALIAS() to the hotpluggable RTC
    platform drivers, to re-enable module auto loading.

    [dbrownell@users.sourceforge.net: more drivers, minor fix]
    Signed-off-by: Kay Sievers
    Signed-off-by: David Brownell
    Cc: Greg KH
    Cc: Alessandro Zummo
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Kay Sievers
     
  • Since 43cc71eed1250755986da4c0f9898f9a635cb3bf, the platform modalias is
    prefixed with "platform:". Add MODULE_ALIAS() to the hotpluggable watchdog
    drivers, to re-enable auto loading.

    [dbrownell@users.sourceforge.net: more drivers; registration fixes]
    Signed-off-by: Kay Sievers
    Signed-off-by: David Brownell
    Cc: Wim Van Sebroeck
    Cc: Greg KH
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Kay Sievers
     
  • Since 43cc71eed1250755986da4c0f9898f9a635cb3bf, the platform modalias is
    prefixed with "platform:". Add MODULE_ALIAS() to the hotpluggable USB HCDs,
    to allow re-enable auto loading.

    [dbrownell@users.sourceforge.net: more drivers; registration fixes]
    Signed-off-by: Kay Sievers
    Signed-off-by: David Brownell
    Cc: Greg KH
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Kay Sievers
     
  • Since 43cc71eed1250755986da4c0f9898f9a635cb3bf, the platform modalias is
    prefixed with "platform:". Add MODULE_ALIAS() to the hotpluggable usb
    peripheral drivers, to re-eable module auto loading.

    [dbrownell@users.sourceforge.net: registration fixes]
    Signed-off-by: Kay Sievers
    Signed-off-by: David Brownell
    Cc: Greg KH
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Kay Sievers
     
  • Since 43cc71eed1250755986da4c0f9898f9a635cb3bf, the platform modalias is
    prefixed with "platform:". Add MODULE_ALIAS() to the hotpluggable SPI
    platform drivers, to allow module auto loading.

    [dbrownell@users.sourceforge.net: more drivers: registration fixes]
    Signed-off-by: Kay Sievers
    Signed-off-by: David Brownell
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Kay Sievers
     
  • Jeff Roberson discovered a race when using kaio eventfd based notifications.
    When it occurs it can lead tomissed wakeups and hung userspace.

    This patch fixes the race by moving the notification inside the spinlocked
    section of kaio. The operation is safe since eventfd spinlock and kaio one
    are unrelated.

    Signed-off-by: Davide Libenzi
    Cc: Zach Brown
    Cc: Jeff Roberson
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Davide Libenzi
     
  • rtc-s35390a uses BITREVERSE functions so it needs to select that config symbol
    to ensure that the functions are built.

    drivers/built-in.o: In function `s35390a_set_datetime':
    linux-2.6.25-rc8-git7/drivers/rtc/rtc-s35390a.c:144: undefined reference to `byte_rev_table'
    drivers/built-in.o: In function `s35390a_get_datetime':
    linux-2.6.25-rc8-git7/drivers/rtc/rtc-s35390a.c:163: undefined reference to `byte_rev_table'

    Signed-off-by: Randy Dunlap
    Acked-by: Alessandro Zummo
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Randy Dunlap
     
  • Extend the /proc//cgroup file to include the appropriate hierarchy ID on
    each line.

    Currently this ID isn't really needed since a hierarchy can be completely
    identified by the set of subsystems bound to it, but this is likely to change
    in the near future in order to support stateless subsystems and
    merging/rebinding of subsystems. Getting this change into 2.6.25 reduces the
    need for an API change later.

    Signed-off-by: Paul Menage
    Cc: Balbir Singh
    Cc: Pavel Emelyanov
    Cc: KAMEZAWA Hiroyuki
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Paul Menage
     
  • I have recently bought some USB PIDs from EZPrototypes for my USB projects
    and one will be for the i2c-tiny-usb. I have not yet started to use the new
    one in the official i2c-tiny-usb firmware since i think it makes sense to get
    the change into the kernel before releasing a modified firmware.

    This patch adds support for the EZPrototypes USB vid/pid pair used in later
    i2c-tiny-usb firmware versions (avrusb v1.06 and up, usbtiny v2.06 and up).

    Signed-off-by: Till Harbaum
    Signed-off-by: Jean Delvare

    Till Harbaum
     
  • DAVINCI_I2C_STR_REG is a write 1 to clear register,
    so don't use a read/modify/write cycle.

    Signed-off-by: Troy Kisky
    Acked-by: Dirk Behme
    Signed-off-by: Kevin Hilman
    Signed-off-by: Jean Delvare

    Troy Kisky
     
  • Noticed this when grepping for fast mode module params, the i2c-ibm_iic
    driver was using a non-existent variable for MODULE_PARM_DESC. Fix it up
    to reflect what it's actually supposed to be describing.

    Signed-off-by: Paul Mundt
    Signed-off-by: Jean Delvare

    Paul Mundt
     
  • Copy the network namespace from the socket to the timewait socket.

    Signed-off-by: Daniel Lezcano
    Acked-by: Mark Lord
    Signed-off-by: David S. Miller

    Daniel Lezcano
     
  • It's really a pretty ugly thing to need, and some day it will hopefully
    be obviated by teaching gcc about the magic calling conventions for the
    low-level system call code, but in the meantime we can at least add big
    honking comments about why we need these insane and strange macros.

    I took my comments from my version of the macro, but I ended up deciding
    to just pick Roland's version of the actual code instead (with his
    prettier syntax that uses vararg macros). Thus the previous two commits
    that actually implement it.

    Signed-off-by: Linus Torvalds

    Linus Torvalds
     
  • Use asmlinkage_protect in sys_io_getevents, because GCC for i386 with
    CONFIG_FRAME_POINTER=n can decide to clobber an argument word on the
    stack, i.e. the user struct pt_regs. Here the problem is not a tail
    call, but just the compiler's use of the stack when it inlines and
    optimizes the body of the called function. This seems to avoid it.

    Signed-off-by: Roland McGrath
    Signed-off-by: Linus Torvalds

    Roland McGrath
     
  • The prevent_tail_call() macro works around the problem of the compiler
    clobbering argument words on the stack, which for asmlinkage functions
    is the caller's (user's) struct pt_regs. The tail/sibling-call
    optimization is not the only way that the compiler can decide to use
    stack argument words as scratch space, which we have to prevent.
    Other optimizations can do it too.

    Until we have new compiler support to make "asmlinkage" binding on the
    compiler's own use of the stack argument frame, we have work around all
    the manifestations of this issue that crop up.

    More cases seem to be prevented by also keeping the incoming argument
    variables live at the end of the function. This makes their original
    stack slots attractive places to leave those variables, so the compiler
    tends not clobber them for something else. It's still no guarantee, but
    it handles some observed cases that prevent_tail_call() did not.

    Signed-off-by: Roland McGrath
    Signed-off-by: Linus Torvalds

    Roland McGrath
     
  • This patch also resolves hangs on boot:
    http://lkml.org/lkml/2008/2/23/263
    http://bugzilla.kernel.org/show_bug.cgi?id=10093

    The bug was causing once-in-few-reboots 10-15 sec wait during boot on
    certain laptops.

    Earlier commit 40d6a146629b98d8e322b6f9332b182c7cbff3df added
    smp_call_function in cpu_idle_wait() to kick cpus that are in tickless
    idle. Looking at cpu_idle_wait code at that time, code seemed to be
    over-engineered for a case which is rarely used (while changing idle
    handler).

    Below is a simplified version of cpu_idle_wait, which just makes a dummy
    smp_call_function to all cpus, to make them come out of old idle handler
    and start using the new idle handler. It eliminates code in the idle
    loop to handle cpu_idle_wait.

    Signed-off-by: Venkatesh Pallipadi
    Signed-off-by: Linus Torvalds

    Venki Pallipadi
     
  • Shift of a LE value seems strange, probably meant to shift the cpu-order
    variable as in the prvious section of the switch statement.

    Signed-off-by: Harvey Harrison
    Acked-by: Richard Purdie
    Signed-off-by: Linus Torvalds

    Harvey Harrison
     
  • Don't make smp_{r,w,}mb() interpolate a MEMBAR instruction when CONFIG_SMP=n as
    SMP memory barries on UP systems should interpolate a compiler barrier only.

    Signed-off-by: David Howells
    Signed-off-by: Linus Torvalds

    David Howells
     
  • Make NOMMU-mode work with base addresses other than 0xC0000000 by:

    (1) Giving the code that sets up the protection registers the right address
    in __sdram_base. Rather than being hard coded to 0xC0000000, the value
    of __page_offset is obtained from the linker script.

    (2) Eliminate the check in __switch_to() that verifies the current thread
    info is in the 0xCxxxxxxx region.

    Signed-off-by: David Howells
    Signed-off-by: Linus Torvalds

    David Howells
     
  • Use traps 120-126 to emulate atomic cmpxchg32, xchg32, and XOR-, OR-, AND-, SUB-
    and ADD-to-memory operations for userspace.

    Signed-off-by: David Howells
    Signed-off-by: Linus Torvalds

    David Howells
     
  • Move STACK_TOP_MAX up so that we don't try moving the stack above it as that
    causes setup_arg_pages() to malfunction.

    Signed-off-by: David Howells
    Signed-off-by: Linus Torvalds

    David Howells
     
  • Handle update_mmu_cache() being called when current->mm is NULL.

    We cache static TLB mappings for the current page table in DAMPR4 and DAMPR5
    on the theory that the next data lookup is likely to be in the same general
    region, and thus is likely to be mapped by the same page table. However, we
    can't get this information if we can't access the appropriate mm_struct.

    If current->mm is NULL, we just clear the cache in the knowledge that the TLB
    miss handlers will load it.

    Signed-off-by: David Howells
    Signed-off-by: Linus Torvalds

    David Howells
     
  • * 'for-linus' of git://oss.sgi.com:8090/xfs/xfs-2.6:
    [XFS] Ensure "both" features2 slots are consistent
    [XFS] Fix superblock features2 field alignment problem
    [XFS] remove shouting-indirection macros from xfs_sb.h

    Linus Torvalds
     
  • * 'for-linus' of git://git.kernel.dk/linux-2.6-block:
    cfq-iosched: do not leak ioc_data across iosched switches
    splice: fix infinite loop in generic_file_splice_read()

    Linus Torvalds
     
  • Some time ago while attempting to handle invalid link counts, I botched
    the unlink of links itself, so this patch fixes this now correctly, so
    that only the link count of nodes that don't point to links is ignored.
    Thanks to Vlado Plaga to notify me of this
    problem.

    Signed-off-by: Roman Zippel
    Signed-off-by: Linus Torvalds

    Roman Zippel
     

10 Apr, 2008

1 commit

  • This fixes kernel bugzilla 10371.

    As reported by M.Piechaczek@osmosys.tv, if we try to grab a
    char sized socket option value, as in:

    unsigned char ttl = 255;
    socklen_t len = sizeof(ttl);
    setsockopt(socket, IPPROTO_IP, IP_MULTICAST_TTL, &ttl, &len);

    getsockopt(socket, IPPROTO_IP, IP_MULTICAST_TTL, &ttl, &len);

    The ttl returned will be wrong on big-endian, and on both little-
    endian and big-endian the next three bytes in userspace are written
    with garbage.

    It's because of this test in do_ip_getsockopt():

    if (len < sizeof(int) && len > 0 && val>=0 && val

    David S. Miller