Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/ieee1394/linux1394-2.6

* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/ieee1394/linux1394-2.6:
firewire: sbp2: fix freeing of unallocated memory
firewire: ohci: fix Ricoh R5C832, video reception
firewire: ohci: fix Agere FW643 and multiple cameras
firewire: core: fix crash in iso resource management

+20 -6
+2 -2
drivers/firewire/core-iso.c
··· 196 196 switch (fw_run_transaction(card, TCODE_LOCK_COMPARE_SWAP, 197 197 irm_id, generation, SCODE_100, 198 198 CSR_REGISTER_BASE + CSR_BANDWIDTH_AVAILABLE, 199 - data, sizeof(data))) { 199 + data, 8)) { 200 200 case RCODE_GENERATION: 201 201 /* A generation change frees all bandwidth. */ 202 202 return allocate ? -EAGAIN : bandwidth; ··· 233 233 data[1] = old ^ c; 234 234 switch (fw_run_transaction(card, TCODE_LOCK_COMPARE_SWAP, 235 235 irm_id, generation, SCODE_100, 236 - offset, data, sizeof(data))) { 236 + offset, data, 8)) { 237 237 case RCODE_GENERATION: 238 238 /* A generation change frees all channels. */ 239 239 return allocate ? -EAGAIN : i;
+14
drivers/firewire/ohci.c
··· 34 34 #include <linux/module.h> 35 35 #include <linux/moduleparam.h> 36 36 #include <linux/pci.h> 37 + #include <linux/pci_ids.h> 37 38 #include <linux/spinlock.h> 38 39 #include <linux/string.h> 39 40 ··· 2373 2372 #define ohci_pmac_off(dev) 2374 2373 #endif /* CONFIG_PPC_PMAC */ 2375 2374 2375 + #define PCI_VENDOR_ID_AGERE PCI_VENDOR_ID_ATT 2376 + #define PCI_DEVICE_ID_AGERE_FW643 0x5901 2377 + 2376 2378 static int __devinit pci_probe(struct pci_dev *dev, 2377 2379 const struct pci_device_id *ent) 2378 2380 { ··· 2425 2421 2426 2422 version = reg_read(ohci, OHCI1394_Version) & 0x00ff00ff; 2427 2423 ohci->use_dualbuffer = version >= OHCI_VERSION_1_1; 2424 + 2425 + /* dual-buffer mode is broken if more than one IR context is active */ 2426 + if (dev->vendor == PCI_VENDOR_ID_AGERE && 2427 + dev->device == PCI_DEVICE_ID_AGERE_FW643) 2428 + ohci->use_dualbuffer = false; 2429 + 2430 + /* dual-buffer mode is broken */ 2431 + if (dev->vendor == PCI_VENDOR_ID_RICOH && 2432 + dev->device == PCI_DEVICE_ID_RICOH_R5C832) 2433 + ohci->use_dualbuffer = false; 2428 2434 2429 2435 /* x86-32 currently doesn't use highmem for dma_alloc_coherent */ 2430 2436 #if !defined(CONFIG_X86_32)
+4 -4
drivers/firewire/sbp2.c
··· 456 456 } 457 457 spin_unlock_irqrestore(&card->lock, flags); 458 458 459 - if (&orb->link != &lu->orb_list) 459 + if (&orb->link != &lu->orb_list) { 460 460 orb->callback(orb, &status); 461 - else 461 + kref_put(&orb->kref, free_orb); 462 + } else { 462 463 fw_error("status write for unknown orb\n"); 463 - 464 - kref_put(&orb->kref, free_orb); 464 + } 465 465 466 466 fw_send_response(card, request, RCODE_COMPLETE); 467 467 }