26 Oct, 2010

2 commits

  • Clones an existing reference to inode; caller must already hold one.

    Signed-off-by: Al Viro

    Al Viro
     
  • Andrew,

    Could you please review this patch, you probably are the right guy to
    take it, because it crosses fs and net trees.

    Note : /proc/sys/fs/file-nr is a read-only file, so this patch doesnt
    depend on previous patch (sysctl: fix min/max handling in
    __do_proc_doulongvec_minmax())

    Thanks !

    [PATCH V4] fs: allow for more than 2^31 files

    Robin Holt tried to boot a 16TB system and found af_unix was overflowing
    a 32bit value :

    We were seeing a failure which prevented boot. The kernel was incapable
    of creating either a named pipe or unix domain socket. This comes down
    to a common kernel function called unix_create1() which does:

    atomic_inc(&unix_nr_socks);
    if (atomic_read(&unix_nr_socks) > 2 * get_max_files())
    goto out;

    The function get_max_files() is a simple return of files_stat.max_files.
    files_stat.max_files is a signed integer and is computed in
    fs/file_table.c's files_init().

    n = (mempages * (PAGE_SIZE / 1024)) / 10;
    files_stat.max_files = n;

    In our case, mempages (total_ram_pages) is approx 3,758,096,384
    (0xe0000000). That leaves max_files at approximately 1,503,238,553.
    This causes 2 * get_max_files() to integer overflow.

    Fix is to let /proc/sys/fs/file-nr & /proc/sys/fs/file-max use long
    integers, and change af_unix to use an atomic_long_t instead of
    atomic_t.

    get_max_files() is changed to return an unsigned long.
    get_nr_files() is changed to return a long.

    unix_nr_socks is changed from atomic_t to atomic_long_t, while not
    strictly needed to address Robin problem.

    Before patch (on a 64bit kernel) :
    # echo 2147483648 >/proc/sys/fs/file-max
    # cat /proc/sys/fs/file-max
    -18446744071562067968

    After patch:
    # echo 2147483648 >/proc/sys/fs/file-max
    # cat /proc/sys/fs/file-max
    2147483648
    # cat /proc/sys/fs/file-nr
    704 0 2147483648

    Reported-by: Robin Holt
    Signed-off-by: Eric Dumazet
    Acked-by: David Miller
    Reviewed-by: Robin Holt
    Tested-by: Robin Holt
    Signed-off-by: Al Viro

    Eric Dumazet
     

25 Oct, 2010

2 commits

  • Read external interrupts parameters from the lowcore in the first
    level interrupt handler in entry[64].S.

    Signed-off-by: Martin Schwidefsky

    Martin Schwidefsky
     
  • * 'for-next' of git://git.kernel.org/pub/scm/linux/kernel/git/jikos/trivial: (39 commits)
    Update broken web addresses in arch directory.
    Update broken web addresses in the kernel.
    Revert "drivers/usb: Remove unnecessary return's from void functions" for musb gadget
    Revert "Fix typo: configuation => configuration" partially
    ida: document IDA_BITMAP_LONGS calculation
    ext2: fix a typo on comment in ext2/inode.c
    drivers/scsi: Remove unnecessary casts of private_data
    drivers/s390: Remove unnecessary casts of private_data
    net/sunrpc/rpc_pipe.c: Remove unnecessary casts of private_data
    drivers/infiniband: Remove unnecessary casts of private_data
    drivers/gpu/drm: Remove unnecessary casts of private_data
    kernel/pm_qos_params.c: Remove unnecessary casts of private_data
    fs/ecryptfs: Remove unnecessary casts of private_data
    fs/seq_file.c: Remove unnecessary casts of private_data
    arm: uengine.c: remove C99 comments
    arm: scoop.c: remove C99 comments
    Fix typo configue => configure in comments
    Fix typo: configuation => configuration
    Fix typo interrest[ing|ed] => interest[ing|ed]
    Fix various typos of valid in comments
    ...

    Fix up trivial conflicts in:
    drivers/char/ipmi/ipmi_si_intf.c
    drivers/usb/gadget/rndis.c
    net/irda/irnet/irnet_ppp.c

    Linus Torvalds
     

24 Oct, 2010

1 commit

  • * git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-next-2.6: (1699 commits)
    bnx2/bnx2x: Unsupported Ethtool operations should return -EINVAL.
    vlan: Calling vlan_hwaccel_do_receive() is always valid.
    tproxy: use the interface primary IP address as a default value for --on-ip
    tproxy: added IPv6 support to the socket match
    cxgb3: function namespace cleanup
    tproxy: added IPv6 support to the TPROXY target
    tproxy: added IPv6 socket lookup function to nf_tproxy_core
    be2net: Changes to use only priority codes allowed by f/w
    tproxy: allow non-local binds of IPv6 sockets if IP_TRANSPARENT is enabled
    tproxy: added tproxy sockopt interface in the IPV6 layer
    tproxy: added udp6_lib_lookup function
    tproxy: added const specifiers to udp lookup functions
    tproxy: split off ipv6 defragmentation to a separate module
    l2tp: small cleanup
    nf_nat: restrict ICMP translation for embedded header
    can: mcp251x: fix generation of error frames
    can: mcp251x: fix endless loop in interrupt handler if CANINTF_MERRF is set
    can-raw: add msg_flags to distinguish local traffic
    9p: client code cleanup
    rds: make local functions/variables static
    ...

    Fix up conflicts in net/core/dev.c, drivers/net/pcmcia/smc91c92_cs.c and
    drivers/net/wireless/ath/ath9k/debug.c as per David

    Linus Torvalds
     

