Commit 388b78adc9899f0299128610f566051d0b1a57f6
Committed by
Linus Torvalds
1 parent
f8f0626989
Exists in
master
and in
20 other branches
rapidio: modify configuration to support PCI-SRIO controller
1. Add an option to include RapidIO support if the PCI is available. 2. Add FSL_RIO configuration option to enable controller selection. 3. Add RapidIO support option into x86 and MIPS architectures. Signed-off-by: Alexandre Bounine <alexandre.bounine@idt.com> Acked-by: Kumar Gala <galak@kernel.crashing.org> Cc: Matt Porter <mporter@kernel.crashing.org> Cc: Li Yang <leoli@freescale.com> Cc: Thomas Moll <thomas.moll@sysgo.com> Cc: Micha Nelissen <micha@neli.hopto.org> Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Showing 7 changed files with 34 additions and 5 deletions Side-by-side Diff
arch/mips/Kconfig
... | ... | @@ -2344,6 +2344,16 @@ |
2344 | 2344 | |
2345 | 2345 | source "drivers/pci/hotplug/Kconfig" |
2346 | 2346 | |
2347 | +config RAPIDIO | |
2348 | + bool "RapidIO support" | |
2349 | + depends on PCI | |
2350 | + default n | |
2351 | + help | |
2352 | + If you say Y here, the kernel will include drivers and | |
2353 | + infrastructure code to support RapidIO interconnect devices. | |
2354 | + | |
2355 | +source "drivers/rapidio/Kconfig" | |
2356 | + | |
2347 | 2357 | endmenu |
2348 | 2358 | |
2349 | 2359 | menu "Executable file formats" |
arch/powerpc/Kconfig
... | ... | @@ -772,10 +772,18 @@ |
772 | 772 | |
773 | 773 | config RAPIDIO |
774 | 774 | bool "RapidIO support" |
775 | - depends on HAS_RAPIDIO | |
775 | + depends on HAS_RAPIDIO || PCI | |
776 | 776 | help |
777 | 777 | If you say Y here, the kernel will include drivers and |
778 | 778 | infrastructure code to support RapidIO interconnect devices. |
779 | + | |
780 | +config FSL_RIO | |
781 | + bool "Freescale Embedded SRIO Controller support" | |
782 | + depends on RAPIDIO && HAS_RAPIDIO | |
783 | + default "n" | |
784 | + ---help--- | |
785 | + Include support for RapidIO controller on Freescale embedded | |
786 | + processors (MPC8548, MPC8641, etc). | |
779 | 787 | |
780 | 788 | source "drivers/rapidio/Kconfig" |
781 | 789 |
arch/powerpc/kernel/cpu_setup_fsl_booke.S
arch/powerpc/sysdev/Makefile
... | ... | @@ -20,7 +20,7 @@ |
20 | 20 | obj-$(CONFIG_MPC8xxx_GPIO) += mpc8xxx_gpio.o |
21 | 21 | obj-$(CONFIG_FSL_85XX_CACHE_SRAM) += fsl_85xx_l2ctlr.o fsl_85xx_cache_sram.o |
22 | 22 | obj-$(CONFIG_SIMPLE_GPIO) += simple_gpio.o |
23 | -obj-$(CONFIG_RAPIDIO) += fsl_rio.o | |
23 | +obj-$(CONFIG_FSL_RIO) += fsl_rio.o | |
24 | 24 | obj-$(CONFIG_TSI108_BRIDGE) += tsi108_pci.o tsi108_dev.o |
25 | 25 | obj-$(CONFIG_QUICC_ENGINE) += qe_lib/ |
26 | 26 | obj-$(CONFIG_PPC_BESTCOMM) += bestcomm/ |
arch/x86/Kconfig
... | ... | @@ -2096,6 +2096,16 @@ |
2096 | 2096 | |
2097 | 2097 | source "drivers/pci/hotplug/Kconfig" |
2098 | 2098 | |
2099 | +config RAPIDIO | |
2100 | + bool "RapidIO support" | |
2101 | + depends on PCI | |
2102 | + default n | |
2103 | + help | |
2104 | + If you say Y here, the kernel will include drivers and | |
2105 | + infrastructure code to support RapidIO interconnect devices. | |
2106 | + | |
2107 | +source "drivers/rapidio/Kconfig" | |
2108 | + | |
2099 | 2109 | endmenu |
2100 | 2110 | |
2101 | 2111 |
drivers/net/rionet.c
... | ... | @@ -382,7 +382,7 @@ |
382 | 382 | struct rionet_peer *peer, *tmp; |
383 | 383 | |
384 | 384 | free_pages((unsigned long)rionet_active, rdev->net->hport->sys_size ? |
385 | - __ilog2(sizeof(void *)) + 4 : 0); | |
385 | + __fls(sizeof(void *)) + 4 : 0); | |
386 | 386 | unregister_netdev(ndev); |
387 | 387 | free_netdev(ndev); |
388 | 388 | |
... | ... | @@ -450,7 +450,7 @@ |
450 | 450 | } |
451 | 451 | |
452 | 452 | rionet_active = (struct rio_dev **)__get_free_pages(GFP_KERNEL, |
453 | - mport->sys_size ? __ilog2(sizeof(void *)) + 4 : 0); | |
453 | + mport->sys_size ? __fls(sizeof(void *)) + 4 : 0); | |
454 | 454 | if (!rionet_active) { |
455 | 455 | rc = -ENOMEM; |
456 | 456 | goto out; |