lkml.org 
[lkml]   [2014]   [Dec]   [11]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
SubjectRe: [PATCH 09/22] [SCSI] mpt2sas, mpt3sas: Added a support to set cpu affinity for each MSIX vector enabled by the HBA
From
> @@ -1373,20 +1380,30 @@ _base_assign_reply_queues(struct MPT2SAS_ADAPTER *ioc)
>
> cpu = cpumask_first(cpu_online_mask);
>
> - do {
> + list_for_each_entry(reply_q, &ioc->reply_queue_list, list) {
> +
>
> Why are you reverting to iterating over the queues? A while back I fixed
> this up so it wouldn't fail when nr_cpus > the number of reply queues.
>

I have kept yours CPUs affinity with reply queues logic as it is. This
patch doesn't break any of it's original CPUs affinity with reply
queues calculation even when nr_cpus > the number of reply queues.
since below loop will help us to calculate CPU groups which needs to
affinity to particular reply queue when nr_cpus > the number of reply
queues

for (i = 0 ; i < group ; i++) {
ioc->cpu_msix_table[cpu] = index;
+ cpumask_or(reply_q->affinity_hint,
+ reply_q->affinity_hint, get_cpu_mask(cpu));
cpu = cpumask_next(cpu, cpu_online_mask);
}

I am iterating over the queues to get the MSIX vector number easily,
while calling irq_set_affinity_hint() API for setting CPUs affinity
hint for that MSIX vector.

Regards,
Sreekanth


\
 
 \ /
  Last update: 2014-12-11 13:21    [W:1.036 / U:0.564 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site