23 Oct, 2010

4 commits

  • * git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/tty-2.6: (49 commits)
    serial8250: ratelimit "too much work" error
    serial: bfin_sport_uart: speed up sport RX sample rate to be 3% faster
    serial: abstraction for 8250 legacy ports
    serial/imx: check that the buffer is non-empty before sending it out
    serial: mfd: add more baud rates support
    jsm: Remove the uart port on errors
    Alchemy: Add UART PM methods.
    8250: allow platforms to override PM hook.
    altera_uart: Don't use plain integer as NULL pointer
    altera_uart: Fix missing prototype for registering an early console
    altera_uart: Fixup type usage of port flags
    altera_uart: Make it possible to use Altera UART and 8250 ports together
    altera_uart: Add support for different address strides
    altera_uart: Add support for getting mapbase and IRQ from resources
    altera_uart: Add support for polling mode (IRQ-less)
    serial: Factor out uart_poll_timeout() from 8250 driver
    serial: mark the 8250 driver as maintained
    serial: 8250: Don't delay after transmitter is ready.
    tty: MAINTAINERS: add drivers/serial/jsm/ as maintained driver
    vcs: invoke the vt update callback when /dev/vcs* is written to
    ...

    Linus Torvalds
     
  • * 'llseek' of git://git.kernel.org/pub/scm/linux/kernel/git/arnd/bkl:
    vfs: make no_llseek the default
    vfs: don't use BKL in default_llseek
    llseek: automatically add .llseek fop
    libfs: use generic_file_llseek for simple_attr
    mac80211: disallow seeks in minstrel debug code
    lirc: make chardev nonseekable
    viotape: use noop_llseek
    raw: use explicit llseek file operations
    ibmasmfs: use generic_file_llseek
    spufs: use llseek in all file operations
    arm/omap: use generic_file_llseek in iommu_debug
    lkdtm: use generic_file_llseek in debugfs
    net/wireless: use generic_file_llseek in debugfs
    drm: use noop_llseek

    Linus Torvalds
     
  • * 'config' of git://git.kernel.org/pub/scm/linux/kernel/git/arnd/bkl:
    BKL: introduce CONFIG_BKL.
    dabusb: remove the BKL
    sunrpc: remove the big kernel lock
    init/main.c: remove BKL notations
    blktrace: remove the big kernel lock
    rtmutex-tester: make it build without BKL
    dvb-core: kill the big kernel lock
    dvb/bt8xx: kill the big kernel lock
    tlclk: remove big kernel lock
    fix rawctl compat ioctls breakage on amd64 and itanic
    uml: kill big kernel lock
    parisc: remove big kernel lock
    cris: autoconvert trivial BKL users
    alpha: kill big kernel lock
    isapnp: BKL removal
    s390/block: kill the big kernel lock
    hpet: kill BKL, add compat_ioctl

    Linus Torvalds
     
  • Again basically cut and paste

    Convert the main driver set to use the hooks for GICOUNT

    Signed-off-by: Alan Cox
    Signed-off-by: Greg Kroah-Hartman

    Alan Cox
     

22 Oct, 2010

