diff options
author | Linus Torvalds <torvalds@woody.linux-foundation.org> | 2008-01-04 13:44:17 -0500 |
---|---|---|
committer | Linus Torvalds <torvalds@woody.linux-foundation.org> | 2008-01-04 13:44:17 -0500 |
commit | 439f61b9f9ebbf84fb7e6b3539fc3794e046bbb9 (patch) | |
tree | 9aeec0e7248175ece16586552bb44655bdcbe028 | |
parent | 2022c1f136067f673964dcaffa1cae1008ddcd74 (diff) | |
parent | 7fde4d779b83898851959f837c9b26fe07ee91c9 (diff) |
Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-2.6
* git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-2.6:
[ISDN]: i4l: Fix DLE handling for i4l-audio
[ISDN] i4l: 'NO CARRIER' message lost after ldisc flush
[CONNECTOR]: Return proper error code in cn_call_callback()
[INET]: Fix netdev renaming and inet address labels
[CASSINI]: Bump driver version and release date.
[CASSINI]: Fix two obvious NAPI bugs.
[CASSINI]: Set skb->truesize properly on receive packets.
[CASSINI]: Program parent Intel31154 bridge when necessary.
[CASSINI]: Revert 'dont touch page_count'.
[CASSINI]: Fix endianness bug.
[XFRM]: Do not define km_migrate() if !CONFIG_XFRM_MIGRATE
[X25]: Add missing x25_neigh_put
-rw-r--r-- | drivers/connector/connector.c | 2 | ||||
-rw-r--r-- | drivers/isdn/i4l/isdn_common.c | 3 | ||||
-rw-r--r-- | drivers/isdn/i4l/isdn_tty.c | 7 | ||||
-rw-r--r-- | drivers/net/cassini.c | 139 | ||||
-rw-r--r-- | drivers/net/cassini.h | 18 | ||||
-rw-r--r-- | net/ipv4/devinet.c | 2 | ||||
-rw-r--r-- | net/x25/x25_forward.c | 5 | ||||
-rw-r--r-- | net/xfrm/xfrm_state.c | 2 |
8 files changed, 127 insertions, 51 deletions
diff --git a/drivers/connector/connector.c b/drivers/connector/connector.c index 6883fcb79ad3..bf9716b75513 100644 --- a/drivers/connector/connector.c +++ b/drivers/connector/connector.c | |||
@@ -145,6 +145,8 @@ static int cn_call_callback(struct cn_msg *msg, void (*destruct_data)(void *), v | |||
145 | if (queue_work(dev->cbdev->cn_queue, | 145 | if (queue_work(dev->cbdev->cn_queue, |
146 | &__cbq->work)) | 146 | &__cbq->work)) |
147 | err = 0; | 147 | err = 0; |
148 | else | ||
149 | err = -EINVAL; | ||
148 | } else { | 150 | } else { |
149 | struct cn_callback_data *d; | 151 | struct cn_callback_data *d; |
150 | 152 | ||
diff --git a/drivers/isdn/i4l/isdn_common.c b/drivers/isdn/i4l/isdn_common.c index d6952959d72a..9cef6fcf587b 100644 --- a/drivers/isdn/i4l/isdn_common.c +++ b/drivers/isdn/i4l/isdn_common.c | |||
@@ -914,6 +914,9 @@ isdn_readbchan_tty(int di, int channel, struct tty_struct *tty, int cisco_hack) | |||
914 | dflag = 0; | 914 | dflag = 0; |
915 | count_pull = count_put = 0; | 915 | count_pull = count_put = 0; |
916 | while ((count_pull < skb->len) && (len > 0)) { | 916 | while ((count_pull < skb->len) && (len > 0)) { |
917 | /* push every character but the last to the tty buffer directly */ | ||
918 | if ( count_put ) | ||
919 | tty_insert_flip_char(tty, last, TTY_NORMAL); | ||
917 | len--; | 920 | len--; |
918 | if (dev->drv[di]->DLEflag & DLEmask) { | 921 | if (dev->drv[di]->DLEflag & DLEmask) { |
919 | last = DLE; | 922 | last = DLE; |
diff --git a/drivers/isdn/i4l/isdn_tty.c b/drivers/isdn/i4l/isdn_tty.c index 4e5f87c1e714..9cb6e5021adb 100644 --- a/drivers/isdn/i4l/isdn_tty.c +++ b/drivers/isdn/i4l/isdn_tty.c | |||
@@ -85,6 +85,8 @@ isdn_tty_try_read(modem_info * info, struct sk_buff *skb) | |||
85 | tty_insert_flip_char(tty, DLE, 0); | 85 | tty_insert_flip_char(tty, DLE, 0); |
86 | tty_insert_flip_char(tty, *dp++, 0); | 86 | tty_insert_flip_char(tty, *dp++, 0); |
87 | } | 87 | } |
88 | if (*dp == DLE) | ||
89 | tty_insert_flip_char(tty, DLE, 0); | ||
88 | last = *dp; | 90 | last = *dp; |
89 | } else { | 91 | } else { |
90 | #endif | 92 | #endif |
@@ -2645,7 +2647,12 @@ isdn_tty_modem_result(int code, modem_info * info) | |||
2645 | if ((info->flags & ISDN_ASYNC_CLOSING) || (!info->tty)) { | 2647 | if ((info->flags & ISDN_ASYNC_CLOSING) || (!info->tty)) { |
2646 | return; | 2648 | return; |
2647 | } | 2649 | } |
2650 | #ifdef CONFIG_ISDN_AUDIO | ||
2651 | if ( !info->vonline ) | ||
2652 | tty_ldisc_flush(info->tty); | ||
2653 | #else | ||
2648 | tty_ldisc_flush(info->tty); | 2654 | tty_ldisc_flush(info->tty); |
2655 | #endif | ||
2649 | if ((info->flags & ISDN_ASYNC_CHECK_CD) && | 2656 | if ((info->flags & ISDN_ASYNC_CHECK_CD) && |
2650 | (!((info->flags & ISDN_ASYNC_CALLOUT_ACTIVE) && | 2657 | (!((info->flags & ISDN_ASYNC_CALLOUT_ACTIVE) && |
2651 | (info->flags & ISDN_ASYNC_CALLOUT_NOHUP)))) { | 2658 | (info->flags & ISDN_ASYNC_CALLOUT_NOHUP)))) { |
diff --git a/drivers/net/cassini.c b/drivers/net/cassini.c index 7df31b5561cc..d66915d82b24 100644 --- a/drivers/net/cassini.c +++ b/drivers/net/cassini.c | |||
@@ -142,8 +142,8 @@ | |||
142 | 142 | ||
143 | #define DRV_MODULE_NAME "cassini" | 143 | #define DRV_MODULE_NAME "cassini" |
144 | #define PFX DRV_MODULE_NAME ": " | 144 | #define PFX DRV_MODULE_NAME ": " |
145 | #define DRV_MODULE_VERSION "1.4" | 145 | #define DRV_MODULE_VERSION "1.5" |
146 | #define DRV_MODULE_RELDATE "1 July 2004" | 146 | #define DRV_MODULE_RELDATE "4 Jan 2008" |
147 | 147 | ||
148 | #define CAS_DEF_MSG_ENABLE \ | 148 | #define CAS_DEF_MSG_ENABLE \ |
149 | (NETIF_MSG_DRV | \ | 149 | (NETIF_MSG_DRV | \ |
@@ -336,30 +336,6 @@ static inline void cas_mask_intr(struct cas *cp) | |||
336 | cas_disable_irq(cp, i); | 336 | cas_disable_irq(cp, i); |
337 | } | 337 | } |
338 | 338 | ||
339 | static inline void cas_buffer_init(cas_page_t *cp) | ||
340 | { | ||
341 | struct page *page = cp->buffer; | ||
342 | atomic_set((atomic_t *)&page->lru.next, 1); | ||
343 | } | ||
344 | |||
345 | static inline int cas_buffer_count(cas_page_t *cp) | ||
346 | { | ||
347 | struct page *page = cp->buffer; | ||
348 | return atomic_read((atomic_t *)&page->lru.next); | ||
349 | } | ||
350 | |||
351 | static inline void cas_buffer_inc(cas_page_t *cp) | ||
352 | { | ||
353 | struct page *page = cp->buffer; | ||
354 | atomic_inc((atomic_t *)&page->lru.next); | ||
355 | } | ||
356 | |||
357 | static inline void cas_buffer_dec(cas_page_t *cp) | ||
358 | { | ||
359 | struct page *page = cp->buffer; | ||
360 | atomic_dec((atomic_t *)&page->lru.next); | ||
361 | } | ||
362 | |||
363 | static void cas_enable_irq(struct cas *cp, const int ring) | 339 | static void cas_enable_irq(struct cas *cp, const int ring) |
364 | { | 340 | { |
365 | if (ring == 0) { /* all but TX_DONE */ | 341 | if (ring == 0) { /* all but TX_DONE */ |
@@ -497,7 +473,6 @@ static int cas_page_free(struct cas *cp, cas_page_t *page) | |||
497 | { | 473 | { |
498 | pci_unmap_page(cp->pdev, page->dma_addr, cp->page_size, | 474 | pci_unmap_page(cp->pdev, page->dma_addr, cp->page_size, |
499 | PCI_DMA_FROMDEVICE); | 475 | PCI_DMA_FROMDEVICE); |
500 | cas_buffer_dec(page); | ||
501 | __free_pages(page->buffer, cp->page_order); | 476 | __free_pages(page->buffer, cp->page_order); |
502 | kfree(page); | 477 | kfree(page); |
503 | return 0; | 478 | return 0; |
@@ -527,7 +502,6 @@ static cas_page_t *cas_page_alloc(struct cas *cp, const gfp_t flags) | |||
527 | page->buffer = alloc_pages(flags, cp->page_order); | 502 | page->buffer = alloc_pages(flags, cp->page_order); |
528 | if (!page->buffer) | 503 | if (!page->buffer) |
529 | goto page_err; | 504 | goto page_err; |
530 | cas_buffer_init(page); | ||
531 | page->dma_addr = pci_map_page(cp->pdev, page->buffer, 0, | 505 | page->dma_addr = pci_map_page(cp->pdev, page->buffer, 0, |
532 | cp->page_size, PCI_DMA_FROMDEVICE); | 506 | cp->page_size, PCI_DMA_FROMDEVICE); |
533 | return page; | 507 | return page; |
@@ -606,7 +580,7 @@ static void cas_spare_recover(struct cas *cp, const gfp_t flags) | |||
606 | list_for_each_safe(elem, tmp, &list) { | 580 | list_for_each_safe(elem, tmp, &list) { |
607 | cas_page_t *page = list_entry(elem, cas_page_t, list); | 581 | cas_page_t *page = list_entry(elem, cas_page_t, list); |
608 | 582 | ||
609 | if (cas_buffer_count(page) > 1) | 583 | if (page_count(page->buffer) > 1) |
610 | continue; | 584 | continue; |
611 | 585 | ||
612 | list_del(elem); | 586 | list_del(elem); |
@@ -1374,7 +1348,7 @@ static inline cas_page_t *cas_page_spare(struct cas *cp, const int index) | |||
1374 | cas_page_t *page = cp->rx_pages[1][index]; | 1348 | cas_page_t *page = cp->rx_pages[1][index]; |
1375 | cas_page_t *new; | 1349 | cas_page_t *new; |
1376 | 1350 | ||
1377 | if (cas_buffer_count(page) == 1) | 1351 | if (page_count(page->buffer) == 1) |
1378 | return page; | 1352 | return page; |
1379 | 1353 | ||
1380 | new = cas_page_dequeue(cp); | 1354 | new = cas_page_dequeue(cp); |
@@ -1394,7 +1368,7 @@ static cas_page_t *cas_page_swap(struct cas *cp, const int ring, | |||
1394 | cas_page_t **page1 = cp->rx_pages[1]; | 1368 | cas_page_t **page1 = cp->rx_pages[1]; |
1395 | 1369 | ||
1396 | /* swap if buffer is in use */ | 1370 | /* swap if buffer is in use */ |
1397 | if (cas_buffer_count(page0[index]) > 1) { | 1371 | if (page_count(page0[index]->buffer) > 1) { |
1398 | cas_page_t *new = cas_page_spare(cp, index); | 1372 | cas_page_t *new = cas_page_spare(cp, index); |
1399 | if (new) { | 1373 | if (new) { |
1400 | page1[index] = page0[index]; | 1374 | page1[index] = page0[index]; |
@@ -1979,6 +1953,7 @@ static int cas_rx_process_pkt(struct cas *cp, struct cas_rx_comp *rxc, | |||
1979 | struct cas_page *page; | 1953 | struct cas_page *page; |
1980 | struct sk_buff *skb; | 1954 | struct sk_buff *skb; |
1981 | void *addr, *crcaddr; | 1955 | void *addr, *crcaddr; |
1956 | __sum16 csum; | ||
1982 | char *p; | 1957 | char *p; |
1983 | 1958 | ||
1984 | hlen = CAS_VAL(RX_COMP2_HDR_SIZE, words[1]); | 1959 | hlen = CAS_VAL(RX_COMP2_HDR_SIZE, words[1]); |
@@ -2062,10 +2037,10 @@ static int cas_rx_process_pkt(struct cas *cp, struct cas_rx_comp *rxc, | |||
2062 | 2037 | ||
2063 | skb_shinfo(skb)->nr_frags++; | 2038 | skb_shinfo(skb)->nr_frags++; |
2064 | skb->data_len += hlen - swivel; | 2039 | skb->data_len += hlen - swivel; |
2040 | skb->truesize += hlen - swivel; | ||
2065 | skb->len += hlen - swivel; | 2041 | skb->len += hlen - swivel; |
2066 | 2042 | ||
2067 | get_page(page->buffer); | 2043 | get_page(page->buffer); |
2068 | cas_buffer_inc(page); | ||
2069 | frag->page = page->buffer; | 2044 | frag->page = page->buffer; |
2070 | frag->page_offset = off; | 2045 | frag->page_offset = off; |
2071 | frag->size = hlen - swivel; | 2046 | frag->size = hlen - swivel; |
@@ -2090,7 +2065,6 @@ static int cas_rx_process_pkt(struct cas *cp, struct cas_rx_comp *rxc, | |||
2090 | frag++; | 2065 | frag++; |
2091 | 2066 | ||
2092 | get_page(page->buffer); | 2067 | get_page(page->buffer); |
2093 | cas_buffer_inc(page); | ||
2094 | frag->page = page->buffer; | 2068 | frag->page = page->buffer; |
2095 | frag->page_offset = 0; | 2069 | frag->page_offset = 0; |
2096 | frag->size = hlen; | 2070 | frag->size = hlen; |
@@ -2158,14 +2132,15 @@ end_copy_pkt: | |||
2158 | skb_put(skb, alloclen); | 2132 | skb_put(skb, alloclen); |
2159 | } | 2133 | } |
2160 | 2134 | ||
2161 | i = CAS_VAL(RX_COMP4_TCP_CSUM, words[3]); | 2135 | csum = (__force __sum16)htons(CAS_VAL(RX_COMP4_TCP_CSUM, words[3])); |
2162 | if (cp->crc_size) { | 2136 | if (cp->crc_size) { |
2163 | /* checksum includes FCS. strip it out. */ | 2137 | /* checksum includes FCS. strip it out. */ |
2164 | i = csum_fold(csum_partial(crcaddr, cp->crc_size, i)); | 2138 | csum = csum_fold(csum_partial(crcaddr, cp->crc_size, |
2139 | csum_unfold(csum))); | ||
2165 | if (addr) | 2140 | if (addr) |
2166 | cas_page_unmap(addr); | 2141 | cas_page_unmap(addr); |
2167 | } | 2142 | } |
2168 | skb->csum = ntohs(i ^ 0xffff); | 2143 | skb->csum = csum_unfold(~csum); |
2169 | skb->ip_summed = CHECKSUM_COMPLETE; | 2144 | skb->ip_summed = CHECKSUM_COMPLETE; |
2170 | skb->protocol = eth_type_trans(skb, cp->dev); | 2145 | skb->protocol = eth_type_trans(skb, cp->dev); |
2171 | return len; | 2146 | return len; |
@@ -2253,7 +2228,7 @@ static int cas_post_rxds_ringN(struct cas *cp, int ring, int num) | |||
2253 | released = 0; | 2228 | released = 0; |
2254 | while (entry != last) { | 2229 | while (entry != last) { |
2255 | /* make a new buffer if it's still in use */ | 2230 | /* make a new buffer if it's still in use */ |
2256 | if (cas_buffer_count(page[entry]) > 1) { | 2231 | if (page_count(page[entry]->buffer) > 1) { |
2257 | cas_page_t *new = cas_page_dequeue(cp); | 2232 | cas_page_t *new = cas_page_dequeue(cp); |
2258 | if (!new) { | 2233 | if (!new) { |
2259 | /* let the timer know that we need to | 2234 | /* let the timer know that we need to |
@@ -2611,7 +2586,7 @@ static int cas_poll(struct napi_struct *napi, int budget) | |||
2611 | { | 2586 | { |
2612 | struct cas *cp = container_of(napi, struct cas, napi); | 2587 | struct cas *cp = container_of(napi, struct cas, napi); |
2613 | struct net_device *dev = cp->dev; | 2588 | struct net_device *dev = cp->dev; |
2614 | int i, enable_intr, todo, credits; | 2589 | int i, enable_intr, credits; |
2615 | u32 status = readl(cp->regs + REG_INTR_STATUS); | 2590 | u32 status = readl(cp->regs + REG_INTR_STATUS); |
2616 | unsigned long flags; | 2591 | unsigned long flags; |
2617 | 2592 | ||
@@ -4375,7 +4350,7 @@ static int cas_close(struct net_device *dev) | |||
4375 | struct cas *cp = netdev_priv(dev); | 4350 | struct cas *cp = netdev_priv(dev); |
4376 | 4351 | ||
4377 | #ifdef USE_NAPI | 4352 | #ifdef USE_NAPI |
4378 | napi_enable(&cp->napi); | 4353 | napi_disable(&cp->napi); |
4379 | #endif | 4354 | #endif |
4380 | /* Make sure we don't get distracted by suspend/resume */ | 4355 | /* Make sure we don't get distracted by suspend/resume */ |
4381 | mutex_lock(&cp->pm_mutex); | 4356 | mutex_lock(&cp->pm_mutex); |
@@ -4872,6 +4847,90 @@ static int cas_ioctl(struct net_device *dev, struct ifreq *ifr, int cmd) | |||
4872 | return rc; | 4847 | return rc; |
4873 | } | 4848 | } |
4874 | 4849 | ||
4850 | /* When this chip sits underneath an Intel 31154 bridge, it is the | ||
4851 | * only subordinate device and we can tweak the bridge settings to | ||
4852 | * reflect that fact. | ||
4853 | */ | ||
4854 | static void __devinit cas_program_bridge(struct pci_dev *cas_pdev) | ||
4855 | { | ||
4856 | struct pci_dev *pdev = cas_pdev->bus->self; | ||
4857 | u32 val; | ||
4858 | |||
4859 | if (!pdev) | ||
4860 | return; | ||
4861 | |||
4862 | if (pdev->vendor != 0x8086 || pdev->device != 0x537c) | ||
4863 | return; | ||
4864 | |||
4865 | /* Clear bit 10 (Bus Parking Control) in the Secondary | ||
4866 | * Arbiter Control/Status Register which lives at offset | ||
4867 | * 0x41. Using a 32-bit word read/modify/write at 0x40 | ||
4868 | * is much simpler so that's how we do this. | ||
4869 | */ | ||
4870 | pci_read_config_dword(pdev, 0x40, &val); | ||
4871 | val &= ~0x00040000; | ||
4872 | pci_write_config_dword(pdev, 0x40, val); | ||
4873 | |||
4874 | /* Max out the Multi-Transaction Timer settings since | ||
4875 | * Cassini is the only device present. | ||
4876 | * | ||
4877 | * The register is 16-bit and lives at 0x50. When the | ||
4878 | * settings are enabled, it extends the GRANT# signal | ||
4879 | * for a requestor after a transaction is complete. This | ||
4880 | * allows the next request to run without first needing | ||
4881 | * to negotiate the GRANT# signal back. | ||
4882 | * | ||
4883 | * Bits 12:10 define the grant duration: | ||
4884 | * | ||
4885 | * 1 -- 16 clocks | ||
4886 | * 2 -- 32 clocks | ||
4887 | * 3 -- 64 clocks | ||
4888 | * 4 -- 128 clocks | ||
4889 | * 5 -- 256 clocks | ||
4890 | * | ||
4891 | * All other values are illegal. | ||
4892 | * | ||
4893 | * Bits 09:00 define which REQ/GNT signal pairs get the | ||
4894 | * GRANT# signal treatment. We set them all. | ||
4895 | */ | ||
4896 | pci_write_config_word(pdev, 0x50, (5 << 10) | 0x3ff); | ||
4897 | |||
4898 | /* The Read Prefecth Policy register is 16-bit and sits at | ||
4899 | * offset 0x52. It enables a "smart" pre-fetch policy. We | ||
4900 | * enable it and max out all of the settings since only one | ||
4901 | * device is sitting underneath and thus bandwidth sharing is | ||
4902 | * not an issue. | ||
4903 | * | ||
4904 | * The register has several 3 bit fields, which indicates a | ||
4905 | * multiplier applied to the base amount of prefetching the | ||
4906 | * chip would do. These fields are at: | ||
4907 | * | ||
4908 | * 15:13 --- ReRead Primary Bus | ||
4909 | * 12:10 --- FirstRead Primary Bus | ||
4910 | * 09:07 --- ReRead Secondary Bus | ||
4911 | * 06:04 --- FirstRead Secondary Bus | ||
4912 | * | ||
4913 | * Bits 03:00 control which REQ/GNT pairs the prefetch settings | ||
4914 | * get enabled on. Bit 3 is a grouped enabler which controls | ||
4915 | * all of the REQ/GNT pairs from [8:3]. Bits 2 to 0 control | ||
4916 | * the individual REQ/GNT pairs [2:0]. | ||
4917 | */ | ||
4918 | pci_write_config_word(pdev, 0x52, | ||
4919 | (0x7 << 13) | | ||
4920 | (0x7 << 10) | | ||
4921 | (0x7 << 7) | | ||
4922 | (0x7 << 4) | | ||
4923 | (0xf << 0)); | ||
4924 | |||
4925 | /* Force cacheline size to 0x8 */ | ||
4926 | pci_write_config_byte(pdev, PCI_CACHE_LINE_SIZE, 0x08); | ||
4927 | |||
4928 | /* Force latency timer to maximum setting so Cassini can | ||
4929 | * sit on the bus as long as it likes. | ||
4930 | */ | ||
4931 | pci_write_config_byte(pdev, PCI_LATENCY_TIMER, 0xff); | ||
4932 | } | ||
4933 | |||
4875 | static int __devinit cas_init_one(struct pci_dev *pdev, | 4934 | static int __devinit cas_init_one(struct pci_dev *pdev, |
4876 | const struct pci_device_id *ent) | 4935 | const struct pci_device_id *ent) |
4877 | { | 4936 | { |
@@ -4927,6 +4986,8 @@ static int __devinit cas_init_one(struct pci_dev *pdev, | |||
4927 | printk(KERN_WARNING PFX "Could not enable MWI for %s\n", | 4986 | printk(KERN_WARNING PFX "Could not enable MWI for %s\n", |
4928 | pci_name(pdev)); | 4987 | pci_name(pdev)); |
4929 | 4988 | ||
4989 | cas_program_bridge(pdev); | ||
4990 | |||
4930 | /* | 4991 | /* |
4931 | * On some architectures, the default cache line size set | 4992 | * On some architectures, the default cache line size set |
4932 | * by pci_try_set_mwi reduces perforamnce. We have to increase | 4993 | * by pci_try_set_mwi reduces perforamnce. We have to increase |
diff --git a/drivers/net/cassini.h b/drivers/net/cassini.h index 2f93f83342d2..552af89ca1cf 100644 --- a/drivers/net/cassini.h +++ b/drivers/net/cassini.h | |||
@@ -4122,8 +4122,8 @@ cas_saturn_patch_t cas_saturn_patch[] = { | |||
4122 | inserted into | 4122 | inserted into |
4123 | outgoing frame. */ | 4123 | outgoing frame. */ |
4124 | struct cas_tx_desc { | 4124 | struct cas_tx_desc { |
4125 | u64 control; | 4125 | __le64 control; |
4126 | u64 buffer; | 4126 | __le64 buffer; |
4127 | }; | 4127 | }; |
4128 | 4128 | ||
4129 | /* descriptor ring for free buffers contains page-sized buffers. the index | 4129 | /* descriptor ring for free buffers contains page-sized buffers. the index |
@@ -4131,8 +4131,8 @@ struct cas_tx_desc { | |||
4131 | * the completion ring. | 4131 | * the completion ring. |
4132 | */ | 4132 | */ |
4133 | struct cas_rx_desc { | 4133 | struct cas_rx_desc { |
4134 | u64 index; | 4134 | __le64 index; |
4135 | u64 buffer; | 4135 | __le64 buffer; |
4136 | }; | 4136 | }; |
4137 | 4137 | ||
4138 | /* received packets are put on the completion ring. */ | 4138 | /* received packets are put on the completion ring. */ |
@@ -4210,10 +4210,10 @@ struct cas_rx_desc { | |||
4210 | #define RX_INDEX_RELEASE 0x0000000000002000ULL | 4210 | #define RX_INDEX_RELEASE 0x0000000000002000ULL |
4211 | 4211 | ||
4212 | struct cas_rx_comp { | 4212 | struct cas_rx_comp { |
4213 | u64 word1; | 4213 | __le64 word1; |
4214 | u64 word2; | 4214 | __le64 word2; |
4215 | u64 word3; | 4215 | __le64 word3; |
4216 | u64 word4; | 4216 | __le64 word4; |
4217 | }; | 4217 | }; |
4218 | 4218 | ||
4219 | enum link_state { | 4219 | enum link_state { |
@@ -4252,7 +4252,7 @@ struct cas_init_block { | |||
4252 | struct cas_rx_comp rxcs[N_RX_COMP_RINGS][INIT_BLOCK_RX_COMP]; | 4252 | struct cas_rx_comp rxcs[N_RX_COMP_RINGS][INIT_BLOCK_RX_COMP]; |
4253 | struct cas_rx_desc rxds[N_RX_DESC_RINGS][INIT_BLOCK_RX_DESC]; | 4253 | struct cas_rx_desc rxds[N_RX_DESC_RINGS][INIT_BLOCK_RX_DESC]; |
4254 | struct cas_tx_desc txds[N_TX_RINGS][INIT_BLOCK_TX]; | 4254 | struct cas_tx_desc txds[N_TX_RINGS][INIT_BLOCK_TX]; |
4255 | u64 tx_compwb; | 4255 | __le64 tx_compwb; |
4256 | }; | 4256 | }; |
4257 | 4257 | ||
4258 | /* tiny buffers to deal with target abort issue. we allocate a bit | 4258 | /* tiny buffers to deal with target abort issue. we allocate a bit |
diff --git a/net/ipv4/devinet.c b/net/ipv4/devinet.c index 3168c3de4919..b42f74617bac 100644 --- a/net/ipv4/devinet.c +++ b/net/ipv4/devinet.c | |||
@@ -1027,7 +1027,7 @@ static void inetdev_changename(struct net_device *dev, struct in_device *in_dev) | |||
1027 | memcpy(ifa->ifa_label, dev->name, IFNAMSIZ); | 1027 | memcpy(ifa->ifa_label, dev->name, IFNAMSIZ); |
1028 | if (named++ == 0) | 1028 | if (named++ == 0) |
1029 | continue; | 1029 | continue; |
1030 | dot = strchr(ifa->ifa_label, ':'); | 1030 | dot = strchr(old, ':'); |
1031 | if (dot == NULL) { | 1031 | if (dot == NULL) { |
1032 | sprintf(old, ":%d", named); | 1032 | sprintf(old, ":%d", named); |
1033 | dot = old; | 1033 | dot = old; |
diff --git a/net/x25/x25_forward.c b/net/x25/x25_forward.c index 8738ec7ce693..34478035e05e 100644 --- a/net/x25/x25_forward.c +++ b/net/x25/x25_forward.c | |||
@@ -118,13 +118,14 @@ int x25_forward_data(int lci, struct x25_neigh *from, struct sk_buff *skb) { | |||
118 | goto out; | 118 | goto out; |
119 | 119 | ||
120 | if ( (skbn = pskb_copy(skb, GFP_ATOMIC)) == NULL){ | 120 | if ( (skbn = pskb_copy(skb, GFP_ATOMIC)) == NULL){ |
121 | goto out; | 121 | goto output; |
122 | 122 | ||
123 | } | 123 | } |
124 | x25_transmit_link(skbn, nb); | 124 | x25_transmit_link(skbn, nb); |
125 | 125 | ||
126 | x25_neigh_put(nb); | ||
127 | rc = 1; | 126 | rc = 1; |
127 | output: | ||
128 | x25_neigh_put(nb); | ||
128 | out: | 129 | out: |
129 | return rc; | 130 | return rc; |
130 | } | 131 | } |
diff --git a/net/xfrm/xfrm_state.c b/net/xfrm/xfrm_state.c index ee1e69753932..f26aaaca1fae 100644 --- a/net/xfrm/xfrm_state.c +++ b/net/xfrm/xfrm_state.c | |||
@@ -1749,6 +1749,7 @@ void km_policy_expired(struct xfrm_policy *pol, int dir, int hard, u32 pid) | |||
1749 | } | 1749 | } |
1750 | EXPORT_SYMBOL(km_policy_expired); | 1750 | EXPORT_SYMBOL(km_policy_expired); |
1751 | 1751 | ||
1752 | #ifdef CONFIG_XFRM_MIGRATE | ||
1752 | int km_migrate(struct xfrm_selector *sel, u8 dir, u8 type, | 1753 | int km_migrate(struct xfrm_selector *sel, u8 dir, u8 type, |
1753 | struct xfrm_migrate *m, int num_migrate) | 1754 | struct xfrm_migrate *m, int num_migrate) |
1754 | { | 1755 | { |
@@ -1768,6 +1769,7 @@ int km_migrate(struct xfrm_selector *sel, u8 dir, u8 type, | |||
1768 | return err; | 1769 | return err; |
1769 | } | 1770 | } |
1770 | EXPORT_SYMBOL(km_migrate); | 1771 | EXPORT_SYMBOL(km_migrate); |
1772 | #endif | ||
1771 | 1773 | ||
1772 | int km_report(u8 proto, struct xfrm_selector *sel, xfrm_address_t *addr) | 1774 | int km_report(u8 proto, struct xfrm_selector *sel, xfrm_address_t *addr) |
1773 | { | 1775 | { |