Skip to content

percpu: Implement Preemption checks for __this_cpu operations V4b

Christoph Lameter lkml 1 version In review

Get series with b4
b4 am [email protected]

Versions newest first

  1. v1 Latest6 patches 25 repliesIn review

V3->v4 from the cover letter

- Drop CONFIG_DEBUG_THIS_CPU_OPERATIONS
- Detail operation triggering the log entry.
- Use quilt 0.60/ [PATCH] prefix.
- Clean up subject lines.
- Include raw_cpu_ops conversion/fixes that were tested on a Ubuntu 13.04 desktop.
- Traces

Patches in v1 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/6net: ip4_datagram_connect: Use correct form of statistics updatenet/ipv4/datagram.c+1 -17 replies
2/6percpu: Add raw_cpu_opsinclude/linux/percpu.h+74 -110 replies
3/6mm: Use raw_cpu ops for determining current NUMA nodeinclude/linux/topology.h+2 -22 replies
4/6Use raw_cpu_write for initialization of per cpu refcount.kernel/module.c+1 -11 reply
5/6net: __this_cpu_inc in route.cnet/ipv4/route.c+1 -14 replies
6/6percpu: Add preemption checks to __this_cpu opsinclude/linux/percpu.h lib/smp_processor_id.c+59 -1411 replies

Reviews trailers per patch

1 of 6 patches has a Reviewed-by or Acked-by.

PatchEric DumazetIngo Molnar
1/6A-b A-b
2/6
3/6
4/6
5/6
6/6

Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.

Read the v1 thread

Cover letter [PATCH 0/6] percpu: Implement Preemption checks for __this_cpu operations V4b

** Resending using Comcast instead of Amazon SES.

This patchset introduces preemption checks for __this_cpu operations.

First we add new raw_cpu operations that perform this cpu operations without preempt checks in the future.

Then those raw_cpu operations are used in a number of locations to avoid false positives.

The last patch then adds the preemption checks by modifying the __this_cpu macros in include/linux/percpu.h

V3->v4:
- Drop CONFIG_DEBUG_THIS_CPU_OPERATIONS
- Detail operation triggering the log entry.
- Use quilt 0.60/ [PATCH] prefix.
- Clean up subject lines.
- Include raw_cpu_ops conversion/fixes that were tested on a Ubuntu 13.04 desktop.
- Traces

V2->V3:
- Subject line in the raw_cpu_ops patch had ; instead of :. Guess I am getting old.
- Improve descriptions and variable names.
- Run tests again with kvm to verify that it still works.
A) No warnings with just the patches applied
B) Lots of warnings with CONFIG_DEBUG_THIS_CPU_OPERATIONS enabled
C) No warnings with 3 core patches applied that simply convert __this_cpu operations to raw_cpu_ops.

V1->V2:
- Reuse preemption check logic in lib/smp_processor_id.c
- Add CONFIG_DEBUG_THIS_CPU_OPERATIONS
- Remove conversions to the use of raw_cpu_ops since these may require some discussion first.