projects/linux·commit b05ee6bf

Merge tag 'staging-3.3-rc3' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/staging

b05ee6bf · Linus Torvalds <[email protected]> · 2012-02-09 13:52:18 -08:00

Staging tree patches for 3.3-rc3

Big things here is the deletion of the Android pmem driver, as it's
obsolete and no one uses it, the gma500 driver as it's already in the
drm portion of the kernel tree, and the pohmelfs filesystem as it's
obsolete and a rewritten version is being proposed for the fs/ section
of the kernel.

Other than that, a smattering of different bugfixes and regressions, and
some omap drm api merge fixups that were needed due to api changes in
the main portion of the drm tree, allowing this code to build properly
again.

Signed-off-by: Greg Kroah-Hartman <[email protected]>

* tag 'staging-3.3-rc3' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/staging: (28 commits)
  staging: pohmelfs: remove drivers/staging/pohmelfs
  staging: android/ram_console: Don't build on arches w/o ioremap
  staging: r8712u: Use asynchronous firmware loading
  staging: usbip: fix to prevent potentially using uninitialized spinlock
  staging: r8712u: Fix problem when CONFIG_R8712_AP is set
  staging: tidspbridge: fix incorrect free to drv_datap
  staging: tidspbridge: fix bridge_open memory leaks
  staging: android: lowmemorykiller: Don't wait more than one second for a process to die
  MAINTAINERS: staging: iio: add iio information
  staging: zcache: fix serialization bug in zv stats
  staging: fix go7007-usb license
  Staging: android: binder: Fix crashes when sharing a binder file between processes
  Staging: android: Remove pmem driver
  Staging: asus_oled: fix NULL-ptr crash on unloading
  Staging: asus_oled: fix image processing
  Staging: android: binder: Don't call dump_stack in binder_vma_open
  staging: r8712u: Add new Sitecom UsB ID
  zcache: Set SWIZ_BITS to 8 to reduce tmem bucket lock contention.
  zcache: fix deadlock condition
  staging: drm/omap: fix locking issue
  ...
Commit
b05ee6bf9e6c7acc38dca1466b63bb24ae5df6f3
Parents
b0286db4 · 67435319

Merge commit. Changes below are compared with the first parent: b0286db4.

Changes

117 files changed · +867 −40542

