Received: by 2002:a9a:4c47:0:b029:116:c383:538 with SMTP id u7csp977095lko; Tue, 13 Jul 2021 14:18:15 -0700 (PDT) X-Google-Smtp-Source: ABdhPJyEKczLrkZEsLlWl/fVMqGyrJrbUX5ZOab3mg4SzT/BFucXroyoIA2pEMqVtLEdxRUy4Lwi X-Received: by 2002:a05:6402:111a:: with SMTP id u26mr8206213edv.260.1626211095260; Tue, 13 Jul 2021 14:18:15 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1626211095; cv=none; d=google.com; s=arc-20160816; b=G9V7F5h4IFPlxLTBDkDbtNdVHIELEpaVucgiq7TtYb0f4jWS7Ykdcp1irD6borTI/X w+ym90efuuYDlslIg6WpLxIPhao5bMth6KEJ7z1SE4OWbFBD1X8Jv+Kd1kJZy1iAQFiA lx+3wwVRq/O3YP2w7K3QHQov8UILp11Ql36Tpnb75PM5WSTStlB5tzYbqAO+E9UzgY8c WJCLW4XtjNgrdPcJBxfly/OEG4ckWtIOMvjMtb3mExM4KaSJqBnktdIY0u9IwD2Oacvm /aVQEmeuA9Cx2LlqNZdYl8RK13kOCdO9gu9r+1sEpISVMUbx3geRIYMsEmh9nW8NlcdG m4NQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:to:from :dkim-signature; bh=kZjBQU8J13gPpGhDK2j5njwWymkpgNNC/KZJDSdOSNw=; b=mwAmr06fFP65QnOmjW82ldXjzA7dIlKYW9F16Pqwz3/dgIGZya0gRUYdXyXBZEF79H cb2fu8mjRGx8CEk1P6lWRAIuaaUfh0XlpWs2FuSzjxPmBpjfu2xtjHGCa6rocqHM0FKa 4Up8USr27PRj6lQC5VaOKWw9qS5AZ5bEj/U1QBdCMeP8uho6P56dtkNZkAK5iJfypup+ 5wWrXK5aSd0qYR5Ir7GUeWCDHHvUm7+EM9sgGr3SMuhtJ0mpBur2uOZ7+CSuGg/b0S3T 0ztkMi0hvER0MM4xWkAnBdRYg8Oah52AOET1iXugUce9czQvuQ1pEc4kaEGiSDd01NE9 43gA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@redhat.com header.s=mimecast20190719 header.b=Fcsn3AWN; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=redhat.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id t24si2731692edr.590.2021.07.13.14.17.52; Tue, 13 Jul 2021 14:18:15 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@redhat.com header.s=mimecast20190719 header.b=Fcsn3AWN; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=redhat.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S236377AbhGMVTI (ORCPT + 99 others); Tue, 13 Jul 2021 17:19:08 -0400 Received: from us-smtp-delivery-124.mimecast.com ([170.10.133.124]:39205 "EHLO us-smtp-delivery-124.mimecast.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S236312AbhGMVTD (ORCPT ); Tue, 13 Jul 2021 17:19:03 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1626210972; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=kZjBQU8J13gPpGhDK2j5njwWymkpgNNC/KZJDSdOSNw=; b=Fcsn3AWNYHQiTWm1iw2EJdlWHOjX7tidoFE8qv68rGLoHTaEpnQe8LeFl+i38uO//XSY/R 15MRvRdJOf+CUsA4VQ9Ija3GPkaOdg+qYpfhDIPkIC8hU+OAZ1DNk6xfN542B6WXigiUcM 7/QifIr5II8xkvYEOPc3OeatYj3CKmI= Received: from mimecast-mx01.redhat.com (mimecast-mx01.redhat.com [209.132.183.4]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-568-hzk_Pxa9NjeZDMOCvPbmTg-1; Tue, 13 Jul 2021 17:16:10 -0400 X-MC-Unique: hzk_Pxa9NjeZDMOCvPbmTg-1 Received: from smtp.corp.redhat.com (int-mx04.intmail.prod.int.phx2.redhat.com [10.5.11.14]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id 4B4A6804140; Tue, 13 Jul 2021 21:16:05 +0000 (UTC) Received: from virtlab719.virt.lab.eng.bos.redhat.com (virtlab719.virt.lab.eng.bos.redhat.com [10.19.153.15]) by smtp.corp.redhat.com (Postfix) with ESMTP id 583645D9DD; Tue, 13 Jul 2021 21:15:58 +0000 (UTC) From: Nitesh Narayan Lal To: linux-kernel@vger.kernel.org, linux-scsi@vger.kernel.org, intel-wired-lan@lists.osuosl.org, netdev@vger.kernel.org, linux-api@vger.kernel.org, linux-pci@vger.kernel.org, tglx@linutronix.de, jesse.brandeburg@intel.com, robin.murphy@arm.com, mtosatti@redhat.com, mingo@kernel.org, jbrandeb@kernel.org, frederic@kernel.org, juri.lelli@redhat.com, abelits@marvell.com, bhelgaas@google.com, rostedt@goodmis.org, peterz@infradead.org, davem@davemloft.net, akpm@linux-foundation.org, sfr@canb.auug.org.au, stephen@networkplumber.org, rppt@linux.vnet.ibm.com, chris.friesen@windriver.com, maz@kernel.org, nhorman@tuxdriver.com, pjwaskiewicz@gmail.com, sassmann@redhat.com, thenzl@redhat.com, kashyap.desai@broadcom.com, sumit.saxena@broadcom.com, shivasharan.srikanteshwara@broadcom.com, sathya.prakash@broadcom.com, sreekanth.reddy@broadcom.com, suganath-prabu.subramani@broadcom.com, james.smart@broadcom.com, dick.kennedy@broadcom.com, jkc@redhat.com, faisal.latif@intel.com, shiraz.saleem@intel.com, tariqt@nvidia.com, ahleihel@redhat.com, kheib@redhat.com, borisp@nvidia.com, saeedm@nvidia.com, benve@cisco.com, govind@gmx.com, jassisinghbrar@gmail.com, ajit.khaparde@broadcom.com, sriharsha.basavapatna@broadcom.com, somnath.kotur@broadcom.com, nilal@redhat.com, tatyana.e.nikolova@intel.com, mustafa.ismail@intel.com, ahs3@redhat.com, leonro@nvidia.com, chandrakanth.patil@broadcom.com Subject: [PATCH v3 06/14] RDMA/irdma: Use irq_set_affinity_and_hint Date: Tue, 13 Jul 2021 17:14:54 -0400 Message-Id: <20210713211502.464259-7-nitesh@redhat.com> In-Reply-To: <20210713211502.464259-1-nitesh@redhat.com> References: <20210713211502.464259-1-nitesh@redhat.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Scanned-By: MIMEDefang 2.79 on 10.5.11.14 Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org The driver uses irq_set_affinity_hint() to update the affinity_hint mask that is consumed by the userspace to distribute the interrupts and to apply the provided mask as the affinity for its interrupts. However, irq_set_affinity_hint() applying the provided cpumask as an affinity for the interrupt is an undocumented side effect. To remove this side effect irq_set_affinity_hint() has been marked as deprecated and new interfaces have been introduced. Hence, replace the irq_set_affinity_hint() with the new interface irq_set_affinity_and_hint() where the provided mask needs to be applied as the affinity and affinity_hint pointer needs to be set and replace with irq_update_affinity_hint() where only affinity_hint needs to be updated. Signed-off-by: Nitesh Narayan Lal --- drivers/infiniband/hw/irdma/hw.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/infiniband/hw/irdma/hw.c b/drivers/infiniband/hw/irdma/hw.c index 7afb8a6a0526..7f13a051d4de 100644 --- a/drivers/infiniband/hw/irdma/hw.c +++ b/drivers/infiniband/hw/irdma/hw.c @@ -537,7 +537,7 @@ static void irdma_destroy_irq(struct irdma_pci_f *rf, struct irdma_sc_dev *dev = &rf->sc_dev; dev->irq_ops->irdma_dis_irq(dev, msix_vec->idx); - irq_set_affinity_hint(msix_vec->irq, NULL); + irq_update_affinity_hint(msix_vec->irq, NULL); free_irq(msix_vec->irq, dev_id); } @@ -1087,7 +1087,7 @@ irdma_cfg_ceq_vector(struct irdma_pci_f *rf, struct irdma_ceq *iwceq, } cpumask_clear(&msix_vec->mask); cpumask_set_cpu(msix_vec->cpu_affinity, &msix_vec->mask); - irq_set_affinity_hint(msix_vec->irq, &msix_vec->mask); + irq_set_affinity_and_hint(msix_vec->irq, &msix_vec->mask); if (status) { ibdev_dbg(&rf->iwdev->ibdev, "ERR: ceq irq config fail\n"); return IRDMA_ERR_CFG; -- 2.27.0