summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorWaldemar Brodkorb <wbx@openadk.org>2015-08-27 20:30:31 +0200
committerWaldemar Brodkorb <wbx@openadk.org>2015-08-27 20:30:31 +0200
commit0fb72a57c6c2981c3749e4d834faeccd2f50b4de (patch)
treedebbbbc45a4faea720ab1ead1e4a39f312c92d02
parent9c2a82065b6d5e54ddf30d77e8b6a73a49a44843 (diff)
allow to build ALSA, I2C, SPI as kernel modules
-rwxr-xr-xscripts/install.sh4
-rw-r--r--target/arm/Makefile13
-rw-r--r--target/arm/kernel/raspberry-pi22
-rw-r--r--target/arm/systems/raspberry-pi1
-rw-r--r--target/arm/systems/raspberry-pi21
-rw-r--r--target/config/Config.in.tools2
-rw-r--r--target/linux/config/Config.in.audio105
-rw-r--r--target/linux/config/Config.in.dma6
-rw-r--r--target/linux/config/Config.in.i2c11
-rw-r--r--target/linux/config/Config.in.regmap19
-rw-r--r--target/linux/config/Config.in.spi6
11 files changed, 88 insertions, 82 deletions
diff --git a/scripts/install.sh b/scripts/install.sh
index 30c4449a8..df39ba9f8 100755
--- a/scripts/install.sh
+++ b/scripts/install.sh
@@ -546,8 +546,8 @@ case $target {
break
done
mkdir "$B/"overlays
- for x in "$B/"*-overlay.dtb; do
- [[ -e "$x" ]] && mv "$B/"*-overlay.dtb "$B/"overlays
+ for x in "$fwdir"/overlays/*.dtb; do
+ [[ -e "$x" ]] && cp "$fwdir"/overlays/*.dtb "$B/"overlays
break
done
umount_fs "$B"
diff --git a/target/arm/Makefile b/target/arm/Makefile
index e654bdd6e..a86a4ac2e 100644
--- a/target/arm/Makefile
+++ b/target/arm/Makefile
@@ -135,17 +135,18 @@ ifeq ($(ADK_TARGET_QEMU_ARM_MODEL_VEXPRESS_A9),y)
env $(KERNEL_MAKE_ENV) $(MAKE) -C "${LINUX_DIR}" $(KERNEL_MAKE_OPTS) \
dtbs $(MAKE_TRACE)
endif
-ifeq ($(ADK_TARGET_SYSTEM_RASPBERRY_PI),y)
- env $(KERNEL_MAKE_ENV) $(MAKE) -C "${LINUX_DIR}" $(KERNEL_MAKE_OPTS) \
- dtbs $(MAKE_TRACE)
-endif
-ifeq ($(ADK_TARGET_SYSTEM_RASPBERRY_PI2),y)
+ifeq ($(ADK_TARGET_BOARD_BCM28XX),y)
env $(KERNEL_MAKE_ENV) $(MAKE) -C "${LINUX_DIR}" $(KERNEL_MAKE_OPTS) \
dtbs $(MAKE_TRACE)
+ mkdir -p $(FW_DIR)/overlays
+ for x in $(LINUX_DIR)/arch/arm/boot/dts/overlays/*.dtb; do \
+ [[ -e "$$x" ]] && cp $(LINUX_DIR)/arch/arm/boot/dts/overlays/*.dtb $(FW_DIR)/overlays; \
+ break; \
+ done
endif
ifeq ($(ADK_TARGET_SYSTEM_BANANA_PRO),y)
env $(KERNEL_MAKE_ENV) $(MAKE) -C "${LINUX_DIR}" $(KERNEL_MAKE_OPTS) \
- sun7i-a20-bananapro.dtb
+ sun7i-a20-bananapro.dtb $(MAKE_TRACE)
endif
ifeq ($(ADK_TARGET_SYSTEM_SOLIDRUN_IMX6),y)
env $(KERNEL_MAKE_ENV) $(MAKE) -C "${LINUX_DIR}" $(KERNEL_MAKE_OPTS) \
diff --git a/target/arm/kernel/raspberry-pi2 b/target/arm/kernel/raspberry-pi2
index a7c4510bc..7aa99d897 100644
--- a/target/arm/kernel/raspberry-pi2
+++ b/target/arm/kernel/raspberry-pi2
@@ -7,7 +7,9 @@ CONFIG_FIQ=y
CONFIG_ATAGS=y
CONFIG_KUSER_HELPERS=y
CONFIG_RASPBERRYPI_FIRMWARE=y
+CONFIG_BRCM_CHAR_DRIVERS=y
CONFIG_BCM2708_VCHIQ=y
+CONFIG_BCM2708_VCMEM=y
CONFIG_MAILBOX=y
CONFIG_BCM2835_MBOX=y
CONFIG_OF=y
diff --git a/target/arm/systems/raspberry-pi b/target/arm/systems/raspberry-pi
index 57b08616b..75267c12b 100644
--- a/target/arm/systems/raspberry-pi
+++ b/target/arm/systems/raspberry-pi
@@ -13,6 +13,7 @@ config ADK_TARGET_SYSTEM_RASPBERRY_PI
select ADK_TARGET_WITH_SPI
select ADK_TARGET_WITH_NET
select ADK_TARGET_WITH_BLOCK
+ select ADK_TARGET_WITH_SOUND
select ADK_PACKAGE_BCM28XX_BOOTLOADER
select ADK_TARGET_WITH_ROOT_RW
select ADK_TARGET_KERNEL_ZIMAGE
diff --git a/target/arm/systems/raspberry-pi2 b/target/arm/systems/raspberry-pi2
index 2e3a0ec8c..e0f438fd5 100644
--- a/target/arm/systems/raspberry-pi2
+++ b/target/arm/systems/raspberry-pi2
@@ -14,6 +14,7 @@ config ADK_TARGET_SYSTEM_RASPBERRY_PI2
select ADK_TARGET_WITH_SMP
select ADK_TARGET_WITH_NET
select ADK_TARGET_WITH_BLOCK
+ select ADK_TARGET_WITH_SOUND
select ADK_PACKAGE_BCM28XX_BOOTLOADER
select ADK_TARGET_WITH_ROOT_RW
select ADK_TARGET_KERNEL_ZIMAGE
diff --git a/target/config/Config.in.tools b/target/config/Config.in.tools
index 06c2b544c..858e57ea3 100644
--- a/target/config/Config.in.tools
+++ b/target/config/Config.in.tools
@@ -209,7 +209,7 @@ config ADK_HOST_BUILD_PCRE
config ADK_HOST_BUILD_KMOD
bool
- default y if ADK_RUNTIME_DEV_UDEV
+ default y
source "target/config/Config.in.prereq"
diff --git a/target/linux/config/Config.in.audio b/target/linux/config/Config.in.audio
index 54270c374..f47a490ea 100644
--- a/target/linux/config/Config.in.audio
+++ b/target/linux/config/Config.in.audio
@@ -1,6 +1,9 @@
menu "Audio devices support"
depends on ADK_TARGET_WITH_PCI || ADK_TARGET_WITH_USB || ADK_TARGET_WITH_SOUND || ADK_TARGET_QEMU
+config ADK_KERNEL_SOUND
+ tristate
+
config ADK_KERNEL_SND_PCI
bool
@@ -13,60 +16,56 @@ config ADK_KERNEL_SND_SOC
config ADK_KERNEL_SND_ARM
bool
+config ADK_KERNEL_SND_TIMER
+ tristate
+
+config ADK_KERNEL_SND_PCM
+ tristate
+
+config ADK_KERNEL_SND_HWDEP
+ tristate
+
+config ADK_KERNEL_SND_RAWMIDI
+ tristate
+
+config ADK_KERNEL_SND_AC97_CODEC
+ tristate
+
config ADK_KERNEL_SND_SOC_SPDIF
- bool
+ tristate
config ADK_KERNEL_SND_SOC_FSL_ASRC
- bool
+ tristate
config ADK_KERNEL_SND_SOC_FSL_SPDIF
- bool
+ tristate
config ADK_KERNEL_SND_SOC_IMX_SGTL5000
- bool
+ tristate
config ADK_KERNEL_SND_SOC_IMX_PCM_DMA
- bool
+ tristate
config ADK_KERNEL_SND_SOC_HDMI_CODEC
- bool
+ tristate
config ADK_KERNEL_SND_SOC_IMX_HDMI_DMA
- bool
+ tristate
config ADK_KERNEL_SND_SOC_IMX_SPDIF
- bool
+ tristate
config ADK_KERNEL_SND_SOC_IMX_HDMI
- bool
+ tristate
config ADK_KERNEL_SND_PXA2XX_AC97
- bool
+ tristate
config ADK_KERNEL_SND_PXA2XX_SOC
- bool
-
-config ADK_KERNEL_SND_TIMER
- bool
-
-config ADK_KERNEL_SND_PCM
- bool
- select ADK_KERNEL_SND_TIMER
-
-config ADK_KERNEL_SND_HWDEP
- bool
-
-config ADK_KERNEL_SOUND
- bool
-
-config ADK_KERNEL_SND_RAWMIDI
- bool
-
-config ADK_KERNEL_SND_AC97_CODEC
- bool
+ tristate
config ADK_KERNEL_SND_SOC_I2C_AND_SPI
- bool
+ tristate
config ADK_KERNEL_SND_SOC_WM8731
tristate
@@ -95,50 +94,50 @@ config ADK_KERNEL_SND_SOC_PCM512x_SPI
select ADK_KERNEL_SND_SOC_I2C_AND_SPI
config ADK_KERNEL_SND
- bool
+ tristate
select ADK_KERNEL_SOUND
select ADK_KERNEL_SND_PCM
select ADK_KERNEL_SND_HWDEP
config ADK_KERNEL_SND_INTEL8X0
- bool "Intel AC97 driver"
+ tristate "Intel AC97 driver"
select ADK_KERNEL_SND
select ADK_KERNEL_SND_PCI
select ADK_KERNEL_SND_AC97_CODEC
- default y if ADK_TARGET_SYSTEM_IBM_X40
- default y if ADK_TARGET_QEMU_WITH_AUDIO
+ default m if ADK_TARGET_SYSTEM_IBM_X40
+ default m if ADK_TARGET_QEMU_WITH_AUDIO
default n
depends on ADK_TARGET_WITH_PCI || ADK_TARGET_QEMU_SYSTEM_X86 || ADK_TARGET_QEMU_SYSTEM_X86_64
help
Driver for intel chipsets.
config ADK_KERNEL_SND_VIA82XX
- bool "VIA82XX driver"
+ tristate "VIA82XX driver"
select ADK_KERNEL_SND
depends on ADK_TARGET_WITH_PCI
help
ALSA VIA82XX driver
config ADK_KERNEL_SND_ENS1370
- bool "Ensoniq 1370 driver"
+ tristate "Ensoniq 1370 driver"
select ADK_KERNEL_SND
depends on ADK_TARGET_WITH_PCI
help
ALSA Ensonique 1370 driver
config ADK_KERNEL_SND_CS5535AUDIO
- bool "AMD CS5535 driver"
+ tristate "AMD CS5535 driver"
select ADK_KERNEL_SND_PCI
select ADK_KERNEL_SND_AC97_CODEC
select ADK_KERNEL_SND
- default y if ADK_TARGET_SYSTEM_LEMOTE_YEELONG
- default y if ADK_TARGET_SYSTEM_PCENGINES_ALIX1C
+ default m if ADK_TARGET_SYSTEM_LEMOTE_YEELONG
+ default m if ADK_TARGET_SYSTEM_PCENGINES_ALIX1C
depends on ADK_TARGET_WITH_PCI
help
ALSA AMD CS5535 driver
config ADK_KERNEL_SND_PXA2XX_SOC_SPITZ
- bool "Sharp Zaurus SoC"
+ tristate "Sharp Zaurus SoC"
select ADK_KERNEL_SND
select ADK_KERNEL_SND_ARM
select ADK_KERNEL_SND_PXA2XX_AC97
@@ -146,15 +145,15 @@ config ADK_KERNEL_SND_PXA2XX_SOC_SPITZ
select ADK_KERNEL_SND_SOC
select ADK_KERNEL_SND_PXA2XX_SOC
depends on ADK_TARGET_SYSTEM_SHARP_ZAURUS
- default y if ADK_TARGET_SYSTEM_SHARP_ZAURUS
+ default m if ADK_TARGET_SYSTEM_SHARP_ZAURUS
default n
config ADK_KERNEL_SND_BCM2835
- bool "BCM2835 onboard soundcard"
+ tristate "BCM2835 onboard soundcard"
select ADK_KERNEL_SND
select ADK_KERNEL_SND_ARM
depends on ADK_TARGET_BOARD_BCM28XX
- default y if ADK_TARGET_BOARD_BCM28XX
+ default m if ADK_TARGET_BOARD_BCM28XX
default n
config ADK_KERNEL_SND_BCM2708_SOC_I2S
@@ -164,6 +163,7 @@ config ADK_KERNEL_SND_BCM2708_SOC_I2S
select ADK_KERNEL_SND_SOC
select ADK_KERNEL_SND_BCM2835
select ADK_KERNEL_DMA_BCM2835
+ select ADK_KERNEL_REGMAP
select ADK_KERNEL_REGMAP_MMIO
depends on ADK_TARGET_BOARD_BCM28XX
default n
@@ -171,39 +171,39 @@ config ADK_KERNEL_SND_BCM2708_SOC_I2S
config ADK_KERNEL_SND_BCM2708_SOC_HIFIBERRY_AMP
tristate "Hifiberry AMP"
select ADK_KERNEL_SND_BCM2708_SOC_I2S
- depends on ADK_TARGET_BOARD_BCM28XX && ADK_KERNEL_VERSION_3_18
+ depends on ADK_TARGET_BOARD_BCM28XX
config ADK_KERNEL_SND_BCM2708_SOC_HIFIBERRY_DAC
tristate "Hifiberry DAC"
select ADK_KERNEL_SND_BCM2708_SOC_I2S
select ADK_KERNEL_SND_SOC_PCM5102A
- depends on ADK_TARGET_BOARD_BCM28XX && ADK_KERNEL_VERSION_3_18
+ depends on ADK_TARGET_BOARD_BCM28XX
config ADK_KERNEL_SND_BCM2708_SOC_HIFIBERRY_DIGI
tristate "Hifiberry DIGI"
select ADK_KERNEL_SND_BCM2708_SOC_I2S
select ADK_KERNEL_SND_SOC_WM8804
- depends on ADK_TARGET_BOARD_BCM28XX && ADK_KERNEL_VERSION_3_18
+ depends on ADK_TARGET_BOARD_BCM28XX
config ADK_KERNEL_SND_BCM2708_SOC_RPI_DAC
tristate "RPI-DAC"
select ADK_KERNEL_SND_BCM2708_SOC_I2S
- depends on ADK_TARGET_BOARD_BCM28XX && ADK_KERNEL_VERSION_3_18
+ depends on ADK_TARGET_BOARD_BCM28XX
config ADK_KERNEL_SND_BCM2708_SOC_IQAUDIO_DAC
tristate "IQAudio-DAC"
select ADK_KERNEL_SND_BCM2708_SOC_I2S
select ADK_KERNEL_SND_SOC_PCM512x_I2C
- depends on ADK_TARGET_BOARD_BCM28XX && ADK_KERNEL_VERSION_3_18
+ depends on ADK_TARGET_BOARD_BCM28XX
config ADK_KERNEL_SND_BCM2708_SOC_RPI_PROTO
tristate "Rpi-Proto"
select ADK_KERNEL_SND_BCM2708_SOC_I2S
select ADK_KERNEL_SND_SOC_WM8731
- depends on ADK_TARGET_BOARD_BCM28XX && ADK_KERNEL_VERSION_3_18
+ depends on ADK_TARGET_BOARD_BCM28XX
config ADK_KERNEL_SND_IMX_SOC
- bool "IMX6 SoC sound chip"
+ tristate "IMX6 SoC sound chip"
select ADK_KERNEL_SND
select ADK_KERNEL_SND_SOC
select ADK_KERNEL_SND_SOC_HDMI_CODEC
@@ -214,10 +214,11 @@ config ADK_KERNEL_SND_IMX_SOC
select ADK_KERNEL_SND_SOC_IMX_SGTL5000 if ADK_TARGET_HUMMINGBOARD_I2EX
select ADK_KERNEL_SND_SOC_FSL_ASRC
select ADK_KERNEL_SND_SOC_FSL_SPDIF
+ select ADK_KERNEL_REGMAP
select ADK_KERNEL_REGMAP_SPI
select ADK_KERNEL_REGMAP_I2C
depends on ADK_TARGET_SYSTEM_SOLIDRUN_IMX6
- default y if ADK_TARGET_SYSTEM_SOLIDRUN_IMX6
+ default m if ADK_TARGET_SYSTEM_SOLIDRUN_IMX6
default n
endmenu
diff --git a/target/linux/config/Config.in.dma b/target/linux/config/Config.in.dma
index 0e542e14e..c01523767 100644
--- a/target/linux/config/Config.in.dma
+++ b/target/linux/config/Config.in.dma
@@ -35,15 +35,19 @@ config ADK_KERNEL_BCM_VC_SM
config ADK_KERNEL_BCM_VC_CMA
bool
+config ADK_KERNEL_BCM_VCIO
+ bool
+
config ADK_KERNEL_DMA_BCM2708
bool
select ADK_KERNEL_DMADEVICES
select ADK_KERNEL_CMA
select ADK_KERNEL_CMA_SIZE_SEL_MBYTES
- select ADK_KERNEL_CMA_SIZE_128
+ select ADK_KERNEL_CMA_SIZE_8
select ADK_KERNEL_DMA_CMA
select ADK_KERNEL_BCM_VC_SM
select ADK_KERNEL_BCM_VC_CMA
+ select ADK_KERNEL_BCM_VCIO
depends on ADK_TARGET_BOARD_BCM28XX
default y if ADK_TARGET_BOARD_BCM28XX
default n
diff --git a/target/linux/config/Config.in.i2c b/target/linux/config/Config.in.i2c
index 02c6bfa45..38d63e118 100644
--- a/target/linux/config/Config.in.i2c
+++ b/target/linux/config/Config.in.i2c
@@ -10,10 +10,11 @@ config ADK_KERNEL_I2C_CHARDEV
config ADK_KERNEL_I2C_BCM2708
tristate "I2C driver for BCM2835 boards"
select ADK_KERNEL_I2C
+ select ADK_KERNEL_REGMAP
select ADK_KERNEL_REGMAP_I2C
select ADK_KERNEL_I2C_CHARDEV
depends on ADK_TARGET_BOARD_BCM28XX
- default y if ADK_TARGET_BOARD_BCM28XX
+ default m if ADK_TARGET_BOARD_BCM28XX
default n
help
I2C driver for BCM2835 boards.
@@ -21,10 +22,11 @@ config ADK_KERNEL_I2C_BCM2708
config ADK_KERNEL_I2C_SUNXI
tristate "I2C driver for SUNXI boards"
select ADK_KERNEL_I2C
+ select ADK_KERNEL_REGMAP
select ADK_KERNEL_REGMAP_I2C
select ADK_KERNEL_I2C_CHARDEV
depends on ADK_TARGET_SYSTEM_BANANA_PRO
- default y if ADK_TARGET_SYSTEM_BANANA_PRO
+ default m if ADK_TARGET_SYSTEM_BANANA_PRO
default n
help
I2C driver for SUNXI boards.
@@ -32,10 +34,11 @@ config ADK_KERNEL_I2C_SUNXI
config ADK_KERNEL_I2C_IMX
tristate "I2C driver for IMX6 boards"
select ADK_KERNEL_I2C
+ select ADK_KERNEL_REGMAP
select ADK_KERNEL_REGMAP_I2C
select ADK_KERNEL_I2C_CHARDEV
depends on ADK_TARGET_SYSTEM_SOLIDRUN_IMX6
- default y if ADK_TARGET_SYSTEM_SOLIDRUN_IMX6
+ default m if ADK_TARGET_SYSTEM_SOLIDRUN_IMX6
default n
help
I2C driver for IMX6 boards.
@@ -45,7 +48,7 @@ config ADK_KERNEL_SCX200_ACB
depends on ADK_CPU_GEODE
select ADK_KERNEL_I2C
select ADK_KERNEL_I2C_CHARDEV
- default y if ADK_CPU_GEODE
+ default m if ADK_CPU_GEODE
default n
help
I2C driver for Geode boards.
diff --git a/target/linux/config/Config.in.regmap b/target/linux/config/Config.in.regmap
index 44a8bcca0..47823cf6b 100644
--- a/target/linux/config/Config.in.regmap
+++ b/target/linux/config/Config.in.regmap
@@ -1,25 +1,16 @@
config ADK_KERNEL_REGMAP
- boolean
+ bool
select ADK_KERNEL_LZO_COMPRESS
select ADK_KERNEL_LZO_DECOMPRESS
- default n
config ADK_KERNEL_REGMAP_I2C
- boolean
- select ADK_KERNEL_REGMAP
- default n
+ tristate
config ADK_KERNEL_REGMAP_SPI
- boolean
- select ADK_KERNEL_REGMAP
- default n
+ tristate
config ADK_KERNEL_REGMAP_MMIO
- boolean
- select ADK_KERNEL_REGMAP
- default n
+ tristate
config ADK_KERNEL_REGMAP_IRQ
- boolean
- select ADK_KERNEL_REGMAP
- default n
+ bool
diff --git a/target/linux/config/Config.in.spi b/target/linux/config/Config.in.spi
index c90c402ff..4d5450f9a 100644
--- a/target/linux/config/Config.in.spi
+++ b/target/linux/config/Config.in.spi
@@ -37,10 +37,11 @@ config ADK_KERNEL_SPI_BCM2708
select ADK_KERNEL_SPI
select ADK_KERNEL_SPI_MASTER
select ADK_KERNEL_SPI_BITBANG
+ select ADK_KERNEL_REGMAP
select ADK_KERNEL_REGMAP_SPI
select ADK_KERNEL_BCM2708_SPIDEV
depends on ADK_TARGET_BOARD_BCM28XX
- default y if ADK_TARGET_BOARD_BCM28XX
+ default m if ADK_TARGET_BOARD_BCM28XX
default n
config ADK_KERNEL_SPI_IMX
@@ -48,9 +49,10 @@ config ADK_KERNEL_SPI_IMX
select ADK_KERNEL_SPI
select ADK_KERNEL_SPI_MASTER
select ADK_KERNEL_SPI_BITBANG
+ select ADK_KERNEL_REGMAP
select ADK_KERNEL_REGMAP_SPI
depends on ADK_TARGET_SYSTEM_SOLIDRUN_IMX6
- default y if ADK_TARGET_SYSTEM_SOLIDRUN_IMX6
+ default m if ADK_TARGET_SYSTEM_SOLIDRUN_IMX6
default n
config ADK_KERNEL_SPI_SPIDEV