FileStatusAddDelContent
MAINTAINERSmodified+6−0View file
drivers/staging/Kconfigmodified+0−4View file
drivers/staging/Makefilemodified+0−2View file
drivers/staging/android/Kconfigmodified+1−4View file
drivers/staging/android/Makefilemodified+0−1View file
drivers/staging/android/android_pmem.hdeleted+0−93View before deletion
drivers/staging/android/binder.cmodified+11−2View file
drivers/staging/android/lowmemorykiller.cmodified+4−1View file
drivers/staging/android/pmem.cdeleted+0−1345View before deletion
drivers/staging/asus_oled/asus_oled.cmodified+9−4View file
drivers/staging/gma500/Kconfigdeleted+0−33View before deletion
drivers/staging/gma500/Makefiledeleted+0−52View before deletion
drivers/staging/gma500/TODOdeleted+0−15View before deletion
drivers/staging/gma500/accel_2d.cdeleted+0−414View before deletion
drivers/staging/gma500/backlight.cdeleted+0−49View before deletion
drivers/staging/gma500/cdv_device.cdeleted+0−350View before deletion
drivers/staging/gma500/cdv_device.hdeleted+0−36View before deletion
drivers/staging/gma500/cdv_intel_crt.cdeleted+0−326View before deletion
drivers/staging/gma500/cdv_intel_display.cdeleted+0−1508View before deletion
drivers/staging/gma500/cdv_intel_hdmi.cdeleted+0−376View before deletion
drivers/staging/gma500/cdv_intel_lvds.cdeleted+0−721View before deletion
drivers/staging/gma500/displays/hdmi.hdeleted+0−33View before deletion
drivers/staging/gma500/displays/pyr_cmd.hdeleted+0−34View before deletion
drivers/staging/gma500/displays/pyr_vid.hdeleted+0−34View before deletion
drivers/staging/gma500/displays/tmd_cmd.hdeleted+0−34View before deletion
drivers/staging/gma500/displays/tmd_vid.hdeleted+0−34View before deletion
drivers/staging/gma500/displays/tpo_cmd.hdeleted+0−35View before deletion
drivers/staging/gma500/displays/tpo_vid.hdeleted+0−33View before deletion
drivers/staging/gma500/framebuffer.cdeleted+0−856View before deletion
drivers/staging/gma500/framebuffer.hdeleted+0−48View before deletion
drivers/staging/gma500/gem.cdeleted+0−292View before deletion
drivers/staging/gma500/gem_glue.cdeleted+0−89View before deletion
drivers/staging/gma500/gem_glue.hdeleted+0−2View before deletion
drivers/staging/gma500/gtt.cdeleted+0−553View before deletion
drivers/staging/gma500/gtt.hdeleted+0−64View before deletion
drivers/staging/gma500/intel_bios.cdeleted+0−303View before deletion
drivers/staging/gma500/intel_bios.hdeleted+0−430View before deletion
drivers/staging/gma500/intel_i2c.cdeleted+0−170View before deletion
drivers/staging/gma500/intel_opregion.cdeleted+0−81View before deletion
drivers/staging/gma500/mdfld_device.cdeleted+0−714View before deletion
drivers/staging/gma500/mdfld_dsi_dbi.cdeleted+0−761View before deletion
drivers/staging/gma500/mdfld_dsi_dbi.hdeleted+0−173View before deletion
drivers/staging/gma500/mdfld_dsi_dbi_dpu.cdeleted+0−778View before deletion
drivers/staging/gma500/mdfld_dsi_dbi_dpu.hdeleted+0−154View before deletion
drivers/staging/gma500/mdfld_dsi_dpi.cdeleted+0−805View before deletion
drivers/staging/gma500/mdfld_dsi_dpi.hdeleted+0−78View before deletion
drivers/staging/gma500/mdfld_dsi_output.cdeleted+0−1014View before deletion
drivers/staging/gma500/mdfld_dsi_output.hdeleted+0−138View before deletion
drivers/staging/gma500/mdfld_dsi_pkg_sender.cdeleted+0−1484View before deletion
drivers/staging/gma500/mdfld_dsi_pkg_sender.hdeleted+0−184View before deletion
drivers/staging/gma500/mdfld_intel_display.cdeleted+0−1404View before deletion
drivers/staging/gma500/mdfld_msic.hdeleted+0−31View before deletion
drivers/staging/gma500/mdfld_output.cdeleted+0−171View before deletion
drivers/staging/gma500/mdfld_output.hdeleted+0−41View before deletion
drivers/staging/gma500/mdfld_pyr_cmd.cdeleted+0−558View before deletion
drivers/staging/gma500/mdfld_tmd_vid.cdeleted+0−206View before deletion
drivers/staging/gma500/mdfld_tpo_cmd.cdeleted+0−509View before deletion
drivers/staging/gma500/mdfld_tpo_vid.cdeleted+0−140View before deletion
drivers/staging/gma500/medfield.hdeleted+0−268View before deletion
drivers/staging/gma500/mid_bios.cdeleted+0−270View before deletion
drivers/staging/gma500/mid_bios.hdeleted+0−21View before deletion
drivers/staging/gma500/mmu.cdeleted+0−858View before deletion
drivers/staging/gma500/mrst.hdeleted+0−252View before deletion
drivers/staging/gma500/mrst_crtc.cdeleted+0−604View before deletion
drivers/staging/gma500/mrst_device.cdeleted+0−634View before deletion
drivers/staging/gma500/mrst_hdmi.cdeleted+0−852View before deletion
drivers/staging/gma500/mrst_hdmi_i2c.cdeleted+0−328View before deletion
drivers/staging/gma500/mrst_lvds.cdeleted+0−407View before deletion
drivers/staging/gma500/power.cdeleted+0−318View before deletion
drivers/staging/gma500/power.hdeleted+0−67View before deletion
drivers/staging/gma500/psb_device.cdeleted+0−321View before deletion
drivers/staging/gma500/psb_drm.hdeleted+0−219View before deletion
drivers/staging/gma500/psb_drv.cdeleted+0−1230View before deletion
drivers/staging/gma500/psb_drv.hdeleted+0−952View before deletion
drivers/staging/gma500/psb_intel_display.cdeleted+0−1429View before deletion
drivers/staging/gma500/psb_intel_display.hdeleted+0−28View before deletion
drivers/staging/gma500/psb_intel_drv.hdeleted+0−230View before deletion
drivers/staging/gma500/psb_intel_lvds.cdeleted+0−854View before deletion
drivers/staging/gma500/psb_intel_modes.cdeleted+0−77View before deletion
drivers/staging/gma500/psb_intel_reg.hdeleted+0−1235View before deletion
drivers/staging/gma500/psb_intel_sdvo.cdeleted+0−1293View before deletion
drivers/staging/gma500/psb_intel_sdvo_regs.hdeleted+0−338View before deletion
drivers/staging/gma500/psb_irq.cdeleted+0−627View before deletion
drivers/staging/gma500/psb_irq.hdeleted+0−45View before deletion
drivers/staging/gma500/psb_lid.cdeleted+0−88View before deletion
drivers/staging/gma500/psb_reg.hdeleted+0−582View before deletion
drivers/staging/omapdrm/Makefilemodified+1−0View file
drivers/staging/omapdrm/omap_crtc.cmodified+45−146View file
drivers/staging/omapdrm/omap_drv.cmodified+48−33View file
drivers/staging/omapdrm/omap_drv.hmodified+46−6View file
drivers/staging/omapdrm/omap_fb.cmodified+167−57View file
drivers/staging/omapdrm/omap_fbdev.cmodified+37−22View file
drivers/staging/omapdrm/omap_gem.cmodified+19−4View file
drivers/staging/omapdrm/omap_plane.cadded+344−0View file
drivers/staging/omapdrm/omap_priv.hmodified+10−2View file
drivers/staging/pohmelfs/Kconfigdeleted+0−20View before deletion
drivers/staging/pohmelfs/Makefiledeleted+0−3View before deletion
drivers/staging/pohmelfs/config.cdeleted+0−611View before deletion
drivers/staging/pohmelfs/crypto.cdeleted+0−878View before deletion
drivers/staging/pohmelfs/dir.cdeleted+0−1102View before deletion
drivers/staging/pohmelfs/inode.cdeleted+0−2055View before deletion
drivers/staging/pohmelfs/lock.cdeleted+0−182View before deletion
drivers/staging/pohmelfs/mcache.cdeleted+0−171View before deletion
drivers/staging/pohmelfs/net.cdeleted+0−1209View before deletion
drivers/staging/pohmelfs/netfs.hdeleted+0−919View before deletion
drivers/staging/pohmelfs/path_entry.cdeleted+0−120View before deletion
drivers/staging/pohmelfs/trans.cdeleted+0−706View before deletion
drivers/staging/rtl8712/drv_types.hmodified+7−0View file
drivers/staging/rtl8712/hal_init.cmodified+43−19View file
drivers/staging/rtl8712/os_intfs.cmodified+11−3View file
drivers/staging/rtl8712/rtl8712_hal.hmodified+1−0View file
drivers/staging/rtl8712/rtl871x_sta_mgt.cmodified+1−0View file
drivers/staging/rtl8712/usb_intf.cmodified+7−3View file
drivers/staging/tidspbridge/core/tiomap3430.cmodified+0−2View file
drivers/staging/tidspbridge/rmgr/drv_interface.cmodified+35−23View file
drivers/staging/usbip/stub_main.cmodified+2−2View file
drivers/staging/zcache/zcache-main.cmodified+12−13View file

Only the first 600 diff lines are shown. Download the complete patch.

MAINTAINERS

View file
diff --git a/MAINTAINERS b/MAINTAINERS
index 55ca0be..9a648eb 100644
--- a/MAINTAINERS
+++ b/MAINTAINERS
@@ -3318,6 +3318,12 @@ S: Maintained
F: net/ieee802154/
F: drivers/ieee802154/
+IIO SUBSYSTEM AND DRIVERS
+M: Jonathan Cameron <[email protected]>
+S: Maintained
+F: drivers/staging/iio/
+
IKANOS/ADI EAGLE ADSL USB DRIVER
M: Matthieu Castet <[email protected]>
M: Stanislaw Gruszka <[email protected]>

