06 Dec, 2011

1 commit

  • On x86_32 casting the unsigned int result of get_random_int() to
    long may result in a negative value. On x86_32 the range of
    mmap_rnd() therefore was -255 to 255. The 32bit mode on x86_64
    used 0 to 255 as intended.

    The bug was introduced by 675a081 ("x86: unify mmap_{32|64}.c")
    in January 2008.

    Signed-off-by: Ludwig Nussel
    Cc: Linus Torvalds
    Cc: harvey.harrison@gmail.com
    Cc: "H. Peter Anvin"
    Cc: Harvey Harrison
    Signed-off-by: Andrew Morton
    Link: http://lkml.kernel.org/r/201111152246.pAFMklOB028527@wpaz5.hot.corp.google.com
    Signed-off-by: Ingo Molnar

    Ludwig Nussel
     

11 Nov, 2011

7 commits

  • Now that zone_sizes_init() is identical on 32-bit and 64-bit,
    move the code to arch/x86/mm/init.c and use it for both
    architectures.

    Acked-by: Tejun Heo
    Acked-by: Yinghai Lu
    Signed-off-by: Pekka Enberg
    Link: http://lkml.kernel.org/r/1320155902-10424-7-git-send-email-penberg@kernel.org
    Signed-off-by: Ingo Molnar

    Pekka Enberg
     
  • Make 32-bit and 64-bit zone_sizes_init() identical in
    preparation for unification.

    Acked-by: Tejun Heo
    Acked-by: Yinghai Lu
    Signed-off-by: Pekka Enberg
    Link: http://lkml.kernel.org/r/1320155902-10424-6-git-send-email-penberg@kernel.org
    Signed-off-by: Ingo Molnar

    Pekka Enberg
     
  • 64-bit has no highmem so max_low_pfn is always the same as
    'max_pfn'.

    Acked-by: Tejun Heo
    Acked-by: Yinghai Lu
    Acked-by: David Rientjes
    Signed-off-by: Pekka Enberg
    Link: http://lkml.kernel.org/r/1320155902-10424-5-git-send-email-penberg@kernel.org
    Signed-off-by: Ingo Molnar

    Pekka Enberg
     
  • In preparation for unifying 32-bit and 64-bit zone_sizes_init()
    make sure ZONE_DMA32 is wrapped in CONFIG_ZONE_DMA32.

    Acked-by: Tejun Heo
    Acked-by: Yinghai Lu
    Acked-by: David Rientjes
    Acked-by: Arun Sharma
    Signed-off-by: Pekka Enberg
    Link: http://lkml.kernel.org/r/1320155902-10424-4-git-send-email-penberg@kernel.org
    Signed-off-by: Ingo Molnar

    Pekka Enberg
     
  • The 'highend_pfn' variable is always set to 'max_pfn' so just
    use the latter directly.

    Acked-by: Tejun Heo
    Acked-by: Yinghai Lu
    Signed-off-by: Pekka Enberg
    Link: http://lkml.kernel.org/r/1320155902-10424-3-git-send-email-penberg@kernel.org
    Signed-off-by: Ingo Molnar

    Pekka Enberg
     
  • This patch introduces a zone_sizes_init() helper function on
    64-bit to make it more similar to 32-bit init.

    Acked-by: Tejun Heo
    Acked-by: Yinghai Lu
    Acked-by: David Rientjes
    Signed-off-by: Pekka Enberg
    Link: http://lkml.kernel.org/r/1320155902-10424-2-git-send-email-penberg@kernel.org
    Signed-off-by: Ingo Molnar

    Pekka Enberg
     
  • Use MAX_DMA_PFN which represents the 16 MB ISA DMA limit on
    32-bit x86 just like we do on 64-bit.

    Acked-by: Tejun Heo
    Acked-by: Yinghai Lu
    Acked-by: David Rientjes
    Signed-off-by: Pekka Enberg
    Link: http://lkml.kernel.org/r/1320155902-10424-1-git-send-email-penberg@kernel.org
    Signed-off-by: Ingo Molnar

    Pekka Enberg
     

10 Nov, 2011

