31 Oct, 2007

16 commits

  • Fix links to files in Documentation/* in various Kconfig files

    Signed-off-by: Dirk Hohndel
    Signed-off-by: Linus Torvalds

    Dirk Hohndel
     
  • Commit commit 65b8291c4000e5f38fc94fb2ca0cb7e8683c8a1b ("dio: invalidate
    clean pages before dio write") introduced a bug which stopped dio from
    ever invalidating the page cache after writes. It still invalidated it
    before writes so most users were fine.

    Karl Schendel reported ( http://lkml.org/lkml/2007/10/26/481 ) hitting
    this bug when he had a buffered reader immediately reading file data
    after an O_DIRECT wirter had written the data. The kernel issued
    read-ahead beyond the position of the reader which overlapped with the
    O_DIRECT writer. The failure to invalidate after writes caused the
    reader to see stale data from the read-ahead.

    The following patch is originally from Karl. The following commentary
    is his:

    The below 3rd try takes on your suggestion of just invalidating
    no matter what the retval from the direct_IO call. I ran it
    thru the test-case several times and it has worked every time.
    The post-invalidate is probably still too early for async-directio,
    but I don't have a testcase for that; just sync. And, this
    won't be any worse in the async case.

    I added a test to the aio-dio-regress repository which mimics Karl's IO
    pattern. It verifed the bad behaviour and that the patch fixed it. I
    agree with Karl, this still doesn't help the case where a buffered
    reader follows an AIO O_DIRECT writer. That will require a bit more
    work.

    This gives up on the idea of returning EIO to indicate to userspace that
    stale data remains if the invalidation failed.

    Signed-off-by: Zach Brown
    Cc: Karl Schendel
    Cc: Benjamin LaHaise
    Cc: Andrew Morton
    Cc: Nick Piggin
    Cc: Leonid Ananiev
    Cc: Chris Mason
    Signed-off-by: Linus Torvalds

    Zach Brown
     
  • * 'release' of git://git.kernel.org/pub/scm/linux/kernel/git/aegl/linux-2.6:
    [IA64] Fix incorrect return value from ia64_setup_msi_irq()
    [IA64] arch/ia64/sn/kernel/mca.c: undo lock when sn_oemdata can't be extended
    [IA64] update sn2 defconfig to 64kb pages
    [IA64] fix typo in per_cpu_offset
    [IA64] /proc/cpuinfo "physical id" field cleanups
    [IA64] vDSO vs --build-id
    [IA64] check-segrel.lds vs --build-id
    [IA64] vmcore_find_descriptor_size should be in __init
    [IA64] ia64/mm/init.c: fix section mismatches

    Linus Torvalds
     
  • * 'upstream-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jgarzik/netdev-2.6:
    ixgb: fix TX hangs under heavy load
    e1000e: Fix typo ! &
    ixgbe: minor sparse fixes
    e1000: sparse warnings fixes
    ixgb: fix sparse warnings
    e1000e: fix sparse warnings
    mv643xx_eth: Fix MV643XX_ETH offsets used by Pegasos 2
    Blackfin EMAC driver: Fix Ethernet communication bug (dupliated and lost packets)
    DM9601: Support for ADMtek ADM8515 NIC

    Linus Torvalds
     
  • * 'upstream-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jgarzik/libata-dev:
    libata: implement and use ATA_QCFLAG_QUIET
    libata: stop being overjealous about non-IO commands
    libata: flush is an IO command
    sata_promise: cleanups
    sata_promise: ASIC PRD table bug workaround, take 2

    Linus Torvalds
     
  • A merge error occurred where we merged the wrong block here
    in version 1.0.120. The right condition for frags is slightly
    different then for the skb, so account for the difference properly
    and trim the TSO based size right.

    Originally part of a fix reported by IBM to fix TSO hangs on
    pSeries hardware.

    Signed-off-by: Jesse Brandeburg
    Signed-off-by: Auke Kok
    Cc: Andy Gospodarek
    Signed-off-by: Jeff Garzik

    Auke Kok
     
  • Signed-off-by: Roel Kluin
    Signed-off-by: Auke Kok
    Signed-off-by: Jeff Garzik

    Roel Kluin
     
  • Make strings const if possible, and fix includes so forward definitions
    are seen.

    Signed-off-by: Stephen Hemminger
    Signed-off-by: Auke Kok
    Signed-off-by: Jeff Garzik

    Stephen Hemminger
     
  • Fix sparse warnings and problems from e1000 driver.

    Added a sparse fix for the module param array index
    -- Auke

    Signed-off-by: Stephen Hemminger
    Signed-off-by: Auke Kok
    Signed-off-by: Jeff Garzik

    Stephen Hemminger
     
  • Fix sparse warnings in ixgb driver for net-2.6.24.

    Added a sparse fix for invalid declaration using non-constant value
    in ixgb_set_multi. Added a fix for the module param array index
    and allows int params in the array. --Auke

    Signed-off-by: Stephen Hemminger
    Signed-off-by: Auke Kok
    Signed-off-by: Jeff Garzik

    Stephen Hemminger
     
  • Fix sparse warnings from e1000e driver in net-2.6.24.

    Added a sparse fix for module param arrays which can have int values
    but only the array index needs to be unsigned. --Auke

    Signed-off-by: Stephen Hemminger
    Signed-off-by: Auke Kok
    Signed-off-by: Jeff Garzik

    Stephen Hemminger
     
  • In the mv643xx_eth driver, we now use offsets from the ethernet
    register block within the chip, but the pegasos 2 platform still
    needs offsets from the full chip's register base address.

    Signed-off-by: Dale Farnsworth
    Signed-off-by: Jeff Garzik

    Dale Farnsworth
     
  • Fix Ethernet communication bug(dupliated and lost packets)
    in RMII PHY mode- dont call mac_disable and mac_enable during
    10/100 REFCLK changes - mac_enable screws up the DMA descriptor chain

    Signed-off-by: Michael Hennerich
    Signed-off-by: Bryan Wu
    Signed-off-by: Jeff Garzik

    Michael Hennerich
     
  • Add device ID for the ADMtek ADM8515 USB NIC to the DM9601 driver.

    Signed-off-by: Peter Korsgaard
    Signed-off-by: Jeff Garzik

    Peter Korsgaard
     
  • Fix the problem that pci_enable_msi() fails on ia64 platform. The cause of
    this problem is incorrect return value of ia64_setup_msi_irq(). It must
    return 0 on success, instead of irq number.

    Signed-off-by: Kenji Kaneshige
    Signed-off-by: Tony Luck

    Kenji Kaneshige
     
  • It's currently possible to send posix_locks_deadlock() into an infinite
    loop (under the BKL).

    For now, fix this just by bailing out after a few iterations. We may
    want to fix this in a way that better clarifies the semantics of
    deadlock detection. But that will take more time, and this minimal fix
    is probably adequate for any realistic scenario, and is simple enough to
    be appropriate for applying to stable kernels now.

    Thanks to George Davis for reporting the problem.

    Cc: "George G. Davis"
    Signed-off-by: J. Bruce Fields
    Acked-by: Alan Cox
    Signed-off-by: Linus Torvalds

    J. Bruce Fields
     

30 Oct, 2007

24 commits

  • * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/cooloney/blackfin-2.6:
    Blackfin arch: use a less common define name in BF549
    Blackfin arch: Add missing definitions for BF561
    Blackfin arch: reclaim a few bytes from the end of our init section
    Blackfin arch: fix libata data struct member from irq_type to irq_flags
    Blackfin arch: Do not pollute name space used in linux-2.6.x/sound
    Blackfin arch: Fix bug set correct baud for spi mmc and enable SPI after DMA.
    Blackfin arch: update board defconfig files according to latest information from ADI datasheet
    Blackfin arch: ensure that speculative loads of bad pointers don't cause us to do bad things.
    Blackfin arch: Add missing definitions of BF54x
    Blackfin arch: Fix random crash issue found by Michael.
    Blackfin arch: fix bug: tell users if the kernel is recovering from a fault condition
    Blackfin arch: add support for checking/clearing overruns in generic purpose Timer API
    Blackfin arch: cleanup arch/blackfin/kernel/traps.c handling code.
    Blackfin arch: Apply Bluetchnix vendor patch provided by Harald Krapfenbauer
    Blackfin arch: fix bug BlueTechnix CM-BF537 board config uses wrong IRQ for net2272 driver
    Blackfin arch: fix bug: kernel prints out error message twice
    Blackfin arch: add NFC driver support in BF527-EZKIT board
    Blackfin arch: Added support for HV Sistemas H8606 board

    Linus Torvalds
     
  • * git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-2.6:
    [TIPC]: Add tipc_config.h to include/linux/Kbuild.
    [WAN]: lmc_ioctl: don't return with locks held
    [SUNRPC]: fix rpc debugging
    [TCP]: Saner thash_entries default with much memory.
    [SUNRPC] rpc_rdma: we need to cast u64 to unsigned long long for printing
    [IPv4] SNMP: Refer correct memory location to display ICMP out-going statistics
    [NET]: Fix error reporting in sys_socketpair().
    [NETFILTER]: nf_ct_alloc_hashtable(): use __GFP_NOWARN
    [NET]: Fix race between poll_napi() and net_rx_action()
    [TCP] MD5: Remove some more unnecessary casting.
    [TCP] vegas: Fix a bug in disabling slow start by gamma parameter.
    [IPVS]: use proper timeout instead of fixed value
    [IPV6] NDISC: Fix setting base_reachable_time_ms variable.

    Linus Torvalds
     
  • Signed-off-by: Krzysztof Helt
    Acked-by: Ben Dooks
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Krzysztof Helt
     
  • Since commit 97d97224ff361e08777fb33e0fd193ca877dac28 ("[SERIAL] Fix
    console initialisation ordering"), serial_core calls ->pm() on
    initialization even if the port was used for console.

    This behaviour breaks serial_txx9 console since The serial_txx9 driver
    initialize its port entirely on its ->pm() method if new state was 0.
    This patch adds checking for oldstate value to fix this probelm.

    Signed-off-by: Atsushi Nemoto
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Atsushi Nemoto
     
  • Fix possible array overflow:

    drivers/pci/intel-iommu.c: In function ¡dmar_get_fault_reason¢:
    drivers/pci/intel-iommu.c:753: warning: array subscript is above array bounds
    drivers/pci/intel-iommu.c: In function ¡iommu_page_fault¢:
    drivers/pci/intel-iommu.c:753: warning: array subscript is above array bounds

    Signed-off-by: Takashi Iwai
    Cc: Mark Gross
    Acked-by: "Keshavamurthy, Anil S"
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Takashi Iwai
     
  • Evgeniy said:

    I wonder on what type of UFS do you test this patch? NetBSD and FreeBSD
    do not use "fs_state", they use "fs_clean" flag, only Solaris does check
    like this: fs_state + fs_time == FSOK.

    That's why parentheses was like that.

    At now with linux-2.6.24-rc1-git1, I get: fs need fsck, but NetBSD's fsck
    says that's all ok.

    I suggest revert this patch.

    Cc: Evgeniy Dushistov
    Cc: Satyam Sharma
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Andrew Morton
     
  • It's possible to provoke unionfs (not yet in mainline, though in mm and
    some distros) to hit shmem_writepage's BUG_ON(page_mapped(page)). I expect
    it's possible to provoke the 2.6.23 ecryptfs in the same way (but the
    2.6.24 ecryptfs no longer calls lower level's ->writepage).

    This came to light with the recent find that AOP_WRITEPAGE_ACTIVATE could
    leak from tmpfs via write_cache_pages and unionfs to userspace. There's
    already a fix (e423003028183df54f039dfda8b58c49e78c89d7 - writeback: don't
    propagate AOP_WRITEPAGE_ACTIVATE) in the tree for that, and it's okay so
    far as it goes; but insufficient because it doesn't address the underlying
    issue, that shmem_writepage expects to be called only by vmscan (relying on
    backing_dev_info capabilities to prevent the normal writeback path from
    ever approaching it).

    That's an increasingly fragile assumption, and ramdisk_writepage (the other
    source of AOP_WRITEPAGE_ACTIVATEs) is already careful to check
    wbc->for_reclaim before returning it. Make the same check in
    shmem_writepage, thereby sidestepping the page_mapped BUG also.

    Signed-off-by: Hugh Dickins
    Cc: Erez Zadok
    Cc:
    Reviewed-by: Pekka Enberg
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Hugh Dickins
     
  • mm/sparse-vmemmap.c uses init_mm in some places. However, it is not
    present in any of the headers currently included in the file.

    init_mm is defined as extern in sched.h, so we add it to the headers list

    Up to now, this problem was masked by the fact that functions like
    set_pte_at() and pmd_populate_kernel() are usually macros that expand to
    simpler variants that does not use the first parameter at all.

    Signed-off-by: Glauber de Oliveira Costa
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Glauber de Oliveira Costa
     
  • No reason I can think of of making them default y Most people don't have
    the hardware and with default y they just pollute lots of configs during
    make oldconfig.

    Signed-off-by: Andi Kleen
    Acked-by: Jeff Garzik
    Acked-by: "Nelson, Shannon"
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Andi Kleen
     
  • Commit baa3a2a0d24ebcf1c451bec8e5bee3d3467f4cbb ("sysctl: remove broken
    sunrpc debug binary sysctls"), by removing initialization of the
    ctl_name field, broke this conditional, preventing the display of
    rpc_tasks that you previously got when turning on rpc debugging.

    [akpm@linux-foundation.org: coding-style fixes]
    Signed-off-by: J. Bruce Fields
    Acked-by: "Eric W. Biederman"
    Cc: "David S. Miller"
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    J. Bruce Fields
     
  • Remove warning from powerpc ppc64_defconfig builds:

    drivers/video/aty/radeon_pm.c:30: warning: 'radeon_reinitialize_M10' declared 'static' but never defined

    It's used only under CONFIG_PM, and only with CONFIG_X86 before it is
    defined, so the forward declaration can be moved under the ifdef.

    Signed-off-by: Olof Johansson
    Cc: Benjamin Herrenschmidt
    Cc: "Antonino A. Daplas"
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Olof Johansson
     
  • Fix FB_OMAP dependencies so that the OMAP FB driver options are presented
    correctly.

    Signed-off-by: Randy Dunlap
    Cc: "Antonino A. Daplas"
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Randy Dunlap
     
  • Coverity spotted some incorrect code in a recent change to the IPMI driver;
    this patch make sure the data is really long enough to pull the
    manufacturer id and product id out of a get device id message.

    Signed-off-by: Corey Minyard
    Cc: Adrian Bunk
    Cc: Stian Jordet
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Corey Minyard
     
  • Do not allow processes to clear their TIF_SIGPENDING if TIF_FREEZE is set,
    so that they will not race with the freezer (like mysqld does, for example).

    Signed-off-by: Rafael J. Wysocki
    Acked-by: Nigel Cunningham
    Acked-by: Pavel Machek
    Cc: Oleg Nesterov
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Rafael J. Wysocki
     
  • Implement ATA_QCFLAG_QUIET which indicates that there's no need to
    report if the command fails with AC_ERR_DEV and set it for passthrough
    commands.

    Combined with previous changes, this now makes device errors for all
    direct commands reported directly to the issuer without going through
    EH actions and reporting.

    Note that EH is still invoked after non-IO device errors to determine
    the nature of the error and resume command execution (some controller
    requires special care after error to continue). It just performs
    default maintenance after error, examines what's going on, realizes
    that it's none of its business and reports the command failure without
    logging any error messages.

    Signed-off-by: Tejun Heo
    Signed-off-by: Jeff Garzik

    Tejun Heo
     
  • libata EH always revalidated device and retried failed command after
    error except for ATAPI CCs. This is unnecessary and hinders with
    users issuing direct commands. This patch makes the following
    changes.

    * Make sata_sil24 not request ATA_EH_REVALIDATE on device errors.
    sil24 is the only driver which does this. All others let libata EH
    core code decide.

    * Don't request revalidation after device error of non-IO command.
    Revalidation doesn't really help anybody. As ATA_EH_REVALIDATE
    isn't set by default, there's no reason to clear it after sense data
    is read. Kill ATA_EH_REVALIDATE clearing code while at it.

    * Don't retry non-IO command after device error. Device has rejected
    the command. There's no point in retrying.

    Signed-off-by: Tejun Heo
    Signed-off-by: Jeff Garzik

    Tejun Heo
     
  • ATA_QCFLAG_IO is used to mark commands which are used to perform
    regluar IO transfers via block layer. These commands are assumed to
    be valid and taken more seriously during error handling. Cache flush
    is used by regular IO path and necessary for data integrity. Mark it
    with ATA_QCFLAG_IO.

    Signed-off-by: Tejun Heo
    Signed-off-by: Jeff Garzik

    Tejun Heo
     
  • Minor sata_promise cleanups:
    - use C99 array initialisers in pdc_port_info[]
    - add myself in the file head's Maintained by note,
    since users don't always read the MAINTAINERS file
    - SG/PRD bug workaround warrants driver version bump

    Signed-off-by: Mikael Pettersson
    --
    drivers/ata/sata_promise.c | 17 +++++++++--------
    1 files changed, 9 insertions(+), 8 deletions(-)
    Signed-off-by: Jeff Garzik

    Mikael Pettersson
     
  • Second-generation Promise SATA controllers have an ASIC bug
    which can trigger if the last PRD entry is larger than 164 bytes,
    resulting in intermittent errors and possible data corruption.

    Work around this by replacing calls to ata_qc_prep() with a
    private version that fills the PRD, checks the size of the
    last entry, and if necessary splits it to avoid the bug.
    Also reduce sg_tablesize by 1 to accommodate the new entry.

    Tested on the second-generation SATA300 TX4 and SATA300 TX2plus,
    and the first-generation PDC20378.

    Thanks to Alexander Sabourenkov for verifying the bug by
    studying the vendor driver, and for writing the initial patch
    upon which this one is based.

    Signed-off-by: Mikael Pettersson
    --
    Changes since previous version:
    * use new PDC_MAX_PRD constant to initialise sg_tablesize

    drivers/ata/sata_promise.c | 87 ++++++++++++++++++++++++++++++++++++++++++---
    1 files changed, 83 insertions(+), 4 deletions(-)
    Signed-off-by: Jeff Garzik

    Mikael Pettersson
     
  • Needed, as reported in:

    http://bugzilla.kernel.org/show_bug.cgi?id=9260

    Signed-off-by: David S. Miller

    David S. Miller
     
  • (akpm: it's doing copy_to_user() inside spin_lock_irqsave(): this driver
    appears to be beyond help).

    Signed-off-by: Roel Kluin
    Signed-off-by: Andrew Morton
    Signed-off-by: David S. Miller

    Roel Kluin
     
  • Commit baa3a2a0d24ebcf1c451bec8e5bee3d3467f4cbb, by removing initialization
    of the ctl_name field, broke this conditional, preventing the display of
    rpc_tasks that you previously got when turning on rpc debugging.

    [akpm@linux-foundation.org: coding-style fixes]

    Signed-off-by: J. Bruce Fields
    Acked-by: "Eric W. Biederman"
    Signed-off-by: Andrew Morton
    Signed-off-by: David S. Miller

    J. Bruce Fields
     
  • On systems with a very large amount of memory, the heuristics in
    alloc_large_system_hash() result in a very large TCP established hash
    table: 16 millions of entries for a 128 GB ia64 system. This makes
    reading from /proc/net/tcp pretty slow (well over a second) and as a
    result netstat is slow on these machines. I know that /proc/net/tcp is
    deprecated in favor of tcp_diag, however at the moment netstat only
    knows of the former.

    I am skeptical that such a large TCP established hash is often needed.
    Just because a system has a lot of memory doesn't imply that it will
    have several millions of concurrent TCP connections. Thus I believe
    that we should put an arbitrary high limit to the size of the TCP
    established hash by default. Users who really need a bigger hash can
    always use the thash_entries boot parameter to get more.

    I propose 2 millions of entries as the arbitrary high limit. This
    makes /proc/net/tcp reasonably fast on the system in question (0.2 s)
    while being still large enough for me to be confident that network
    performance won't suffer.

    This is just one way to limit the hash size, there are others; I am not
    familiar enough with the TCP code to decide which is best. Thus, I
    would welcome the proposals of alternatives.

    [ 2 million is still too large, thus I've modified the limit in the
    change to be '512 * 1024'. -DaveM ]

    Signed-off-by: Jean Delvare
    Signed-off-by: David S. Miller

    Jean Delvare
     
  • as some architectures have unsigned long for u64.

    net/sunrpc/xprtrdma/rpc_rdma.c: In function 'rpcrdma_create_chunks':
    net/sunrpc/xprtrdma/rpc_rdma.c:222: warning: format '%llx' expects type 'long long unsigned int', but argument 4 has type 'u64'
    net/sunrpc/xprtrdma/rpc_rdma.c:234: warning: format '%llx' expects type 'long long unsigned int', but argument 5 has type 'u64'
    net/sunrpc/xprtrdma/rpc_rdma.c: In function 'rpcrdma_count_chunks':
    net/sunrpc/xprtrdma/rpc_rdma.c:577: warning: format '%llx' expects type 'long long unsigned int', but argument 4 has type 'u64

    Noticed on PowerPC pseries_defconfig build.

    Signed-off-by: Stephen Rothwell
    Signed-off-by: David S. Miller

    Stephen Rothwell