drivers/staging/Kconfig

View file
diff --git a/drivers/staging/Kconfig b/drivers/staging/Kconfig
index 21e2f4b..9e63472 100644
--- a/drivers/staging/Kconfig
+++ b/drivers/staging/Kconfig
@@ -60,8 +60,6 @@ source "drivers/staging/rts5139/Kconfig"
source "drivers/staging/frontier/Kconfig"
-source "drivers/staging/pohmelfs/Kconfig"
-
source "drivers/staging/phison/Kconfig"
source "drivers/staging/line6/Kconfig"
@@ -120,8 +118,6 @@ source "drivers/staging/cptm1217/Kconfig"
source "drivers/staging/ste_rmi4/Kconfig"
-source "drivers/staging/gma500/Kconfig"
-
source "drivers/staging/mei/Kconfig"
source "drivers/staging/nvec/Kconfig"

drivers/staging/Makefile

View file
diff --git a/drivers/staging/Makefile b/drivers/staging/Makefile
index 7c5808d..943e148 100644
--- a/drivers/staging/Makefile
+++ b/drivers/staging/Makefile
@@ -22,7 +22,6 @@ obj-$(CONFIG_R8712U) += rtl8712/
obj-$(CONFIG_RTS_PSTOR) += rts_pstor/
obj-$(CONFIG_RTS5139) += rts5139/
obj-$(CONFIG_TRANZPORT) += frontier/
-obj-$(CONFIG_POHMELFS) += pohmelfs/
obj-$(CONFIG_IDE_PHISON) += phison/
obj-$(CONFIG_LINE6_USB) += line6/
obj-$(CONFIG_USB_SERIAL_QUATECH2) += serqt_usb2/
@@ -52,7 +51,6 @@ obj-$(CONFIG_FT1000) += ft1000/
obj-$(CONFIG_SPEAKUP) += speakup/
obj-$(CONFIG_TOUCHSCREEN_CLEARPAD_TM1217) += cptm1217/
obj-$(CONFIG_TOUCHSCREEN_SYNAPTICS_I2C_RMI4) += ste_rmi4/
-obj-$(CONFIG_DRM_PSB) += gma500/
obj-$(CONFIG_INTEL_MEI) += mei/
obj-$(CONFIG_MFD_NVEC) += nvec/
obj-$(CONFIG_DRM_OMAP) += omapdrm/

drivers/staging/android/Kconfig

View file
diff --git a/drivers/staging/android/Kconfig b/drivers/staging/android/Kconfig
index becf711..fef3580 100644
--- a/drivers/staging/android/Kconfig
+++ b/drivers/staging/android/Kconfig
@@ -27,6 +27,7 @@ config ANDROID_LOGGER
config ANDROID_RAM_CONSOLE
bool "Android RAM buffer console"
+ depends on !S390 && !UML
default n
config ANDROID_RAM_CONSOLE_ENABLE_VERBOSE
@@ -99,10 +100,6 @@ config ANDROID_LOW_MEMORY_KILLER
---help---
Register processes to be killed when memory is low
-config ANDROID_PMEM
- bool "Android pmem allocator"
- depends on ARM
-
source "drivers/staging/android/switch/Kconfig"
endif # if ANDROID

drivers/staging/android/Makefile

View file
diff --git a/drivers/staging/android/Makefile b/drivers/staging/android/Makefile
index eaed1ff..5fcc24f 100644
--- a/drivers/staging/android/Makefile
+++ b/drivers/staging/android/Makefile
@@ -5,5 +5,4 @@ obj-$(CONFIG_ANDROID_RAM_CONSOLE) += ram_console.o
obj-$(CONFIG_ANDROID_TIMED_OUTPUT) += timed_output.o
obj-$(CONFIG_ANDROID_TIMED_GPIO) += timed_gpio.o
obj-$(CONFIG_ANDROID_LOW_MEMORY_KILLER) += lowmemorykiller.o
-obj-$(CONFIG_ANDROID_PMEM) += pmem.o
obj-$(CONFIG_ANDROID_SWITCH) += switch/

drivers/staging/android/android_pmem.h

