aboutsummaryrefslogtreecommitdiffstats
path: root/tools/perf/scripts/python/bin/stackcollapse-report
diff options
context:
space:
mode:
authorVladimir Oltean <vladimir.oltean@nxp.com>2020-09-18 04:07:24 +0300
committerDavid S. Miller <davem@davemloft.net>2020-09-18 13:52:33 -0700
commit6565243c0677aa2befa5a953cf11bc7b4a6f0a47 (patch)
tree2b57ec438bfe55b8e25f47f4a7df5e7aae959545 /tools/perf/scripts/python/bin/stackcollapse-report
parentnet: mscc: ocelot: fix race condition with TX timestamping (diff)
downloadlinux-6565243c0677aa2befa5a953cf11bc7b4a6f0a47.tar.gz
linux-6565243c0677aa2befa5a953cf11bc7b4a6f0a47.zip
net: mscc: ocelot: add locking for the port TX timestamp ID
The ocelot_port->ts_id is used to: (a) populate skb->cb[0] for matching the TX timestamp in the PTP IRQ with an skb. (b) populate the REW_OP from the injection header of the ongoing skb. Only then is ocelot_port->ts_id incremented. This is a problem because, at least theoretically, another timestampable skb might use the same ocelot_port->ts_id before that is incremented. Normally all transmit calls are serialized by the netdev transmit spinlock, but in this case, ocelot_port_add_txtstamp_skb() is also called by DSA, which has started declaring the NETIF_F_LLTX feature since commit 2b86cb829976 ("net: dsa: declare lockless TX feature for slave ports"). So the logic of using and incrementing the timestamp id should be atomic per port. The solution is to use the global ocelot_port->ts_id only while protected by the associated ocelot_port->ts_id_lock. That's where we populate skb->cb[0]. Note that for ocelot, ocelot_port_add_txtstamp_skb is called for the actual skb, but for felix, it is called for the skb's clone. That is something which will also be changed in the future. Signed-off-by: Vladimir Oltean <vladimir.oltean@nxp.com> Reviewed-by: Horatiu Vultur <horatiu.vultur@microchip.com> Reviewed-by: Florian Fainelli <f.fainelli@gmail.com> Tested-by: Alexandre Belloni <alexandre.belloni@bootlin.com> Reviewed-by: Alexandre Belloni <alexandre.belloni@bootlin.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'tools/perf/scripts/python/bin/stackcollapse-report')
0 files changed, 0 insertions, 0 deletions
warningsRobin Murphy1-1/+1 2018-02-16arm64: mm: Use READ_ONCE/WRITE_ONCE when accessing page tablesWill Deacon13-399/+426 2018-02-16mm: hide a #warning for COMPILE_TESTArnd Bergmann1-1/+1 2018-02-16dm: correctly handle chained bios in dec_pending()NeilBrown1-1/+2 2018-02-16irqdomain: Re-use DEFINE_SHOW_ATTRIBUTE() macroAndy Shevchenko1-14/+4 2018-02-16irqchip/bcm: Remove hashed address printingJaedon Shin3-9/+0 2018-02-16irqchip/gic-v2m: Add PCI Multi-MSI supportMarc Zyngier1-24/+22 2018-02-16irqchip/gic-v3: Ignore disabled ITS nodesStephen Boyd4-0/+8 2018-02-16irqchip/gic-v3: Use wmb() instead of smb_wmb() in gic_raise_softirq()Shanker Donthineni1-1/+1 2018-02-16irqchip/gic-v3: Change pr_debug message to pr_develMark Salter1-1/+1 2018-02-16irqchip/mips-gic: Avoid spuriously handling masked interruptsMatt Redfearn1-2/+0 2018-02-16powerpc/pseries: Check for zero filled ibm,dynamic-memory propertyNathan Fontenot1-0/+8 2018-02-16cpumask: Make for_each_cpu_wrap() available on UP as wellMichael Kelley1-0/+2 2018-02-16x86/Kconfig: Explicitly enumerate i686-class CPUs in KconfigMatthew Whitehead1-1/+1 2018-02-16x86/Kconfig: Exclude i586-class CPUs lacking PAE support from the HIGHMEM64G ...Matthew Whitehead1-1/+1 2018-02-16x86/Kconfig: Add missing i586-class CPUs to the X86_CMPXCHG64 Kconfig groupMatthew Whitehead1-1/+1 2018-02-16kprobes: Propagate error from disarm_kprobe_ftrace()Jessica Yu1-25/+53 2018-02-16kprobes: Propagate error from arm_kprobe_ftrace()Jessica Yu1-25/+75 2018-02-16drm/nouveau: Make clock gate support conditionalThierry Reding1-3/+3 2018-02-15sparc,leon: Select USB_UHCI_BIG_ENDIAN_{MMIO,DESC}James Hogan2-2/+2 2018-02-15usb: Move USB_UHCI_BIG_ENDIAN_* out of USB_SUPPORTJames Hogan2-8/+8 2018-02-15block: fix a typo in comment of BLK_MQ_POLL_STATS_BKTSMinwoo Im1-1/+1 2018-02-15Revert "tools include s390: Grab a copy of arch/s390/include/uapi/asm/unistd.h"Hendrik Brueckner2-413/+0 2018-02-15perf s390: Rework system call table creation by using syscall.tblHendrik Brueckner2-14/+14