diff options
| -rw-r--r-- | Documentation/filesystems/tmpfs.txt | 2 | ||||
| -rw-r--r-- | MAINTAINERS | 8 | ||||
| -rw-r--r-- | arch/mips/include/asm/uaccess.h | 2 | ||||
| -rw-r--r-- | arch/mips/sgi-ip32/ip32-reset.c | 7 | ||||
| -rw-r--r-- | arch/powerpc/platforms/maple/pci.c | 14 | ||||
| -rw-r--r-- | arch/sh/boards/board-ap325rxa.c | 3 | ||||
| -rw-r--r-- | drivers/char/ipmi/ipmi_msghandler.c | 13 | ||||
| -rw-r--r-- | drivers/ide/ide-io.c | 4 | ||||
| -rw-r--r-- | drivers/ide/ide-iops.c | 21 | ||||
| -rw-r--r-- | drivers/ide/ide-lib.c | 27 | ||||
| -rw-r--r-- | drivers/ide/ide-probe.c | 9 | ||||
| -rw-r--r-- | drivers/ide/via82cxxx.c | 2 | ||||
| -rw-r--r-- | drivers/pci/pci.c | 3 | ||||
| -rw-r--r-- | drivers/video/sh_mobile_lcdcfb.c | 7 | ||||
| -rw-r--r-- | fs/cifs/dir.c | 14 | ||||
| -rw-r--r-- | fs/cifs/file.c | 66 | ||||
| -rw-r--r-- | fs/nilfs2/ioctl.c | 2 | ||||
| -rw-r--r-- | include/linux/ide.h | 2 | ||||
| -rw-r--r-- | include/linux/pci_ids.h | 2 | ||||
| -rw-r--r-- | mm/rmap.c | 2 |
20 files changed, 127 insertions, 83 deletions
diff --git a/Documentation/filesystems/tmpfs.txt b/Documentation/filesystems/tmpfs.txt index 222437efd75a..3015da0c6b2a 100644 --- a/Documentation/filesystems/tmpfs.txt +++ b/Documentation/filesystems/tmpfs.txt | |||
| @@ -133,4 +133,4 @@ RAM/SWAP in 10240 inodes and it is only accessible by root. | |||
| 133 | Author: | 133 | Author: |
| 134 | Christoph Rohland <cr@sap.com>, 1.12.01 | 134 | Christoph Rohland <cr@sap.com>, 1.12.01 |
| 135 | Updated: | 135 | Updated: |
| 136 | Hugh Dickins <hugh@veritas.com>, 4 June 2007 | 136 | Hugh Dickins, 4 June 2007 |
diff --git a/MAINTAINERS b/MAINTAINERS index 2b349ba4add4..64ea80e45e3b 100644 --- a/MAINTAINERS +++ b/MAINTAINERS | |||
| @@ -5579,6 +5579,14 @@ M: ian@mnementh.co.uk | |||
| 5579 | S: Maintained | 5579 | S: Maintained |
| 5580 | F: drivers/mmc/host/tmio_mmc.* | 5580 | F: drivers/mmc/host/tmio_mmc.* |
| 5581 | 5581 | ||
| 5582 | TMPFS (SHMEM FILESYSTEM) | ||
| 5583 | P: Hugh Dickins | ||
| 5584 | M: hugh.dickins@tiscali.co.uk | ||
| 5585 | L: linux-mm@kvack.org | ||
| 5586 | S: Maintained | ||
| 5587 | F: include/linux/shmem_fs.h | ||
| 5588 | F: mm/shmem.c | ||
| 5589 | |||
| 5582 | TPM DEVICE DRIVER | 5590 | TPM DEVICE DRIVER |
| 5583 | P: Debora Velarde | 5591 | P: Debora Velarde |
| 5584 | M: debora@linux.vnet.ibm.com | 5592 | M: debora@linux.vnet.ibm.com |
diff --git a/arch/mips/include/asm/uaccess.h b/arch/mips/include/asm/uaccess.h index 8de858f5449f..c2d53c18fd36 100644 --- a/arch/mips/include/asm/uaccess.h +++ b/arch/mips/include/asm/uaccess.h | |||
| @@ -956,7 +956,7 @@ __clear_user(void __user *addr, __kernel_size_t size) | |||
| 956 | void __user * __cl_addr = (addr); \ | 956 | void __user * __cl_addr = (addr); \ |
| 957 | unsigned long __cl_size = (n); \ | 957 | unsigned long __cl_size = (n); \ |
| 958 | if (__cl_size && access_ok(VERIFY_WRITE, \ | 958 | if (__cl_size && access_ok(VERIFY_WRITE, \ |
| 959 | ((unsigned long)(__cl_addr)), __cl_size)) \ | 959 | __cl_addr, __cl_size)) \ |
| 960 | __cl_size = __clear_user(__cl_addr, __cl_size); \ | 960 | __cl_size = __clear_user(__cl_addr, __cl_size); \ |
| 961 | __cl_size; \ | 961 | __cl_size; \ |
| 962 | }) | 962 | }) |
diff --git a/arch/mips/sgi-ip32/ip32-reset.c b/arch/mips/sgi-ip32/ip32-reset.c index 667da932b7b2..9b95d80ebc6e 100644 --- a/arch/mips/sgi-ip32/ip32-reset.c +++ b/arch/mips/sgi-ip32/ip32-reset.c | |||
| @@ -53,7 +53,7 @@ static inline void ip32_machine_halt(void) | |||
| 53 | 53 | ||
| 54 | static void ip32_machine_power_off(void) | 54 | static void ip32_machine_power_off(void) |
| 55 | { | 55 | { |
| 56 | volatile unsigned char reg_a, xctrl_a, xctrl_b; | 56 | unsigned char reg_a, xctrl_a, xctrl_b; |
| 57 | 57 | ||
| 58 | disable_irq(MACEISA_RTC_IRQ); | 58 | disable_irq(MACEISA_RTC_IRQ); |
| 59 | reg_a = CMOS_READ(RTC_REG_A); | 59 | reg_a = CMOS_READ(RTC_REG_A); |
| @@ -91,9 +91,10 @@ static void blink_timeout(unsigned long data) | |||
| 91 | 91 | ||
| 92 | static void debounce(unsigned long data) | 92 | static void debounce(unsigned long data) |
| 93 | { | 93 | { |
| 94 | volatile unsigned char reg_a, reg_c, xctrl_a; | 94 | unsigned char reg_a, reg_c, xctrl_a; |
| 95 | 95 | ||
| 96 | reg_c = CMOS_READ(RTC_INTR_FLAGS); | 96 | reg_c = CMOS_READ(RTC_INTR_FLAGS); |
| 97 | reg_a = CMOS_READ(RTC_REG_A); | ||
| 97 | CMOS_WRITE(reg_a | DS_REGA_DV0, RTC_REG_A); | 98 | CMOS_WRITE(reg_a | DS_REGA_DV0, RTC_REG_A); |
| 98 | wbflush(); | 99 | wbflush(); |
| 99 | xctrl_a = CMOS_READ(DS_B1_XCTRL4A); | 100 | xctrl_a = CMOS_READ(DS_B1_XCTRL4A); |
| @@ -137,7 +138,7 @@ static inline void ip32_power_button(void) | |||
| 137 | 138 | ||
| 138 | static irqreturn_t ip32_rtc_int(int irq, void *dev_id) | 139 | static irqreturn_t ip32_rtc_int(int irq, void *dev_id) |
| 139 | { | 140 | { |
| 140 | volatile unsigned char reg_c; | 141 | unsigned char reg_c; |
| 141 | 142 | ||
| 142 | reg_c = CMOS_READ(RTC_INTR_FLAGS); | 143 | reg_c = CMOS_READ(RTC_INTR_FLAGS); |
| 143 | if (!(reg_c & RTC_IRQF)) { | 144 | if (!(reg_c & RTC_IRQF)) { |
diff --git a/arch/powerpc/platforms/maple/pci.c b/arch/powerpc/platforms/maple/pci.c index 301855263b81..04296ffff8bf 100644 --- a/arch/powerpc/platforms/maple/pci.c +++ b/arch/powerpc/platforms/maple/pci.c | |||
| @@ -592,3 +592,17 @@ int maple_pci_get_legacy_ide_irq(struct pci_dev *pdev, int channel) | |||
| 592 | } | 592 | } |
| 593 | return irq; | 593 | return irq; |
| 594 | } | 594 | } |
| 595 | |||
| 596 | static void __devinit quirk_ipr_msi(struct pci_dev *dev) | ||
| 597 | { | ||
| 598 | /* Something prevents MSIs from the IPR from working on Bimini, | ||
| 599 | * and the driver has no smarts to recover. So disable MSI | ||
| 600 | * on it for now. */ | ||
| 601 | |||
| 602 | if (machine_is(maple)) { | ||
| 603 | dev->no_msi = 1; | ||
| 604 | dev_info(&dev->dev, "Quirk disabled MSI\n"); | ||
| 605 | } | ||
| 606 | } | ||
| 607 | DECLARE_PCI_FIXUP_FINAL(PCI_VENDOR_ID_IBM, PCI_DEVICE_ID_IBM_OBSIDIAN, | ||
| 608 | quirk_ipr_msi); | ||
diff --git a/arch/sh/boards/board-ap325rxa.c b/arch/sh/boards/board-ap325rxa.c index 39e46919df14..f2a29641b6a3 100644 --- a/arch/sh/boards/board-ap325rxa.c +++ b/arch/sh/boards/board-ap325rxa.c | |||
| @@ -263,6 +263,9 @@ static int camera_probe(void) | |||
| 263 | struct i2c_msg msg; | 263 | struct i2c_msg msg; |
| 264 | int ret; | 264 | int ret; |
| 265 | 265 | ||
| 266 | if (!a) | ||
| 267 | return -ENODEV; | ||
| 268 | |||
| 266 | camera_power(1); | 269 | camera_power(1); |
| 267 | msg.addr = 0x6e; | 270 | msg.addr = 0x6e; |
| 268 | msg.buf = camera_ncm03j_magic; | 271 | msg.buf = camera_ncm03j_magic; |
diff --git a/drivers/char/ipmi/ipmi_msghandler.c b/drivers/char/ipmi/ipmi_msghandler.c index aa83a0865ec1..09050797c76a 100644 --- a/drivers/char/ipmi/ipmi_msghandler.c +++ b/drivers/char/ipmi/ipmi_msghandler.c | |||
| @@ -2856,6 +2856,7 @@ int ipmi_register_smi(struct ipmi_smi_handlers *handlers, | |||
| 2856 | /* Assume a single IPMB channel at zero. */ | 2856 | /* Assume a single IPMB channel at zero. */ |
| 2857 | intf->channels[0].medium = IPMI_CHANNEL_MEDIUM_IPMB; | 2857 | intf->channels[0].medium = IPMI_CHANNEL_MEDIUM_IPMB; |
| 2858 | intf->channels[0].protocol = IPMI_CHANNEL_PROTOCOL_IPMB; | 2858 | intf->channels[0].protocol = IPMI_CHANNEL_PROTOCOL_IPMB; |
| 2859 | intf->curr_channel = IPMI_MAX_CHANNELS; | ||
| 2859 | } | 2860 | } |
| 2860 | 2861 | ||
| 2861 | if (rv == 0) | 2862 | if (rv == 0) |
| @@ -3648,13 +3649,13 @@ static int handle_new_recv_msg(ipmi_smi_t intf, | |||
| 3648 | } | 3649 | } |
| 3649 | 3650 | ||
| 3650 | /* | 3651 | /* |
| 3651 | ** We need to make sure the channels have been initialized. | 3652 | * We need to make sure the channels have been initialized. |
| 3652 | ** The channel_handler routine will set the "curr_channel" | 3653 | * The channel_handler routine will set the "curr_channel" |
| 3653 | ** equal to or greater than IPMI_MAX_CHANNELS when all the | 3654 | * equal to or greater than IPMI_MAX_CHANNELS when all the |
| 3654 | ** channels for this interface have been initialized. | 3655 | * channels for this interface have been initialized. |
| 3655 | */ | 3656 | */ |
| 3656 | if (intf->curr_channel < IPMI_MAX_CHANNELS) { | 3657 | if (intf->curr_channel < IPMI_MAX_CHANNELS) { |
| 3657 | requeue = 1; /* Just put the message back for now */ | 3658 | requeue = 0; /* Throw the message away */ |
| 3658 | goto out; | 3659 | goto out; |
| 3659 | } | 3660 | } |
| 3660 | 3661 | ||
diff --git a/drivers/ide/ide-io.c b/drivers/ide/ide-io.c index 35dc38d3b2c5..6415a2e2ba87 100644 --- a/drivers/ide/ide-io.c +++ b/drivers/ide/ide-io.c | |||
| @@ -696,7 +696,7 @@ void ide_timer_expiry (unsigned long data) | |||
| 696 | } | 696 | } |
| 697 | spin_lock_irq(&hwif->lock); | 697 | spin_lock_irq(&hwif->lock); |
| 698 | enable_irq(hwif->irq); | 698 | enable_irq(hwif->irq); |
| 699 | if (startstop == ide_stopped) { | 699 | if (startstop == ide_stopped && hwif->polling == 0) { |
| 700 | ide_unlock_port(hwif); | 700 | ide_unlock_port(hwif); |
| 701 | plug_device = 1; | 701 | plug_device = 1; |
| 702 | } | 702 | } |
| @@ -868,7 +868,7 @@ irqreturn_t ide_intr (int irq, void *dev_id) | |||
| 868 | * same irq as is currently being serviced here, and Linux | 868 | * same irq as is currently being serviced here, and Linux |
| 869 | * won't allow another of the same (on any CPU) until we return. | 869 | * won't allow another of the same (on any CPU) until we return. |
| 870 | */ | 870 | */ |
| 871 | if (startstop == ide_stopped) { | 871 | if (startstop == ide_stopped && hwif->polling == 0) { |
| 872 | BUG_ON(hwif->handler); | 872 | BUG_ON(hwif->handler); |
| 873 | ide_unlock_port(hwif); | 873 | ide_unlock_port(hwif); |
| 874 | plug_device = 1; | 874 | plug_device = 1; |
diff --git a/drivers/ide/ide-iops.c b/drivers/ide/ide-iops.c index c19a221b1e18..06fe002116ec 100644 --- a/drivers/ide/ide-iops.c +++ b/drivers/ide/ide-iops.c | |||
| @@ -206,8 +206,6 @@ EXPORT_SYMBOL_GPL(ide_in_drive_list); | |||
| 206 | 206 | ||
| 207 | /* | 207 | /* |
| 208 | * Early UDMA66 devices don't set bit14 to 1, only bit13 is valid. | 208 | * Early UDMA66 devices don't set bit14 to 1, only bit13 is valid. |
| 209 | * We list them here and depend on the device side cable detection for them. | ||
| 210 | * | ||
| 211 | * Some optical devices with the buggy firmwares have the same problem. | 209 | * Some optical devices with the buggy firmwares have the same problem. |
| 212 | */ | 210 | */ |
| 213 | static const struct drive_list_entry ivb_list[] = { | 211 | static const struct drive_list_entry ivb_list[] = { |
| @@ -251,10 +249,25 @@ u8 eighty_ninty_three(ide_drive_t *drive) | |||
| 251 | * - force bit13 (80c cable present) check also for !ivb devices | 249 | * - force bit13 (80c cable present) check also for !ivb devices |
| 252 | * (unless the slave device is pre-ATA3) | 250 | * (unless the slave device is pre-ATA3) |
| 253 | */ | 251 | */ |
| 254 | if ((id[ATA_ID_HW_CONFIG] & 0x4000) || | 252 | if (id[ATA_ID_HW_CONFIG] & 0x4000) |
| 255 | (ivb && (id[ATA_ID_HW_CONFIG] & 0x2000))) | ||
| 256 | return 1; | 253 | return 1; |
| 257 | 254 | ||
| 255 | if (ivb) { | ||
| 256 | const char *model = (char *)&id[ATA_ID_PROD]; | ||
| 257 | |||
| 258 | if (strstr(model, "TSSTcorp CDDVDW SH-S202")) { | ||
| 259 | /* | ||
| 260 | * These ATAPI devices always report 80c cable | ||
| 261 | * so we have to depend on the host in this case. | ||
| 262 | */ | ||
| 263 | if (hwif->cbl == ATA_CBL_PATA80) | ||
| 264 | return 1; | ||
| 265 | } else { | ||
| 266 | /* Depend on the device side cable detection. */ | ||
| 267 | if (id[ATA_ID_HW_CONFIG] & 0x2000) | ||
| 268 | return 1; | ||
| 269 | } | ||
| 270 | } | ||
| 258 | no_80w: | 271 | no_80w: |
| 259 | if (drive->dev_flags & IDE_DFLAG_UDMA33_WARNED) | 272 | if (drive->dev_flags & IDE_DFLAG_UDMA33_WARNED) |
| 260 | return 0; | 273 | return 0; |
diff --git a/drivers/ide/ide-lib.c b/drivers/ide/ide-lib.c index 56ff8c46c7d1..2148df836ce7 100644 --- a/drivers/ide/ide-lib.c +++ b/drivers/ide/ide-lib.c | |||
| @@ -31,24 +31,6 @@ void ide_toggle_bounce(ide_drive_t *drive, int on) | |||
| 31 | blk_queue_bounce_limit(drive->queue, addr); | 31 | blk_queue_bounce_limit(drive->queue, addr); |
| 32 | } | 32 | } |
| 33 | 33 | ||
| 34 | static void ide_dump_opcode(ide_drive_t *drive) | ||
| 35 | { | ||
| 36 | struct request *rq = drive->hwif->rq; | ||
| 37 | struct ide_cmd *cmd = NULL; | ||
| 38 | |||
| 39 | if (!rq) | ||
| 40 | return; | ||
| 41 | |||
| 42 | if (rq->cmd_type == REQ_TYPE_ATA_TASKFILE) | ||
| 43 | cmd = rq->special; | ||
| 44 | |||
| 45 | printk(KERN_ERR "ide: failed opcode was: "); | ||
| 46 | if (cmd == NULL) | ||
| 47 | printk(KERN_CONT "unknown\n"); | ||
| 48 | else | ||
| 49 | printk(KERN_CONT "0x%02x\n", cmd->tf.command); | ||
| 50 | } | ||
| 51 | |||
| 52 | u64 ide_get_lba_addr(struct ide_cmd *cmd, int lba48) | 34 | u64 ide_get_lba_addr(struct ide_cmd *cmd, int lba48) |
| 53 | { | 35 | { |
| 54 | struct ide_taskfile *tf = &cmd->tf; | 36 | struct ide_taskfile *tf = &cmd->tf; |
| @@ -91,7 +73,7 @@ static void ide_dump_sector(ide_drive_t *drive) | |||
| 91 | 73 | ||
| 92 | static void ide_dump_ata_error(ide_drive_t *drive, u8 err) | 74 | static void ide_dump_ata_error(ide_drive_t *drive, u8 err) |
| 93 | { | 75 | { |
| 94 | printk(KERN_ERR "{ "); | 76 | printk(KERN_CONT "{ "); |
| 95 | if (err & ATA_ABORTED) | 77 | if (err & ATA_ABORTED) |
| 96 | printk(KERN_CONT "DriveStatusError "); | 78 | printk(KERN_CONT "DriveStatusError "); |
| 97 | if (err & ATA_ICRC) | 79 | if (err & ATA_ICRC) |
| @@ -121,7 +103,7 @@ static void ide_dump_ata_error(ide_drive_t *drive, u8 err) | |||
| 121 | 103 | ||
| 122 | static void ide_dump_atapi_error(ide_drive_t *drive, u8 err) | 104 | static void ide_dump_atapi_error(ide_drive_t *drive, u8 err) |
| 123 | { | 105 | { |
| 124 | printk(KERN_ERR "{ "); | 106 | printk(KERN_CONT "{ "); |
| 125 | if (err & ATAPI_ILI) | 107 | if (err & ATAPI_ILI) |
| 126 | printk(KERN_CONT "IllegalLengthIndication "); | 108 | printk(KERN_CONT "IllegalLengthIndication "); |
| 127 | if (err & ATAPI_EOM) | 109 | if (err & ATAPI_EOM) |
| @@ -179,7 +161,10 @@ u8 ide_dump_status(ide_drive_t *drive, const char *msg, u8 stat) | |||
| 179 | else | 161 | else |
| 180 | ide_dump_atapi_error(drive, err); | 162 | ide_dump_atapi_error(drive, err); |
| 181 | } | 163 | } |
| 182 | ide_dump_opcode(drive); | 164 | |
| 165 | printk(KERN_ERR "%s: possibly failed opcode: 0x%02x\n", | ||
| 166 | drive->name, drive->hwif->cmd.tf.command); | ||
| 167 | |||
| 183 | return err; | 168 | return err; |
| 184 | } | 169 | } |
| 185 | EXPORT_SYMBOL(ide_dump_status); | 170 | EXPORT_SYMBOL(ide_dump_status); |
diff --git a/drivers/ide/ide-probe.c b/drivers/ide/ide-probe.c index 7f264ed1141b..c895ed52b2e8 100644 --- a/drivers/ide/ide-probe.c +++ b/drivers/ide/ide-probe.c | |||
| @@ -295,7 +295,7 @@ int ide_dev_read_id(ide_drive_t *drive, u8 cmd, u16 *id) | |||
| 295 | 295 | ||
| 296 | timeout = ((cmd == ATA_CMD_ID_ATA) ? WAIT_WORSTCASE : WAIT_PIDENTIFY) / 2; | 296 | timeout = ((cmd == ATA_CMD_ID_ATA) ? WAIT_WORSTCASE : WAIT_PIDENTIFY) / 2; |
| 297 | 297 | ||
| 298 | if (ide_busy_sleep(hwif, timeout, use_altstatus)) | 298 | if (ide_busy_sleep(drive, timeout, use_altstatus)) |
| 299 | return 1; | 299 | return 1; |
| 300 | 300 | ||
| 301 | /* wait for IRQ and ATA_DRQ */ | 301 | /* wait for IRQ and ATA_DRQ */ |
| @@ -316,8 +316,9 @@ int ide_dev_read_id(ide_drive_t *drive, u8 cmd, u16 *id) | |||
| 316 | return rc; | 316 | return rc; |
| 317 | } | 317 | } |
| 318 | 318 | ||
| 319 | int ide_busy_sleep(ide_hwif_t *hwif, unsigned long timeout, int altstatus) | 319 | int ide_busy_sleep(ide_drive_t *drive, unsigned long timeout, int altstatus) |
| 320 | { | 320 | { |
| 321 | ide_hwif_t *hwif = drive->hwif; | ||
| 321 | u8 stat; | 322 | u8 stat; |
| 322 | 323 | ||
| 323 | timeout += jiffies; | 324 | timeout += jiffies; |
| @@ -330,6 +331,8 @@ int ide_busy_sleep(ide_hwif_t *hwif, unsigned long timeout, int altstatus) | |||
| 330 | return 0; | 331 | return 0; |
| 331 | } while (time_before(jiffies, timeout)); | 332 | } while (time_before(jiffies, timeout)); |
| 332 | 333 | ||
| 334 | printk(KERN_ERR "%s: timeout in %s\n", drive->name, __func__); | ||
| 335 | |||
| 333 | return 1; /* drive timed-out */ | 336 | return 1; /* drive timed-out */ |
| 334 | } | 337 | } |
| 335 | 338 | ||
| @@ -420,7 +423,7 @@ static int do_probe (ide_drive_t *drive, u8 cmd) | |||
| 420 | tp_ops->dev_select(drive); | 423 | tp_ops->dev_select(drive); |
| 421 | msleep(50); | 424 | msleep(50); |
| 422 | tp_ops->exec_command(hwif, ATA_CMD_DEV_RESET); | 425 | tp_ops->exec_command(hwif, ATA_CMD_DEV_RESET); |
| 423 | (void)ide_busy_sleep(hwif, WAIT_WORSTCASE, 0); | 426 | (void)ide_busy_sleep(drive, WAIT_WORSTCASE, 0); |
| 424 | rc = ide_dev_read_id(drive, cmd, id); | 427 | rc = ide_dev_read_id(drive, cmd, id); |
| 425 | } | 428 | } |
| 426 | 429 | ||
diff --git a/drivers/ide/via82cxxx.c b/drivers/ide/via82cxxx.c index 3ff7231e4858..028de26a25fe 100644 --- a/drivers/ide/via82cxxx.c +++ b/drivers/ide/via82cxxx.c | |||
| @@ -67,6 +67,7 @@ static struct via_isa_bridge { | |||
| 67 | u8 udma_mask; | 67 | u8 udma_mask; |
| 68 | u8 flags; | 68 | u8 flags; |
| 69 | } via_isa_bridges[] = { | 69 | } via_isa_bridges[] = { |
| 70 | { "vx855", PCI_DEVICE_ID_VIA_VX855, 0x00, 0x2f, ATA_UDMA6, VIA_BAD_AST }, | ||
| 70 | { "vx800", PCI_DEVICE_ID_VIA_VX800, 0x00, 0x2f, ATA_UDMA6, VIA_BAD_AST }, | 71 | { "vx800", PCI_DEVICE_ID_VIA_VX800, 0x00, 0x2f, ATA_UDMA6, VIA_BAD_AST }, |
| 71 | { "cx700", PCI_DEVICE_ID_VIA_CX700, 0x00, 0x2f, ATA_UDMA6, VIA_BAD_AST }, | 72 | { "cx700", PCI_DEVICE_ID_VIA_CX700, 0x00, 0x2f, ATA_UDMA6, VIA_BAD_AST }, |
| 72 | { "vt8237s", PCI_DEVICE_ID_VIA_8237S, 0x00, 0x2f, ATA_UDMA6, VIA_BAD_AST }, | 73 | { "vt8237s", PCI_DEVICE_ID_VIA_8237S, 0x00, 0x2f, ATA_UDMA6, VIA_BAD_AST }, |
| @@ -474,6 +475,7 @@ static const struct pci_device_id via_pci_tbl[] = { | |||
| 474 | { PCI_VDEVICE(VIA, PCI_DEVICE_ID_VIA_82C576_1), 0 }, | 475 | { PCI_VDEVICE(VIA, PCI_DEVICE_ID_VIA_82C576_1), 0 }, |
| 475 | { PCI_VDEVICE(VIA, PCI_DEVICE_ID_VIA_82C586_1), 0 }, | 476 | { PCI_VDEVICE(VIA, PCI_DEVICE_ID_VIA_82C586_1), 0 }, |
| 476 | { PCI_VDEVICE(VIA, PCI_DEVICE_ID_VIA_CX700_IDE), 0 }, | 477 | { PCI_VDEVICE(VIA, PCI_DEVICE_ID_VIA_CX700_IDE), 0 }, |
| 478 | { PCI_VDEVICE(VIA, PCI_DEVICE_ID_VIA_VX855_IDE), 0 }, | ||
| 477 | { PCI_VDEVICE(VIA, PCI_DEVICE_ID_VIA_6410), 1 }, | 479 | { PCI_VDEVICE(VIA, PCI_DEVICE_ID_VIA_6410), 1 }, |
| 478 | { PCI_VDEVICE(VIA, PCI_DEVICE_ID_VIA_SATA_EIDE), 1 }, | 480 | { PCI_VDEVICE(VIA, PCI_DEVICE_ID_VIA_SATA_EIDE), 1 }, |
| 479 | { 0, }, | 481 | { 0, }, |
diff --git a/drivers/pci/pci.c b/drivers/pci/pci.c index 34bf0fdf5047..1a91bf9687af 100644 --- a/drivers/pci/pci.c +++ b/drivers/pci/pci.c | |||
| @@ -557,7 +557,8 @@ static int pci_platform_power_transition(struct pci_dev *dev, pci_power_t state) | |||
| 557 | } else { | 557 | } else { |
| 558 | error = -ENODEV; | 558 | error = -ENODEV; |
| 559 | /* Fall back to PCI_D0 if native PM is not supported */ | 559 | /* Fall back to PCI_D0 if native PM is not supported */ |
| 560 | pci_update_current_state(dev, PCI_D0); | 560 | if (!dev->pm_cap) |
| 561 | dev->current_state = PCI_D0; | ||
| 561 | } | 562 | } |
| 562 | 563 | ||
| 563 | return error; | 564 | return error; |
diff --git a/drivers/video/sh_mobile_lcdcfb.c b/drivers/video/sh_mobile_lcdcfb.c index 92ea0ab44ce2..f10d2fbeda06 100644 --- a/drivers/video/sh_mobile_lcdcfb.c +++ b/drivers/video/sh_mobile_lcdcfb.c | |||
| @@ -47,6 +47,7 @@ struct sh_mobile_lcdc_priv { | |||
| 47 | #endif | 47 | #endif |
| 48 | unsigned long lddckr; | 48 | unsigned long lddckr; |
| 49 | struct sh_mobile_lcdc_chan ch[2]; | 49 | struct sh_mobile_lcdc_chan ch[2]; |
| 50 | int started; | ||
| 50 | }; | 51 | }; |
| 51 | 52 | ||
| 52 | /* shared registers */ | 53 | /* shared registers */ |
| @@ -451,6 +452,7 @@ static int sh_mobile_lcdc_start(struct sh_mobile_lcdc_priv *priv) | |||
| 451 | 452 | ||
| 452 | /* start the lcdc */ | 453 | /* start the lcdc */ |
| 453 | sh_mobile_lcdc_start_stop(priv, 1); | 454 | sh_mobile_lcdc_start_stop(priv, 1); |
| 455 | priv->started = 1; | ||
| 454 | 456 | ||
| 455 | /* tell the board code to enable the panel */ | 457 | /* tell the board code to enable the panel */ |
| 456 | for (k = 0; k < ARRAY_SIZE(priv->ch); k++) { | 458 | for (k = 0; k < ARRAY_SIZE(priv->ch); k++) { |
| @@ -493,7 +495,10 @@ static void sh_mobile_lcdc_stop(struct sh_mobile_lcdc_priv *priv) | |||
| 493 | } | 495 | } |
| 494 | 496 | ||
| 495 | /* stop the lcdc */ | 497 | /* stop the lcdc */ |
| 496 | sh_mobile_lcdc_start_stop(priv, 0); | 498 | if (priv->started) { |
| 499 | sh_mobile_lcdc_start_stop(priv, 0); | ||
| 500 | priv->started = 0; | ||
| 501 | } | ||
| 497 | 502 | ||
| 498 | /* stop clocks */ | 503 | /* stop clocks */ |
| 499 | for (k = 0; k < ARRAY_SIZE(priv->ch); k++) | 504 | for (k = 0; k < ARRAY_SIZE(priv->ch); k++) |
diff --git a/fs/cifs/dir.c b/fs/cifs/dir.c index 11431ed72a7f..f49d684edd96 100644 --- a/fs/cifs/dir.c +++ b/fs/cifs/dir.c | |||
| @@ -225,6 +225,7 @@ int cifs_posix_open(char *full_path, struct inode **pinode, | |||
| 225 | if (!(oflags & FMODE_READ)) | 225 | if (!(oflags & FMODE_READ)) |
| 226 | write_only = true; | 226 | write_only = true; |
| 227 | 227 | ||
| 228 | mode &= ~current_umask(); | ||
| 228 | rc = CIFSPOSIXCreate(xid, cifs_sb->tcon, posix_flags, mode, | 229 | rc = CIFSPOSIXCreate(xid, cifs_sb->tcon, posix_flags, mode, |
| 229 | pnetfid, presp_data, &oplock, full_path, | 230 | pnetfid, presp_data, &oplock, full_path, |
| 230 | cifs_sb->local_nls, cifs_sb->mnt_cifs_flags & | 231 | cifs_sb->local_nls, cifs_sb->mnt_cifs_flags & |
| @@ -310,7 +311,6 @@ cifs_create(struct inode *inode, struct dentry *direntry, int mode, | |||
| 310 | return -ENOMEM; | 311 | return -ENOMEM; |
| 311 | } | 312 | } |
| 312 | 313 | ||
| 313 | mode &= ~current_umask(); | ||
| 314 | if (oplockEnabled) | 314 | if (oplockEnabled) |
| 315 | oplock = REQ_OPLOCK; | 315 | oplock = REQ_OPLOCK; |
| 316 | 316 | ||
| @@ -336,7 +336,7 @@ cifs_create(struct inode *inode, struct dentry *direntry, int mode, | |||
| 336 | else /* success, no need to query */ | 336 | else /* success, no need to query */ |
| 337 | goto cifs_create_set_dentry; | 337 | goto cifs_create_set_dentry; |
| 338 | } else if ((rc != -EIO) && (rc != -EREMOTE) && | 338 | } else if ((rc != -EIO) && (rc != -EREMOTE) && |
| 339 | (rc != -EOPNOTSUPP)) /* path not found or net err */ | 339 | (rc != -EOPNOTSUPP) && (rc != -EINVAL)) |
| 340 | goto cifs_create_out; | 340 | goto cifs_create_out; |
| 341 | /* else fallthrough to retry, using older open call, this is | 341 | /* else fallthrough to retry, using older open call, this is |
| 342 | case where server does not support this SMB level, and | 342 | case where server does not support this SMB level, and |
| @@ -609,7 +609,6 @@ cifs_lookup(struct inode *parent_dir_inode, struct dentry *direntry, | |||
| 609 | int xid; | 609 | int xid; |
| 610 | int rc = 0; /* to get around spurious gcc warning, set to zero here */ | 610 | int rc = 0; /* to get around spurious gcc warning, set to zero here */ |
| 611 | int oplock = 0; | 611 | int oplock = 0; |
| 612 | int mode; | ||
| 613 | __u16 fileHandle = 0; | 612 | __u16 fileHandle = 0; |
| 614 | bool posix_open = false; | 613 | bool posix_open = false; |
| 615 | struct cifs_sb_info *cifs_sb; | 614 | struct cifs_sb_info *cifs_sb; |
| @@ -660,13 +659,12 @@ cifs_lookup(struct inode *parent_dir_inode, struct dentry *direntry, | |||
| 660 | 659 | ||
| 661 | if (pTcon->unix_ext) { | 660 | if (pTcon->unix_ext) { |
| 662 | if (!(nd->flags & (LOOKUP_PARENT | LOOKUP_DIRECTORY)) && | 661 | if (!(nd->flags & (LOOKUP_PARENT | LOOKUP_DIRECTORY)) && |
| 663 | (nd->flags & LOOKUP_OPEN)) { | 662 | (nd->flags & LOOKUP_OPEN) && !pTcon->broken_posix_open) { |
| 664 | if (!((nd->intent.open.flags & O_CREAT) && | 663 | if (!((nd->intent.open.flags & O_CREAT) && |
| 665 | (nd->intent.open.flags & O_EXCL))) { | 664 | (nd->intent.open.flags & O_EXCL))) { |
| 666 | mode = nd->intent.open.create_mode & | ||
| 667 | ~current_umask(); | ||
| 668 | rc = cifs_posix_open(full_path, &newInode, | 665 | rc = cifs_posix_open(full_path, &newInode, |
| 669 | parent_dir_inode->i_sb, mode, | 666 | parent_dir_inode->i_sb, |
| 667 | nd->intent.open.create_mode, | ||
| 670 | nd->intent.open.flags, &oplock, | 668 | nd->intent.open.flags, &oplock, |
| 671 | &fileHandle, xid); | 669 | &fileHandle, xid); |
| 672 | /* | 670 | /* |
| @@ -681,6 +679,8 @@ cifs_lookup(struct inode *parent_dir_inode, struct dentry *direntry, | |||
| 681 | */ | 679 | */ |
| 682 | if ((rc != -EINVAL) && (rc != -EOPNOTSUPP)) | 680 | if ((rc != -EINVAL) && (rc != -EOPNOTSUPP)) |
| 683 | posix_open = true; | 681 | posix_open = true; |
| 682 | else | ||
| 683 | pTcon->broken_posix_open = true; | ||
| 684 | } | 684 | } |
| 685 | } | 685 | } |
| 686 | if (!posix_open) | 686 | if (!posix_open) |
diff --git a/fs/cifs/file.c b/fs/cifs/file.c index 38c06f826575..302ea15f02e6 100644 --- a/fs/cifs/file.c +++ b/fs/cifs/file.c | |||
| @@ -130,10 +130,6 @@ static inline int cifs_posix_open_inode_helper(struct inode *inode, | |||
| 130 | struct cifsFileInfo *pCifsFile, int oplock, u16 netfid) | 130 | struct cifsFileInfo *pCifsFile, int oplock, u16 netfid) |
| 131 | { | 131 | { |
| 132 | 132 | ||
| 133 | file->private_data = kmalloc(sizeof(struct cifsFileInfo), GFP_KERNEL); | ||
| 134 | if (file->private_data == NULL) | ||
| 135 | return -ENOMEM; | ||
| 136 | pCifsFile = cifs_init_private(file->private_data, inode, file, netfid); | ||
| 137 | write_lock(&GlobalSMBSeslock); | 133 | write_lock(&GlobalSMBSeslock); |
| 138 | 134 | ||
| 139 | pCifsInode = CIFS_I(file->f_path.dentry->d_inode); | 135 | pCifsInode = CIFS_I(file->f_path.dentry->d_inode); |
| @@ -184,6 +180,38 @@ psx_client_can_cache: | |||
| 184 | return 0; | 180 | return 0; |
| 185 | } | 181 | } |
| 186 | 182 | ||
| 183 | static struct cifsFileInfo * | ||
| 184 | cifs_fill_filedata(struct file *file) | ||
| 185 | { | ||
| 186 | struct list_head *tmp; | ||
| 187 | struct cifsFileInfo *pCifsFile = NULL; | ||
| 188 | struct cifsInodeInfo *pCifsInode = NULL; | ||
| 189 | |||
| 190 | /* search inode for this file and fill in file->private_data */ | ||
| 191 | pCifsInode = CIFS_I(file->f_path.dentry->d_inode); | ||
| 192 | read_lock(&GlobalSMBSeslock); | ||
| 193 | list_for_each(tmp, &pCifsInode->openFileList) { | ||
| 194 | pCifsFile = list_entry(tmp, struct cifsFileInfo, flist); | ||
| 195 | if ((pCifsFile->pfile == NULL) && | ||
| 196 | (pCifsFile->pid == current->tgid)) { | ||
| 197 | /* mode set in cifs_create */ | ||
| 198 | |||
| 199 | /* needed for writepage */ | ||
| 200 | pCifsFile->pfile = file; | ||
| 201 | file->private_data = pCifsFile; | ||
| 202 | break; | ||
| 203 | } | ||
| 204 | } | ||
| 205 | read_unlock(&GlobalSMBSeslock); | ||
| 206 | |||
| 207 | if (file->private_data != NULL) { | ||
| 208 | return pCifsFile; | ||
| 209 | } else if ((file->f_flags & O_CREAT) && (file->f_flags & O_EXCL)) | ||
| 210 | cERROR(1, ("could not find file instance for " | ||
| 211 | "new file %p", file)); | ||
| 212 | return NULL; | ||
| 213 | } | ||
| 214 | |||
| 187 | /* all arguments to this function must be checked for validity in caller */ | 215 | /* all arguments to this function must be checked for validity in caller */ |
| 188 | static inline int cifs_open_inode_helper(struct inode *inode, struct file *file, | 216 | static inline int cifs_open_inode_helper(struct inode *inode, struct file *file, |
| 189 | struct cifsInodeInfo *pCifsInode, struct cifsFileInfo *pCifsFile, | 217 | struct cifsInodeInfo *pCifsInode, struct cifsFileInfo *pCifsFile, |
| @@ -258,7 +286,6 @@ int cifs_open(struct inode *inode, struct file *file) | |||
| 258 | struct cifsTconInfo *tcon; | 286 | struct cifsTconInfo *tcon; |
| 259 | struct cifsFileInfo *pCifsFile; | 287 | struct cifsFileInfo *pCifsFile; |
| 260 | struct cifsInodeInfo *pCifsInode; | 288 | struct cifsInodeInfo *pCifsInode; |
| 261 | struct list_head *tmp; | ||
| 262 | char *full_path = NULL; | 289 | char *full_path = NULL; |
| 263 | int desiredAccess; | 290 | int desiredAccess; |
| 264 | int disposition; | 291 | int disposition; |
| @@ -270,32 +297,12 @@ int cifs_open(struct inode *inode, struct file *file) | |||
| 270 | cifs_sb = CIFS_SB(inode->i_sb); | 297 | cifs_sb = CIFS_SB(inode->i_sb); |
| 271 | tcon = cifs_sb->tcon; | 298 | tcon = cifs_sb->tcon; |
| 272 | 299 | ||
| 273 | /* search inode for this file and fill in file->private_data */ | ||
| 274 | pCifsInode = CIFS_I(file->f_path.dentry->d_inode); | 300 | pCifsInode = CIFS_I(file->f_path.dentry->d_inode); |
| 275 | read_lock(&GlobalSMBSeslock); | 301 | pCifsFile = cifs_fill_filedata(file); |
| 276 | list_for_each(tmp, &pCifsInode->openFileList) { | 302 | if (pCifsFile) { |
| 277 | pCifsFile = list_entry(tmp, struct cifsFileInfo, | ||
| 278 | flist); | ||
| 279 | if ((pCifsFile->pfile == NULL) && | ||
| 280 | (pCifsFile->pid == current->tgid)) { | ||
| 281 | /* mode set in cifs_create */ | ||
| 282 | |||
| 283 | /* needed for writepage */ | ||
| 284 | pCifsFile->pfile = file; | ||
| 285 | |||
| 286 | file->private_data = pCifsFile; | ||
| 287 | break; | ||
| 288 | } | ||
| 289 | } | ||
| 290 | read_unlock(&GlobalSMBSeslock); | ||
| 291 | |||
| 292 | if (file->private_data != NULL) { | ||
| 293 | rc = 0; | ||
| 294 | FreeXid(xid); | 303 | FreeXid(xid); |
| 295 | return rc; | 304 | return 0; |
| 296 | } else if ((file->f_flags & O_CREAT) && (file->f_flags & O_EXCL)) | 305 | } |
| 297 | cERROR(1, ("could not find file instance for " | ||
| 298 | "new file %p", file)); | ||
| 299 | 306 | ||
| 300 | full_path = build_path_from_dentry(file->f_path.dentry); | 307 | full_path = build_path_from_dentry(file->f_path.dentry); |
| 301 | if (full_path == NULL) { | 308 | if (full_path == NULL) { |
| @@ -325,6 +332,7 @@ int cifs_open(struct inode *inode, struct file *file) | |||
| 325 | /* no need for special case handling of setting mode | 332 | /* no need for special case handling of setting mode |
| 326 | on read only files needed here */ | 333 | on read only files needed here */ |
| 327 | 334 | ||
| 335 | pCifsFile = cifs_fill_filedata(file); | ||
| 328 | cifs_posix_open_inode_helper(inode, file, pCifsInode, | 336 | cifs_posix_open_inode_helper(inode, file, pCifsInode, |
| 329 | pCifsFile, oplock, netfid); | 337 | pCifsFile, oplock, netfid); |
| 330 | goto out; | 338 | goto out; |
diff --git a/fs/nilfs2/ioctl.c b/fs/nilfs2/ioctl.c index 50ff3f2cdf24..d6759b92006f 100644 --- a/fs/nilfs2/ioctl.c +++ b/fs/nilfs2/ioctl.c | |||
| @@ -576,7 +576,7 @@ static int nilfs_ioctl_clean_segments(struct inode *inode, struct file *filp, | |||
| 576 | ret = nilfs_clean_segments(inode->i_sb, argv, kbufs); | 576 | ret = nilfs_clean_segments(inode->i_sb, argv, kbufs); |
| 577 | 577 | ||
| 578 | out_free: | 578 | out_free: |
| 579 | while (--n > 0) | 579 | while (--n >= 0) |
| 580 | vfree(kbufs[n]); | 580 | vfree(kbufs[n]); |
| 581 | kfree(kbufs[4]); | 581 | kfree(kbufs[4]); |
| 582 | return ret; | 582 | return ret; |
diff --git a/include/linux/ide.h b/include/linux/ide.h index ff65fffb078f..9fed365a598b 100644 --- a/include/linux/ide.h +++ b/include/linux/ide.h | |||
| @@ -1109,7 +1109,7 @@ void ide_fix_driveid(u16 *); | |||
| 1109 | 1109 | ||
| 1110 | extern void ide_fixstring(u8 *, const int, const int); | 1110 | extern void ide_fixstring(u8 *, const int, const int); |
| 1111 | 1111 | ||
| 1112 | int ide_busy_sleep(ide_hwif_t *, unsigned long, int); | 1112 | int ide_busy_sleep(ide_drive_t *, unsigned long, int); |
| 1113 | 1113 | ||
| 1114 | int ide_wait_stat(ide_startstop_t *, ide_drive_t *, u8, u8, unsigned long); | 1114 | int ide_wait_stat(ide_startstop_t *, ide_drive_t *, u8, u8, unsigned long); |
| 1115 | 1115 | ||
diff --git a/include/linux/pci_ids.h b/include/linux/pci_ids.h index 06ba90c211a5..0f71812d67d3 100644 --- a/include/linux/pci_ids.h +++ b/include/linux/pci_ids.h | |||
| @@ -1406,7 +1406,7 @@ | |||
| 1406 | #define PCI_DEVICE_ID_VIA_82C598_1 0x8598 | 1406 | #define PCI_DEVICE_ID_VIA_82C598_1 0x8598 |
| 1407 | #define PCI_DEVICE_ID_VIA_838X_1 0xB188 | 1407 | #define PCI_DEVICE_ID_VIA_838X_1 0xB188 |
| 1408 | #define PCI_DEVICE_ID_VIA_83_87XX_1 0xB198 | 1408 | #define PCI_DEVICE_ID_VIA_83_87XX_1 0xB198 |
| 1409 | #define PCI_DEVICE_ID_VIA_C409_IDE 0XC409 | 1409 | #define PCI_DEVICE_ID_VIA_VX855_IDE 0xC409 |
| 1410 | #define PCI_DEVICE_ID_VIA_ANON 0xFFFF | 1410 | #define PCI_DEVICE_ID_VIA_ANON 0xFFFF |
| 1411 | 1411 | ||
| 1412 | #define PCI_VENDOR_ID_SIEMENS 0x110A | 1412 | #define PCI_VENDOR_ID_SIEMENS 0x110A |
| @@ -14,7 +14,7 @@ | |||
| 14 | * Original design by Rik van Riel <riel@conectiva.com.br> 2001 | 14 | * Original design by Rik van Riel <riel@conectiva.com.br> 2001 |
| 15 | * File methods by Dave McCracken <dmccr@us.ibm.com> 2003, 2004 | 15 | * File methods by Dave McCracken <dmccr@us.ibm.com> 2003, 2004 |
| 16 | * Anonymous methods by Andrea Arcangeli <andrea@suse.de> 2004 | 16 | * Anonymous methods by Andrea Arcangeli <andrea@suse.de> 2004 |
| 17 | * Contributions by Hugh Dickins <hugh@veritas.com> 2003, 2004 | 17 | * Contributions by Hugh Dickins 2003, 2004 |
| 18 | */ | 18 | */ |
| 19 | 19 | ||
| 20 | /* | 20 | /* |
