26 Jan, 2011

6 commits

  • …l/git/lethal/fbdev-2.6

    * 'fbdev-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/lethal/fbdev-2.6:
    mailmap: Add an entry for Axel Lin.
    video: fix some comments in drivers/video/console/vgacon.c
    drivers/video/bf537-lq035.c: Add missing IS_ERR test
    video: pxa168fb: remove a redundant pxa168fb_check_var call
    video: da8xx-fb: fix fb_probe error path
    video: pxa3xx-gcu: Return -EFAULT when copy_from_user() fails
    video: nuc900fb: properly free resources in nuc900fb_remove
    video: nuc900fb: fix compile error

    Linus Torvalds
     
  • * 'sh-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/lethal/sh-2.6:
    sh: Fix build of sh7750 base boards
    sh: update INTC to clear IRQ sense valid flag
    sh: Fix sh build failure when CONFIG_SFC=m
    sh: fix MSIOF0 SPI on ecovec: it conflicts with VOU
    sh: support XZ-compressed kernel.
    sh: Fix up breakage from asm-generic/pgtable.h changes.

    Linus Torvalds
     
  • Fix __key_link_end()'s attempt to fix up the quota if an error occurs.

    There are two erroneous cases: Firstly, we always decrease the quota if
    the preallocated replacement keyring needs cleaning up, irrespective of
    whether or not we should (we may have replaced a pointer rather than
    adding another pointer).

    Secondly, we never clean up the quota if we added a pointer without the
    keyring storage being extended (we allocate multiple pointers at a time,
    even if we're not going to use them all immediately).

    We handle this by setting the bottom bit of the preallocation pointer in
    __key_link_begin() to indicate that the quota needs fixing up, which is
    then passed to __key_link() (which clears the whole thing) and
    __key_link_end().

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

    David Howells
     
  • GPL V2 should be GPL v2

    Signed-off-by: Alan Cox
    Signed-off-by: Linus Torvalds

    Alan Cox
     
  • A B C D E ...

    Signed-off-by: Alan Cox
    Signed-off-by: Linus Torvalds

    Alan Cox
     
  • busy_loop() returns negative error code, thus change err variable
    from u32 to int to properly propagate correct error code.

    Also remove unneeded initialization for err and i variables.

    Signed-off-by: Axel Lin
    Signed-off-by: Alan Cox
    Signed-off-by: Linus Torvalds

    Axel Lin
     

25 Jan, 2011

24 commits

  • Not all of Axel's patches have used a consistent casing, so fix it up
    here.

    Signed-off-by: Paul Mundt

    Paul Mundt
     
  • Now vgacon_scrollback_startup() uses slab, not bootmem,
    the comment above it is obsolete, so does __init_refok.

    Signed-off-by: WANG Cong
    Signed-off-by: Paul Mundt

    Amerigo Wang
     
  • lcd_device_register may return ERR_PTR, so a check is added for this value
    before the dereference. All of the other changes reorganize the error
    handling code in this function to avoid duplicating all of it in the added
    case.

    In the original code, in one case, the global variable fb_buffer was set to
    NULL in error code that appears after this variable is initialized. This
    is done now in all error handling code that has this property.

    The semantic match that finds this problem is as follows:
    (http://coccinelle.lip6.fr/)

    //
    @r@
    identifier f;
    @@
    f(...) { ... return ERR_PTR(...); }

    @@
    identifier r.f, fld;
    expression x;
    statement S1,S2;
    @@
    x = f(...)
    ... when != IS_ERR(x)
    (
    if (IS_ERR(x) ||...) S1 else S2
    |
    *x->fld
    )
    //

    Signed-off-by: Julia Lawall
    Acked-by: Mike Frysinger
    Signed-off-by: Paul Mundt

    Julia Lawall
     
  • Current implementation calls pxa168fb_check_var twice in pxa168fb_probe.

    Signed-off-by: Axel Lin
    Signed-off-by: Paul Mundt

    axel lin
     
  • Current implementation puts CONFIG_CPU_FREQ at wrong place, CONFIG_CPU_FREQ
    is for lcd_da8xx_cpufreq_deregister not for unregister_framebuffer.

    Signed-off-by: Axel Lin
    Signed-off-by: Paul Mundt

    axel lin
     
  • Renamed platform_register_device to platform_device_register.

    Signed-off-by: Nobuhiro Iwamatsu
    Signed-off-by: Paul Mundt

    Nobuhiro Iwamatsu
     
  • * git://git.kernel.org/pub/scm/linux/kernel/git/sfrench/cifs-2.6:
    Make CIFS mount work in a container.
    CIFS: Remove pointless variable assignment in cifs_dfs_do_automount()

    Linus Torvalds
     
  • * 'for-38-rc3' of git://codeaurora.org/quic/kernel/davidb/linux-msm:
    drivers: mmc: msm: remove clock disable in probe
    mmc: msm: fix dma usage not to use internal APIs

    Linus Torvalds
     
  • * 'drm-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/airlied/drm-2.6:
    drm/radeon/kms: add new radeon_info ioctl query for clock crystal freq
    drm/i915: Prevent uninitialised reads during error state capture
    drm/i915: Use consistent mappings for OpRegion between ACPI and i915
    drm/i915: Handle the no-interrupts case for UMS by polling
    drm/i915: Disable high-precision vblank timestamping for UMS
    drm/i915: Increase the amount of defense before computing vblank timestamps
    drm/i915,agp/intel: Do not clear stolen entries
    drm/radeon/kms: simplify atom adjust pll setup
    drm/radeon/kms: match r6xx/r7xx/evergreen asic_reset with previous asics
    drm/radeon/kms: make the mac rv630 quirk generic
    drm/radeon/kms: fix a spelling error in an error message
    drm/radeon/kms: Initialize pageflip spinlocks.
    drm/i915: Recognise non-VGA display devices
    drm/i915: Fix use of invalid array size for ring->sync_seqno
    drm/i915/ringbuffer: Fix use of stale HEAD position whilst polling for space
    drm/i915: Don't kick-off hangcheck after a DRI interrupt
    drm/i915: Add dependency on CONFIG_TMPFS
    drm/i915: Initialise ring vfuncs for old DRI paths
    drm/i915: make the blitter report buffer modifications to the FBC unit
    drm/i915: set more FBC chicken bits

    Linus Torvalds
     
  • …/git/ickle/drm-intel into drm-fixes

    * 'drm-intel-fixes-2' of ssh://master.kernel.org/pub/scm/linux/kernel/git/ickle/drm-intel: (30 commits)
    drm/i915: Prevent uninitialised reads during error state capture
    drm/i915: Use consistent mappings for OpRegion between ACPI and i915
    drm/i915: Handle the no-interrupts case for UMS by polling
    drm/i915: Disable high-precision vblank timestamping for UMS
    drm/i915: Increase the amount of defense before computing vblank timestamps
    drm/i915,agp/intel: Do not clear stolen entries
    Remove MAYBE_BUILD_BUG_ON
    BUILD_BUG_ON: make it handle more cases
    module: fix missing semicolons in MODULE macro usage
    param: add null statement to compiled-in module params
    module: fix linker error for MODULE_VERSION when !MODULE and CONFIG_SYSFS=n
    module: show version information for built-in modules in sysfs
    selinux: return -ENOMEM when memory allocation fails
    tpm: fix panic caused by "tpm: Autodetect itpm devices"
    TPM: Long default timeout fix
    trusted keys: Fix a memory leak in trusted_update().
    keys: add trusted and encrypted maintainers
    encrypted-keys: rename encrypted_defined files to encrypted
    trusted-keys: rename trusted_defined files to trusted
    drm/i915: Recognise non-VGA display devices
    ...

    Dave Airlie
     
  • Needed for timer queries in the 3D driver.

    Signed-off-by: Alex Deucher
    Signed-off-by: Dave Airlie

    Alex Deucher
     
  • Fix a shutdown regression caused by 2a2d31c8dc6f ("intel_idle: open
    broadcast clock event"). The clockevent framework can automatically
    shutdown broadcast timers for hotremove CPUs. And we get a shutdown
    regression when we shutdown broadcast timer for hot remove CPU, so just
    delete some code.

    Also fix some section mismatch.

    Reported-by: Ari Savolainen
    Signed-off-by: Shaohua Li
    Tested-by: Linus Torvalds
    Cc: stable@kernel.org
    Signed-off-by: Linus Torvalds

    Shaohua Li
     
  • …/git/tmlind/linux-omap-2.6

    * 'omap-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tmlind/linux-omap-2.6:
    omap: DMA: clear interrupt status correctly
    OMAP3: Devkit8000: Fix tps65930 pullup/pulldown configuration
    arm: omap3: cm-t3517: minor comment fix
    arm: omap3: cm-t3517: rtc fix
    omap1: Fix sched_clock implementation when both MPU timer and 32K timer are used
    omap1: Fix booting for 15xx and 730 with omap1_defconfig
    omap1: Fix sched_clock for the MPU timer
    OMAP: PRCM: remove duplicated headers
    OMAP4: clockdomain: bypass unimplemented wake-up dependency functions on OMAP4
    OMAP: counter_32k: init clocksource as part of machine timer init

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

    * 'perf-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip:
    perf tools: Fix time function double declaration with glibc
    perf tools: Fix build by checking if extra warnings are supported
    perf tools: Fix build when using gcc 3.4.6
    perf tools: Add missing header, fixes build
    perf tools: Fix 64 bit integer format strings
    perf test: Fix build on older glibcs
    perf: perf_event_exit_task_context: s/rcu_dereference/rcu_dereference_raw/
    perf test: Use cpu_map->[cpu] when setting affinity
    perf symbols: Fix annotation of thumb code
    perf: Annotate cpuctx->ctx.mutex to avoid a lockdep splat
    powerpc, perf: Fix frequency calculation for overflowing counters (FSL version)
    perf: Fix perf_event_init_task()/perf_event_free_task() interaction
    perf: Fix find_get_context() vs perf_event_exit_task() race

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

    * 'timers-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip:
    RTC: Remove Kconfig symbol for UIE emulation
    RTC: Properly handle rtc_read_alarm error propagation and fix bug
    RTC: Propagate error handling via rtc_timer_enqueue properly
    acpi_pm: Clear pmtmr_ioport if acpi_pm initialization fails
    rtc: Cleanup removed UIE emulation declaration
    hrtimers: Notify hrtimer users of switches to NOHZ mode

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

    * 'sched-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip:
    sched: Fix poor interactivity on UP systems due to group scheduler nice tune bug

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

    * 'x86-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip:
    x86: Fix jump label with RO/NX module protection crash
    x86, hotplug: Fix powersavings with offlined cores on AMD
    x86, mcheck, therm_throt.c: Export symbol platform_thermal_notify to allow coretemp to handler intr
    x86: Use asm-generic/cacheflush.h
    x86: Update CPU cache attributes table descriptors

    Linus Torvalds
     
  • error_bo and pinned_bo could be used uninitialised if there were no
    active buffers.

    Caught by kmemcheck.

    Signed-off-by: Chris Wilson

    Chris Wilson
     
  • The opregion is a shared memory region between ACPI and the graphics
    driver. As the ACPI mapping has been changed to cachable in commit
    6d5bbf00d251cc73223a71422d69e069dc2e0b8d, mapping the intel opregion
    non-cachable now fails. As no bus-master hardware is involved in the
    opregion, cachable map should do no harm.

    Tested on a Fujitsu Lifebook P8010.

    Signed-off-by: Michael Karcher
    [ickle: convert to acpi_os_ioremap for consistency]
    Signed-off-by: Chris Wilson

    Michael Karcher
     
  • Merge with Linus to resolve conflicting fixes for the reusing the stale
    HEAD value during intel_ring_wait().

    Conflicts:
    drivers/gpu/drm/i915/intel_ringbuffer.c

    Chris Wilson
     
  • If the driver calls into the kernel to wait for a breadcrumb to pass,
    but hasn't enabled interrupts, fallback to polling the breadcrumb value.

    Reported-by: Chris Clayton
    Tested-by: Chris Clayton
    Signed-off-by: Chris Wilson

    Chris Wilson
     
  • We only have sufficient information for accurate (sub-frame) timestamping
    when the modesetting is under our control.

    Reported-by: Chris Clayton
    Tested-by: Chris Clayton
    Reviewed-by: Mario Kleiner
    Signed-off-by: Chris Wilson

    Chris Wilson
     
  • Reported-by: Chris Clayton
    Tested-by: Chris Clayton
    Signed-off-by: Chris Wilson

    Chris Wilson
     
  • We can only utilize the stolen portion of the GTT if we are in sole
    charge of the hardware. This is only true if using GEM and KMS,
    otherwise VESA continues to access stolen memory.

    Reported-by: Arnd Bergmann
    Reported-by: Frederic Weisbecker
    Tested-by: Jiri Olsa
    Tested-by: Frederic Weisbecker
    Cc: Daniel Vetter
    Signed-off-by: Chris Wilson

    Chris Wilson
     

24 Jan, 2011

10 commits

  • Michael Witten and Christian Kujau reported that the autogroup
    scheduling feature hurts interactivity on their UP systems.

    It turns out that this is an older bug in the group scheduling code,
    and the wider appeal provided by the autogroup feature exposed it
    more prominently.

    When on UP with FAIR_GROUP_SCHED enabled, tune shares
    only affect tg->shares, but is not reflected in
    tg->se->load. The reason is that update_cfs_shares()
    does nothing on UP.

    So introduce update_cfs_shares() for UP && FAIR_GROUP_SCHED.

    This issue was found when enable autogroup scheduling was enabled,
    but it is an older bug that also exists on cgroup.cpu on UP.

    Reported-and-Tested-by: Michael Witten
    Reported-and-Tested-by: Christian Kujau
    Signed-off-by: Yong Zhang
    Acked-by: Pekka Enberg
    Acked-by: Mike Galbraith
    Acked-by: Peter Zijlstra
    Cc: Linus Torvalds
    LKML-Reference:
    Signed-off-by: Ingo Molnar

    Yong Zhang
     
  • * 'BUG_ON' of git://git.kernel.org/pub/scm/linux/kernel/git/rusty/linux-2.6-for-linus:
    Remove MAYBE_BUILD_BUG_ON
    BUILD_BUG_ON: make it handle more cases

    Linus Torvalds
     
  • * git://git.kernel.org/pub/scm/linux/kernel/git/rusty/linux-2.6-for-linus:
    module: fix missing semicolons in MODULE macro usage
    param: add null statement to compiled-in module params
    module: fix linker error for MODULE_VERSION when !MODULE and CONFIG_SYSFS=n
    module: show version information for built-in modules in sysfs

    Linus Torvalds
     
  • …s/security-testing-2.6

    * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jmorris/security-testing-2.6:
    selinux: return -ENOMEM when memory allocation fails
    tpm: fix panic caused by "tpm: Autodetect itpm devices"
    TPM: Long default timeout fix
    trusted keys: Fix a memory leak in trusted_update().
    keys: add trusted and encrypted maintainers
    encrypted-keys: rename encrypted_defined files to encrypted
    trusted-keys: rename trusted_defined files to trusted

    Linus Torvalds
     
  • Teach cifs about network namespaces, so mounting uses adresses/routing
    visible from the container rather than from init context.

    A container is a chroot on steroids that changes more than just the root
    filesystem the new processes see. One thing containers can isolate is
    "network namespaces", meaning each container can have its own set of
    ethernet interfaces, each with its own own IP address and routing to the
    outside world. And if you open a socket in _userspace_ from processes
    within such a container, this works fine.

    But sockets opened from within the kernel still use a single global
    networking context in a lot of places, meaning the new socket's address
    and routing are correct for PID 1 on the host, but are _not_ what
    userspace processes in the container get to use.

    So when you mount a network filesystem from within in a container, the
    mount code in the CIFS driver uses the host's networking context and not
    the container's networking context, so it gets the wrong address, uses
    the wrong routing, and may even try to go out an interface that the
    container can't even access... Bad stuff.

    This patch copies the mount process's network context into the CIFS
    structure that stores the rest of the server information for that mount
    point, and changes the socket open code to use the saved network context
    instead of the global network context. I.E. "when you attempt to use
    these addresses, do so relative to THIS set of network interfaces and
    routing rules, not the old global context from back before we supported
    containers".

    The big long HOWTO sets up a test environment on the assumption you've
    never used ocntainers before. It basically says:

    1) configure and build a new kernel that has container support
    2) build a new root filesystem that includes the userspace container
    control package (LXC)
    3) package/run them under KVM (so you don't have to mess up your host
    system in order to play with containers).
    4) set up some containers under the KVM system
    5) set up contradictory routing in the KVM system and the container so
    that the host and the container see different things for the same address
    6) try to mount a CIFS share from both contexts so you can both force it
    to work and force it to fail.

    For a long drawn out test reproduction sequence, see:

    http://landley.livejournal.com/47024.html
    http://landley.livejournal.com/47205.html
    http://landley.livejournal.com/47476.html

    Signed-off-by: Rob Landley
    Reviewed-by: Jeff Layton
    Signed-off-by: Steve French

    Rob Landley
     
  • Now BUILD_BUG_ON() can handle optimizable constants, we don't need
    MAYBE_BUILD_BUG_ON any more.

    Signed-off-by: Rusty Russell

    Rusty Russell
     
  • BUILD_BUG_ON used to use the optimizer to do code elimination or fail
    at link time; it was changed to first the size of a negative array (a
    nicer compile time error), then (in
    8c87df457cb58fe75b9b893007917cf8095660a0) to a bitfield.

    This forced us to change some non-constant cases to MAYBE_BUILD_BUG_ON();
    as Jan points out in that commit, it didn't work as intended anyway.

    bitfields: needs a literal constant at parse time, and can't be put under
    "if (__builtin_constant_p(x))" for example.
    negative array: can handle anything, but if the compiler can't tell it's
    a constant, silently has no effect.
    link time: breaks link if the compiler can't determine the value, but the
    linker output is not usually as informative as a compiler error.

    If we use the negative-array-size method *and* the link time trick,
    we get the ability to use BUILD_BUG_ON() under __builtin_constant_p()
    branches, and maximal ability for the compiler to detect errors at
    build time.

    We also document it thoroughly.

    Signed-off-by: Rusty Russell
    Cc: Jan Beulich
    Acked-by: Hollis Blanchard

    Rusty Russell
     
  • You always needed them when you were a module, but the builtin versions
    of the macros used to be more lenient.

    Reported-by: Stephen Rothwell
    Signed-off-by: Rusty Russell

    Rusty Russell
     
  • Add an unused struct declaration statement requiring a
    terminating semicolon to the compile-in case to provoke an
    error if __MODULE_INFO() is used without the terminating
    semicolon. Previously MODULE_ALIAS("foo") (no semicolon)
    compiled fine if MODULE was not selected.

    Cc: Dan Carpenter
    Signed-off-by: Linus Walleij
    Signed-off-by: Rusty Russell

    Linus Walleij
     
  • lib/built-in.o:(__modver+0x8): undefined reference to `__modver_version_show'
    lib/built-in.o:(__modver+0x2c): undefined reference to `__modver_version_show'

    Simplest to just not emit anything: if they've disabled SYSFS they probably
    want the smallest kernel possible.

    Reported-by: Randy Dunlap
    Signed-off-by: Rusty Russell

    Rusty Russell