View before deletion
diff --git a/drivers/staging/android/android_pmem.h b/drivers/staging/android/android_pmem.h
deleted file mode 100644
index f633621..0000000
--- a/drivers/staging/android/android_pmem.h
+++ /dev/null
@@ -1,93 +0,0 @@
-/* include/linux/android_pmem.h
- *
- * Copyright (C) 2007 Google, Inc.
- *
- * This software is licensed under the terms of the GNU General Public
- * License version 2, as published by the Free Software Foundation, and
- * may be copied, distributed, and modified under those terms.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU General Public License for more details.
- *
- */
-
-#ifndef _ANDROID_PMEM_H_
-#define _ANDROID_PMEM_H_
-
-#define PMEM_IOCTL_MAGIC 'p'
-#define PMEM_GET_PHYS _IOW(PMEM_IOCTL_MAGIC, 1, unsigned int)
-#define PMEM_MAP _IOW(PMEM_IOCTL_MAGIC, 2, unsigned int)
-#define PMEM_GET_SIZE _IOW(PMEM_IOCTL_MAGIC, 3, unsigned int)
-#define PMEM_UNMAP _IOW(PMEM_IOCTL_MAGIC, 4, unsigned int)
-/* This ioctl will allocate pmem space, backing the file, it will fail
- * if the file already has an allocation, pass it the len as the argument
- * to the ioctl */
-#define PMEM_ALLOCATE _IOW(PMEM_IOCTL_MAGIC, 5, unsigned int)
-/* This will connect a one pmem file to another, pass the file that is already
- * backed in memory as the argument to the ioctl
- */
-#define PMEM_CONNECT _IOW(PMEM_IOCTL_MAGIC, 6, unsigned int)
-/* Returns the total size of the pmem region it is sent to as a pmem_region
- * struct (with offset set to 0).
- */
-#define PMEM_GET_TOTAL_SIZE _IOW(PMEM_IOCTL_MAGIC, 7, unsigned int)
-#define PMEM_CACHE_FLUSH _IOW(PMEM_IOCTL_MAGIC, 8, unsigned int)
-
-struct android_pmem_platform_data
-{
- const char* name;
- /* starting physical address of memory region */
- unsigned long start;
- /* size of memory region */
- unsigned long size;
- /* set to indicate the region should not be managed with an allocator */
- unsigned no_allocator;
- /* set to indicate maps of this region should be cached, if a mix of
- * cached and uncached is desired, set this and open the device with
- * O_SYNC to get an uncached region */
- unsigned cached;
- /* The MSM7k has bits to enable a write buffer in the bus controller*/
- unsigned buffered;
-};
-
-struct pmem_region {
- unsigned long offset;
- unsigned long len;
-};
-
-#ifdef CONFIG_ANDROID_PMEM
-int is_pmem_file(struct file *file);
-int get_pmem_file(int fd, unsigned long *start, unsigned long *vstart,
- unsigned long *end, struct file **filp);
-int get_pmem_user_addr(struct file *file, unsigned long *start,
- unsigned long *end);
-void put_pmem_file(struct file* file);
-void flush_pmem_file(struct file *file, unsigned long start, unsigned long len);
-int pmem_setup(struct android_pmem_platform_data *pdata,
- long (*ioctl)(struct file *, unsigned int, unsigned long),
- int (*release)(struct inode *, struct file *));
-int pmem_remap(struct pmem_region *region, struct file *file,
- unsigned operation);
-
-#else
-static inline int is_pmem_file(struct file *file) { return 0; }
-static inline int get_pmem_file(int fd, unsigned long *start,
- unsigned long *vstart, unsigned long *end,
- struct file **filp) { return -ENOSYS; }
-static inline int get_pmem_user_addr(struct file *file, unsigned long *start,
- unsigned long *end) { return -ENOSYS; }
-static inline void put_pmem_file(struct file* file) { return; }
-static inline void flush_pmem_file(struct file *file, unsigned long start,
- unsigned long len) { return; }
-static inline int pmem_setup(struct android_pmem_platform_data *pdata,
- long (*ioctl)(struct file *, unsigned int, unsigned long),
- int (*release)(struct inode *, struct file *)) { return -ENOSYS; }
-
-static inline int pmem_remap(struct pmem_region *region, struct file *file,
- unsigned operation) { return -ENOSYS; }
-#endif
-
-#endif //_ANDROID_PPP_H_
-

drivers/staging/android/binder.c

