Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 232978
b: refs/heads/master
c: eee4da2
h: refs/heads/master
v: v3
  • Loading branch information
Linus Torvalds committed Feb 7, 2011
1 parent 07fdbd0 commit e489618
Show file tree
Hide file tree
Showing 18 changed files with 93 additions and 67 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: 57cdfdf829a850a317425ed93c6a576c9ee6329c
refs/heads/master: eee4da2cef8e2dc2b15066e9ebb5b2ff63396eb3
24 changes: 12 additions & 12 deletions trunk/arch/arm/mach-omap1/lcd_dma.c
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ int omap_lcd_dma_running(void)
* On OMAP1510, internal LCD controller will start the transfer
* when it gets enabled, so assume DMA running if LCD enabled.
*/
if (cpu_is_omap1510())
if (cpu_is_omap15xx())
if (omap_readw(OMAP_LCDC_CONTROL) & OMAP_LCDC_CTRL_LCD_EN)
return 1;

Expand Down Expand Up @@ -95,7 +95,7 @@ EXPORT_SYMBOL(omap_set_lcd_dma_single_transfer);

void omap_set_lcd_dma_b1_rotation(int rotate)
{
if (cpu_is_omap1510()) {
if (cpu_is_omap15xx()) {
printk(KERN_ERR "DMA rotation is not supported in 1510 mode\n");
BUG();
return;
Expand All @@ -106,7 +106,7 @@ EXPORT_SYMBOL(omap_set_lcd_dma_b1_rotation);

void omap_set_lcd_dma_b1_mirror(int mirror)
{
if (cpu_is_omap1510()) {
if (cpu_is_omap15xx()) {
printk(KERN_ERR "DMA mirror is not supported in 1510 mode\n");
BUG();
}
Expand All @@ -116,7 +116,7 @@ EXPORT_SYMBOL(omap_set_lcd_dma_b1_mirror);

void omap_set_lcd_dma_b1_vxres(unsigned long vxres)
{
if (cpu_is_omap1510()) {
if (cpu_is_omap15xx()) {
printk(KERN_ERR "DMA virtual resulotion is not supported "
"in 1510 mode\n");
BUG();
Expand All @@ -127,7 +127,7 @@ EXPORT_SYMBOL(omap_set_lcd_dma_b1_vxres);

void omap_set_lcd_dma_b1_scale(unsigned int xscale, unsigned int yscale)
{
if (cpu_is_omap1510()) {
if (cpu_is_omap15xx()) {
printk(KERN_ERR "DMA scale is not supported in 1510 mode\n");
BUG();
}
Expand Down Expand Up @@ -177,7 +177,7 @@ static void set_b1_regs(void)
bottom = PIXADDR(lcd_dma.xres - 1, lcd_dma.yres - 1);
/* 1510 DMA requires the bottom address to be 2 more
* than the actual last memory access location. */
if (cpu_is_omap1510() &&
if (cpu_is_omap15xx() &&
lcd_dma.data_type == OMAP_DMA_DATA_TYPE_S32)
bottom += 2;
ei = PIXSTEP(0, 0, 1, 0);
Expand Down Expand Up @@ -241,7 +241,7 @@ static void set_b1_regs(void)
return; /* Suppress warning about uninitialized vars */
}

if (cpu_is_omap1510()) {
if (cpu_is_omap15xx()) {
omap_writew(top >> 16, OMAP1510_DMA_LCD_TOP_F1_U);
omap_writew(top, OMAP1510_DMA_LCD_TOP_F1_L);
omap_writew(bottom >> 16, OMAP1510_DMA_LCD_BOT_F1_U);
Expand Down Expand Up @@ -343,7 +343,7 @@ void omap_free_lcd_dma(void)
BUG();
return;
}
if (!cpu_is_omap1510())
if (!cpu_is_omap15xx())
omap_writew(omap_readw(OMAP1610_DMA_LCD_CCR) & ~1,
OMAP1610_DMA_LCD_CCR);
lcd_dma.reserved = 0;
Expand All @@ -360,7 +360,7 @@ void omap_enable_lcd_dma(void)
* connected. Otherwise the OMAP internal controller will
* start the transfer when it gets enabled.
*/
if (cpu_is_omap1510() || !lcd_dma.ext_ctrl)
if (cpu_is_omap15xx() || !lcd_dma.ext_ctrl)
return;

w = omap_readw(OMAP1610_DMA_LCD_CTRL);
Expand All @@ -378,14 +378,14 @@ EXPORT_SYMBOL(omap_enable_lcd_dma);
void omap_setup_lcd_dma(void)
{
BUG_ON(lcd_dma.active);
if (!cpu_is_omap1510()) {
if (!cpu_is_omap15xx()) {
/* Set some reasonable defaults */
omap_writew(0x5440, OMAP1610_DMA_LCD_CCR);
omap_writew(0x9102, OMAP1610_DMA_LCD_CSDP);
omap_writew(0x0004, OMAP1610_DMA_LCD_LCH_CTRL);
}
set_b1_regs();
if (!cpu_is_omap1510()) {
if (!cpu_is_omap15xx()) {
u16 w;

w = omap_readw(OMAP1610_DMA_LCD_CCR);
Expand All @@ -407,7 +407,7 @@ void omap_stop_lcd_dma(void)
u16 w;

lcd_dma.active = 0;
if (cpu_is_omap1510() || !lcd_dma.ext_ctrl)
if (cpu_is_omap15xx() || !lcd_dma.ext_ctrl)
return;

w = omap_readw(OMAP1610_DMA_LCD_CCR);
Expand Down
1 change: 0 additions & 1 deletion trunk/arch/arm/mach-omap1/time.c
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,6 @@
#include <linux/clocksource.h>
#include <linux/clockchips.h>
#include <linux/io.h>
#include <linux/sched.h>

#include <asm/system.h>
#include <mach/hardware.h>
Expand Down
27 changes: 16 additions & 11 deletions trunk/arch/arm/mach-omap2/board-devkit8000.c
Original file line number Diff line number Diff line change
Expand Up @@ -115,9 +115,6 @@ static struct omap2_hsmmc_info mmc[] = {

static int devkit8000_panel_enable_lcd(struct omap_dss_device *dssdev)
{
twl_i2c_write_u8(TWL4030_MODULE_GPIO, 0x80, REG_GPIODATADIR1);
twl_i2c_write_u8(TWL4030_MODULE_LED, 0x0, 0x0);

if (gpio_is_valid(dssdev->reset_gpio))
gpio_set_value_cansleep(dssdev->reset_gpio, 1);
return 0;
Expand Down Expand Up @@ -247,6 +244,8 @@ static struct gpio_led gpio_leds[];
static int devkit8000_twl_gpio_setup(struct device *dev,
unsigned gpio, unsigned ngpio)
{
int ret;

omap_mux_init_gpio(29, OMAP_PIN_INPUT);
/* gpio + 0 is "mmc0_cd" (input/IRQ) */
mmc[0].gpio_cd = gpio + 0;
Expand All @@ -255,17 +254,23 @@ static int devkit8000_twl_gpio_setup(struct device *dev,
/* TWL4030_GPIO_MAX + 1 == ledB, PMU_STAT (out, active low LED) */
gpio_leds[2].gpio = gpio + TWL4030_GPIO_MAX + 1;

/* gpio + 1 is "LCD_PWREN" (out, active high) */
devkit8000_lcd_device.reset_gpio = gpio + 1;
gpio_request(devkit8000_lcd_device.reset_gpio, "LCD_PWREN");
/* Disable until needed */
gpio_direction_output(devkit8000_lcd_device.reset_gpio, 0);
/* TWL4030_GPIO_MAX + 0 is "LCD_PWREN" (out, active high) */
devkit8000_lcd_device.reset_gpio = gpio + TWL4030_GPIO_MAX + 0;
ret = gpio_request_one(devkit8000_lcd_device.reset_gpio,
GPIOF_DIR_OUT | GPIOF_INIT_LOW, "LCD_PWREN");
if (ret < 0) {
devkit8000_lcd_device.reset_gpio = -EINVAL;
printk(KERN_ERR "Failed to request GPIO for LCD_PWRN\n");
}

/* gpio + 7 is "DVI_PD" (out, active low) */
devkit8000_dvi_device.reset_gpio = gpio + 7;
gpio_request(devkit8000_dvi_device.reset_gpio, "DVI PowerDown");
/* Disable until needed */
gpio_direction_output(devkit8000_dvi_device.reset_gpio, 0);
ret = gpio_request_one(devkit8000_dvi_device.reset_gpio,
GPIOF_DIR_OUT | GPIOF_INIT_LOW, "DVI PowerDown");
if (ret < 0) {
devkit8000_dvi_device.reset_gpio = -EINVAL;
printk(KERN_ERR "Failed to request GPIO for DVI PowerDown\n");
}

return 0;
}
Expand Down
2 changes: 0 additions & 2 deletions trunk/arch/arm/mach-omap2/board-omap4panda.c
Original file line number Diff line number Diff line change
Expand Up @@ -409,8 +409,6 @@ static void __init omap4_panda_init(void)
platform_add_devices(panda_devices, ARRAY_SIZE(panda_devices));
omap_serial_init();
omap4_twl6030_hsmmc_init(mmc);
/* OMAP4 Panda uses internal transceiver so register nop transceiver */
usb_nop_xceiv_register();
omap4_ehci_init();
usb_musb_init(&musb_board_data);
}
Expand Down
3 changes: 0 additions & 3 deletions trunk/arch/arm/mach-omap2/board-rm680.c
Original file line number Diff line number Diff line change
Expand Up @@ -40,9 +40,6 @@ static struct regulator_consumer_supply rm680_vemmc_consumers[] = {
static struct regulator_init_data rm680_vemmc = {
.constraints = {
.name = "rm680_vemmc",
.min_uV = 2900000,
.max_uV = 2900000,
.apply_uV = 1,
.valid_modes_mask = REGULATOR_MODE_NORMAL
| REGULATOR_MODE_STANDBY,
.valid_ops_mask = REGULATOR_CHANGE_STATUS
Expand Down
1 change: 1 addition & 0 deletions trunk/arch/arm/mach-omap2/mux.c
Original file line number Diff line number Diff line change
Expand Up @@ -1000,6 +1000,7 @@ int __init omap_mux_init(const char *name, u32 flags,
if (!partition->base) {
pr_err("%s: Could not ioremap mux partition at 0x%08x\n",
__func__, partition->phys);
kfree(partition);
return -ENODEV;
}

Expand Down
7 changes: 4 additions & 3 deletions trunk/arch/arm/mach-omap2/pm34xx.c
Original file line number Diff line number Diff line change
Expand Up @@ -168,9 +168,10 @@ static void omap3_core_restore_context(void)
* once during boot sequence, but this works as we are not using secure
* services.
*/
static void omap3_save_secure_ram_context(u32 target_mpu_state)
static void omap3_save_secure_ram_context(void)
{
u32 ret;
int mpu_next_state = pwrdm_read_next_pwrst(mpu_pwrdm);

if (omap_type() != OMAP2_DEVICE_TYPE_GP) {
/*
Expand All @@ -181,7 +182,7 @@ static void omap3_save_secure_ram_context(u32 target_mpu_state)
pwrdm_set_next_pwrst(mpu_pwrdm, PWRDM_POWER_ON);
ret = _omap_save_secure_sram((u32 *)
__pa(omap3_secure_ram_storage));
pwrdm_set_next_pwrst(mpu_pwrdm, target_mpu_state);
pwrdm_set_next_pwrst(mpu_pwrdm, mpu_next_state);
/* Following is for error tracking, it should not happen */
if (ret) {
printk(KERN_ERR "save_secure_sram() returns %08x\n",
Expand Down Expand Up @@ -1094,7 +1095,7 @@ static int __init omap3_pm_init(void)
local_fiq_disable();

omap_dma_global_context_save();
omap3_save_secure_ram_context(PWRDM_POWER_ON);
omap3_save_secure_ram_context();
omap_dma_global_context_restore();

local_irq_enable();
Expand Down
11 changes: 5 additions & 6 deletions trunk/arch/arm/mach-omap2/smartreflex.c
Original file line number Diff line number Diff line change
Expand Up @@ -780,8 +780,7 @@ static int omap_sr_autocomp_show(void *data, u64 *val)
struct omap_sr *sr_info = (struct omap_sr *) data;

if (!sr_info) {
pr_warning("%s: omap_sr struct for sr_%s not found\n",
__func__, sr_info->voltdm->name);
pr_warning("%s: omap_sr struct not found\n", __func__);
return -EINVAL;
}

Expand All @@ -795,8 +794,7 @@ static int omap_sr_autocomp_store(void *data, u64 val)
struct omap_sr *sr_info = (struct omap_sr *) data;

if (!sr_info) {
pr_warning("%s: omap_sr struct for sr_%s not found\n",
__func__, sr_info->voltdm->name);
pr_warning("%s: omap_sr struct not found\n", __func__);
return -EINVAL;
}

Expand Down Expand Up @@ -834,7 +832,8 @@ static int __init omap_sr_probe(struct platform_device *pdev)

if (!pdata) {
dev_err(&pdev->dev, "%s: platform data missing\n", __func__);
return -EINVAL;
ret = -EINVAL;
goto err_free_devinfo;
}

mem = platform_get_resource(pdev, IORESOURCE_MEM, 0);
Expand Down Expand Up @@ -966,7 +965,7 @@ static int __devexit omap_sr_remove(struct platform_device *pdev)
}

sr_info = _sr_lookup(pdata->voltdm);
if (!sr_info) {
if (IS_ERR(sr_info)) {
dev_warn(&pdev->dev, "%s: omap_sr struct not found\n",
__func__);
return -EINVAL;
Expand Down
1 change: 1 addition & 0 deletions trunk/arch/arm/mach-omap2/voltage.c
Original file line number Diff line number Diff line change
Expand Up @@ -471,6 +471,7 @@ static void __init vdd_debugfs_init(struct omap_vdd_info *vdd)
strcat(name, vdd->voltdm.name);

vdd->debug_dir = debugfs_create_dir(name, voltage_dir);
kfree(name);
if (IS_ERR(vdd->debug_dir)) {
pr_warning("%s: Unable to create debugfs directory for"
" vdd_%s\n", __func__, vdd->voltdm.name);
Expand Down
13 changes: 10 additions & 3 deletions trunk/arch/x86/kernel/acpi/sleep.c
Original file line number Diff line number Diff line change
Expand Up @@ -12,10 +12,8 @@
#include <linux/cpumask.h>
#include <asm/segment.h>
#include <asm/desc.h>

#ifdef CONFIG_X86_32
#include <asm/pgtable.h>
#endif
#include <asm/cacheflush.h>

#include "realmode/wakeup.h"
#include "sleep.h"
Expand Down Expand Up @@ -149,6 +147,15 @@ void __init acpi_reserve_wakeup_memory(void)
memblock_x86_reserve_range(mem, mem + WAKEUP_SIZE, "ACPI WAKEUP");
}

int __init acpi_configure_wakeup_memory(void)
{
if (acpi_realmode)
set_memory_x(acpi_realmode, WAKEUP_SIZE >> PAGE_SHIFT);

return 0;
}
arch_initcall(acpi_configure_wakeup_memory);


static int __init acpi_sleep_setup(char *str)
{
Expand Down
4 changes: 4 additions & 0 deletions trunk/fs/cifs/cifsacl.c
Original file line number Diff line number Diff line change
Expand Up @@ -372,6 +372,10 @@ static void parse_dacl(struct cifs_acl *pdacl, char *end_of_acl,

ppace = kmalloc(num_aces * sizeof(struct cifs_ace *),
GFP_KERNEL);
if (!ppace) {
cERROR(1, "DACL memory allocation error");
return;
}

for (i = 0; i < num_aces; ++i) {
ppace[i] = (struct cifs_ace *) (acl_base + acl_size);
Expand Down
5 changes: 1 addition & 4 deletions trunk/fs/cifs/cifssmb.c
Original file line number Diff line number Diff line change
Expand Up @@ -136,9 +136,6 @@ cifs_reconnect_tcon(struct cifsTconInfo *tcon, int smb_command)
}
}

if (ses->status == CifsExiting)
return -EIO;

/*
* Give demultiplex thread up to 10 seconds to reconnect, should be
* greater than cifs socket timeout which is 7 seconds
Expand All @@ -156,7 +153,7 @@ cifs_reconnect_tcon(struct cifsTconInfo *tcon, int smb_command)
* retrying until process is killed or server comes
* back on-line
*/
if (!tcon->retry || ses->status == CifsExiting) {
if (!tcon->retry) {
cFYI(1, "gave up waiting on reconnect in smb_init");
return -EHOSTDOWN;
}
Expand Down
22 changes: 13 additions & 9 deletions trunk/fs/cifs/connect.c
Original file line number Diff line number Diff line change
Expand Up @@ -337,8 +337,12 @@ cifs_echo_request(struct work_struct *work)
struct TCP_Server_Info *server = container_of(work,
struct TCP_Server_Info, echo.work);

/* no need to ping if we got a response recently */
if (time_before(jiffies, server->lstrp + SMB_ECHO_INTERVAL - HZ))
/*
* We cannot send an echo until the NEGOTIATE_PROTOCOL request is done.
* Also, no need to ping if we got a response recently
*/
if (server->tcpStatus != CifsGood ||
time_before(jiffies, server->lstrp + SMB_ECHO_INTERVAL - HZ))
goto requeue_echo;

rc = CIFSSMBEcho(server);
Expand Down Expand Up @@ -578,12 +582,12 @@ cifs_demultiplex_thread(struct TCP_Server_Info *server)
else if (reconnect == 1)
continue;

length += 4; /* account for rfc1002 hdr */
total_read += 4; /* account for rfc1002 hdr */


dump_smb(smb_buffer, length);
if (checkSMB(smb_buffer, smb_buffer->Mid, total_read+4)) {
cifs_dump_mem("Bad SMB: ", smb_buffer, 48);
dump_smb(smb_buffer, total_read);
if (checkSMB(smb_buffer, smb_buffer->Mid, total_read)) {
cifs_dump_mem("Bad SMB: ", smb_buffer,
total_read < 48 ? total_read : 48);
continue;
}

Expand Down Expand Up @@ -633,11 +637,11 @@ cifs_demultiplex_thread(struct TCP_Server_Info *server)
mid_entry->largeBuf = isLargeBuf;
multi_t2_fnd:
mid_entry->midState = MID_RESPONSE_RECEIVED;
list_del_init(&mid_entry->qhead);
mid_entry->callback(mid_entry);
#ifdef CONFIG_CIFS_STATS2
mid_entry->when_received = jiffies;
#endif
list_del_init(&mid_entry->qhead);
mid_entry->callback(mid_entry);
break;
}
mid_entry = NULL;
Expand Down
Loading

0 comments on commit e489618

Please sign in to comment.