Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 211430
b: refs/heads/master
c: 85a3318
h: refs/heads/master
v: v3
  • Loading branch information
Linus Torvalds committed Oct 9, 2010
1 parent 0559ee9 commit 87e295a
Show file tree
Hide file tree
Showing 85 changed files with 586 additions and 282 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: ae6df5f96a51818d6376da5307d773baeece4014
refs/heads/master: 85a331881dd52a93e7d4c57bcaf5486cc8718465
2 changes: 1 addition & 1 deletion trunk/Documentation/vm/page-types.c
Original file line number Diff line number Diff line change
Expand Up @@ -478,7 +478,7 @@ static void prepare_hwpoison_fd(void)
}

if (opt_unpoison && !hwpoison_forget_fd) {
sprintf(buf, "%s/renew-pfn", hwpoison_debug_fs);
sprintf(buf, "%s/unpoison-pfn", hwpoison_debug_fs);
hwpoison_forget_fd = checked_open(buf, O_WRONLY);
}
}
Expand Down
12 changes: 11 additions & 1 deletion trunk/MAINTAINERS
Original file line number Diff line number Diff line change
Expand Up @@ -969,6 +969,16 @@ L: linux-samsung-soc@vger.kernel.org (moderated for non-subscribers)
S: Maintained
F: arch/arm/mach-s5p*/

ARM/SAMSUNG S5P SERIES FIMC SUPPORT
M: Kyungmin Park <kyungmin.park@samsung.com>
M: Sylwester Nawrocki <s.nawrocki@samsung.com>
L: linux-arm-kernel@lists.infradead.org
L: linux-media@vger.kernel.org
S: Maintained
F: arch/arm/plat-s5p/dev-fimc*
F: arch/arm/plat-samsung/include/plat/*fimc*
F: drivers/media/video/s5p-fimc/

ARM/SHMOBILE ARM ARCHITECTURE
M: Paul Mundt <lethal@linux-sh.org>
M: Magnus Damm <magnus.damm@gmail.com>
Expand Down Expand Up @@ -2535,7 +2545,7 @@ S: Supported
F: drivers/scsi/gdt*

GENERIC GPIO I2C DRIVER
M: Haavard Skinnemoen <hskinnemoen@atmel.com>
M: Haavard Skinnemoen <hskinnemoen@gmail.com>
S: Supported
F: drivers/i2c/busses/i2c-gpio.c
F: include/linux/i2c-gpio.h
Expand Down
1 change: 1 addition & 0 deletions trunk/arch/arm/mach-s5p6440/cpu.c
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@
#include <linux/sysdev.h>
#include <linux/serial_core.h>
#include <linux/platform_device.h>
#include <linux/sched.h>

#include <asm/mach/arch.h>
#include <asm/mach/map.h>
Expand Down
1 change: 1 addition & 0 deletions trunk/arch/arm/mach-s5p6442/cpu.c
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@
#include <linux/sysdev.h>
#include <linux/serial_core.h>
#include <linux/platform_device.h>
#include <linux/sched.h>

#include <asm/mach/arch.h>
#include <asm/mach/map.h>
Expand Down
1 change: 1 addition & 0 deletions trunk/arch/arm/mach-s5pc100/cpu.c
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@
#include <linux/sysdev.h>
#include <linux/serial_core.h>
#include <linux/platform_device.h>
#include <linux/sched.h>

#include <asm/mach/arch.h>
#include <asm/mach/map.h>
Expand Down
5 changes: 0 additions & 5 deletions trunk/arch/arm/mach-s5pv210/clock.c
Original file line number Diff line number Diff line change
Expand Up @@ -173,11 +173,6 @@ static int s5pv210_clk_ip3_ctrl(struct clk *clk, int enable)
return s5p_gatectrl(S5P_CLKGATE_IP3, clk, enable);
}

static int s5pv210_clk_ip4_ctrl(struct clk *clk, int enable)
{
return s5p_gatectrl(S5P_CLKGATE_IP4, clk, enable);
}

static int s5pv210_clk_mask0_ctrl(struct clk *clk, int enable)
{
return s5p_gatectrl(S5P_CLK_SRC_MASK0, clk, enable);
Expand Down
1 change: 1 addition & 0 deletions trunk/arch/arm/mach-s5pv210/cpu.c
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@
#include <linux/io.h>
#include <linux/sysdev.h>
#include <linux/platform_device.h>
#include <linux/sched.h>

#include <asm/mach/arch.h>
#include <asm/mach/map.h>
Expand Down
1 change: 0 additions & 1 deletion trunk/arch/arm/plat-samsung/adc.c
Original file line number Diff line number Diff line change
Expand Up @@ -435,7 +435,6 @@ static int s3c_adc_suspend(struct platform_device *pdev, pm_message_t state)
static int s3c_adc_resume(struct platform_device *pdev)
{
struct adc_device *adc = platform_get_drvdata(pdev);
unsigned long flags;

clk_enable(adc->clk);
enable_irq(adc->irq);
Expand Down
27 changes: 26 additions & 1 deletion trunk/arch/arm/plat-samsung/clock.c
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,9 @@
#include <plat/clock.h>
#include <plat/cpu.h>

#include <linux/serial_core.h>
#include <plat/regs-serial.h> /* for s3c24xx_uart_devs */