View file
diff --git a/drivers/staging/android/binder.c b/drivers/staging/android/binder.c
index 7491801..f0b7e66 100644
--- a/drivers/staging/android/binder.c
+++ b/drivers/staging/android/binder.c
@@ -38,6 +38,7 @@
static DEFINE_MUTEX(binder_lock);
static DEFINE_MUTEX(binder_deferred_lock);
+static DEFINE_MUTEX(binder_mmap_lock);
static HLIST_HEAD(binder_procs);
static HLIST_HEAD(binder_deferred_list);
@@ -632,6 +633,11 @@ static int binder_update_page_range(struct binder_proc *proc, int allocate,
if (mm) {
down_write(&mm->mmap_sem);
vma = proc->vma;
+ if (vma && mm != vma->vm_mm) {
+ pr_err("binder: %d: vma mm and task mm mismatch\n",
+ proc->pid);
+ vma = NULL;
+ }
}
if (allocate == 0)
@@ -2759,7 +2765,6 @@ static void binder_vma_open(struct vm_area_struct *vma)
proc->pid, vma->vm_start, vma->vm_end,
(vma->vm_end - vma->vm_start) / SZ_1K, vma->vm_flags,
(unsigned long)pgprot_val(vma->vm_page_prot));
- dump_stack();
}
static void binder_vma_close(struct vm_area_struct *vma)
@@ -2803,6 +2808,7 @@ static int binder_mmap(struct file *filp, struct vm_area_struct *vma)
}
vma->vm_flags = (vma->vm_flags | VM_DONTCOPY) & ~VM_MAYWRITE;
+ mutex_lock(&binder_mmap_lock);
if (proc->buffer) {
ret = -EBUSY;
failure_string = "already mapped";
@@ -2817,6 +2823,7 @@ static int binder_mmap(struct file *filp, struct vm_area_struct *vma)
}
proc->buffer = area->addr;
proc->user_buffer_offset = vma->vm_start - (uintptr_t)proc->buffer;
+ mutex_unlock(&binder_mmap_lock);
#ifdef CONFIG_CPU_CACHE_VIPT
if (cache_is_vipt_aliasing()) {
@@ -2849,7 +2856,7 @@ static int binder_mmap(struct file *filp, struct vm_area_struct *vma)
binder_insert_free_buffer(proc, buffer);
proc->free_async_space = proc->buffer_size / 2;
barrier();
- proc->files = get_files_struct(current);
+ proc->files = get_files_struct(proc->tsk);
proc->vma = vma;
/*printk(KERN_INFO "binder_mmap: %d %lx-%lx maps %p\n",
@@ -2860,10 +2867,12 @@ err_alloc_small_buf_failed:
kfree(proc->pages);
proc->pages = NULL;
err_alloc_pages_failed:
+ mutex_lock(&binder_mmap_lock);
vfree(proc->buffer);
proc->buffer = NULL;
err_get_vm_area_failed:
err_already_mapped:
+ mutex_unlock(&binder_mmap_lock);
err_bad_arg:
printk(KERN_ERR "binder_mmap: %d %lx-%lx %s failed %d\n",
proc->pid, vma->vm_start, vma->vm_end, failure_string, ret);

drivers/staging/android/lowmemorykiller.c

View file
diff --git a/drivers/staging/android/lowmemorykiller.c b/drivers/staging/android/lowmemorykiller.c
index 2d8d2b7..efc7dc1 100644
--- a/drivers/staging/android/lowmemorykiller.c
+++ b/drivers/staging/android/lowmemorykiller.c
@@ -54,6 +54,7 @@ static size_t lowmem_minfree[6] = {
static int lowmem_minfree_size = 4;
static struct task_struct *lowmem_deathpending;
+static unsigned long lowmem_deathpending_timeout;
#define lowmem_print(level, x...) \
do { \
@@ -103,7 +104,8 @@ static int lowmem_shrink(struct shrinker *s, struct shrink_control *sc)
* Note: Currently you need CONFIG_PROFILING
* for this to work correctly.
*/
- if (lowmem_deathpending)
+ if (lowmem_deathpending &&
+ time_before_eq(jiffies, lowmem_deathpending_timeout))
return 0;
if (lowmem_adj_size < array_size)
@@ -178,6 +180,7 @@ static int lowmem_shrink(struct shrinker *s, struct shrink_control *sc)
*/
#ifdef CONFIG_PROFILING
lowmem_deathpending = selected;
+ lowmem_deathpending_timeout = jiffies + HZ;
task_handoff_register(&task_nb);
#endif
force_sig(SIGKILL, selected);

drivers/staging/android/pmem.c

View before deletion
diff --git a/drivers/staging/android/pmem.c b/drivers/staging/android/pmem.c
deleted file mode 100644
index 7d97032..0000000
--- a/drivers/staging/android/pmem.c
+++ /dev/null
@@ -1,1345 +0,0 @@
-/* pmem.c
- *
- * Copyright (C) 2007 Google, Inc.
- *
- * This software is licensed under the terms of the GNU General Public
- * License version 2, as published by the Free Software Foundation, and
- * may be copied, distributed, and modified under those terms.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU General Public License for more details.
- *
- */
-
-#include <linux/miscdevice.h>
-#include <linux/platform_device.h>
-#include <linux/fs.h>
-#include <linux/file.h>
-#include <linux/mm.h>
-#include <linux/list.h>
-#include <linux/mutex.h>
-#include <linux/debugfs.h>
-#include <linux/mempolicy.h>
-#include <linux/sched.h>
-#include <asm/io.h>
-#include <asm/uaccess.h>
-#include <asm/cacheflush.h>
-#include "android_pmem.h"
-
-#define PMEM_MAX_DEVICES 10
-#define PMEM_MAX_ORDER 128
-#define PMEM_MIN_ALLOC PAGE_SIZE
-
-#define PMEM_DEBUG 1
-
-/* indicates that a refernce to this file has been taken via get_pmem_file,
- * the file should not be released until put_pmem_file is called */
-#define PMEM_FLAGS_BUSY 0x1
-/* indicates that this is a suballocation of a larger master range */
-#define PMEM_FLAGS_CONNECTED 0x1 << 1
-/* indicates this is a master and not a sub allocation and that it is mmaped */
-#define PMEM_FLAGS_MASTERMAP 0x1 << 2
-/* submap and unsubmap flags indicate:
- * 00: subregion has never been mmaped
- * 10: subregion has been mmaped, reference to the mm was taken
- * 11: subretion has ben released, refernece to the mm still held
- * 01: subretion has been released, reference to the mm has been released
- */
-#define PMEM_FLAGS_SUBMAP 0x1 << 3
-#define PMEM_FLAGS_UNSUBMAP 0x1 << 4
-
-
-struct pmem_data {
- /* in alloc mode: an index into the bitmap
- * in no_alloc mode: the size of the allocation */
- int index;
- /* see flags above for descriptions */
- unsigned int flags;
- /* protects this data field, if the mm_mmap sem will be held at the
- * same time as this sem, the mm sem must be taken first (as this is
- * the order for vma_open and vma_close ops */
- struct rw_semaphore sem;
- /* info about the mmaping process */
- struct vm_area_struct *vma;
- /* task struct of the mapping process */
- struct task_struct *task;
- /* process id of teh mapping process */
- pid_t pid;
- /* file descriptor of the master */
- int master_fd;
- /* file struct of the master */
- struct file *master_file;
- /* a list of currently available regions if this is a suballocation */
- struct list_head region_list;
- /* a linked list of data so we can access them for debugging */
- struct list_head list;
-#if PMEM_DEBUG
- int ref;
-#endif
-};
-
-struct pmem_bits {
- unsigned allocated:1; /* 1 if allocated, 0 if free */
- unsigned order:7; /* size of the region in pmem space */
-};
-
-struct pmem_region_node {
- struct pmem_region region;
- struct list_head list;
-};
-
-#define PMEM_DEBUG_MSGS 0
-#if PMEM_DEBUG_MSGS
-#define DLOG(fmt,args...) \
- do { printk(KERN_INFO "[%s:%s:%d] "fmt, __FILE__, __func__, __LINE__, \
- ##args); } \
- while (0)
-#else
-#define DLOG(x...) do {} while (0)
-#endif
-
-struct pmem_info {
- struct miscdevice dev;
- /* physical start address of the remaped pmem space */
- unsigned long base;
- /* vitual start address of the remaped pmem space */
- unsigned char __iomem *vbase;
- /* total size of the pmem space */
- unsigned long size;
- /* number of entries in the pmem space */
- unsigned long num_entries;
- /* pfn of the garbage page in memory */
- unsigned long garbage_pfn;
- /* index of the garbage page in the pmem space */
- int garbage_index;
- /* the bitmap for the region indicating which entries are allocated
- * and which are free */
- struct pmem_bits *bitmap;
- /* indicates the region should not be managed with an allocator */
- unsigned no_allocator;
- /* indicates maps of this region should be cached, if a mix of
- * cached and uncached is desired, set this and open the device with
- * O_SYNC to get an uncached region */
- unsigned cached;
- unsigned buffered;
- /* in no_allocator mode the first mapper gets the whole space and sets
- * this flag */
- unsigned allocated;
- /* for debugging, creates a list of pmem file structs, the
- * data_list_lock should be taken before pmem_data->sem if both are
- * needed */
- struct mutex data_list_lock;
- struct list_head data_list;
- /* pmem_sem protects the bitmap array
- * a write lock should be held when modifying entries in bitmap
- * a read lock should be held when reading data from bits or
- * dereferencing a pointer into bitmap
- *
- * pmem_data->sem protects the pmem data of a particular file
- * Many of the function that require the pmem_data->sem have a non-
- * locking version for when the caller is already holding that sem.
- *
- * IF YOU TAKE BOTH LOCKS TAKE THEM IN THIS ORDER:
- * down(pmem_data->sem) => down(bitmap_sem)
- */
- struct rw_semaphore bitmap_sem;
-
- long (*ioctl)(struct file *, unsigned int, unsigned long);
- int (*release)(struct inode *, struct file *);
-};
-
-static struct pmem_info pmem[PMEM_MAX_DEVICES];
-static int id_count;
-
-#define PMEM_IS_FREE(id, index) !(pmem[id].bitmap[index].allocated)
-#define PMEM_ORDER(id, index) pmem[id].bitmap[index].order
-#define PMEM_BUDDY_INDEX(id, index) (index ^ (1 << PMEM_ORDER(id, index)))
-#define PMEM_NEXT_INDEX(id, index) (index + (1 << PMEM_ORDER(id, index)))
-#define PMEM_OFFSET(index) (index * PMEM_MIN_ALLOC)
-#define PMEM_START_ADDR(id, index) (PMEM_OFFSET(index) + pmem[id].base)
-#define PMEM_LEN(id, index) ((1 << PMEM_ORDER(id, index)) * PMEM_MIN_ALLOC)
-#define PMEM_END_ADDR(id, index) (PMEM_START_ADDR(id, index) + \
- PMEM_LEN(id, index))
-#define PMEM_START_VADDR(id, index) (PMEM_OFFSET(id, index) + pmem[id].vbase)
-#define PMEM_END_VADDR(id, index) (PMEM_START_VADDR(id, index) + \
- PMEM_LEN(id, index))
-#define PMEM_REVOKED(data) (data->flags & PMEM_FLAGS_REVOKED)
-#define PMEM_IS_PAGE_ALIGNED(addr) (!((addr) & (~PAGE_MASK)))
-#define PMEM_IS_SUBMAP(data) ((data->flags & PMEM_FLAGS_SUBMAP) && \
- (!(data->flags & PMEM_FLAGS_UNSUBMAP)))
-
-static int pmem_release(struct inode *, struct file *);
-static int pmem_mmap(struct file *, struct vm_area_struct *);
-static int pmem_open(struct inode *, struct file *);
-static long pmem_ioctl(struct file *, unsigned int, unsigned long);
-
-struct file_operations pmem_fops = {
- .release = pmem_release,
- .mmap = pmem_mmap,
- .open = pmem_open,
- .unlocked_ioctl = pmem_ioctl,
-};
-
-static int get_id(struct file *file)
-{
- return MINOR(file->f_dentry->d_inode->i_rdev);
-}
-
-int is_pmem_file(struct file *file)
-{
- int id;
-
- if (unlikely(!file || !file->f_dentry || !file->f_dentry->d_inode))
- return 0;
- id = get_id(file);
- if (unlikely(id >= PMEM_MAX_DEVICES))
- return 0;
- if (unlikely(file->f_dentry->d_inode->i_rdev !=
- MKDEV(MISC_MAJOR, pmem[id].dev.minor)))
- return 0;
- return 1;
-}
-
-static int has_allocation(struct file *file)
-{
- struct pmem_data *data;
- /* check is_pmem_file first if not accessed via pmem_file_ops */
-
- if (unlikely(!file->private_data))
- return 0;
- data = (struct pmem_data *)file->private_data;
- if (unlikely(data->index < 0))
- return 0;
- return 1;
-}
-
-static int is_master_owner(struct file *file)
-{
- struct file *master_file;
- struct pmem_data *data;
- int put_needed, ret = 0;
-
- if (!is_pmem_file(file) || !has_allocation(file))
- return 0;
- data = (struct pmem_data *)file->private_data;
- if (PMEM_FLAGS_MASTERMAP & data->flags)
- return 1;
- master_file = fget_light(data->master_fd, &put_needed);
- if (master_file && data->master_file == master_file)
- ret = 1;
- fput_light(master_file, put_needed);
- return ret;
-}
-
-static int pmem_free(int id, int index)
-{
- /* caller should hold the write lock on pmem_sem! */
- int buddy, curr = index;
- DLOG("index %d\n", index);
-
- if (pmem[id].no_allocator) {
- pmem[id].allocated = 0;
- return 0;
- }
- /* clean up the bitmap, merging any buddies */
- pmem[id].bitmap[curr].allocated = 0;
- /* find a slots buddy Buddy# = Slot# ^ (1 << order)
- * if the buddy is also free merge them
- * repeat until the buddy is not free or end of the bitmap is reached
- */
- do {
- buddy = PMEM_BUDDY_INDEX(id, curr);
- if (PMEM_IS_FREE(id, buddy) &&
- PMEM_ORDER(id, buddy) == PMEM_ORDER(id, curr)) {
- PMEM_ORDER(id, buddy)++;
- PMEM_ORDER(id, curr)++;
- curr = min(buddy, curr);
- } else {
- break;
- }
- } while (curr < pmem[id].num_entries);
-
- return 0;
-}
-
-static void pmem_revoke(struct file *file, struct pmem_data *data);
-
-static int pmem_release(struct inode *inode, struct file *file)
-{
- struct pmem_data *data = (struct pmem_data *)file->private_data;
- struct pmem_region_node *region_node;
- struct list_head *elt, *elt2;
- int id = get_id(file), ret = 0;
-
-
- mutex_lock(&pmem[id].data_list_lock);
- /* if this file is a master, revoke all the memory in the connected
- * files */
- if (PMEM_FLAGS_MASTERMAP & data->flags) {
- struct pmem_data *sub_data;
- list_for_each(elt, &pmem[id].data_list) {
- sub_data = list_entry(elt, struct pmem_data, list);
- down_read(&sub_data->sem);
- if (PMEM_IS_SUBMAP(sub_data) &&
- file == sub_data->master_file) {
- up_read(&sub_data->sem);
- pmem_revoke(file, sub_data);
- } else
- up_read(&sub_data->sem);
- }
- }
- list_del(&data->list);
- mutex_unlock(&pmem[id].data_list_lock);
-
-
- down_write(&data->sem);
-
- /* if its not a conencted file and it has an allocation, free it */
- if (!(PMEM_FLAGS_CONNECTED & data->flags) && has_allocation(file)) {
- down_write(&pmem[id].bitmap_sem);
- ret = pmem_free(id, data->index);
- up_write(&pmem[id].bitmap_sem);

This diff is incomplete. Download the complete patch.

drivers/staging/asus_oled/asus_oled.c

View file

This diff is incomplete. Download the complete patch.

drivers/staging/gma500/Kconfig

View before deletion

This diff is incomplete. Download the complete patch.

drivers/staging/gma500/Makefile

View before deletion

This diff is incomplete. Download the complete patch.

drivers/staging/gma500/TODO

View before deletion

This diff is incomplete. Download the complete patch.

drivers/staging/gma500/accel_2d.c

View before deletion

This diff is incomplete. Download the complete patch.

drivers/staging/gma500/backlight.c

View before deletion

This diff is incomplete. Download the complete patch.

drivers/staging/gma500/cdv_device.c

View before deletion

This diff is incomplete. Download the complete patch.

drivers/staging/gma500/cdv_device.h

View before deletion

This diff is incomplete. Download the complete patch.

drivers/staging/gma500/cdv_intel_crt.c

View before deletion

This diff is incomplete. Download the complete patch.

drivers/staging/gma500/cdv_intel_display.c

View before deletion

This diff is incomplete. Download the complete patch.

drivers/staging/gma500/cdv_intel_hdmi.c

View before deletion

This diff is incomplete. Download the complete patch.

drivers/staging/gma500/cdv_intel_lvds.c

View before deletion

This diff is incomplete. Download the complete patch.

drivers/staging/gma500/displays/hdmi.h

View before deletion

This diff is incomplete. Download the complete patch.

drivers/staging/gma500/displays/pyr_cmd.h

View before deletion

This diff is incomplete. Download the complete patch.

drivers/staging/gma500/displays/pyr_vid.h

View before deletion

This diff is incomplete. Download the complete patch.

drivers/staging/gma500/displays/tmd_cmd.h

View before deletion

This diff is incomplete. Download the complete patch.

drivers/staging/gma500/displays/tmd_vid.h

View before deletion

This diff is incomplete. Download the complete patch.

drivers/staging/gma500/displays/tpo_cmd.h

View before deletion

This diff is incomplete. Download the complete patch.

drivers/staging/gma500/displays/tpo_vid.h

View before deletion

This diff is incomplete. Download the complete patch.

drivers/staging/gma500/framebuffer.c

View before deletion

This diff is incomplete. Download the complete patch.

drivers/staging/gma500/framebuffer.h

View before deletion

This diff is incomplete. Download the complete patch.

drivers/staging/gma500/gem.c

View before deletion

This diff is incomplete. Download the complete patch.

drivers/staging/gma500/gem_glue.c

View before deletion

This diff is incomplete. Download the complete patch.

drivers/staging/gma500/gem_glue.h

View before deletion

This diff is incomplete. Download the complete patch.

drivers/staging/gma500/gtt.c

View before deletion

This diff is incomplete. Download the complete patch.

drivers/staging/gma500/gtt.h

View before deletion

This diff is incomplete. Download the complete patch.

drivers/staging/gma500/intel_bios.c

View before deletion

This diff is incomplete. Download the complete patch.

drivers/staging/gma500/intel_bios.h

View before deletion

This diff is incomplete. Download the complete patch.

drivers/staging/gma500/intel_i2c.c

View before deletion

This diff is incomplete. Download the complete patch.

drivers/staging/gma500/intel_opregion.c

View before deletion

This diff is incomplete. Download the complete patch.

drivers/staging/gma500/mdfld_device.c

View before deletion

This diff is incomplete. Download the complete patch.

drivers/staging/gma500/mdfld_dsi_dbi.c

View before deletion

This diff is incomplete. Download the complete patch.

drivers/staging/gma500/mdfld_dsi_dbi.h

View before deletion

This diff is incomplete. Download the complete patch.

drivers/staging/gma500/mdfld_dsi_dbi_dpu.c

View before deletion

This diff is incomplete. Download the complete patch.

drivers/staging/gma500/mdfld_dsi_dbi_dpu.h

View before deletion

This diff is incomplete. Download the complete patch.

drivers/staging/gma500/mdfld_dsi_dpi.c

View before deletion

This diff is incomplete. Download the complete patch.

drivers/staging/gma500/mdfld_dsi_dpi.h

View before deletion

This diff is incomplete. Download the complete patch.

drivers/staging/gma500/mdfld_dsi_output.c

View before deletion

This diff is incomplete. Download the complete patch.

drivers/staging/gma500/mdfld_dsi_output.h

View before deletion

This diff is incomplete. Download the complete patch.

drivers/staging/gma500/mdfld_dsi_pkg_sender.c

View before deletion

This diff is incomplete. Download the complete patch.

drivers/staging/gma500/mdfld_dsi_pkg_sender.h

View before deletion

This diff is incomplete. Download the complete patch.

drivers/staging/gma500/mdfld_intel_display.c

View before deletion

This diff is incomplete. Download the complete patch.

drivers/staging/gma500/mdfld_msic.h

View before deletion

This diff is incomplete. Download the complete patch.

drivers/staging/gma500/mdfld_output.c

View before deletion

This diff is incomplete. Download the complete patch.

drivers/staging/gma500/mdfld_output.h

View before deletion

This diff is incomplete. Download the complete patch.

drivers/staging/gma500/mdfld_pyr_cmd.c

View before deletion

This diff is incomplete. Download the complete patch.

drivers/staging/gma500/mdfld_tmd_vid.c

View before deletion

This diff is incomplete. Download the complete patch.

drivers/staging/gma500/mdfld_tpo_cmd.c

View before deletion

This diff is incomplete. Download the complete patch.

drivers/staging/gma500/mdfld_tpo_vid.c

View before deletion

This diff is incomplete. Download the complete patch.

drivers/staging/gma500/medfield.h

View before deletion

This diff is incomplete. Download the complete patch.

drivers/staging/gma500/mid_bios.c

View before deletion

This diff is incomplete. Download the complete patch.

drivers/staging/gma500/mid_bios.h

View before deletion

This diff is incomplete. Download the complete patch.

drivers/staging/gma500/mmu.c

View before deletion

This diff is incomplete. Download the complete patch.

drivers/staging/gma500/mrst.h

View before deletion

This diff is incomplete. Download the complete patch.

drivers/staging/gma500/mrst_crtc.c

View before deletion

This diff is incomplete. Download the complete patch.

drivers/staging/gma500/mrst_device.c

View before deletion

This diff is incomplete. Download the complete patch.

drivers/staging/gma500/mrst_hdmi.c

View before deletion

This diff is incomplete. Download the complete patch.

drivers/staging/gma500/mrst_hdmi_i2c.c

View before deletion

This diff is incomplete. Download the complete patch.

drivers/staging/gma500/mrst_lvds.c

View before deletion

This diff is incomplete. Download the complete patch.

drivers/staging/gma500/power.c

View before deletion

This diff is incomplete. Download the complete patch.

drivers/staging/gma500/power.h

View before deletion

This diff is incomplete. Download the complete patch.

drivers/staging/gma500/psb_device.c

View before deletion

This diff is incomplete. Download the complete patch.

drivers/staging/gma500/psb_drm.h

View before deletion

This diff is incomplete. Download the complete patch.

drivers/staging/gma500/psb_drv.c

View before deletion

This diff is incomplete. Download the complete patch.

drivers/staging/gma500/psb_drv.h

View before deletion

This diff is incomplete. Download the complete patch.

drivers/staging/gma500/psb_intel_display.c

View before deletion

This diff is incomplete. Download the complete patch.

drivers/staging/gma500/psb_intel_display.h

View before deletion

This diff is incomplete. Download the complete patch.

drivers/staging/gma500/psb_intel_drv.h

View before deletion

This diff is incomplete. Download the complete patch.

drivers/staging/gma500/psb_intel_lvds.c

View before deletion

This diff is incomplete. Download the complete patch.

drivers/staging/gma500/psb_intel_modes.c

View before deletion

This diff is incomplete. Download the complete patch.

drivers/staging/gma500/psb_intel_reg.h

View before deletion

This diff is incomplete. Download the complete patch.

drivers/staging/gma500/psb_intel_sdvo.c

View before deletion

This diff is incomplete. Download the complete patch.

drivers/staging/gma500/psb_intel_sdvo_regs.h

View before deletion

This diff is incomplete. Download the complete patch.

drivers/staging/gma500/psb_irq.c

View before deletion

This diff is incomplete. Download the complete patch.

drivers/staging/gma500/psb_irq.h

View before deletion

This diff is incomplete. Download the complete patch.

drivers/staging/gma500/psb_lid.c

View before deletion

This diff is incomplete. Download the complete patch.

drivers/staging/gma500/psb_reg.h

View before deletion

This diff is incomplete. Download the complete patch.

drivers/staging/omapdrm/Makefile

View file

This diff is incomplete. Download the complete patch.

drivers/staging/omapdrm/omap_crtc.c

View file

This diff is incomplete. Download the complete patch.

drivers/staging/omapdrm/omap_drv.c

View file

This diff is incomplete. Download the complete patch.

drivers/staging/omapdrm/omap_drv.h

View file

This diff is incomplete. Download the complete patch.

drivers/staging/omapdrm/omap_fb.c

View file

This diff is incomplete. Download the complete patch.

drivers/staging/omapdrm/omap_fbdev.c

View file

This diff is incomplete. Download the complete patch.

drivers/staging/omapdrm/omap_gem.c

View file

This diff is incomplete. Download the complete patch.

drivers/staging/omapdrm/omap_plane.c

View file

This diff is incomplete. Download the complete patch.

drivers/staging/omapdrm/omap_priv.h

View file

This diff is incomplete. Download the complete patch.

drivers/staging/pohmelfs/Kconfig

View before deletion

This diff is incomplete. Download the complete patch.

drivers/staging/pohmelfs/Makefile

View before deletion

This diff is incomplete. Download the complete patch.

drivers/staging/pohmelfs/config.c

View before deletion

This diff is incomplete. Download the complete patch.

drivers/staging/pohmelfs/crypto.c

View before deletion

This diff is incomplete. Download the complete patch.

drivers/staging/pohmelfs/dir.c

View before deletion

This diff is incomplete. Download the complete patch.

drivers/staging/pohmelfs/inode.c

View before deletion

This diff is incomplete. Download the complete patch.

drivers/staging/pohmelfs/lock.c

View before deletion

This diff is incomplete. Download the complete patch.

drivers/staging/pohmelfs/mcache.c

View before deletion

This diff is incomplete. Download the complete patch.

drivers/staging/pohmelfs/net.c

View before deletion

This diff is incomplete. Download the complete patch.

drivers/staging/pohmelfs/netfs.h

View before deletion

This diff is incomplete. Download the complete patch.

drivers/staging/pohmelfs/path_entry.c

View before deletion

This diff is incomplete. Download the complete patch.

drivers/staging/pohmelfs/trans.c

View before deletion

This diff is incomplete. Download the complete patch.

drivers/staging/rtl8712/drv_types.h

View file

This diff is incomplete. Download the complete patch.

drivers/staging/rtl8712/hal_init.c

View file

This diff is incomplete. Download the complete patch.

drivers/staging/rtl8712/os_intfs.c

View file

This diff is incomplete. Download the complete patch.

drivers/staging/rtl8712/rtl8712_hal.h

View file

This diff is incomplete. Download the complete patch.

drivers/staging/rtl8712/rtl871x_sta_mgt.c

View file

This diff is incomplete. Download the complete patch.

drivers/staging/rtl8712/usb_intf.c

View file

This diff is incomplete. Download the complete patch.

drivers/staging/tidspbridge/core/tiomap3430.c

View file

This diff is incomplete. Download the complete patch.

drivers/staging/tidspbridge/rmgr/drv_interface.c

View file

This diff is incomplete. Download the complete patch.

drivers/staging/usbip/stub_main.c

View file

This diff is incomplete. Download the complete patch.

drivers/staging/zcache/zcache-main.c

View file

This diff is incomplete. Download the complete patch.