Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1260829

Re: [PATCH v6 2/3] percpu: add PERCPU_ATOM_SIZE for a generic percpu area setup

From Catalin Marinas <catalin.marinas@arm.com>
Newsgroups linux.kernel
Subject Re: [PATCH v6 2/3] percpu: add PERCPU_ATOM_SIZE for a generic percpu area setup
Date 2015-11-02 18:40 +0100
Message-ID <qqrfj-8a7-13@gated-at.bofh.it> (permalink)
References <qpVyN-5qp-3@gated-at.bofh.it> <qpVyN-5qp-1@gated-at.bofh.it> <qqpZU-7ux-15@gated-at.bofh.it> <qqq9B-7xI-21@gated-at.bofh.it> <qqqsW-7Ek-11@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


On Mon, Nov 02, 2015 at 10:48:17AM -0600, Christoph Lameter wrote:
> On Mon, 2 Nov 2015, Catalin Marinas wrote:
> > I haven't looked at the patch 3/3 in detail but I'm pretty sure I'll NAK
> > the approach (and the definition of PERCPU_ATOM_SIZE), therefore
> > rendering this patch unnecessary. IIUC, this is used to enforce some
> > alignment of the per-CPU IRQ stack to be able to check whether the
> > current stack is process or IRQ on exception entry. But there are other,
> > less intrusive ways to achieve the same (e.g. x86).
> 
> The percpu allocator allows the specification of alignment requirements.

Patch 3/3 does something like this:

DEFINE_PER_CPU(char [IRQ_STACK_SIZE], irq_stacks) __aligned(IRQ_STACK_SIZE)

where IRQ_STACK_SIZE > PAGE_SIZE. AFAICT, setup_per_cpu_areas() doesn't
guarantee alignment greater than PAGE_SIZE.

-- 
Catalin
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Back to linux.kernel | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

[PATCH v6 2/3] percpu: add PERCPU_ATOM_SIZE for a generic percpu area setup Jungseok Lee <jungseoklee85@gmail.com> - 2015-11-01 08:50 +0100
  Re: [PATCH v6 2/3] percpu: add PERCPU_ATOM_SIZE for a generic percpu  area setup Christoph Lameter <cl@linux.com> - 2015-11-02 17:20 +0100
    Re: [PATCH v6 2/3] percpu: add PERCPU_ATOM_SIZE for a generic percpu  area setup Catalin Marinas <catalin.marinas@arm.com> - 2015-11-02 17:30 +0100
      Re: [PATCH v6 2/3] percpu: add PERCPU_ATOM_SIZE for a generic percpu  area setup Christoph Lameter <cl@linux.com> - 2015-11-02 17:50 +0100
        Re: [PATCH v6 2/3] percpu: add PERCPU_ATOM_SIZE for a generic percpu  area setup Catalin Marinas <catalin.marinas@arm.com> - 2015-11-02 18:40 +0100
          Re: [PATCH v6 2/3] percpu: add PERCPU_ATOM_SIZE for a generic percpu  area setup Christoph Lameter <cl@linux.com> - 2015-11-02 19:20 +0100
            Re: [PATCH v6 2/3] percpu: add PERCPU_ATOM_SIZE for a generic percpu  area setup Catalin Marinas <catalin.marinas@arm.com> - 2015-11-02 19:40 +0100
      Re: [PATCH v6 2/3] percpu: add PERCPU_ATOM_SIZE for a generic percpu area setup Jungseok Lee <jungseoklee85@gmail.com> - 2015-11-03 15:00 +0100
        Re: [PATCH v6 2/3] percpu: add PERCPU_ATOM_SIZE for a generic percpu  area setup James Morse <james.morse@arm.com> - 2015-11-03 19:00 +0100
          Re: [PATCH v6 2/3] percpu: add PERCPU_ATOM_SIZE for a generic percpu area setup Jungseok Lee <jungseoklee85@gmail.com> - 2015-11-04 14:40 +0100
    Re: [PATCH v6 2/3] percpu: add PERCPU_ATOM_SIZE for a generic percpu area setup Jungseok Lee <jungseoklee85@gmail.com> - 2015-11-03 15:20 +0100

csiph-web