1. 12 8月, 2015 1 次提交
  2. 23 6月, 2015 1 次提交
    • A
      net: fs_enet: Fix NETIF_F_SG feature for Freescale MPC5121 · 26c0a14f
      Alexander Popov 提交于
      Commit 4fc9b87b ("net: fs_enet: Implement NETIF_F_SG feature")
      brings a trouble to Freescale MPC512x: a kernel oops happens
      during sending non-linear sk_buff with .data not aligned by 4.
      
      Log quotation:
      
      Unable to handle kernel paging request for data at address 0xe467c000
      Faulting instruction address: 0xc000cd44
      Oops: Kernel access of bad area, sig: 11 [#1]
      MPC512x generic
      Modules linked in:
      CPU: 0 PID: 984 Comm: kworker/0:1H Not tainted 4.1.0-rc8-00024-gbb16140a #2
      Workqueue: rpciod rpc_async_schedule
      task: cf364a50 ti: cf362000 task.ti: cf362000
      NIP: c000cd44 LR: c000c720 CTR: 00000206
      REGS: cf363ac0 TRAP: 0300   Not tainted  (4.1.0-rc8-00024-gbb16140a)
      MSR: 00009032 <EE,ME,IR,DR,RI>  CR: 42004082  XER: 00000000
      DAR: e467c000 DSISR: 20000000
      GPR00: c0279e24 cf363b70 cf364a50 e467c000 00000206 0000001f 00000001 00000001
      GPR08: 00000000 e467c000 e46800be 000139a6 82002082 00000000 c002e46c cf3c3680
      GPR16: c044cb30 c04b0000 cf363c48 00000000 00000001 fde0315c 00000000 0000000b
      GPR24: 0000002c 000040be cf339aa0 0000000b 00000001 cf873210 00282f85 00000000
      NIP [c000cd44] clean_dcache_range+0x1c/0x30
      LR [c000c720] dma_direct_map_page+0x40/0x94
      Call Trace:
      [cf363b70] [cf339b60] 0xcf339b60 (unreliable)
      [cf363b90] [c0279e24] fs_enet_start_xmit+0x1c8/0x42c
      [cf363bd0] [c02ff710] dev_hard_start_xmit+0x2dc/0x3d4
      [cf363c40] [c0319c60] sch_direct_xmit+0xcc/0x1cc
      [cf363c70] [c02ff9c0] __dev_queue_xmit+0x1b8/0x47c
      [cf363ca0] [c032a3e8] ip_finish_output+0x1fc/0x9a8
      [cf363ce0] [c032c31c] ip_send_skb+0x1c/0xa4
      [cf363cf0] [c035112c] udp_send_skb+0xe4/0x2e8
      [cf363d10] [c0351368] udp_push_pending_frames+0x38/0x84
      [cf363d20] [c03537b8] udp_sendpage+0x134/0x174
      [cf363d70] [c0384fd4] xs_sendpages+0x21c/0x250
      [cf363db0] [c03852bc] xs_udp_send_request+0x50/0xf8
      [cf363de0] [c0382f08] xprt_transmit+0x64/0x280
      [cf363e20] [c038017c] call_transmit+0x168/0x234
      [cf363e40] [c0387918] __rpc_execute+0x88/0x2b0
      [cf363e80] [c00296f8] process_one_work+0x124/0x2fc
      [cf363ea0] [c0029a00] worker_thread+0x130/0x480
      [cf363ef0] [c002e528] kthread+0xbc/0xd0
      [cf363f40] [c000e4a8] ret_from_kernel_thread+0x5c/0x64
      Instruction dump:
      7c70faa6 60630800 7c70fba6 4c00012c 4e800020 38a0001f 7c632878 7c832050
      7c842a14 5484d97f 4d820020 7c8903a6 <7c00186c> 38630020 4200fff8 7c0004ac
      ---[ end trace c846c1eceb513c85 ]---
      
      The reason:
      
      MPC5121 FEC requires 4-byte alignment for TX data buffer and calls
      tx_skb_align_workaround() for copying sk_buff with not aligned .data to a new
      sk_buff with aligned one. But tx_skb_align_workaround() uses
      skb_copy_from_linear_data() which doesn't work for non-linear sk_buff:
      a new sk_buff has non-zero nr_frags and zero .data_len.
      
      So improve the condition of calling tx_skb_align_workaround() and use
      skb_linearize() in it.
      Signed-off-by: NAlexander Popov <alex.popov@linux.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      26c0a14f
  3. 12 6月, 2015 1 次提交
  4. 18 3月, 2015 1 次提交
  5. 05 2月, 2015 1 次提交
  6. 20 10月, 2014 1 次提交
  7. 09 10月, 2014 2 次提交
    • L
      net: fs_enet: Add NAPI TX · d43a396a
      LEROY Christophe 提交于
      When using a MPC8xx as a router, 'perf' shows a significant time spent in
      fs_enet_interrupt() and fs_enet_start_xmit().
      'perf annotate' shows that the time spent in fs_enet_start_xmit is indeed spent
      between spin_unlock_irqrestore() and the following instruction, hence in
      interrupt handling. This is due to the TX complete interrupt that fires after
      each transmitted packet.
      This patch modifies the handling of TX complete to use NAPI.
      With this patch, my NAT router offers a throughput improved by 21%
      
      Original performance:
      
      [root@localhost tmp]# scp toto pgs:/tmp
      toto                                          100%  256MB   2.8MB/s   01:31
      
      Performance with the patch:
      
      [root@localhost tmp]# scp toto pgs:/tmp
      toto                                          100%  256MB   3.4MB/s   01:16
      Signed-off-by: NChristophe Leroy <christophe.leroy@c-s.fr>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      d43a396a
    • L
      net: fs_enet: Remove non NAPI RX · 583d4a68
      LEROY Christophe 提交于
      In the probe function, use_napi is inconditionnaly set to 1. This patch removes
      all the code which is conditional to !use_napi, and removes use_napi which has
      then become useless.
      Signed-off-by: NChristophe Leroy <christophe.leroy@c-s.fr>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      583d4a68
  8. 08 8月, 2014 1 次提交
  9. 23 5月, 2014 1 次提交
  10. 15 3月, 2014 1 次提交
  11. 17 1月, 2014 1 次提交
  12. 03 10月, 2013 1 次提交
  13. 23 8月, 2013 2 次提交
  14. 26 5月, 2013 1 次提交
  15. 10 3月, 2013 1 次提交
  16. 07 1月, 2013 1 次提交
  17. 04 12月, 2012 1 次提交
  18. 04 4月, 2012 1 次提交
  19. 20 3月, 2012 1 次提交
  20. 07 2月, 2012 1 次提交
  21. 29 11月, 2011 1 次提交
    • A
      net/ethernet: convert drivers/net/ethernet/* to use module_platform_driver() · db62f684
      Axel Lin 提交于
      This patch converts the drivers in drivers/net/ethernet/* to use the
      module_platform_driver() macro which makes the code smaller and a bit
      simpler.
      
      Cc: "David S. Miller" <davem@davemloft.net>
      Cc: Pantelis Antoniou <pantelis.antoniou@gmail.com>
      Cc: Vitaly Bordug <vbordug@ru.mvista.com>
      Cc: Wan ZongShun <mcuos.com@gmail.com>
      Cc: Nicolas Pitre <nico@fluxnic.net>
      Cc: Giuseppe Cavallaro <peppe.cavallaro@st.com>
      Cc: Marc Kleine-Budde <mkl@pengutronix.de>
      Cc: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
      Cc: Jiri Pirko <jpirko@redhat.com>
      Cc: Daniel Hellstrom <daniel@gaisler.com>
      Cc: Alexey Dobriyan <adobriyan@gmail.com>
      Cc: Tobias Klauser <tklauser@distanz.ch>
      Cc: Grant Likely <grant.likely@secretlab.ca>
      Cc: Jiri Kosina <jkosina@suse.cz>
      Cc: Richard Cochran <richard.cochran@omicron.at>
      Cc: Jonas Bonn <jonas@southpole.se>
      Cc: Sebastian Poehn <sebastian.poehn@belden.com>
      Cc: Yoshihiro Shimoda <yoshihiro.shimoda.uh@renesas.com>
      Cc: Ricardo Ribalda Delgado <ricardo.ribalda@gmail.com>
      Cc: "Michał Mirosław" <mirq-linux@rere.qmqm.pl>
      Signed-off-by: NAxel Lin <axel.lin@gmail.com>
      Acked-by: NWan ZongShun <mcuos.com@gmail.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      db62f684
  22. 18 8月, 2011 1 次提交
  23. 12 8月, 2011 1 次提交
    • J
      freescale: Move the Freescale drivers · ec21e2ec
      Jeff Kirsher 提交于
      Move the Freescale drivers into drivers/net/ethernet/freescale/ and
      make the necessary Kconfig and Makefile changes.
      
      CC: Sandeep Gopalpet <sandeep.kumar@freescale.com>
      CC: Andy Fleming <afleming@freescale.com>
      CC: Shlomi Gridish <gridish@freescale.com>
      CC: Li Yang <leoli@freescale.com>
      CC: Pantelis Antoniou <pantelis.antoniou@gmail.com>
      CC: Vitaly Bordug <vbordug@ru.mvista.com>
      CC: Dan Malek <dmalek@jlc.net>
      CC: Sylvain Munaut <tnt@246tNt.com>
      Signed-off-by: NJeff Kirsher <jeffrey.t.kirsher@intel.com>
      ec21e2ec
  24. 21 6月, 2011 1 次提交
  25. 19 5月, 2011 1 次提交
    • G
      drivercore: revert addition of of_match to struct device · b1608d69
      Grant Likely 提交于
      Commit b826291c, "drivercore/dt: add a match table pointer to struct
      device" added an of_match pointer to struct device to cache the
      of_match_table entry discovered at driver match time.  This was unsafe
      because matching is not an atomic operation with probing a driver.  If
      two or more drivers are attempted to be matched to a driver at the
      same time, then the cached matching entry pointer could get
      overwritten.
      
      This patch reverts the of_match cache pointer and reworks all users to
      call of_match_device() directly instead.
      Signed-off-by: NGrant Likely <grant.likely@secretlab.ca>
      b1608d69
  26. 11 4月, 2011 1 次提交
  27. 01 3月, 2011 1 次提交
  28. 01 11月, 2010 1 次提交
  29. 07 9月, 2010 1 次提交
    • J
      drivers/net/fs_enet/fs_enet-main.c: Add of_node_put to avoid memory leak · e8f7f43a
      Julia Lawall 提交于
      In this case, a device_node structure is stored in another structure that
      is then freed without first decrementing the reference count of the
      device_node structure.
      
      The semantic match that finds this problem is as follows:
      (http://coccinelle.lip6.fr/)
      
      // <smpl>
      @r exists@
      expression x;
      identifier f;
      position p1,p2;
      @@
      
      x@p1->f = \(of_find_node_by_path\|of_find_node_by_name\|of_find_node_by_phandle\|of_get_parent\|of_get_next_parent\|of_get_next_child\|of_find_compatible_node\|of_match_node\|of_find_node_by_type\|of_find_node_with_property\|of_find_matching_node\|of_parse_phandle\|of_node_get\)(...);
      ... when != of_node_put(x)
      kfree@p2(x)
      
      @script:python@
      p1 << r.p1;
      p2 << r.p2;
      @@
      cocci.print_main("call",p1)
      cocci.print_secs("free",p2)
      // </smpl>
      Signed-off-by: NJulia Lawall <julia@diku.dk>
      Acked-by: NWolfram Sang <w.sang@pengutronix.de>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      e8f7f43a
  30. 06 8月, 2010 1 次提交
  31. 19 7月, 2010 1 次提交
  32. 22 5月, 2010 1 次提交
    • G
      of: Remove duplicate fields from of_platform_driver · 4018294b
      Grant Likely 提交于
      .name, .match_table and .owner are duplicated in both of_platform_driver
      and device_driver.  This patch is a removes the extra copies from struct
      of_platform_driver and converts all users to the device_driver members.
      
      This patch is a pretty mechanical change.  The usage model doesn't change
      and if any drivers have been missed, or if anything has been fixed up
      incorrectly, then it will fail with a compile time error, and the fixup
      will be trivial.  This patch looks big and scary because it touches so
      many files, but it should be pretty safe.
      Signed-off-by: NGrant Likely <grant.likely@secretlab.ca>
      Acked-by: NSean MacLennan <smaclennan@pikatech.com>
      4018294b
  33. 19 5月, 2010 1 次提交
  34. 10 5月, 2010 1 次提交
  35. 27 2月, 2010 3 次提交
  36. 15 10月, 2009 1 次提交