Index: sys/amd64/include/pcpu.h =================================================================== --- sys/amd64/include/pcpu.h +++ sys/amd64/include/pcpu.h @@ -179,34 +179,6 @@ *__PCPU_PTR(name) += __val; \ } while (0) -/* - * Increments the value of the per-cpu counter name. The implementation - * must be atomic with respect to interrupts. - */ -#define __PCPU_INC(name) do { \ - CTASSERT(sizeof(__pcpu_type(name)) == 1 || \ - sizeof(__pcpu_type(name)) == 2 || \ - sizeof(__pcpu_type(name)) == 4 || \ - sizeof(__pcpu_type(name)) == 8); \ - if (sizeof(__pcpu_type(name)) == 1) { \ - __asm __volatile("incb %%gs:%0" \ - : "=m" (*(__pcpu_type(name) *)(__pcpu_offset(name)))\ - : "m" (*(__pcpu_type(name) *)(__pcpu_offset(name))));\ - } else if (sizeof(__pcpu_type(name)) == 2) { \ - __asm __volatile("incw %%gs:%0" \ - : "=m" (*(__pcpu_type(name) *)(__pcpu_offset(name)))\ - : "m" (*(__pcpu_type(name) *)(__pcpu_offset(name))));\ - } else if (sizeof(__pcpu_type(name)) == 4) { \ - __asm __volatile("incl %%gs:%0" \ - : "=m" (*(__pcpu_type(name) *)(__pcpu_offset(name)))\ - : "m" (*(__pcpu_type(name) *)(__pcpu_offset(name))));\ - } else if (sizeof(__pcpu_type(name)) == 8) { \ - __asm __volatile("incq %%gs:%0" \ - : "=m" (*(__pcpu_type(name) *)(__pcpu_offset(name)))\ - : "m" (*(__pcpu_type(name) *)(__pcpu_offset(name))));\ - } \ -} while (0) - /* * Sets the value of the per-cpu variable name to value val. */ @@ -239,7 +211,6 @@ #define PCPU_GET(member) __PCPU_GET(pc_ ## member) #define PCPU_ADD(member, val) __PCPU_ADD(pc_ ## member, val) -#define PCPU_INC(member) __PCPU_INC(pc_ ## member) #define PCPU_PTR(member) __PCPU_PTR(pc_ ## member) #define PCPU_SET(member, val) __PCPU_SET(pc_ ## member, val) Index: sys/arm/include/pcpu.h =================================================================== --- sys/arm/include/pcpu.h +++ sys/arm/include/pcpu.h @@ -136,7 +136,6 @@ #define PCPU_GET(member) (get_pcpu()->pc_ ## member) #define PCPU_ADD(member, value) (get_pcpu()->pc_ ## member += (value)) -#define PCPU_INC(member) PCPU_ADD(member, 1) #define PCPU_PTR(member) (&get_pcpu()->pc_ ## member) #define PCPU_SET(member,value) (get_pcpu()->pc_ ## member = (value)) Index: sys/arm64/include/pcpu.h =================================================================== --- sys/arm64/include/pcpu.h +++ sys/arm64/include/pcpu.h @@ -73,7 +73,6 @@ #define PCPU_GET(member) (pcpup->pc_ ## member) #define PCPU_ADD(member, value) (pcpup->pc_ ## member += (value)) -#define PCPU_INC(member) PCPU_ADD(member, 1) #define PCPU_PTR(member) (&pcpup->pc_ ## member) #define PCPU_SET(member,value) (pcpup->pc_ ## member = (value)) Index: sys/i386/include/pcpu.h =================================================================== --- sys/i386/include/pcpu.h +++ sys/i386/include/pcpu.h @@ -169,29 +169,6 @@ *__PCPU_PTR(name) += __val; \ } while (0) -/* - * Increments the value of the per-cpu counter name. The implementation - * must be atomic with respect to interrupts. - */ -#define __PCPU_INC(name) do { \ - CTASSERT(sizeof(__pcpu_type(name)) == 1 || \ - sizeof(__pcpu_type(name)) == 2 || \ - sizeof(__pcpu_type(name)) == 4); \ - if (sizeof(__pcpu_type(name)) == 1) { \ - __asm __volatile("incb %%fs:%0" \ - : "=m" (*(__pcpu_type(name) *)(__pcpu_offset(name)))\ - : "m" (*(__pcpu_type(name) *)(__pcpu_offset(name))));\ - } else if (sizeof(__pcpu_type(name)) == 2) { \ - __asm __volatile("incw %%fs:%0" \ - : "=m" (*(__pcpu_type(name) *)(__pcpu_offset(name)))\ - : "m" (*(__pcpu_type(name) *)(__pcpu_offset(name))));\ - } else if (sizeof(__pcpu_type(name)) == 4) { \ - __asm __volatile("incl %%fs:%0" \ - : "=m" (*(__pcpu_type(name) *)(__pcpu_offset(name)))\ - : "m" (*(__pcpu_type(name) *)(__pcpu_offset(name))));\ - } \ -} while (0) - /* * Sets the value of the per-cpu variable name to value val. */ @@ -224,7 +201,6 @@ #define PCPU_GET(member) __PCPU_GET(pc_ ## member) #define PCPU_ADD(member, val) __PCPU_ADD(pc_ ## member, val) -#define PCPU_INC(member) __PCPU_INC(pc_ ## member) #define PCPU_PTR(member) __PCPU_PTR(pc_ ## member) #define PCPU_SET(member, val) __PCPU_SET(pc_ ## member, val) Index: sys/mips/include/pcpu.h =================================================================== --- sys/mips/include/pcpu.h +++ sys/mips/include/pcpu.h @@ -83,7 +83,6 @@ #define PCPU_ADD(member, value) (PCPUP->pc_ ## member += (value)) #define PCPU_GET(member) (PCPUP->pc_ ## member) -#define PCPU_INC(member) PCPU_ADD(member, 1) #define PCPU_PTR(member) (&PCPUP->pc_ ## member) #define PCPU_SET(member,value) (PCPUP->pc_ ## member = (value)) #define PCPU_LAZY_INC(member) (++PCPUP->pc_ ## member) Index: sys/powerpc/include/pcpu.h =================================================================== --- sys/powerpc/include/pcpu.h +++ sys/powerpc/include/pcpu.h @@ -168,7 +168,6 @@ * with respect to preemption. */ #define PCPU_ADD(member, value) (pcpup->pc_ ## member += (value)) -#define PCPU_INC(member) PCPU_ADD(member, 1) #define PCPU_PTR(member) (&pcpup->pc_ ## member) #define PCPU_SET(member,value) (pcpup->pc_ ## member = (value)) Index: sys/riscv/include/pcpu.h =================================================================== --- sys/riscv/include/pcpu.h +++ sys/riscv/include/pcpu.h @@ -79,7 +79,6 @@ #define PCPU_GET(member) (get_pcpu()->pc_ ## member) #define PCPU_ADD(member, value) (get_pcpu()->pc_ ## member += (value)) -#define PCPU_INC(member) PCPU_ADD(member, 1) #define PCPU_PTR(member) (&get_pcpu()->pc_ ## member) #define PCPU_SET(member,value) (get_pcpu()->pc_ ## member = (value))