/* clock information */

static LIST_HEAD(clocks);
Expand All @@ -65,6 +68,28 @@ static int clk_null_enable(struct clk *clk, int enable)
return 0;
}

static int dev_is_s3c_uart(struct device *dev)
{
struct platform_device **pdev = s3c24xx_uart_devs;
int i;
for (i = 0; i < ARRAY_SIZE(s3c24xx_uart_devs); i++, pdev++)
if (*pdev && dev == &(*pdev)->dev)
return 1;
return 0;
}

/*
* Serial drivers call get_clock() very early, before platform bus
* has been set up, this requires a special check to let them get
* a proper clock
*/

static int dev_is_platform_device(struct device *dev)
{
return dev->bus == &platform_bus_type ||
(dev->bus == NULL && dev_is_s3c_uart(dev));
}

/* Clock API calls */

struct clk *clk_get(struct device *dev, const char *id)
Expand All @@ -73,7 +98,7 @@ struct clk *clk_get(struct device *dev, const char *id)
struct clk *clk = ERR_PTR(-ENOENT);
int idno;

if (dev == NULL || dev->bus != &platform_bus_type)
if (dev == NULL || !dev_is_platform_device(dev))
idno = -1;
else
idno = to_platform_device(dev)->id;
Expand Down
1 change: 1 addition & 0 deletions trunk/arch/mips/include/asm/siginfo.h
Original file line number Diff line number Diff line change
Expand Up @@ -88,6 +88,7 @@ typedef struct siginfo {
#ifdef __ARCH_SI_TRAPNO
int _trapno; /* TRAP # which caused the signal */
#endif
short _addr_lsb;
} _sigfault;

/* SIGPOLL, SIGXFSZ (To do ...) */
Expand Down
12 changes: 8 additions & 4 deletions trunk/block/elevator.c
Original file line number Diff line number Diff line change
Expand Up @@ -938,6 +938,7 @@ int elv_register_queue(struct request_queue *q)
}
}
kobject_uevent(&e->kobj, KOBJ_ADD);
e->registered = 1;
}
return error;
}
Expand All @@ -947,6 +948,7 @@ static void __elv_unregister_queue(struct elevator_queue *e)
{
kobject_uevent(&e->kobj, KOBJ_REMOVE);
kobject_del(&e->kobj);
e->registered = 0;
}

void elv_unregister_queue(struct request_queue *q)
Expand Down Expand Up @@ -1042,11 +1044,13 @@ static int elevator_switch(struct request_queue *q, struct elevator_type *new_e)

spin_unlock_irq(q->queue_lock);

__elv_unregister_queue(old_elevator);
if (old_elevator->registered) {
__elv_unregister_queue(old_elevator);

err = elv_register_queue(q);
if (err)
goto fail_register;
err = elv_register_queue(q);
if (err)
goto fail_register;
}

