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


Groups > linux.kernel > #1612214

Re: [PATCH] irq/affinity: Assign all CPUs a vector

From Sagi Grimberg <sagi@grimberg.me>
Newsgroups linux.kernel
Subject Re: [PATCH] irq/affinity: Assign all CPUs a vector
Date 2017-03-29 20:00 +0200
Message-ID <tqq2Z-1Wd-21@gated-at.bofh.it> (permalink)
References <tq8z7-6vF-1@gated-at.bofh.it> <tqpqi-1xr-15@gated-at.bofh.it> <tqpTj-1P5-19@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


> Sure, I have a 2-socket server with 16 threads each. I take one CPU
> offline in socket 2, so I've 16 threads on socket 1, 15 in socket 2. In
> total, 31 threads so requesting 31 vectors.
>
> Currently, vecs_per_node is calculated in the first iteration as 31 / 2, so 15.
>
> ncpus of socket 1 is 16. cpus_per_vec = 16 / 15, so 1 CPU per vector
> with one extra.
>
> When iterating the second socket, though, vecs_per_node is incremented
> from 15 to 16 (to account for the "extra" from before). However, the
> ncpus is only 15, so that iteration calculates:
>
>   cpus_per_vec = 15 / 16
>
> And since that's zero, the remaining 16 vectors are not assigned to any
> CPU, and the second socket has no vectors assigned to their CPUs.

Thanks for the clarification, makes sense...

Reviewed-by: Sagi Grimberg <sagi@grimberg.me>

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


Thread

[PATCH] irq/affinity: Assign all CPUs a vector Keith Busch <keith.busch@intel.com> - 2017-03-29 01:20 +0200
  Re: [PATCH] irq/affinity: Assign all CPUs a vector Sagi Grimberg <sagi@grimberg.me> - 2017-03-29 19:20 +0200
    Re: [PATCH] irq/affinity: Assign all CPUs a vector Keith Busch <keith.busch@intel.com> - 2017-03-29 19:50 +0200
      Re: [PATCH] irq/affinity: Assign all CPUs a vector Sagi Grimberg <sagi@grimberg.me> - 2017-03-29 20:00 +0200
  Re: [PATCH] irq/affinity: Assign all CPUs a vector Christoph Hellwig <hch@lst.de> - 2017-03-30 10:30 +0200
    Re: [PATCH] irq/affinity: Assign all CPUs a vector Keith Busch <keith.busch@intel.com> - 2017-03-30 19:10 +0200
  Re: [PATCH] irq/affinity: Assign all CPUs a vector Thomas Gleixner <tglx@linutronix.de> - 2017-03-31 13:10 +0200

csiph-web