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-prev] [day] [month] [year] [list]
Date:	Fri, 30 Jul 2010 09:48:33 -0700
From:	Jesse Barnes <jbarnes@...tuousgeek.org>
To:	Kulikov Vasiliy <segooon@...il.com>
Cc:	Kernel Janitors <kernel-janitors@...r.kernel.org>,
	linux-pci@...r.kernel.org, linux-kernel@...r.kernel.org
Subject: Re: [PATCH 17/19] drivers/pci: use for_each_pci_dev()

On Sat,  3 Jul 2010 20:04:39 +0400
Kulikov Vasiliy <segooon@...il.com> wrote:

> Use for_each_pci_dev() to simplify the code.
> 
> Signed-off-by: Kulikov Vasiliy <segooon@...il.com>
> ---
>  drivers/pci/setup-irq.c |    3 +--
>  1 files changed, 1 insertions(+), 2 deletions(-)
> 
> diff --git a/drivers/pci/setup-irq.c b/drivers/pci/setup-irq.c
> index aa795fd..eec9738 100644
> --- a/drivers/pci/setup-irq.c
> +++ b/drivers/pci/setup-irq.c
> @@ -59,7 +59,6 @@ pci_fixup_irqs(u8 (*swizzle)(struct pci_dev *, u8 *),
>  	       int (*map_irq)(struct pci_dev *, u8, u8))
>  {
>  	struct pci_dev *dev = NULL;
> -	while ((dev = pci_get_device(PCI_ANY_ID, PCI_ANY_ID, dev)) != NULL) {
> +	for_each_pci_dev(dev)
>  		pdev_fixup_irq(dev, swizzle, map_irq);
> -	}
>  }

Applied all of these to my linux-next branch.  I squashed all the PCI
ones into a single commit, keeping only the x86 one separate.

-- 
Jesse Barnes, Intel Open Source Technology Center
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