/*
* finally exit old elevator and turn off BYPASS.
Expand Down
17 changes: 17 additions & 0 deletions trunk/drivers/acpi/blacklist.c
Original file line number Diff line number Diff line change
Expand Up @@ -204,6 +204,23 @@ static struct dmi_system_id acpi_osi_dmi_table[] __initdata = {
},
},
{
/*
* There have a NVIF method in MSI GX723 DSDT need call by Nvidia
* driver (e.g. nouveau) when user press brightness hotkey.
* Currently, nouveau driver didn't do the job and it causes there
* have a infinite while loop in DSDT when user press hotkey.
* We add MSI GX723's dmi information to this table for workaround
* this issue.
* Will remove MSI GX723 from the table after nouveau grows support.
*/
.callback = dmi_disable_osi_vista,
.ident = "MSI GX723",
.matches = {
DMI_MATCH(DMI_SYS_VENDOR, "Micro-Star International"),
DMI_MATCH(DMI_PRODUCT_NAME, "GX723"),
},
},
{
.callback = dmi_disable_osi_vista,
.ident = "Sony VGN-NS10J_S",
.matches = {
Expand Down
1 change: 1 addition & 0 deletions trunk/drivers/acpi/processor_core.c
Original file line number Diff line number Diff line change
Expand Up @@ -346,4 +346,5 @@ void __init acpi_early_processor_set_pdc(void)
acpi_walk_namespace(ACPI_TYPE_PROCESSOR, ACPI_ROOT_OBJECT,
ACPI_UINT32_MAX,
early_init_pdc, NULL, NULL, NULL);
acpi_get_devices("ACPI0007", early_init_pdc, NULL, NULL);
}
6 changes: 5 additions & 1 deletion trunk/drivers/block/virtio_blk.c
Original file line number Diff line number Diff line change
Expand Up @@ -202,6 +202,7 @@ static int virtblk_get_id(struct gendisk *disk, char *id_str)
struct virtio_blk *vblk = disk->private_data;
struct request *req;
struct bio *bio;
int err;

bio = bio_map_kern(vblk->disk->queue, id_str, VIRTIO_BLK_ID_BYTES,
GFP_KERNEL);
Expand All @@ -215,7 +216,10 @@ static int virtblk_get_id(struct gendisk *disk, char *id_str)
}

req->cmd_type = REQ_TYPE_SPECIAL;
return blk_execute_rq(vblk->disk->queue, vblk->disk, req, false);
err = blk_execute_rq(vblk->disk->queue, vblk->disk, req, false);
blk_put_request(req);

return err;
}

static int virtblk_locked_ioctl(struct block_device *bdev, fmode_t mode,
Expand Down
3 changes: 3 additions & 0 deletions trunk/drivers/gpu/drm/i915/i915_dma.c
Original file line number Diff line number Diff line change
Expand Up @@ -2231,6 +2231,9 @@ int i915_driver_load(struct drm_device *dev, unsigned long flags)
dev_priv->mchdev_lock = &mchdev_lock;
spin_unlock(&mchdev_lock);

/* XXX Prevent module unload due to memory corruption bugs. */
__module_get(THIS_MODULE);

return 0;

out_workqueue_free:
Expand Down
2 changes: 1 addition & 1 deletion trunk/drivers/gpu/drm/i915/intel_fb.c
Original file line number Diff line number Diff line change
Expand Up @@ -238,8 +238,8 @@ int intel_fbdev_destroy(struct drm_device *dev,

drm_framebuffer_cleanup(&ifb->base);
if (ifb->obj) {
drm_gem_object_handle_unreference(ifb->obj);
drm_gem_object_unreference(ifb->obj);
ifb->obj = NULL;
}

return 0;
Expand Down
1 change: 0 additions & 1 deletion trunk/drivers/gpu/drm/nouveau/nouveau_fbcon.c
Original file line number Diff line number Diff line change
Expand Up @@ -352,7 +352,6 @@ nouveau_fbcon_destroy(struct drm_device *dev, struct nouveau_fbdev *nfbdev)

if (nouveau_fb->nvbo) {
nouveau_bo_unmap(nouveau_fb->nvbo);
drm_gem_object_handle_unreference_unlocked(nouveau_fb->nvbo->gem);
drm_gem_object_unreference_unlocked(nouveau_fb->nvbo->gem);
nouveau_fb->nvbo = NULL;
}
Expand Down
1 change: 0 additions & 1 deletion trunk/drivers/gpu/drm/nouveau/nouveau_notifier.c
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,6 @@ nouveau_notifier_takedown_channel(struct nouveau_channel *chan)
mutex_lock(&dev->struct_mutex);
nouveau_bo_unpin(chan->notifier_bo);
mutex_unlock(&dev->struct_mutex);
drm_gem_object_handle_unreference_unlocked(chan->notifier_bo->gem);
drm_gem_object_unreference_unlocked(chan->notifier_bo->gem);
drm_mm_takedown(&chan->notifier_heap);
}
Expand Down
1 change: 0 additions & 1 deletion trunk/drivers/gpu/drm/radeon/radeon_fb.c
Original file line number Diff line number Diff line change
Expand Up @@ -97,7 +97,6 @@ static void radeonfb_destroy_pinned_object(struct drm_gem_object *gobj)
radeon_bo_unpin(rbo);
radeon_bo_unreserve(rbo);
}
drm_gem_object_handle_unreference(gobj);
drm_gem_object_unreference_unlocked(gobj);
}

