Re: [PATCH -mm2] net: Fix compiler-error on dgrs.c when !CONFIG_PCI

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

 



Herbert Xu wrote:

Richard Knutsson <[email protected]> wrote:
We need it even if pci_register_driver() and pci_register_driver() is empty shells. And instead of removing #endif CONFIG_PCI for

I don't think so.  Please see my previous patch where pci_register_driver
is not called at all if CONFIG_PCI is not defined.

Cheers,
Yes, I know you patch don't need it (thought you commented the patch vs. dgrs.c, not vs. you patch). But to do that, you have to introduce a new dgrs-specific pci-layer to compensate. If you don't want to have an empty struct, is it not nicer/easier to just #ifdef CONFIG_PCI the pci_*-functions? (instead of two inline functions for every used pci_*-function?)

Am thinking of removing the #ifdef CONFIG_PCI's in other files, to "clean up" the code, but that would introduce this problem again, don't you think it is more readable to make an empty struct when !CONFIG_PCI, then making new pci_*-functions specific to the driver?

cu

-
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