01 May, 2007

29 commits

  • net/sunrpc/pmap_clnt.c has been replaced by net/sunrpc/rpcb_clnt.c.

    Signed-off-by: Chuck Lever
    Signed-off-by: Trond Myklebust

    Chuck Lever
     
  • It is arguable whether NFSROOT will support IPv6, and thus whether
    rpcb_getport_external needs to support rpcbind versions greater than 2.

    Signed-off-by: Chuck Lever
    Signed-off-by: Trond Myklebust

    Chuck Lever
     
  • Eventually this interface will support versions 3 and 4 of the rpcbind
    protocol, which will allow the Linux RPC server to register services on
    IPv6 addresses.

    Signed-off-by: Chuck Lever
    Signed-off-by: Trond Myklebust

    Chuck Lever
     
  • Now that we have a version of the portmapper that supports versions 3 and 4
    of the rpcbind protocol, use it for new RPC client connections over
    sockets.

    Signed-off-by: Chuck Lever
    Signed-off-by: Trond Myklebust

    Chuck Lever
     
  • Introduce a replacement for the in-kernel portmapper client that supports
    all 3 versions of the rpcbind protocol. This code is not used yet.

    Original code by Groupe Bull updated for the latest kernel, with multiple
    bug fixes.

    Note that rpcb_clnt.c does not yet support registering via versions 3 and
    4 of the rpcbind protocol. That is planned for a later patch.

    Signed-off-by: Chuck Lever
    Signed-off-by: Trond Myklebust

    Chuck Lever
     
  • Currently rpc_malloc sets req->rq_buffer internally. Make this a more
    generic interface: return a pointer to the new buffer (or NULL) and
    make the caller set req->rq_buffer and req->rq_bufsize. This looks much
    more like kmalloc and eliminates the side effects.

    To fix a potential deadlock, this patch also replaces GFP_NOFS with
    GFP_NOWAIT in rpc_malloc. This prevents async RPCs from sleeping outside
    the RPC's task scheduler while allocating their buffer.

    Signed-off-by: Chuck Lever
    Signed-off-by: Trond Myklebust

    Chuck Lever
     
  • The RPC buffer size estimation logic in net/sunrpc/clnt.c always
    significantly overestimates the requirements for the buffer size.
    A little instrumentation demonstrated that in fact rpc_malloc was never
    allocating the buffer from the mempool, but almost always called kmalloc.

    To compute the size of the RPC buffer more precisely, split p_bufsiz into
    two fields; one for the argument size, and one for the result size.

    Then, compute the sum of the exact call and reply header sizes, and split
    the RPC buffer precisely between the two. That should keep almost all RPC
    buffers within the 2KiB buffer mempool limit.

    And, we can finally be rid of RPC_SLACK_SPACE!

    Signed-off-by: Chuck Lever
    Signed-off-by: Trond Myklebust

    Chuck Lever
     
  • NLM version 4 requests estimate the call and reply header sizes rather
    conservatively, using the very maximum size allowed in the protocol even
    though Linux always uses only a small fraction of the allowable space.

    Reduce the size of caller and lock arguments to conserve RPC buffer space
    while XDR encoding NLM4 arguments. Add compile-time checks to ensure the
    hostname string won't overflow NLM protocol maximums.

    Signed-off-by: Chuck Lever
    Signed-off-by: Trond Myklebust

    Chuck Lever
     
  • Signed-off-by: Trond Myklebust

    Trond Myklebust
     
  • It has no business touching wbc->pages_skipped.

    Signed-off-by: Trond Myklebust

    Trond Myklebust
     
  • Signed-off-by: Trond Myklebust

    Trond Myklebust
     
  • Currently we do write coalescing in a very inefficient manner: one pass in
    generic_writepages() in order to lock the pages for writing, then one pass
    in nfs_flush_mapping() and/or nfs_sync_mapping_wait() in order to gather
    the locked pages for coalescing into RPC requests of size "wsize".

    In fact, it turns out there is actually a deadlock possible here since we
    only start I/O on the second pass. If the user signals the process while
    we're in nfs_sync_mapping_wait(), for instance, then we may exit before
    starting I/O on all the requests that have been queued up.

    Signed-off-by: Trond Myklebust

    Trond Myklebust
     
  • Do the coalescing of read requests into block sized requests at start of
    I/O as we scan through the pages instead of going through a second pass.

    Signed-off-by: Trond Myklebust

    Trond Myklebust
     
  • Signed-off-by: Trond Myklebust

    Trond Myklebust
     
  • Signed-off-by: Trond Myklebust

    Trond Myklebust
     
  • It is redundant, and will interfere with the call to
    balance_dirty_pages_ratelimited_nr in generic_file_write().

    Signed-off-by: Trond Myklebust

    Trond Myklebust
     
  • The nfs statfs function returns a success code on error, and fills the
    output buffer with invalid values. The attached patch makes it return a
    correct error code instead.

    Signed-off-by: Amnon Aaronsohn
    Cc: Trond Myklebust
    Signed-off-by: Andrew Morton
    Signed-off-by: Trond Myklebust
    (Modified patch to reinstate the dprintk())

    Amnon Aaronsohn
     
  • Be more careful about testing page->mapping.

    Signed-off-by: Trond Myklebust

    Trond Myklebust
     
  • The Marvell IDE interface on my machine would hit a BUG_ON() in
    lib/iomem.c because it was calling ata_pci_init_one() specifying just a
    single port on the host, but that would actually end up trying to
    initialize two ports, the second one with bogus information.

    This fixes "ata_pci_init_one()" so that it actually passes down the
    n_ports variable that it got from the low-level driver to the host
    allocation routine ("ata_host_alloc_pinfo()"), which results in the ATA
    layer actually having the correct port number information.

    And in order to make it all work, I also needed to fix a few places that
    had incorrectly hard-coded the fact that a host always had exactly two
    ports (both ata_pci_init_bmdma() and ata_request_legacy_irqs() would
    just always iterate over both ports).

    Acked-by: Jeff Garzik
    Signed-off-by: Linus Torvalds

    Linus Torvalds
     
  • For backwards compatibility, call_platform_enable_wakeup() can return 0
    instead of -EIO since we aren't guaranteed to have errno defined.

    Cc: David Brownell
    Signed-off-by: David Rientjes
    Cc: "Randy.Dunlap"
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    David Rientjes
     
  • Add a kvasprintf() function to complement kasprintf().

    No in-tree users yet, but I have some coming up.

    [akpm@linux-foundation.org: EXPORT it]
    Signed-off-by: Jeremy Fitzhardinge
    Cc: Andrew Morton
    Cc: Keir Fraser
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Jeremy Fitzhardinge
     
  • This patch changes the docs and behaviour from "all states valid" to "no
    states valid" if no .valid callback is assigned. Users of pm_ops that only
    need mem sleep can assign pm_valid_only_mem without any overhead, others
    will require more elaborate callbacks.

    Now that all users of pm_ops have a .valid callback this is a safe thing to
    do and prevents things from getting messy again as they were before.

    Signed-off-by: Johannes Berg
    Acked-by: Pavel Machek
    Looks-okay-to: Rafael J. Wysocki
    Cc:
    Cc: Greg KH
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Johannes Berg
     
  • Almost all users of pm_ops only support mem sleep, don't check in .valid and
    don't reject any others in .prepare so users can be confused if they check
    /sys/power/state, especially when new states are added (these would then
    result in s-t-r although they're supposed to be something different).

    This patch implements a generic pm_valid_only_mem function that is then
    exported for users and puts it to use in almost all existing pm_ops.

    Signed-off-by: Johannes Berg
    Cc: David Brownell
    Acked-by: Pavel Machek
    Cc: linux-pm@lists.linux-foundation.org
    Cc: Len Brown
    Acked-by: Russell King
    Cc: Greg KH
    Cc: "Rafael J. Wysocki"
    Cc: Paul Mundt
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Johannes Berg
     
  • This patch removes the firmware disk suspend mode which is the wrong approach,
    it is supposed to be used for implementing firmware-based disk suspend but
    cannot actually be used for that.

    Signed-off-by: Johannes Berg
    Acked-by: Pavel Machek
    Cc:
    Cc: David Brownell
    Cc: Len Brown
    Acked-by: Russell King
    Cc: Greg KH
    Cc: "Rafael J. Wysocki"
    Cc: Paul Mundt
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Johannes Berg
     
  • This patch series cleans up some misconceptions about pm_ops. Some users of
    the pm_ops structure attempt to use it to stop the user from entering suspend
    to disk, this, however, is not possible since the user can always use
    "shutdown" in /sys/power/disk and then the pm_ops are never invoked. Also,
    platforms that don't support suspend to disk simply should not allow
    configuring SOFTWARE_SUSPEND (read the help text on it, it only selects
    suspend to disk and nothing else, all the other stuff depends on PM).

    The pm_ops structure is actually intended to provide a way to enter
    platform-defined sleep states (currently supported states are "standby" and
    "mem" (suspend to ram)) and additionally (if SOFTWARE_SUSPEND is configured)
    allows a platform to support a platform specific way to enter low-power mode
    once everything has been saved to disk. This is currently only used by ACPI
    (S4).

    This patch:

    The pm_ops.pm_disk_mode is used in totally bogus ways since nobody really
    seems to understand what it actually does.

    This patch clarifies the pm_disk_mode description.

    It also removes all the arm and sh users that think they can veto suspend to
    disk via pm_ops; not so since the user can always do echo shutdown >
    /sys/power/disk, they need to find a better way involving Kconfig or such.

    ACPI is the only user left with a non-zero pm_disk_mode.

    The patch also sets the default mode to shutdown again, but when a new pm_ops
    is registered its pm_disk_mode is selected as default, that way the default
    stays for ACPI where it is apparently required.

    Signed-off-by: Johannes Berg
    Cc: David Brownell
    Acked-by: Pavel Machek
    Cc:
    Cc: Len Brown
    Acked-by: Russell King
    Cc: Greg KH
    Cc: "Rafael J. Wysocki"
    Acked-by: Paul Mundt
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Johannes Berg
     
  • We're getting lockdep warnings due to a post-2.6.21-rc7 bugfix.

    The xattr_sem can never be taken in the manner described. Internal inodes
    are protected by I_PRIVATE. Add the appropriate annotation.

    Cc:
    Cc: "Antonino A. Daplas"
    Cc: Takashi Iwai
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Jeff Mahoney
     
  • Today's print_symbol function dumps a kernel symbol with printk. This
    patch extends the functionality of kallsyms.c so that the symbol lookup
    function may be used without the printk. This is useful for modules that
    want to dump symbols elsewhere, for example, to debugfs. I intend to use
    the new function call in the GFS2 file system (which will be a separate
    patch).

    [akpm@linux-foundation.org: build fix]
    [clameter@sgi.com: sprint_symbol should return length of string like sprintf]
    Signed-off-by: Robert Peterson
    Cc: Rusty Russell
    Cc: Roman Zippel
    Cc: "Randy.Dunlap"
    Cc: Sam Ravnborg
    Acked-by: Paulo Marques
    Signed-off-by: Christoph Lameter
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Robert Peterson
     
  • When allocating local ports, do not allow a bind to a port
    with a specific local address when a bind to that port with
    a wildcard local address already exists.

    Noticed by Linus.

    Signed-off-by: David S. Miller

    David S. Miller
     
  • I accidently applied an earlier version of Eric Dumazet's patch, from
    March 21st. His version from March 30th didn't have these bugs, so
    this just interdiffs to the correct patch.

    Signed-off-by: David S. Miller

    David S. Miller
     

30 Apr, 2007

11 commits

  • * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/ieee1394/linux1394-2.6: (56 commits)
    ieee1394: remove garbage from Kconfig
    ieee1394: more help in Kconfig
    ieee1394: ohci1394: Fix mistake in printk message.
    ieee1394: ohci1394: remove unnecessary rcvPhyPkt bit flipping in LinkControl register
    ieee1394: ohci1394: fix cosmetic problem in error logging
    ieee1394: eth1394: send async streams at S100 on 1394b buses
    ieee1394: eth1394: fix error path in module_init
    ieee1394: eth1394: correct return codes in hard_start_xmit
    ieee1394: eth1394: hard_start_xmit is called in atomic context
    ieee1394: eth1394: some conditions are unlikely
    ieee1394: eth1394: clean up fragment_overlap
    ieee1394: eth1394: don't use alloc_etherdev
    ieee1394: eth1394: omit useless set_mac_address callback
    ieee1394: eth1394: CONFIG_INET is always defined
    ieee1394: eth1394: allow MTU bigger than 1500
    ieee1394: unexport highlevel_host_reset
    ieee1394: eth1394: contain host reset
    ieee1394: eth1394: shorter error messages
    ieee1394: eth1394: correct a memset argument
    ieee1394: eth1394: refactor .probe and .update
    ...

    Linus Torvalds
     
  • * 'for-linus' of master.kernel.org:/pub/scm/linux/kernel/git/jikos/hid: (21 commits)
    USB HID: don't warn on idVendor == 0
    USB HID: add 'quirks' module parameter
    USB HID: add support for dynamically-created quirks
    USB HID: clarify static quirk handling as squirks
    USB HID: encapsulate quirk handling into hid-quirks.c
    USB HID: EMS USBII device needs HID_QUIRK_MULTI_INPUT
    HID: update copyright and authorship macro
    HID: introduce proper zeroing of unused bits in output reports
    USB HID: add support for WiseGroup MP-8800 Quad Joypad
    USB HID: add FF support for Logitech Force 3D Pro Joystick
    USB HID: numlock quirk for dell W7658 keyboard
    USB HID: Logitech MX3000 keyboard needs report descriptor quirk
    USB HID: extend quirk for Logitech S510 keyboard
    USB HID: usbkbd/usbmouse - handle errors when registering devices
    USB HID: add QUIRK_HIDDEV for Belkin Flip KVM
    HID: enable dead keys on a belkin wireless keyboard
    USB HID: Thustmaster firestorm dual power v1 support
    USB HID: specify explicit size for hid_blacklist.quirks
    USB HID: fix retry & reset logic
    USB HID: consolidate vendor/product ids
    ...

    Linus Torvalds
     
  • * master.kernel.org:/pub/scm/linux/kernel/git/davem/net-2.6: (21 commits)
    [IPV4] SNMP: Support OutMcastPkts and OutBcastPkts
    [IPV4] SNMP: Support InMcastPkts and InBcastPkts
    [IPV4] SNMP: Support InTruncatedPkts
    [IPV4] SNMP: Support InNoRoutes
    [SNMP]: Add definitions for {In,Out}BcastPkts
    [TCP] FRTO: RFC4138 allows Nagle override when new data must be sent
    [TCP] FRTO: Delay skb available check until it's mandatory
    [XFRM]: Restrict upper layer information by bundle.
    [TCP]: Catch skb with S+L bugs earlier
    [PATCH] INET : IPV4 UDP lookups converted to a 2 pass algo
    [L2TP]: Add the ability to autoload a pppox protocol module.
    [SKB]: Introduce skb_queue_walk_safe()
    [AF_IUCV/IUCV]: smp_call_function deadlock
    [IPV6]: Fix slab corruption running ip6sic
    [TCP]: Update references in two old comments
    [XFRM]: Export SPD info
    [IPV6]: Track device renames in snmp6.
    [SCTP]: Fix sctp_getsockopt_local_addrs_old() to use local storage.
    [NET]: Remove NETIF_F_INTERNAL_STATS, default to internal stats.
    [NETPOLL]: Remove CONFIG_NETPOLL_RX
    ...

    Linus Torvalds
     
  • * 'for-linus' of git://git.kernel.dk/data/git/linux-2.6-block:
    [PATCH] elevator: elv_list_lock does not need irq disabling
    [BLOCK] Don't pin lots of memory in mempools
    cfq-iosched: speedup cic rb lookup
    ll_rw_blk: add io_context private pointer
    cfq-iosched: get rid of cfqq hash
    cfq-iosched: tighten queue request overlap condition
    cfq-iosched: improve sync vs async workloads
    cfq-iosched: never allow an async queue idling
    cfq-iosched: get rid of ->dispatch_slice
    cfq-iosched: don't pass unused preemption variable around
    cfq-iosched: get rid of ->cur_rr and ->cfq_list
    cfq-iosched: slice offset should take ioprio into account
    [PATCH] cfq-iosched: style cleanups and comments
    cfq-iosched: sort IDLE queues into the rbtree
    cfq-iosched: sort RT queues into the rbtree
    [PATCH] cfq-iosched: speed up rbtree handling
    cfq-iosched: rework the whole round-robin list concept
    cfq-iosched: minor updates
    cfq-iosched: development update
    cfq-iosched: improve preemption for cooperating tasks

    Linus Torvalds
     
  • * 'for-2.6.22' of git://git.kernel.org/pub/scm/linux/kernel/git/paulus/powerpc: (255 commits)
    [POWERPC] Remove dev_dbg redefinition in drivers/ps3/vuart.c
    [POWERPC] remove kernel module option for booke wdt
    [POWERPC] Avoid putting cpu node twice
    [POWERPC] Spinlock initializer cleanup
    [POWERPC] ppc4xx_sgdma needs dma-mapping.h
    [POWERPC] arch/powerpc/sysdev/timer.c build fix
    [POWERPC] get_property cleanups
    [POWERPC] Remove the unused HTDMSOUND driver
    [POWERPC] cell: cbe_cpufreq cleanup and crash fix
    [POWERPC] Declare enable_kernel_spe in a header
    [POWERPC] Add dt_xlate_addr() to bootwrapper
    [POWERPC] bootwrapper: CONFIG_ -> CONFIG_DEVICE_TREE
    [POWERPC] Don't define a custom bd_t for Xilixn Virtex based boards.
    [POWERPC] Add sane defaults for Xilinx EDK generated xparameters files
    [POWERPC] Add uartlite boot console driver for the zImage wrapper
    [POWERPC] Stop using ppc_sys for Xilinx Virtex boards
    [POWERPC] New registration for common Xilinx Virtex ppc405 platform devices
    [POWERPC] Merge common virtex header files
    [POWERPC] Rework Kconfig dependancies for Xilinx Virtex ppc405 platform
    [POWERPC] Clean up cpufreq Kconfig dependencies
    ...

    Linus Torvalds
     
  • A transmitted IP multicast datagram should be counted as OutMcastPkts.
    By the same token, a transmitted IP broadcast datagram should be
    counted as OutBcastPkts.

    Signed-off-by: Mitsuru Chinen
    Signed-off-by: David S. Miller

    Mitsuru Chinen
     
  • A received IP multicast datagram should be counted as InMcastPkts.
    By the same token, a received IP broadcast datagram should be
    counted as InBcastPkts.

    Signed-off-by: Mitsuru Chinen
    Signed-off-by: David S. Miller

    Mitsuru Chinen
     
  • An IP datagram which is being discarded because the datagram frame
    didn't carry enough data should be counted as InTruncatedPkts.

    Signed-off-by: Mitsuru Chinen
    Signed-off-by: David S. Miller

    Mitsuru Chinen
     
  • An IP datagram which is being discarded because of no routes in the
    forwarding path should be counted as InNoRoutes.

    Signed-off-by: Mitsuru Chinen
    Signed-off-by: David S. Miller

    Mitsuru Chinen
     
  • The updated IP-MIB RFC (RFC4293) specifys new objects, InBcastPkts
    and OutBcastPkts. This adds definitions for them.

    Signed-off-by: Mitsuru Chinen
    Signed-off-by: David S. Miller

    Mitsuru Chinen
     
  • This is a corner case where less than MSS sized new data thingie
    is awaiting in the send queue. For F-RTO to work correctly, a
    new data segment must be sent at certain point or F-RTO cannot
    be used at all. RFC4138 allows overriding of Nagle at that
    point.

    Implementation uses frto_counter states 2 and 3 to distinguish
    when Nagle override is needed.

    Signed-off-by: Ilpo Järvinen
    Signed-off-by: David S. Miller

    Ilpo Järvinen