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

Configure Feed

Select the types of activity you want to include in your feed.

Merge tag 'firewire-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/ieee1394/linux1394

Pull firewire fixes from Stefan Richter:
"Fix a use-after-free regression since v3.4 and an initialization
regression since v3.10"

* tag 'firewire-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/ieee1394/linux1394:
firewire: ohci: fix probe failure with Agere/LSI controllers
firewire: net: fix use after free

+5 -16
+3 -3
drivers/firewire/net.c
··· 929 929 if (rcode == RCODE_COMPLETE) { 930 930 fwnet_transmit_packet_done(ptask); 931 931 } else { 932 - fwnet_transmit_packet_failed(ptask); 933 - 934 932 if (printk_timed_ratelimit(&j, 1000) || rcode != last_rcode) { 935 933 dev_err(&ptask->dev->netdev->dev, 936 934 "fwnet_write_complete failed: %x (skipped %d)\n", ··· 936 938 937 939 errors_skipped = 0; 938 940 last_rcode = rcode; 939 - } else 941 + } else { 940 942 errors_skipped++; 943 + } 944 + fwnet_transmit_packet_failed(ptask); 941 945 } 942 946 } 943 947
+2 -13
drivers/firewire/ohci.c
··· 290 290 #define QUIRK_NO_MSI 0x10 291 291 #define QUIRK_TI_SLLZ059 0x20 292 292 #define QUIRK_IR_WAKE 0x40 293 - #define QUIRK_PHY_LCTRL_TIMEOUT 0x80 294 293 295 294 /* In case of multiple matches in ohci_quirks[], only the first one is used. */ 296 295 static const struct { ··· 302 303 QUIRK_BE_HEADERS}, 303 304 304 305 {PCI_VENDOR_ID_ATT, PCI_DEVICE_ID_AGERE_FW643, 6, 305 - QUIRK_PHY_LCTRL_TIMEOUT | QUIRK_NO_MSI}, 306 - 307 - {PCI_VENDOR_ID_ATT, PCI_ANY_ID, PCI_ANY_ID, 308 - QUIRK_PHY_LCTRL_TIMEOUT}, 306 + QUIRK_NO_MSI}, 309 307 310 308 {PCI_VENDOR_ID_CREATIVE, PCI_DEVICE_ID_CREATIVE_SB1394, PCI_ANY_ID, 311 309 QUIRK_RESET_PACKET}, ··· 349 353 ", disable MSI = " __stringify(QUIRK_NO_MSI) 350 354 ", TI SLLZ059 erratum = " __stringify(QUIRK_TI_SLLZ059) 351 355 ", IR wake unreliable = " __stringify(QUIRK_IR_WAKE) 352 - ", phy LCtrl timeout = " __stringify(QUIRK_PHY_LCTRL_TIMEOUT) 353 356 ")"); 354 357 355 358 #define OHCI_PARAM_DEBUG_AT_AR 1 ··· 2294 2299 * TI TSB82AA2 + TSB81BA3(A) cards signal LPS enabled early but 2295 2300 * cannot actually use the phy at that time. These need tens of 2296 2301 * millisecods pause between LPS write and first phy access too. 2297 - * 2298 - * But do not wait for 50msec on Agere/LSI cards. Their phy 2299 - * arbitration state machine may time out during such a long wait. 2300 2302 */ 2301 2303 2302 2304 reg_write(ohci, OHCI1394_HCControlSet, ··· 2301 2309 OHCI1394_HCControl_postedWriteEnable); 2302 2310 flush_writes(ohci); 2303 2311 2304 - if (!(ohci->quirks & QUIRK_PHY_LCTRL_TIMEOUT)) 2312 + for (lps = 0, i = 0; !lps && i < 3; i++) { 2305 2313 msleep(50); 2306 - 2307 - for (lps = 0, i = 0; !lps && i < 150; i++) { 2308 - msleep(1); 2309 2314 lps = reg_read(ohci, OHCI1394_HCControlSet) & 2310 2315 OHCI1394_HCControl_LPS; 2311 2316 }