Re: [PATCH 1/1] Char: correct pci_get_device changes

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

 



On Sun, Oct 15, 2006 at 01:36:45AM +0200, Jiri Slaby wrote:
> correct pci_get_device changes
> 
> Commits 881a8c120acf7ec09c90289e2996b7c70f51e996 and
> efe1ec27837d6639eae82e1f5876910ba6433c3f are totally wrong and
> "Replace pci_find_device() with more safer pci_get_device()." holds only for a
> very short time until next iteration of pci_get_device is called (and
> refcount is decreased again there).
> 
> Whenever pci_find_device -> pci_get_device change is performed, also
> pci_dev_get and pci_dev_put should be in most cases called. If not, it's
> not easy to find such issues and this is example of such case. Here it
> was made safer in no way but a moment during initialization, weird.
> 
> It affects moxa and rio char drivers. (All this stuff deserves to be
> converted to pci_probing, though.)
> 
> Cc: <[email protected]>
> Cc: Amit Gud <[email protected]>
> Cc: Greg Kroah-Hartman <[email protected]>
> Signed-off-by: Jiri Slaby <[email protected]>

Acked-by: Greg Kroah-Hartman <[email protected]>

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [email protected]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

[Index of Archives]     [Kernel Newbies]     [Netfilter]     [Bugtraq]     [Photo]     [Stuff]     [Gimp]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Video 4 Linux]     [Linux for the blind]     [Linux Resources]
  Powered by Linux