- 24 6月, 2015 6 次提交
-
-
由 Achiad Shochat 提交于
NOP completion SKBs are always NULL. Signed-off-by: NAchiad Shochat <achiad@mellanox.com> Signed-off-by: NSaeed Mahameed <saeedm@mellanox.com> Signed-off-by: NOr Gerlitz <ogerlitz@mellanox.com> Signed-off-by: NDavid S. Miller <davem@davemloft.net>
-
由 Achiad Shochat 提交于
It is already assigned at mlx5e_build_rq_param() Signed-off-by: NAchiad Shochat <achiad@mellanox.com> Signed-off-by: NSaeed Mahameed <saeedm@mellanox.com> Signed-off-by: NOr Gerlitz <ogerlitz@mellanox.com> Signed-off-by: NDavid S. Miller <davem@davemloft.net>
-
由 Saeed Mahameed 提交于
Instead of counting number of gso fragments, we can use skb_shinfo(skb)->gso_segs. Signed-off-by: NSaeed Mahameed <saeedm@mellanox.com> Signed-off-by: NOr Gerlitz <ogerlitz@mellanox.com> Signed-off-by: NDavid S. Miller <davem@davemloft.net>
-
由 Saeed Mahameed 提交于
To save per-packet calculations, we use the following static mappings: 1) priv {channel, tc} to netdev txq (used @mlx5e_selec_queue()) 2) netdev txq to priv sq (used @mlx5e_xmit()) Thanks to these static mappings, no more need for a separate implementation of ndo_start_xmit when multiple TCs are configured. We believe the performance improvement of such separation would be negligible, if any. The previous way of dynamically calculating the above mappings required allocating more TX queues than actually used (@alloc_etherdev_mqs()), which is now no longer needed. Signed-off-by: NSaeed Mahameed <saeedm@mellanox.com> Signed-off-by: NOr Gerlitz <ogerlitz@mellanox.com> Signed-off-by: NDavid S. Miller <davem@davemloft.net>
-
由 Eran Ben Elisha 提交于
Under SRIOV, the port rx/tx bytes/packets statistics should by read from the HW instead of using the PF netdevice SW accounting. This is needed in order to get the full port statistics and not just the PF own ones Signed-off-by: NEran Ben Elisha <eranbe@mellanox.com> Signed-off-by: NOr Gerlitz <ogerlitz@mellanox.com> Signed-off-by: NDavid S. Miller <davem@davemloft.net>
-
由 Eran Ben Elisha 提交于
NUM_ALL_STATS was not updated with the new four entries, instead NUM_FLOW_STATS was updated, fix it. that caused off-by-four for all counters below pf_*_*. Fixes: b42de4d0 ('net/mlx4_en: Show PF own statistics via ethtool') Signed-off-by: NEran Ben Elisha <eranbe@mellanox.com> Signed-off-by: NOr Gerlitz <ogerlitz@mellanox.com> Signed-off-by: NDavid S. Miller <davem@davemloft.net>
-
- 23 6月, 2015 34 次提交
-
-
由 David S. Miller 提交于
Suman Tripathi says: ==================== drivers: net: xgene: Fix the ACPI support for RGMII/SGMII0/XFI ethernet interfaces of APM X-Gene SoC. ==================== Signed-off-by: NIyappan Subramanian <isubramanian@apm.com> Signed-off-by: NSuman Tripathi <stripathi@apm.com> Signed-off-by: NDavid S. Miller <davem@davemloft.net>
-
由 Suman Tripathi 提交于
This patches fixes the code to check for IS_ERR rather than NULL for clock interface. Signed-off-by: NIyappan Subramanian <isubramanian@apm.com> Signed-off-by: NSuman Tripathi <stripathi@apm.com> Signed-off-by: NDavid S. Miller <davem@davemloft.net>
-
由 Suman Tripathi 提交于
drivers: net: xgene: Add ACPI support for SGMII0 and XFI1 interface of 2nd H/W version of APM X-Gene SoC ethernet controller. This patch adds the ACPI support for SGMII0 and XFI1 interface of 2nd H/W version of APM X-Gene SoC ethernet controller. Signed-off-by: NIyappan Subramanian <isubramanian@apm.com> Signed-off-by: NSuman Tripathi <stripathi@apm.com> Signed-off-by: NDavid S. Miller <davem@davemloft.net>
-
由 Suman Tripathi 提交于
drivers: net: xgene: Implement the backward compatibility with the old and new firmware w.r.t Tx completion IRQ interrupt. This patch implements the backward compatibility with the old firmware where the Tx completion IRQ interrupt was absent whereas incase of new firmware the Tx completion IRQ interrupt is present. Signed-off-by: NIyappan Subramanian <isubramanian@apm.com> Signed-off-by: NSuman Tripathi <stripathi@apm.com> Signed-off-by: NDavid S. Miller <davem@davemloft.net>
-
由 Suman Tripathi 提交于
drivers: net: xgene: Fix the ACPI support for RGMII/SGMII0/XFI interface of APM X-Gene SoC ethernet controller. This patch implements couple of fixes to support ACPI for RGMII/SGMII0/XFI interface of APM X-Gene SoC ethernet controller driver. This patch uses the _SUN acpi object to fetch the port-id information whereas the FDT uses port-id binding for port-id information. Signed-off-by: NIyappan Subramanian <isubramanian@apm.com> Signed-off-by: NSuman Tripathi <stripathi@apm.com> Signed-off-by: NDavid S. Miller <davem@davemloft.net>
-
由 Noam Camus 提交于
Simple LAN device for debug or management purposes. Device supports interrupts for RX and TX(completion). Device does not have DMA ability. Signed-off-by: NNoam Camus <noamc@ezchip.com> Signed-off-by: NTal Zilcer <talz@ezchip.com> Acked-by: NAlexey Brodkin <abrodkin@synopsys.com> Signed-off-by: NDavid S. Miller <davem@davemloft.net>
-
由 Nimrod Andy 提交于
Below case causes mii bus probe failed: ifconfig eth0 down -> suspend/resume with Mega/fax mix off -> ifconfig eth0 up In i.MX6SX/i.MX7D chip, Mega/fast mix off feature is supported that means most of SOC power will be off including ENET MAC for power saving. Once ENET MAC power off, all initialized MAC registers reset to default, so in the case, it must init MAC prior to mii bus probe. Signed-off-by: NFugang Duan <B38611@freescale.com> Signed-off-by: NDavid S. Miller <davem@davemloft.net>
-
由 Anish Bhatt 提交于
While IEEE and CEE use the same structure to store apps, the selector and priority fields for both are different. Only the priority field is explained, add documentation explaining how the selector field differs for both. cgdcbxd code shows an example of how selector fields differ. Signed-off-by: NAnish Bhatt <anish@chelsio.com> Signed-off-by: NDavid S. Miller <davem@davemloft.net>
-
由 Scott Feldman 提交于
This particular BUG_ON condition was checking for attr set err in the COMMIT phase, which isn't expected (it's a driver bug if PREPARE phase is OK but COMMIT fails). But BUG_ON() is too strong for this case, so change to WARN(). BUG_ON() would be warranted if the system was corrupted beyond repair, but this is not the case here. Signed-off-by: NScott Feldman <sfeldma@gmail.com> Signed-off-by: NDavid S. Miller <davem@davemloft.net>
-
由 David S. Miller 提交于
Scott Feldman says: ==================== switchdev; add VLAN support for port's bridge_getlink One more missing piece of the puzzle. Add vlan dump support to switchdev port's bridge_getlink. iproute2 "bridge vlan show" cmd already knows how to show the vlans installed on the bridge and the device , but (until now) no one implemented the port vlan part of the netlink PF_BRIDGE:RTM_GETLINK msg. Before this patch, "bridge vlan show": $ bridge -c vlan show port vlan ids sw1p1 30-34 << bridge side vlans 57 sw1p1 << device side vlans (missing) sw1p2 57 sw1p2 sw1p3 sw1p4 br0 None (When the port is bridged, the output repeats the vlan list for the vlans on the bridge side of the port and the vlans on the device side of the port. The listing above show no vlans for the device side even though they are installed). After this patch: $ bridge -c vlan show port vlan ids sw1p1 30-34 << bridge side vlan 57 sw1p1 30-34 << device side vlans 57 3840 PVID sw1p2 57 sw1p2 57 3840 PVID sw1p3 3842 PVID sw1p4 3843 PVID br0 None ==================== Signed-off-by: NDavid S. Miller <davem@davemloft.net>
-
由 Scott Feldman 提交于
One more missing piece of the puzzle. Add vlan dump support to switchdev port's bridge_getlink. iproute2 "bridge vlan show" cmd already knows how to show the vlans installed on the bridge and the device , but (until now) no one implemented the port vlan part of the netlink PF_BRIDGE:RTM_GETLINK msg. Before this patch, "bridge vlan show": $ bridge -c vlan show port vlan ids sw1p1 30-34 << bridge side vlans 57 sw1p1 << device side vlans (missing) sw1p2 57 sw1p2 sw1p3 sw1p4 br0 None (When the port is bridged, the output repeats the vlan list for the vlans on the bridge side of the port and the vlans on the device side of the port. The listing above show no vlans for the device side even though they are installed). After this patch: $ bridge -c vlan show port vlan ids sw1p1 30-34 << bridge side vlan 57 sw1p1 30-34 << device side vlans 57 3840 PVID sw1p2 57 sw1p2 57 3840 PVID sw1p3 3842 PVID sw1p4 3843 PVID br0 None I re-used ndo_dflt_bridge_getlink to add vlan fill call-back func. switchdev support adds an obj dump for VLAN objects, using the same call-back scheme as FDB dump. Support included for both compressed and un-compressed vlan dumps. Signed-off-by: NScott Feldman <sfeldma@gmail.com> Signed-off-by: NDavid S. Miller <davem@davemloft.net>
-
由 Scott Feldman 提交于
Use vid_begin/end to be consistent with BRIDGE_VLAN_INFO_RANGE_BEGIN/END. Signed-off-by: NScott Feldman <sfeldma@gmail.com> Signed-off-by: NDavid S. Miller <davem@davemloft.net>
-
由 Maninder Singh 提交于
Remove handling of tx_ring in prb_setup_retire_blk_timer for TPACKET_V3 because init_prb_bdqc is called only for zero tx_ring and thus prb_setup_retire_blk_timer for zero tx_ring only. And also in functon init_prb_bdqc there is no usage of tx_ring. Thus removing tx_ring from init_prb_bdqc. Signed-off-by: NManinder Singh <maninder1.s@samsung.com> Suggested-by: NFrans Klaver <fransklaver@gmail.com> Signed-off-by: NDavid S. Miller <davem@davemloft.net>
-
由 Paul Gortmaker 提交于
This howto made sense in the 1990s when users had to manually configure ISA cards with jumpers or vendor utilities, but with the implementation of PCI it became increasingly less and less relevant, to the point where it has been well over a decade since I last updated it. And there is no value in anyone else taking over updating it either. However the references to it continue to spread as boiler plate text from one Kconfig file into the next. We are not doing end users any favours by pointing them at this old document, so lets kill it with fire, once and for all, to hopefully stop any further spread. No code is changed in this commit, just Kconfig help text. Signed-off-by: NPaul Gortmaker <paul.gortmaker@windriver.com> Signed-off-by: NDavid S. Miller <davem@davemloft.net>
-
由 David S. Miller 提交于
Heiko Stuebner says: ==================== net: stmmac: dwmac-rk: add support for rk3368 Apart from small cleanups, this series provides support for the dwmac on the new rk3368 ARM64 soc. Tested on a R88 board using a RMII phy. Changes since v1: - Adapt to changes resulting from patch d42202dc ("net: stmmac: dwmac-rk: Don't add function name in info or err messages") ==================== Signed-off-by: NDavid S. Miller <davem@davemloft.net>
-
由 Heiko Stübner 提交于
Add constants and callback functions for the dwmac on rk3368 socs. As can be seen, the base structure is the same, only registers and the bits in them moved slightly. Signed-off-by: NHeiko Stuebner <heiko@sntech.de> Signed-off-by: NDavid S. Miller <davem@davemloft.net>
-
由 Heiko Stübner 提交于
The mac settings like RGMII/RMII, speeds etc are done in the so called "General Register Files", contain numerous other settings as well and always seem to change between Rockchip SoCs. Therefore abstract the register accesses into a per-soc ops struct to make this reusable on other Rockchip SoCs. Signed-off-by: NHeiko Stuebner <heiko@sntech.de> Signed-off-by: NDavid S. Miller <davem@davemloft.net>
-
由 Heiko Stübner 提交于
The first iteration of the dwmac-rk support did access an intermediate clock directly below the pll selector. This was removed in a subsequent revision, but the clock and one invocation remained. This results in the driver trying to set the rate of a non-existent clock when the soc and not some external source provides the phy clock for RMII phys. So set the rate of the correct clock and remove the remaining now completely unused definition. Fixes: 436f5ae08f9d ("GMAC: add driver for Rockchip RK3288 SoCs integrated GMAC") Cc: stable@vger.kernel.org Signed-off-by: NHeiko Stuebner <heiko@sntech.de> Signed-off-by: NDavid S. Miller <davem@davemloft.net>
-
由 Heiko Stübner 提交于
In a first version the driver did want to do some gpio wiggling, which of course never made it into the kernel, but somehow these register defines where forgotten. Remove them, as they shouldn't be here. Signed-off-by: NHeiko Stuebner <heiko@sntech.de> Signed-off-by: NDavid S. Miller <davem@davemloft.net>
-
由 Andrew Lunn 提交于
Zero the statistics counters when setting up the global registers. Otherwise the counters will remain from the last boot if the power has not been removed. Signed-off-by: NAndrew Lunn <andrew@lunn.ch> Signed-off-by: NDavid S. Miller <davem@davemloft.net>
-
由 David S. Miller 提交于
Andrew Lunn says: ==================== debugfs for mv88e6xxx This patchset adds some debugfs files for seeing into a mv88e6xxx family of switch chips. DB T/P Vec State Addr 003 Port 008 7 00:22:02:00:18:44 003 Port 008 6 80:ee:73:83:60:27 005 Port 020 7 94:10:3e:80:bc:f3 0f8 Port 001 6 8e:25:13:53:44:de This walks all possible entries, so is a bit slow, but is always correct. Target Port 0 15 1 15 2 15 3 15 4 15 5 15 6 15 7 15 8 15 9 15 -->snip<-- 31 15 A rather boring example, since i only have one switch here. But this shows the routing between multiple switches. GLOBAL GLOBAL2 0 1 2 3 4 5 6 0: c804 0 1e4f 100f 100f 1e4f 1e0f e07 e07 1: fe 0 3 3 3 3 3 c03e c03f 2: 0 ffff 0 0 0 0 0 0 0 3: 0 ffff 1721 1721 1721 1721 1721 1721 1721 4: 6000 258 433 431 431 433 433 373f 433 5: 0 ff 0 0 0 0 0 0 0 6: c000 1f0f 2026 2025 2023 3020 4020 501f 6020 7: 0 707f 0 0 0 0 0 0 0 8: 0 7800 2080 2080 2080 2080 2080 2080 2080 9: 0 1600 1 1 1 1 1 1 1 a: 148 0 0 0 0 0 0 0 0 b: 4000 1000 1 2 4 8 10 20 40 c: 0 7f 0 0 0 0 0 0 0 d: ffff 5f3 0 0 0 0 0 0 0 e: ffff 6 0 0 0 0 0 0 0 f: ffff f00 dada dada dada dada dada dada dada 10: 0 0 0 0 0 0 0 0 0 11: 0 0 0 0 0 0 0 0 0 12: 5555 0 0 0 0 0 0 0 0 13: 5555 0 1a 0 0 1df0 0 1e07 0 14: aaaa 400 0 0 0 0 0 0 0 15: aaaa 0 0 0 0 0 0 0 0 16: ffff 0 6011 6011 6011 6011 33 33 0 17: ffff 0 0 0 0 0 0 0 0 18: fa41 1844 3210 3210 3210 3210 3210 3210 3210 19: 0 1e1 7654 7654 7654 7654 7654 7654 7654 1a: 5550 0 0 0 0 0 0 0 0 1b: 1fb f869 8000 8000 8000 8000 8000 8000 8000 1c: 0 0 0 0 0 0 0 0 0 1d: c00 0 0 0 0 0 0 0 0 1e: 0 0 0 0 0 0 0 0 0 1f: 0 0 0 0 0 0 0 0 0 All the switch registers which are directly accessible. Statistic Port 0 Port 1 Port 2 Port 3 Port 4 Port 5 Port 6 in_good_octets: 2176 0 0 4263711 0 499540 0 in_bad_octets: 46050 0 0 50196 0 0 0 in_unicast: 0 0 0 7693 0 7691 0 in_broadcasts: 0 0 0 0 0 3 0 in_multicasts: 34 0 0 0 0 27 0 in_pause: 0 0 0 0 0 0 0 in_undersize: 0 0 0 0 0 0 0 in_fragments: 45 0 0 2 0 0 0 in_oversize: 0 0 0 0 0 0 0 in_jabber: 0 0 0 0 0 0 0 in_rx_error: 0 0 0 0 0 0 0 in_fcs_error: 159 0 0 37 0 0 0 out_octets: 808 0 0 496608 336 4267159 0 out_unicast: 0 0 0 7691 0 7693 0 out_broadcasts: 1 0 0 3 0 0 0 out_multicasts: 9 0 0 6 4 34 0 out_pause: 0 0 0 0 0 0 0 excessive: 0 0 0 0 0 0 0 collisions: 0 0 0 0 0 0 0 deferred: 0 0 0 0 0 0 0 single: 0 0 0 0 0 0 0 multiple: 0 0 0 0 0 0 0 out_fcs_error: 0 0 0 0 0 0 0 late: 0 0 0 0 0 0 0 hist_64bytes: 36 0 0 7577 0 7574 0 hist_65_127bytes: 53 0 0 241 4 298 0 hist_128_255bytes: 50 0 0 12 0 10 0 hist_256_511bytes: 43 0 0 8 0 2 0 hist_512_1023bytes: 18 0 0 7573 0 7564 0 hist_1024_max_bytes: 3 0 0 19 0 0 0 sw_in_discards: 0 0 0 0 0 0 0 sw_in_filtered: 0 0 0 0 0 0 0 sw_out_filtered: 34 0 0 7693 0 7721 0 Of particular interest here is that you get to see all ports, including the CPU port and any DSA ports. You cannot get statistics for these ports via ethtool. ==================== Signed-off-by: NDavid S. Miller <davem@davemloft.net>
-
由 Andrew Lunn 提交于
Allow the contents of the scratch registers to be shown in debugfs. Signed-off-by: NAndrew Lunn <andrew@lunn.ch> Signed-off-by: NDavid S. Miller <davem@davemloft.net>
-
由 Andrew Lunn 提交于
The device map is used to route packets between cascaded switches. Add dumping a switches device map via debugfs. Signed-off-by: NAndrew Lunn <andrew@lunn.ch> Signed-off-by: NDavid S. Miller <davem@davemloft.net>
-
由 Andrew Lunn 提交于
Allow the contents of the statistics counters to be shown in debugfs. This is particularly useful for the cpu and dsa ports, which cannot be seen using ethtools -S. Signed-off-by: NAndrew Lunn <andrew@lunn.ch> Signed-off-by: NDavid S. Miller <davem@davemloft.net>
-
由 Andrew Lunn 提交于
Move the code to retrieve a statistics counter into a function of its own, so it can later be reused. Signed-off-by: NAndrew Lunn <andrew@lunn.ch> Signed-off-by: NDavid S. Miller <davem@davemloft.net>
-
由 Andrew Lunn 提交于
Dump the Address Translation Unit via a file in debugfs. Signed-off-by: NAndrew Lunn <andrew@lunn.ch> Signed-off-by: NDavid S. Miller <davem@davemloft.net>
-
由 Andrew Lunn 提交于
Allow the contents of the registers to be shown in debugfs. Signed-off-by: NAndrew Lunn <andrew@lunn.ch> Signed-off-by: NDavid S. Miller <davem@davemloft.net>
-
由 Shreyas Bhatewara 提交于
Make the driver understand adapter version 2. Cc: Rachel Lunnon <rachel_lunnon@stormagic.com> Signed-off-by: NGuolin Yang <gyang@vmware.com> Signed-off-by: NShreyas N Bhatewara <sbhatewara@vmware.com> Signed-off-by: NDavid S. Miller <davem@davemloft.net>
-
由 Shreyas Bhatewara 提交于
If rcd length was zero, the page used for frag was not being released. It was being replaced with a newly allocated page. This change takes care of that memory leak. Signed-off-by: NGuolin Yang <gyang@vmware.com> Signed-off-by: NShreyas N Bhatewara <sbhatewara@vmware.com> Signed-off-by: NDavid S. Miller <davem@davemloft.net>
-
由 Shreyas Bhatewara 提交于
Implement a handler for pci shutdown so that the driver has an opportunity to make sure that device is quiesced before the PCI switches to legacy IRQs. This way the possibility of "screaming interrupt" is avoided. Acked-by: NShrikrishna Khare <skhare@vmware.com> Signed-off-by: NShreyas N Bhatewara <sbhatewara@vmware.com> Signed-off-by: NDavid S. Miller <davem@davemloft.net>
-
由 Eric W. Biederman 提交于
Add code to nf_unregister_hook to flush the nf_queue when a hook is unregistered. This guarantees that the pointer that the nf_queue code retains into the nf_hook list will remain valid while a packet is queued. I tested what would happen if we do not flush queued packets and was trivially able to obtain the oops below. All that was required was to stop the nf_queue listening process, to delete all of the nf_tables, and to awaken the nf_queue listening process. > BUG: unable to handle kernel paging request at 0000000100000001 > IP: [<0000000100000001>] 0x100000001 > PGD b9c35067 PUD 0 > Oops: 0010 [#1] SMP > Modules linked in: > CPU: 0 PID: 519 Comm: lt-nfqnl_test Not tainted > task: ffff8800b9c8c050 ti: ffff8800ba9d8000 task.ti: ffff8800ba9d8000 > RIP: 0010:[<0000000100000001>] [<0000000100000001>] 0x100000001 > RSP: 0018:ffff8800ba9dba40 EFLAGS: 00010a16 > RAX: ffff8800bab48a00 RBX: ffff8800ba9dba90 RCX: ffff8800ba9dba90 > RDX: ffff8800b9c10128 RSI: ffff8800ba940900 RDI: ffff8800bab48a00 > RBP: ffff8800b9c10128 R08: ffffffff82976660 R09: ffff8800ba9dbb28 > R10: dead000000100100 R11: dead000000200200 R12: ffff8800ba940900 > R13: ffffffff8313fd50 R14: ffff8800b9c95200 R15: 0000000000000000 > FS: 00007fb91fc34700(0000) GS:ffff8800bfa00000(0000) knlGS:0000000000000000 > CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033 > CR2: 0000000100000001 CR3: 00000000babfb000 CR4: 00000000000007f0 > Stack: > ffffffff8206ab0f ffffffff82982240 ffff8800bab48a00 ffff8800b9c100a8 > ffff8800b9c10100 0000000000000001 ffff8800ba940900 ffff8800b9c10128 > ffffffff8206bd65 ffff8800bfb0d5e0 ffff8800bab48a00 0000000000014dc0 > Call Trace: > [<ffffffff8206ab0f>] ? nf_iterate+0x4f/0xa0 > [<ffffffff8206bd65>] ? nf_reinject+0x125/0x190 > [<ffffffff8206dee5>] ? nfqnl_recv_verdict+0x255/0x360 > [<ffffffff81386290>] ? nla_parse+0x80/0xf0 > [<ffffffff8206c42c>] ? nfnetlink_rcv_msg+0x13c/0x240 > [<ffffffff811b2fec>] ? __memcg_kmem_get_cache+0x4c/0x150 > [<ffffffff8206c2f0>] ? nfnl_lock+0x20/0x20 > [<ffffffff82068159>] ? netlink_rcv_skb+0xa9/0xc0 > [<ffffffff820677bf>] ? netlink_unicast+0x12f/0x1c0 > [<ffffffff82067ade>] ? netlink_sendmsg+0x28e/0x650 > [<ffffffff81fdd814>] ? sock_sendmsg+0x44/0x50 > [<ffffffff81fde07b>] ? ___sys_sendmsg+0x2ab/0x2c0 > [<ffffffff810e8f73>] ? __wake_up+0x43/0x70 > [<ffffffff8141a134>] ? tty_write+0x1c4/0x2a0 > [<ffffffff81fde9f4>] ? __sys_sendmsg+0x44/0x80 > [<ffffffff823ff8d7>] ? system_call_fastpath+0x12/0x6a > Code: Bad RIP value. > RIP [<0000000100000001>] 0x100000001 > RSP <ffff8800ba9dba40> > CR2: 0000000100000001 > ---[ end trace 08eb65d42362793f ]--- Cc: stable@vger.kernel.org Signed-off-by: N"Eric W. Biederman" <ebiederm@xmission.com> Signed-off-by: NDavid S. Miller <davem@davemloft.net>
-
由 Eric W. Biederman 提交于
Currenlty nf_tables chains added in one network namespace are being run in all network namespace. The issues are myriad with the simplest being an unprivileged user can cause any network packets to be dropped. Address this by simply not running nf_tables chains in the wrong network namespace. Cc: stable@vger.kernel.org Signed-off-by: N"Eric W. Biederman" <ebiederm@xmission.com> Acked-by: NPablo Neira Ayuso <pablo@netfilter.org> Signed-off-by: NDavid S. Miller <davem@davemloft.net>
-
由 Pankaj Gupta 提交于
Macvtap should be compatible with tuntap for maximum number of queues. commit 'baf71c5c (tuntap: Increase the number of queues in tun.)' removes the limitations and increases number of queues in tuntap. Now, Its safe to increase number of queues in Macvtap as well. This patch also modifies 'macvtap_del_queues' function to avoid extra memory allocation in stack. Changes from v1->v2 : Michael S. Tsirkin, Jason Wang : Better way to use linked list to avoid use of extra memory in stack. Sergei Shtylyov : Specify dependent commit's summary. Signed-off-by: NPankaj Gupta <pagupta@redhat.com> Signed-off-by: NDavid S. Miller <davem@davemloft.net>
-
由 Daniel Wagner 提交于
BPF offers another way to generate latency histograms. We attach kprobes at trace_preempt_off and trace_preempt_on and calculate the time it takes to from seeing the off/on transition. The first array is used to store the start time stamp. The key is the CPU id. The second array stores the log2(time diff). We need to use static allocation here (array and not hash tables). The kprobes hooking into trace_preempt_on|off should not calling any dynamic memory allocation or free path. We need to avoid recursivly getting called. Besides that, it reduces jitter in the measurement. CPU 0 latency : count distribution 1 -> 1 : 0 | | 2 -> 3 : 0 | | 4 -> 7 : 0 | | 8 -> 15 : 0 | | 16 -> 31 : 0 | | 32 -> 63 : 0 | | 64 -> 127 : 0 | | 128 -> 255 : 0 | | 256 -> 511 : 0 | | 512 -> 1023 : 0 | | 1024 -> 2047 : 0 | | 2048 -> 4095 : 166723 |*************************************** | 4096 -> 8191 : 19870 |*** | 8192 -> 16383 : 6324 | | 16384 -> 32767 : 1098 | | 32768 -> 65535 : 190 | | 65536 -> 131071 : 179 | | 131072 -> 262143 : 18 | | 262144 -> 524287 : 4 | | 524288 -> 1048575 : 1363 | | CPU 1 latency : count distribution 1 -> 1 : 0 | | 2 -> 3 : 0 | | 4 -> 7 : 0 | | 8 -> 15 : 0 | | 16 -> 31 : 0 | | 32 -> 63 : 0 | | 64 -> 127 : 0 | | 128 -> 255 : 0 | | 256 -> 511 : 0 | | 512 -> 1023 : 0 | | 1024 -> 2047 : 0 | | 2048 -> 4095 : 114042 |*************************************** | 4096 -> 8191 : 9587 |** | 8192 -> 16383 : 4140 | | 16384 -> 32767 : 673 | | 32768 -> 65535 : 179 | | 65536 -> 131071 : 29 | | 131072 -> 262143 : 4 | | 262144 -> 524287 : 1 | | 524288 -> 1048575 : 364 | | CPU 2 latency : count distribution 1 -> 1 : 0 | | 2 -> 3 : 0 | | 4 -> 7 : 0 | | 8 -> 15 : 0 | | 16 -> 31 : 0 | | 32 -> 63 : 0 | | 64 -> 127 : 0 | | 128 -> 255 : 0 | | 256 -> 511 : 0 | | 512 -> 1023 : 0 | | 1024 -> 2047 : 0 | | 2048 -> 4095 : 40147 |*************************************** | 4096 -> 8191 : 2300 |* | 8192 -> 16383 : 828 | | 16384 -> 32767 : 178 | | 32768 -> 65535 : 59 | | 65536 -> 131071 : 2 | | 131072 -> 262143 : 0 | | 262144 -> 524287 : 1 | | 524288 -> 1048575 : 174 | | CPU 3 latency : count distribution 1 -> 1 : 0 | | 2 -> 3 : 0 | | 4 -> 7 : 0 | | 8 -> 15 : 0 | | 16 -> 31 : 0 | | 32 -> 63 : 0 | | 64 -> 127 : 0 | | 128 -> 255 : 0 | | 256 -> 511 : 0 | | 512 -> 1023 : 0 | | 1024 -> 2047 : 0 | | 2048 -> 4095 : 29626 |*************************************** | 4096 -> 8191 : 2704 |** | 8192 -> 16383 : 1090 | | 16384 -> 32767 : 160 | | 32768 -> 65535 : 72 | | 65536 -> 131071 : 32 | | 131072 -> 262143 : 26 | | 262144 -> 524287 : 12 | | 524288 -> 1048575 : 298 | | All this is based on the trace3 examples written by Alexei Starovoitov <ast@plumgrid.com>. Signed-off-by: NDaniel Wagner <daniel.wagner@bmw-carit.de> Cc: Alexei Starovoitov <ast@plumgrid.com> Cc: Alexei Starovoitov <ast@plumgrid.com> Cc: "David S. Miller" <davem@davemloft.net> Cc: Daniel Borkmann <daniel@iogearbox.net> Cc: Ingo Molnar <mingo@kernel.org> Cc: linux-kernel@vger.kernel.org Cc: netdev@vger.kernel.org Acked-by: NAlexei Starovoitov <ast@plumgrid.com> Acked-by: NDaniel Borkmann <daniel@iogearbox.net> Signed-off-by: NDavid S. Miller <davem@davemloft.net>
-