Expand Down
83 changes: 71 additions & 12 deletions trunk/drivers/gpu/drm/ttm/ttm_bo.c
Original file line number Diff line number Diff line change
Expand Up @@ -441,6 +441,43 @@ static int ttm_bo_handle_move_mem(struct ttm_buffer_object *bo,
return ret;
}

/**
* Call bo::reserved and with the lru lock held.
* Will release GPU memory type usage on destruction.
* This is the place to put in driver specific hooks.
* Will release the bo::reserved lock and the
* lru lock on exit.
*/

static void ttm_bo_cleanup_memtype_use(struct ttm_buffer_object *bo)
{
struct ttm_bo_global *glob = bo->glob;

if (bo->ttm) {

/**
* Release the lru_lock, since we don't want to have
* an atomic requirement on ttm_tt[unbind|destroy].
*/

spin_unlock(&glob->lru_lock);
ttm_tt_unbind(bo->ttm);
ttm_tt_destroy(bo->ttm);
bo->ttm = NULL;
spin_lock(&glob->lru_lock);
}

if (bo->mem.mm_node) {
drm_mm_put_block(bo->mem.mm_node);
bo->mem.mm_node = NULL;
}

atomic_set(&bo->reserved, 0);
wake_up_all(&bo->event_queue);
spin_unlock(&glob->lru_lock);
}


/**
* If bo idle, remove from delayed- and lru lists, and unref.
* If not idle, and already on delayed list, do nothing.
Expand All @@ -456,6 +493,7 @@ static int ttm_bo_cleanup_refs(struct ttm_buffer_object *bo, bool remove_all)
int ret;

spin_lock(&bo->lock);
retry:
(void) ttm_bo_wait(bo, false, false, !remove_all);

if (!bo->sync_obj) {
Expand All @@ -464,31 +502,52 @@ static int ttm_bo_cleanup_refs(struct ttm_buffer_object *bo, bool remove_all)
spin_unlock(&bo->lock);

spin_lock(&glob->lru_lock);
put_count = ttm_bo_del_from_lru(bo);
ret = ttm_bo_reserve_locked(bo, false, !remove_all, false, 0);

/**
* Someone else has the object reserved. Bail and retry.
*/

ret = ttm_bo_reserve_locked(bo, false, false, false, 0);
BUG_ON(ret);
if (bo->ttm)
ttm_tt_unbind(bo->ttm);
if (unlikely(ret == -EBUSY)) {
spin_unlock(&glob->lru_lock);
spin_lock(&bo->lock);
goto requeue;
}

/**
* We can re-check for sync object without taking
* the bo::lock since setting the sync object requires
* also bo::reserved. A busy object at this point may
* be caused by another thread starting an accelerated
* eviction.
*/

if (unlikely(bo->sync_obj)) {
atomic_set(&bo->reserved, 0);
wake_up_all(&bo->event_queue);
spin_unlock(&glob->lru_lock);
spin_lock(&bo->lock);
if (remove_all)
goto retry;
else
goto requeue;
}

put_count = ttm_bo_del_from_lru(bo);

if (!list_empty(&bo->ddestroy)) {
list_del_init(&bo->ddestroy);
++put_count;
}
if (bo->mem.mm_node) {
drm_mm_put_block(bo->mem.mm_node);
bo->mem.mm_node = NULL;
}
spin_unlock(&glob->lru_lock);

atomic_set(&bo->reserved, 0);
ttm_bo_cleanup_memtype_use(bo);

while (put_count--)
kref_put(&bo->list_kref, ttm_bo_ref_bug);

return 0;
}

requeue:
spin_lock(&glob->lru_lock);
if (list_empty(&bo->ddestroy)) {
void *sync_obj = bo->sync_obj;
Expand Down
Loading

0 comments on commit 87e295a

Please sign in to comment.