5 commits

  • …/git/tip/linux-2.6-tip

    * 'sched-core-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip: (29 commits)
    sched: Export account_system_vtime()
    sched: Call tick_check_idle before __irq_enter
    sched: Remove irq time from available CPU power
    sched: Do not account irq time to current task
    x86: Add IRQ_TIME_ACCOUNTING
    sched: Add IRQ_TIME_ACCOUNTING, finer accounting of irq time
    sched: Add a PF flag for ksoftirqd identification
    sched: Consolidate account_system_vtime extern declaration
    sched: Fix softirq time accounting
    sched: Drop group_capacity to 1 only if local group has extra capacity
    sched: Force balancing on newidle balance if local group has capacity
    sched: Set group_imb only a task can be pulled from the busiest cpu
    sched: Do not consider SCHED_IDLE tasks to be cache hot
    sched: Drop all load weight manipulation for RT tasks
    sched: Create special class for stop/migrate work
    sched: Unindent labels
    sched: Comment updates: fix default latency and granularity numbers
    tracing/sched: Add sched_pi_setprio tracepoint
    sched: Give CPU bound RT tasks preference
    sched: Try not to migrate higher priority RT tasks
    ...

    Linus Torvalds
     
  • …git/tip/linux-2.6-tip

    * 'perf-core-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip: (163 commits)
    tracing: Fix compile issue for trace_sched_wakeup.c
    [S390] hardirq: remove pointless header file includes
    [IA64] Move local_softirq_pending() definition
    perf, powerpc: Fix power_pmu_event_init to not use event->ctx
    ftrace: Remove recursion between recordmcount and scripts/mod/empty
    jump_label: Add COND_STMT(), reducer wrappery
    perf: Optimize sw events
    perf: Use jump_labels to optimize the scheduler hooks
    jump_label: Add atomic_t interface
    jump_label: Use more consistent naming
    perf, hw_breakpoint: Fix crash in hw_breakpoint creation
    perf: Find task before event alloc
    perf: Fix task refcount bugs
    perf: Fix group moving
    irq_work: Add generic hardirq context callbacks
    perf_events: Fix transaction recovery in group_sched_in()
    perf_events: Fix bogus AMD64 generic TLB events
    perf_events: Fix bogus context time tracking
    tracing: Remove parent recording in latency tracer graph options
    tracing: Use one prologue for the preempt irqs off tracer function tracers
    ...

    Linus Torvalds
     
  • * 'core-rcu-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip: (52 commits)
    sched: fix RCU lockdep splat from task_group()
    rcu: using ACCESS_ONCE() to observe the jiffies_stall/rnp->qsmask value
    sched: suppress RCU lockdep splat in task_fork_fair
    net: suppress RCU lockdep false positive in sock_update_classid
    rcu: move check from rcu_dereference_bh to rcu_read_lock_bh_held
    rcu: Add advice to PROVE_RCU_REPEATEDLY kernel config parameter
    rcu: Add tracing data to support queueing models
    rcu: fix sparse errors in rcutorture.c
    rcu: only one evaluation of arg in rcu_dereference_check() unless sparse
    kernel: Remove undead ifdef CONFIG_DEBUG_LOCK_ALLOC
    rcu: fix _oddness handling of verbose stall warnings
    rcu: performance fixes to TINY_PREEMPT_RCU callback checking
    rcu: upgrade stallwarn.txt documentation for CPU-bound RT processes
    vhost: add __rcu annotations
    rcu: add comment stating that list_empty() applies to RCU-protected lists
    rcu: apply TINY_PREEMPT_RCU read-side speedup to TREE_PREEMPT_RCU
    rcu: combine duplicate code, courtesy of CONFIG_PREEMPT_RCU
    rcu: Upgrade srcu_read_lock() docbook about SRCU grace periods
    rcu: document ways of stalling updates in low-memory situations
    rcu: repair code-duplication FIXMEs
    ...

    Linus Torvalds
     
  • …s/security-testing-2.6

    * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jmorris/security-testing-2.6: (26 commits)
    selinux: include vmalloc.h for vmalloc_user
    secmark: fix config problem when CONFIG_NF_CONNTRACK_SECMARK is not set
    selinux: implement mmap on /selinux/policy
    SELinux: allow userspace to read policy back out of the kernel
    SELinux: drop useless (and incorrect) AVTAB_MAX_SIZE
    SELinux: deterministic ordering of range transition rules
    kernel: roundup should only reference arguments once
    kernel: rounddown helper function
    secmark: export secctx, drop secmark in procfs
    conntrack: export lsm context rather than internal secid via netlink
    security: secid_to_secctx returns len when data is NULL
    secmark: make secmark object handling generic
    secmark: do not return early if there was no error
    AppArmor: Ensure the size of the copy is < the buffer allocated to hold it
    TOMOYO: Print URL information before panic().
    security: remove unused parameter from security_task_setscheduler()
    tpm: change 'tpm_suspend_pcr' to be module parameter
    selinux: fix up style problem on /selinux/status
    selinux: change to new flag variable
    selinux: really fix dependency causing parallel compile failure.
    ...

    Linus Torvalds
     
  • * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/sage/ceph-client: (22 commits)
    ceph: do not carry i_lock for readdir from dcache
    fs/ceph/xattr.c: Use kmemdup
    rbd: passing wrong variable to bvec_kunmap_irq()
    rbd: null vs ERR_PTR
    ceph: fix num_pages_free accounting in pagelist
    ceph: add CEPH_MDS_OP_SETDIRLAYOUT and associated ioctl.
    ceph: don't crash when passed bad mount options
    ceph: fix debugfs warnings
    block: rbd: removing unnecessary test
    block: rbd: fixed may leaks
    ceph: switch from BKL to lock_flocks()
    ceph: preallocate flock state without locks held
    ceph: add pagelist_reserve, pagelist_truncate, pagelist_set_cursor
    ceph: use mapping->nrpages to determine if mapping is empty
    ceph: only invalidate on check_caps if we actually have pages
    ceph: do not hide .snap in root directory
    rbd: introduce rados block device (rbd), based on libceph
    ceph: factor out libceph from Ceph file system
    ceph-rbd: osdc support for osd call and rollback operations
    ceph: messenger and osdc changes for rbd
    ...

    Linus Torvalds
     

21 Oct, 2010

26 commits