1 commit

  • This reverts commit aa6afca5bcaba8101f3ea09d5c3e4100b2b9f0e5.

    It escalates of some of the google-chrome SELinux problems with ptrace
    ("Check failed: pid_ > 0. Did not find zygote process"), and Andrew
    says that it is also causing mystery lockdep reports.

    Reported-by: Alex Villacís Lasso
    Requested-by: James Morris
    Requested-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Linus Torvalds
     

09 Nov, 2011

12 commits

  • * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/paulg/linux:
    drivers/media: video/a5k6aa is a module and so needs module.h
    mfd: fix build failures in recently added ab5500 code
    hwspinlock/u8500: include linux/module.h
    MTD: MAPS: bcm963xx-flash.c: explicitly include module.h

    Linus Torvalds
     
  • * 'for-linus' of git://neil.brown.name/md:
    md/raid5: STRIPE_ACTIVE has lock semantics, add barriers
    md/raid5: abort any pending parity operations when array fails.

    Linus Torvalds
     
  • * 'docs-move' of git://git.kernel.org/pub/scm/linux/kernel/git/rdunlap/linux-docs: (45 commits)
    DocBook/drm: Clean up a todo-note
    DocBook/drm: `device aware' -> `device-aware'
    DocBook/drm: `(device|driver) specific' -> `(device|driver)-specific'
    DocBook/drm: Clean up the paragraph on framebuffer objects
    DocBook/drm: Use `; otherwise,'
    DocBook/drm: Better flow with `, and then'
    DocBook/drm: Refer to the domain-setting function as a device-specific ioctl
    DocBook/drm: Improve flow of GPU/CPU coherence sentence
    DocBook/drm: Use an for fundamental GEM operations
    DocBook/drm: Insert a comma
    DocBook/drm: Use a for vblank ioctls
    DocBook/drm: Use an itemizedlist for what an encoder needs to provide
    DocBook/drm: Insert `the' for readability, and change `set' to `setting'
    DocBook/drm: Remove extraneous commas
    DocBook/drm: Use a colon
    DocBook/drm: Clarify `final initialization' via better formatting
    DocBook/drm: Remove redundancy
    DocBook/drm: Insert `it' for smooth reading
    DocBook/drm: The word `so-called'; I do not think it connotes what you think it connotes
    DocBook/drm: Use a singular subject for grammatical cleanliness
    ...

    Linus Torvalds
     
  • * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/rostedt/linux-ktest: (21 commits)
    ktest: Evaluate variables entered on the command line
    ktest: Add variable ${PWD}
    ktest: Add another monitor flush before installing kernel
    ktest: Do not opencode reboot in grub setting
    ktest: Add processing of complex conditionals
    ktest: Fix parsing of config section lines
    ktest: Sort make_min_config configs by dependecies
    ktest: Add DEFINED keyword for IF statements
    ktest: Add OVERRIDE keyword to DEFAULTS section
    ktest: Consolidate TEST_TYPE and DEFAULT code
    ktest: Add INCLUDE keyword to include other config files
    ktest: Let IF keyword take comparisons
    ktest: Add IF and ELSE to config sections
    ktest: Do not reboot on config or build issues
    ktest: Add option REBOOT_SUCCESS_LINE to stop waiting after a reboot
    ktest: Add NO_INSTALL option to not install for a test
    ktest: Fail when grub menu not found
    ktest: Include monitor in reboot code
    ktest: Only need to save .config when doing mrproper
    ktest: Create outputdir if it does not exist
    ...

    Linus Torvalds
     
  • * 'pm-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm:
    PM / OPP: Use ERR_CAST instead of ERR_PTR(PTR_ERR())
    PM / devfreq: fix private_data
    Documentation: Fix typo in freezer-subsystem.txt
    PM / QoS: Set cpu_dma_pm_qos->name

    Linus Torvalds
     
  • Use ERR_CAST inlined function instead of ERR_PTR(PTR_ERR(...))

    [The semantic patch that makes this change is available
    in scripts/coccinelle/api/err_cast.cocci.

    More information about semantic patching is available at
    http://coccinelle.lip6.fr/]

    Signed-off-by: Thomas Meyer
    Signed-off-by: Rafael J. Wysocki

    Thomas Meyer
     
  • * 'fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/ohad/hwspinlock:
    hwspinlock/u8500: fix build error due to undefined label
    hwspinlock: Don't return a value in __hwspin_unlock

    Linus Torvalds
     
  • * git://git.kernel.org/pub/scm/linux/kernel/git/davem/sparc:
    sparc: Hook up process_vm_{readv,writev} syscalls.

    Linus Torvalds
     
  • The Kconfig loop detection goes crazy without this.

    Signed-off-by: Linus Torvalds

    Linus Torvalds
     
  • Otherwise we get compile errors like this:

    ERROR: "led_classdev_unregister" [drivers/platform/x86/dell-laptop.ko] undefined!
    ERROR: "led_classdev_register" [drivers/platform/x86/dell-laptop.ko] undefined!
    make[1]: *** [__modpost] Error 1
    make: *** [modules] Error 2

    when the dell-laptop support is enabled without the necessary LED
    support being enabled.

    Reported-by: Alessandro Suardi
    Acked-by: Matthew Garrett
    Signed-off-by: Linus Torvalds

    Linus Torvalds
     
  • This file uses core functions like module_init() and module_exit()
    and so it explicitly needs to include the module.h header.

    Signed-off-by: Paul Gortmaker

    Paul Gortmaker
     
  • Alek Du reported that the code erroneously applies time to jiffies
    conversions twice to the t1 and t2 values. In normal use on a modem link
    this cases no visible problem but on a slower link it will break as with
    HZ=1000 as is typical we are running t1/t2 ten times too fast.

    Alek's original patch removed the conversion from the timer setting but we
    in fact have to be more careful as the contents of t1/t2 are visible via
    the device API and we thus need to correct the constants.

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

    Alan Cox
     

08 Nov, 2011

19 commits

  • Fix below build error:

    CC drivers/hwspinlock/u8500_hsem.o
    drivers/hwspinlock/u8500_hsem.c: In function 'u8500_hsem_probe':
    drivers/hwspinlock/u8500_hsem.c:113: error: label 'free_state' used but not defined

    Signed-off-by: Axel Lin
    Signed-off-by: Ohad Ben-Cohen

    Axel Lin
     
  • Fix below build warning:

    CC arch/arm/mach-omap2/hwspinlock.o
    In file included from arch/arm/mach-omap2/hwspinlock.c:22:
    include/linux/hwspinlock.h: In function '__hwspin_unlock':
    include/linux/hwspinlock.h:121: warning: 'return' with a value, in function returning void

    Signed-off-by: Axel Lin
    Signed-off-by: Ohad Ben-Cohen

    Axel Lin
     
  • All updates that occur under STRIPE_ACTIVE should be globally visible
    when STRIPE_ACTIVE clears. test_and_set_bit() implies a barrier, but
    clear_bit() does not.

    This is suitable for 3.1-stable.

    Signed-off-by: Dan Williams
    Signed-off-by: NeilBrown
    Cc: stable@kernel.org

    Dan Williams
     
  • When the number of failed devices exceeds the allowed number
    we must abort any active parity operations (checks or updates) as they
    are no longer meaningful, and can lead to a BUG_ON in
    handle_parity_checks6.

    This bug was introduce by commit 6c0069c0ae9659e3a91b68eaed06a5c6c37f45c8
    in 2.6.29.

    Reported-by: Manish Katiyar
    Tested-by: Manish Katiyar
    Acked-by: Dan Williams
    Signed-off-by: NeilBrown
    Cc: stable@kernel.org

    NeilBrown
     
  • These files had implicit dependencies on modular support
    which now show up as build failures with the module cleanup
    work merged to mainline.

    Reported-by: Axel Lin
    Signed-off-by: Paul Gortmaker

    Paul Gortmaker
     
  • Include module.h to fix below build error:

    CC drivers/hwspinlock/u8500_hsem.o
    drivers/hwspinlock/u8500_hsem.c:177: error: 'THIS_MODULE' undeclared here (not in a function)
    [...]
    drivers/hwspinlock/u8500_hsem.c:196: warning: type defaults to 'int' in declaration of 'MODULE_AUTHOR'
    drivers/hwspinlock/u8500_hsem.c:196: warning: function declaration isn't a prototype
    make[2]: *** [drivers/hwspinlock/u8500_hsem.o] Error 1
    make[1]: *** [drivers/hwspinlock] Error 2
    make: *** [drivers] Error 2

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

    Axel Lin
     
  • module.h was previously implicitly included through mtd/mtd.h.

    Fixes the following build failure after the module.h cleanup:

    CC drivers/mtd/maps/bcm963xx-flash.o
    drivers/mtd/maps/bcm963xx-flash.c: In function 'bcm963xx_probe':
    drivers/mtd/maps/bcm963xx-flash.c:208:29: error: 'THIS_MODULE' undeclared (first use in this function)
    [...]
    drivers/mtd/maps/bcm963xx-flash.c:276:1: warning: type defaults to 'int' in declaration of 'MODULE_AUTHOR'
    drivers/mtd/maps/bcm963xx-flash.c:276:15: warning: function declaration isn't a prototype
    make[7]: *** [drivers/mtd/maps/bcm963xx-flash.o] Error 1

    Signed-off-by: Jonas Gorski
    Signed-off-by: Paul Gortmaker

    Jonas Gorski
     
  • .. with new name. Because nothing says "really solid kernel release"
    like naming it after an extinct animal that just happened to be in the
    news lately.

    Linus Torvalds
     
  • * 'fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/tmlind/linux-omap: (31 commits)
    ARM: OMAP: Fix export.h or module.h includes
    ARM: OMAP: omap_device: Include linux/export.h
    ARM: OMAP2: Fix H4 matrix keyboard warning
    ARM: OMAP1: Remove unused omap-alsa.h
    ARM: OMAP1: Fix warnings about enabling 32 KiHz timer
    ARM: OMAP2+: timer: Remove omap_device_pm_latency
    ARM: OMAP2+: clock data: Remove redundant timer clkdev
    ARM: OMAP: Devkit8000: Remove double omap_mux_init_gpio
    ARM: OMAP: usb: musb: OMAP: Delete unused function
    MAINTAINERS: Update linux-omap git repository
    ARM: OMAP: change get_context_loss_count ret value to int
    ARM: OMAP4: hsmmc: configure SDMMC1_DR0 properly
    ARM: OMAP4: hsmmc: Fix Pbias configuration on regulator OFF
    ARM: OMAP3: hwmod: fix variant registration and remove SmartReflex from common list
    ARM: OMAP: I2C: Fix omap_register_i2c_bus() return value on success
    ARM: OMAP: dmtimer: Include linux/module.h
    ARM: OMAP2+: l3-noc: Include linux/module.h
    ARM: OMAP2+: devices: Fixes for McPDM
    ARM: OMAP: Fix errors and warnings when building for one board
    ARM: OMAP3: PM: restrict erratum i443 handling to OMAP3430 only
    ...

    Linus Torvalds
     
  • Mountpoint crossing is similar to following procfs symlinks - we do
    not get ->d_revalidate() called for dentry we have arrived at, with
    unpleasant consequences for NFS4.

    Simple way to reproduce the problem in mainline:

    cat >/tmp/a.c <
    #include
    #include
    main()
    {
    struct flock fl = {.l_type = F_RDLCK, .l_whence = SEEK_SET, .l_len = 1};
    if (fcntl(0, F_SETLK, &fl))
    perror("setlk");
    }
    EOF
    cc /tmp/a.c -o /tmp/test

    then on nfs4:

    mount --bind file1 file2
    /tmp/test < file1 # ok
    /tmp/test < file2 # spews "setlk: No locks available"...

    What happens is the missing call of ->d_revalidate() after mountpoint
    crossing and that's where NFS4 would issue OPEN request to server.

    The fix is simple - treat mountpoint crossing the same way we deal with
    following procfs-style symlinks. I.e. set LOOKUP_JUMPED...

    Cc: stable@kernel.org
    Signed-off-by: Al Viro
    Signed-off-by: Linus Torvalds

    Al Viro
     
  • The "private_date" field in struct devfreq_dev_status almost certainly
    wants to be "private_data"; since there are no in-tree users of this
    functionality, now seems like an easy time to make the fix.

    Signed-off-by: Jonathan Corbet
    Signed-off-by: Rafael J. Wysocki

    Jonathan Corbet
     
  • Fix a typo in Documentation/cgroups/freezer-subsystem.txt.

    Signed-off-by: Rafael J. Wysocki
    Reviewed-by: Srivatsa S. Bhat
    Acked-by: Randy Dunlap

    Rafael J. Wysocki
     
  • Since commit 4a31a334, the name of this misc device is not initialized,
    which leads to a funny device named /dev/(null) being created and
    /proc/misc containing an entry with just a number but no name. The latter
    leads to complaints by cryptsetup, which caused me to investigate this
    matter.

    Signed-off-by: Dominik Brodowski
    Signed-off-by: Rafael J. Wysocki

    Dominik Brodowski
     
  • * 'perf-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip:
    perf top: Fix live annotation in the --stdio interface
    perf top tui: Don't recalc column widths considering just the first page
    perf report: Add progress bar when processing time ordered events
    perf hists browser: Warn about lost events
    perf tools: Fix a typo of command name as trace-cmd
    perf hists: Fix recalculation of total_period when sorting entries
    perf header: Fix build on old systems
    perf ui browser: Handle K_RESIZE in dialog windows
    perf ui browser: No need to switch char sets that often
    perf hists browser: Use K_TIMER
    perf ui: Rename ui__warning_paranoid to ui__error_paranoid
    perf ui: Reimplement the popup windows using libslang
    perf ui: Reimplement ui__popup_menu using ui__browser
    perf ui: Reimplement ui_helpline using libslang
    perf ui: Improve handling sigwinch a bit
    perf ui progress: Reimplement using slang
    perf evlist: Fix grouping of multiple events

    Linus Torvalds
     
  • Tony Lindgren
     
  • Commit 32aaeffbd4a7457bf2f7448b33b5946ff2a960eb (Merge branch
    'modsplit-Oct31_2011'...) caused some build errors. Fix these
    and make sure we always have export.h or module.h included
    for MODULE_ and EXPORT_SYMBOL users:

    $ grep -rl ^MODULE_ arch/arm/*omap*/*.c | xargs \
    grep -L linux/module.h
    arch/arm/mach-omap2/dsp.c
    arch/arm/mach-omap2/mailbox.c
    arch/arm/mach-omap2/omap-iommu.c
    arch/arm/mach-omap2/smartreflex.c

    Also check we either have export.h or module.h included
    for the files exporting symbols:

    $ grep -rl EXPORT_SYMBOL arch/arm/*omap*/*.c | xargs \
    grep -L linux/export.h | xargs grep -L linux/module.h

    Cc: Russell King
    Signed-off-by: Tony Lindgren

    Tony Lindgren
     
  • Include linux/export.h to fix below build warning:

    CC arch/arm/plat-omap/omap_device.o
    arch/arm/plat-omap/omap_device.c:1055: warning: data definition has no type or storage class
    arch/arm/plat-omap/omap_device.c:1055: warning: type defaults to 'int' in declaration of 'EXPORT_SYMBOL'
    arch/arm/plat-omap/omap_device.c:1055: warning: parameter names (without types) in function declaration

    Signed-off-by: Axel Lin
    Signed-off-by: Tony Lindgren

    Axel Lin
     
  • * git://git.kernel.org/pub/scm/linux/kernel/git/davem/net: (47 commits)
    forcedeth: fix a few sparse warnings (variable shadowing)
    forcedeth: Improve stats counters
    forcedeth: remove unneeded stats updates
    forcedeth: Acknowledge only interrupts that are being processed
    forcedeth: fix race when unloading module
    MAINTAINERS/rds: update maintainer
    wanrouter: Remove kernel_lock annotations
    usbnet: fix oops in usbnet_start_xmit
    ixgbe: Fix compile for kernel without CONFIG_PCI_IOV defined
    etherh: Add MAINTAINERS entry for etherh
    bonding: comparing a u8 with -1 is always false
    sky2: fix regression on Yukon Optima
    netlink: clarify attribute length check documentation
    netlink: validate NLA_MSECS length
    i825xx:xscale:8390:freescale: Fix Kconfig dependancies
    macvlan: receive multicast with local address
    tg3: Update version to 3.121
    tg3: Eliminate timer race with reset_task
    tg3: Schedule at most one tg3_reset_task run
    tg3: Obtain PCI function number from device
    ...

    Linus Torvalds
     
  • Signed-off-by: Al Viro
    Signed-off-by: Linus Torvalds

    Al Viro