lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-ID: <e416c587-d3cc-947a-7336-2c1954e2e432@broadcom.com>
Date:   Wed, 20 Jul 2022 09:12:44 -0700
From:   Scott Branden <scott.branden@...adcom.com>
To:     Breno Leitao <leitao@...tao.org>,
        bcm-kernel-feedback-list@...adcom.com
Cc:     leit@...com, linux-kernel@...r.kernel.org,
        Breno Leitao <leitao@...ian.org>
Subject: Re: [PATCH] misc: bcm-vk: Specify the minimum number of IRQ vecs

Hi Breno,

On 2022-07-19 05:23, Breno Leitao wrote:
> From: Breno Leitao <leitao@...ian.org>
> 
> During bcm_vk_probe(), pci_alloc_irq_vectors() is called passing the
> number of IRQ vectors as 1, but, later, check how many IRQ vectors it
> got, and fails if it is smaller than VK_MSIX_IRQ_MIN_REQ.
> 
> The most appropriated way to do it is setting the 'min_vecs' param as
> VK_MSIX_IRQ_MIN_REQ, instead of one. pci_alloc_irq_vectors() should
> know the requirements when called.
Yes, the end result is no operational change before or after this commit.
> 
> The test was done by just loading this module on a machine with a
> Valkyrie offload engine
> 
> Signed-off-by: Breno Leitao <leitao@...ian.org>
Acked-by: Scott Branden <scott.branden@...adcom.com>
> ---
>   drivers/misc/bcm-vk/bcm_vk_dev.c | 2 +-
>   1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/drivers/misc/bcm-vk/bcm_vk_dev.c b/drivers/misc/bcm-vk/bcm_vk_dev.c
> index a16b99bdaa13..bedab17884b8 100644
> --- a/drivers/misc/bcm-vk/bcm_vk_dev.c
> +++ b/drivers/misc/bcm-vk/bcm_vk_dev.c
> @@ -1339,7 +1339,7 @@ static int bcm_vk_probe(struct pci_dev *pdev, const struct pci_device_id *ent)
>   	pci_set_drvdata(pdev, vk);
>   
>   	irq = pci_alloc_irq_vectors(pdev,
> -				    1,
> +				    VK_MSIX_IRQ_MIN_REQ,
>   				    VK_MSIX_IRQ_MAX,
>   				    PCI_IRQ_MSI | PCI_IRQ_MSIX);
>   

Download attachment "smime.p7s" of type "application/pkcs7-signature" (4212 bytes)

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