Re: [PATCH 1/14 v2] drivers/isdn/hisax/telespci.c: fix warning

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Sun, 27 Jul 2008, Michael Borisov wrote:

> Probably now it is correct ? 

Please explain why.

julia

> This patch fixes the following compile warning:
> 
> drivers/isdn/hisax/telespci.c: In function ÿÿsetup_telespciÿÿ:
> drivers/isdn/hisax/telespci.c:303: warning: ÿÿpci_find_deviceÿÿ is
> deprecated (declared at include/linux/pci.h:535)
> 
> Signed-off-by: Michael Borisov <niro@xxxxxx>
> ---
> diff --git a/drivers/isdn/hisax/telespci.c
> b/drivers/isdn/hisax/telespci.c
> index 28b08de..1142f35 100644
> --- a/drivers/isdn/hisax/telespci.c
> +++ b/drivers/isdn/hisax/telespci.c
> @@ -300,7 +300,9 @@ setup_telespci(struct IsdnCard *card)
>  	if (cs->typ != ISDN_CTYPE_TELESPCI)
>  		return (0);
>  
> -	if ((dev_tel = pci_find_device (PCI_VENDOR_ID_ZORAN,
> PCI_DEVICE_ID_ZORAN_36120, dev_tel))) {
> +	dev_tel = pci_get_device (PCI_VENDOR_ID_ZORAN,
> PCI_DEVICE_ID_ZORAN_36120, NULL);
> +	if (dev_tel) {
> +		pci_dev_put(dev_tel);
>  		if (pci_enable_device(dev_tel))
>  			return(0);
>  		cs->irq = dev_tel->irq;
> 
> --
> To unsubscribe from this list: send the line "unsubscribe kernel-janitors" in
> the body of a message to majordomo@xxxxxxxxxxxxxxx
> More majordomo info at  http://vger.kernel.org/majordomo-info.html
> 

[Index of Archives]     [Kernel Development]     [Kernel Announce]     [Kernel Newbies]     [Linux Networking Development]     [Share Photos]     [IDE]     [Security]     [Git]     [Netfilter]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Device Mapper]

  Powered by Linux