}
-@@ -887,7 +913,9 @@ static int tulip_ethtool_set_wol(struct
+@@ -887,7 +913,9 @@ static int tulip_ethtool_set_wol(struct
return -EOPNOTSUPP;
tp->wolinfo.wolopts = wolinfo->wolopts;
.name = DRV_NAME,
.id_table = tulip_pci_tbl,
.probe = tulip_init_one,
-@@ -1974,10 +2014,12 @@ static struct pci_driver tulip_driver =
+@@ -1974,10 +2014,12 @@ static struct pci_driver tulip_driver =
.resume = tulip_resume,
#endif /* CONFIG_PM */
};
}
-@@ -916,6 +951,9 @@ static int tulip_ethtool_set_wol(struct
+@@ -916,6 +951,9 @@ static int tulip_ethtool_set_wol(struct
#ifdef CONFIG_TULIP_PCI
device_set_wakeup_enable(tp->kdev, tp->wolinfo.wolopts);
#endif
}
static void
-@@ -573,8 +572,8 @@ pl010_console_write(struct console *co,
+@@ -573,8 +572,8 @@ pl010_console_write(struct console *co,
/*
* First save the CR then disable the interrupts
*/
uart_console_write(&uap->port, s, count, pl010_console_putchar);
-@@ -583,10 +582,10 @@ pl010_console_write(struct console *co,
+@@ -583,10 +582,10 @@ pl010_console_write(struct console *co,
* and restore the TCR
*/
do {
arch/mips/ar7/platform.c | 1 +
1 file changed, 1 insertion(+)
-diff --git a/arch/mips/ar7/platform.c b/arch/mips/ar7/platform.c
-index 7e2356f..e4f47d3 100644
--- a/arch/mips/ar7/platform.c
+++ b/arch/mips/ar7/platform.c
-@@ -581,6 +581,7 @@ static int __init ar7_register_uarts(void)
+@@ -581,6 +581,7 @@ static int __init ar7_register_uarts(voi
uart_port.type = PORT_AR7;
uart_port.uartclk = clk_get_rate(bus_clk) / 2;
uart_port.iotype = UPIO_MEM32;
uart_port.regshift = 2;
uart_port.line = 0;
---
-1.8.5.3.2.g3dbf181
-
--- a/drivers/char/Kconfig
+++ b/drivers/char/Kconfig
-@@ -464,6 +464,15 @@ config MWAVE
+@@ -452,6 +452,15 @@ config MWAVE
To compile this driver as a module, choose M here: the
module will be called mwave.
depends on SCx200
--- a/drivers/char/Makefile
+++ b/drivers/char/Makefile
-@@ -43,6 +43,7 @@ obj-$(CONFIG_HW_RANDOM) += hw_random/
+@@ -42,6 +42,7 @@ obj-$(CONFIG_HW_RANDOM) += hw_random/
obj-$(CONFIG_PPDEV) += ppdev.o
obj-$(CONFIG_NWBUTTON) += nwbutton.o
obj-$(CONFIG_NWFLASH) += nwflash.o
return 0;
}
-@@ -501,24 +547,16 @@ static int __vlynq_enable_device(struct
+@@ -501,24 +547,16 @@ static int __vlynq_enable_device(struct
return result;
switch (dev->divisor) {
break;
case vlynq_ldiv1:
case vlynq_ldiv2:
-@@ -528,15 +566,12 @@ static int __vlynq_enable_device(struct
+@@ -528,15 +566,12 @@ static int __vlynq_enable_device(struct
case vlynq_ldiv6:
case vlynq_ldiv7:
case vlynq_ldiv8:
return 0;
}
break;
-@@ -548,20 +583,17 @@ static int __vlynq_enable_device(struct
+@@ -548,20 +583,17 @@ static int __vlynq_enable_device(struct
case vlynq_rdiv6:
case vlynq_rdiv7:
case vlynq_rdiv8:
#define AR7_IRQ_UART0 15
--- a/arch/mips/Kconfig
+++ b/arch/mips/Kconfig
-@@ -86,7 +86,7 @@ config AR7
+@@ -89,7 +89,7 @@ config AR7
select HAVE_CLK
help
Support for the Texas Instruments AR7 System-on-a-Chip
config ATH79
bool "Atheros AR71XX/AR724X/AR913X based boards"
-@@ -839,6 +839,7 @@ config NLM_XLP_BOARD
+@@ -796,6 +796,7 @@ config NLM_XLP_BOARD
endchoice
source "arch/mips/alchemy/Kconfig"
--- a/drivers/mtd/Kconfig
+++ b/drivers/mtd/Kconfig
-@@ -192,6 +192,11 @@ config MTD_OF_PARTS
+@@ -169,6 +169,11 @@ config MTD_OF_PARTS
the partition map from the children of the flash node,
as described in Documentation/devicetree/booting-without-of.txt.
};
/* Uart divisor latch read */
-@@ -2843,7 +2850,11 @@ static void serial8250_console_putchar(s
+@@ -2861,7 +2868,11 @@ static void serial8250_console_putchar(s
struct uart_8250_port *up =
container_of(port, struct uart_8250_port, port);
size_t len;
unsigned int pre_size = master->erasesize, post_size = 0;
unsigned int root_offset = ROOT_OFFSET;
-@@ -55,6 +62,16 @@ static int create_mtd_partitions(struct
+@@ -55,6 +62,16 @@ static int create_mtd_partitions(struct
int retries = 10;
struct mtd_partition *ar7_parts;
ar7_parts = kzalloc(sizeof(*ar7_parts) * AR7_PARTS, GFP_KERNEL);
if (!ar7_parts)
return -ENOMEM;
-@@ -83,34 +100,39 @@ static int create_mtd_partitions(struct
+@@ -83,34 +100,39 @@ static int create_mtd_partitions(struct
pre_size = offset;
--- a/drivers/net/ethernet/ti/cpmac.c
+++ b/drivers/net/ethernet/ti/cpmac.c
-@@ -1155,6 +1155,8 @@ static int cpmac_probe(struct platform_d
+@@ -1154,6 +1154,8 @@ static int cpmac_probe(struct platform_d
goto fail;
}
dev->irq = platform_get_irq_byname(pdev, "irq");
dev->netdev_ops = &cpmac_netdev_ops;
-@@ -1233,7 +1235,7 @@ int cpmac_init(void)
+@@ -1232,7 +1234,7 @@ int cpmac_init(void)
cpmac_mii->reset = cpmac_mdio_reset;
cpmac_mii->irq = mii_irqs;
if (!cpmac_mii->priv) {
printk(KERN_ERR "Can't ioremap mdio registers\n");
-@@ -1244,10 +1246,16 @@ int cpmac_init(void)
+@@ -1243,10 +1245,16 @@ int cpmac_init(void)
#warning FIXME: unhardcode gpio&reset bits
ar7_gpio_disable(26);
ar7_gpio_disable(27);
cpmac_mii->reset(cpmac_mii);
for (i = 0; i < 300; i++) {
-@@ -1264,7 +1272,11 @@ int cpmac_init(void)
+@@ -1263,7 +1271,11 @@ int cpmac_init(void)
mask = 0;
}
+ ubnt_loco_m_xw_setup);
--- a/arch/mips/ath79/machtypes.h
+++ b/arch/mips/ath79/machtypes.h
-@@ -121,9 +121,11 @@ enum ath79_mach_type {
+@@ -122,9 +122,11 @@ enum ath79_mach_type {
ATH79_MACH_TL_WR941ND, /* TP-LINK TL-WR941ND */
ATH79_MACH_UBNT_AIRROUTER, /* Ubiquiti AirRouter */
ATH79_MACH_UBNT_BULLET_M, /* Ubiquiti Bullet M */
select SOC_AR724X
--- a/arch/mips/ath79/Makefile
+++ b/arch/mips/ath79/Makefile
-@@ -114,6 +114,7 @@ obj-$(CONFIG_ATH79_MACH_WNDR3700) += mac
+@@ -115,6 +115,7 @@ obj-$(CONFIG_ATH79_MACH_WNDR3700) += mac
obj-$(CONFIG_ATH79_MACH_WNDR4300) += mach-wndr4300.o
obj-$(CONFIG_ATH79_MACH_WNR2000) += mach-wnr2000.o
obj-$(CONFIG_ATH79_MACH_WNR2000_V3) += mach-wnr2000-v3.o
obj-$(CONFIG_ATH79_MACH_WPE72) += mach-wpe72.o
--- a/arch/mips/ath79/machtypes.h
+++ b/arch/mips/ath79/machtypes.h
-@@ -144,6 +144,7 @@ enum ath79_mach_type {
+@@ -145,6 +145,7 @@ enum ath79_mach_type {
ATH79_MACH_WNDR4300, /* NETGEAR WNDR4300 */
ATH79_MACH_WNR2000, /* NETGEAR WNR2000 */
ATH79_MACH_WNR2000_V3, /* NETGEAR WNR2000 v3 */
--- a/arch/mips/ath79/machtypes.h
+++ b/arch/mips/ath79/machtypes.h
-@@ -101,6 +101,7 @@ enum ath79_mach_type {
+@@ -102,6 +102,7 @@ enum ath79_mach_type {
ATH79_MACH_TL_WA750RE, /* TP-LINK TL-WA750RE */
ATH79_MACH_TL_WA7510N_V1, /* TP-LINK TL-WA7510N v1*/
ATH79_MACH_TL_WA850RE, /* TP-LINK TL-WA850RE */
--- a/arch/mips/ath79/machtypes.h
+++ b/arch/mips/ath79/machtypes.h
-@@ -104,6 +104,7 @@ enum ath79_mach_type {
+@@ -105,6 +105,7 @@ enum ath79_mach_type {
ATH79_MACH_TL_WA801ND_V2, /* TP-LINK TL-WA801ND v2 */
ATH79_MACH_TL_WA901ND, /* TP-LINK TL-WA901ND */
ATH79_MACH_TL_WA901ND_V2, /* TP-LINK TL-WA901ND v2 */
--- a/arch/mips/ath79/machtypes.h
+++ b/arch/mips/ath79/machtypes.h
-@@ -57,6 +57,7 @@ enum ath79_mach_type {
+@@ -58,6 +58,7 @@ enum ath79_mach_type {
ATH79_MACH_MR600V2, /* OpenMesh MR600v2 */
ATH79_MACH_MR600, /* OpenMesh MR600 */
ATH79_MACH_MYNET_N600, /* WD My Net N600 */
ATH79_MACH_MZK_W300NH, /* Planex MZK-W300NH */
--- a/arch/mips/ath79/Kconfig
+++ b/arch/mips/ath79/Kconfig
-@@ -830,6 +830,16 @@ config ATH79_MACH_MYNET_N600
+@@ -839,6 +839,16 @@ config ATH79_MACH_MYNET_N600
select ATH79_DEV_WMAC
select ATH79_NVRAM
select SOC_AR934X
--- a/arch/mips/ath79/Makefile
+++ b/arch/mips/ath79/Makefile
-@@ -67,6 +67,7 @@ obj-$(CONFIG_ATH79_MACH_JWAP003) += mach
+@@ -68,6 +68,7 @@ obj-$(CONFIG_ATH79_MACH_JWAP003) += mach
obj-$(CONFIG_ATH79_MACH_HORNET_UB) += mach-hornet-ub.o
obj-$(CONFIG_ATH79_MACH_MR600) += mach-mr600.o
obj-$(CONFIG_ATH79_MACH_MYNET_N600) += mach-mynet-n600.o
--- a/arch/mips/ath79/machtypes.h
+++ b/arch/mips/ath79/machtypes.h
-@@ -76,6 +76,7 @@ enum ath79_mach_type {
+@@ -77,6 +77,7 @@ enum ath79_mach_type {
ATH79_MACH_RB_450, /* MikroTik RouterBOARD 450 */
ATH79_MACH_RB_493, /* Mikrotik RouterBOARD 493/493AH */
ATH79_MACH_RB_493G, /* Mikrotik RouterBOARD 493G */
select SOC_AR934X
--- a/arch/mips/ath79/Makefile
+++ b/arch/mips/ath79/Makefile
-@@ -78,6 +78,7 @@ obj-$(CONFIG_ATH79_MACH_PB44) += mach-p
+@@ -79,6 +79,7 @@ obj-$(CONFIG_ATH79_MACH_PB44) += mach-p
obj-$(CONFIG_ATH79_MACH_PB92) += mach-pb92.o
obj-$(CONFIG_ATH79_MACH_RB4XX) += mach-rb4xx.o
obj-$(CONFIG_ATH79_MACH_RB750) += mach-rb750.o
--- a/arch/mips/ath79/machtypes.h
+++ b/arch/mips/ath79/machtypes.h
-@@ -109,6 +109,7 @@ enum ath79_mach_type {
+@@ -110,6 +110,7 @@ enum ath79_mach_type {
ATH79_MACH_TL_WA901ND_V3, /* TP-LINK TL-WA901ND v3 */
ATH79_MACH_TL_WDR3500, /* TP-LINK TL-WDR3500 */
ATH79_MACH_TL_WDR4300, /* TP-LINK TL-WDR4300 */
--- a/arch/mips/ath79/machtypes.h
+++ b/arch/mips/ath79/machtypes.h
-@@ -82,6 +82,7 @@ enum ath79_mach_type {
+@@ -83,6 +83,7 @@ enum ath79_mach_type {
ATH79_MACH_RB_751, /* MikroTik RouterBOARD 751 */
ATH79_MACH_RB_751G, /* Mikrotik RouterBOARD 751G */
ATH79_MACH_RB_951G, /* Mikrotik RouterBOARD 951G */
--- a/arch/mips/ath79/machtypes.h
+++ b/arch/mips/ath79/machtypes.h
-@@ -50,6 +50,7 @@ enum ath79_mach_type {
+@@ -51,6 +51,7 @@ enum ath79_mach_type {
ATH79_MACH_EW_DORIN, /* embedded wireless Dorin Platform */
ATH79_MACH_EW_DORIN_ROUTER, /* embedded wireless Dorin Router Platform */
ATH79_MACH_EAP7660D, /* Senao EAP7660D */
select SOC_AR71XX
--- a/arch/mips/ath79/Makefile
+++ b/arch/mips/ath79/Makefile
-@@ -62,6 +62,7 @@ obj-$(CONFIG_ATH79_MACH_DIR_825_C1) += m
+@@ -63,6 +63,7 @@ obj-$(CONFIG_ATH79_MACH_DIR_825_C1) += m
obj-$(CONFIG_ATH79_MACH_DRAGINO2) += mach-dragino2.o
obj-$(CONFIG_ATH79_MACH_EW_DORIN) += mach-ew-dorin.o
obj-$(CONFIG_ATH79_MACH_EAP7660D) += mach-eap7660d.o
--- a/arch/mips/ath79/Kconfig
+++ b/arch/mips/ath79/Kconfig
-@@ -939,6 +939,10 @@ config SOC_AR934X
+@@ -948,6 +948,10 @@ config SOC_AR934X
select PCI_AR724X if PCI
def_bool n
config SOC_QCA955X
select USB_ARCH_HAS_EHCI
select HW_HAS_PCI
-@@ -982,7 +986,7 @@ config ATH79_DEV_USB
+@@ -991,7 +995,7 @@ config ATH79_DEV_USB
def_bool n
config ATH79_DEV_WMAC
--- a/arch/mips/ath79/Kconfig
+++ b/arch/mips/ath79/Kconfig
-@@ -726,6 +726,15 @@ config ATH79_MACH_TL_WR841N_V8
+@@ -735,6 +735,15 @@ config ATH79_MACH_TL_WR841N_V8
select ATH79_DEV_USB
select ATH79_DEV_WMAC
select SOC_AR913X
--- a/arch/mips/ath79/Makefile
+++ b/arch/mips/ath79/Makefile
-@@ -100,6 +100,7 @@ obj-$(CONFIG_ATH79_MACH_TL_WR741ND) += m
+@@ -101,6 +101,7 @@ obj-$(CONFIG_ATH79_MACH_TL_WR741ND) += m
obj-$(CONFIG_ATH79_MACH_TL_WR741ND_V4) += mach-tl-wr741nd-v4.o
obj-$(CONFIG_ATH79_MACH_TL_WR841N_V1) += mach-tl-wr841n.o
obj-$(CONFIG_ATH79_MACH_TL_WR841N_V8) += mach-tl-wr841n-v8.o
obj-$(CONFIG_ATH79_MACH_TL_WR1043ND) += mach-tl-wr1043nd.o
--- a/arch/mips/ath79/machtypes.h
+++ b/arch/mips/ath79/machtypes.h
-@@ -124,6 +124,7 @@ enum ath79_mach_type {
+@@ -125,6 +125,7 @@ enum ath79_mach_type {
ATH79_MACH_TL_WR841N_V1, /* TP-LINK TL-WR841N v1 */
ATH79_MACH_TL_WR841N_V7, /* TP-LINK TL-WR841N/ND v7 */
ATH79_MACH_TL_WR841N_V8, /* TP-LINK TL-WR841N/ND v8 */
--- a/arch/mips/ath79/Makefile
+++ b/arch/mips/ath79/Makefile
-@@ -63,6 +63,7 @@ obj-$(CONFIG_ATH79_MACH_DRAGINO2) += mac
+@@ -64,6 +64,7 @@ obj-$(CONFIG_ATH79_MACH_DRAGINO2) += mac
obj-$(CONFIG_ATH79_MACH_EW_DORIN) += mach-ew-dorin.o
obj-$(CONFIG_ATH79_MACH_EAP7660D) += mach-eap7660d.o
obj-$(CONFIG_ATH79_MACH_GS_OOLITE) += mach-gs-oolite.o
obj-$(CONFIG_ATH79_MACH_HORNET_UB) += mach-hornet-ub.o
--- a/arch/mips/ath79/machtypes.h
+++ b/arch/mips/ath79/machtypes.h
-@@ -51,6 +51,7 @@ enum ath79_mach_type {
+@@ -52,6 +52,7 @@ enum ath79_mach_type {
ATH79_MACH_EW_DORIN_ROUTER, /* embedded wireless Dorin Router Platform */
ATH79_MACH_EAP7660D, /* Senao EAP7660D */
ATH79_MACH_GS_OOLITE, /* GS OOLITE V1.0 */
--- a/arch/mips/ath79/Makefile
+++ b/arch/mips/ath79/Makefile
-@@ -131,3 +131,4 @@ obj-$(CONFIG_ATH79_MACH_WZR_HP_AG300H) +
+@@ -132,3 +132,4 @@ obj-$(CONFIG_ATH79_MACH_WZR_HP_AG300H) +
obj-$(CONFIG_ATH79_MACH_WZR_HP_G450H) += mach-wzr-hp-g450h.o
obj-$(CONFIG_ATH79_MACH_ZCN_1523H) += mach-zcn-1523h.o
obj-$(CONFIG_ATH79_MACH_CARAMBOLA2) += mach-carambola2.o
+obj-$(CONFIG_ATH79_MACH_NBG6716) += mach-nbg6716.o
--- a/arch/mips/ath79/machtypes.h
+++ b/arch/mips/ath79/machtypes.h
-@@ -64,6 +64,7 @@ enum ath79_mach_type {
+@@ -65,6 +65,7 @@ enum ath79_mach_type {
ATH79_MACH_MZK_W04NU, /* Planex MZK-W04NU */
ATH79_MACH_MZK_W300NH, /* Planex MZK-W300NH */
ATH79_MACH_NBG460N, /* Zyxel NBG460N/550N/550NH */
ATH79_MACH_OM2P, /* OpenMesh OM2P */
--- a/arch/mips/ath79/Kconfig
+++ b/arch/mips/ath79/Kconfig
-@@ -909,6 +909,17 @@ config ATH79_MACH_NBG460N
+@@ -918,6 +918,17 @@ config ATH79_MACH_NBG460N
select ATH79_DEV_M25P80
select ATH79_DEV_WMAC
--- a/arch/mips/ath79/machtypes.h
+++ b/arch/mips/ath79/machtypes.h
-@@ -67,6 +67,7 @@ enum ath79_mach_type {
+@@ -68,6 +68,7 @@ enum ath79_mach_type {
ATH79_MACH_NBG6716, /* Zyxel NBG6716 */
ATH79_MACH_OM2P_HS, /* OpenMesh OM2P-HS */
ATH79_MACH_OM2P_LC, /* OpenMesh OM2P-LC */
--- a/arch/mips/ath79/machtypes.h
+++ b/arch/mips/ath79/machtypes.h
-@@ -65,6 +65,7 @@ enum ath79_mach_type {
+@@ -66,6 +66,7 @@ enum ath79_mach_type {
ATH79_MACH_MZK_W300NH, /* Planex MZK-W300NH */
ATH79_MACH_NBG460N, /* Zyxel NBG460N/550N/550NH */
ATH79_MACH_NBG6716, /* Zyxel NBG6716 */
--- a/arch/mips/ath79/machtypes.h
+++ b/arch/mips/ath79/machtypes.h
-@@ -50,6 +50,8 @@ enum ath79_mach_type {
+@@ -51,6 +51,8 @@ enum ath79_mach_type {
ATH79_MACH_EW_DORIN, /* embedded wireless Dorin Platform */
ATH79_MACH_EW_DORIN_ROUTER, /* embedded wireless Dorin Router Platform */
ATH79_MACH_EAP7660D, /* Senao EAP7660D */
select SOC_AR933X
--- a/arch/mips/ath79/Makefile
+++ b/arch/mips/ath79/Makefile
-@@ -62,6 +62,8 @@ obj-$(CONFIG_ATH79_MACH_DIR_825_C1) += m
+@@ -63,6 +63,8 @@ obj-$(CONFIG_ATH79_MACH_DIR_825_C1) += m
obj-$(CONFIG_ATH79_MACH_DRAGINO2) += mach-dragino2.o
obj-$(CONFIG_ATH79_MACH_EW_DORIN) += mach-ew-dorin.o
obj-$(CONFIG_ATH79_MACH_EAP7660D) += mach-eap7660d.o
select SOC_AR71XX
--- a/arch/mips/ath79/machtypes.h
+++ b/arch/mips/ath79/machtypes.h
-@@ -93,6 +93,8 @@ enum ath79_mach_type {
+@@ -94,6 +94,8 @@ enum ath79_mach_type {
ATH79_MACH_RB_2011G, /* Mikrotik RouterBOARD 2011UAS-2HnD */
ATH79_MACH_RB_2011L, /* Mikrotik RouterBOARD 2011L */
ATH79_MACH_RB_2011US, /* Mikrotik RouterBOARD 2011UAS */
ATH79_MACH_TEW_673GRU, /* TRENDnet TEW-673GRU */
--- a/arch/mips/ath79/Makefile
+++ b/arch/mips/ath79/Makefile
-@@ -85,6 +85,7 @@ obj-$(CONFIG_ATH79_MACH_RB750) += mach-
+@@ -86,6 +86,7 @@ obj-$(CONFIG_ATH79_MACH_RB750) += mach-
obj-$(CONFIG_ATH79_MACH_RB91X) += mach-rb91x.o
obj-$(CONFIG_ATH79_MACH_RB95X) += mach-rb95x.o
obj-$(CONFIG_ATH79_MACH_RB2011) += mach-rb2011.o
--- a/arch/mips/ath79/Kconfig
+++ b/arch/mips/ath79/Kconfig
-@@ -666,6 +666,16 @@ config ATH79_MACH_TL_WAX50RE
+@@ -675,6 +675,16 @@ config ATH79_MACH_TL_WAX50RE
select ATH79_DEV_M25P80
select ATH79_DEV_WMAC
select SOC_AR724X
--- a/arch/mips/ath79/Makefile
+++ b/arch/mips/ath79/Makefile
-@@ -96,6 +96,7 @@ obj-$(CONFIG_ATH79_MACH_TL_MR13U) += mac
+@@ -97,6 +97,7 @@ obj-$(CONFIG_ATH79_MACH_TL_MR13U) += mac
obj-$(CONFIG_ATH79_MACH_TL_MR3020) += mach-tl-mr3020.o
obj-$(CONFIG_ATH79_MACH_TL_MR3X20) += mach-tl-mr3x20.o
obj-$(CONFIG_ATH79_MACH_TL_WAX50RE) += mach-tl-wax50re.o
obj-$(CONFIG_ATH79_MACH_TL_WDR3500) += mach-tl-wdr3500.o
--- a/arch/mips/ath79/machtypes.h
+++ b/arch/mips/ath79/machtypes.h
-@@ -114,6 +114,7 @@ enum ath79_mach_type {
+@@ -115,6 +115,7 @@ enum ath79_mach_type {
ATH79_MACH_TL_WA7510N_V1, /* TP-LINK TL-WA7510N v1*/
ATH79_MACH_TL_WA850RE, /* TP-LINK TL-WA850RE */
ATH79_MACH_TL_WA801ND_V2, /* TP-LINK TL-WA801ND v2 */
--- a/arch/mips/ath79/machtypes.h
+++ b/arch/mips/ath79/machtypes.h
-@@ -113,6 +113,7 @@ enum ath79_mach_type {
+@@ -114,6 +114,7 @@ enum ath79_mach_type {
ATH79_MACH_TL_WA750RE, /* TP-LINK TL-WA750RE */
ATH79_MACH_TL_WA7510N_V1, /* TP-LINK TL-WA7510N v1*/
ATH79_MACH_TL_WA850RE, /* TP-LINK TL-WA850RE */
rb2011_setup(RB2011_FLAG_SFP |
--- a/arch/mips/ath79/machtypes.h
+++ b/arch/mips/ath79/machtypes.h
-@@ -93,6 +93,7 @@ enum ath79_mach_type {
+@@ -94,6 +94,7 @@ enum ath79_mach_type {
ATH79_MACH_RB_2011G, /* Mikrotik RouterBOARD 2011UAS-2HnD */
ATH79_MACH_RB_2011L, /* Mikrotik RouterBOARD 2011L */
ATH79_MACH_RB_2011US, /* Mikrotik RouterBOARD 2011UAS */
select SOC_AR933X
--- a/arch/mips/ath79/machtypes.h
+++ b/arch/mips/ath79/machtypes.h
-@@ -52,6 +52,7 @@ enum ath79_mach_type {
+@@ -53,6 +53,7 @@ enum ath79_mach_type {
ATH79_MACH_EAP7660D, /* Senao EAP7660D */
ATH79_MACH_EL_M150, /* EasyLink EL-M150 */
ATH79_MACH_EL_MINI, /* EasyLink EL-MINI */
ATH79_MACH_JA76PF, /* jjPlus JA76PF */
--- a/arch/mips/ath79/Makefile
+++ b/arch/mips/ath79/Makefile
-@@ -64,6 +64,7 @@ obj-$(CONFIG_ATH79_MACH_EW_DORIN) += mac
+@@ -65,6 +65,7 @@ obj-$(CONFIG_ATH79_MACH_EW_DORIN) += mac
obj-$(CONFIG_ATH79_MACH_EAP7660D) += mach-eap7660d.o
obj-$(CONFIG_ATH79_MACH_EL_M150) += mach-el-m150.o
obj-$(CONFIG_ATH79_MACH_EL_MINI) += mach-el-mini.o
select SOC_AR724X
--- a/arch/mips/ath79/Makefile
+++ b/arch/mips/ath79/Makefile
-@@ -64,6 +64,7 @@ obj-$(CONFIG_ATH79_MACH_EW_DORIN) += mac
+@@ -65,6 +65,7 @@ obj-$(CONFIG_ATH79_MACH_EW_DORIN) += mac
obj-$(CONFIG_ATH79_MACH_EAP7660D) += mach-eap7660d.o
obj-$(CONFIG_ATH79_MACH_EL_M150) += mach-el-m150.o
obj-$(CONFIG_ATH79_MACH_EL_MINI) += mach-el-mini.o
obj-$(CONFIG_ATH79_MACH_HIWIFI_HC6361) += mach-hiwifi-hc6361.o
--- a/arch/mips/ath79/machtypes.h
+++ b/arch/mips/ath79/machtypes.h
-@@ -52,6 +52,7 @@ enum ath79_mach_type {
+@@ -53,6 +53,7 @@ enum ath79_mach_type {
ATH79_MACH_EAP7660D, /* Senao EAP7660D */
ATH79_MACH_EL_M150, /* EasyLink EL-M150 */
ATH79_MACH_EL_MINI, /* EasyLink EL-MINI */
--- a/arch/mips/ath79/machtypes.h
+++ b/arch/mips/ath79/machtypes.h
-@@ -47,6 +47,7 @@ enum ath79_mach_type {
+@@ -48,6 +48,7 @@ enum ath79_mach_type {
ATH79_MACH_DIR_825_C1, /* D-Link DIR-825 rev. C1 */
ATH79_MACH_DIR_835_A1, /* D-Link DIR-835 rev. A1 */
ATH79_MACH_DRAGINO2, /* Dragino Version 2 */
select SOC_AR933X
--- a/arch/mips/ath79/Makefile
+++ b/arch/mips/ath79/Makefile
-@@ -60,6 +60,7 @@ obj-$(CONFIG_ATH79_MACH_DIR_615_C1) += m
+@@ -61,6 +61,7 @@ obj-$(CONFIG_ATH79_MACH_DIR_615_C1) += m
obj-$(CONFIG_ATH79_MACH_DIR_825_B1) += mach-dir-825-b1.o
obj-$(CONFIG_ATH79_MACH_DIR_825_C1) += mach-dir-825-c1.o
obj-$(CONFIG_ATH79_MACH_DRAGINO2) += mach-dragino2.o
--- a/arch/mips/ath79/machtypes.h
+++ b/arch/mips/ath79/machtypes.h
-@@ -141,6 +141,7 @@ enum ath79_mach_type {
+@@ -142,6 +142,7 @@ enum ath79_mach_type {
ATH79_MACH_TL_WR841N_V9, /* TP-LINK TL-WR841N/ND v9 */
ATH79_MACH_TL_WR842N_V2, /* TP-LINK TL-WR842N/ND v2 */
ATH79_MACH_TL_WR941ND, /* TP-LINK TL-WR941ND */
select SOC_AR724X
--- a/arch/mips/ath79/Makefile
+++ b/arch/mips/ath79/Makefile
-@@ -116,6 +116,7 @@ obj-$(CONFIG_ATH79_MACH_TL_WR1043ND_V2)
+@@ -117,6 +117,7 @@ obj-$(CONFIG_ATH79_MACH_TL_WR1043ND_V2)
obj-$(CONFIG_ATH79_MACH_TL_WR2543N) += mach-tl-wr2543n.o
obj-$(CONFIG_ATH79_MACH_TL_WR703N) += mach-tl-wr703n.o
obj-$(CONFIG_ATH79_MACH_TL_WR720N_V3) += mach-tl-wr720n-v3.o
--- a/arch/mips/ath79/machtypes.h
+++ b/arch/mips/ath79/machtypes.h
-@@ -50,6 +50,7 @@ enum ath79_mach_type {
+@@ -51,6 +51,7 @@ enum ath79_mach_type {
ATH79_MACH_ESR900, /* EnGenius ESR900 */
ATH79_MACH_EW_DORIN, /* embedded wireless Dorin Platform */
ATH79_MACH_EW_DORIN_ROUTER, /* embedded wireless Dorin Router Platform */
select SOC_AR933X
--- a/arch/mips/ath79/Makefile
+++ b/arch/mips/ath79/Makefile
-@@ -62,6 +62,7 @@ obj-$(CONFIG_ATH79_MACH_DIR_825_C1) += m
+@@ -63,6 +63,7 @@ obj-$(CONFIG_ATH79_MACH_DIR_825_C1) += m
obj-$(CONFIG_ATH79_MACH_DRAGINO2) += mach-dragino2.o
obj-$(CONFIG_ATH79_MACH_ESR900) += mach-esr900.o
obj-$(CONFIG_ATH79_MACH_EW_DORIN) += mach-ew-dorin.o
+
--- a/arch/mips/ath79/machtypes.h
+++ b/arch/mips/ath79/machtypes.h
-@@ -143,6 +143,7 @@ enum ath79_mach_type {
+@@ -144,6 +144,7 @@ enum ath79_mach_type {
ATH79_MACH_TL_WR842N_V2, /* TP-LINK TL-WR842N/ND v2 */
ATH79_MACH_TL_WR941ND, /* TP-LINK TL-WR941ND */
ATH79_MACH_TUBE2H, /* Alfa Network Tube2H */
--- a/arch/mips/ath79/machtypes.h
+++ b/arch/mips/ath79/machtypes.h
-@@ -76,6 +76,7 @@ enum ath79_mach_type {
+@@ -77,6 +77,7 @@ enum ath79_mach_type {
ATH79_MACH_OM2P_LC, /* OpenMesh OM2P-LC */
ATH79_MACH_OM2Pv2, /* OpenMesh OM2Pv2 */
ATH79_MACH_OM2P, /* OpenMesh OM2P */
select SOC_AR934X
--- a/arch/mips/ath79/Makefile
+++ b/arch/mips/ath79/Makefile
-@@ -81,6 +81,7 @@ obj-$(CONFIG_ATH79_MACH_MZK_W04NU) += ma
+@@ -82,6 +82,7 @@ obj-$(CONFIG_ATH79_MACH_MZK_W04NU) += ma
obj-$(CONFIG_ATH79_MACH_MZK_W300NH) += mach-mzk-w300nh.o
obj-$(CONFIG_ATH79_MACH_NBG460N) += mach-nbg460n.o
obj-$(CONFIG_ATH79_MACH_OM2P) += mach-om2p.o
--- a/arch/mips/ath79/machtypes.h
+++ b/arch/mips/ath79/machtypes.h
-@@ -103,6 +103,7 @@ enum ath79_mach_type {
+@@ -104,6 +104,7 @@ enum ath79_mach_type {
ATH79_MACH_RB_SXTLITE2ND, /* Mikrotik RouterBOARD SXT Lite 2nD */
ATH79_MACH_RB_SXTLITE5ND, /* Mikrotik RouterBOARD SXT Lite 5nD */
ATH79_MACH_RW2458N, /* Redwave RW2458N */
select SOC_AR71XX
--- a/arch/mips/ath79/Makefile
+++ b/arch/mips/ath79/Makefile
-@@ -92,6 +92,7 @@ obj-$(CONFIG_ATH79_MACH_RB95X) += mach-
+@@ -93,6 +93,7 @@ obj-$(CONFIG_ATH79_MACH_RB95X) += mach-
obj-$(CONFIG_ATH79_MACH_RB2011) += mach-rb2011.o
obj-$(CONFIG_ATH79_MACH_RBSXTLITE) += mach-rbsxtlite.o
obj-$(CONFIG_ATH79_MACH_RW2458N) += mach-rw2458n.o
MIPS_MACHINE_NONAME(ATH79_MACH_RB_2011R5, "2011r5", rb2011r5_setup);
--- a/arch/mips/ath79/machtypes.h
+++ b/arch/mips/ath79/machtypes.h
-@@ -99,7 +99,7 @@ enum ath79_mach_type {
+@@ -100,7 +100,7 @@ enum ath79_mach_type {
ATH79_MACH_RB_2011G, /* Mikrotik RouterBOARD 2011UAS-2HnD */
ATH79_MACH_RB_2011L, /* Mikrotik RouterBOARD 2011L */
ATH79_MACH_RB_2011US, /* Mikrotik RouterBOARD 2011UAS */
--- a/arch/mips/ath79/Kconfig
+++ b/arch/mips/ath79/Kconfig
-@@ -1044,6 +1044,17 @@ config ATH79_MACH_BHU_BXU2000N2_A
+@@ -1053,6 +1053,17 @@ config ATH79_MACH_BHU_BXU2000N2_A
select ATH79_DEV_USB
select ATH79_DEV_WMAC
config SOC_AR71XX
--- a/arch/mips/ath79/machtypes.h
+++ b/arch/mips/ath79/machtypes.h
-@@ -80,6 +80,7 @@ enum ath79_mach_type {
+@@ -81,6 +81,7 @@ enum ath79_mach_type {
ATH79_MACH_OM5P, /* OpenMesh OM5P */
ATH79_MACH_PB42, /* Atheros PB42 */
ATH79_MACH_PB92, /* Atheros PB92 */
ATH79_MACH_RB_433, /* MikroTik RouterBOARD 433/433AH */
--- a/arch/mips/ath79/Makefile
+++ b/arch/mips/ath79/Makefile
-@@ -85,6 +85,7 @@ obj-$(CONFIG_ATH79_MACH_OM5P) += mach-o
+@@ -86,6 +86,7 @@ obj-$(CONFIG_ATH79_MACH_OM5P) += mach-o
obj-$(CONFIG_ATH79_MACH_PB42) += mach-pb42.o
obj-$(CONFIG_ATH79_MACH_PB44) += mach-pb44.o
obj-$(CONFIG_ATH79_MACH_PB92) += mach-pb92.o
--- a/arch/mips/ath79/machtypes.h
+++ b/arch/mips/ath79/machtypes.h
-@@ -184,6 +184,7 @@ enum ath79_mach_type {
+@@ -185,6 +185,7 @@ enum ath79_mach_type {
ATH79_MACH_WZR_HP_G300NH, /* Buffalo WZR-HP-G300NH */
ATH79_MACH_WZR_HP_G300NH2, /* Buffalo WZR-HP-G300NH2 */
ATH79_MACH_WZR_HP_G450H, /* Buffalo WZR-HP-G450H */
select SOC_AR71XX
--- a/arch/mips/ath79/Makefile
+++ b/arch/mips/ath79/Makefile
-@@ -141,6 +141,7 @@ obj-$(CONFIG_ATH79_MACH_WZR_HP_G300NH) +
+@@ -142,6 +142,7 @@ obj-$(CONFIG_ATH79_MACH_WZR_HP_G300NH) +
obj-$(CONFIG_ATH79_MACH_WZR_HP_G300NH2) += mach-wzr-hp-g300nh2.o
obj-$(CONFIG_ATH79_MACH_WZR_HP_AG300H) += mach-wzr-hp-ag300h.o
obj-$(CONFIG_ATH79_MACH_WZR_HP_G450H) += mach-wzr-hp-g450h.o
--- a/arch/mips/ath79/machtypes.h
+++ b/arch/mips/ath79/machtypes.h
-@@ -39,6 +39,7 @@ enum ath79_mach_type {
- ATH79_MACH_CARAMBOLA2, /* 8devices Carambola2 */
+@@ -40,6 +40,7 @@ enum ath79_mach_type {
+ ATH79_MACH_CPE510, /* TP-LINK CPE510 */
ATH79_MACH_DB120, /* Atheros DB120 reference board */
ATH79_MACH_PB44, /* Atheros PB44 reference board */
+ ATH79_MACH_DHP_1565_A1, /* D-Link DHP-1565 rev. A1 */
select SOC_AR933X
--- a/arch/mips/ath79/Makefile
+++ b/arch/mips/ath79/Makefile
-@@ -54,6 +54,7 @@ obj-$(CONFIG_ATH79_MACH_AW_NR580) += mac
- obj-$(CONFIG_ATH79_MACH_BHU_BXU2000N2_A)+= mach-bhu-bxu2000n2-a.o
+@@ -55,6 +55,7 @@ obj-$(CONFIG_ATH79_MACH_BHU_BXU2000N2_A)
obj-$(CONFIG_ATH79_MACH_CAP4200AG) += mach-cap4200ag.o
+ obj-$(CONFIG_ATH79_MACH_CPE510) += mach-cpe510.o
obj-$(CONFIG_ATH79_MACH_DB120) += mach-db120.o
+obj-$(CONFIG_ATH79_MACH_DHP_1565_A1) += mach-dhp-1565-a1.o
obj-$(CONFIG_ATH79_MACH_DIR_505_A1) += mach-dir-505-a1.o
select SOC_AR71XX
--- a/arch/mips/ath79/Makefile
+++ b/arch/mips/ath79/Makefile
-@@ -75,6 +75,7 @@ obj-$(CONFIG_ATH79_MACH_JA76PF) += mach
+@@ -76,6 +76,7 @@ obj-$(CONFIG_ATH79_MACH_JA76PF) += mach
obj-$(CONFIG_ATH79_MACH_JWAP003) += mach-jwap003.o
obj-$(CONFIG_ATH79_MACH_HORNET_UB) += mach-hornet-ub.o
obj-$(CONFIG_ATH79_MACH_MR600) += mach-mr600.o
obj-$(CONFIG_ATH79_MACH_MYNET_REXT) += mach-mynet-rext.o
--- a/arch/mips/ath79/machtypes.h
+++ b/arch/mips/ath79/machtypes.h
-@@ -66,6 +66,7 @@ enum ath79_mach_type {
+@@ -67,6 +67,7 @@ enum ath79_mach_type {
ATH79_MACH_HORNET_UB, /* ALFA Networks Hornet-UB */
ATH79_MACH_MR600V2, /* OpenMesh MR600v2 */
ATH79_MACH_MR600, /* OpenMesh MR600 */
--- a/arch/mips/ath79/machtypes.h
+++ b/arch/mips/ath79/machtypes.h
-@@ -67,6 +67,7 @@ enum ath79_mach_type {
+@@ -68,6 +68,7 @@ enum ath79_mach_type {
ATH79_MACH_MR600V2, /* OpenMesh MR600v2 */
ATH79_MACH_MR600, /* OpenMesh MR600 */
ATH79_MACH_MR900, /* OpenMesh MR900 */
select SOC_AR71XX
--- a/arch/mips/ath79/Makefile
+++ b/arch/mips/ath79/Makefile
-@@ -88,6 +88,7 @@ obj-$(CONFIG_ATH79_MACH_PB42) += mach-p
+@@ -89,6 +89,7 @@ obj-$(CONFIG_ATH79_MACH_PB42) += mach-p
obj-$(CONFIG_ATH79_MACH_PB44) += mach-pb44.o
obj-$(CONFIG_ATH79_MACH_PB92) += mach-pb92.o
obj-$(CONFIG_ATH79_MACH_QIHOO_C301) += mach-qihoo-c301.o
obj-$(CONFIG_ATH79_MACH_RB91X) += mach-rb91x.o
--- a/arch/mips/ath79/machtypes.h
+++ b/arch/mips/ath79/machtypes.h
-@@ -84,6 +84,7 @@ enum ath79_mach_type {
+@@ -85,6 +85,7 @@ enum ath79_mach_type {
ATH79_MACH_PB42, /* Atheros PB42 */
ATH79_MACH_PB92, /* Atheros PB92 */
ATH79_MACH_QIHOO_C301, /* Qihoo 360 C301 */
--- a/arch/mips/alchemy/board-mtx1.c
+++ b/arch/mips/alchemy/board-mtx1.c
-@@ -171,7 +171,7 @@ static struct platform_device mtx1_gpio_
+@@ -169,7 +169,7 @@ static struct platform_device mtx1_gpio_
static struct mtd_partition mtx1_mtd_partitions[] = {
{
--- a/drivers/net/ethernet/amd/au1000_eth.c
+++ b/drivers/net/ethernet/amd/au1000_eth.c
-@@ -990,10 +990,14 @@ static void au1000_multicast_list(struct
+@@ -988,10 +988,14 @@ static void au1000_multicast_list(struct
writel(reg, &aup->mac->control);
}
--- a/arch/mips/alchemy/board-mtx1.c
+++ b/arch/mips/alchemy/board-mtx1.c
-@@ -100,6 +100,9 @@ void __init board_setup(void)
+@@ -98,6 +98,9 @@ void __init board_setup(void)
alchemy_gpio_direction_output(211, 1); /* green on */
alchemy_gpio_direction_output(212, 0); /* red off */
create mode 100644 arch/arm/mach-bcm2708/vcio.c
create mode 100644 drivers/mmc/host/sdhci-bcm2708.c
-diff --git a/arch/arm/Kconfig b/arch/arm/Kconfig
-index 4733d32..9e23417 100644
--- a/arch/arm/Kconfig
+++ b/arch/arm/Kconfig
@@ -380,6 +380,22 @@ config ARCH_AT91
source "arch/arm/mach-zynq/Kconfig"
-diff --git a/arch/arm/Kconfig.debug b/arch/arm/Kconfig.debug
-index 0531da8..117fb79 100644
--- a/arch/arm/Kconfig.debug
+++ b/arch/arm/Kconfig.debug
@@ -920,6 +920,14 @@ choice
endchoice
config DEBUG_EXYNOS_UART
-diff --git a/arch/arm/Makefile b/arch/arm/Makefile
-index 08a9ef5..755e9c2 100644
--- a/arch/arm/Makefile
+++ b/arch/arm/Makefile
-@@ -143,6 +143,7 @@ textofs-$(CONFIG_ARCH_MSM8960) := 0x00208000
+@@ -148,6 +148,7 @@ textofs-$(CONFIG_ARCH_MSM8960) := 0x0020
# by CONFIG_* macro name.
machine-$(CONFIG_ARCH_AT91) += at91
machine-$(CONFIG_ARCH_BCM) += bcm
machine-$(CONFIG_ARCH_BCM2835) += bcm2835
machine-$(CONFIG_ARCH_BERLIN) += berlin
machine-$(CONFIG_ARCH_CLPS711X) += clps711x
-diff --git a/arch/arm/configs/bcmrpi_cutdown_defconfig b/arch/arm/configs/bcmrpi_cutdown_defconfig
-new file mode 100644
-index 0000000..74f2dc9
--- /dev/null
+++ b/arch/arm/configs/bcmrpi_cutdown_defconfig
@@ -0,0 +1,474 @@
+# CONFIG_CRYPTO_HW is not set
+CONFIG_CRC_ITU_T=y
+CONFIG_LIBCRC32C=y
-diff --git a/arch/arm/configs/bcmrpi_defconfig b/arch/arm/configs/bcmrpi_defconfig
-new file mode 100644
-index 0000000..339aabf
--- /dev/null
+++ b/arch/arm/configs/bcmrpi_defconfig
@@ -0,0 +1,510 @@
+# CONFIG_CRYPTO_HW is not set
+CONFIG_CRC_ITU_T=y
+CONFIG_LIBCRC32C=y
-diff --git a/arch/arm/configs/bcmrpi_emergency_defconfig b/arch/arm/configs/bcmrpi_emergency_defconfig
-new file mode 100644
-index 0000000..3b40c49
--- /dev/null
+++ b/arch/arm/configs/bcmrpi_emergency_defconfig
@@ -0,0 +1,532 @@
+# CONFIG_CRYPTO_HW is not set
+CONFIG_CRC_ITU_T=y
+CONFIG_LIBCRC32C=y
-diff --git a/arch/arm/kernel/process.c b/arch/arm/kernel/process.c
-index 92f7b15..7b5ed03 100644
--- a/arch/arm/kernel/process.c
+++ b/arch/arm/kernel/process.c
@@ -176,6 +176,16 @@ void arch_cpu_idle(void)
/*
* Called by kexec, immediately prior to machine_kexec().
*
-diff --git a/arch/arm/mach-bcm2708/Kconfig b/arch/arm/mach-bcm2708/Kconfig
-new file mode 100644
-index 0000000..9355841
--- /dev/null
+++ b/arch/arm/mach-bcm2708/Kconfig
@@ -0,0 +1,34 @@
+ Do not allow ARM to use GPU's L2 cache. Requires disable_l2cache in config.txt.
+
+endmenu
-diff --git a/arch/arm/mach-bcm2708/Makefile b/arch/arm/mach-bcm2708/Makefile
-new file mode 100644
-index 0000000..a722f3f
--- /dev/null
+++ b/arch/arm/mach-bcm2708/Makefile
@@ -0,0 +1,7 @@
+obj-$(CONFIG_MACH_BCM2708) += clock.o bcm2708.o armctrl.o vcio.o power.o dma.o
+obj-$(CONFIG_BCM2708_GPIO) += bcm2708_gpio.o
+obj-$(CONFIG_BCM2708_VCMEM) += vc_mem.o
-diff --git a/arch/arm/mach-bcm2708/Makefile.boot b/arch/arm/mach-bcm2708/Makefile.boot
-new file mode 100644
-index 0000000..67039c3
--- /dev/null
+++ b/arch/arm/mach-bcm2708/Makefile.boot
@@ -0,0 +1,3 @@
+ zreladdr-y := 0x00008000
+params_phys-y := 0x00000100
+initrd_phys-y := 0x00800000
-diff --git a/arch/arm/mach-bcm2708/armctrl.c b/arch/arm/mach-bcm2708/armctrl.c
-new file mode 100644
-index 0000000..da18725
--- /dev/null
+++ b/arch/arm/mach-bcm2708/armctrl.c
@@ -0,0 +1,208 @@
+ armctrl_pm_register(base, irq_start, resume_sources);
+ return 0;
+}
-diff --git a/arch/arm/mach-bcm2708/armctrl.h b/arch/arm/mach-bcm2708/armctrl.h
-new file mode 100644
-index 0000000..0aa916e
--- /dev/null
+++ b/arch/arm/mach-bcm2708/armctrl.h
@@ -0,0 +1,27 @@
+ u32 armctrl_sources, u32 resume_sources);
+
+#endif
-diff --git a/arch/arm/mach-bcm2708/bcm2708.c b/arch/arm/mach-bcm2708/bcm2708.c
-new file mode 100644
-index 0000000..a5af6ec
--- /dev/null
+++ b/arch/arm/mach-bcm2708/bcm2708.c
@@ -0,0 +1,720 @@
+module_param(disk_led_gpio, uint, 0644);
+module_param(disk_led_active_low, uint, 0644);
+module_param(reboot_part, uint, 0644);
-diff --git a/arch/arm/mach-bcm2708/bcm2708.h b/arch/arm/mach-bcm2708/bcm2708.h
-new file mode 100644
-index 0000000..e339a93
--- /dev/null
+++ b/arch/arm/mach-bcm2708/bcm2708.h
@@ -0,0 +1,49 @@
+}
+
+#endif
-diff --git a/arch/arm/mach-bcm2708/bcm2708_gpio.c b/arch/arm/mach-bcm2708/bcm2708_gpio.c
-new file mode 100644
-index 0000000..120929ff
--- /dev/null
+++ b/arch/arm/mach-bcm2708/bcm2708_gpio.c
@@ -0,0 +1,361 @@
+
+MODULE_DESCRIPTION("Broadcom BCM2708 GPIO driver");
+MODULE_LICENSE("GPL");
-diff --git a/arch/arm/mach-bcm2708/clock.c b/arch/arm/mach-bcm2708/clock.c
-new file mode 100644
-index 0000000..4fc556e
--- /dev/null
+++ b/arch/arm/mach-bcm2708/clock.c
@@ -0,0 +1,61 @@
+ return -EIO;
+}
+EXPORT_SYMBOL(clk_set_rate);
-diff --git a/arch/arm/mach-bcm2708/clock.h b/arch/arm/mach-bcm2708/clock.h
-new file mode 100644
-index 0000000..5f9d725
--- /dev/null
+++ b/arch/arm/mach-bcm2708/clock.h
@@ -0,0 +1,24 @@
+struct clk {
+ unsigned long rate;
+};
-diff --git a/arch/arm/mach-bcm2708/dma.c b/arch/arm/mach-bcm2708/dma.c
-new file mode 100644
-index 0000000..51d147a
--- /dev/null
+++ b/arch/arm/mach-bcm2708/dma.c
@@ -0,0 +1,399 @@
+MODULE_LICENSE("GPL");
+
+MODULE_PARM_DESC(dmachans, "Bitmap of DMA channels available to the ARM");
-diff --git a/arch/arm/mach-bcm2708/include/mach/arm_control.h b/arch/arm/mach-bcm2708/include/mach/arm_control.h
-new file mode 100644
-index 0000000..a82bb92
--- /dev/null
+++ b/arch/arm/mach-bcm2708/include/mach/arm_control.h
@@ -0,0 +1,419 @@
+#define AJBTDO HW_REGISTER_RW(AJB_BASE+0x0c)
+
+#endif
-diff --git a/arch/arm/mach-bcm2708/include/mach/arm_power.h b/arch/arm/mach-bcm2708/include/mach/arm_power.h
-new file mode 100644
-index 0000000..aae9136
--- /dev/null
+++ b/arch/arm/mach-bcm2708/include/mach/arm_power.h
@@ -0,0 +1,60 @@
+};
+
+#endif
-diff --git a/arch/arm/mach-bcm2708/include/mach/clkdev.h b/arch/arm/mach-bcm2708/include/mach/clkdev.h
-new file mode 100644
-index 0000000..04b37a8
--- /dev/null
+++ b/arch/arm/mach-bcm2708/include/mach/clkdev.h
@@ -0,0 +1,7 @@
+#define __clk_put(clk) do { } while (0)
+
+#endif
-diff --git a/arch/arm/mach-bcm2708/include/mach/debug-macro.S b/arch/arm/mach-bcm2708/include/mach/debug-macro.S
-new file mode 100644
-index 0000000..b24304a
--- /dev/null
+++ b/arch/arm/mach-bcm2708/include/mach/debug-macro.S
@@ -0,0 +1,22 @@
+ .endm
+
+#include <debug/pl01x.S>
-diff --git a/arch/arm/mach-bcm2708/include/mach/dma.h b/arch/arm/mach-bcm2708/include/mach/dma.h
-new file mode 100644
-index 0000000..ac7a4a0
--- /dev/null
+++ b/arch/arm/mach-bcm2708/include/mach/dma.h
@@ -0,0 +1,86 @@
+
+
+#endif /* _MACH_BCM2708_DMA_H */
-diff --git a/arch/arm/mach-bcm2708/include/mach/entry-macro.S b/arch/arm/mach-bcm2708/include/mach/entry-macro.S
-new file mode 100644
-index 0000000..79b62d9
--- /dev/null
+++ b/arch/arm/mach-bcm2708/include/mach/entry-macro.S
@@ -0,0 +1,69 @@
+1020: @ EQ will be set if no irqs pending
+
+ .endm
-diff --git a/arch/arm/mach-bcm2708/include/mach/frc.h b/arch/arm/mach-bcm2708/include/mach/frc.h
-new file mode 100644
-index 0000000..dd51e07
--- /dev/null
+++ b/arch/arm/mach-bcm2708/include/mach/frc.h
@@ -0,0 +1,38 @@
+extern unsigned long long frc_clock_ticks63(void);
+
+#endif
-diff --git a/arch/arm/mach-bcm2708/include/mach/gpio.h b/arch/arm/mach-bcm2708/include/mach/gpio.h
-new file mode 100644
-index 0000000..7965a97
--- /dev/null
+++ b/arch/arm/mach-bcm2708/include/mach/gpio.h
@@ -0,0 +1,17 @@
+#define irq_to_gpio(x) ((x) - GPIO_IRQ_START)
+
+#endif
-diff --git a/arch/arm/mach-bcm2708/include/mach/hardware.h b/arch/arm/mach-bcm2708/include/mach/hardware.h
-new file mode 100644
-index 0000000..c2954e8
--- /dev/null
+++ b/arch/arm/mach-bcm2708/include/mach/hardware.h
@@ -0,0 +1,28 @@
+#include <mach/platform.h>
+
+#endif
-diff --git a/arch/arm/mach-bcm2708/include/mach/io.h b/arch/arm/mach-bcm2708/include/mach/io.h
-new file mode 100644
-index 0000000..e6eb84d
--- /dev/null
+++ b/arch/arm/mach-bcm2708/include/mach/io.h
@@ -0,0 +1,27 @@
+#define __io(a) __typesafe_io(a)
+
+#endif
-diff --git a/arch/arm/mach-bcm2708/include/mach/irqs.h b/arch/arm/mach-bcm2708/include/mach/irqs.h
-new file mode 100644
-index 0000000..faf5d1a
--- /dev/null
+++ b/arch/arm/mach-bcm2708/include/mach/irqs.h
@@ -0,0 +1,194 @@
+#define NR_IRQS (HARD_IRQS+GPIO_IRQS+SPARE_IRQS)
+
+#endif /* _BCM2708_IRQS_H_ */
-diff --git a/arch/arm/mach-bcm2708/include/mach/memory.h b/arch/arm/mach-bcm2708/include/mach/memory.h
-new file mode 100644
-index 0000000..521540d
--- /dev/null
+++ b/arch/arm/mach-bcm2708/include/mach/memory.h
@@ -0,0 +1,57 @@
+#define __bus_to_pfn(x) __phys_to_pfn((x) - (BUS_OFFSET - PLAT_PHYS_OFFSET))
+
+#endif
-diff --git a/arch/arm/mach-bcm2708/include/mach/platform.h b/arch/arm/mach-bcm2708/include/mach/platform.h
-new file mode 100644
-index 0000000..110ce07
--- /dev/null
+++ b/arch/arm/mach-bcm2708/include/mach/platform.h
@@ -0,0 +1,220 @@
+#endif
+
+/* END */
-diff --git a/arch/arm/mach-bcm2708/include/mach/power.h b/arch/arm/mach-bcm2708/include/mach/power.h
-new file mode 100644
-index 0000000..52b3b02
--- /dev/null
+++ b/arch/arm/mach-bcm2708/include/mach/power.h
@@ -0,0 +1,26 @@
+extern int bcm_power_close(BCM_POWER_HANDLE_T handle);
+
+#endif
-diff --git a/arch/arm/mach-bcm2708/include/mach/system.h b/arch/arm/mach-bcm2708/include/mach/system.h
-new file mode 100644
-index 0000000..2d0b821
--- /dev/null
+++ b/arch/arm/mach-bcm2708/include/mach/system.h
@@ -0,0 +1,38 @@
+}
+
+#endif
-diff --git a/arch/arm/mach-bcm2708/include/mach/timex.h b/arch/arm/mach-bcm2708/include/mach/timex.h
-new file mode 100644
-index 0000000..64a660c
--- /dev/null
+++ b/arch/arm/mach-bcm2708/include/mach/timex.h
@@ -0,0 +1,23 @@
+ */
+
+#define CLOCK_TICK_RATE (1000000)
-diff --git a/arch/arm/mach-bcm2708/include/mach/uncompress.h b/arch/arm/mach-bcm2708/include/mach/uncompress.h
-new file mode 100644
-index 0000000..d634813
--- /dev/null
+++ b/arch/arm/mach-bcm2708/include/mach/uncompress.h
@@ -0,0 +1,84 @@
+ * nothing to do
+ */
+#define arch_decomp_wdog()
-diff --git a/arch/arm/mach-bcm2708/include/mach/vc_mem.h b/arch/arm/mach-bcm2708/include/mach/vc_mem.h
-new file mode 100644
-index 0000000..4a4a338
--- /dev/null
+++ b/arch/arm/mach-bcm2708/include/mach/vc_mem.h
@@ -0,0 +1,35 @@
+#endif
+
+#endif /* VC_MEM_H */
-diff --git a/arch/arm/mach-bcm2708/include/mach/vcio.h b/arch/arm/mach-bcm2708/include/mach/vcio.h
-new file mode 100644
-index 0000000..9935e02
--- /dev/null
+++ b/arch/arm/mach-bcm2708/include/mach/vcio.h
@@ -0,0 +1,141 @@
+#define DEVICE_FILE_NAME "char_dev"
+
+#endif
-diff --git a/arch/arm/mach-bcm2708/include/mach/vmalloc.h b/arch/arm/mach-bcm2708/include/mach/vmalloc.h
-new file mode 100644
-index 0000000..502c617
--- /dev/null
+++ b/arch/arm/mach-bcm2708/include/mach/vmalloc.h
@@ -0,0 +1,20 @@
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+ */
+#define VMALLOC_END (0xe8000000)
-diff --git a/arch/arm/mach-bcm2708/power.c b/arch/arm/mach-bcm2708/power.c
-new file mode 100644
-index 0000000..256bf1a
--- /dev/null
+++ b/arch/arm/mach-bcm2708/power.c
@@ -0,0 +1,194 @@
+MODULE_AUTHOR("Phil Elwell");
+MODULE_DESCRIPTION("Interface to BCM2708 power management");
+MODULE_LICENSE("GPL");
-diff --git a/arch/arm/mach-bcm2708/vc_mem.c b/arch/arm/mach-bcm2708/vc_mem.c
-new file mode 100644
-index 0000000..2adac12
--- /dev/null
+++ b/arch/arm/mach-bcm2708/vc_mem.c
@@ -0,0 +1,432 @@
+module_param(mem_size, uint, 0644);
+module_param(mem_base, uint, 0644);
+
-diff --git a/arch/arm/mach-bcm2708/vcio.c b/arch/arm/mach-bcm2708/vcio.c
-new file mode 100644
-index 0000000..5e43e85
--- /dev/null
+++ b/arch/arm/mach-bcm2708/vcio.c
@@ -0,0 +1,474 @@
+MODULE_DESCRIPTION("ARM I/O to VideoCore processor");
+MODULE_LICENSE("GPL");
+MODULE_ALIAS("platform:bcm-mbox");
-diff --git a/arch/arm/mm/Kconfig b/arch/arm/mm/Kconfig
-index ca8ecde..4afbeda 100644
--- a/arch/arm/mm/Kconfig
+++ b/arch/arm/mm/Kconfig
@@ -358,7 +358,7 @@ config CPU_PJ4B
select CPU_32v6
select CPU_ABRT_EV6
select CPU_CACHE_V6
-diff --git a/arch/arm/mm/proc-v6.S b/arch/arm/mm/proc-v6.S
-index 32b3558..4712ccb 100644
--- a/arch/arm/mm/proc-v6.S
+++ b/arch/arm/mm/proc-v6.S
@@ -73,10 +73,19 @@ ENDPROC(cpu_v6_reset)
mov pc, lr
ENTRY(cpu_v6_dcache_clean_area)
-diff --git a/arch/arm/tools/mach-types b/arch/arm/tools/mach-types
-index a10297d..c9ddd87 100644
--- a/arch/arm/tools/mach-types
+++ b/arch/arm/tools/mach-types
@@ -522,6 +522,7 @@ torbreck MACH_TORBRECK TORBRECK 3090
ag5evm MACH_AG5EVM AG5EVM 3189
ics_if_voip MACH_ICS_IF_VOIP ICS_IF_VOIP 3206
wlf_cragg_6410 MACH_WLF_CRAGG_6410 WLF_CRAGG_6410 3207
-diff --git a/drivers/mmc/host/Kconfig b/drivers/mmc/host/Kconfig
-index 1384f67..bad4c9b 100644
--- a/drivers/mmc/host/Kconfig
+++ b/drivers/mmc/host/Kconfig
@@ -272,6 +272,27 @@ config MMC_SDHCI_BCM_KONA
config MMC_SDHCI_BCM2835
tristate "SDHCI platform support for the BCM2835 SD/MMC Controller"
depends on ARCH_BCM2835
-diff --git a/drivers/mmc/host/Makefile b/drivers/mmc/host/Makefile
-index 3483b6b..11460d7 100644
--- a/drivers/mmc/host/Makefile
+++ b/drivers/mmc/host/Makefile
-@@ -16,6 +16,7 @@ obj-$(CONFIG_MMC_SDHCI_PXAV2) += sdhci-pxav2.o
+@@ -16,6 +16,7 @@ obj-$(CONFIG_MMC_SDHCI_PXAV2) += sdhci-p
obj-$(CONFIG_MMC_SDHCI_S3C) += sdhci-s3c.o
obj-$(CONFIG_MMC_SDHCI_SIRF) += sdhci-sirf.o
obj-$(CONFIG_MMC_SDHCI_SPEAR) += sdhci-spear.o
obj-$(CONFIG_MMC_WBSD) += wbsd.o
obj-$(CONFIG_MMC_AU1X) += au1xmmc.o
obj-$(CONFIG_MMC_OMAP) += omap.o
-diff --git a/drivers/mmc/host/sdhci-bcm2708.c b/drivers/mmc/host/sdhci-bcm2708.c
-new file mode 100644
-index 0000000..d8ef77c
--- /dev/null
+++ b/drivers/mmc/host/sdhci-bcm2708.c
@@ -0,0 +1,1424 @@
+MODULE_AUTHOR("Broadcom <info@broadcom.com>");
+MODULE_LICENSE("GPL v2");
+MODULE_ALIAS("platform:"DRIVER_NAME);
-diff --git a/drivers/mmc/host/sdhci.c b/drivers/mmc/host/sdhci.c
-index 9ddef47..b78afa2 100644
--- a/drivers/mmc/host/sdhci.c
+++ b/drivers/mmc/host/sdhci.c
@@ -28,6 +28,7 @@
#include <linux/mmc/slot-gpio.h>
#include "sdhci.h"
-@@ -326,7 +327,7 @@ static void sdhci_read_block_pio(struct sdhci_host *host)
+@@ -326,7 +327,7 @@ static void sdhci_read_block_pio(struct
u32 uninitialized_var(scratch);
u8 *buf;
blksize = host->data->blksz;
chunk = 0;
-@@ -371,7 +372,7 @@ static void sdhci_write_block_pio(struct sdhci_host *host)
+@@ -371,7 +372,7 @@ static void sdhci_write_block_pio(struct
u32 scratch;
u8 *buf;
blksize = host->data->blksz;
chunk = 0;
-@@ -410,19 +411,28 @@ static void sdhci_write_block_pio(struct sdhci_host *host)
+@@ -410,19 +411,28 @@ static void sdhci_write_block_pio(struct
local_irq_restore(flags);
}
/*
* Some controllers (JMicron JMB38x) mess up the buffer bits
-@@ -433,7 +443,7 @@ static void sdhci_transfer_pio(struct sdhci_host *host)
+@@ -433,7 +443,7 @@ static void sdhci_transfer_pio(struct sd
(host->data->blocks == 1))
mask = ~0;
if (host->quirks & SDHCI_QUIRK_PIO_NEEDS_DELAY)
udelay(100);
-@@ -445,9 +455,11 @@ static void sdhci_transfer_pio(struct sdhci_host *host)
+@@ -445,9 +455,11 @@ static void sdhci_transfer_pio(struct sd
host->blocks--;
if (host->blocks == 0)
break;
}
static char *sdhci_kmap_atomic(struct scatterlist *sg, unsigned long *flags)
-@@ -720,7 +732,9 @@ static void sdhci_set_transfer_irqs(struct sdhci_host *host)
+@@ -720,7 +732,9 @@ static void sdhci_set_transfer_irqs(stru
u32 pio_irqs = SDHCI_INT_DATA_AVAIL | SDHCI_INT_SPACE_AVAIL;
u32 dma_irqs = SDHCI_INT_DMA_END | SDHCI_INT_ADMA_ERROR;
sdhci_clear_set_irqs(host, pio_irqs, dma_irqs);
else
sdhci_clear_set_irqs(host, dma_irqs, pio_irqs);
-@@ -752,44 +766,25 @@ static void sdhci_prepare_data(struct sdhci_host *host, struct mmc_command *cmd)
+@@ -752,44 +766,25 @@ static void sdhci_prepare_data(struct sd
host->data_early = 0;
host->data->bytes_xfered = 0;
int broken, i;
struct scatterlist *sg;
-@@ -848,7 +843,8 @@ static void sdhci_prepare_data(struct sdhci_host *host, struct mmc_command *cmd)
+@@ -848,7 +843,8 @@ static void sdhci_prepare_data(struct sd
*/
WARN_ON(1);
host->flags &= ~SDHCI_REQ_USE_DMA;
WARN_ON(sg_cnt != 1);
sdhci_writel(host, sg_dma_address(data->sg),
SDHCI_DMA_ADDRESS);
-@@ -864,11 +860,13 @@ static void sdhci_prepare_data(struct sdhci_host *host, struct mmc_command *cmd)
+@@ -864,11 +860,13 @@ static void sdhci_prepare_data(struct sd
if (host->version >= SDHCI_SPEC_200) {
ctrl = sdhci_readb(host, SDHCI_HOST_CONTROL);
ctrl &= ~SDHCI_CTRL_DMA_MASK;
sdhci_writeb(host, ctrl, SDHCI_HOST_CONTROL);
}
-@@ -925,7 +923,8 @@ static void sdhci_set_transfer_mode(struct sdhci_host *host,
+@@ -925,7 +923,8 @@ static void sdhci_set_transfer_mode(stru
if (data->flags & MMC_DATA_READ)
mode |= SDHCI_TRNS_READ;
mode |= SDHCI_TRNS_DMA;
sdhci_writew(host, mode, SDHCI_TRANSFER_MODE);
-@@ -941,13 +940,16 @@ static void sdhci_finish_data(struct sdhci_host *host)
+@@ -941,13 +940,16 @@ static void sdhci_finish_data(struct sdh
host->data = NULL;
if (host->flags & SDHCI_REQ_USE_DMA) {
}
/*
-@@ -1000,6 +1002,12 @@ void sdhci_send_command(struct sdhci_host *host, struct mmc_command *cmd)
+@@ -1000,6 +1002,12 @@ void sdhci_send_command(struct sdhci_hos
if ((cmd->data != NULL) || (cmd->flags & MMC_RSP_BUSY))
mask |= SDHCI_DATA_INHIBIT;
/* We shouldn't wait for data inihibit for stop commands, even
though they might use busy signaling */
if (host->mrq->data && (cmd == host->mrq->data->stop))
-@@ -1017,6 +1025,8 @@ void sdhci_send_command(struct sdhci_host *host, struct mmc_command *cmd)
+@@ -1017,6 +1025,8 @@ void sdhci_send_command(struct sdhci_hos
timeout--;
mdelay(1);
}
timeout = jiffies;
if (!cmd->data && cmd->cmd_timeout_ms > 9000)
-@@ -1026,6 +1036,10 @@ void sdhci_send_command(struct sdhci_host *host, struct mmc_command *cmd)
+@@ -1026,6 +1036,10 @@ void sdhci_send_command(struct sdhci_hos
mod_timer(&host->timer, timeout);
host->cmd = cmd;
sdhci_prepare_data(host, cmd);
-@@ -1505,7 +1519,7 @@ static void sdhci_do_set_ios(struct sdhci_host *host, struct mmc_ios *ios)
+@@ -1505,7 +1519,7 @@ static void sdhci_do_set_ios(struct sdhc
else
ctrl &= ~SDHCI_CTRL_HISPD;
u16 clk, ctrl_2;
/* In case of UHS-I modes, set High Speed Enable */
-@@ -2204,7 +2218,7 @@ static void sdhci_timeout_timer(unsigned long data)
+@@ -2204,7 +2218,7 @@ static void sdhci_timeout_timer(unsigned
if (host->mrq) {
pr_err("%s: Timeout waiting for hardware "
sdhci_dumpregs(host);
if (host->data) {
-@@ -2249,10 +2263,13 @@ static void sdhci_cmd_irq(struct sdhci_host *host, u32 intmask)
+@@ -2249,10 +2263,13 @@ static void sdhci_cmd_irq(struct sdhci_h
BUG_ON(intmask == 0);
if (!host->cmd) {
return;
}
-@@ -2322,6 +2339,19 @@ static void sdhci_show_adma_error(struct sdhci_host *host)
+@@ -2322,6 +2339,19 @@ static void sdhci_show_adma_error(struct
static void sdhci_show_adma_error(struct sdhci_host *host) { }
#endif
static void sdhci_data_irq(struct sdhci_host *host, u32 intmask)
{
u32 command;
-@@ -2351,23 +2381,39 @@ static void sdhci_data_irq(struct sdhci_host *host, u32 intmask)
+@@ -2351,23 +2381,39 @@ static void sdhci_data_irq(struct sdhci_
}
}
pr_err("%s: ADMA error\n", mmc_hostname(host->mmc));
sdhci_show_adma_error(host);
host->data->error = -EIO;
-@@ -2375,11 +2421,18 @@ static void sdhci_data_irq(struct sdhci_host *host, u32 intmask)
+@@ -2375,11 +2421,18 @@ static void sdhci_data_irq(struct sdhci_
host->ops->adma_workaround(host, intmask);
}
/*
* We currently don't do anything fancy with DMA
-@@ -2408,18 +2461,8 @@ static void sdhci_data_irq(struct sdhci_host *host, u32 intmask)
+@@ -2408,18 +2461,8 @@ static void sdhci_data_irq(struct sdhci_
sdhci_writel(host, dmanow, SDHCI_DMA_ADDRESS);
}
if (intmask & SDHCI_INT_BUS_POWER) {
pr_err("%s: Card is consuming too much power!\n",
-@@ -2602,7 +2667,8 @@ int sdhci_resume_host(struct sdhci_host *host)
+@@ -2602,7 +2667,8 @@ int sdhci_resume_host(struct sdhci_host
{
int ret = 0;
if (host->ops->enable_dma)
host->ops->enable_dma(host);
}
-@@ -2833,14 +2899,16 @@ int sdhci_add_host(struct sdhci_host *host)
+@@ -2833,14 +2899,16 @@ int sdhci_add_host(struct sdhci_host *ho
host->flags &= ~SDHCI_USE_ADMA;
}
}
}
}
-@@ -3266,6 +3334,7 @@ int sdhci_add_host(struct sdhci_host *host)
+@@ -3266,6 +3334,7 @@ int sdhci_add_host(struct sdhci_host *ho
pr_info("%s: SDHCI controller on %s [%s] using %s\n",
mmc_hostname(mmc), host->hw_name, dev_name(mmc_dev(mmc)),
(host->flags & SDHCI_USE_ADMA) ? "ADMA" :
(host->flags & SDHCI_USE_SDMA) ? "DMA" : "PIO");
-diff --git a/drivers/mmc/host/sdhci.h b/drivers/mmc/host/sdhci.h
-index 0a3ed01..6857875 100644
--- a/drivers/mmc/host/sdhci.h
+++ b/drivers/mmc/host/sdhci.h
@@ -290,6 +290,20 @@ struct sdhci_ops {
void (*hw_reset)(struct sdhci_host *host);
void (*platform_suspend)(struct sdhci_host *host);
void (*platform_resume)(struct sdhci_host *host);
-@@ -403,6 +417,29 @@ extern int sdhci_resume_host(struct sdhci_host *host);
+@@ -403,6 +417,29 @@ extern int sdhci_resume_host(struct sdhc
extern void sdhci_enable_irq_wakeups(struct sdhci_host *host);
#endif
#ifdef CONFIG_PM_RUNTIME
extern int sdhci_runtime_suspend_host(struct sdhci_host *host);
extern int sdhci_runtime_resume_host(struct sdhci_host *host);
-diff --git a/drivers/tty/serial/amba-pl011.c b/drivers/tty/serial/amba-pl011.c
-index b569011..76fa055 100644
--- a/drivers/tty/serial/amba-pl011.c
+++ b/drivers/tty/serial/amba-pl011.c
@@ -84,7 +84,7 @@ struct vendor_data {
}
static struct vendor_data vendor_arm = {
-diff --git a/include/linux/mmc/sdhci.h b/include/linux/mmc/sdhci.h
-index 362927c4..e23fffb 100644
--- a/include/linux/mmc/sdhci.h
+++ b/include/linux/mmc/sdhci.h
@@ -133,6 +133,7 @@ struct sdhci_host {
struct mmc_data *data; /* Current data request */
unsigned int data_early:1; /* Data finished before cmd */
---
-1.9.1
-
1 file changed, 197 insertions(+)
create mode 100644 arch/arm/configs/bcmrpi_quick_defconfig
-diff --git a/arch/arm/configs/bcmrpi_quick_defconfig b/arch/arm/configs/bcmrpi_quick_defconfig
-new file mode 100644
-index 0000000..e5efe75
--- /dev/null
+++ b/arch/arm/configs/bcmrpi_quick_defconfig
@@ -0,0 +1,197 @@
+# CONFIG_CRYPTO_HW is not set
+CONFIG_CRC_ITU_T=y
+CONFIG_LIBCRC32C=y
---
-1.9.1
-
create mode 100644 drivers/usb/host/dwc_otg/test/test_mod_param.pl
create mode 100644 drivers/usb/host/dwc_otg/test/test_sysfs.pl
-diff --git a/drivers/usb/Makefile b/drivers/usb/Makefile
-index 1ae2bf3..c4a45aa 100644
--- a/drivers/usb/Makefile
+++ b/drivers/usb/Makefile
@@ -24,6 +24,7 @@ obj-$(CONFIG_USB_U132_HCD) += host/
obj-$(CONFIG_USB_IMX21_HCD) += host/
obj-$(CONFIG_USB_FSL_MPH_DR_OF) += host/
obj-$(CONFIG_USB_FUSBH200_HCD) += host/
-diff --git a/drivers/usb/core/generic.c b/drivers/usb/core/generic.c
-index acbfeb0..7d675c8 100644
--- a/drivers/usb/core/generic.c
+++ b/drivers/usb/core/generic.c
-@@ -152,6 +152,7 @@ int usb_choose_configuration(struct usb_device *udev)
+@@ -152,6 +152,7 @@ int usb_choose_configuration(struct usb_
dev_warn(&udev->dev,
"no configuration chosen from %d choice%s\n",
num_configs, plural(num_configs));
}
return i;
}
-diff --git a/drivers/usb/core/message.c b/drivers/usb/core/message.c
-index f829a1a..4a44ae7 100644
--- a/drivers/usb/core/message.c
+++ b/drivers/usb/core/message.c
@@ -1888,6 +1888,85 @@ free_interfaces:
/* Now that the interfaces are installed, re-enable LPM. */
usb_unlocked_enable_lpm(dev);
-diff --git a/drivers/usb/core/otg_whitelist.h b/drivers/usb/core/otg_whitelist.h
-index e8cdce5..ca0ac47 100644
--- a/drivers/usb/core/otg_whitelist.h
+++ b/drivers/usb/core/otg_whitelist.h
@@ -19,33 +19,82 @@
static int is_targeted(struct usb_device *dev)
{
struct usb_device_id *id = whitelist_table;
-@@ -55,58 +104,83 @@ static int is_targeted(struct usb_device *dev)
+@@ -55,58 +104,83 @@ static int is_targeted(struct usb_device
return 1;
/* HNP test device is _never_ targeted (see OTG spec 6.6.6) */
+ } else if (!enable_whitelist) {
+ return 1;
+ } else {
-+
+
+- /* NOTE: can't use usb_match_id() since interface caches
+- * aren't set up yet. this is cut/paste from that code.
+- */
+- for (id = whitelist_table; id->match_flags; id++) {
+- if ((id->match_flags & USB_DEVICE_ID_MATCH_VENDOR) &&
+- id->idVendor != le16_to_cpu(dev->descriptor.idVendor))
+- continue;
+-
+- if ((id->match_flags & USB_DEVICE_ID_MATCH_PRODUCT) &&
+- id->idProduct != le16_to_cpu(dev->descriptor.idProduct))
+- continue;
+-
+- /* No need to test id->bcdDevice_lo != 0, since 0 is never
+- greater than any unsigned number. */
+- if ((id->match_flags & USB_DEVICE_ID_MATCH_DEV_LO) &&
+- (id->bcdDevice_lo > le16_to_cpu(dev->descriptor.bcdDevice)))
+- continue;
+-
+- if ((id->match_flags & USB_DEVICE_ID_MATCH_DEV_HI) &&
+- (id->bcdDevice_hi < le16_to_cpu(dev->descriptor.bcdDevice)))
+- continue;
+-
+- if ((id->match_flags & USB_DEVICE_ID_MATCH_DEV_CLASS) &&
+- (id->bDeviceClass != dev->descriptor.bDeviceClass))
+- continue;
+-
+- if ((id->match_flags & USB_DEVICE_ID_MATCH_DEV_SUBCLASS) &&
+- (id->bDeviceSubClass != dev->descriptor.bDeviceSubClass))
+- continue;
+-
+- if ((id->match_flags & USB_DEVICE_ID_MATCH_DEV_PROTOCOL) &&
+- (id->bDeviceProtocol != dev->descriptor.bDeviceProtocol))
+- continue;
+#ifdef DEBUG
+ dev_dbg(&dev->dev, "device V:%04x P:%04x DC:%04x SC:%04x PR:%04x \n",
+ dev->descriptor.idVendor,
+ dev->descriptor.bDeviceProtocol);
+#endif
-- /* NOTE: can't use usb_match_id() since interface caches
-- * aren't set up yet. this is cut/paste from that code.
-- */
-- for (id = whitelist_table; id->match_flags; id++) {
-- if ((id->match_flags & USB_DEVICE_ID_MATCH_VENDOR) &&
-- id->idVendor != le16_to_cpu(dev->descriptor.idVendor))
-- continue;
-+ return 1;
+ return 1;
+ /* NOTE: can't use usb_match_id() since interface caches
+ * aren't set up yet. this is cut/paste from that code.
+ */
+ id->bDeviceSubClass,
+ id->bDeviceProtocol);
+#endif
-
-- if ((id->match_flags & USB_DEVICE_ID_MATCH_PRODUCT) &&
-- id->idProduct != le16_to_cpu(dev->descriptor.idProduct))
-- continue;
++
+ if ((id->match_flags & USB_DEVICE_ID_MATCH_VENDOR) &&
+ id->idVendor != le16_to_cpu(dev->descriptor.idVendor))
+ continue;
-
-- /* No need to test id->bcdDevice_lo != 0, since 0 is never
-- greater than any unsigned number. */
-- if ((id->match_flags & USB_DEVICE_ID_MATCH_DEV_LO) &&
-- (id->bcdDevice_lo > le16_to_cpu(dev->descriptor.bcdDevice)))
-- continue;
++
+ if ((id->match_flags & USB_DEVICE_ID_MATCH_PRODUCT) &&
+ id->idProduct != le16_to_cpu(dev->descriptor.idProduct))
+ continue;
-
-- if ((id->match_flags & USB_DEVICE_ID_MATCH_DEV_HI) &&
-- (id->bcdDevice_hi < le16_to_cpu(dev->descriptor.bcdDevice)))
-- continue;
++
+ /* No need to test id->bcdDevice_lo != 0, since 0 is never
+ greater than any unsigned number. */
+ if ((id->match_flags & USB_DEVICE_ID_MATCH_DEV_LO) &&
+ (id->bcdDevice_lo > le16_to_cpu(dev->descriptor.bcdDevice)))
+ continue;
-
-- if ((id->match_flags & USB_DEVICE_ID_MATCH_DEV_CLASS) &&
-- (id->bDeviceClass != dev->descriptor.bDeviceClass))
-- continue;
++
+ if ((id->match_flags & USB_DEVICE_ID_MATCH_DEV_HI) &&
+ (id->bcdDevice_hi < le16_to_cpu(dev->descriptor.bcdDevice)))
+ continue;
-
-- if ((id->match_flags & USB_DEVICE_ID_MATCH_DEV_SUBCLASS) &&
-- (id->bDeviceSubClass != dev->descriptor.bDeviceSubClass))
-- continue;
++
+ if ((id->match_flags & USB_DEVICE_ID_MATCH_DEV_CLASS) &&
+ (id->bDeviceClass != dev->descriptor.bDeviceClass))
+ continue;
-
-- if ((id->match_flags & USB_DEVICE_ID_MATCH_DEV_PROTOCOL) &&
-- (id->bDeviceProtocol != dev->descriptor.bDeviceProtocol))
-- continue;
++
+ if ((id->match_flags & USB_DEVICE_ID_MATCH_DEV_SUBCLASS) &&
+ (id->bDeviceSubClass != dev->descriptor.bDeviceSubClass))
+ continue;
-
-- return 1;
++
+ if ((id->match_flags & USB_DEVICE_ID_MATCH_DEV_PROTOCOL) &&
+ (id->bDeviceProtocol != dev->descriptor.bDeviceProtocol))
+ continue;
#endif
}
-diff --git a/drivers/usb/gadget/file_storage.c b/drivers/usb/gadget/file_storage.c
-new file mode 100644
-index 0000000..a896d73
--- /dev/null
+++ b/drivers/usb/gadget/file_storage.c
@@ -0,0 +1,3676 @@
+ kref_put(&fsg->ref, fsg_release);
+}
+module_exit(fsg_cleanup);
-diff --git a/drivers/usb/host/Kconfig b/drivers/usb/host/Kconfig
-index a9707da..e252b95 100644
--- a/drivers/usb/host/Kconfig
+++ b/drivers/usb/host/Kconfig
@@ -689,6 +689,19 @@ config USB_HWA_HCD
config USB_IMX21_HCD
tristate "i.MX21 HCD support"
depends on ARM && ARCH_MXC
-diff --git a/drivers/usb/host/Makefile b/drivers/usb/host/Makefile
-index 7530468..876f024 100644
--- a/drivers/usb/host/Makefile
+++ b/drivers/usb/host/Makefile
@@ -63,6 +63,8 @@ obj-$(CONFIG_USB_U132_HCD) += u132-hcd.o
obj-$(CONFIG_USB_IMX21_HCD) += imx21-hcd.o
obj-$(CONFIG_USB_FSL_MPH_DR_OF) += fsl-mph-dr-of.o
obj-$(CONFIG_USB_OCTEON2_COMMON) += octeon2-common.o
-diff --git a/drivers/usb/host/dwc_common_port/Makefile b/drivers/usb/host/dwc_common_port/Makefile
-new file mode 100644
-index 0000000..f10d466
--- /dev/null
+++ b/drivers/usb/host/dwc_common_port/Makefile
@@ -0,0 +1,58 @@
+
+clean:
+ rm -rf *.o *.ko .*.cmd *.mod.c .*.o.d .*.o.tmp modules.order Module.markers Module.symvers .tmp_versions/
-diff --git a/drivers/usb/host/dwc_common_port/Makefile.fbsd b/drivers/usb/host/dwc_common_port/Makefile.fbsd
-new file mode 100644
-index 0000000..45db991
--- /dev/null
+++ b/drivers/usb/host/dwc_common_port/Makefile.fbsd
@@ -0,0 +1,17 @@
+ dwc_common_fbsd.c dwc_mem.c
+
+.include <bsd.kmod.mk>
-diff --git a/drivers/usb/host/dwc_common_port/Makefile.linux b/drivers/usb/host/dwc_common_port/Makefile.linux
-new file mode 100644
-index 0000000..0cef7b4
--- /dev/null
+++ b/drivers/usb/host/dwc_common_port/Makefile.linux
@@ -0,0 +1,49 @@
+
+clean:
+ rm -rf *.o *.ko .*.cmd *.mod.c .*.o.d .*.o.tmp modules.order Module.markers Module.symvers .tmp_versions/
-diff --git a/drivers/usb/host/dwc_common_port/changes.txt b/drivers/usb/host/dwc_common_port/changes.txt
-new file mode 100644
-index 0000000..f6839f9
--- /dev/null
+++ b/drivers/usb/host/dwc_common_port/changes.txt
@@ -0,0 +1,174 @@
+A DWC_LIBMODULE #define has also been added. If this is not defined, then the
+module code in dwc_common_linux.c is not compiled in. This allows linking the
+library code directly into a driver module, instead of as a standalone module.
-diff --git a/drivers/usb/host/dwc_common_port/doc/doxygen.cfg b/drivers/usb/host/dwc_common_port/doc/doxygen.cfg
-new file mode 100644
-index 0000000..89aa887
--- /dev/null
+++ b/drivers/usb/host/dwc_common_port/doc/doxygen.cfg
@@ -0,0 +1,270 @@
+# Configuration::additions related to the search engine
+#---------------------------------------------------------------------------
+SEARCHENGINE = NO
-diff --git a/drivers/usb/host/dwc_common_port/dwc_cc.c b/drivers/usb/host/dwc_common_port/dwc_cc.c
-new file mode 100644
-index 0000000..5ec2ae2
--- /dev/null
+++ b/drivers/usb/host/dwc_common_port/dwc_cc.c
@@ -0,0 +1,532 @@
+}
+
+#endif /* DWC_CCLIB */
-diff --git a/drivers/usb/host/dwc_common_port/dwc_cc.h b/drivers/usb/host/dwc_common_port/dwc_cc.h
-new file mode 100644
-index 0000000..f86e6f2
--- /dev/null
+++ b/drivers/usb/host/dwc_common_port/dwc_cc.h
@@ -0,0 +1,224 @@
+#endif
+
+#endif /* _DWC_CC_H_ */
-diff --git a/drivers/usb/host/dwc_common_port/dwc_common_fbsd.c b/drivers/usb/host/dwc_common_port/dwc_common_fbsd.c
-new file mode 100644
-index 0000000..6dd04b5
--- /dev/null
+++ b/drivers/usb/host/dwc_common_port/dwc_common_fbsd.c
@@ -0,0 +1,1308 @@
+{
+ return wq->pending;
+}
-diff --git a/drivers/usb/host/dwc_common_port/dwc_common_linux.c b/drivers/usb/host/dwc_common_port/dwc_common_linux.c
-new file mode 100644
-index 0000000..440bcfc
--- /dev/null
+++ b/drivers/usb/host/dwc_common_port/dwc_common_linux.c
@@ -0,0 +1,1421 @@
+MODULE_LICENSE ("GPL");
+
+#endif /* DWC_LIBMODULE */
-diff --git a/drivers/usb/host/dwc_common_port/dwc_common_nbsd.c b/drivers/usb/host/dwc_common_port/dwc_common_nbsd.c
-new file mode 100644
-index 0000000..49b07e1
--- /dev/null
+++ b/drivers/usb/host/dwc_common_port/dwc_common_nbsd.c
@@ -0,0 +1,1275 @@
+{
+ return wq->pending;
+}
-diff --git a/drivers/usb/host/dwc_common_port/dwc_crypto.c b/drivers/usb/host/dwc_common_port/dwc_crypto.c
-new file mode 100644
-index 0000000..3b03532
--- /dev/null
+++ b/drivers/usb/host/dwc_common_port/dwc_crypto.c
@@ -0,0 +1,308 @@
+}
+
+#endif /* DWC_CRYPTOLIB */
-diff --git a/drivers/usb/host/dwc_common_port/dwc_crypto.h b/drivers/usb/host/dwc_common_port/dwc_crypto.h
-new file mode 100644
-index 0000000..26fcddc
--- /dev/null
+++ b/drivers/usb/host/dwc_common_port/dwc_crypto.h
@@ -0,0 +1,111 @@
+#endif
+
+#endif /* _DWC_CRYPTO_H_ */
-diff --git a/drivers/usb/host/dwc_common_port/dwc_dh.c b/drivers/usb/host/dwc_common_port/dwc_dh.c
-new file mode 100644
-index 0000000..2b429a3
--- /dev/null
+++ b/drivers/usb/host/dwc_common_port/dwc_dh.c
@@ -0,0 +1,291 @@
+#endif /* !CONFIG_MACH_IPMATE */
+
+#endif /* DWC_CRYPTOLIB */
-diff --git a/drivers/usb/host/dwc_common_port/dwc_dh.h b/drivers/usb/host/dwc_common_port/dwc_dh.h
-new file mode 100644
-index 0000000..25c1cc0
--- /dev/null
+++ b/drivers/usb/host/dwc_common_port/dwc_dh.h
@@ -0,0 +1,106 @@
+#endif
+
+#endif /* _DWC_DH_H_ */
-diff --git a/drivers/usb/host/dwc_common_port/dwc_list.h b/drivers/usb/host/dwc_common_port/dwc_list.h
-new file mode 100644
-index 0000000..89cc325
--- /dev/null
+++ b/drivers/usb/host/dwc_common_port/dwc_list.h
@@ -0,0 +1,594 @@
+#endif
+
+#endif /* _DWC_LIST_H_ */
-diff --git a/drivers/usb/host/dwc_common_port/dwc_mem.c b/drivers/usb/host/dwc_common_port/dwc_mem.c
-new file mode 100644
-index 0000000..ad645ff
--- /dev/null
+++ b/drivers/usb/host/dwc_common_port/dwc_mem.c
@@ -0,0 +1,245 @@
+}
+
+#endif /* DWC_DEBUG_MEMORY */
-diff --git a/drivers/usb/host/dwc_common_port/dwc_modpow.c b/drivers/usb/host/dwc_common_port/dwc_modpow.c
-new file mode 100644
-index 0000000..2004538
--- /dev/null
+++ b/drivers/usb/host/dwc_common_port/dwc_modpow.c
@@ -0,0 +1,636 @@
+#endif /* CONFIG_MACH_IPMATE */
+
+#endif /*DWC_CRYPTOLIB */
-diff --git a/drivers/usb/host/dwc_common_port/dwc_modpow.h b/drivers/usb/host/dwc_common_port/dwc_modpow.h
-new file mode 100644
-index 0000000..64f00c2
--- /dev/null
+++ b/drivers/usb/host/dwc_common_port/dwc_modpow.h
@@ -0,0 +1,34 @@
+#endif
+
+#endif /* _LINUX_BIGNUM_H */
-diff --git a/drivers/usb/host/dwc_common_port/dwc_notifier.c b/drivers/usb/host/dwc_common_port/dwc_notifier.c
-new file mode 100644
-index 0000000..8b3772a
--- /dev/null
+++ b/drivers/usb/host/dwc_common_port/dwc_notifier.c
@@ -0,0 +1,319 @@
+}
+
+#endif /* DWC_NOTIFYLIB */
-diff --git a/drivers/usb/host/dwc_common_port/dwc_notifier.h b/drivers/usb/host/dwc_common_port/dwc_notifier.h
-new file mode 100644
-index 0000000..4a8cdfe
--- /dev/null
+++ b/drivers/usb/host/dwc_common_port/dwc_notifier.h
@@ -0,0 +1,122 @@
+#endif
+
+#endif /* __DWC_NOTIFIER_H__ */
-diff --git a/drivers/usb/host/dwc_common_port/dwc_os.h b/drivers/usb/host/dwc_common_port/dwc_os.h
-new file mode 100644
-index 0000000..9ffe929
--- /dev/null
+++ b/drivers/usb/host/dwc_common_port/dwc_os.h
@@ -0,0 +1,1260 @@
+#endif
+
+#endif /* _DWC_OS_H_ */
-diff --git a/drivers/usb/host/dwc_common_port/usb.h b/drivers/usb/host/dwc_common_port/usb.h
-new file mode 100644
-index 0000000..27bda82
--- /dev/null
+++ b/drivers/usb/host/dwc_common_port/usb.h
@@ -0,0 +1,946 @@
+#endif
+
+#endif /* _USB_H_ */
-diff --git a/drivers/usb/host/dwc_otg/Makefile b/drivers/usb/host/dwc_otg/Makefile
-new file mode 100644
-index 0000000..236c47c
--- /dev/null
+++ b/drivers/usb/host/dwc_otg/Makefile
@@ -0,0 +1,80 @@
+ rm -rf *.o *.ko .*cmd *.mod.c .tmp_versions Module.symvers
+
+endif
-diff --git a/drivers/usb/host/dwc_otg/doc/doxygen.cfg b/drivers/usb/host/dwc_otg/doc/doxygen.cfg
-new file mode 100644
-index 0000000..712b057
--- /dev/null
+++ b/drivers/usb/host/dwc_otg/doc/doxygen.cfg
@@ -0,0 +1,224 @@
+# Configuration::additions related to the search engine
+#---------------------------------------------------------------------------
+SEARCHENGINE = NO
-diff --git a/drivers/usb/host/dwc_otg/dummy_audio.c b/drivers/usb/host/dwc_otg/dummy_audio.c
-new file mode 100644
-index 0000000..225decf
--- /dev/null
+++ b/drivers/usb/host/dwc_otg/dummy_audio.c
@@ -0,0 +1,1575 @@
+ remove_proc_entry("isoc_test", NULL);
+}
+module_exit (cleanup);
-diff --git a/drivers/usb/host/dwc_otg/dwc_cfi_common.h b/drivers/usb/host/dwc_otg/dwc_cfi_common.h
-new file mode 100644
-index 0000000..7770e20
--- /dev/null
+++ b/drivers/usb/host/dwc_otg/dwc_cfi_common.h
@@ -0,0 +1,142 @@
+typedef struct cfi_string cfi_string_t;
+
+#endif
-diff --git a/drivers/usb/host/dwc_otg/dwc_otg_adp.c b/drivers/usb/host/dwc_otg/dwc_otg_adp.c
-new file mode 100644
-index 0000000..ce0618d
--- /dev/null
+++ b/drivers/usb/host/dwc_otg/dwc_otg_adp.c
@@ -0,0 +1,854 @@
+#endif
+ return 1;
+}
-diff --git a/drivers/usb/host/dwc_otg/dwc_otg_adp.h b/drivers/usb/host/dwc_otg/dwc_otg_adp.h
-new file mode 100644
-index 0000000..4110b25
--- /dev/null
+++ b/drivers/usb/host/dwc_otg/dwc_otg_adp.h
@@ -0,0 +1,80 @@
+extern int32_t dwc_otg_adp_handle_srp_intr(dwc_otg_core_if_t * core_if);
+
+#endif //__DWC_OTG_ADP_H__
-diff --git a/drivers/usb/host/dwc_otg/dwc_otg_attr.c b/drivers/usb/host/dwc_otg/dwc_otg_attr.c
-new file mode 100644
-index 0000000..fab2961
--- /dev/null
+++ b/drivers/usb/host/dwc_otg/dwc_otg_attr.c
@@ -0,0 +1,1210 @@
+ device_remove_file(&dev->dev, &dev_attr_sleep_status);
+#endif
+}
-diff --git a/drivers/usb/host/dwc_otg/dwc_otg_attr.h b/drivers/usb/host/dwc_otg/dwc_otg_attr.h
-new file mode 100644
-index 0000000..e10b67f
--- /dev/null
+++ b/drivers/usb/host/dwc_otg/dwc_otg_attr.h
@@ -0,0 +1,89 @@
+#endif
+ );
+#endif
-diff --git a/drivers/usb/host/dwc_otg/dwc_otg_cfi.c b/drivers/usb/host/dwc_otg/dwc_otg_cfi.c
-new file mode 100644
-index 0000000..bbb3d32
--- /dev/null
+++ b/drivers/usb/host/dwc_otg/dwc_otg_cfi.c
@@ -0,0 +1,1876 @@
+}
+
+#endif //DWC_UTE_CFI
-diff --git a/drivers/usb/host/dwc_otg/dwc_otg_cfi.h b/drivers/usb/host/dwc_otg/dwc_otg_cfi.h
-new file mode 100644
-index 0000000..55fd337
--- /dev/null
+++ b/drivers/usb/host/dwc_otg/dwc_otg_cfi.h
@@ -0,0 +1,320 @@
+int cfi_setup(struct dwc_otg_pcd *pcd, struct cfi_usb_ctrlrequest *ctrl);
+
+#endif /* (__DWC_OTG_CFI_H__) */
-diff --git a/drivers/usb/host/dwc_otg/dwc_otg_cil.c b/drivers/usb/host/dwc_otg/dwc_otg_cil.c
-new file mode 100644
-index 0000000..6a32c5c
--- /dev/null
+++ b/drivers/usb/host/dwc_otg/dwc_otg_cil.c
@@ -0,0 +1,7151 @@
+ dwc_otg_pcd_start_srp_timer(core_if);
+ return;
+}
-diff --git a/drivers/usb/host/dwc_otg/dwc_otg_cil.h b/drivers/usb/host/dwc_otg/dwc_otg_cil.h
-new file mode 100644
-index 0000000..79dbf83
--- /dev/null
+++ b/drivers/usb/host/dwc_otg/dwc_otg_cil.h
@@ -0,0 +1,1464 @@
+//////////////////////////////////////////////////////////////////////
+
+#endif
-diff --git a/drivers/usb/host/dwc_otg/dwc_otg_cil_intr.c b/drivers/usb/host/dwc_otg/dwc_otg_cil_intr.c
-new file mode 100644
-index 0000000..59fc862
--- /dev/null
+++ b/drivers/usb/host/dwc_otg/dwc_otg_cil_intr.c
@@ -0,0 +1,1563 @@
+
+ return retval;
+}
-diff --git a/drivers/usb/host/dwc_otg/dwc_otg_core_if.h b/drivers/usb/host/dwc_otg/dwc_otg_core_if.h
-new file mode 100644
-index 0000000..4138fd1
--- /dev/null
+++ b/drivers/usb/host/dwc_otg/dwc_otg_core_if.h
@@ -0,0 +1,705 @@
+/** @} */
+
+#endif /* __DWC_CORE_IF_H__ */
-diff --git a/drivers/usb/host/dwc_otg/dwc_otg_dbg.h b/drivers/usb/host/dwc_otg/dwc_otg_dbg.h
-new file mode 100644
-index 0000000..8900318
--- /dev/null
+++ b/drivers/usb/host/dwc_otg/dwc_otg_dbg.h
@@ -0,0 +1,116 @@
+
+#endif /*DEBUG*/
+#endif
-diff --git a/drivers/usb/host/dwc_otg/dwc_otg_driver.c b/drivers/usb/host/dwc_otg/dwc_otg_driver.c
-new file mode 100644
-index 0000000..ac2c846
--- /dev/null
+++ b/drivers/usb/host/dwc_otg/dwc_otg_driver.c
@@ -0,0 +1,1700 @@
+ </td></tr>
+
+*/
-diff --git a/drivers/usb/host/dwc_otg/dwc_otg_driver.h b/drivers/usb/host/dwc_otg/dwc_otg_driver.h
-new file mode 100644
-index 0000000..6a8be63
--- /dev/null
+++ b/drivers/usb/host/dwc_otg/dwc_otg_driver.h
@@ -0,0 +1,86 @@
+#endif
+
+#endif
-diff --git a/drivers/usb/host/dwc_otg/dwc_otg_hcd.c b/drivers/usb/host/dwc_otg/dwc_otg_hcd.c
-new file mode 100644
-index 0000000..ab935c0
--- /dev/null
+++ b/drivers/usb/host/dwc_otg/dwc_otg_hcd.c
@@ -0,0 +1,3473 @@
+}
+
+#endif /* DWC_DEVICE_ONLY */
-diff --git a/drivers/usb/host/dwc_otg/dwc_otg_hcd.h b/drivers/usb/host/dwc_otg/dwc_otg_hcd.h
-new file mode 100644
-index 0000000..bb4f67a
--- /dev/null
+++ b/drivers/usb/host/dwc_otg/dwc_otg_hcd.h
@@ -0,0 +1,824 @@
+#endif
+#endif
+#endif /* DWC_DEVICE_ONLY */
-diff --git a/drivers/usb/host/dwc_otg/dwc_otg_hcd_ddma.c b/drivers/usb/host/dwc_otg/dwc_otg_hcd_ddma.c
-new file mode 100644
-index 0000000..274967b
--- /dev/null
+++ b/drivers/usb/host/dwc_otg/dwc_otg_hcd_ddma.c
@@ -0,0 +1,1133 @@
+}
+
+#endif /* DWC_DEVICE_ONLY */
-diff --git a/drivers/usb/host/dwc_otg/dwc_otg_hcd_if.h b/drivers/usb/host/dwc_otg/dwc_otg_hcd_if.h
-new file mode 100644
-index 0000000..4823167
--- /dev/null
+++ b/drivers/usb/host/dwc_otg/dwc_otg_hcd_if.h
@@ -0,0 +1,412 @@
+
+#endif /* __DWC_HCD_IF_H__ */
+#endif /* DWC_DEVICE_ONLY */
-diff --git a/drivers/usb/host/dwc_otg/dwc_otg_hcd_intr.c b/drivers/usb/host/dwc_otg/dwc_otg_hcd_intr.c
-new file mode 100644
-index 0000000..b41e164
--- /dev/null
+++ b/drivers/usb/host/dwc_otg/dwc_otg_hcd_intr.c
@@ -0,0 +1,2106 @@
+}
+
+#endif /* DWC_DEVICE_ONLY */
-diff --git a/drivers/usb/host/dwc_otg/dwc_otg_hcd_linux.c b/drivers/usb/host/dwc_otg/dwc_otg_hcd_linux.c
-new file mode 100644
-index 0000000..e4787f5
--- /dev/null
+++ b/drivers/usb/host/dwc_otg/dwc_otg_hcd_linux.c
@@ -0,0 +1,893 @@
+}
+
+#endif /* DWC_DEVICE_ONLY */
-diff --git a/drivers/usb/host/dwc_otg/dwc_otg_hcd_queue.c b/drivers/usb/host/dwc_otg/dwc_otg_hcd_queue.c
-new file mode 100644
-index 0000000..9761566
--- /dev/null
+++ b/drivers/usb/host/dwc_otg/dwc_otg_hcd_queue.c
@@ -0,0 +1,922 @@
+}
+
+#endif /* DWC_DEVICE_ONLY */
-diff --git a/drivers/usb/host/dwc_otg/dwc_otg_os_dep.h b/drivers/usb/host/dwc_otg/dwc_otg_os_dep.h
-new file mode 100644
-index 0000000..e46d9bb
--- /dev/null
+++ b/drivers/usb/host/dwc_otg/dwc_otg_os_dep.h
@@ -0,0 +1,185 @@
+
+
+#endif /* _DWC_OS_DEP_H_ */
-diff --git a/drivers/usb/host/dwc_otg/dwc_otg_pcd.c b/drivers/usb/host/dwc_otg/dwc_otg_pcd.c
-new file mode 100644
-index 0000000..40fb25c
--- /dev/null
+++ b/drivers/usb/host/dwc_otg/dwc_otg_pcd.c
@@ -0,0 +1,2708 @@
+}
+
+#endif /* DWC_HOST_ONLY */
-diff --git a/drivers/usb/host/dwc_otg/dwc_otg_pcd.h b/drivers/usb/host/dwc_otg/dwc_otg_pcd.h
-new file mode 100644
-index 0000000..8ef7ba6
--- /dev/null
+++ b/drivers/usb/host/dwc_otg/dwc_otg_pcd.h
@@ -0,0 +1,266 @@
+extern void do_test_mode(void *data);
+#endif
+#endif /* DWC_HOST_ONLY */
-diff --git a/drivers/usb/host/dwc_otg/dwc_otg_pcd_if.h b/drivers/usb/host/dwc_otg/dwc_otg_pcd_if.h
-new file mode 100644
-index 0000000..c8d2e0e
--- /dev/null
+++ b/drivers/usb/host/dwc_otg/dwc_otg_pcd_if.h
@@ -0,0 +1,360 @@
+#endif /* __DWC_PCD_IF_H__ */
+
+#endif /* DWC_HOST_ONLY */
-diff --git a/drivers/usb/host/dwc_otg/dwc_otg_pcd_intr.c b/drivers/usb/host/dwc_otg/dwc_otg_pcd_intr.c
-new file mode 100644
-index 0000000..1b1f83c
--- /dev/null
+++ b/drivers/usb/host/dwc_otg/dwc_otg_pcd_intr.c
@@ -0,0 +1,5147 @@
+}
+
+#endif /* DWC_HOST_ONLY */
-diff --git a/drivers/usb/host/dwc_otg/dwc_otg_pcd_linux.c b/drivers/usb/host/dwc_otg/dwc_otg_pcd_linux.c
-new file mode 100644
-index 0000000..5d310df
--- /dev/null
+++ b/drivers/usb/host/dwc_otg/dwc_otg_pcd_linux.c
@@ -0,0 +1,1358 @@
+EXPORT_SYMBOL(usb_gadget_unregister_driver);
+
+#endif /* DWC_HOST_ONLY */
-diff --git a/drivers/usb/host/dwc_otg/dwc_otg_regs.h b/drivers/usb/host/dwc_otg/dwc_otg_regs.h
-new file mode 100644
-index 0000000..8e0e7b5
--- /dev/null
+++ b/drivers/usb/host/dwc_otg/dwc_otg_regs.h
@@ -0,0 +1,2550 @@
+} gpwrdn_data_t;
+
+#endif
-diff --git a/drivers/usb/host/dwc_otg/test/Makefile b/drivers/usb/host/dwc_otg/test/Makefile
-new file mode 100644
-index 0000000..fc45375
--- /dev/null
+++ b/drivers/usb/host/dwc_otg/test/Makefile
@@ -0,0 +1,16 @@
+ else echo "=======> $$test, FAILED" ; \
+ fi \
+ done
-diff --git a/drivers/usb/host/dwc_otg/test/dwc_otg_test.pm b/drivers/usb/host/dwc_otg/test/dwc_otg_test.pm
-new file mode 100644
-index 0000000..85e55fd
--- /dev/null
+++ b/drivers/usb/host/dwc_otg/test/dwc_otg_test.pm
@@ -0,0 +1,337 @@
+);
+
+1;
-diff --git a/drivers/usb/host/dwc_otg/test/test_mod_param.pl b/drivers/usb/host/dwc_otg/test/test_mod_param.pl
-new file mode 100644
-index 0000000..dc3820d
--- /dev/null
+++ b/drivers/usb/host/dwc_otg/test/test_mod_param.pl
@@ -0,0 +1,133 @@
+
+test_main();
+0;
-diff --git a/drivers/usb/host/dwc_otg/test/test_sysfs.pl b/drivers/usb/host/dwc_otg/test/test_sysfs.pl
-new file mode 100644
-index 0000000..cdc9963
--- /dev/null
+++ b/drivers/usb/host/dwc_otg/test/test_sysfs.pl
@@ -0,0 +1,193 @@
+
+test_main();
+0;
---
-1.9.1
-
3 files changed, 391 insertions(+)
create mode 100644 drivers/watchdog/bcm2708_wdog.c
-diff --git a/drivers/watchdog/Kconfig b/drivers/watchdog/Kconfig
-index 79d2589..3641dbd 100644
--- a/drivers/watchdog/Kconfig
+++ b/drivers/watchdog/Kconfig
@@ -402,6 +402,12 @@ config RETU_WATCHDOG
config MOXART_WDT
tristate "MOXART watchdog"
depends on ARCH_MOXART
-diff --git a/drivers/watchdog/Makefile b/drivers/watchdog/Makefile
-index 985a66c..f68e32c 100644
--- a/drivers/watchdog/Makefile
+++ b/drivers/watchdog/Makefile
-@@ -54,6 +54,7 @@ obj-$(CONFIG_TS72XX_WATCHDOG) += ts72xx_wdt.o
+@@ -54,6 +54,7 @@ obj-$(CONFIG_TS72XX_WATCHDOG) += ts72xx_
obj-$(CONFIG_IMX2_WDT) += imx2_wdt.o
obj-$(CONFIG_UX500_WATCHDOG) += ux500_wdt.o
obj-$(CONFIG_RETU_WATCHDOG) += retu_wdt.o
obj-$(CONFIG_BCM2835_WDT) += bcm2835_wdt.o
obj-$(CONFIG_MOXART_WDT) += moxart_wdt.o
obj-$(CONFIG_SIRFSOC_WATCHDOG) += sirfsoc_wdt.o
-diff --git a/drivers/watchdog/bcm2708_wdog.c b/drivers/watchdog/bcm2708_wdog.c
-new file mode 100644
-index 0000000..2f19203
--- /dev/null
+++ b/drivers/watchdog/bcm2708_wdog.c
@@ -0,0 +1,384 @@
+MODULE_ALIAS_MISCDEV(WATCHDOG_MINOR);
+MODULE_ALIAS_MISCDEV(TEMP_MINOR);
+MODULE_LICENSE("GPL");
---
-1.9.1
-
4 files changed, 1395 insertions(+), 1602 deletions(-)
create mode 100644 drivers/video/bcm2708_fb.c
-diff --git a/drivers/video/Kconfig b/drivers/video/Kconfig
-index dade5b7..4afc29b 100644
--- a/drivers/video/Kconfig
+++ b/drivers/video/Kconfig
@@ -310,6 +310,20 @@ config FB_PM2_FIFO_DISCONNECT
config FB_ARMCLCD
tristate "ARM PrimeCell PL110 support"
depends on ARM || ARM64 || COMPILE_TEST
-diff --git a/drivers/video/Makefile b/drivers/video/Makefile
-index ae17ddf..35654ba 100644
--- a/drivers/video/Makefile
+++ b/drivers/video/Makefile
-@@ -100,6 +100,7 @@ obj-$(CONFIG_FB_PVR2) += pvr2fb.o
+@@ -100,6 +100,7 @@ obj-$(CONFIG_FB_PVR2) += pvr
obj-$(CONFIG_FB_VOODOO1) += sstfb.o
obj-$(CONFIG_FB_ARMCLCD) += amba-clcd.o
obj-$(CONFIG_FB_GOLDFISH) += goldfishfb.o
obj-$(CONFIG_FB_68328) += 68328fb.o
obj-$(CONFIG_FB_GBE) += gbefb.o
obj-$(CONFIG_FB_CIRRUS) += cirrusfb.o
-diff --git a/drivers/video/bcm2708_fb.c b/drivers/video/bcm2708_fb.c
-new file mode 100644
-index 0000000..54cd760
--- /dev/null
+++ b/drivers/video/bcm2708_fb.c
@@ -0,0 +1,499 @@
+MODULE_PARM_DESC(fbheight, "Height of ARM Framebuffer");
+MODULE_PARM_DESC(fbdepth, "Bit depth of ARM Framebuffer");
+MODULE_PARM_DESC(fbswap, "Swap order of red and blue in 24 and 32 bit modes");
-diff --git a/drivers/video/logo/logo_linux_clut224.ppm b/drivers/video/logo/logo_linux_clut224.ppm
-index 3c14e43..7626beb 100644
--- a/drivers/video/logo/logo_linux_clut224.ppm
+++ b/drivers/video/logo/logo_linux_clut224.ppm
@@ -1,1604 +1,883 @@
+0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
+0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
+0 0 0 0 0 0 0 0 0
---
-1.9.1
-
create mode 100644 drivers/misc/vc04_services/interface/vchiq_arm/vchiq_util.h
create mode 100644 drivers/misc/vc04_services/interface/vchiq_arm/vchiq_version.c
-diff --git a/drivers/misc/Kconfig b/drivers/misc/Kconfig
-index 6cb388e..56867fa 100644
--- a/drivers/misc/Kconfig
+++ b/drivers/misc/Kconfig
@@ -524,6 +524,7 @@ source "drivers/misc/carma/Kconfig"
source "drivers/misc/mic/Kconfig"
source "drivers/misc/genwqe/Kconfig"
endmenu
-diff --git a/drivers/misc/Makefile b/drivers/misc/Makefile
-index 99b9424..ad85616 100644
--- a/drivers/misc/Makefile
+++ b/drivers/misc/Makefile
@@ -52,5 +52,6 @@ obj-$(CONFIG_INTEL_MEI) += mei/
+obj-y += vc04_services/
obj-y += mic/
obj-$(CONFIG_GENWQE) += genwqe/
-diff --git a/drivers/misc/vc04_services/Kconfig b/drivers/misc/vc04_services/Kconfig
-new file mode 100644
-index 0000000..2663933
--- /dev/null
+++ b/drivers/misc/vc04_services/Kconfig
@@ -0,0 +1,9 @@
+ BCM2708 family of products.
+ Defaults to Y when the Broadcom Videocore services
+ are included in the build, N otherwise.
-diff --git a/drivers/misc/vc04_services/Makefile b/drivers/misc/vc04_services/Makefile
-new file mode 100644
-index 0000000..4224f58
--- /dev/null
+++ b/drivers/misc/vc04_services/Makefile
@@ -0,0 +1,17 @@
+ccflags-y += -DVCOS_VERIFY_BKPTS=1 -Idrivers/misc/vc04_services -DUSE_VCHIQ_ARM -D__VCCOREVER__=0x04000000
+
+endif
-diff --git a/drivers/misc/vc04_services/interface/vchi/connections/connection.h b/drivers/misc/vc04_services/interface/vchi/connections/connection.h
-new file mode 100644
-index 0000000..fef6ac3
--- /dev/null
+++ b/drivers/misc/vc04_services/interface/vchi/connections/connection.h
@@ -0,0 +1,328 @@
+#endif /* CONNECTION_H_ */
+
+/****************************** End of file **********************************/
-diff --git a/drivers/misc/vc04_services/interface/vchi/message_drivers/message.h b/drivers/misc/vc04_services/interface/vchi/message_drivers/message.h
-new file mode 100644
-index 0000000..8b3f767
--- /dev/null
+++ b/drivers/misc/vc04_services/interface/vchi/message_drivers/message.h
@@ -0,0 +1,204 @@
+#endif // _VCHI_MESSAGE_H_
+
+/****************************** End of file ***********************************/
-diff --git a/drivers/misc/vc04_services/interface/vchi/vchi.h b/drivers/misc/vc04_services/interface/vchi/vchi.h
-new file mode 100644
-index 0000000..cee5291
--- /dev/null
+++ b/drivers/misc/vc04_services/interface/vchi/vchi.h
@@ -0,0 +1,373 @@
+#endif /* VCHI_H_ */
+
+/****************************** End of file **********************************/
-diff --git a/drivers/misc/vc04_services/interface/vchi/vchi_cfg.h b/drivers/misc/vc04_services/interface/vchi/vchi_cfg.h
-new file mode 100644
-index 0000000..26bc2d3
--- /dev/null
+++ b/drivers/misc/vc04_services/interface/vchi/vchi_cfg.h
@@ -0,0 +1,224 @@
+#endif /* VCHI_CFG_H_ */
+
+/****************************** End of file **********************************/
-diff --git a/drivers/misc/vc04_services/interface/vchi/vchi_cfg_internal.h b/drivers/misc/vc04_services/interface/vchi/vchi_cfg_internal.h
-new file mode 100644
-index 0000000..35dcba4
--- /dev/null
+++ b/drivers/misc/vc04_services/interface/vchi/vchi_cfg_internal.h
@@ -0,0 +1,71 @@
+//#define VCHI_RX_NANOLOCKS
+
+#endif /*VCHI_CFG_INTERNAL_H_*/
-diff --git a/drivers/misc/vc04_services/interface/vchi/vchi_common.h b/drivers/misc/vc04_services/interface/vchi/vchi_common.h
-new file mode 100644
-index 0000000..9e6c00e
--- /dev/null
+++ b/drivers/misc/vc04_services/interface/vchi/vchi_common.h
@@ -0,0 +1,163 @@
+
+
+#endif // VCHI_COMMON_H_
-diff --git a/drivers/misc/vc04_services/interface/vchi/vchi_mh.h b/drivers/misc/vc04_services/interface/vchi/vchi_mh.h
-new file mode 100644
-index 0000000..198bd07
--- /dev/null
+++ b/drivers/misc/vc04_services/interface/vchi/vchi_mh.h
@@ -0,0 +1,42 @@
+#define VCHI_MEM_HANDLE_INVALID 0
+
+#endif
-diff --git a/drivers/misc/vc04_services/interface/vchiq_arm/vchiq.h b/drivers/misc/vc04_services/interface/vchiq_arm/vchiq.h
-new file mode 100644
-index 0000000..ad398ba
--- /dev/null
+++ b/drivers/misc/vc04_services/interface/vchiq_arm/vchiq.h
@@ -0,0 +1,40 @@
+#include "vchiq_util.h"
+
+#endif
-diff --git a/drivers/misc/vc04_services/interface/vchiq_arm/vchiq_2835.h b/drivers/misc/vc04_services/interface/vchiq_arm/vchiq_2835.h
-new file mode 100644
-index 0000000..7ea5c64
--- /dev/null
+++ b/drivers/misc/vc04_services/interface/vchiq_arm/vchiq_2835.h
@@ -0,0 +1,42 @@
+#define VCHIQ_PLATFORM_FRAGMENTS_COUNT_IDX 1
+
+#endif /* VCHIQ_2835_H */
-diff --git a/drivers/misc/vc04_services/interface/vchiq_arm/vchiq_2835_arm.c b/drivers/misc/vc04_services/interface/vchiq_arm/vchiq_2835_arm.c
-new file mode 100644
-index 0000000..b3bdaa2
--- /dev/null
+++ b/drivers/misc/vc04_services/interface/vchiq_arm/vchiq_2835_arm.c
@@ -0,0 +1,561 @@
+
+ kfree(pagelist);
+}
-diff --git a/drivers/misc/vc04_services/interface/vchiq_arm/vchiq_arm.c b/drivers/misc/vc04_services/interface/vchiq_arm/vchiq_arm.c
-new file mode 100644
-index 0000000..c1fb8c3
--- /dev/null
+++ b/drivers/misc/vc04_services/interface/vchiq_arm/vchiq_arm.c
@@ -0,0 +1,2813 @@
+module_exit(vchiq_exit);
+MODULE_LICENSE("GPL");
+MODULE_AUTHOR("Broadcom Corporation");
-diff --git a/drivers/misc/vc04_services/interface/vchiq_arm/vchiq_arm.h b/drivers/misc/vc04_services/interface/vchiq_arm/vchiq_arm.h
-new file mode 100644
-index 0000000..75ad4c6
--- /dev/null
+++ b/drivers/misc/vc04_services/interface/vchiq_arm/vchiq_arm.h
@@ -0,0 +1,212 @@
+
+
+#endif /* VCHIQ_ARM_H */
-diff --git a/drivers/misc/vc04_services/interface/vchiq_arm/vchiq_build_info.h b/drivers/misc/vc04_services/interface/vchiq_arm/vchiq_build_info.h
-new file mode 100644
-index 0000000..df64581
--- /dev/null
+++ b/drivers/misc/vc04_services/interface/vchiq_arm/vchiq_build_info.h
@@ -0,0 +1,37 @@
+const char *vchiq_get_build_version(void);
+const char *vchiq_get_build_time(void);
+const char *vchiq_get_build_date(void);
-diff --git a/drivers/misc/vc04_services/interface/vchiq_arm/vchiq_cfg.h b/drivers/misc/vc04_services/interface/vchiq_arm/vchiq_cfg.h
-new file mode 100644
-index 0000000..493c86c
--- /dev/null
+++ b/drivers/misc/vc04_services/interface/vchiq_arm/vchiq_cfg.h
@@ -0,0 +1,60 @@
+#endif
+
+#endif /* VCHIQ_CFG_H */
-diff --git a/drivers/misc/vc04_services/interface/vchiq_arm/vchiq_connected.c b/drivers/misc/vc04_services/interface/vchiq_arm/vchiq_connected.c
-new file mode 100644
-index 0000000..65f4b52
--- /dev/null
+++ b/drivers/misc/vc04_services/interface/vchiq_arm/vchiq_connected.c
@@ -0,0 +1,119 @@
+ mutex_unlock(&g_connected_mutex);
+}
+EXPORT_SYMBOL(vchiq_add_connected_callback);
-diff --git a/drivers/misc/vc04_services/interface/vchiq_arm/vchiq_connected.h b/drivers/misc/vc04_services/interface/vchiq_arm/vchiq_connected.h
-new file mode 100644
-index 0000000..863b3e3
--- /dev/null
+++ b/drivers/misc/vc04_services/interface/vchiq_arm/vchiq_connected.h
@@ -0,0 +1,50 @@
+void vchiq_call_connected_callbacks(void);
+
+#endif /* VCHIQ_CONNECTED_H */
-diff --git a/drivers/misc/vc04_services/interface/vchiq_arm/vchiq_core.c b/drivers/misc/vc04_services/interface/vchiq_arm/vchiq_core.c
-new file mode 100644
-index 0000000..f35ed4f
--- /dev/null
+++ b/drivers/misc/vc04_services/interface/vchiq_arm/vchiq_core.c
@@ -0,0 +1,3824 @@
+ numBytes = 0;
+ }
+}
-diff --git a/drivers/misc/vc04_services/interface/vchiq_arm/vchiq_core.h b/drivers/misc/vc04_services/interface/vchiq_arm/vchiq_core.h
-new file mode 100644
-index 0000000..47cdf27
--- /dev/null
+++ b/drivers/misc/vc04_services/interface/vchiq_arm/vchiq_core.h
@@ -0,0 +1,706 @@
+ size_t numBytes);
+
+#endif
-diff --git a/drivers/misc/vc04_services/interface/vchiq_arm/vchiq_genversion b/drivers/misc/vc04_services/interface/vchiq_arm/vchiq_genversion
-new file mode 100644
-index 0000000..9f5b634
--- /dev/null
+++ b/drivers/misc/vc04_services/interface/vchiq_arm/vchiq_genversion
@@ -0,0 +1,87 @@
+ return vchiq_build_time;
+}
+EOF
-diff --git a/drivers/misc/vc04_services/interface/vchiq_arm/vchiq_if.h b/drivers/misc/vc04_services/interface/vchiq_arm/vchiq_if.h
-new file mode 100644
-index 0000000..50359b0
--- /dev/null
+++ b/drivers/misc/vc04_services/interface/vchiq_arm/vchiq_if.h
@@ -0,0 +1,188 @@
+ short *peer_version);
+
+#endif /* VCHIQ_IF_H */
-diff --git a/drivers/misc/vc04_services/interface/vchiq_arm/vchiq_ioctl.h b/drivers/misc/vc04_services/interface/vchiq_arm/vchiq_ioctl.h
-new file mode 100644
-index 0000000..e248037
--- /dev/null
+++ b/drivers/misc/vc04_services/interface/vchiq_arm/vchiq_ioctl.h
@@ -0,0 +1,129 @@
+#define VCHIQ_IOC_MAX 15
+
+#endif
-diff --git a/drivers/misc/vc04_services/interface/vchiq_arm/vchiq_kern_lib.c b/drivers/misc/vc04_services/interface/vchiq_arm/vchiq_kern_lib.c
-new file mode 100644
-index 0000000..be9735f
--- /dev/null
+++ b/drivers/misc/vc04_services/interface/vchiq_arm/vchiq_kern_lib.c
@@ -0,0 +1,456 @@
+
+ return status;
+}
-diff --git a/drivers/misc/vc04_services/interface/vchiq_arm/vchiq_memdrv.h b/drivers/misc/vc04_services/interface/vchiq_arm/vchiq_memdrv.h
-new file mode 100644
-index 0000000..d02e776
--- /dev/null
+++ b/drivers/misc/vc04_services/interface/vchiq_arm/vchiq_memdrv.h
@@ -0,0 +1,71 @@
+ const VCHIQ_PLATFORM_DATA_T * platform_data);
+
+#endif
-diff --git a/drivers/misc/vc04_services/interface/vchiq_arm/vchiq_pagelist.h b/drivers/misc/vc04_services/interface/vchiq_arm/vchiq_pagelist.h
-new file mode 100644
-index 0000000..54a3ece
--- /dev/null
+++ b/drivers/misc/vc04_services/interface/vchiq_arm/vchiq_pagelist.h
@@ -0,0 +1,58 @@
+} FRAGMENTS_T;
+
+#endif /* VCHIQ_PAGELIST_H */
-diff --git a/drivers/misc/vc04_services/interface/vchiq_arm/vchiq_proc.c b/drivers/misc/vc04_services/interface/vchiq_arm/vchiq_proc.c
-new file mode 100644
-index 0000000..8e59676
--- /dev/null
+++ b/drivers/misc/vc04_services/interface/vchiq_arm/vchiq_proc.c
@@ -0,0 +1,253 @@
+}
+
+#endif
-diff --git a/drivers/misc/vc04_services/interface/vchiq_arm/vchiq_shim.c b/drivers/misc/vc04_services/interface/vchiq_arm/vchiq_shim.c
-new file mode 100644
-index 0000000..a0b069d
--- /dev/null
+++ b/drivers/misc/vc04_services/interface/vchiq_arm/vchiq_shim.c
@@ -0,0 +1,828 @@
+ return ret;
+}
+EXPORT_SYMBOL(vchi_service_release);
-diff --git a/drivers/misc/vc04_services/interface/vchiq_arm/vchiq_util.c b/drivers/misc/vc04_services/interface/vchiq_arm/vchiq_util.c
-new file mode 100644
-index 0000000..c2eefef
--- /dev/null
+++ b/drivers/misc/vc04_services/interface/vchiq_arm/vchiq_util.c
@@ -0,0 +1,151 @@
+
+ return header;
+}
-diff --git a/drivers/misc/vc04_services/interface/vchiq_arm/vchiq_util.h b/drivers/misc/vc04_services/interface/vchiq_arm/vchiq_util.h
-new file mode 100644
-index 0000000..f4d0b66
--- /dev/null
+++ b/drivers/misc/vc04_services/interface/vchiq_arm/vchiq_util.h
@@ -0,0 +1,81 @@
+extern VCHIQ_HEADER_T *vchiu_queue_pop(VCHIU_QUEUE_T *queue);
+
+#endif
-diff --git a/drivers/misc/vc04_services/interface/vchiq_arm/vchiq_version.c b/drivers/misc/vc04_services/interface/vchiq_arm/vchiq_version.c
-new file mode 100644
-index 0000000..b6bfa21
--- /dev/null
+++ b/drivers/misc/vc04_services/interface/vchiq_arm/vchiq_version.c
@@ -0,0 +1,59 @@
+{
+ return vchiq_build_time;
+}
---
-1.9.1
-
7 files changed, 75 insertions(+)
create mode 100644 drivers/misc/vc04_services/interface/vchiq_arm/vchiq_killable.h
-diff --git a/drivers/misc/vc04_services/interface/vchiq_arm/vchiq_2835_arm.c b/drivers/misc/vc04_services/interface/vchiq_arm/vchiq_2835_arm.c
-index b3bdaa2..7e7b09f 100644
--- a/drivers/misc/vc04_services/interface/vchiq_arm/vchiq_2835_arm.c
+++ b/drivers/misc/vc04_services/interface/vchiq_arm/vchiq_2835_arm.c
@@ -56,6 +56,7 @@
#define MAX_FRAGMENTS (VCHIQ_NUM_CURRENT_BULKS * 2)
-diff --git a/drivers/misc/vc04_services/interface/vchiq_arm/vchiq_arm.c b/drivers/misc/vc04_services/interface/vchiq_arm/vchiq_arm.c
-index c1fb8c3..99c8967e 100644
--- a/drivers/misc/vc04_services/interface/vchiq_arm/vchiq_arm.c
+++ b/drivers/misc/vc04_services/interface/vchiq_arm/vchiq_arm.c
@@ -49,6 +49,7 @@
#define DEVICE_NAME "vchiq"
-diff --git a/drivers/misc/vc04_services/interface/vchiq_arm/vchiq_connected.c b/drivers/misc/vc04_services/interface/vchiq_arm/vchiq_connected.c
-index 65f4b52..5efc62f 100644
--- a/drivers/misc/vc04_services/interface/vchiq_arm/vchiq_connected.c
+++ b/drivers/misc/vc04_services/interface/vchiq_arm/vchiq_connected.c
@@ -33,6 +33,7 @@
#include <linux/module.h>
#include <linux/mutex.h>
-diff --git a/drivers/misc/vc04_services/interface/vchiq_arm/vchiq_core.c b/drivers/misc/vc04_services/interface/vchiq_arm/vchiq_core.c
-index f35ed4f..71ed0a5 100644
--- a/drivers/misc/vc04_services/interface/vchiq_arm/vchiq_core.c
+++ b/drivers/misc/vc04_services/interface/vchiq_arm/vchiq_core.c
@@ -32,6 +32,7 @@
#define VCHIQ_SLOT_HANDLER_STACK 8192
-diff --git a/drivers/misc/vc04_services/interface/vchiq_arm/vchiq_kern_lib.c b/drivers/misc/vc04_services/interface/vchiq_arm/vchiq_kern_lib.c
-index be9735f..5a4182e 100644
--- a/drivers/misc/vc04_services/interface/vchiq_arm/vchiq_kern_lib.c
+++ b/drivers/misc/vc04_services/interface/vchiq_arm/vchiq_kern_lib.c
@@ -39,6 +39,7 @@
/* ---- Public Variables ------------------------------------------------- */
-diff --git a/drivers/misc/vc04_services/interface/vchiq_arm/vchiq_killable.h b/drivers/misc/vc04_services/interface/vchiq_arm/vchiq_killable.h
-new file mode 100644
-index 0000000..505ee1a
--- /dev/null
+++ b/drivers/misc/vc04_services/interface/vchiq_arm/vchiq_killable.h
@@ -0,0 +1,69 @@
+#define mutex_lock_interruptible mutex_lock_interruptible_killable
+
+#endif
-diff --git a/drivers/misc/vc04_services/interface/vchiq_arm/vchiq_util.c b/drivers/misc/vc04_services/interface/vchiq_arm/vchiq_util.c
-index c2eefef..05e7979 100644
--- a/drivers/misc/vc04_services/interface/vchiq_arm/vchiq_util.c
+++ b/drivers/misc/vc04_services/interface/vchiq_arm/vchiq_util.c
@@ -32,6 +32,7 @@
static inline int is_pow2(int i)
{
---
-1.9.1
-
create mode 100644 drivers/char/broadcom/vc_cma/vc_cma.c
create mode 100644 include/linux/broadcom/vc_cma.h
-diff --git a/drivers/char/Kconfig b/drivers/char/Kconfig
-index 1386749..fcf51a3 100644
--- a/drivers/char/Kconfig
+++ b/drivers/char/Kconfig
@@ -581,6 +581,8 @@ config DEVPORT
config MSM_SMD_PKT
bool "Enable device interface for some SMD packet ports"
default n
-diff --git a/drivers/char/Makefile b/drivers/char/Makefile
-index a324f93..aef3ed0 100644
--- a/drivers/char/Makefile
+++ b/drivers/char/Makefile
@@ -61,3 +61,5 @@ obj-$(CONFIG_JS_RTC) += js-rtc.o
obj-$(CONFIG_TILE_SROM) += tile-srom.o
+
+obj-$(CONFIG_BRCM_CHAR_DRIVERS) += broadcom/
-diff --git a/drivers/char/broadcom/Kconfig b/drivers/char/broadcom/Kconfig
-new file mode 100644
-index 0000000..f089943
--- /dev/null
+++ b/drivers/char/broadcom/Kconfig
@@ -0,0 +1,16 @@
+ help
+ Helper for videocore CMA access.
+
-diff --git a/drivers/char/broadcom/Makefile b/drivers/char/broadcom/Makefile
-new file mode 100644
-index 0000000..13c5bca
--- /dev/null
+++ b/drivers/char/broadcom/Makefile
@@ -0,0 +1 @@
+obj-$(CONFIG_BCM_VC_CMA) += vc_cma/
-diff --git a/drivers/char/broadcom/vc_cma/Makefile b/drivers/char/broadcom/vc_cma/Makefile
-new file mode 100644
-index 0000000..6a94de4
--- /dev/null
+++ b/drivers/char/broadcom/vc_cma/Makefile
@@ -0,0 +1,14 @@
+obj-$(CONFIG_BCM_VC_CMA) += vc-cma.o
+
+vc-cma-objs := vc_cma.o
-diff --git a/drivers/char/broadcom/vc_cma/vc_cma.c b/drivers/char/broadcom/vc_cma/vc_cma.c
-new file mode 100644
-index 0000000..a635f9f
--- /dev/null
+++ b/drivers/char/broadcom/vc_cma/vc_cma.c
@@ -0,0 +1,1143 @@
+module_exit(vc_cma_exit);
+MODULE_LICENSE("GPL");
+MODULE_AUTHOR("Broadcom Corporation");
-diff --git a/drivers/misc/Makefile b/drivers/misc/Makefile
-index ad85616..8418ba7 100644
--- a/drivers/misc/Makefile
+++ b/drivers/misc/Makefile
@@ -52,6 +52,6 @@ obj-$(CONFIG_INTEL_MEI) += mei/
+obj-$(CONFIG_BCM2708_VCHIQ) += vc04_services/
obj-y += mic/
obj-$(CONFIG_GENWQE) += genwqe/
-diff --git a/include/linux/broadcom/vc_cma.h b/include/linux/broadcom/vc_cma.h
-new file mode 100644
-index 0000000..5325832
--- /dev/null
+++ b/include/linux/broadcom/vc_cma.h
@@ -0,0 +1,29 @@
+#endif
+
+#endif /* VC_CMA_H */
---
-1.9.1
-
create mode 100755 sound/arm/bcm2835.h
create mode 100644 sound/arm/vc_vchi_audioserv_defs.h
-diff --git a/arch/arm/configs/bcmrpi_cutdown_defconfig b/arch/arm/configs/bcmrpi_cutdown_defconfig
-index 74f2dc9..e519412 100644
--- a/arch/arm/configs/bcmrpi_cutdown_defconfig
+++ b/arch/arm/configs/bcmrpi_cutdown_defconfig
@@ -208,6 +208,26 @@ CONFIG_FRAMEBUFFER_CONSOLE=y
CONFIG_HID_PID=y
CONFIG_USB_HIDDEV=y
CONFIG_HID_A4TECH=m
-diff --git a/arch/arm/configs/bcmrpi_defconfig b/arch/arm/configs/bcmrpi_defconfig
-index 339aabf..df947e5 100644
--- a/arch/arm/configs/bcmrpi_defconfig
+++ b/arch/arm/configs/bcmrpi_defconfig
@@ -225,6 +225,26 @@ CONFIG_FRAMEBUFFER_CONSOLE=y
CONFIG_HID_PID=y
CONFIG_USB_HIDDEV=y
CONFIG_HID_A4TECH=m
-diff --git a/arch/arm/mach-bcm2708/bcm2708.c b/arch/arm/mach-bcm2708/bcm2708.c
-index a5af6ec..1904066 100644
--- a/arch/arm/mach-bcm2708/bcm2708.c
+++ b/arch/arm/mach-bcm2708/bcm2708.c
-@@ -431,6 +431,58 @@ struct platform_device bcm2708_powerman_device = {
+@@ -431,6 +431,58 @@ struct platform_device bcm2708_powerman_
.coherent_dma_mask = 0xffffffffUL},
};
for (i = 0; i < ARRAY_SIZE(amba_devs); i++) {
struct amba_device *d = amba_devs[i];
-diff --git a/sound/arm/Kconfig b/sound/arm/Kconfig
-index 885683a..f7ceafd 100644
--- a/sound/arm/Kconfig
+++ b/sound/arm/Kconfig
@@ -39,5 +39,12 @@ config SND_PXA2XX_AC97
+
endif # SND_ARM
-diff --git a/sound/arm/Makefile b/sound/arm/Makefile
-index 8c0c851..6796d7f 100644
--- a/sound/arm/Makefile
+++ b/sound/arm/Makefile
-@@ -14,3 +14,8 @@ snd-pxa2xx-lib-$(CONFIG_SND_PXA2XX_LIB_AC97) += pxa2xx-ac97-lib.o
+@@ -14,3 +14,8 @@ snd-pxa2xx-lib-$(CONFIG_SND_PXA2XX_LIB_A
obj-$(CONFIG_SND_PXA2XX_AC97) += snd-pxa2xx-ac97.o
snd-pxa2xx-ac97-objs := pxa2xx-ac97.o
+snd-bcm2835-objs := bcm2835.o bcm2835-ctl.o bcm2835-pcm.o bcm2835-vchiq.o
+
+ccflags-y += -Idrivers/misc/vc04_services -Idrivers/misc/vc04_services/interface/vcos/linuxkernel -D__VCCOREVER__=0x04000000
-diff --git a/sound/arm/bcm2835-ctl.c b/sound/arm/bcm2835-ctl.c
-new file mode 100755
-index 0000000..8c5334a
--- /dev/null
+++ b/sound/arm/bcm2835-ctl.c
@@ -0,0 +1,200 @@
+ }
+ return 0;
+}
-diff --git a/sound/arm/bcm2835-pcm.c b/sound/arm/bcm2835-pcm.c
-new file mode 100755
-index 0000000..2e7d405
--- /dev/null
+++ b/sound/arm/bcm2835-pcm.c
@@ -0,0 +1,409 @@
+
+ return 0;
+}
-diff --git a/sound/arm/bcm2835-vchiq.c b/sound/arm/bcm2835-vchiq.c
-new file mode 100755
-index 0000000..b9b4fe8
--- /dev/null
+++ b/sound/arm/bcm2835-vchiq.c
@@ -0,0 +1,844 @@
+
+module_param(force_bulk, bool, 0444);
+MODULE_PARM_DESC(force_bulk, "Force use of vchiq bulk for audio");
-diff --git a/sound/arm/bcm2835.c b/sound/arm/bcm2835.c
-new file mode 100755
-index 0000000..317e7d9
--- /dev/null
+++ b/sound/arm/bcm2835.c
@@ -0,0 +1,413 @@
+MODULE_DESCRIPTION("Alsa driver for BCM2835 chip");
+MODULE_LICENSE("GPL");
+MODULE_ALIAS("platform:bcm2835_alsa");
-diff --git a/sound/arm/bcm2835.h b/sound/arm/bcm2835.h
-new file mode 100755
-index 0000000..080bd5c
--- /dev/null
+++ b/sound/arm/bcm2835.h
@@ -0,0 +1,155 @@
+void bcm2835_audio_flush_playback_buffers(bcm2835_alsa_stream_t * alsa_stream);
+
+#endif /* __SOUND_ARM_BCM2835_H */
-diff --git a/sound/arm/vc_vchi_audioserv_defs.h b/sound/arm/vc_vchi_audioserv_defs.h
-new file mode 100644
-index 0000000..af3e6eb
--- /dev/null
+++ b/sound/arm/vc_vchi_audioserv_defs.h
@@ -0,0 +1,116 @@
+} VC_AUDIO_MSG_T;
+
+#endif // _VC_AUDIO_DEFS_H_
---
-1.9.1
-
sound/arm/bcm2835.h | 2 ++
4 files changed, 124 insertions(+), 70 deletions(-)
-diff --git a/sound/arm/bcm2835-pcm.c b/sound/arm/bcm2835-pcm.c
-index 2e7d405..b4084bb 100755
--- a/sound/arm/bcm2835-pcm.c
+++ b/sound/arm/bcm2835-pcm.c
@@ -19,7 +19,8 @@
.formats = SNDRV_PCM_FMTBIT_U8 | SNDRV_PCM_FMTBIT_S16_LE,
.rates = SNDRV_PCM_RATE_CONTINUOUS | SNDRV_PCM_RATE_8000_48000,
.rate_min = 8000,
-@@ -251,6 +252,12 @@ static int snd_bcm2835_pcm_prepare(struct snd_pcm_substream *substream)
+@@ -251,6 +252,12 @@ static int snd_bcm2835_pcm_prepare(struc
audio_info(" .. IN\n");
alsa_stream->buffer_size = snd_pcm_lib_buffer_bytes(substream);
alsa_stream->period_size = snd_pcm_lib_period_bytes(substream);
alsa_stream->pos = 0;
-@@ -263,6 +270,32 @@ static int snd_bcm2835_pcm_prepare(struct snd_pcm_substream *substream)
+@@ -263,6 +270,32 @@ static int snd_bcm2835_pcm_prepare(struc
return 0;
}
/* trigger callback */
static int snd_bcm2835_pcm_trigger(struct snd_pcm_substream *substream, int cmd)
{
-@@ -279,6 +312,11 @@ static int snd_bcm2835_pcm_trigger(struct snd_pcm_substream *substream, int cmd)
+@@ -279,6 +312,11 @@ static int snd_bcm2835_pcm_trigger(struc
if (!alsa_stream->running) {
err = bcm2835_audio_start(alsa_stream);
if (err == 0) {
alsa_stream->running = 1;
alsa_stream->draining = 1;
} else {
-@@ -327,30 +365,9 @@ snd_bcm2835_pcm_pointer(struct snd_pcm_substream *substream)
+@@ -327,30 +365,9 @@ snd_bcm2835_pcm_pointer(struct snd_pcm_s
alsa_stream->pos);
audio_info(" .. OUT\n");
}
static int snd_bcm2835_pcm_lib_ioctl(struct snd_pcm_substream *substream,
-@@ -372,7 +389,7 @@ static struct snd_pcm_ops snd_bcm2835_playback_ops = {
+@@ -372,7 +389,7 @@ static struct snd_pcm_ops snd_bcm2835_pl
.prepare = snd_bcm2835_pcm_prepare,
.trigger = snd_bcm2835_pcm_trigger,
.pointer = snd_bcm2835_pcm_pointer,
};
/* create a pcm device */
-diff --git a/sound/arm/bcm2835-vchiq.c b/sound/arm/bcm2835-vchiq.c
-index b9b4fe8..ee09b13 100755
--- a/sound/arm/bcm2835-vchiq.c
+++ b/sound/arm/bcm2835-vchiq.c
@@ -27,6 +27,7 @@
break;
}
kfree((void *)work);
-@@ -107,7 +120,7 @@ int bcm2835_audio_start(bcm2835_alsa_stream_t * alsa_stream)
+@@ -107,7 +120,7 @@ int bcm2835_audio_start(bcm2835_alsa_str
if (work) {
INIT_WORK((struct work_struct *)work, my_wq_function);
work->alsa_stream = alsa_stream;
if (queue_work
(alsa_stream->my_wq, (struct work_struct *)work))
ret = 0;
-@@ -128,7 +141,31 @@ int bcm2835_audio_stop(bcm2835_alsa_stream_t * alsa_stream)
+@@ -128,7 +141,31 @@ int bcm2835_audio_stop(bcm2835_alsa_stre
if (work) {
INIT_WORK((struct work_struct *)work, my_wq_function);
work->alsa_stream = alsa_stream;
if (queue_work
(alsa_stream->my_wq, (struct work_struct *)work))
ret = 0;
-@@ -178,7 +215,7 @@ static void audio_vchi_callback(void *param,
+@@ -178,7 +215,7 @@ static void audio_vchi_callback(void *pa
(" .. instance=%p, m.type=VC_AUDIO_MSG_TYPE_RESULT, success=%d\n",
instance, m.u.result.success);
instance->result = m.u.result.success;
} else if (m.type == VC_AUDIO_MSG_TYPE_COMPLETE) {
irq_handler_t callback = (irq_handler_t) m.u.complete.callback;
LOG_DBG
-@@ -435,8 +472,8 @@ static int bcm2835_audio_set_ctls_chan(bcm2835_alsa_stream_t * alsa_stream,
+@@ -435,8 +472,8 @@ static int bcm2835_audio_set_ctls_chan(b
m.u.control.dest = chip->dest;
m.u.control.volume = chip->volume;
/* Send the message to the videocore */
success = vchi_msg_queue(instance->vchi_handle[0],
-@@ -452,11 +489,10 @@ static int bcm2835_audio_set_ctls_chan(bcm2835_alsa_stream_t * alsa_stream,
+@@ -452,11 +489,10 @@ static int bcm2835_audio_set_ctls_chan(b
}
/* We are expecting a reply from the videocore */
goto unlock;
}
-@@ -539,8 +575,8 @@ int bcm2835_audio_set_params(bcm2835_alsa_stream_t * alsa_stream,
+@@ -539,8 +575,8 @@ int bcm2835_audio_set_params(bcm2835_als
m.u.config.samplerate = samplerate;
m.u.config.bps = bps;
/* Send the message to the videocore */
success = vchi_msg_queue(instance->vchi_handle[0],
-@@ -556,11 +592,10 @@ int bcm2835_audio_set_params(bcm2835_alsa_stream_t * alsa_stream,
+@@ -556,11 +592,10 @@ int bcm2835_audio_set_params(bcm2835_als
}
/* We are expecting a reply from the videocore */
goto unlock;
}
-@@ -688,8 +723,8 @@ int bcm2835_audio_close(bcm2835_alsa_stream_t * alsa_stream)
+@@ -688,8 +723,8 @@ int bcm2835_audio_close(bcm2835_alsa_str
m.type = VC_AUDIO_MSG_TYPE_CLOSE;
/* Send the message to the videocore */
success = vchi_msg_queue(instance->vchi_handle[0],
-@@ -702,11 +737,11 @@ int bcm2835_audio_close(bcm2835_alsa_stream_t * alsa_stream)
+@@ -702,11 +737,11 @@ int bcm2835_audio_close(bcm2835_alsa_str
ret = -1;
goto unlock;
}
{
VC_AUDIO_MSG_T m;
AUDIO_INSTANCE_T *instance = alsa_stream->instance;
-diff --git a/sound/arm/bcm2835.c b/sound/arm/bcm2835.c
-index 317e7d9..e2047a7 100755
--- a/sound/arm/bcm2835.c
+++ b/sound/arm/bcm2835.c
-@@ -110,20 +110,20 @@ static int snd_bcm2835_alsa_probe(struct platform_device *pdev)
+@@ -110,20 +110,20 @@ static int snd_bcm2835_alsa_probe(struct
err = snd_bcm2835_create(g_card, pdev, &chip);
if (err < 0) {
return err;
}
-@@ -326,49 +326,49 @@ static int bcm2835_alsa_device_init(void)
+@@ -326,49 +326,49 @@ static int bcm2835_alsa_device_init(void
int err;
err = platform_driver_register(&bcm2835_alsa0_driver);
if (err) {
goto unregister_6;
}
-diff --git a/sound/arm/bcm2835.h b/sound/arm/bcm2835.h
-index 080bd5c..36afee3 100755
--- a/sound/arm/bcm2835.h
+++ b/sound/arm/bcm2835.h
@@ -23,6 +23,7 @@
struct semaphore buffers_update_sem;
struct semaphore control_sem;
---
-1.9.1
-
4 files changed, 130 insertions(+)
create mode 100755 drivers/char/hw_random/bcm2708-rng.c
-diff --git a/arch/arm/mach-bcm2708/include/mach/platform.h b/arch/arm/mach-bcm2708/include/mach/platform.h
-index 110ce07..ecd854e 100644
--- a/arch/arm/mach-bcm2708/include/mach/platform.h
+++ b/arch/arm/mach-bcm2708/include/mach/platform.h
@@ -60,6 +60,7 @@
#define GPIO_BASE (BCM2708_PERI_BASE + 0x200000) /* GPIO */
#define UART0_BASE (BCM2708_PERI_BASE + 0x201000) /* Uart 0 */
#define MMCI0_BASE (BCM2708_PERI_BASE + 0x202000) /* MMC interface */
-diff --git a/drivers/char/hw_random/Kconfig b/drivers/char/hw_random/Kconfig
-index 2f2b084..cfca8e9 100644
--- a/drivers/char/hw_random/Kconfig
+++ b/drivers/char/hw_random/Kconfig
@@ -341,6 +341,17 @@ config HW_RANDOM_TPM
config HW_RANDOM_MSM
tristate "Qualcomm MSM Random Number Generator support"
depends on HW_RANDOM && ARCH_MSM
-diff --git a/drivers/char/hw_random/Makefile b/drivers/char/hw_random/Makefile
-index 3ae7755..a7bfb80 100644
--- a/drivers/char/hw_random/Makefile
+++ b/drivers/char/hw_random/Makefile
-@@ -29,4 +29,5 @@ obj-$(CONFIG_HW_RANDOM_POWERNV) += powernv-rng.o
+@@ -29,4 +29,5 @@ obj-$(CONFIG_HW_RANDOM_POWERNV) += power
obj-$(CONFIG_HW_RANDOM_EXYNOS) += exynos-rng.o
obj-$(CONFIG_HW_RANDOM_TPM) += tpm-rng.o
obj-$(CONFIG_HW_RANDOM_BCM2835) += bcm2835-rng.o
+obj-$(CONFIG_HW_RANDOM_BCM2708) += bcm2708-rng.o
obj-$(CONFIG_HW_RANDOM_MSM) += msm-rng.o
-diff --git a/drivers/char/hw_random/bcm2708-rng.c b/drivers/char/hw_random/bcm2708-rng.c
-new file mode 100755
-index 0000000..1ffa7d7
--- /dev/null
+++ b/drivers/char/hw_random/bcm2708-rng.c
@@ -0,0 +1,117 @@
+
+MODULE_DESCRIPTION("BCM2708 H/W Random Number Generator (RNG) driver");
+MODULE_LICENSE("GPL and additional rights");
---
-1.9.1
-
3 files changed, 702 insertions(+)
create mode 100644 drivers/staging/media/lirc/lirc_rpi.c
-diff --git a/drivers/staging/media/lirc/Kconfig b/drivers/staging/media/lirc/Kconfig
-index e60a59f..6b7ff70 100644
--- a/drivers/staging/media/lirc/Kconfig
+++ b/drivers/staging/media/lirc/Kconfig
@@ -38,6 +38,12 @@ config LIRC_PARALLEL
config LIRC_SASEM
tristate "Sasem USB IR Remote"
depends on LIRC && USB
-diff --git a/drivers/staging/media/lirc/Makefile b/drivers/staging/media/lirc/Makefile
-index b90fcab..2b227fd 100644
--- a/drivers/staging/media/lirc/Makefile
+++ b/drivers/staging/media/lirc/Makefile
@@ -7,6 +7,7 @@ obj-$(CONFIG_LIRC_BT829) += lirc_bt829.o
obj-$(CONFIG_LIRC_SASEM) += lirc_sasem.o
obj-$(CONFIG_LIRC_SERIAL) += lirc_serial.o
obj-$(CONFIG_LIRC_SIR) += lirc_sir.o
-diff --git a/drivers/staging/media/lirc/lirc_rpi.c b/drivers/staging/media/lirc/lirc_rpi.c
-new file mode 100644
-index 0000000..57ffacf
--- /dev/null
+++ b/drivers/staging/media/lirc/lirc_rpi.c
@@ -0,0 +1,695 @@
+
+module_param(debug, bool, S_IRUGO | S_IWUSR);
+MODULE_PARM_DESC(debug, "Enable debugging messages");
---
-1.9.1
-
include/linux/mmc/sdhci.h | 1 +
7 files changed, 365 insertions(+), 191 deletions(-)
-diff --git a/drivers/mmc/card/block.c b/drivers/mmc/card/block.c
-index 7b5424f..687cccb 100644
--- a/drivers/mmc/card/block.c
+++ b/drivers/mmc/card/block.c
-@@ -1361,7 +1361,7 @@ static void mmc_blk_rw_rq_prep(struct mmc_queue_req *mqrq,
+@@ -1361,7 +1361,7 @@ static void mmc_blk_rw_rq_prep(struct mm
brq->data.blocks = 1;
}
/* SPI multiblock writes terminate using a special
* token, not a STOP_TRANSMISSION request.
*/
-diff --git a/drivers/mmc/core/sd.c b/drivers/mmc/core/sd.c
-index 692fdb1..ea11f9c 100644
--- a/drivers/mmc/core/sd.c
+++ b/drivers/mmc/core/sd.c
@@ -15,6 +15,8 @@
#include <linux/mmc/host.h>
#include <linux/mmc/card.h>
-@@ -67,6 +69,15 @@ static const unsigned int sd_au_size[] = {
+@@ -67,6 +69,15 @@ static const unsigned int sd_au_size[] =
__res & __mask; \
})
/*
* Given the decoded CSD structure, decode the raw CID to our CID structure.
*/
-@@ -219,12 +230,63 @@ static int mmc_decode_scr(struct mmc_card *card)
+@@ -219,12 +230,63 @@ static int mmc_decode_scr(struct mmc_car
}
/*
u32 *ssr;
if (!(card->csd.cmdclass & CCC_APP_SPEC)) {
-@@ -237,14 +299,40 @@ static int mmc_read_ssr(struct mmc_card *card)
+@@ -237,14 +299,40 @@ static int mmc_read_ssr(struct mmc_card
if (!ssr)
return -ENOMEM;
for (i = 0; i < 16; i++)
ssr[i] = be32_to_cpu(ssr[i]);
-@@ -826,14 +914,10 @@ int mmc_sd_setup_card(struct mmc_host *host, struct mmc_card *card,
+@@ -826,14 +914,10 @@ int mmc_sd_setup_card(struct mmc_host *h
if (!reinit) {
/*
return err;
/*
-diff --git a/drivers/mmc/host/sdhci-bcm2708.c b/drivers/mmc/host/sdhci-bcm2708.c
-index d8ef77c..3173c18 100644
--- a/drivers/mmc/host/sdhci-bcm2708.c
+++ b/drivers/mmc/host/sdhci-bcm2708.c
@@ -51,7 +51,6 @@
/*****************************************************************************\
* *
-@@ -129,6 +133,14 @@ static inline unsigned long int since_ns(hptime_t t)
+@@ -129,6 +133,14 @@ static inline unsigned long int since_ns
return (unsigned long)((hptime() - t) * HPTIME_CLK_NS);
}
#if 0
static void hptime_test(void)
{
-@@ -241,19 +253,19 @@ static void sdhci_bcm2708_raw_writel(struct sdhci_host *host, u32 val, int reg)
+@@ -241,19 +253,19 @@ static void sdhci_bcm2708_raw_writel(str
/* host->clock is the clock freq in Hz */
static hptime_t last_write_hpt;
hptime_t now = hptime();
}
last_write_hpt = now;
}
-@@ -269,13 +281,13 @@ static void sdhci_bcm2708_raw_writel(struct sdhci_host *host, u32 val, int reg)
+@@ -269,13 +281,13 @@ static void sdhci_bcm2708_raw_writel(str
ier &= ~SDHCI_INT_DATA_TIMEOUT;
writel(ier, host->ioaddr + SDHCI_SIGNAL_ENABLE);
timeout_disabled = true;
}
#endif
writel(val, host->ioaddr + reg);
-@@ -353,68 +365,9 @@ void sdhci_bcm2708_writeb(struct sdhci_host *host, u8 val, int reg)
+@@ -353,68 +365,9 @@ void sdhci_bcm2708_writeb(struct sdhci_h
static unsigned int sdhci_bcm2708_get_max_clock(struct sdhci_host *host)
{
if (host_priv->dma_wanted) {
if (NULL == data) {
-@@ -720,13 +673,16 @@ sdhci_bcm2708_platdma_reset(struct sdhci_host *host, struct mmc_data *data)
+@@ -720,13 +673,16 @@ sdhci_bcm2708_platdma_reset(struct sdhci
cs = readl(host_priv->dma_chan_base + BCM2708_DMA_CS);
if (!(BCM2708_DMA_ACTIVE & cs))
else
printk(KERN_INFO "%s: resetting ongoing cmd %d"
"DMA before %d/%d [%d]/[%d] complete\n",
-@@ -779,7 +735,7 @@ sdhci_bcm2708_platdma_reset(struct sdhci_host *host, struct mmc_data *data)
+@@ -779,7 +735,7 @@ sdhci_bcm2708_platdma_reset(struct sdhci
#endif
}
}
-@@ -792,11 +748,11 @@ static void sdhci_bcm2708_dma_complete_irq(struct sdhci_host *host,
+@@ -792,11 +748,11 @@ static void sdhci_bcm2708_dma_complete_i
int sg_len;
int sg_ix;
int sg_todo;
data = host->data;
#ifdef CHECK_DMA_USE
-@@ -821,7 +777,7 @@ static void sdhci_bcm2708_dma_complete_irq(struct sdhci_host *host,
+@@ -821,7 +777,7 @@ static void sdhci_bcm2708_dma_complete_i
if (NULL == data) {
DBG("PDMA unused completion - status 0x%X\n", dma_cs);
return;
}
sg = data->sg;
-@@ -878,40 +834,34 @@ static void sdhci_bcm2708_dma_complete_irq(struct sdhci_host *host,
+@@ -878,40 +834,34 @@ static void sdhci_bcm2708_dma_complete_i
SDHCI_INT_SPACE_AVAIL);
}
} else {
- u32 state_mask;
- int timeout=1000000;
- hptime_t now = hptime();
--
-- DBG("PDMA over - sync card\n");
-- if (data->flags & MMC_DATA_READ)
-- state_mask = SDHCI_DOING_READ;
-- else
-- state_mask = SDHCI_DOING_WRITE;
--
-- while (0 != (sdhci_bcm2708_raw_readl(host,
-- SDHCI_PRESENT_STATE) &
-- state_mask) && --timeout > 0)
-- continue;
+ if (sync_after_dma) {
+ /* On the Arasan controller the stop command (which will be
+ scheduled after this completes) does not seem to work
+ the SD controller to finish reading/writing to the card. */
+ u32 state_mask;
+ int timeout=3*1000*1000;
-+
+
+- DBG("PDMA over - sync card\n");
+- if (data->flags & MMC_DATA_READ)
+- state_mask = SDHCI_DOING_READ;
+- else
+- state_mask = SDHCI_DOING_WRITE;
+ DBG("PDMA over - sync card\n");
+ if (data->flags & MMC_DATA_READ)
+ state_mask = SDHCI_DOING_READ;
+ else
+ state_mask = SDHCI_DOING_WRITE;
+- while (0 != (sdhci_bcm2708_raw_readl(host,
+- SDHCI_PRESENT_STATE) &
+- state_mask) && --timeout > 0)
+- continue;
+-
- if (1000000-timeout > 4000) /*ave. is about 3250*/
- DBG("%s: note - long %s sync %luns - "
- "%d its.\n",
if (host_priv->complete) {
(*host_priv->complete)(host);
DBG("PDMA %s complete\n",
-@@ -920,7 +870,7 @@ static void sdhci_bcm2708_dma_complete_irq(struct sdhci_host *host,
+@@ -920,7 +870,7 @@ static void sdhci_bcm2708_dma_complete_i
SDHCI_INT_SPACE_AVAIL);
}
}
}
static irqreturn_t sdhci_bcm2708_dma_irq(int irq, void *dev_id)
-@@ -929,12 +879,11 @@ static irqreturn_t sdhci_bcm2708_dma_irq(int irq, void *dev_id)
+@@ -929,12 +879,11 @@ static irqreturn_t sdhci_bcm2708_dma_irq
struct sdhci_host *host = dev_id;
struct sdhci_bcm2708_priv *host_priv = SDHCI_HOST_PRIV(host);
u32 dma_cs; /* control and status register */
dma_cs = readl(host_priv->dma_chan_base + BCM2708_DMA_CS);
-@@ -958,7 +907,8 @@ static irqreturn_t sdhci_bcm2708_dma_irq(int irq, void *dev_id)
+@@ -958,7 +907,8 @@ static irqreturn_t sdhci_bcm2708_dma_irq
if (!host_priv->dma_wanted) {
/* ignore this interrupt - it was reset */
"results were reset\n",
mmc_hostname(host->mmc), dma_cs);
#ifdef CHECK_DMA_USE
-@@ -975,8 +925,7 @@ static irqreturn_t sdhci_bcm2708_dma_irq(int irq, void *dev_id)
+@@ -975,8 +925,7 @@ static irqreturn_t sdhci_bcm2708_dma_irq
result = IRQ_HANDLED;
}
return result;
}
-@@ -1019,10 +968,12 @@ static ssize_t attr_dma_store(struct device *_dev,
+@@ -1019,10 +968,12 @@ static ssize_t attr_dma_store(struct dev
int on = simple_strtol(buf, NULL, 0);
if (on) {
host->flags |= SDHCI_USE_PLATDMA;
printk(KERN_INFO "%s: DMA disabled\n",
mmc_hostname(host->mmc));
}
-@@ -1126,7 +1077,7 @@ static int sdhci_bcm2708_suspend(struct platform_device *dev, pm_message_t state
+@@ -1126,7 +1077,7 @@ static int sdhci_bcm2708_suspend(struct
int ret = 0;
if (host->mmc) {
}
return ret;
-@@ -1139,7 +1090,7 @@ static int sdhci_bcm2708_resume(struct platform_device *dev)
+@@ -1139,7 +1090,7 @@ static int sdhci_bcm2708_resume(struct p
int ret = 0;
if (host->mmc) {
}
return ret;
-@@ -1158,19 +1109,14 @@ static unsigned int sdhci_bcm2708_quirk_extra_ints(struct sdhci_host *host)
+@@ -1158,19 +1109,14 @@ static unsigned int sdhci_bcm2708_quirk_
return 1;
}
}
/***************************************************************************** \
-@@ -1190,11 +1136,7 @@ static struct sdhci_ops sdhci_bcm2708_ops = {
+@@ -1190,11 +1136,7 @@ static struct sdhci_ops sdhci_bcm2708_op
#else
#error The BCM2708 SDHCI driver needs CONFIG_MMC_SDHCI_IO_ACCESSORS to be set
#endif
#ifdef CONFIG_MMC_SDHCI_BCM2708_DMA
// Platform DMA operations
-@@ -1203,9 +1145,6 @@ static struct sdhci_ops sdhci_bcm2708_ops = {
+@@ -1203,9 +1145,6 @@ static struct sdhci_ops sdhci_bcm2708_op
.pdma_reset = sdhci_bcm2708_platdma_reset,
#endif
.extra_ints = sdhci_bcm2708_quirk_extra_ints,
};
/*****************************************************************************\
-@@ -1244,15 +1183,30 @@ static int sdhci_bcm2708_probe(struct platform_device *pdev)
+@@ -1244,15 +1183,30 @@ static int sdhci_bcm2708_probe(struct pl
ret = PTR_ERR(host);
goto err;
}
#ifdef CONFIG_MMC_SDHCI_BCM2708_DMA
host->flags = SDHCI_USE_PLATDMA;
#endif
-@@ -1305,17 +1259,24 @@ static int sdhci_bcm2708_probe(struct platform_device *pdev)
+@@ -1305,17 +1259,24 @@ static int sdhci_bcm2708_probe(struct pl
host_priv->dma_chan = ret;
ret = request_irq(host_priv->dma_irq, sdhci_bcm2708_dma_irq,
#endif
ret = sdhci_add_host(host);
-@@ -1327,6 +1288,12 @@ static int sdhci_bcm2708_probe(struct platform_device *pdev)
+@@ -1327,6 +1288,12 @@ static int sdhci_bcm2708_probe(struct pl
ret = device_create_file(&pdev->dev, &dev_attr_dma_wait);
ret = device_create_file(&pdev->dev, &dev_attr_status);
+MODULE_PARM_DESC(extra_messages, "Enable more sdcard warning messages");
+
+
-diff --git a/drivers/mmc/host/sdhci.c b/drivers/mmc/host/sdhci.c
-index b78afa2..db67be8 100644
--- a/drivers/mmc/host/sdhci.c
+++ b/drivers/mmc/host/sdhci.c
-@@ -131,6 +131,99 @@ static void sdhci_dumpregs(struct sdhci_host *host)
+@@ -131,6 +131,99 @@ static void sdhci_dumpregs(struct sdhci_
* Low level functions *
* *
\*****************************************************************************/
static void sdhci_clear_set_irqs(struct sdhci_host *host, u32 clear, u32 set)
{
-@@ -300,7 +393,7 @@ static void sdhci_led_control(struct led_classdev *led,
+@@ -300,7 +393,7 @@ static void sdhci_led_control(struct led
struct sdhci_host *host = container_of(led, struct sdhci_host, led);
unsigned long flags;
if (host->runtime_suspended)
goto out;
-@@ -310,7 +403,7 @@ static void sdhci_led_control(struct led_classdev *led,
+@@ -310,7 +403,7 @@ static void sdhci_led_control(struct led
else
sdhci_activate_led(host);
out:
}
#endif
-@@ -457,6 +550,7 @@ static void sdhci_transfer_pio(struct sdhci_host *host, u32 intstate)
+@@ -457,6 +550,7 @@ static void sdhci_transfer_pio(struct sd
break;
state = sdhci_readl(host, SDHCI_PRESENT_STATE);
available = state & mask;
}
DBG("PIO transfer complete - %d blocks left.\n", host->blocks);
-@@ -1023,7 +1117,9 @@ void sdhci_send_command(struct sdhci_host *host, struct mmc_command *cmd)
+@@ -1023,7 +1117,9 @@ void sdhci_send_command(struct sdhci_hos
return;
}
timeout--;
}
clk |= SDHCI_CLOCK_CARD_EN;
-@@ -1357,7 +1455,7 @@ static void sdhci_request(struct mmc_host *mmc, struct mmc_request *mrq)
+@@ -1357,7 +1455,7 @@ static void sdhci_request(struct mmc_hos
sdhci_runtime_pm_get(host);
WARN_ON(host->mrq != NULL);
-@@ -1422,9 +1520,9 @@ static void sdhci_request(struct mmc_host *mmc, struct mmc_request *mrq)
+@@ -1422,9 +1520,9 @@ static void sdhci_request(struct mmc_hos
*/
host->mrq = NULL;
/* Restore original mmc_request structure */
host->mrq = mrq;
-@@ -1438,7 +1536,7 @@ static void sdhci_request(struct mmc_host *mmc, struct mmc_request *mrq)
+@@ -1438,7 +1536,7 @@ static void sdhci_request(struct mmc_hos
}
mmiowb();
}
static void sdhci_do_set_ios(struct sdhci_host *host, struct mmc_ios *ios)
-@@ -1447,10 +1545,10 @@ static void sdhci_do_set_ios(struct sdhci_host *host, struct mmc_ios *ios)
+@@ -1447,10 +1545,10 @@ static void sdhci_do_set_ios(struct sdhc
int vdd_bit = -1;
u8 ctrl;
if (host->vmmc && ios->power_mode == MMC_POWER_OFF)
mmc_regulator_set_ocr(host->mmc, host->vmmc, 0);
return;
-@@ -1478,9 +1576,9 @@ static void sdhci_do_set_ios(struct sdhci_host *host, struct mmc_ios *ios)
+@@ -1478,9 +1576,9 @@ static void sdhci_do_set_ios(struct sdhc
vdd_bit = sdhci_set_power(host, ios->vdd);
if (host->vmmc && vdd_bit != -1) {
}
if (host->ops->platform_send_init_74_clocks)
-@@ -1519,7 +1617,7 @@ static void sdhci_do_set_ios(struct sdhci_host *host, struct mmc_ios *ios)
+@@ -1519,7 +1617,7 @@ static void sdhci_do_set_ios(struct sdhc
else
ctrl &= ~SDHCI_CTRL_HISPD;
u16 clk, ctrl_2;
/* In case of UHS-I modes, set High Speed Enable */
-@@ -1617,7 +1715,7 @@ static void sdhci_do_set_ios(struct sdhci_host *host, struct mmc_ios *ios)
+@@ -1617,7 +1715,7 @@ static void sdhci_do_set_ios(struct sdhc
sdhci_reset(host, SDHCI_RESET_CMD | SDHCI_RESET_DATA);
mmiowb();
}
static void sdhci_set_ios(struct mmc_host *mmc, struct mmc_ios *ios)
-@@ -1665,7 +1763,7 @@ static int sdhci_check_ro(struct sdhci_host *host)
+@@ -1665,7 +1763,7 @@ static int sdhci_check_ro(struct sdhci_h
unsigned long flags;
int is_readonly;
if (host->flags & SDHCI_DEVICE_DEAD)
is_readonly = 0;
-@@ -1675,7 +1773,7 @@ static int sdhci_check_ro(struct sdhci_host *host)
+@@ -1675,7 +1773,7 @@ static int sdhci_check_ro(struct sdhci_h
is_readonly = !(sdhci_readl(host, SDHCI_PRESENT_STATE)
& SDHCI_WRITE_PROTECT);
/* This quirk needs to be replaced by a callback-function later */
return host->quirks & SDHCI_QUIRK_INVERTED_WRITE_PROTECT ?
-@@ -1748,9 +1846,9 @@ static void sdhci_enable_sdio_irq(struct mmc_host *mmc, int enable)
+@@ -1748,9 +1846,9 @@ static void sdhci_enable_sdio_irq(struct
struct sdhci_host *host = mmc_priv(mmc);
unsigned long flags;
}
static int sdhci_do_start_signal_voltage_switch(struct sdhci_host *host,
-@@ -2101,7 +2199,7 @@ static void sdhci_card_event(struct mmc_host *mmc)
+@@ -2101,7 +2199,7 @@ static void sdhci_card_event(struct mmc_
if (host->ops->card_event)
host->ops->card_event(host);
/* Check host->mrq first in case we are runtime suspended */
if (host->mrq && !sdhci_do_get_cd(host)) {
-@@ -2117,7 +2215,7 @@ static void sdhci_card_event(struct mmc_host *mmc)
+@@ -2117,7 +2215,7 @@ static void sdhci_card_event(struct mmc_
tasklet_schedule(&host->finish_tasklet);
}
}
static const struct mmc_host_ops sdhci_ops = {
-@@ -2156,14 +2254,14 @@ static void sdhci_tasklet_finish(unsigned long param)
+@@ -2156,14 +2254,14 @@ static void sdhci_tasklet_finish(unsigne
host = (struct sdhci_host*)param;
return;
}
-@@ -2201,7 +2299,7 @@ static void sdhci_tasklet_finish(unsigned long param)
+@@ -2201,7 +2299,7 @@ static void sdhci_tasklet_finish(unsigne
#endif
mmiowb();
mmc_request_done(host->mmc, mrq);
sdhci_runtime_pm_put(host);
-@@ -2214,7 +2312,7 @@ static void sdhci_timeout_timer(unsigned long data)
+@@ -2214,7 +2312,7 @@ static void sdhci_timeout_timer(unsigned
host = (struct sdhci_host*)data;
if (host->mrq) {
pr_err("%s: Timeout waiting for hardware "
-@@ -2235,7 +2333,7 @@ static void sdhci_timeout_timer(unsigned long data)
+@@ -2235,7 +2333,7 @@ static void sdhci_timeout_timer(unsigned
}
mmiowb();
}
static void sdhci_tuning_timer(unsigned long data)
-@@ -2245,11 +2343,11 @@ static void sdhci_tuning_timer(unsigned long data)
+@@ -2245,11 +2343,11 @@ static void sdhci_tuning_timer(unsigned
host = (struct sdhci_host *)data;
}
/*****************************************************************************\
-@@ -2473,10 +2571,10 @@ static irqreturn_t sdhci_irq(int irq, void *dev_id)
+@@ -2473,10 +2571,10 @@ static irqreturn_t sdhci_irq(int irq, vo
u32 intmask, unexpected = 0;
int cardint = 0, max_loops = 16;
if (unexpected) {
pr_err("%s: Unexpected interrupt 0x%08x.\n",
-@@ -2674,7 +2772,7 @@ int sdhci_resume_host(struct sdhci_host *host)
+@@ -2674,7 +2772,7 @@ int sdhci_resume_host(struct sdhci_host
}
if (!device_may_wakeup(mmc_dev(host->mmc))) {
mmc_hostname(host->mmc), host);
if (ret)
return ret;
-@@ -2750,15 +2848,15 @@ int sdhci_runtime_suspend_host(struct sdhci_host *host)
+@@ -2750,15 +2848,15 @@ int sdhci_runtime_suspend_host(struct sd
host->flags &= ~SDHCI_NEEDS_RETUNING;
}
return ret;
}
-@@ -2784,16 +2882,16 @@ int sdhci_runtime_resume_host(struct sdhci_host *host)
+@@ -2784,16 +2882,16 @@ int sdhci_runtime_resume_host(struct sdh
sdhci_do_start_signal_voltage_switch(host, &host->mmc->ios);
if ((host_flags & SDHCI_PV_ENABLED) &&
!(host->quirks2 & SDHCI_QUIRK2_PRESET_VALUE_BROKEN)) {
host->runtime_suspended = false;
-@@ -2804,7 +2902,7 @@ int sdhci_runtime_resume_host(struct sdhci_host *host)
+@@ -2804,7 +2902,7 @@ int sdhci_runtime_resume_host(struct sdh
/* Enable Card Detection */
sdhci_enable_card_detection(host);
return ret;
}
-@@ -3300,8 +3398,8 @@ int sdhci_add_host(struct sdhci_host *host)
+@@ -3300,8 +3398,8 @@ int sdhci_add_host(struct sdhci_host *ho
sdhci_init(host, 0);
if (ret) {
pr_err("%s: Failed to request IRQ %d: %d\n",
mmc_hostname(mmc), host->irq, ret);
-@@ -3362,7 +3460,7 @@ void sdhci_remove_host(struct sdhci_host *host, int dead)
+@@ -3362,7 +3460,7 @@ void sdhci_remove_host(struct sdhci_host
unsigned long flags;
if (dead) {
host->flags |= SDHCI_DEVICE_DEAD;
-@@ -3374,7 +3472,7 @@ void sdhci_remove_host(struct sdhci_host *host, int dead)
+@@ -3374,7 +3472,7 @@ void sdhci_remove_host(struct sdhci_host
tasklet_schedule(&host->finish_tasklet);
}
}
sdhci_disable_card_detection(host);
-diff --git a/drivers/mmc/host/sdhci.h b/drivers/mmc/host/sdhci.h
-index 6857875..649f3cf 100644
--- a/drivers/mmc/host/sdhci.h
+++ b/drivers/mmc/host/sdhci.h
@@ -300,8 +300,6 @@ struct sdhci_ops {
unsigned int (*missing_status)(struct sdhci_host *host);
void (*hw_reset)(struct sdhci_host *host);
-@@ -445,4 +443,10 @@ extern int sdhci_runtime_suspend_host(struct sdhci_host *host);
+@@ -445,4 +443,10 @@ extern int sdhci_runtime_suspend_host(st
extern int sdhci_runtime_resume_host(struct sdhci_host *host);
#endif
+
+
#endif /* __SDHCI_HW_H */
-diff --git a/include/linux/mmc/host.h b/include/linux/mmc/host.h
-index 99f5709..cd6f996 100644
--- a/include/linux/mmc/host.h
+++ b/include/linux/mmc/host.h
@@ -282,6 +282,7 @@ struct mmc_host {
mmc_pm_flag_t pm_caps; /* supported pm features */
-diff --git a/include/linux/mmc/sdhci.h b/include/linux/mmc/sdhci.h
-index e23fffb..b1b6537 100644
--- a/include/linux/mmc/sdhci.h
+++ b/include/linux/mmc/sdhci.h
@@ -102,6 +102,7 @@ struct sdhci_host {
void __iomem *ioaddr; /* Mapped address */
const struct sdhci_ops *ops; /* Low level hw interface */
---
-1.9.1
-
4 files changed, 249 insertions(+)
create mode 100755 drivers/cpufreq/bcm2835-cpufreq.c
-diff --git a/arch/arm/Kconfig b/arch/arm/Kconfig
-index 9e23417..be8a752 100644
--- a/arch/arm/Kconfig
+++ b/arch/arm/Kconfig
@@ -389,6 +389,7 @@ config ARCH_BCM2708
select GENERIC_CLOCKEVENTS
select ARM_ERRATA_411920
select MACH_BCM2708
-diff --git a/drivers/cpufreq/Kconfig.arm b/drivers/cpufreq/Kconfig.arm
-index 3129749..d12c80d 100644
--- a/drivers/cpufreq/Kconfig.arm
+++ b/drivers/cpufreq/Kconfig.arm
@@ -235,6 +235,14 @@ config ARM_SPEAR_CPUFREQ
config ARM_TEGRA_CPUFREQ
bool "TEGRA CPUFreq support"
depends on ARCH_TEGRA
-diff --git a/drivers/cpufreq/Makefile b/drivers/cpufreq/Makefile
-index dac58f6..d8ded24 100644
--- a/drivers/cpufreq/Makefile
+++ b/drivers/cpufreq/Makefile
-@@ -73,6 +73,7 @@ obj-$(CONFIG_ARM_S5PV210_CPUFREQ) += s5pv210-cpufreq.o
+@@ -73,6 +73,7 @@ obj-$(CONFIG_ARM_S5PV210_CPUFREQ) += s5p
obj-$(CONFIG_ARM_SA1100_CPUFREQ) += sa1100-cpufreq.o
obj-$(CONFIG_ARM_SA1110_CPUFREQ) += sa1110-cpufreq.o
obj-$(CONFIG_ARM_SPEAR_CPUFREQ) += spear-cpufreq.o
obj-$(CONFIG_ARM_TEGRA_CPUFREQ) += tegra-cpufreq.o
obj-$(CONFIG_ARM_VEXPRESS_SPC_CPUFREQ) += vexpress-spc-cpufreq.o
-diff --git a/drivers/cpufreq/bcm2835-cpufreq.c b/drivers/cpufreq/bcm2835-cpufreq.c
-new file mode 100755
-index 0000000..7bc55bd
--- /dev/null
+++ b/drivers/cpufreq/bcm2835-cpufreq.c
@@ -0,0 +1,239 @@
+
+module_init(bcm2835_cpufreq_module_init);
+module_exit(bcm2835_cpufreq_module_exit);
---
-1.9.1
-
create mode 100644 drivers/hwmon/bcm2835-hwmon.c
create mode 100644 drivers/thermal/bcm2835-thermal.c
-Index: linux-3.14.18/arch/arm/mach-bcm2708/bcm2708.c
-===================================================================
---- linux-3.14.18.orig/arch/arm/mach-bcm2708/bcm2708.c 2014-09-27 12:03:08.607411837 -0700
-+++ linux-3.14.18/arch/arm/mach-bcm2708/bcm2708.c 2014-09-27 12:03:08.603411837 -0700
-@@ -483,6 +483,14 @@
+--- a/arch/arm/mach-bcm2708/bcm2708.c
++++ b/arch/arm/mach-bcm2708/bcm2708.c
+@@ -483,6 +483,14 @@ static struct platform_device bcm2708_al
},
};
int __init bcm_register_device(struct platform_device *pdev)
{
int ret;
-@@ -594,6 +602,9 @@
+@@ -594,6 +602,9 @@ void __init bcm2708_init(void)
for (i = 0; i < ARRAY_SIZE(bcm2708_alsa_devices); i++)
bcm_register_device(&bcm2708_alsa_devices[i]);
for (i = 0; i < ARRAY_SIZE(amba_devs); i++) {
struct amba_device *d = amba_devs[i];
amba_device_register(d, &iomem_resource);
-Index: linux-3.14.18/drivers/hwmon/Kconfig
-===================================================================
---- linux-3.14.18.orig/drivers/hwmon/Kconfig 2014-09-27 12:03:08.607411837 -0700
-+++ linux-3.14.18/drivers/hwmon/Kconfig 2014-09-27 12:03:08.603411837 -0700
-@@ -1565,6 +1565,16 @@
+--- a/drivers/hwmon/Kconfig
++++ b/drivers/hwmon/Kconfig
+@@ -1565,6 +1565,16 @@ config SENSORS_MC13783_ADC
help
Support for the A/D converter on MC13783 and MC13892 PMIC.
if ACPI
comment "ACPI drivers"
-Index: linux-3.14.18/drivers/hwmon/bcm2835-hwmon.c
-===================================================================
---- /dev/null 1970-01-01 00:00:00.000000000 +0000
-+++ linux-3.14.18/drivers/hwmon/bcm2835-hwmon.c 2014-09-27 12:03:08.603411837 -0700
+--- /dev/null
++++ b/drivers/hwmon/bcm2835-hwmon.c
@@ -0,0 +1,219 @@
+/*****************************************************************************
+* Copyright 2011 Broadcom Corporation. All rights reserved.
+MODULE_DESCRIPTION("HW Monitor driver for bcm2835 chip");
+
+module_platform_driver(bcm2835_hwmon_driver);
-Index: linux-3.14.18/drivers/thermal/Kconfig
-===================================================================
---- linux-3.14.18.orig/drivers/thermal/Kconfig 2014-09-27 12:03:08.607411837 -0700
-+++ linux-3.14.18/drivers/thermal/Kconfig 2014-09-27 12:03:08.603411837 -0700
-@@ -196,6 +196,12 @@
+--- a/drivers/thermal/Kconfig
++++ b/drivers/thermal/Kconfig
+@@ -196,6 +196,12 @@ config INTEL_POWERCLAMP
enforce idle time which results in more package C-state residency. The
user interface is exposed via generic thermal framework.
config X86_PKG_TEMP_THERMAL
tristate "X86 package temperature thermal driver"
depends on X86_THERMAL_VECTOR
-Index: linux-3.14.18/drivers/thermal/Makefile
-===================================================================
---- linux-3.14.18.orig/drivers/thermal/Makefile 2014-09-27 12:03:08.607411837 -0700
-+++ linux-3.14.18/drivers/thermal/Makefile 2014-09-27 12:03:08.603411837 -0700
-@@ -28,6 +28,7 @@
+--- a/drivers/thermal/Makefile
++++ b/drivers/thermal/Makefile
+@@ -28,6 +28,7 @@ obj-$(CONFIG_ARMADA_THERMAL) += armada_t
obj-$(CONFIG_IMX_THERMAL) += imx_thermal.o
obj-$(CONFIG_DB8500_CPUFREQ_COOLING) += db8500_cpufreq_cooling.o
obj-$(CONFIG_INTEL_POWERCLAMP) += intel_powerclamp.o
obj-$(CONFIG_X86_PKG_TEMP_THERMAL) += x86_pkg_temp_thermal.o
obj-$(CONFIG_TI_SOC_THERMAL) += ti-soc-thermal/
obj-$(CONFIG_ACPI_INT3403_THERMAL) += int3403_thermal.o
-Index: linux-3.14.18/drivers/thermal/bcm2835-thermal.c
-===================================================================
---- /dev/null 1970-01-01 00:00:00.000000000 +0000
-+++ linux-3.14.18/drivers/thermal/bcm2835-thermal.c 2014-09-27 12:03:08.603411837 -0700
+--- /dev/null
++++ b/drivers/thermal/bcm2835-thermal.c
@@ -0,0 +1,184 @@
+/*****************************************************************************
+* Copyright 2011 Broadcom Corporation. All rights reserved.
drivers/net/usb/smsc95xx.c | 56 ++++++++++++++++++++++++++++++++++++++++++++++
1 file changed, 56 insertions(+)
-diff --git a/drivers/net/usb/smsc95xx.c b/drivers/net/usb/smsc95xx.c
-index 424db65e..fc1ef4e 100644
--- a/drivers/net/usb/smsc95xx.c
+++ b/drivers/net/usb/smsc95xx.c
@@ -59,6 +59,7 @@
static int __must_check __smsc95xx_read_reg(struct usbnet *dev, u32 index,
u32 *data, int in_pm)
{
-@@ -763,8 +768,59 @@ static int smsc95xx_ioctl(struct net_device *netdev, struct ifreq *rq, int cmd)
+@@ -763,8 +768,59 @@ static int smsc95xx_ioctl(struct net_dev
return generic_mii_ioctl(&dev->mii, if_mii(rq), cmd, NULL);
}
/* try reading mac address from EEPROM */
if (smsc95xx_read_eeprom(dev, EEPROM_MAC_OFFSET, ETH_ALEN,
dev->net->dev_addr) == 0) {
---
-1.9.1
-
create mode 100644 drivers/i2c/busses/i2c-bcm2708.c
create mode 100644 drivers/spi/spi-bcm2708.c
-diff --git a/arch/arm/configs/bcmrpi_cutdown_defconfig b/arch/arm/configs/bcmrpi_cutdown_defconfig
-index e519412..2c2e29e 100644
--- a/arch/arm/configs/bcmrpi_cutdown_defconfig
+++ b/arch/arm/configs/bcmrpi_cutdown_defconfig
@@ -492,3 +492,12 @@ CONFIG_CRYPTO_DEFLATE=m
+CONFIG_SPI=y
+CONFIG_SPI_MASTER=y
+CONFIG_SPI_BCM2708=m
-diff --git a/arch/arm/configs/bcmrpi_defconfig b/arch/arm/configs/bcmrpi_defconfig
-index df947e5..31f5afaa 100644
--- a/arch/arm/configs/bcmrpi_defconfig
+++ b/arch/arm/configs/bcmrpi_defconfig
@@ -214,6 +214,12 @@ CONFIG_SERIAL_AMBA_PL011=y
CONFIG_GPIO_SYSFS=y
# CONFIG_HWMON is not set
CONFIG_WATCHDOG=y
-diff --git a/arch/arm/mach-bcm2708/Kconfig b/arch/arm/mach-bcm2708/Kconfig
-index 9355841..e151ed4 100644
--- a/arch/arm/mach-bcm2708/Kconfig
+++ b/arch/arm/mach-bcm2708/Kconfig
@@ -31,4 +31,11 @@ config BCM2708_NOL2CACHE
+ help
+ Binds spidev driver to the SPI0 master
endmenu
-diff --git a/arch/arm/mach-bcm2708/bcm2708.c b/arch/arm/mach-bcm2708/bcm2708.c
-index 314bbcc..e892006 100644
--- a/arch/arm/mach-bcm2708/bcm2708.c
+++ b/arch/arm/mach-bcm2708/bcm2708.c
@@ -31,6 +31,7 @@
}
};
-@@ -483,6 +491,89 @@ static struct platform_device bcm2708_alsa_devices[] = {
+@@ -483,6 +491,89 @@ static struct platform_device bcm2708_al
},
};
}
static void timer_set_mode(enum clock_event_mode mode,
-diff --git a/arch/arm/mach-bcm2708/include/mach/platform.h b/arch/arm/mach-bcm2708/include/mach/platform.h
-index ecd854e..f4bb733 100644
--- a/arch/arm/mach-bcm2708/include/mach/platform.h
+++ b/arch/arm/mach-bcm2708/include/mach/platform.h
@@ -64,9 +64,12 @@
#define USB_BASE (BCM2708_PERI_BASE + 0x980000) /* DTC_OTG USB controller */
#define MCORE_BASE (BCM2708_PERI_BASE + 0x0000) /* Fake frame buffer device (actually the multicore sync block*/
-diff --git a/drivers/i2c/busses/Kconfig b/drivers/i2c/busses/Kconfig
-index c5eec02..315421d 100644
--- a/drivers/i2c/busses/Kconfig
+++ b/drivers/i2c/busses/Kconfig
@@ -348,6 +348,25 @@ config I2C_BCM2835
config I2C_BCM_KONA
tristate "BCM Kona I2C adapter"
depends on ARCH_BCM_MOBILE
-diff --git a/drivers/i2c/busses/Makefile b/drivers/i2c/busses/Makefile
-index a08931f..a62fadf 100644
--- a/drivers/i2c/busses/Makefile
+++ b/drivers/i2c/busses/Makefile
-@@ -32,6 +32,7 @@ obj-$(CONFIG_I2C_POWERMAC) += i2c-powermac.o
+@@ -32,6 +32,7 @@ obj-$(CONFIG_I2C_POWERMAC) += i2c-powerm
obj-$(CONFIG_I2C_AT91) += i2c-at91.o
obj-$(CONFIG_I2C_AU1550) += i2c-au1550.o
obj-$(CONFIG_I2C_BCM2835) += i2c-bcm2835.o
obj-$(CONFIG_I2C_BLACKFIN_TWI) += i2c-bfin-twi.o
obj-$(CONFIG_I2C_CBUS_GPIO) += i2c-cbus-gpio.o
obj-$(CONFIG_I2C_CPM) += i2c-cpm.o
-diff --git a/drivers/i2c/busses/i2c-bcm2708.c b/drivers/i2c/busses/i2c-bcm2708.c
-new file mode 100644
-index 0000000..b3d96f0
--- /dev/null
+++ b/drivers/i2c/busses/i2c-bcm2708.c
@@ -0,0 +1,419 @@
+MODULE_AUTHOR("Chris Boot <bootc@bootc.net>");
+MODULE_LICENSE("GPL v2");
+MODULE_ALIAS("platform:" DRV_NAME);
-diff --git a/drivers/spi/Kconfig b/drivers/spi/Kconfig
-index 581ee2a..6029f6f 100644
--- a/drivers/spi/Kconfig
+++ b/drivers/spi/Kconfig
@@ -85,6 +85,14 @@ config SPI_BCM2835
config SPI_BFIN5XX
tristate "SPI controller driver for ADI Blackfin5xx"
depends on BLACKFIN && !BF60x
-diff --git a/drivers/spi/Makefile b/drivers/spi/Makefile
-index 95af48d..51996c2 100644
--- a/drivers/spi/Makefile
+++ b/drivers/spi/Makefile
-@@ -19,6 +19,7 @@ obj-$(CONFIG_SPI_BCM63XX) += spi-bcm63xx.o
+@@ -19,6 +19,7 @@ obj-$(CONFIG_SPI_BCM63XX) += spi-bcm63x
obj-$(CONFIG_SPI_BCM63XX_HSSPI) += spi-bcm63xx-hsspi.o
obj-$(CONFIG_SPI_BFIN5XX) += spi-bfin5xx.o
obj-$(CONFIG_SPI_BFIN_V3) += spi-bfin-v3.o
obj-$(CONFIG_SPI_BFIN_SPORT) += spi-bfin-sport.o
obj-$(CONFIG_SPI_BITBANG) += spi-bitbang.o
obj-$(CONFIG_SPI_BUTTERFLY) += spi-butterfly.o
-diff --git a/drivers/spi/spi-bcm2708.c b/drivers/spi/spi-bcm2708.c
-new file mode 100644
-index 0000000..180264a
--- /dev/null
+++ b/drivers/spi/spi-bcm2708.c
@@ -0,0 +1,626 @@
+MODULE_AUTHOR("Chris Boot <bootc@bootc.net>");
+MODULE_LICENSE("GPL v2");
+MODULE_ALIAS("platform:" DRV_NAME);
---
-1.9.1
-
drivers/i2c/busses/i2c-bcm2708.c | 31 ++++++++++++++++++++++++++++++-
1 file changed, 30 insertions(+), 1 deletion(-)
-diff --git a/drivers/i2c/busses/i2c-bcm2708.c b/drivers/i2c/busses/i2c-bcm2708.c
-index b3d96f0..05531db 100644
--- a/drivers/i2c/busses/i2c-bcm2708.c
+++ b/drivers/i2c/busses/i2c-bcm2708.c
-@@ -74,6 +74,9 @@ static unsigned int baudrate = CONFIG_I2C_BCM2708_BAUDRATE;
+@@ -74,6 +74,9 @@ static unsigned int baudrate = CONFIG_I2
module_param(baudrate, uint, S_IRUSR | S_IWUSR | S_IRGRP | S_IWGRP);
MODULE_PARM_DESC(baudrate, "The I2C baudrate");
struct bcm2708_i2c {
struct i2c_adapter adapter;
-@@ -150,7 +153,7 @@ static inline void bcm2708_bsc_fifo_fill(struct bcm2708_i2c *bi)
+@@ -150,7 +153,7 @@ static inline void bcm2708_bsc_fifo_fill
static inline void bcm2708_bsc_setup(struct bcm2708_i2c *bi)
{
unsigned long bus_hz;
u32 c = BSC_C_I2CEN | BSC_C_INTD | BSC_C_ST | BSC_C_CLEAR_1;
bus_hz = clk_get_rate(bi->clk);
-@@ -166,6 +169,32 @@ static inline void bcm2708_bsc_setup(struct bcm2708_i2c *bi)
+@@ -166,6 +169,32 @@ static inline void bcm2708_bsc_setup(str
bcm2708_wr(bi, BSC_DIV, cdiv);
bcm2708_wr(bi, BSC_A, bi->msg->addr);
bcm2708_wr(bi, BSC_DLEN, bi->msg->len);
bcm2708_wr(bi, BSC_C, c);
}
---
-1.9.1
-
drivers/w1/w1_io.c | 18 ++++++++++---
5 files changed, 115 insertions(+), 9 deletions(-)
-diff --git a/arch/arm/mach-bcm2708/bcm2708.c b/arch/arm/mach-bcm2708/bcm2708.c
-index e892006..221d145 100644
--- a/arch/arm/mach-bcm2708/bcm2708.c
+++ b/arch/arm/mach-bcm2708/bcm2708.c
@@ -32,6 +32,7 @@
static void __init bcm2708_init_led(void);
-@@ -258,6 +266,20 @@ static struct platform_device bcm2708_dmaman_device = {
+@@ -258,6 +266,20 @@ static struct platform_device bcm2708_dm
.num_resources = ARRAY_SIZE(bcm2708_dmaman_resources),
};
module_param(reboot_part, uint, 0644);
+module_param(w1_gpio_pin, uint, 0644);
+module_param(w1_gpio_pullup, uint, 0644);
-diff --git a/drivers/w1/masters/w1-gpio.c b/drivers/w1/masters/w1-gpio.c
-index 9709b8b..b10f9c9 100644
--- a/drivers/w1/masters/w1-gpio.c
+++ b/drivers/w1/masters/w1-gpio.c
@@ -23,6 +23,15 @@
#if defined(CONFIG_OF)
static struct of_device_id w1_gpio_dt_ids[] = {
{ .compatible = "w1-gpio" },
-@@ -102,14 +121,16 @@ static int w1_gpio_probe_dt(struct platform_device *pdev)
+@@ -102,14 +121,16 @@ static int w1_gpio_probe_dt(struct platf
static int w1_gpio_probe(struct platform_device *pdev)
{
struct w1_bus_master *master;
}
}
-@@ -127,6 +148,19 @@ static int w1_gpio_probe(struct platform_device *pdev)
+@@ -127,6 +148,19 @@ static int w1_gpio_probe(struct platform
return -ENOMEM;
}
err = devm_gpio_request(&pdev->dev, pdata->pin, "w1");
if (err) {
dev_err(&pdev->dev, "gpio_request (pin) failed\n");
-@@ -156,6 +190,14 @@ static int w1_gpio_probe(struct platform_device *pdev)
+@@ -156,6 +190,14 @@ static int w1_gpio_probe(struct platform
master->set_pullup = w1_gpio_set_pullup;
}
err = w1_add_master_device(master);
if (err) {
dev_err(&pdev->dev, "w1_add_master device failed\n");
-@@ -186,6 +228,9 @@ static int w1_gpio_remove(struct platform_device *pdev)
+@@ -186,6 +228,9 @@ static int w1_gpio_remove(struct platfor
w1_remove_master_device(master);
return 0;
}
-diff --git a/drivers/w1/w1.h b/drivers/w1/w1.h
-index ca8081a..3392959 100644
--- a/drivers/w1/w1.h
+++ b/drivers/w1/w1.h
@@ -148,6 +148,12 @@ struct w1_bus_master
/** Really nice hardware can handles the different types of ROM search
* w1_master* is passed to the slave found callback.
*/
-diff --git a/drivers/w1/w1_int.c b/drivers/w1/w1_int.c
-index 590bd8a..a4d69b6 100644
--- a/drivers/w1/w1_int.c
+++ b/drivers/w1/w1_int.c
-@@ -118,6 +118,20 @@ int w1_add_master_device(struct w1_bus_master *master)
+@@ -118,6 +118,20 @@ int w1_add_master_device(struct w1_bus_m
return(-EINVAL);
}
/* Lock until the device is added (or not) to w1_masters. */
mutex_lock(&w1_mlock);
/* Search for the first available id (starting at 1). */
-diff --git a/drivers/w1/w1_io.c b/drivers/w1/w1_io.c
-index e10acc2..667fdd5 100644
--- a/drivers/w1/w1_io.c
+++ b/drivers/w1/w1_io.c
-@@ -127,10 +127,22 @@ static void w1_pre_write(struct w1_master *dev)
+@@ -127,10 +127,22 @@ static void w1_pre_write(struct w1_maste
static void w1_post_write(struct w1_master *dev)
{
if (dev->pullup_duration) {
dev->pullup_duration = 0;
}
}
---
-1.9.1
-
create mode 100755 drivers/net/wireless/rtl8192cu/runwpa
create mode 100755 drivers/net/wireless/rtl8192cu/wlan0dhcp
-diff --git a/drivers/net/wireless/Kconfig b/drivers/net/wireless/Kconfig
-index 200020e..6ba6446 100644
--- a/drivers/net/wireless/Kconfig
+++ b/drivers/net/wireless/Kconfig
-@@ -276,7 +276,8 @@ source "drivers/net/wireless/libertas/Kconfig"
+@@ -276,7 +276,8 @@ source "drivers/net/wireless/libertas/Kc
source "drivers/net/wireless/orinoco/Kconfig"
source "drivers/net/wireless/p54/Kconfig"
source "drivers/net/wireless/rt2x00/Kconfig"
source "drivers/net/wireless/ti/Kconfig"
source "drivers/net/wireless/zd1211rw/Kconfig"
source "drivers/net/wireless/mwifiex/Kconfig"
-diff --git a/drivers/net/wireless/Makefile b/drivers/net/wireless/Makefile
-index 0fab227..1fb9e0b 100644
--- a/drivers/net/wireless/Makefile
+++ b/drivers/net/wireless/Makefile
@@ -24,7 +24,8 @@ obj-$(CONFIG_B43LEGACY) += b43legacy/
# 16-bit wireless PCMCIA client drivers
obj-$(CONFIG_PCMCIA_RAYCS) += ray_cs.o
-diff --git a/drivers/net/wireless/rtl8192cu/Kconfig b/drivers/net/wireless/rtl8192cu/Kconfig
-new file mode 100644
-index 0000000..bee5ed6
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/Kconfig
@@ -0,0 +1,6 @@
+ ---help---
+ Help message of RTL8192CU
+
-diff --git a/drivers/net/wireless/rtl8192cu/Makefile b/drivers/net/wireless/rtl8192cu/Makefile
-new file mode 100644
-index 0000000..c399011
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/Makefile
@@ -0,0 +1,616 @@
+ cd os_dep ; rm -fr *.mod.c *.mod *.o .*.cmd *.ko
+endif
+
-diff --git a/drivers/net/wireless/rtl8192cu/clean b/drivers/net/wireless/rtl8192cu/clean
-new file mode 100755
-index 0000000..8766421
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/clean
@@ -0,0 +1,5 @@
+rmmod 8192ce
+rmmod 8192du
+rmmod 8192de
-diff --git a/drivers/net/wireless/rtl8192cu/core/efuse/rtw_efuse.c b/drivers/net/wireless/rtl8192cu/core/efuse/rtw_efuse.c
-new file mode 100644
-index 0000000..3d341ac
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/core/efuse/rtw_efuse.c
@@ -0,0 +1,1147 @@
+#endif //PLATFORM_LINUX
+
+
-diff --git a/drivers/net/wireless/rtl8192cu/core/rtw_ap.c b/drivers/net/wireless/rtl8192cu/core/rtw_ap.c
-new file mode 100644
-index 0000000..405e7fe
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/core/rtw_ap.c
@@ -0,0 +1,2940 @@
+#endif //CONFIG_NATIVEAP_MLME
+#endif //CONFIG_AP_MODE
+
-diff --git a/drivers/net/wireless/rtl8192cu/core/rtw_br_ext.c b/drivers/net/wireless/rtl8192cu/core/rtw_br_ext.c
-new file mode 100644
-index 0000000..6bb924e
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/core/rtw_br_ext.c
@@ -0,0 +1,1699 @@
+}
+
+#endif // CONFIG_BR_EXT
-diff --git a/drivers/net/wireless/rtl8192cu/core/rtw_cmd.c b/drivers/net/wireless/rtl8192cu/core/rtw_cmd.c
-new file mode 100644
-index 0000000..f906eb3
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/core/rtw_cmd.c
@@ -0,0 +1,3035 @@
+
+}
+
-diff --git a/drivers/net/wireless/rtl8192cu/core/rtw_debug.c b/drivers/net/wireless/rtl8192cu/core/rtw_debug.c
-new file mode 100644
-index 0000000..f70fcb7
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/core/rtw_debug.c
@@ -0,0 +1,1337 @@
+
+#endif
+
-diff --git a/drivers/net/wireless/rtl8192cu/core/rtw_eeprom.c b/drivers/net/wireless/rtl8192cu/core/rtw_eeprom.c
-new file mode 100644
-index 0000000..fd07d64
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/core/rtw_eeprom.c
@@ -0,0 +1,423 @@
+_func_exit_;
+}
+
-diff --git a/drivers/net/wireless/rtl8192cu/core/rtw_ieee80211.c b/drivers/net/wireless/rtl8192cu/core/rtw_ieee80211.c
-new file mode 100644
-index 0000000..6305ba3
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/core/rtw_ieee80211.c
@@ -0,0 +1,1915 @@
+ return _action_public_str[action];
+}
+
-diff --git a/drivers/net/wireless/rtl8192cu/core/rtw_io.c b/drivers/net/wireless/rtl8192cu/core/rtw_io.c
-new file mode 100644
-index 0000000..4ffaa50
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/core/rtw_io.c
@@ -0,0 +1,464 @@
+#endif
+
+
-diff --git a/drivers/net/wireless/rtl8192cu/core/rtw_ioctl_query.c b/drivers/net/wireless/rtl8192cu/core/rtw_ioctl_query.c
-new file mode 100644
-index 0000000..0601886
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/core/rtw_ioctl_query.c
@@ -0,0 +1,196 @@
+}
+#endif
+
-diff --git a/drivers/net/wireless/rtl8192cu/core/rtw_ioctl_rtl.c b/drivers/net/wireless/rtl8192cu/core/rtw_ioctl_rtl.c
-new file mode 100644
-index 0000000..31b4704
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/core/rtw_ioctl_rtl.c
@@ -0,0 +1,1031 @@
+ return status;
+}
+//************** oid_rtl_seg_03_00 section end **************
-diff --git a/drivers/net/wireless/rtl8192cu/core/rtw_ioctl_set.c b/drivers/net/wireless/rtl8192cu/core/rtw_ioctl_set.c
-new file mode 100644
-index 0000000..e67f219
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/core/rtw_ioctl_set.c
@@ -0,0 +1,1494 @@
+ return _FAIL;
+}
+
-diff --git a/drivers/net/wireless/rtl8192cu/core/rtw_iol.c b/drivers/net/wireless/rtl8192cu/core/rtw_iol.c
-new file mode 100644
-index 0000000..872cc42
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/core/rtw_iol.c
@@ -0,0 +1,263 @@
+
+#endif //CONFIG_IOL
+
-diff --git a/drivers/net/wireless/rtl8192cu/core/rtw_mlme.c b/drivers/net/wireless/rtl8192cu/core/rtw_mlme.c
-new file mode 100644
-index 0000000..00edd9c
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/core/rtw_mlme.c
@@ -0,0 +1,3967 @@
+}
+#endif //CONFIG_CONCURRENT_MODE
+
-diff --git a/drivers/net/wireless/rtl8192cu/core/rtw_mlme_ext.c b/drivers/net/wireless/rtl8192cu/core/rtw_mlme_ext.c
-new file mode 100644
-index 0000000..d29a20c
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/core/rtw_mlme_ext.c
@@ -0,0 +1,13600 @@
+
+}
+
-diff --git a/drivers/net/wireless/rtl8192cu/core/rtw_mp.c b/drivers/net/wireless/rtl8192cu/core/rtw_mp.c
-new file mode 100644
-index 0000000..9af42cd
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/core/rtw_mp.c
@@ -0,0 +1,1324 @@
+
+#endif
+
-diff --git a/drivers/net/wireless/rtl8192cu/core/rtw_mp_ioctl.c b/drivers/net/wireless/rtl8192cu/core/rtw_mp_ioctl.c
-new file mode 100644
-index 0000000..b941e2c
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/core/rtw_mp_ioctl.c
@@ -0,0 +1,2954 @@
+#endif
+}
+
-diff --git a/drivers/net/wireless/rtl8192cu/core/rtw_p2p.c b/drivers/net/wireless/rtl8192cu/core/rtw_p2p.c
-new file mode 100644
-index 0000000..66c5f96
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/core/rtw_p2p.c
@@ -0,0 +1,5294 @@
+
+#endif //CONFIG_P2P
+
-diff --git a/drivers/net/wireless/rtl8192cu/core/rtw_pwrctrl.c b/drivers/net/wireless/rtl8192cu/core/rtw_pwrctrl.c
-new file mode 100644
-index 0000000..d1c11fa
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/core/rtw_pwrctrl.c
@@ -0,0 +1,1540 @@
+}
+
+
-diff --git a/drivers/net/wireless/rtl8192cu/core/rtw_recv.c b/drivers/net/wireless/rtl8192cu/core/rtw_recv.c
-new file mode 100644
-index 0000000..2cc8faa
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/core/rtw_recv.c
@@ -0,0 +1,4289 @@
+
+
+
-diff --git a/drivers/net/wireless/rtl8192cu/core/rtw_rf.c b/drivers/net/wireless/rtl8192cu/core/rtw_rf.c
-new file mode 100644
-index 0000000..7ae8635
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/core/rtw_rf.c
@@ -0,0 +1,95 @@
+ return ch;
+}
+
-diff --git a/drivers/net/wireless/rtl8192cu/core/rtw_security.c b/drivers/net/wireless/rtl8192cu/core/rtw_security.c
-new file mode 100644
-index 0000000..8fa8ed5
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/core/rtw_security.c
@@ -0,0 +1,3115 @@
+ return status;
+}
+
-diff --git a/drivers/net/wireless/rtl8192cu/core/rtw_sreset.c b/drivers/net/wireless/rtl8192cu/core/rtw_sreset.c
-new file mode 100644
-index 0000000..e08b1f7
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/core/rtw_sreset.c
@@ -0,0 +1,352 @@
+#endif
+}
+
-diff --git a/drivers/net/wireless/rtl8192cu/core/rtw_sta_mgt.c b/drivers/net/wireless/rtl8192cu/core/rtw_sta_mgt.c
-new file mode 100644
-index 0000000..f818a0c
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/core/rtw_sta_mgt.c
@@ -0,0 +1,848 @@
+
+}
+
-diff --git a/drivers/net/wireless/rtl8192cu/core/rtw_tdls.c b/drivers/net/wireless/rtl8192cu/core/rtw_tdls.c
-new file mode 100644
-index 0000000..e8c4d4c
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/core/rtw_tdls.c
@@ -0,0 +1,2941 @@
+
+#endif //CONFIG_TDLS
+
-diff --git a/drivers/net/wireless/rtl8192cu/core/rtw_wlan_util.c b/drivers/net/wireless/rtl8192cu/core/rtw_wlan_util.c
-new file mode 100644
-index 0000000..56dac60d
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/core/rtw_wlan_util.c
@@ -0,0 +1,2305 @@
+ return status;
+}
+
-diff --git a/drivers/net/wireless/rtl8192cu/core/rtw_xmit.c b/drivers/net/wireless/rtl8192cu/core/rtw_xmit.c
-new file mode 100644
-index 0000000..18f1fdb
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/core/rtw_xmit.c
@@ -0,0 +1,4156 @@
+}
+#endif //CONFIG_XMIT_ACK
+
-diff --git a/drivers/net/wireless/rtl8192cu/hal/HalPwrSeqCmd.c b/drivers/net/wireless/rtl8192cu/hal/HalPwrSeqCmd.c
-new file mode 100644
-index 0000000..c59bb66
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/hal/HalPwrSeqCmd.c
@@ -0,0 +1,177 @@
+}
+
+
-diff --git a/drivers/net/wireless/rtl8192cu/hal/dm.c b/drivers/net/wireless/rtl8192cu/hal/dm.c
-new file mode 100644
-index 0000000..465ca82
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/hal/dm.c
@@ -0,0 +1,314 @@
+#endif /* CONFIG_DM_ADAPTIVITY */
+}
+
-diff --git a/drivers/net/wireless/rtl8192cu/hal/dm.h b/drivers/net/wireless/rtl8192cu/hal/dm.h
-new file mode 100644
-index 0000000..dd9a57d
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/hal/dm.h
@@ -0,0 +1,30 @@
+void dm_adaptivity(_adapter *pAdapter);
+
+#endif /* __DM_H__ */
-diff --git a/drivers/net/wireless/rtl8192cu/hal/hal_com.c b/drivers/net/wireless/rtl8192cu/hal/hal_com.c
-new file mode 100644
-index 0000000..4dcafd6
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/hal/hal_com.c
@@ -0,0 +1,371 @@
+ return ret;
+}
+
-diff --git a/drivers/net/wireless/rtl8192cu/hal/hal_intf.c b/drivers/net/wireless/rtl8192cu/hal/hal_intf.c
-new file mode 100644
-index 0000000..6c56e72
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/hal/hal_intf.c
@@ -0,0 +1,546 @@
+ return adapter->HalFunc.c2h_id_filter_ccx;
+}
+
-diff --git a/drivers/net/wireless/rtl8192cu/hal/rtl8192c/rtl8192c_cmd.c b/drivers/net/wireless/rtl8192cu/hal/rtl8192c/rtl8192c_cmd.c
-new file mode 100644
-index 0000000..33921e2
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/hal/rtl8192c/rtl8192c_cmd.c
@@ -0,0 +1,1159 @@
+
+
+
-diff --git a/drivers/net/wireless/rtl8192cu/hal/rtl8192c/rtl8192c_dm.c b/drivers/net/wireless/rtl8192cu/hal/rtl8192c/rtl8192c_dm.c
-new file mode 100644
-index 0000000..6e5634c
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/hal/rtl8192c/rtl8192c_dm.c
@@ -0,0 +1,5056 @@
+
+}
+
-diff --git a/drivers/net/wireless/rtl8192cu/hal/rtl8192c/rtl8192c_hal_init.c b/drivers/net/wireless/rtl8192cu/hal/rtl8192c/rtl8192c_hal_init.c
-new file mode 100644
-index 0000000..b9e91d7
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/hal/rtl8192c/rtl8192c_hal_init.c
@@ -0,0 +1,3628 @@
+ pHalFunc->c2h_id_filter_ccx = c2h_id_filter_ccx_8192c;
+}
+
-diff --git a/drivers/net/wireless/rtl8192cu/hal/rtl8192c/rtl8192c_mp.c b/drivers/net/wireless/rtl8192cu/hal/rtl8192c/rtl8192c_mp.c
-new file mode 100644
-index 0000000..a4194c4
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/hal/rtl8192c/rtl8192c_mp.c
@@ -0,0 +1,1207 @@
+}
+
+#endif // CONFIG_MP_INCLUDE
-diff --git a/drivers/net/wireless/rtl8192cu/hal/rtl8192c/rtl8192c_phycfg.c b/drivers/net/wireless/rtl8192cu/hal/rtl8192c/rtl8192c_phycfg.c
-new file mode 100644
-index 0000000..1bae6da
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/hal/rtl8192c/rtl8192c_phycfg.c
@@ -0,0 +1,4841 @@
+ }
+}
+
-diff --git a/drivers/net/wireless/rtl8192cu/hal/rtl8192c/rtl8192c_rf6052.c b/drivers/net/wireless/rtl8192cu/hal/rtl8192c/rtl8192c_rf6052.c
-new file mode 100644
-index 0000000..cf46969
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/hal/rtl8192c/rtl8192c_rf6052.c
@@ -0,0 +1,1031 @@
+
+/* End of HalRf6052.c */
+
-diff --git a/drivers/net/wireless/rtl8192cu/hal/rtl8192c/rtl8192c_rxdesc.c b/drivers/net/wireless/rtl8192cu/hal/rtl8192c/rtl8192c_rxdesc.c
-new file mode 100644
-index 0000000..3e0d795
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/hal/rtl8192c/rtl8192c_rxdesc.c
@@ -0,0 +1,876 @@
+}
+
+
-diff --git a/drivers/net/wireless/rtl8192cu/hal/rtl8192c/rtl8192c_sreset.c b/drivers/net/wireless/rtl8192cu/hal/rtl8192c/rtl8192c_sreset.c
-new file mode 100644
-index 0000000..1368d66
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/hal/rtl8192c/rtl8192c_sreset.c
@@ -0,0 +1,94 @@
+}
+#endif
+
-diff --git a/drivers/net/wireless/rtl8192cu/hal/rtl8192c/rtl8192c_xmit.c b/drivers/net/wireless/rtl8192cu/hal/rtl8192c/rtl8192c_xmit.c
-new file mode 100644
-index 0000000..2cfd851
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/hal/rtl8192c/rtl8192c_xmit.c
@@ -0,0 +1,63 @@
+}
+#endif //CONFIG_XMIT_ACK
+
-diff --git a/drivers/net/wireless/rtl8192cu/hal/rtl8192c/usb/Hal8192CUHWImg.c b/drivers/net/wireless/rtl8192cu/hal/rtl8192c/usb/Hal8192CUHWImg.c
-new file mode 100644
-index 0000000..b49486b
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/hal/rtl8192c/usb/Hal8192CUHWImg.c
@@ -0,0 +1,8758 @@
+0xc78,0x621f001e,
+};
+
-diff --git a/drivers/net/wireless/rtl8192cu/hal/rtl8192c/usb/Hal8192CUHWImg_wowlan.c b/drivers/net/wireless/rtl8192cu/hal/rtl8192c/usb/Hal8192CUHWImg_wowlan.c
-new file mode 100644
-index 0000000..66970f1
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/hal/rtl8192c/usb/Hal8192CUHWImg_wowlan.c
@@ -0,0 +1,2564 @@
+
+
+
-diff --git a/drivers/net/wireless/rtl8192cu/hal/rtl8192c/usb/rtl8192cu_led.c b/drivers/net/wireless/rtl8192cu/hal/rtl8192c/usb/rtl8192cu_led.c
-new file mode 100644
-index 0000000..0d7af4a
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/hal/rtl8192c/usb/rtl8192cu_led.c
@@ -0,0 +1,2675 @@
+ DeInitLed871x( &(ledpriv->SwLed1) );
+}
+
-diff --git a/drivers/net/wireless/rtl8192cu/hal/rtl8192c/usb/rtl8192cu_recv.c b/drivers/net/wireless/rtl8192cu/hal/rtl8192c/usb/rtl8192cu_recv.c
-new file mode 100644
-index 0000000..1119cf8
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/hal/rtl8192c/usb/rtl8192cu_recv.c
@@ -0,0 +1,229 @@
+}
+
+
-diff --git a/drivers/net/wireless/rtl8192cu/hal/rtl8192c/usb/rtl8192cu_xmit.c b/drivers/net/wireless/rtl8192cu/hal/rtl8192c/usb/rtl8192cu_xmit.c
-new file mode 100644
-index 0000000..3a4137b
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/hal/rtl8192c/usb/rtl8192cu_xmit.c
@@ -0,0 +1,1150 @@
+}
+#endif
+
-diff --git a/drivers/net/wireless/rtl8192cu/hal/rtl8192c/usb/usb_halinit.c b/drivers/net/wireless/rtl8192cu/hal/rtl8192c/usb/usb_halinit.c
-new file mode 100644
-index 0000000..ff89473
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/hal/rtl8192c/usb/usb_halinit.c
@@ -0,0 +1,6261 @@
+
+}
+
-diff --git a/drivers/net/wireless/rtl8192cu/hal/rtl8192c/usb/usb_ops_ce.c b/drivers/net/wireless/rtl8192cu/hal/rtl8192c/usb/usb_ops_ce.c
-new file mode 100644
-index 0000000..9523337
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/hal/rtl8192c/usb/usb_ops_ce.c
@@ -0,0 +1,1207 @@
+}
+
+
-diff --git a/drivers/net/wireless/rtl8192cu/hal/rtl8192c/usb/usb_ops_linux.c b/drivers/net/wireless/rtl8192cu/hal/rtl8192c/usb/usb_ops_linux.c
-new file mode 100644
-index 0000000..2d627d3
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/hal/rtl8192c/usb/usb_ops_linux.c
@@ -0,0 +1,1536 @@
+
+}
+
-diff --git a/drivers/net/wireless/rtl8192cu/hal/rtl8192c/usb/usb_ops_xp.c b/drivers/net/wireless/rtl8192cu/hal/rtl8192c/usb/usb_ops_xp.c
-new file mode 100644
-index 0000000..32ff645
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/hal/rtl8192c/usb/usb_ops_xp.c
@@ -0,0 +1,1265 @@
+
+}
+
-diff --git a/drivers/net/wireless/rtl8192cu/ifcfg-wlan0 b/drivers/net/wireless/rtl8192cu/ifcfg-wlan0
-new file mode 100755
-index 0000000..7ecb7ae
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/ifcfg-wlan0
@@ -0,0 +1,4 @@
+BOOTPROTO=dhcp
+ONBOOT=yes
\ No newline at end of file
-diff --git a/drivers/net/wireless/rtl8192cu/include/Hal8192CEHWImg.h b/drivers/net/wireless/rtl8192cu/include/Hal8192CEHWImg.h
-new file mode 100644
-index 0000000..4ae3630
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/include/Hal8192CEHWImg.h
@@ -0,0 +1,85 @@
+extern u32 Rtl8192CEAGCTAB_1TArray[AGCTAB_1TArrayLength];
+
+#endif //__INC_HAL8192CE_FW_IMG_H
-diff --git a/drivers/net/wireless/rtl8192cu/include/Hal8192CPhyCfg.h b/drivers/net/wireless/rtl8192cu/include/Hal8192CPhyCfg.h
-new file mode 100644
-index 0000000..3afb292
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/include/Hal8192CPhyCfg.h
@@ -0,0 +1,428 @@
+
+#endif // __INC_HAL8192CPHYCFG_H
+
-diff --git a/drivers/net/wireless/rtl8192cu/include/Hal8192CPhyReg.h b/drivers/net/wireless/rtl8192cu/include/Hal8192CPhyReg.h
-new file mode 100644
-index 0000000..6364166
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/include/Hal8192CPhyReg.h
@@ -0,0 +1,1123 @@
+
+#endif //__INC_HAL8192SPHYREG_H
+
-diff --git a/drivers/net/wireless/rtl8192cu/include/Hal8192CUHWImg.h b/drivers/net/wireless/rtl8192cu/include/Hal8192CUHWImg.h
-new file mode 100644
-index 0000000..ba3c282
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/include/Hal8192CUHWImg.h
@@ -0,0 +1,105 @@
+extern u32 Rtl8192CUAGCTAB_1T_HPArray[AGCTAB_1T_HPArrayLength];
+
+#endif //__INC_HAL8192CU_FW_IMG_H
-diff --git a/drivers/net/wireless/rtl8192cu/include/Hal8192CUHWImg_wowlan.h b/drivers/net/wireless/rtl8192cu/include/Hal8192CUHWImg_wowlan.h
-new file mode 100644
-index 0000000..47d4d2f
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/include/Hal8192CUHWImg_wowlan.h
@@ -0,0 +1,34 @@
+
+#endif //__INC_HAL8192CU_FW_IMG_WOWLAN_H
+
-diff --git a/drivers/net/wireless/rtl8192cu/include/Hal8192DEHWImg.h b/drivers/net/wireless/rtl8192cu/include/Hal8192DEHWImg.h
-new file mode 100644
-index 0000000..0639775
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/include/Hal8192DEHWImg.h
@@ -0,0 +1,66 @@
+extern const u32 Rtl8192DEAGCTAB_1TArray[Rtl8192DEAGCTAB_1TArrayLength];
+
+#endif //__INC_HAL8192CU_FW_IMG_H
-diff --git a/drivers/net/wireless/rtl8192cu/include/Hal8192DPhyCfg.h b/drivers/net/wireless/rtl8192cu/include/Hal8192DPhyCfg.h
-new file mode 100644
-index 0000000..624fbda
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/include/Hal8192DPhyCfg.h
@@ -0,0 +1,528 @@
+
+#endif // __INC_HAL8192SPHYCFG_H
+
-diff --git a/drivers/net/wireless/rtl8192cu/include/Hal8192DPhyReg.h b/drivers/net/wireless/rtl8192cu/include/Hal8192DPhyReg.h
-new file mode 100644
-index 0000000..f28aa03
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/include/Hal8192DPhyReg.h
@@ -0,0 +1,1171 @@
+
+#endif //__INC_HAL8192SPHYREG_H
+
-diff --git a/drivers/net/wireless/rtl8192cu/include/Hal8192DUHWImg.h b/drivers/net/wireless/rtl8192cu/include/Hal8192DUHWImg.h
-new file mode 100644
-index 0000000..d6c66d9
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/include/Hal8192DUHWImg.h
@@ -0,0 +1,66 @@
+extern const u32 Rtl8192DUAGCTAB_1TArray[Rtl8192DUAGCTAB_1TArrayLength];
+
+#endif //__INC_HAL8192CU_FW_IMG_H
-diff --git a/drivers/net/wireless/rtl8192cu/include/Hal8192DUHWImg_wowlan.h b/drivers/net/wireless/rtl8192cu/include/Hal8192DUHWImg_wowlan.h
-new file mode 100644
-index 0000000..cc27a77
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/include/Hal8192DUHWImg_wowlan.h
@@ -0,0 +1,30 @@
+
+#endif //__INC_HAL8192DU_FW_IMG_WOWLAN_H
+
-diff --git a/drivers/net/wireless/rtl8192cu/include/HalPwrSeqCmd.h b/drivers/net/wireless/rtl8192cu/include/HalPwrSeqCmd.h
-new file mode 100644
-index 0000000..e5d151c
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/include/HalPwrSeqCmd.h
@@ -0,0 +1,137 @@
+ WLAN_PWR_CFG PwrCfgCmd[]);
+
+#endif
-diff --git a/drivers/net/wireless/rtl8192cu/include/autoconf.h b/drivers/net/wireless/rtl8192cu/include/autoconf.h
-new file mode 100644
-index 0000000..12294df
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/include/autoconf.h
@@ -0,0 +1,336 @@
+
+//turn off power tracking when traffic is busy
+//#define CONFIG_BUSY_TRAFFIC_SKIP_PWR_TRACK
-diff --git a/drivers/net/wireless/rtl8192cu/include/basic_types.h b/drivers/net/wireless/rtl8192cu/include/basic_types.h
-new file mode 100644
-index 0000000..f76e68f
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/include/basic_types.h
@@ -0,0 +1,321 @@
+
+#endif //__BASIC_TYPES_H__
+
-diff --git a/drivers/net/wireless/rtl8192cu/include/byteorder/big_endian.h b/drivers/net/wireless/rtl8192cu/include/byteorder/big_endian.h
-new file mode 100644
-index 0000000..eca68a6
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/include/byteorder/big_endian.h
@@ -0,0 +1,87 @@
+#include <byteorder/generic.h>
+
+#endif /* _LINUX_BYTEORDER_BIG_ENDIAN_H */
-diff --git a/drivers/net/wireless/rtl8192cu/include/byteorder/generic.h b/drivers/net/wireless/rtl8192cu/include/byteorder/generic.h
-new file mode 100644
-index 0000000..7c8d4d7
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/include/byteorder/generic.h
@@ -0,0 +1,212 @@
+#endif
+
+#endif /* _LINUX_BYTEORDER_GENERIC_H */
-diff --git a/drivers/net/wireless/rtl8192cu/include/byteorder/little_endian.h b/drivers/net/wireless/rtl8192cu/include/byteorder/little_endian.h
-new file mode 100644
-index 0000000..433045e
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/include/byteorder/little_endian.h
@@ -0,0 +1,89 @@
+#include <byteorder/generic.h>
+
+#endif /* _LINUX_BYTEORDER_LITTLE_ENDIAN_H */
-diff --git a/drivers/net/wireless/rtl8192cu/include/byteorder/swab.h b/drivers/net/wireless/rtl8192cu/include/byteorder/swab.h
-new file mode 100644
-index 0000000..a3ca9ea
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/include/byteorder/swab.h
@@ -0,0 +1,140 @@
+#endif
+
+#endif /* _LINUX_BYTEORDER_SWAB_H */
-diff --git a/drivers/net/wireless/rtl8192cu/include/byteorder/swabb.h b/drivers/net/wireless/rtl8192cu/include/byteorder/swabb.h
-new file mode 100644
-index 0000000..7e2a118
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/include/byteorder/swabb.h
@@ -0,0 +1,156 @@
+#endif
+
+#endif /* _LINUX_BYTEORDER_SWABB_H */
-diff --git a/drivers/net/wireless/rtl8192cu/include/circ_buf.h b/drivers/net/wireless/rtl8192cu/include/circ_buf.h
-new file mode 100644
-index 0000000..1bd4704
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/include/circ_buf.h
@@ -0,0 +1,27 @@
+#define CIRC_SPACE(head,tail,size) CIRC_CNT((tail),((head)+1),(size))
+
+#endif //_CIRC_BUF_H_
-diff --git a/drivers/net/wireless/rtl8192cu/include/cmd_osdep.h b/drivers/net/wireless/rtl8192cu/include/cmd_osdep.h
-new file mode 100644
-index 0000000..077efa7
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/include/cmd_osdep.h
@@ -0,0 +1,36 @@
+
+#endif
+
-diff --git a/drivers/net/wireless/rtl8192cu/include/drv_conf.h b/drivers/net/wireless/rtl8192cu/include/drv_conf.h
-new file mode 100644
-index 0000000..1317687
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/include/drv_conf.h
@@ -0,0 +1,78 @@
+
+#endif // __DRV_CONF_H__
+
-diff --git a/drivers/net/wireless/rtl8192cu/include/drv_types.h b/drivers/net/wireless/rtl8192cu/include/drv_types.h
-new file mode 100644
-index 0000000..0ac34f2
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/include/drv_types.h
@@ -0,0 +1,662 @@
+
+#endif //__DRV_TYPES_H__
+
-diff --git a/drivers/net/wireless/rtl8192cu/include/drv_types_ce.h b/drivers/net/wireless/rtl8192cu/include/drv_types_ce.h
-new file mode 100644
-index 0000000..be0459d
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/include/drv_types_ce.h
@@ -0,0 +1,92 @@
+
+
+#endif
-diff --git a/drivers/net/wireless/rtl8192cu/include/drv_types_linux.h b/drivers/net/wireless/rtl8192cu/include/drv_types_linux.h
-new file mode 100644
-index 0000000..db1c585
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/include/drv_types_linux.h
@@ -0,0 +1,25 @@
+
+#endif
+
-diff --git a/drivers/net/wireless/rtl8192cu/include/drv_types_sdio.h b/drivers/net/wireless/rtl8192cu/include/drv_types_sdio.h
-new file mode 100644
-index 0000000..fd467ca
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/include/drv_types_sdio.h
@@ -0,0 +1,70 @@
+
+#endif
+
-diff --git a/drivers/net/wireless/rtl8192cu/include/drv_types_xp.h b/drivers/net/wireless/rtl8192cu/include/drv_types_xp.h
-new file mode 100644
-index 0000000..2d51b1d
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/include/drv_types_xp.h
@@ -0,0 +1,95 @@
+
+#endif
+
-diff --git a/drivers/net/wireless/rtl8192cu/include/ethernet.h b/drivers/net/wireless/rtl8192cu/include/ethernet.h
-new file mode 100644
-index 0000000..36e29c0
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/include/ethernet.h
@@ -0,0 +1,41 @@
+
+
+#endif // #ifndef __INC_ETHERNET_H
-diff --git a/drivers/net/wireless/rtl8192cu/include/h2clbk.h b/drivers/net/wireless/rtl8192cu/include/h2clbk.h
-new file mode 100644
-index 0000000..359c9e7
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/include/h2clbk.h
@@ -0,0 +1,35 @@
+void _lbk_evt(IN PADAPTER Adapter);
+
+void h2c_event_callback(unsigned char *dev, unsigned char *pbuf);
-diff --git a/drivers/net/wireless/rtl8192cu/include/hal_com.h b/drivers/net/wireless/rtl8192cu/include/hal_com.h
-new file mode 100644
-index 0000000..42aae0e
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/include/hal_com.h
@@ -0,0 +1,146 @@
+
+#endif //__HAL_COMMON_H__
+
-diff --git a/drivers/net/wireless/rtl8192cu/include/hal_intf.h b/drivers/net/wireless/rtl8192cu/include/hal_intf.h
-new file mode 100644
-index 0000000..dd82662
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/include/hal_intf.h
@@ -0,0 +1,432 @@
+
+#endif //__HAL_INTF_H__
+
-diff --git a/drivers/net/wireless/rtl8192cu/include/ieee80211.h b/drivers/net/wireless/rtl8192cu/include/ieee80211.h
-new file mode 100644
-index 0000000..e283a5f
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/include/ieee80211.h
@@ -0,0 +1,1580 @@
+
+#endif /* IEEE80211_H */
+
-diff --git a/drivers/net/wireless/rtl8192cu/include/ieee80211_ext.h b/drivers/net/wireless/rtl8192cu/include/ieee80211_ext.h
-new file mode 100644
-index 0000000..3e55305
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/include/ieee80211_ext.h
@@ -0,0 +1,477 @@
+
+#endif
+
-diff --git a/drivers/net/wireless/rtl8192cu/include/if_ether.h b/drivers/net/wireless/rtl8192cu/include/if_ether.h
-new file mode 100644
-index 0000000..9e36d7f
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/include/if_ether.h
@@ -0,0 +1,112 @@
+
+
+#endif /* _LINUX_IF_ETHER_H */
-diff --git a/drivers/net/wireless/rtl8192cu/include/ioctl_cfg80211.h b/drivers/net/wireless/rtl8192cu/include/ioctl_cfg80211.h
-new file mode 100644
-index 0000000..ceb0db8
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/include/ioctl_cfg80211.h
@@ -0,0 +1,180 @@
+
+#endif //__IOCTL_CFG80211_H__
+
-diff --git a/drivers/net/wireless/rtl8192cu/include/ip.h b/drivers/net/wireless/rtl8192cu/include/ip.h
-new file mode 100644
-index 0000000..d7f723d
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/include/ip.h
@@ -0,0 +1,141 @@
+};
+
+#endif /* _LINUX_IP_H */
-diff --git a/drivers/net/wireless/rtl8192cu/include/linux/wireless.h b/drivers/net/wireless/rtl8192cu/include/linux/wireless.h
-new file mode 100644
-index 0000000..24a22d6
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/include/linux/wireless.h
@@ -0,0 +1,90 @@
+};
+
+#endif /* _LINUX_WIRELESS_H */
-diff --git a/drivers/net/wireless/rtl8192cu/include/mlme_osdep.h b/drivers/net/wireless/rtl8192cu/include/mlme_osdep.h
-new file mode 100644
-index 0000000..75754db
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/include/mlme_osdep.h
@@ -0,0 +1,40 @@
+
+#endif //_MLME_OSDEP_H_
+
-diff --git a/drivers/net/wireless/rtl8192cu/include/mp_custom_oid.h b/drivers/net/wireless/rtl8192cu/include/mp_custom_oid.h
-new file mode 100644
-index 0000000..5f86738
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/include/mp_custom_oid.h
@@ -0,0 +1,353 @@
+#define OID_RT_PRO_EFUSE_MAP 0xFF871217 //Q, S
+
+#endif //#ifndef __CUSTOM_OID_H
-diff --git a/drivers/net/wireless/rtl8192cu/include/nic_spec.h b/drivers/net/wireless/rtl8192cu/include/nic_spec.h
-new file mode 100644
-index 0000000..18e7b2c
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/include/nic_spec.h
@@ -0,0 +1,47 @@
+
+#endif // __RTL8711_SPEC_H__
+
-diff --git a/drivers/net/wireless/rtl8192cu/include/osdep_ce_service.h b/drivers/net/wireless/rtl8192cu/include/osdep_ce_service.h
-new file mode 100644
-index 0000000..e374077
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/include/osdep_ce_service.h
@@ -0,0 +1,171 @@
+}
+#endif
+
-diff --git a/drivers/net/wireless/rtl8192cu/include/osdep_intf.h b/drivers/net/wireless/rtl8192cu/include/osdep_intf.h
-new file mode 100644
-index 0000000..3cd1659
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/include/osdep_intf.h
@@ -0,0 +1,155 @@
+
+#endif //_OSDEP_INTF_H_
+
-diff --git a/drivers/net/wireless/rtl8192cu/include/osdep_service.h b/drivers/net/wireless/rtl8192cu/include/osdep_service.h
-new file mode 100644
-index 0000000..c5c465e
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/include/osdep_service.h
@@ -0,0 +1,1815 @@
+#endif
+
+
-diff --git a/drivers/net/wireless/rtl8192cu/include/pci_hal.h b/drivers/net/wireless/rtl8192cu/include/pci_hal.h
-new file mode 100644
-index 0000000..1ee0ee2
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/include/pci_hal.h
@@ -0,0 +1,168 @@
+
+#endif //__PCIE_HAL_H__
+
-diff --git a/drivers/net/wireless/rtl8192cu/include/pci_ops.h b/drivers/net/wireless/rtl8192cu/include/pci_ops.h
-new file mode 100644
-index 0000000..9404ff4
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/include/pci_ops.h
@@ -0,0 +1,60 @@
+#endif
+
+#endif
-diff --git a/drivers/net/wireless/rtl8192cu/include/pci_osintf.h b/drivers/net/wireless/rtl8192cu/include/pci_osintf.h
-new file mode 100644
-index 0000000..09715af
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/include/pci_osintf.h
@@ -0,0 +1,33 @@
+
+#endif
+
-diff --git a/drivers/net/wireless/rtl8192cu/include/recv_osdep.h b/drivers/net/wireless/rtl8192cu/include/recv_osdep.h
-new file mode 100644
-index 0000000..536ed31
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/include/recv_osdep.h
@@ -0,0 +1,58 @@
+
+#endif //
+
-diff --git a/drivers/net/wireless/rtl8192cu/include/rtl8192c_cmd.h b/drivers/net/wireless/rtl8192cu/include/rtl8192c_cmd.h
-new file mode 100644
-index 0000000..c54cc31
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/include/rtl8192c_cmd.h
@@ -0,0 +1,153 @@
+
+#endif // __RTL8192C_CMD_H_
+
-diff --git a/drivers/net/wireless/rtl8192cu/include/rtl8192c_dm.h b/drivers/net/wireless/rtl8192cu/include/rtl8192c_dm.h
-new file mode 100644
-index 0000000..9d06540
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/include/rtl8192c_dm.h
@@ -0,0 +1,516 @@
+
+#endif //__HAL8190PCIDM_H__
+
-diff --git a/drivers/net/wireless/rtl8192cu/include/rtl8192c_event.h b/drivers/net/wireless/rtl8192cu/include/rtl8192c_event.h
-new file mode 100644
-index 0000000..1013f74
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/include/rtl8192c_event.h
@@ -0,0 +1,28 @@
+#endif
+
+
-diff --git a/drivers/net/wireless/rtl8192cu/include/rtl8192c_hal.h b/drivers/net/wireless/rtl8192cu/include/rtl8192c_hal.h
-new file mode 100644
-index 0000000..3348971
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/include/rtl8192c_hal.h
@@ -0,0 +1,937 @@
+
+
+
-diff --git a/drivers/net/wireless/rtl8192cu/include/rtl8192c_led.h b/drivers/net/wireless/rtl8192cu/include/rtl8192c_led.h
-new file mode 100644
-index 0000000..1ccf935
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/include/rtl8192c_led.h
@@ -0,0 +1,42 @@
+
+#endif
+
-diff --git a/drivers/net/wireless/rtl8192cu/include/rtl8192c_recv.h b/drivers/net/wireless/rtl8192cu/include/rtl8192c_recv.h
-new file mode 100644
-index 0000000..d5656f5
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/include/rtl8192c_recv.h
@@ -0,0 +1,184 @@
+
+#endif
+
-diff --git a/drivers/net/wireless/rtl8192cu/include/rtl8192c_rf.h b/drivers/net/wireless/rtl8192cu/include/rtl8192c_rf.h
-new file mode 100644
-index 0000000..26c678a
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/include/rtl8192c_rf.h
@@ -0,0 +1,92 @@
+
+#endif/* End of HalRf.h */
+
-diff --git a/drivers/net/wireless/rtl8192cu/include/rtl8192c_spec.h b/drivers/net/wireless/rtl8192cu/include/rtl8192c_spec.h
-new file mode 100644
-index 0000000..8ff13a7
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/include/rtl8192c_spec.h
@@ -0,0 +1,1865 @@
+
+#endif
+
-diff --git a/drivers/net/wireless/rtl8192cu/include/rtl8192c_sreset.h b/drivers/net/wireless/rtl8192cu/include/rtl8192c_sreset.h
-new file mode 100644
-index 0000000..20e88b5
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/include/rtl8192c_sreset.h
@@ -0,0 +1,32 @@
+extern void rtl8192c_sreset_linked_status_check(_adapter *padapter);
+#endif
+#endif
-diff --git a/drivers/net/wireless/rtl8192cu/include/rtl8192c_xmit.h b/drivers/net/wireless/rtl8192cu/include/rtl8192c_xmit.h
-new file mode 100644
-index 0000000..7d2059d
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/include/rtl8192c_xmit.h
@@ -0,0 +1,129 @@
+
+#endif
+
-diff --git a/drivers/net/wireless/rtl8192cu/include/rtl8192d_cmd.h b/drivers/net/wireless/rtl8192cu/include/rtl8192d_cmd.h
-new file mode 100644
-index 0000000..ad7e783
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/include/rtl8192d_cmd.h
@@ -0,0 +1,142 @@
+#endif // __RTL8192D_CMD_H_
+
+
-diff --git a/drivers/net/wireless/rtl8192cu/include/rtl8192d_dm.h b/drivers/net/wireless/rtl8192cu/include/rtl8192d_dm.h
-new file mode 100644
-index 0000000..ab5e5f7
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/include/rtl8192d_dm.h
@@ -0,0 +1,420 @@
+VOID rtl8192d_dm_CheckTXPowerTracking(IN PADAPTER Adapter);
+
+#endif //__HAL8190PCIDM_H__
-diff --git a/drivers/net/wireless/rtl8192cu/include/rtl8192d_hal.h b/drivers/net/wireless/rtl8192cu/include/rtl8192d_hal.h
-new file mode 100644
-index 0000000..1ab5f98
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/include/rtl8192d_hal.h
@@ -0,0 +1,1126 @@
+
+#endif //end CONFIG_MP_INCLUDED
+
-diff --git a/drivers/net/wireless/rtl8192cu/include/rtl8192d_led.h b/drivers/net/wireless/rtl8192cu/include/rtl8192d_led.h
-new file mode 100644
-index 0000000..d736bda4
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/include/rtl8192d_led.h
@@ -0,0 +1,43 @@
+
+#endif
+
-diff --git a/drivers/net/wireless/rtl8192cu/include/rtl8192d_recv.h b/drivers/net/wireless/rtl8192cu/include/rtl8192d_recv.h
-new file mode 100644
-index 0000000..36cc232
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/include/rtl8192d_recv.h
@@ -0,0 +1,187 @@
+
+#endif
+
-diff --git a/drivers/net/wireless/rtl8192cu/include/rtl8192d_rf.h b/drivers/net/wireless/rtl8192cu/include/rtl8192d_rf.h
-new file mode 100644
-index 0000000..0b439a3
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/include/rtl8192d_rf.h
@@ -0,0 +1,97 @@
+
+#endif/* End of HalRf.h */
+
-diff --git a/drivers/net/wireless/rtl8192cu/include/rtl8192d_spec.h b/drivers/net/wireless/rtl8192cu/include/rtl8192d_spec.h
-new file mode 100644
-index 0000000..bef7184
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/include/rtl8192d_spec.h
@@ -0,0 +1,1841 @@
+
+#endif
+
-diff --git a/drivers/net/wireless/rtl8192cu/include/rtl8192d_xmit.h b/drivers/net/wireless/rtl8192cu/include/rtl8192d_xmit.h
-new file mode 100644
-index 0000000..d01fb4a
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/include/rtl8192d_xmit.h
@@ -0,0 +1,145 @@
+
+#endif
+
-diff --git a/drivers/net/wireless/rtl8192cu/include/rtw_android.h b/drivers/net/wireless/rtl8192cu/include/rtw_android.h
-new file mode 100644
-index 0000000..f9214c2
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/include/rtw_android.h
@@ -0,0 +1,90 @@
+
+#endif //__RTW_ANDROID_H__
+
-diff --git a/drivers/net/wireless/rtl8192cu/include/rtw_ap.h b/drivers/net/wireless/rtl8192cu/include/rtw_ap.h
-new file mode 100644
-index 0000000..42be4c6
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/include/rtw_ap.h
@@ -0,0 +1,64 @@
+
+#endif
+
-diff --git a/drivers/net/wireless/rtl8192cu/include/rtw_br_ext.h b/drivers/net/wireless/rtl8192cu/include/rtw_br_ext.h
-new file mode 100644
-index 0000000..9da3fdd
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/include/rtw_br_ext.h
@@ -0,0 +1,76 @@
+
+#endif // _RTW_BR_EXT_H_
+
-diff --git a/drivers/net/wireless/rtl8192cu/include/rtw_byteorder.h b/drivers/net/wireless/rtl8192cu/include/rtw_byteorder.h
-new file mode 100644
-index 0000000..0f06b7a
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/include/rtw_byteorder.h
@@ -0,0 +1,40 @@
+
+#endif /* _RTL871X_BYTEORDER_H_ */
+
-diff --git a/drivers/net/wireless/rtl8192cu/include/rtw_cmd.h b/drivers/net/wireless/rtl8192cu/include/rtw_cmd.h
-new file mode 100644
-index 0000000..ab115c5
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/include/rtw_cmd.h
@@ -0,0 +1,1167 @@
+
+#endif // _CMD_H_
+
-diff --git a/drivers/net/wireless/rtl8192cu/include/rtw_debug.h b/drivers/net/wireless/rtl8192cu/include/rtw_debug.h
-new file mode 100644
-index 0000000..0ccf220
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/include/rtw_debug.h
@@ -0,0 +1,538 @@
+
+#endif //__RTW_DEBUG_H__
+
-diff --git a/drivers/net/wireless/rtl8192cu/include/rtw_eeprom.h b/drivers/net/wireless/rtl8192cu/include/rtw_eeprom.h
-new file mode 100644
-index 0000000..ce834dd
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/include/rtw_eeprom.h
@@ -0,0 +1,152 @@
+#endif //PLATFORM_LINUX
+
+#endif //__RTL871X_EEPROM_H__
-diff --git a/drivers/net/wireless/rtl8192cu/include/rtw_efuse.h b/drivers/net/wireless/rtl8192cu/include/rtw_efuse.h
-new file mode 100644
-index 0000000..224aa4f
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/include/rtw_efuse.h
@@ -0,0 +1,124 @@
+
+#endif
+
-diff --git a/drivers/net/wireless/rtl8192cu/include/rtw_event.h b/drivers/net/wireless/rtl8192cu/include/rtw_event.h
-new file mode 100644
-index 0000000..4299ddc
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/include/rtw_event.h
@@ -0,0 +1,154 @@
+
+#endif // _WLANEVENT_H_
+
-diff --git a/drivers/net/wireless/rtl8192cu/include/rtw_ht.h b/drivers/net/wireless/rtl8192cu/include/rtw_ht.h
-new file mode 100644
-index 0000000..3cd904d
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/include/rtw_ht.h
@@ -0,0 +1,50 @@
+
+#endif //_RTL871X_HT_H_
+
-diff --git a/drivers/net/wireless/rtl8192cu/include/rtw_io.h b/drivers/net/wireless/rtl8192cu/include/rtw_io.h
-new file mode 100644
-index 0000000..c66845c
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/include/rtw_io.h
@@ -0,0 +1,504 @@
+*/
+
+#endif //_RTL8711_IO_H_
-diff --git a/drivers/net/wireless/rtl8192cu/include/rtw_ioctl.h b/drivers/net/wireless/rtl8192cu/include/rtw_ioctl.h
-new file mode 100644
-index 0000000..c4da301
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/include/rtw_ioctl.h
@@ -0,0 +1,269 @@
+
+#endif // #ifndef __INC_CEINFO_
+
-diff --git a/drivers/net/wireless/rtl8192cu/include/rtw_ioctl_query.h b/drivers/net/wireless/rtl8192cu/include/rtw_ioctl_query.h
-new file mode 100644
-index 0000000..5b6018a
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/include/rtw_ioctl_query.h
@@ -0,0 +1,36 @@
+
+#endif
+
-diff --git a/drivers/net/wireless/rtl8192cu/include/rtw_ioctl_rtl.h b/drivers/net/wireless/rtl8192cu/include/rtw_ioctl_rtl.h
-new file mode 100644
-index 0000000..3bff766
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/include/rtw_ioctl_rtl.h
@@ -0,0 +1,83 @@
+
+
+#endif
-diff --git a/drivers/net/wireless/rtl8192cu/include/rtw_ioctl_set.h b/drivers/net/wireless/rtl8192cu/include/rtw_ioctl_set.h
-new file mode 100644
-index 0000000..82f9810
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/include/rtw_ioctl_set.h
@@ -0,0 +1,79 @@
+
+#endif
+
-diff --git a/drivers/net/wireless/rtl8192cu/include/rtw_iol.h b/drivers/net/wireless/rtl8192cu/include/rtw_iol.h
-new file mode 100644
-index 0000000..45fa5a2
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/include/rtw_iol.h
@@ -0,0 +1,89 @@
+bool rtw_IOL_applied(ADAPTER *adapter);
+
+#endif //__RTW_IOL_H_
-diff --git a/drivers/net/wireless/rtl8192cu/include/rtw_led.h b/drivers/net/wireless/rtl8192cu/include/rtw_led.h
-new file mode 100644
-index 0000000..b5365ba
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/include/rtw_led.h
@@ -0,0 +1,217 @@
+
+#endif //__RTW_LED_H_
+
-diff --git a/drivers/net/wireless/rtl8192cu/include/rtw_mlme.h b/drivers/net/wireless/rtl8192cu/include/rtw_mlme.h
-new file mode 100644
-index 0000000..d9d6456
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/include/rtw_mlme.h
@@ -0,0 +1,844 @@
+#endif //CONFIG_INTEL_PROXIM
+#endif //__RTL871X_MLME_H_
+
-diff --git a/drivers/net/wireless/rtl8192cu/include/rtw_mlme_ext.h b/drivers/net/wireless/rtl8192cu/include/rtw_mlme_ext.h
-new file mode 100644
-index 0000000..5cddca4
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/include/rtw_mlme_ext.h
@@ -0,0 +1,963 @@
+
+#endif
+
-diff --git a/drivers/net/wireless/rtl8192cu/include/rtw_mp.h b/drivers/net/wireless/rtl8192cu/include/rtw_mp.h
-new file mode 100644
-index 0000000..0ebb1ba
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/include/rtw_mp.h
@@ -0,0 +1,712 @@
+
+#endif //_RTW_MP_H_
+
-diff --git a/drivers/net/wireless/rtl8192cu/include/rtw_mp_ioctl.h b/drivers/net/wireless/rtl8192cu/include/rtw_mp_ioctl.h
-new file mode 100644
-index 0000000..962bc38
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/include/rtw_mp_ioctl.h
@@ -0,0 +1,596 @@
+
+#endif
+
-diff --git a/drivers/net/wireless/rtl8192cu/include/rtw_mp_phy_regdef.h b/drivers/net/wireless/rtl8192cu/include/rtw_mp_phy_regdef.h
-new file mode 100644
-index 0000000..0b47cb5
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/include/rtw_mp_phy_regdef.h
@@ -0,0 +1,1097 @@
+
+#endif //__INC_HAL8192SPHYREG_H
+
-diff --git a/drivers/net/wireless/rtl8192cu/include/rtw_p2p.h b/drivers/net/wireless/rtl8192cu/include/rtw_p2p.h
-new file mode 100644
-index 0000000..4249bc9
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/include/rtw_p2p.h
@@ -0,0 +1,161 @@
+
+#endif
+
-diff --git a/drivers/net/wireless/rtl8192cu/include/rtw_pwrctrl.h b/drivers/net/wireless/rtl8192cu/include/rtw_pwrctrl.h
-new file mode 100644
-index 0000000..a4cb292
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/include/rtw_pwrctrl.h
@@ -0,0 +1,362 @@
+int rtw_pm_set_lps(_adapter *padapter, u8 mode);
+
+#endif //__RTL871X_PWRCTRL_H_
-diff --git a/drivers/net/wireless/rtl8192cu/include/rtw_qos.h b/drivers/net/wireless/rtl8192cu/include/rtw_qos.h
-new file mode 100644
-index 0000000..a359c5f
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/include/rtw_qos.h
@@ -0,0 +1,40 @@
+
+#endif //_RTL871X_QOS_H_
+
-diff --git a/drivers/net/wireless/rtl8192cu/include/rtw_recv.h b/drivers/net/wireless/rtl8192cu/include/rtw_recv.h
-new file mode 100644
-index 0000000..3a4b14b
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/include/rtw_recv.h
@@ -0,0 +1,731 @@
+
+#endif
+
-diff --git a/drivers/net/wireless/rtl8192cu/include/rtw_rf.h b/drivers/net/wireless/rtl8192cu/include/rtw_rf.h
-new file mode 100644
-index 0000000..697dd4e
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/include/rtw_rf.h
@@ -0,0 +1,152 @@
+
+#endif //_RTL8711_RF_H_
+
-diff --git a/drivers/net/wireless/rtl8192cu/include/rtw_security.h b/drivers/net/wireless/rtl8192cu/include/rtw_security.h
-new file mode 100644
-index 0000000..835677c3
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/include/rtw_security.h
@@ -0,0 +1,447 @@
+
+#endif //__RTL871X_SECURITY_H_
+
-diff --git a/drivers/net/wireless/rtl8192cu/include/rtw_sreset.h b/drivers/net/wireless/rtl8192cu/include/rtw_sreset.h
-new file mode 100644
-index 0000000..45dd2bf
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/include/rtw_sreset.h
@@ -0,0 +1,74 @@
+
+#endif
+
-diff --git a/drivers/net/wireless/rtl8192cu/include/rtw_tdls.h b/drivers/net/wireless/rtl8192cu/include/rtw_tdls.h
-new file mode 100644
-index 0000000..1005331
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/include/rtw_tdls.h
@@ -0,0 +1,143 @@
+
+#endif
+
-diff --git a/drivers/net/wireless/rtl8192cu/include/rtw_version.h b/drivers/net/wireless/rtl8192cu/include/rtw_version.h
-new file mode 100644
-index 0000000..4fb9dd4
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/include/rtw_version.h
@@ -0,0 +1 @@
+#define DRIVERVERSION "v4.0.2_9000.20130911"
-diff --git a/drivers/net/wireless/rtl8192cu/include/rtw_xmit.h b/drivers/net/wireless/rtl8192cu/include/rtw_xmit.h
-new file mode 100644
-index 0000000..f7eaf4a
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/include/rtw_xmit.h
@@ -0,0 +1,754 @@
+
+#endif //_RTL871X_XMIT_H_
+
-diff --git a/drivers/net/wireless/rtl8192cu/include/sta_info.h b/drivers/net/wireless/rtl8192cu/include/sta_info.h
-new file mode 100644
-index 0000000..75763db
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/include/sta_info.h
@@ -0,0 +1,432 @@
+
+#endif //_STA_INFO_H_
+
-diff --git a/drivers/net/wireless/rtl8192cu/include/usb_hal.h b/drivers/net/wireless/rtl8192cu/include/usb_hal.h
-new file mode 100644
-index 0000000..d765b82
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/include/usb_hal.h
@@ -0,0 +1,37 @@
+#endif //CONFIG_WOWLAN
+#endif //__USB_HAL_H__
+
-diff --git a/drivers/net/wireless/rtl8192cu/include/usb_ops.h b/drivers/net/wireless/rtl8192cu/include/usb_ops.h
-new file mode 100644
-index 0000000..8bbec2d
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/include/usb_ops.h
@@ -0,0 +1,110 @@
+
+#endif //__USB_OPS_H_
+
-diff --git a/drivers/net/wireless/rtl8192cu/include/usb_ops_linux.h b/drivers/net/wireless/rtl8192cu/include/usb_ops_linux.h
-new file mode 100644
-index 0000000..d418ba2
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/include/usb_ops_linux.h
@@ -0,0 +1,63 @@
+
+#endif
+
-diff --git a/drivers/net/wireless/rtl8192cu/include/usb_osintf.h b/drivers/net/wireless/rtl8192cu/include/usb_osintf.h
-new file mode 100644
-index 0000000..753013d
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/include/usb_osintf.h
@@ -0,0 +1,38 @@
+
+#endif
+
-diff --git a/drivers/net/wireless/rtl8192cu/include/usb_vendor_req.h b/drivers/net/wireless/rtl8192cu/include/usb_vendor_req.h
-new file mode 100644
-index 0000000..f33e982
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/include/usb_vendor_req.h
@@ -0,0 +1,59 @@
+//BOOLEAN CEusbGetDescriptorRequest(PCE_USB_DEVICE CEdevice, IN short urbLength, IN UCHAR DescriptorType, IN UCHAR Index, IN USHORT LanguageId, IN PVOID TransferBuffer, IN ULONG TransferBufferLength);
+
+#endif
-diff --git a/drivers/net/wireless/rtl8192cu/include/wifi.h b/drivers/net/wireless/rtl8192cu/include/wifi.h
-new file mode 100644
-index 0000000..0bb55bb
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/include/wifi.h
@@ -0,0 +1,1246 @@
+
+#endif // _WIFI_H_
+
-diff --git a/drivers/net/wireless/rtl8192cu/include/wlan_bssdef.h b/drivers/net/wireless/rtl8192cu/include/wlan_bssdef.h
-new file mode 100644
-index 0000000..1cf93dc
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/include/wlan_bssdef.h
@@ -0,0 +1,703 @@
+
+#endif //#ifndef WLAN_BSSDEF_H_
+
-diff --git a/drivers/net/wireless/rtl8192cu/include/xmit_osdep.h b/drivers/net/wireless/rtl8192cu/include/xmit_osdep.h
-new file mode 100644
-index 0000000..e5848ec
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/include/xmit_osdep.h
@@ -0,0 +1,95 @@
+
+#endif //__XMIT_OSDEP_H_
+
-diff --git a/drivers/net/wireless/rtl8192cu/os_dep/linux/ioctl_cfg80211.c b/drivers/net/wireless/rtl8192cu/os_dep/linux/ioctl_cfg80211.c
-new file mode 100644
-index 0000000..5975d1e
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/os_dep/linux/ioctl_cfg80211.c
@@ -0,0 +1,5489 @@
+
+#endif //CONFIG_IOCTL_CFG80211
+
-diff --git a/drivers/net/wireless/rtl8192cu/os_dep/linux/ioctl_linux.c b/drivers/net/wireless/rtl8192cu/os_dep/linux/ioctl_linux.c
-new file mode 100644
-index 0000000..9adbeaf
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/os_dep/linux/ioctl_linux.c
@@ -0,0 +1,11909 @@
+};
+#endif
+
-diff --git a/drivers/net/wireless/rtl8192cu/os_dep/linux/mlme_linux.c b/drivers/net/wireless/rtl8192cu/os_dep/linux/mlme_linux.c
-new file mode 100644
-index 0000000..6fc9f03
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/os_dep/linux/mlme_linux.c
@@ -0,0 +1,586 @@
+#endif
+#endif
+
-diff --git a/drivers/net/wireless/rtl8192cu/os_dep/linux/os_intfs.c b/drivers/net/wireless/rtl8192cu/os_dep/linux/os_intfs.c
-new file mode 100644
-index 0000000..82dee6d
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/os_dep/linux/os_intfs.c
@@ -0,0 +1,2749 @@
+ free_netdev(ndev);
+}
+
-diff --git a/drivers/net/wireless/rtl8192cu/os_dep/linux/pci_intf.c b/drivers/net/wireless/rtl8192cu/os_dep/linux/pci_intf.c
-new file mode 100644
-index 0000000..5bf576f
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/os_dep/linux/pci_intf.c
@@ -0,0 +1,1997 @@
+module_init(rtw_drv_entry);
+module_exit(rtw_drv_halt);
+
-diff --git a/drivers/net/wireless/rtl8192cu/os_dep/linux/pci_ops_linux.c b/drivers/net/wireless/rtl8192cu/os_dep/linux/pci_ops_linux.c
-new file mode 100644
-index 0000000..7d671df
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/os_dep/linux/pci_ops_linux.c
@@ -0,0 +1,24 @@
+
+
+
-diff --git a/drivers/net/wireless/rtl8192cu/os_dep/linux/recv_linux.c b/drivers/net/wireless/rtl8192cu/os_dep/linux/recv_linux.c
-new file mode 100644
-index 0000000..9c92019
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/os_dep/linux/recv_linux.c
@@ -0,0 +1,448 @@
+
+}
+
-diff --git a/drivers/net/wireless/rtl8192cu/os_dep/linux/rtw_android.c b/drivers/net/wireless/rtl8192cu/os_dep/linux/rtw_android.c
-new file mode 100644
-index 0000000..a4bb073
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/os_dep/linux/rtw_android.c
@@ -0,0 +1,839 @@
+}
+#endif /* defined(RTW_ENABLE_WIFI_CONTROL_FUNC) */
+
-diff --git a/drivers/net/wireless/rtl8192cu/os_dep/linux/usb_intf.c b/drivers/net/wireless/rtl8192cu/os_dep/linux/usb_intf.c
-new file mode 100644
-index 0000000..4c1089a
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/os_dep/linux/usb_intf.c
@@ -0,0 +1,1655 @@
+EXPORT_SYMBOL(rtw_usb_get_sw_pointer);
+#endif //CONFIG_INTEL_PROXIM
+
-diff --git a/drivers/net/wireless/rtl8192cu/os_dep/linux/usb_ops_linux.c b/drivers/net/wireless/rtl8192cu/os_dep/linux/usb_ops_linux.c
-new file mode 100644
-index 0000000..f54cfb4
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/os_dep/linux/usb_ops_linux.c
@@ -0,0 +1,649 @@
+ }
+}
+
-diff --git a/drivers/net/wireless/rtl8192cu/os_dep/linux/xmit_linux.c b/drivers/net/wireless/rtl8192cu/os_dep/linux/xmit_linux.c
-new file mode 100644
-index 0000000..9105e29
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/os_dep/linux/xmit_linux.c
@@ -0,0 +1,421 @@
+ return _rtw_xmit_entry(pkt, pnetdev);
+}
+
-diff --git a/drivers/net/wireless/rtl8192cu/os_dep/osdep_service.c b/drivers/net/wireless/rtl8192cu/os_dep/osdep_service.c
-new file mode 100644
-index 0000000..e73a068
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/os_dep/osdep_service.c
@@ -0,0 +1,2300 @@
+ rtw_mfree((u8*)cbuf, sizeof(*cbuf) + sizeof(void*)*cbuf->size);
+}
+
-diff --git a/drivers/net/wireless/rtl8192cu/runwpa b/drivers/net/wireless/rtl8192cu/runwpa
-new file mode 100755
-index 0000000..f825e8b
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/runwpa
@@ -0,0 +1,20 @@
+fi
+
+
-diff --git a/drivers/net/wireless/rtl8192cu/wlan0dhcp b/drivers/net/wireless/rtl8192cu/wlan0dhcp
-new file mode 100755
-index 0000000..6043382
--- /dev/null
+++ b/drivers/net/wireless/rtl8192cu/wlan0dhcp
@@ -0,0 +1,16 @@
+
+echo "get ip: $var1"
+
---
-1.9.1
-
drivers/net/wireless/rtl8192cu/os_dep/linux/usb_intf.c | 1 +
5 files changed, 23 insertions(+), 3 deletions(-)
-diff --git a/drivers/net/wireless/rtl8192cu/Kconfig b/drivers/net/wireless/rtl8192cu/Kconfig
-index bee5ed6..ef46361 100644
--- a/drivers/net/wireless/rtl8192cu/Kconfig
+++ b/drivers/net/wireless/rtl8192cu/Kconfig
@@ -1,6 +1,8 @@
- Help message of RTL8192CU
+ Enable wireless network adapters based on Realtek RTL8192C chipset family, such as EDUP nano series
-diff --git a/drivers/net/wireless/rtl8192cu/Makefile b/drivers/net/wireless/rtl8192cu/Makefile
-index c399011..f85c59f 100644
--- a/drivers/net/wireless/rtl8192cu/Makefile
+++ b/drivers/net/wireless/rtl8192cu/Makefile
@@ -38,7 +38,7 @@ CONFIG_RTL8192CU_REDEFINE_1X1 = n
ifneq ($(USER_MODULE_NAME),)
MODULE_NAME := $(USER_MODULE_NAME)
endif
-diff --git a/drivers/net/wireless/rtl8192cu/include/autoconf.h b/drivers/net/wireless/rtl8192cu/include/autoconf.h
-index 12294df..1341ff0 100644
--- a/drivers/net/wireless/rtl8192cu/include/autoconf.h
+++ b/drivers/net/wireless/rtl8192cu/include/autoconf.h
@@ -296,7 +296,7 @@
#define CONFIG_PROC_DEBUG 1
-diff --git a/drivers/net/wireless/rtl8192cu/os_dep/linux/os_intfs.c b/drivers/net/wireless/rtl8192cu/os_dep/linux/os_intfs.c
-index 82dee6d..b0bf0e9 100644
--- a/drivers/net/wireless/rtl8192cu/os_dep/linux/os_intfs.c
+++ b/drivers/net/wireless/rtl8192cu/os_dep/linux/os_intfs.c
@@ -277,6 +277,18 @@ static int rtw_proc_cnt = 0;
void rtw_proc_init_one(struct net_device *dev)
{
struct proc_dir_entry *dir_dev = NULL;
-@@ -751,6 +763,7 @@ void rtw_proc_remove_one(struct net_device *dev)
+@@ -751,6 +763,7 @@ void rtw_proc_remove_one(struct net_devi
}
}
}
#endif
uint loadparam( _adapter *padapter, _nic_hdl pnetdev);
-diff --git a/drivers/net/wireless/rtl8192cu/os_dep/linux/usb_intf.c b/drivers/net/wireless/rtl8192cu/os_dep/linux/usb_intf.c
-index 4c1089a..baccb59 100644
--- a/drivers/net/wireless/rtl8192cu/os_dep/linux/usb_intf.c
+++ b/drivers/net/wireless/rtl8192cu/os_dep/linux/usb_intf.c
-@@ -138,6 +138,7 @@ static void rtw_dev_remove(struct usb_interface *pusb_intf);
+@@ -138,6 +138,7 @@ static void rtw_dev_remove(struct usb_in
{USB_DEVICE(0x2001, 0x3307)},/* D-Link - Cameo */ \
{USB_DEVICE(0x2001, 0x330A)},/* D-Link - Alpha */ \
{USB_DEVICE(0x2001, 0x3309)},/* D-Link - Alpha */ \
{USB_DEVICE(0x0586, 0x341F)},/* Zyxel - Abocom */ \
{USB_DEVICE(0x7392, 0x7822)},/* Edimax - Edimax */ \
{USB_DEVICE(0x2019, 0xAB2B)},/* Planex - Abocom */ \
---
-1.9.1
-
drivers/media/usb/dvb-usb-v2/rtl28xxu.c | 4 ++++
1 file changed, 4 insertions(+)
-diff --git a/drivers/media/usb/dvb-usb-v2/rtl28xxu.c b/drivers/media/usb/dvb-usb-v2/rtl28xxu.c
-index fd1312d..54740d0 100644
--- a/drivers/media/usb/dvb-usb-v2/rtl28xxu.c
+++ b/drivers/media/usb/dvb-usb-v2/rtl28xxu.c
-@@ -1429,6 +1429,10 @@ static const struct usb_device_id rtl28xxu_id_table[] = {
+@@ -1429,6 +1429,10 @@ static const struct usb_device_id rtl28x
&rtl2832u_props, "Compro VideoMate U620F", NULL) },
{ DVB_USB_DEVICE(USB_VID_KWORLD_2, 0xd394,
&rtl2832u_props, "MaxMedia HU394-T", NULL) },
{ DVB_USB_DEVICE(USB_VID_LEADTEK, 0x6a03,
&rtl2832u_props, "Leadtek WinFast DTV Dongle mini", NULL) },
{ DVB_USB_DEVICE(USB_VID_GTEK, USB_PID_CPYTO_REDI_PC50A,
---
-1.9.1
-
arch/arm/configs/bcmrpi_defconfig | 755 ++++++++++++++++++++++++++++++++------
1 file changed, 649 insertions(+), 106 deletions(-)
-diff --git a/arch/arm/configs/bcmrpi_defconfig b/arch/arm/configs/bcmrpi_defconfig
-index 31f5afaa..78d789c 100644
--- a/arch/arm/configs/bcmrpi_defconfig
+++ b/arch/arm/configs/bcmrpi_defconfig
@@ -1,11 +1,17 @@
# CONFIG_CRYPTO_ANSI_CPRNG is not set
# CONFIG_CRYPTO_HW is not set
CONFIG_CRC_ITU_T=y
---
-1.9.1
-
drivers/video/cfbimgblt.c | 152 ++++++++++++++++++++++++++++++++++++++++++++--
1 file changed, 147 insertions(+), 5 deletions(-)
-diff --git a/drivers/video/cfbimgblt.c b/drivers/video/cfbimgblt.c
-index a2bb276..436494f 100644
--- a/drivers/video/cfbimgblt.c
+++ b/drivers/video/cfbimgblt.c
@@ -28,6 +28,11 @@
*/
#include <linux/module.h>
#include <linux/string.h>
-@@ -262,6 +267,133 @@ static inline void fast_imageblit(const struct fb_image *image, struct fb_info *
+@@ -262,6 +267,133 @@ static inline void fast_imageblit(const
}
}
void cfb_imageblit(struct fb_info *p, const struct fb_image *image)
{
u32 fgcolor, bgcolor, start_index, bitstart, pitch_index = 0;
-@@ -294,11 +426,21 @@ void cfb_imageblit(struct fb_info *p, const struct fb_image *image)
+@@ -294,11 +426,21 @@ void cfb_imageblit(struct fb_info *p, co
bgcolor = image->bg_color;
}
slow_imageblit(image, p, dst1, fgcolor, bgcolor,
start_index, pitch_index);
} else
---
-1.9.1
-
include/uapi/linux/fb.h | 5 +++++
2 files changed, 35 insertions(+)
-diff --git a/drivers/video/fbmem.c b/drivers/video/fbmem.c
-index 7309ac7..46984cc 100644
--- a/drivers/video/fbmem.c
+++ b/drivers/video/fbmem.c
-@@ -1083,6 +1083,25 @@ fb_blank(struct fb_info *info, int blank)
+@@ -1083,6 +1083,25 @@ fb_blank(struct fb_info *info, int blank
}
EXPORT_SYMBOL(fb_blank);
static long do_fb_ioctl(struct fb_info *info, unsigned int cmd,
unsigned long arg)
{
-@@ -1093,6 +1112,7 @@ static long do_fb_ioctl(struct fb_info *info, unsigned int cmd,
+@@ -1093,6 +1112,7 @@ static long do_fb_ioctl(struct fb_info *
struct fb_cmap cmap_from;
struct fb_cmap_user cmap;
struct fb_event event;
void __user *argp = (void __user *)arg;
long ret = 0;
-@@ -1210,6 +1230,15 @@ static long do_fb_ioctl(struct fb_info *info, unsigned int cmd,
+@@ -1210,6 +1230,15 @@ static long do_fb_ioctl(struct fb_info *
unlock_fb_info(info);
console_unlock();
break;
default:
if (!lock_fb_info(info))
return -ENODEV;
-@@ -1364,6 +1393,7 @@ static long fb_compat_ioctl(struct file *file, unsigned int cmd,
+@@ -1364,6 +1393,7 @@ static long fb_compat_ioctl(struct file
case FBIOPAN_DISPLAY:
case FBIOGET_CON2FBMAP:
case FBIOPUT_CON2FBMAP:
arg = (unsigned long) compat_ptr(arg);
case FBIOBLANK:
ret = do_fb_ioctl(info, cmd, arg);
-diff --git a/include/uapi/linux/fb.h b/include/uapi/linux/fb.h
-index fb795c3..fa72af0 100644
--- a/include/uapi/linux/fb.h
+++ b/include/uapi/linux/fb.h
@@ -34,6 +34,11 @@
#define FB_TYPE_PACKED_PIXELS 0 /* Packed Pixels */
#define FB_TYPE_PLANES 1 /* Non interleaved planes */
---
-1.9.1
-
drivers/video/bcm2708_fb.c | 273 ++++++++++++++++++++++++++++++-
3 files changed, 278 insertions(+), 5 deletions(-)
-diff --git a/arch/arm/mach-bcm2708/dma.c b/arch/arm/mach-bcm2708/dma.c
-index 51d147a..1da2413 100644
--- a/arch/arm/mach-bcm2708/dma.c
+++ b/arch/arm/mach-bcm2708/dma.c
-@@ -83,6 +83,14 @@ extern void bcm_dma_wait_idle(void __iomem *dma_chan_base)
+@@ -83,6 +83,14 @@ extern void bcm_dma_wait_idle(void __iom
EXPORT_SYMBOL_GPL(bcm_dma_start);
/* Complete an ongoing DMA (assuming its results are to be ignored)
Does nothing if there is no DMA in progress.
This routine waits for the current AXI transfer to complete before
-diff --git a/arch/arm/mach-bcm2708/include/mach/dma.h b/arch/arm/mach-bcm2708/include/mach/dma.h
-index ac7a4a0..6d2f9a0 100644
--- a/arch/arm/mach-bcm2708/include/mach/dma.h
+++ b/arch/arm/mach-bcm2708/include/mach/dma.h
@@ -62,11 +62,13 @@ struct bcm2708_dma_cb {
extern int /*rc*/ bcm_dma_abort(void __iomem *dma_chan_base);
/* When listing features we can ask for when allocating DMA channels give
-diff --git a/drivers/video/bcm2708_fb.c b/drivers/video/bcm2708_fb.c
-index 54cd760..798eb52 100644
--- a/drivers/video/bcm2708_fb.c
+++ b/drivers/video/bcm2708_fb.c
@@ -21,13 +21,16 @@
#include <mach/platform.h>
#include <mach/vcio.h>
-@@ -51,6 +54,10 @@ static int fbheight = 480; /* module parameter */
+@@ -51,6 +54,10 @@ static int fbheight = 480; /* module par
static int fbdepth = 16; /* module parameter */
static int fbswap = 0; /* module parameter */
static int bcm2708_fb_set_bitfields(struct fb_var_screeninfo *var)
{
int ret = 0;
-@@ -322,11 +386,148 @@ static void bcm2708_fb_fillrect(struct fb_info *info,
+@@ -322,11 +386,148 @@ static void bcm2708_fb_fillrect(struct f
cfb_fillrect(info, rect);
}
}
static void bcm2708_fb_imageblit(struct fb_info *info,
-@@ -336,6 +537,24 @@ static void bcm2708_fb_imageblit(struct fb_info *info,
+@@ -336,6 +537,24 @@ static void bcm2708_fb_imageblit(struct
cfb_imageblit(info, image);
}
static struct fb_ops bcm2708_fb_ops = {
.owner = THIS_MODULE,
.fb_check_var = bcm2708_fb_check_var,
-@@ -365,7 +584,7 @@ static int bcm2708_fb_register(struct bcm2708_fb *fb)
+@@ -365,7 +584,7 @@ static int bcm2708_fb_register(struct bc
fb->dma = dma;
}
fb->fb.fbops = &bcm2708_fb_ops;
fb->fb.pseudo_palette = fb->cmap;
strncpy(fb->fb.fix.id, bcm2708_name, sizeof(fb->fb.fix.id));
-@@ -396,6 +615,7 @@ static int bcm2708_fb_register(struct bcm2708_fb *fb)
+@@ -396,6 +615,7 @@ static int bcm2708_fb_register(struct bc
fb->fb.monspecs.dclkmax = 100000000;
bcm2708_fb_set_bitfields(&fb->fb.var);
/*
* Allocate colourmap.
-@@ -421,14 +641,45 @@ static int bcm2708_fb_probe(struct platform_device *dev)
+@@ -421,14 +641,45 @@ static int bcm2708_fb_probe(struct platf
struct bcm2708_fb *fb;
int ret;
fb->dev = dev;
-@@ -438,6 +689,11 @@ static int bcm2708_fb_probe(struct platform_device *dev)
+@@ -438,6 +689,11 @@ static int bcm2708_fb_probe(struct platf
goto out;
}
kfree(fb);
free_region:
dev_err(&dev->dev, "probe failed, err %d\n", ret);
-@@ -455,8 +711,15 @@ static int bcm2708_fb_remove(struct platform_device *dev)
+@@ -455,8 +711,15 @@ static int bcm2708_fb_remove(struct plat
iounmap(fb->fb.screen_base);
unregister_framebuffer(&fb->fb);
kfree(fb);
return 0;
---
-1.9.1
-
mm/memcontrol.c | 1 +
3 files changed, 29 insertions(+)
-diff --git a/arch/arm/configs/bcmrpi_defconfig b/arch/arm/configs/bcmrpi_defconfig
-index 78d789c..e89e430 100644
--- a/arch/arm/configs/bcmrpi_defconfig
+++ b/arch/arm/configs/bcmrpi_defconfig
@@ -18,6 +18,7 @@ CONFIG_CGROUP_FREEZER=y
CONFIG_BLK_CGROUP=y
CONFIG_NAMESPACES=y
CONFIG_SCHED_AUTOGROUP=y
-diff --git a/kernel/cgroup.c b/kernel/cgroup.c
-index 0c753dd..a18b46e 100644
--- a/kernel/cgroup.c
+++ b/kernel/cgroup.c
-@@ -5252,6 +5252,33 @@ static int __init cgroup_disable(char *str)
+@@ -5251,6 +5251,33 @@ static int __init cgroup_disable(char *s
}
__setup("cgroup_disable=", cgroup_disable);
/**
* css_from_dir - get corresponding css from the dentry of a cgroup dir
* @dentry: directory dentry of interest
-diff --git a/mm/memcontrol.c b/mm/memcontrol.c
-index 9b35da2..a9891cc 100644
--- a/mm/memcontrol.c
+++ b/mm/memcontrol.c
-@@ -7289,6 +7289,7 @@ struct cgroup_subsys mem_cgroup_subsys = {
+@@ -7316,6 +7316,7 @@ struct cgroup_subsys mem_cgroup_subsys =
.bind = mem_cgroup_bind,
.base_cftypes = mem_cgroup_files,
.early_init = 0,
};
#ifdef CONFIG_MEMCG_SWAP
---
-1.9.1
-
create mode 100755 drivers/usb/host/dwc_otg/dwc_otg_mphi_fix.c
create mode 100755 drivers/usb/host/dwc_otg/dwc_otg_mphi_fix.h
-diff --git a/arch/arm/Kconfig b/arch/arm/Kconfig
-index be8a752..7cdab14 100644
--- a/arch/arm/Kconfig
+++ b/arch/arm/Kconfig
@@ -394,6 +394,7 @@ config ARCH_BCM2708
help
This enables support for Broadcom BCM2708 boards.
-diff --git a/arch/arm/include/asm/irqflags.h b/arch/arm/include/asm/irqflags.h
-index 3b763d6..5770408 100644
--- a/arch/arm/include/asm/irqflags.h
+++ b/arch/arm/include/asm/irqflags.h
-@@ -145,12 +145,22 @@ static inline unsigned long arch_local_save_flags(void)
+@@ -145,12 +145,22 @@ static inline unsigned long arch_local_s
}
/*
:
: "r" (flags)
: "memory", "cc");
-diff --git a/arch/arm/kernel/fiqasm.S b/arch/arm/kernel/fiqasm.S
-index 207f9d6..5233d54 100644
--- a/arch/arm/kernel/fiqasm.S
+++ b/arch/arm/kernel/fiqasm.S
@@ -47,3 +47,7 @@ ENTRY(__get_fiq_regs)
+ENTRY(__FIQ_Branch)
+ mov pc, r8
+ENDPROC(__FIQ_Branch)
-diff --git a/arch/arm/mach-bcm2708/armctrl.c b/arch/arm/mach-bcm2708/armctrl.c
-index da18725..274aa30 100644
--- a/arch/arm/mach-bcm2708/armctrl.c
+++ b/arch/arm/mach-bcm2708/armctrl.c
-@@ -52,8 +52,12 @@ static void armctrl_mask_irq(struct irq_data *d)
+@@ -52,8 +52,12 @@ static void armctrl_mask_irq(struct irq_
0
};
}
static void armctrl_unmask_irq(struct irq_data *d)
-@@ -65,8 +69,14 @@ static void armctrl_unmask_irq(struct irq_data *d)
+@@ -65,8 +69,14 @@ static void armctrl_unmask_irq(struct ir
0
};
}
#if defined(CONFIG_PM)
-@@ -204,5 +214,6 @@ int __init armctrl_init(void __iomem * base, unsigned int irq_start,
+@@ -204,5 +214,6 @@ int __init armctrl_init(void __iomem * b
}
armctrl_pm_register(base, irq_start, resume_sources);
+ init_FIQ(FIQ_START);
return 0;
}
-diff --git a/arch/arm/mach-bcm2708/bcm2708.c b/arch/arm/mach-bcm2708/bcm2708.c
-index 221d145..47a66f8 100644
--- a/arch/arm/mach-bcm2708/bcm2708.c
+++ b/arch/arm/mach-bcm2708/bcm2708.c
-@@ -321,12 +321,32 @@ static struct resource bcm2708_usb_resources[] = {
+@@ -321,12 +321,32 @@ static struct resource bcm2708_usb_resou
.flags = IORESOURCE_MEM,
},
[1] = {
bcm_register_device(&bcm2708_usb_device);
bcm_register_device(&bcm2708_uart1_device);
bcm_register_device(&bcm2708_powerman_device);
-diff --git a/arch/arm/mach-bcm2708/include/mach/irqs.h b/arch/arm/mach-bcm2708/include/mach/irqs.h
-index faf5d1a..4299054 100644
--- a/arch/arm/mach-bcm2708/include/mach/irqs.h
+++ b/arch/arm/mach-bcm2708/include/mach/irqs.h
@@ -106,89 +106,92 @@
+#define NR_IRQS (HARD_IRQS+FIQ_IRQS+GPIO_IRQS+SPARE_IRQS)
#endif /* _BCM2708_IRQS_H_ */
-diff --git a/arch/arm/mach-bcm2708/include/mach/platform.h b/arch/arm/mach-bcm2708/include/mach/platform.h
-index f4bb733..992a630 100644
--- a/arch/arm/mach-bcm2708/include/mach/platform.h
+++ b/arch/arm/mach-bcm2708/include/mach/platform.h
@@ -56,7 +56,9 @@
#define DMA_BASE (BCM2708_PERI_BASE + 0x7000) /* DMA controller */
#define ARM_BASE (BCM2708_PERI_BASE + 0xB000) /* BCM2708 ARM control block */
#define PM_BASE (BCM2708_PERI_BASE + 0x100000) /* Power Management, Reset controller and Watchdog registers */
-diff --git a/drivers/usb/host/dwc_common_port/dwc_common_linux.c b/drivers/usb/host/dwc_common_port/dwc_common_linux.c
-index 440bcfc..6d01261 100644
--- a/drivers/usb/host/dwc_common_port/dwc_common_linux.c
+++ b/drivers/usb/host/dwc_common_port/dwc_common_linux.c
-@@ -580,7 +580,13 @@ void DWC_WRITE_REG64(uint64_t volatile *reg, uint64_t value)
+@@ -580,7 +580,13 @@ void DWC_WRITE_REG64(uint64_t volatile *
void DWC_MODIFY_REG32(uint32_t volatile *reg, uint32_t clear_mask, uint32_t set_mask)
{
}
#if 0
-@@ -991,6 +997,11 @@ void DWC_TASK_SCHEDULE(dwc_tasklet_t *task)
+@@ -991,6 +997,11 @@ void DWC_TASK_SCHEDULE(dwc_tasklet_t *ta
tasklet_schedule(&task->t);
}
/* workqueues
- run in process context (can sleep)
-diff --git a/drivers/usb/host/dwc_common_port/dwc_list.h b/drivers/usb/host/dwc_common_port/dwc_list.h
-index 89cc325..4ce560d 100644
--- a/drivers/usb/host/dwc_common_port/dwc_list.h
+++ b/drivers/usb/host/dwc_common_port/dwc_list.h
@@ -384,17 +384,17 @@ struct { \
/*
* Tail queue functions.
-diff --git a/drivers/usb/host/dwc_common_port/dwc_os.h b/drivers/usb/host/dwc_common_port/dwc_os.h
-index 9ffe929..09ed244 100644
--- a/drivers/usb/host/dwc_common_port/dwc_os.h
+++ b/drivers/usb/host/dwc_common_port/dwc_os.h
-@@ -981,6 +981,8 @@ extern void DWC_TASK_FREE(dwc_tasklet_t *task);
+@@ -981,6 +981,8 @@ extern void DWC_TASK_FREE(dwc_tasklet_t
extern void DWC_TASK_SCHEDULE(dwc_tasklet_t *task);
#define dwc_task_schedule DWC_TASK_SCHEDULE
/** @name Timer
*
-diff --git a/drivers/usb/host/dwc_otg/Makefile b/drivers/usb/host/dwc_otg/Makefile
-index 236c47c..a56f193 100644
--- a/drivers/usb/host/dwc_otg/Makefile
+++ b/drivers/usb/host/dwc_otg/Makefile
-@@ -36,6 +36,7 @@ dwc_otg-objs += dwc_otg_cil.o dwc_otg_cil_intr.o
+@@ -36,6 +36,7 @@ dwc_otg-objs += dwc_otg_cil.o dwc_otg_ci
dwc_otg-objs += dwc_otg_pcd_linux.o dwc_otg_pcd.o dwc_otg_pcd_intr.o
dwc_otg-objs += dwc_otg_hcd.o dwc_otg_hcd_linux.o dwc_otg_hcd_intr.o dwc_otg_hcd_queue.o dwc_otg_hcd_ddma.o
dwc_otg-objs += dwc_otg_adp.o
ifneq ($(CFI),)
dwc_otg-objs += dwc_otg_cfi.o
endif
-diff --git a/drivers/usb/host/dwc_otg/dwc_otg_attr.c b/drivers/usb/host/dwc_otg/dwc_otg_attr.c
-index fab2961..9da0c92 100644
--- a/drivers/usb/host/dwc_otg/dwc_otg_attr.c
+++ b/drivers/usb/host/dwc_otg/dwc_otg_attr.c
-@@ -909,7 +909,7 @@ static ssize_t regdump_show(struct device *_dev,
+@@ -909,7 +909,7 @@ static ssize_t regdump_show(struct devic
return sprintf(buf, "Register Dump\n");
}
/**
* Dump global registers and either host or device registers (depending on the
-@@ -920,12 +920,12 @@ static ssize_t spramdump_show(struct device *_dev,
+@@ -920,12 +920,12 @@ static ssize_t spramdump_show(struct dev
{
dwc_otg_device_t *otg_dev = dwc_otg_drvdev(_dev);
/**
* Dump the current hcd state.
-@@ -940,7 +940,7 @@ static ssize_t hcddump_show(struct device *_dev,
+@@ -940,7 +940,7 @@ static ssize_t hcddump_show(struct devic
return sprintf(buf, "HCD Dump\n");
}
/**
* Dump the average frame remaining at SOF. This can be used to
-@@ -958,7 +958,7 @@ static ssize_t hcd_frrem_show(struct device *_dev,
+@@ -958,7 +958,7 @@ static ssize_t hcd_frrem_show(struct dev
return sprintf(buf, "HCD Dump Frame Remaining\n");
}
/**
* Displays the time required to read the GNPTXFSIZ register many times (the
-@@ -986,7 +986,7 @@ static ssize_t rd_reg_test_show(struct device *_dev,
+@@ -986,7 +986,7 @@ static ssize_t rd_reg_test_show(struct d
RW_REG_COUNT, time * MSEC_PER_JIFFIE, time);
}
/**
* Displays the time required to write the GNPTXFSIZ register many times (the
-@@ -1014,7 +1014,7 @@ static ssize_t wr_reg_test_show(struct device *_dev,
+@@ -1014,7 +1014,7 @@ static ssize_t wr_reg_test_show(struct d
RW_REG_COUNT, time * MSEC_PER_JIFFIE, time);
}
#ifdef CONFIG_USB_DWC_OTG_LPM
-diff --git a/drivers/usb/host/dwc_otg/dwc_otg_cil_intr.c b/drivers/usb/host/dwc_otg/dwc_otg_cil_intr.c
-index 59fc862..2f8b3bd 100644
--- a/drivers/usb/host/dwc_otg/dwc_otg_cil_intr.c
+++ b/drivers/usb/host/dwc_otg/dwc_otg_cil_intr.c
@@ -45,6 +45,7 @@
#ifdef DEBUG
inline const char *op_state_str(dwc_otg_core_if_t * core_if)
-@@ -1318,7 +1319,7 @@ static int32_t dwc_otg_handle_lpm_intr(dwc_otg_core_if_t * core_if)
+@@ -1318,7 +1319,7 @@ static int32_t dwc_otg_handle_lpm_intr(d
/**
* This function returns the Core Interrupt register.
*/
{
gahbcfg_data_t gahbcfg = {.d32 = 0 };
gintsts_data_t gintsts;
-@@ -1335,26 +1336,45 @@ static inline uint32_t dwc_otg_read_common_intr(dwc_otg_core_if_t * core_if)
+@@ -1335,26 +1336,45 @@ static inline uint32_t dwc_otg_read_comm
gintmsk_common.b.lpmtranrcvd = 1;
#endif
gintmsk_common.b.restoredone = 1;
}
-@@ -1386,6 +1406,7 @@ int32_t dwc_otg_handle_common_intr(void *dev)
+@@ -1386,6 +1406,7 @@ int32_t dwc_otg_handle_common_intr(void
{
int retval = 0;
gintsts_data_t gintsts;
gpwrdn_data_t gpwrdn = {.d32 = 0 };
dwc_otg_device_t *otg_dev = dev;
dwc_otg_core_if_t *core_if = otg_dev->core_if;
-@@ -1407,7 +1428,7 @@ int32_t dwc_otg_handle_common_intr(void *dev)
+@@ -1407,7 +1428,7 @@ int32_t dwc_otg_handle_common_intr(void
}
if (core_if->hibernation_suspend <= 0) {
if (gintsts.b.modemismatch) {
retval |= dwc_otg_handle_mode_mismatch_intr(core_if);
-@@ -1504,8 +1525,12 @@ int32_t dwc_otg_handle_common_intr(void *dev)
+@@ -1504,8 +1525,12 @@ int32_t dwc_otg_handle_common_intr(void
gintsts.b.portintr = 1;
DWC_WRITE_REG32(&core_if->core_global_regs->gintsts,gintsts.d32);
retval |= 1;
} else {
DWC_DEBUGPL(DBG_ANY, "gpwrdn=%08x\n", gpwrdn.d32);
-diff --git a/drivers/usb/host/dwc_otg/dwc_otg_dbg.h b/drivers/usb/host/dwc_otg/dwc_otg_dbg.h
-index 8900318..ccc24e0 100644
--- a/drivers/usb/host/dwc_otg/dwc_otg_dbg.h
+++ b/drivers/usb/host/dwc_otg/dwc_otg_dbg.h
-@@ -49,6 +49,7 @@ static inline uint32_t SET_DEBUG_LEVEL(const uint32_t new)
+@@ -49,6 +49,7 @@ static inline uint32_t SET_DEBUG_LEVEL(c
return old;
}
/** When debug level has the DBG_CIL bit set, display CIL Debug messages. */
#define DBG_CIL (0x2)
/** When debug level has the DBG_CILV bit set, display CIL Verbose debug
-diff --git a/drivers/usb/host/dwc_otg/dwc_otg_driver.c b/drivers/usb/host/dwc_otg/dwc_otg_driver.c
-index ac2c846..f06c3d22 100644
--- a/drivers/usb/host/dwc_otg/dwc_otg_driver.c
+++ b/drivers/usb/host/dwc_otg/dwc_otg_driver.c
@@ -64,6 +64,8 @@ bool microframe_schedule=true;
extern int pcd_init(
#ifdef LM_INTERFACE
struct lm_device *_dev
-@@ -238,6 +240,14 @@ static struct dwc_otg_driver_module_params dwc_otg_module_params = {
+@@ -238,6 +240,14 @@ static struct dwc_otg_driver_module_para
.adp_enable = -1,
};
#else
{
struct map_desc desc = {
-@@ -1044,6 +1070,12 @@ static int __init dwc_otg_driver_init(void)
+@@ -1044,6 +1070,12 @@ static int __init dwc_otg_driver_init(vo
int retval = 0;
int error;
struct device_driver *drv;
printk(KERN_INFO "%s: version %s (%s bus)\n", dwc_driver_name,
DWC_DRIVER_VERSION,
#ifdef LM_INTERFACE
-@@ -1063,6 +1095,9 @@ static int __init dwc_otg_driver_init(void)
+@@ -1063,6 +1095,9 @@ static int __init dwc_otg_driver_init(vo
printk(KERN_ERR "%s retval=%d\n", __func__, retval);
return retval;
}
error = driver_create_file(drv, &driver_attr_version);
#ifdef DEBUG
-@@ -1343,6 +1378,13 @@ MODULE_PARM_DESC(otg_ver, "OTG revision supported 0=OTG 1.3 1=OTG 2.0");
+@@ -1343,6 +1378,13 @@ MODULE_PARM_DESC(otg_ver, "OTG revision
module_param(microframe_schedule, bool, 0444);
MODULE_PARM_DESC(microframe_schedule, "Enable the microframe scheduler");
/** @page "Module Parameters"
*
* The following parameters may be specified when starting the module.
-diff --git a/drivers/usb/host/dwc_otg/dwc_otg_hcd.c b/drivers/usb/host/dwc_otg/dwc_otg_hcd.c
-index ab935c0..22300f0 100644
--- a/drivers/usb/host/dwc_otg/dwc_otg_hcd.c
+++ b/drivers/usb/host/dwc_otg/dwc_otg_hcd.c
@@ -40,10 +40,14 @@
//#define DEBUG_HOST_CHANNELS
#ifdef DEBUG_HOST_CHANNELS
-@@ -53,6 +57,13 @@ static int last_sel_trans_num_avail_hc_at_start = 0;
+@@ -53,6 +57,13 @@ static int last_sel_trans_num_avail_hc_a
static int last_sel_trans_num_avail_hc_at_end = 0;
#endif /* DEBUG_HOST_CHANNELS */
dwc_otg_hcd_t *dwc_otg_hcd_alloc_hcd(void)
{
return DWC_ALLOC(sizeof(dwc_otg_hcd_t));
-@@ -162,31 +173,43 @@ static void del_timers(dwc_otg_hcd_t * hcd)
+@@ -162,31 +173,43 @@ static void del_timers(dwc_otg_hcd_t * h
/**
* Processes all the URBs in a single list of QHs. Completes them with
* and periodic schedules. The QTD associated with each URB is removed from
* the schedule and freed. This function may be called when a disconnect is
* detected or when the HCD is being stopped.
-@@ -272,7 +295,8 @@ static int32_t dwc_otg_hcd_disconnect_cb(void *p)
+@@ -272,7 +295,8 @@ static int32_t dwc_otg_hcd_disconnect_cb
*/
dwc_otg_hcd->flags.b.port_connect_status_change = 1;
dwc_otg_hcd->flags.b.port_connect_status = 0;
/*
* Shutdown any transfers in process by clearing the Tx FIFO Empty
* interrupt mask and status bits and disabling subsequent host
-@@ -368,8 +392,22 @@ static int32_t dwc_otg_hcd_disconnect_cb(void *p)
+@@ -368,8 +392,22 @@ static int32_t dwc_otg_hcd_disconnect_cb
channel->qh = NULL;
}
}
/**
* HCD Callback function for Remote Wakeup.
*
-@@ -457,10 +496,12 @@ int dwc_otg_hcd_urb_enqueue(dwc_otg_hcd_t * hcd,
+@@ -457,10 +496,12 @@ int dwc_otg_hcd_urb_enqueue(dwc_otg_hcd_
dwc_otg_hcd_urb_t * dwc_otg_urb, void **ep_handle,
int atomic_alloc)
{
#ifdef DEBUG /* integrity checks (Broadcom) */
if (NULL == hcd->core_if) {
-@@ -475,6 +516,16 @@ int dwc_otg_hcd_urb_enqueue(dwc_otg_hcd_t * hcd,
+@@ -475,6 +516,16 @@ int dwc_otg_hcd_urb_enqueue(dwc_otg_hcd_
return -DWC_E_NO_DEVICE;
}
qtd = dwc_otg_hcd_qtd_create(dwc_otg_urb, atomic_alloc);
if (qtd == NULL) {
DWC_ERROR("DWC OTG HCD URB Enqueue failed creating QTD\n");
-@@ -490,32 +541,27 @@ int dwc_otg_hcd_urb_enqueue(dwc_otg_hcd_t * hcd,
+@@ -490,32 +541,27 @@ int dwc_otg_hcd_urb_enqueue(dwc_otg_hcd_
return -DWC_E_NO_MEMORY;
}
#endif
return retval;
}
-@@ -524,6 +570,8 @@ int dwc_otg_hcd_urb_dequeue(dwc_otg_hcd_t * hcd,
+@@ -524,6 +570,8 @@ int dwc_otg_hcd_urb_dequeue(dwc_otg_hcd_
{
dwc_otg_qh_t *qh;
dwc_otg_qtd_t *urb_qtd;
#ifdef DEBUG /* integrity checks (Broadcom) */
-@@ -540,14 +588,17 @@ int dwc_otg_hcd_urb_dequeue(dwc_otg_hcd_t * hcd,
+@@ -540,14 +588,17 @@ int dwc_otg_hcd_urb_dequeue(dwc_otg_hcd_
return -DWC_E_INVALID;
}
urb_qtd = dwc_otg_urb->qtd;
if (CHK_DEBUG_LEVEL(DBG_HCDV | DBG_HCD_URB)) {
if (urb_qtd->in_process) {
dump_channel_info(hcd, qh);
-@@ -571,6 +622,8 @@ int dwc_otg_hcd_urb_dequeue(dwc_otg_hcd_t * hcd,
+@@ -571,6 +622,8 @@ int dwc_otg_hcd_urb_dequeue(dwc_otg_hcd_
*/
dwc_otg_hc_halt(hcd->core_if, qh->channel,
DWC_OTG_HC_XFER_URB_DEQUEUE);
}
}
-@@ -687,6 +740,33 @@ static void reset_tasklet_func(void *data)
+@@ -687,6 +740,33 @@ static void reset_tasklet_func(void *dat
dwc_otg_hcd->flags.b.port_reset_change = 1;
}
static void qh_list_free(dwc_otg_hcd_t * hcd, dwc_list_link_t * qh_list)
{
dwc_list_link_t *item;
-@@ -819,12 +899,14 @@ static void dwc_otg_hcd_free(dwc_otg_hcd_t * dwc_otg_hcd)
+@@ -819,12 +899,14 @@ static void dwc_otg_hcd_free(dwc_otg_hcd
} else if (dwc_otg_hcd->status_buf != NULL) {
DWC_FREE(dwc_otg_hcd->status_buf);
}
#ifdef DWC_DEV_SRPCAP
if (dwc_otg_hcd->core_if->power_down == 2 &&
-@@ -845,6 +927,7 @@ int dwc_otg_hcd_init(dwc_otg_hcd_t * hcd, dwc_otg_core_if_t * core_if)
+@@ -845,6 +927,7 @@ int dwc_otg_hcd_init(dwc_otg_hcd_t * hcd
dwc_hc_t *channel;
hcd->lock = DWC_SPINLOCK_ALLOC();
DWC_DEBUGPL(DBG_HCDV, "init of HCD %p given core_if %p\n",
hcd, core_if);
if (!hcd->lock) {
-@@ -868,7 +951,7 @@ int dwc_otg_hcd_init(dwc_otg_hcd_t * hcd, dwc_otg_core_if_t * core_if)
+@@ -868,7 +951,7 @@ int dwc_otg_hcd_init(dwc_otg_hcd_t * hcd
DWC_LIST_INIT(&hcd->periodic_sched_ready);
DWC_LIST_INIT(&hcd->periodic_sched_assigned);
DWC_LIST_INIT(&hcd->periodic_sched_queued);
/*
* Create a host channel descriptor for each host channel implemented
* in the controller. Initialize the channel descriptor array.
-@@ -906,6 +989,9 @@ int dwc_otg_hcd_init(dwc_otg_hcd_t * hcd, dwc_otg_core_if_t * core_if)
+@@ -906,6 +989,9 @@ int dwc_otg_hcd_init(dwc_otg_hcd_t * hcd
/* Initialize reset tasklet. */
hcd->reset_tasklet = DWC_TASK_ALLOC("reset_tasklet", reset_tasklet_func, hcd);
#ifdef DWC_DEV_SRPCAP
if (hcd->core_if->power_down == 2) {
/* Initialize Power on timer for Host power up in case hibernation */
-@@ -938,6 +1024,12 @@ int dwc_otg_hcd_init(dwc_otg_hcd_t * hcd, dwc_otg_core_if_t * core_if)
+@@ -938,6 +1024,12 @@ int dwc_otg_hcd_init(dwc_otg_hcd_t * hcd
hcd->frame_list = NULL;
hcd->frame_list_dma = 0;
hcd->periodic_qh_count = 0;
out:
return retval;
}
-@@ -1083,7 +1175,12 @@ static void assign_and_init_hc(dwc_otg_hcd_t * hcd, dwc_otg_qh_t * qh)
+@@ -1083,7 +1175,12 @@ static void assign_and_init_hc(dwc_otg_h
uint32_t hub_addr, port_addr;
hc->do_split = 1;
hc->xact_pos = qtd->isoc_split_pos;
hcd->fops->hub_info(hcd, urb->priv, &hub_addr, &port_addr);
hc->hub_addr = (uint8_t) hub_addr;
hc->port_addr = (uint8_t) port_addr;
-@@ -1230,6 +1327,65 @@ static void assign_and_init_hc(dwc_otg_hcd_t * hcd, dwc_otg_qh_t * qh)
+@@ -1230,6 +1327,65 @@ static void assign_and_init_hc(dwc_otg_h
hc->qh = qh;
}
/**
* This function selects transactions from the HCD transfer schedule and
* assigns them to available host channels. It is called from HCD interrupt
-@@ -1243,9 +1399,10 @@ dwc_otg_transaction_type_e dwc_otg_hcd_select_transactions(dwc_otg_hcd_t * hcd)
+@@ -1243,9 +1399,10 @@ dwc_otg_transaction_type_e dwc_otg_hcd_s
{
dwc_list_link_t *qh_ptr;
dwc_otg_qh_t *qh;
dwc_otg_transaction_type_e ret_val = DWC_OTG_TRANSACTION_NONE;
#ifdef DEBUG_SOF
-@@ -1263,11 +1420,29 @@ dwc_otg_transaction_type_e dwc_otg_hcd_select_transactions(dwc_otg_hcd_t * hcd)
+@@ -1263,11 +1420,29 @@ dwc_otg_transaction_type_e dwc_otg_hcd_s
while (qh_ptr != &hcd->periodic_sched_ready &&
!DWC_CIRCLEQ_EMPTY(&hcd->free_hc_list)) {
break;
}
hcd->available_host_channels--;
-@@ -1288,8 +1463,6 @@ dwc_otg_transaction_type_e dwc_otg_hcd_select_transactions(dwc_otg_hcd_t * hcd)
+@@ -1288,8 +1463,6 @@ dwc_otg_transaction_type_e dwc_otg_hcd_s
DWC_LIST_MOVE_HEAD(&hcd->periodic_sched_assigned,
&qh->qh_list_entry);
DWC_SPINUNLOCK_IRQRESTORE(channel_lock, flags);
}
/*
-@@ -1304,6 +1477,31 @@ dwc_otg_transaction_type_e dwc_otg_hcd_select_transactions(dwc_otg_hcd_t * hcd)
+@@ -1304,6 +1477,31 @@ dwc_otg_transaction_type_e dwc_otg_hcd_s
num_channels - hcd->periodic_channels) &&
!DWC_CIRCLEQ_EMPTY(&hcd->free_hc_list)) {
if (microframe_schedule) {
DWC_SPINLOCK_IRQSAVE(channel_lock, &flags);
if (hcd->available_host_channels < 1) {
-@@ -1316,7 +1514,6 @@ dwc_otg_transaction_type_e dwc_otg_hcd_select_transactions(dwc_otg_hcd_t * hcd)
+@@ -1316,7 +1514,6 @@ dwc_otg_transaction_type_e dwc_otg_hcd_s
last_sel_trans_num_nonper_scheduled++;
#endif /* DEBUG_HOST_CHANNELS */
}
assign_and_init_hc(hcd, qh);
-@@ -1330,21 +1527,22 @@ dwc_otg_transaction_type_e dwc_otg_hcd_select_transactions(dwc_otg_hcd_t * hcd)
+@@ -1330,21 +1527,22 @@ dwc_otg_transaction_type_e dwc_otg_hcd_s
&qh->qh_list_entry);
DWC_SPINUNLOCK_IRQRESTORE(channel_lock, flags);
return ret_val;
}
-@@ -1458,6 +1656,15 @@ static void process_periodic_channels(dwc_otg_hcd_t * hcd)
+@@ -1458,6 +1656,15 @@ static void process_periodic_channels(dw
qh = DWC_LIST_ENTRY(qh_ptr, dwc_otg_qh_t, qh_list_entry);
/*
* Set a flag if we're queuing high-bandwidth in slave mode.
* The flag prevents any halts to get into the request queue in
-@@ -1587,6 +1794,15 @@ static void process_non_periodic_channels(dwc_otg_hcd_t * hcd)
+@@ -1587,6 +1794,15 @@ static void process_non_periodic_channel
qh = DWC_LIST_ENTRY(hcd->non_periodic_qh_ptr, dwc_otg_qh_t,
qh_list_entry);
status =
queue_transaction(hcd, qh->channel,
tx_status.b.nptxfspcavail);
-@@ -3112,17 +3328,13 @@ dwc_otg_hcd_urb_t *dwc_otg_hcd_urb_alloc(dwc_otg_hcd_t * hcd,
+@@ -3112,17 +3328,13 @@ dwc_otg_hcd_urb_t *dwc_otg_hcd_urb_alloc
else
dwc_otg_urb = DWC_ALLOC(size);
return dwc_otg_urb;
}
-diff --git a/drivers/usb/host/dwc_otg/dwc_otg_hcd.h b/drivers/usb/host/dwc_otg/dwc_otg_hcd.h
-index bb4f67a..0007fa1 100644
--- a/drivers/usb/host/dwc_otg/dwc_otg_hcd.h
+++ b/drivers/usb/host/dwc_otg/dwc_otg_hcd.h
@@ -168,10 +168,10 @@ typedef enum dwc_otg_control_phase {
/** Frame List DMA address */
dma_addr_t frame_list_dma;
-@@ -589,6 +612,10 @@ extern dwc_otg_transaction_type_e dwc_otg_hcd_select_transactions(dwc_otg_hcd_t
+@@ -589,6 +612,10 @@ extern dwc_otg_transaction_type_e dwc_ot
extern void dwc_otg_hcd_queue_transactions(dwc_otg_hcd_t * hcd,
dwc_otg_transaction_type_e tr_type);
/** @} */
/** @name Interrupt Handler Functions */
-diff --git a/drivers/usb/host/dwc_otg/dwc_otg_hcd_ddma.c b/drivers/usb/host/dwc_otg/dwc_otg_hcd_ddma.c
-index 274967b..ee920c4 100644
--- a/drivers/usb/host/dwc_otg/dwc_otg_hcd_ddma.c
+++ b/drivers/usb/host/dwc_otg/dwc_otg_hcd_ddma.c
-@@ -276,7 +276,7 @@ void dump_frame_list(dwc_otg_hcd_t * hcd)
+@@ -276,7 +276,7 @@ void dump_frame_list(dwc_otg_hcd_t * hcd
static void release_channel_ddma(dwc_otg_hcd_t * hcd, dwc_otg_qh_t * qh)
{
dwc_irqflags_t flags;
dwc_hc_t *hc = qh->channel;
if (dwc_qh_is_non_per(qh)) {
-@@ -306,7 +306,6 @@ static void release_channel_ddma(dwc_otg_hcd_t * hcd, dwc_otg_qh_t * qh)
+@@ -306,7 +306,6 @@ static void release_channel_ddma(dwc_otg
dwc_memset(qh->desc_list, 0x00,
sizeof(dwc_otg_host_dma_desc_t) * max_desc_num(qh));
}
}
/**
-diff --git a/drivers/usb/host/dwc_otg/dwc_otg_hcd_if.h b/drivers/usb/host/dwc_otg/dwc_otg_hcd_if.h
-index 4823167..fb57db0 100644
--- a/drivers/usb/host/dwc_otg/dwc_otg_hcd_if.h
+++ b/drivers/usb/host/dwc_otg/dwc_otg_hcd_if.h
-@@ -113,6 +113,11 @@ extern void dwc_otg_hcd_remove(dwc_otg_hcd_t * hcd);
+@@ -113,6 +113,11 @@ extern void dwc_otg_hcd_remove(dwc_otg_h
*/
extern int32_t dwc_otg_hcd_handle_intr(dwc_otg_hcd_t * dwc_otg_hcd);
/**
* Returns private data set by
* dwc_otg_hcd_set_priv_data function.
-diff --git a/drivers/usb/host/dwc_otg/dwc_otg_hcd_intr.c b/drivers/usb/host/dwc_otg/dwc_otg_hcd_intr.c
-index b41e164..64d33a5 100644
--- a/drivers/usb/host/dwc_otg/dwc_otg_hcd_intr.c
+++ b/drivers/usb/host/dwc_otg/dwc_otg_hcd_intr.c
@@ -34,6 +34,12 @@
/* Don't print debug message in the interrupt handler on SOF */
#ifndef DEBUG_SOF
if (gintsts.d32 != DWC_SOF_INTR_MASK)
-@@ -88,10 +543,16 @@ int32_t dwc_otg_hcd_handle_intr(dwc_otg_hcd_t * dwc_otg_hcd)
+@@ -88,10 +543,16 @@ int32_t dwc_otg_hcd_handle_intr(dwc_otg_
"DWC OTG HCD Interrupt Detected gintsts&gintmsk=0x%08x core_if=%p\n",
gintsts.d32, core_if);
#endif
if (gintsts.b.rxstsqlvl) {
retval |=
dwc_otg_hcd_handle_rx_status_q_level_intr
-@@ -106,7 +567,10 @@ int32_t dwc_otg_hcd_handle_intr(dwc_otg_hcd_t * dwc_otg_hcd)
+@@ -106,7 +567,10 @@ int32_t dwc_otg_hcd_handle_intr(dwc_otg_
/** @todo Implement i2cintr handler. */
}
if (gintsts.b.portintr) {
}
if (gintsts.b.hcintr) {
retval |= dwc_otg_hcd_handle_hc_intr(dwc_otg_hcd);
-@@ -138,11 +602,48 @@ int32_t dwc_otg_hcd_handle_intr(dwc_otg_hcd_t * dwc_otg_hcd)
+@@ -138,11 +602,48 @@ int32_t dwc_otg_hcd_handle_intr(dwc_otg_
#endif
}
#warning Compiling code to track missed SOFs
#define FRAME_NUM_ARRAY_SIZE 1000
/**
-@@ -188,7 +689,8 @@ int32_t dwc_otg_hcd_handle_sof_intr(dwc_otg_hcd_t * hcd)
+@@ -188,7 +689,8 @@ int32_t dwc_otg_hcd_handle_sof_intr(dwc_
dwc_list_link_t *qh_entry;
dwc_otg_qh_t *qh;
dwc_otg_transaction_type_e tr_type;
hfnum.d32 =
DWC_READ_REG32(&hcd->core_if->host_if->host_global_regs->hfnum);
-@@ -212,17 +714,31 @@ int32_t dwc_otg_hcd_handle_sof_intr(dwc_otg_hcd_t * hcd)
+@@ -212,17 +714,31 @@ int32_t dwc_otg_hcd_handle_sof_intr(dwc_
qh = DWC_LIST_ENTRY(qh_entry, dwc_otg_qh_t, qh_list_entry);
qh_entry = qh_entry->next;
if (dwc_frame_num_le(qh->sched_frame, hcd->frame_number)) {
}
/* Clear interrupt */
-@@ -511,6 +1027,15 @@ int32_t dwc_otg_hcd_handle_hc_intr(dwc_otg_hcd_t * dwc_otg_hcd)
+@@ -511,6 +1027,15 @@ int32_t dwc_otg_hcd_handle_hc_intr(dwc_o
haint.d32 = dwc_otg_read_host_all_channels_intr(dwc_otg_hcd->core_if);
for (i = 0; i < dwc_otg_hcd->core_if->core_params->host_channels; i++) {
if (haint.b2.chint & (1 << i)) {
retval |= dwc_otg_hcd_handle_hc_n_intr(dwc_otg_hcd, i);
-@@ -551,7 +1076,10 @@ static uint32_t get_actual_xfer_length(dwc_hc_t * hc,
+@@ -551,7 +1076,10 @@ static uint32_t get_actual_xfer_length(d
*short_read = (hctsiz.b.xfersize != 0);
}
} else if (hc->qh->do_split) {
} else {
length = hc->xfer_len;
}
-@@ -595,7 +1123,6 @@ static int update_urb_state_xfer_comp(dwc_hc_t * hc,
+@@ -595,7 +1123,6 @@ static int update_urb_state_xfer_comp(dw
DWC_OTG_HC_XFER_COMPLETE,
&short_read);
/* non DWORD-aligned buffer case handling. */
if (hc->align_buff && xfer_length && hc->ep_is_in) {
dwc_memcpy(urb->buf + urb->actual_length, hc->qh->dw_align_buf,
-@@ -797,11 +1324,24 @@ static void release_channel(dwc_otg_hcd_t * hcd,
+@@ -797,11 +1324,24 @@ static void release_channel(dwc_otg_hcd_
dwc_otg_transaction_type_e tr_type;
int free_qtd;
dwc_irqflags_t flags;
}
/**
-@@ -1295,6 +1852,17 @@ static int32_t handle_hc_nak_intr(dwc_otg_hcd_t * hcd,
+@@ -1295,6 +1852,17 @@ static int32_t handle_hc_nak_intr(dwc_ot
"NAK Received--\n", hc->hc_num);
/*
* Handle NAK for IN/OUT SSPLIT/CSPLIT transfers, bulk, control, and
* interrupt. Re-start the SSPLIT transfer.
*/
-@@ -1316,7 +1884,11 @@ static int32_t handle_hc_nak_intr(dwc_otg_hcd_t * hcd,
+@@ -1316,7 +1884,11 @@ static int32_t handle_hc_nak_intr(dwc_ot
* transfers in DMA mode for the sole purpose of
* resetting the error count after a transaction error
* occurs. The core will continue transferring data.
qtd->error_count = 0;
goto handle_nak_done;
}
-@@ -1428,6 +2000,15 @@ static int32_t handle_hc_ack_intr(dwc_otg_hcd_t * hcd,
+@@ -1428,6 +2000,15 @@ static int32_t handle_hc_ack_intr(dwc_ot
halt_channel(hcd, hc, qtd, DWC_OTG_HC_XFER_ACK);
}
} else {
qtd->error_count = 0;
if (hc->qh->ping_state) {
-@@ -1490,8 +2071,10 @@ static int32_t handle_hc_nyet_intr(dwc_otg_hcd_t * hcd,
+@@ -1490,8 +2071,10 @@ static int32_t handle_hc_nyet_intr(dwc_o
hc->ep_type == DWC_OTG_EP_TYPE_ISOC) {
int frnum = dwc_otg_hcd_get_frame_number(hcd);
/*
* No longer in the same full speed frame.
* Treat this as a transaction error.
-@@ -1778,13 +2361,28 @@ static int32_t handle_hc_datatglerr_intr(dwc_otg_hcd_t * hcd,
+@@ -1778,13 +2361,28 @@ static int32_t handle_hc_datatglerr_intr
dwc_otg_qtd_t * qtd)
{
DWC_DEBUGPL(DBG_HCDI, "--Host Channel %d Interrupt: "
}
disable_hc_int(hc_regs, datatglerr);
-@@ -1862,10 +2460,10 @@ static inline int halt_status_ok(dwc_otg_hcd_t * hcd,
+@@ -1862,10 +2460,10 @@ static inline int halt_status_ok(dwc_otg
static void handle_hc_chhltd_intr_dma(dwc_otg_hcd_t * hcd,
dwc_hc_t * hc,
dwc_otg_hc_regs_t * hc_regs,
int out_nak_enh = 0;
/* For core with OUT NAK enhancement, the flow for high-
-@@ -1897,8 +2495,11 @@ static void handle_hc_chhltd_intr_dma(dwc_otg_hcd_t * hcd,
+@@ -1897,8 +2495,11 @@ static void handle_hc_chhltd_intr_dma(dw
}
/* Read the HCINTn register to determine the cause for the halt. */
if (hcint.b.xfercomp) {
/** @todo This is here because of a possible hardware bug. Spec
-@@ -1937,6 +2538,8 @@ static void handle_hc_chhltd_intr_dma(dwc_otg_hcd_t * hcd,
+@@ -1937,6 +2538,8 @@ static void handle_hc_chhltd_intr_dma(dw
handle_hc_babble_intr(hcd, hc, hc_regs, qtd);
} else if (hcint.b.frmovrun) {
handle_hc_frmovrun_intr(hcd, hc, hc_regs, qtd);
} else if (!out_nak_enh) {
if (hcint.b.nyet) {
/*
-@@ -1986,12 +2589,24 @@ static void handle_hc_chhltd_intr_dma(dwc_otg_hcd_t * hcd,
+@@ -1986,12 +2589,24 @@ static void handle_hc_chhltd_intr_dma(dw
DWC_READ_REG32(&hcd->
core_if->core_global_regs->
gintsts));
}
}
-@@ -2009,13 +2624,15 @@ static void handle_hc_chhltd_intr_dma(dwc_otg_hcd_t * hcd,
+@@ -2009,13 +2624,15 @@ static void handle_hc_chhltd_intr_dma(dw
static int32_t handle_hc_chhltd_intr(dwc_otg_hcd_t * hcd,
dwc_hc_t * hc,
dwc_otg_hc_regs_t * hc_regs,
} else {
#ifdef DEBUG
if (!halt_status_ok(hcd, hc, hc_regs, qtd)) {
-@@ -2032,7 +2649,7 @@ static int32_t handle_hc_chhltd_intr(dwc_otg_hcd_t * hcd,
+@@ -2032,7 +2649,7 @@ static int32_t handle_hc_chhltd_intr(dwc
int32_t dwc_otg_hcd_handle_hc_n_intr(dwc_otg_hcd_t * dwc_otg_hcd, uint32_t num)
{
int retval = 0;
hcintmsk_data_t hcintmsk;
dwc_hc_t *hc;
dwc_otg_hc_regs_t *hc_regs;
-@@ -2042,15 +2659,33 @@ int32_t dwc_otg_hcd_handle_hc_n_intr(dwc_otg_hcd_t * dwc_otg_hcd, uint32_t num)
+@@ -2042,15 +2659,33 @@ int32_t dwc_otg_hcd_handle_hc_n_intr(dwc
hc = dwc_otg_hcd->hc_ptr_array[num];
hc_regs = dwc_otg_hcd->core_if->host_if->hc_regs[num];
if (!dwc_otg_hcd->core_if->dma_enable) {
if (hcint.b.chhltd && hcint.d32 != 0x2) {
hcint.b.chhltd = 0;
-@@ -2068,7 +2703,7 @@ int32_t dwc_otg_hcd_handle_hc_n_intr(dwc_otg_hcd_t * dwc_otg_hcd, uint32_t num)
+@@ -2068,7 +2703,7 @@ int32_t dwc_otg_hcd_handle_hc_n_intr(dwc
hcint.b.nyet = 0;
}
if (hcint.b.chhltd) {
}
if (hcint.b.ahberr) {
retval |= handle_hc_ahberr_intr(dwc_otg_hcd, hc, hc_regs, qtd);
-@@ -2080,7 +2715,8 @@ int32_t dwc_otg_hcd_handle_hc_n_intr(dwc_otg_hcd_t * dwc_otg_hcd, uint32_t num)
+@@ -2080,7 +2715,8 @@ int32_t dwc_otg_hcd_handle_hc_n_intr(dwc
retval |= handle_hc_nak_intr(dwc_otg_hcd, hc, hc_regs, qtd);
}
if (hcint.b.ack) {
}
if (hcint.b.nyet) {
retval |= handle_hc_nyet_intr(dwc_otg_hcd, hc, hc_regs, qtd);
-@@ -2102,5 +2738,4 @@ int32_t dwc_otg_hcd_handle_hc_n_intr(dwc_otg_hcd_t * dwc_otg_hcd, uint32_t num)
+@@ -2102,5 +2738,4 @@ int32_t dwc_otg_hcd_handle_hc_n_intr(dwc
return retval;
}
-
#endif /* DWC_DEVICE_ONLY */
-diff --git a/drivers/usb/host/dwc_otg/dwc_otg_hcd_linux.c b/drivers/usb/host/dwc_otg/dwc_otg_hcd_linux.c
-index e4787f5..ee8eec9 100644
--- a/drivers/usb/host/dwc_otg/dwc_otg_hcd_linux.c
+++ b/drivers/usb/host/dwc_otg/dwc_otg_hcd_linux.c
@@ -1,3 +1,4 @@
/** @name Linux HC Driver API Functions */
/** @{ */
/* manage i/o requests, device state */
-@@ -259,13 +265,15 @@ static void free_bus_bandwidth(struct usb_hcd *hcd, uint32_t bw,
+@@ -259,13 +265,15 @@ static void free_bus_bandwidth(struct us
/**
* Sets the final status of an URB and returns it to the device driver. Any
if (CHK_DEBUG_LEVEL(DBG_HCDV | DBG_HCD_URB)) {
DWC_PRINTF("%s: urb %p, device %d, ep %d %s, status=%d\n",
__func__, urb, usb_pipedevice(urb->pipe),
-@@ -279,7 +287,7 @@ static int _complete(dwc_otg_hcd_t * hcd, void *urb_handle,
+@@ -279,7 +287,7 @@ static int _complete(dwc_otg_hcd_t * hcd
}
}
}
urb->actual_length = dwc_otg_hcd_urb_get_actual_length(dwc_otg_urb);
/* Convert status value. */
switch (status) {
-@@ -301,6 +309,9 @@ static int _complete(dwc_otg_hcd_t * hcd, void *urb_handle,
+@@ -301,6 +309,9 @@ static int _complete(dwc_otg_hcd_t * hcd
case -DWC_E_OVERFLOW:
status = -EOVERFLOW;
break;
default:
if (status) {
DWC_PRINTF("Uknown urb status %d\n", status);
-@@ -342,18 +353,33 @@ static int _complete(dwc_otg_hcd_t * hcd, void *urb_handle,
+@@ -342,18 +353,33 @@ static int _complete(dwc_otg_hcd_t * hcd
}
DWC_FREE(dwc_otg_urb);
return 0;
}
-@@ -366,6 +392,16 @@ static struct dwc_otg_hcd_function_ops hcd_fops = {
+@@ -366,6 +392,16 @@ static struct dwc_otg_hcd_function_ops h
.get_b_hnp_enable = _get_b_hnp_enable,
};
/* Initialize the DWC OTG HCD. */
dwc_otg_hcd = dwc_otg_hcd_alloc_hcd();
if (!dwc_otg_hcd) {
-@@ -607,9 +682,7 @@ static int dwc_otg_urb_enqueue(struct usb_hcd *hcd,
+@@ -607,9 +682,7 @@ static int dwc_otg_urb_enqueue(struct us
#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,28)
struct usb_host_endpoint *ep = urb->ep;
#endif
void **ref_ep_hcpriv = &ep->hcpriv;
dwc_otg_hcd_t *dwc_otg_hcd = hcd_to_dwc_otg_hcd(hcd);
dwc_otg_hcd_urb_t *dwc_otg_urb;
-@@ -661,9 +734,8 @@ static int dwc_otg_urb_enqueue(struct usb_hcd *hcd,
+@@ -661,9 +734,8 @@ static int dwc_otg_urb_enqueue(struct us
if(dwc_otg_urb == NULL)
return -ENOMEM;
dwc_otg_hcd_urb_set_pipeinfo(dwc_otg_urb, usb_pipedevice(urb->pipe),
usb_pipeendpoint(urb->pipe), ep_type,
-@@ -703,37 +775,42 @@ static int dwc_otg_urb_enqueue(struct usb_hcd *hcd,
+@@ -703,37 +775,42 @@ static int dwc_otg_urb_enqueue(struct us
iso_frame_desc[i].length);
}
- DWC_SPINLOCK_IRQSAVE(dwc_otg_hcd->lock, &irqflags);
- usb_hcd_unlink_urb_from_ep(hcd, urb);
- DWC_SPINUNLOCK_IRQRESTORE(dwc_otg_hcd->lock, irqflags);
-+ usb_hcd_unlink_urb_from_ep(hcd, urb);
- #endif
+-#endif
- if (retval == -DWC_E_NO_DEVICE) {
- retval = -ENODEV;
- }
- }
- }
++ usb_hcd_unlink_urb_from_ep(hcd, urb);
++#endif
+ DWC_FREE(dwc_otg_urb);
+ urb->hcpriv = NULL;
+ if (retval == -DWC_E_NO_DEVICE)
return retval;
}
-@@ -777,6 +854,8 @@ static int dwc_otg_urb_dequeue(struct usb_hcd *hcd, struct urb *urb, int status)
+@@ -777,6 +854,8 @@ static int dwc_otg_urb_dequeue(struct us
usb_hcd_unlink_urb_from_ep(hcd, urb);
#endif
DWC_SPINUNLOCK_IRQRESTORE(dwc_otg_hcd->lock, flags);
#if LINUX_VERSION_CODE < KERNEL_VERSION(2,6,28)
usb_hcd_giveback_urb(hcd, urb);
#else
-diff --git a/drivers/usb/host/dwc_otg/dwc_otg_hcd_queue.c b/drivers/usb/host/dwc_otg/dwc_otg_hcd_queue.c
-index 9761566..db95851 100644
--- a/drivers/usb/host/dwc_otg/dwc_otg_hcd_queue.c
+++ b/drivers/usb/host/dwc_otg/dwc_otg_hcd_queue.c
@@ -41,6 +41,7 @@
extern bool microframe_schedule;
-@@ -181,6 +182,7 @@ void qh_init(dwc_otg_hcd_t * hcd, dwc_otg_qh_t * qh, dwc_otg_hcd_urb_t * urb)
+@@ -181,6 +182,7 @@ void qh_init(dwc_otg_hcd_t * hcd, dwc_ot
if (microframe_schedule)
qh->speed = dev_speed;
if (((dev_speed == USB_SPEED_LOW) ||
(dev_speed == USB_SPEED_FULL)) &&
-@@ -190,6 +192,7 @@ void qh_init(dwc_otg_hcd_t * hcd, dwc_otg_qh_t * qh, dwc_otg_hcd_urb_t * urb)
+@@ -190,6 +192,7 @@ void qh_init(dwc_otg_hcd_t * hcd, dwc_ot
dwc_otg_hcd_get_ep_num(&urb->pipe_info), hub_addr,
hub_port);
qh->do_split = 1;
}
if (qh->ep_type == UE_INTERRUPT || qh->ep_type == UE_ISOCHRONOUS) {
-@@ -572,6 +575,9 @@ static int check_max_xfer_size(dwc_otg_hcd_t * hcd, dwc_otg_qh_t * qh)
+@@ -572,6 +575,9 @@ static int check_max_xfer_size(dwc_otg_h
return status;
}
/**
* Schedules an interrupt or isochronous transfer in the periodic schedule.
*
-@@ -630,8 +636,13 @@ static int schedule_periodic(dwc_otg_hcd_t * hcd, dwc_otg_qh_t * qh)
+@@ -630,8 +636,13 @@ static int schedule_periodic(dwc_otg_hcd
DWC_LIST_INSERT_TAIL(&hcd->periodic_sched_ready, &qh->qh_list_entry);
}
else {
}
if (!microframe_schedule) {
-@@ -645,6 +656,7 @@ static int schedule_periodic(dwc_otg_hcd_t * hcd, dwc_otg_qh_t * qh)
+@@ -645,6 +656,7 @@ static int schedule_periodic(dwc_otg_hcd
return status;
}
/**
* This function adds a QH to either the non periodic or periodic schedule if
* it is not already in the schedule. If the QH is already in the schedule, no
-@@ -667,6 +679,7 @@ int dwc_otg_hcd_qh_add(dwc_otg_hcd_t * hcd, dwc_otg_qh_t * qh)
+@@ -667,6 +679,7 @@ int dwc_otg_hcd_qh_add(dwc_otg_hcd_t * h
/* Always start in the inactive schedule. */
DWC_LIST_INSERT_TAIL(&hcd->non_periodic_sched_inactive,
&qh->qh_list_entry);
} else {
status = schedule_periodic(hcd, qh);
if ( !hcd->periodic_qh_count ) {
-@@ -726,6 +739,9 @@ void dwc_otg_hcd_qh_remove(dwc_otg_hcd_t * hcd, dwc_otg_qh_t * qh)
+@@ -726,6 +739,9 @@ void dwc_otg_hcd_qh_remove(dwc_otg_hcd_t
hcd->non_periodic_qh_ptr->next;
}
DWC_LIST_REMOVE_INIT(&qh->qh_list_entry);
} else {
deschedule_periodic(hcd, qh);
hcd->periodic_qh_count--;
-@@ -754,6 +770,24 @@ void dwc_otg_hcd_qh_deactivate(dwc_otg_hcd_t * hcd, dwc_otg_qh_t * qh,
+@@ -754,6 +770,24 @@ void dwc_otg_hcd_qh_deactivate(dwc_otg_h
int sched_next_periodic_split)
{
if (dwc_qh_is_non_per(qh)) {
dwc_otg_hcd_qh_remove(hcd, qh);
if (!DWC_CIRCLEQ_EMPTY(&qh->qtd_list)) {
/* Add back to inactive non-periodic schedule. */
-@@ -767,6 +801,7 @@ void dwc_otg_hcd_qh_deactivate(dwc_otg_hcd_t * hcd, dwc_otg_qh_t * qh,
+@@ -767,6 +801,7 @@ void dwc_otg_hcd_qh_deactivate(dwc_otg_h
if (sched_next_periodic_split) {
qh->sched_frame = frame_number;
if (dwc_frame_num_le(frame_number,
dwc_frame_num_inc
(qh->start_split_frame,
-@@ -815,6 +850,11 @@ void dwc_otg_hcd_qh_deactivate(dwc_otg_hcd_t * hcd, dwc_otg_qh_t * qh,
+@@ -815,6 +850,11 @@ void dwc_otg_hcd_qh_deactivate(dwc_otg_h
DWC_LIST_MOVE_HEAD(&hcd->periodic_sched_ready,
&qh->qh_list_entry);
} else {
DWC_LIST_MOVE_HEAD
(&hcd->periodic_sched_inactive,
&qh->qh_list_entry);
-@@ -879,6 +919,7 @@ void dwc_otg_hcd_qtd_init(dwc_otg_qtd_t * qtd, dwc_otg_hcd_urb_t * urb)
+@@ -879,6 +919,7 @@ void dwc_otg_hcd_qtd_init(dwc_otg_qtd_t
* QH to place the QTD into. If it does not find a QH, then it will create a
* new QH. If the QH to which the QTD is added is not currently scheduled, it
* is placed into the proper schedule based on its EP type.
*
* @param[in] qtd The QTD to add
* @param[in] hcd The DWC HCD structure
-@@ -891,8 +932,6 @@ int dwc_otg_hcd_qtd_add(dwc_otg_qtd_t * qtd,
+@@ -891,8 +932,6 @@ int dwc_otg_hcd_qtd_add(dwc_otg_qtd_t *
dwc_otg_hcd_t * hcd, dwc_otg_qh_t ** qh, int atomic_alloc)
{
int retval = 0;
dwc_otg_hcd_urb_t *urb = qtd->urb;
/*
-@@ -902,18 +941,16 @@ int dwc_otg_hcd_qtd_add(dwc_otg_qtd_t * qtd,
+@@ -902,18 +941,16 @@ int dwc_otg_hcd_qtd_add(dwc_otg_qtd_t *
if (*qh == NULL) {
*qh = dwc_otg_hcd_qh_create(hcd, urb, atomic_alloc);
if (*qh == NULL) {
done:
return retval;
-diff --git a/drivers/usb/host/dwc_otg/dwc_otg_mphi_fix.c b/drivers/usb/host/dwc_otg/dwc_otg_mphi_fix.c
-new file mode 100755
-index 0000000..50b94a8
--- /dev/null
+++ b/drivers/usb/host/dwc_otg/dwc_otg_mphi_fix.c
@@ -0,0 +1,113 @@
+
+ return;
+}
-diff --git a/drivers/usb/host/dwc_otg/dwc_otg_mphi_fix.h b/drivers/usb/host/dwc_otg/dwc_otg_mphi_fix.h
-new file mode 100755
-index 0000000..ca17379
--- /dev/null
+++ b/drivers/usb/host/dwc_otg/dwc_otg_mphi_fix.h
@@ -0,0 +1,48 @@
+extern bool fiq_fix_enable, nak_holdoff_enable, fiq_split_enable;
+
+#endif
-diff --git a/drivers/usb/host/dwc_otg/dwc_otg_os_dep.h b/drivers/usb/host/dwc_otg/dwc_otg_os_dep.h
-index e46d9bb..6b2c7d0 100644
--- a/drivers/usb/host/dwc_otg/dwc_otg_os_dep.h
+++ b/drivers/usb/host/dwc_otg/dwc_otg_os_dep.h
@@ -97,6 +97,9 @@ typedef struct os_dependent {
#ifdef LM_INTERFACE
struct lm_device *lmdev;
#elif defined(PCI_INTERFACE)
-diff --git a/drivers/usb/host/dwc_otg/dwc_otg_pcd_intr.c b/drivers/usb/host/dwc_otg/dwc_otg_pcd_intr.c
-index 1b1f83c..c8590b5 100644
--- a/drivers/usb/host/dwc_otg/dwc_otg_pcd_intr.c
+++ b/drivers/usb/host/dwc_otg/dwc_otg_pcd_intr.c
@@ -4276,7 +4276,7 @@ do { \
out_desc_addr->status.d32;
if (status.b.sr) {
---
-1.9.1
-
delete mode 100755 drivers/usb/host/dwc_otg/dwc_otg_mphi_fix.c
delete mode 100755 drivers/usb/host/dwc_otg/dwc_otg_mphi_fix.h
-diff --git a/arch/arm/mach-bcm2708/bcm2708.c b/arch/arm/mach-bcm2708/bcm2708.c
-index 47a66f8..89d0824 100644
--- a/arch/arm/mach-bcm2708/bcm2708.c
+++ b/arch/arm/mach-bcm2708/bcm2708.c
-@@ -330,22 +330,13 @@ static struct resource bcm2708_usb_resources[] = {
+@@ -330,22 +330,13 @@ static struct resource bcm2708_usb_resou
.end = IRQ_HOSTPORT,
.flags = IORESOURCE_IRQ,
},
bcm_register_device(&bcm2708_usb_device);
bcm_register_device(&bcm2708_uart1_device);
bcm_register_device(&bcm2708_powerman_device);
-diff --git a/drivers/usb/host/dwc_otg/Makefile b/drivers/usb/host/dwc_otg/Makefile
-index a56f193..e7bdd12 100644
--- a/drivers/usb/host/dwc_otg/Makefile
+++ b/drivers/usb/host/dwc_otg/Makefile
-@@ -36,7 +36,8 @@ dwc_otg-objs += dwc_otg_cil.o dwc_otg_cil_intr.o
+@@ -36,7 +36,8 @@ dwc_otg-objs += dwc_otg_cil.o dwc_otg_ci
dwc_otg-objs += dwc_otg_pcd_linux.o dwc_otg_pcd.o dwc_otg_pcd_intr.o
dwc_otg-objs += dwc_otg_hcd.o dwc_otg_hcd_linux.o dwc_otg_hcd_intr.o dwc_otg_hcd_queue.o dwc_otg_hcd_ddma.o
dwc_otg-objs += dwc_otg_adp.o
ifneq ($(CFI),)
dwc_otg-objs += dwc_otg_cfi.o
endif
-diff --git a/drivers/usb/host/dwc_otg/dwc_otg_cil_intr.c b/drivers/usb/host/dwc_otg/dwc_otg_cil_intr.c
-index 2f8b3bd..065807f 100644
--- a/drivers/usb/host/dwc_otg/dwc_otg_cil_intr.c
+++ b/drivers/usb/host/dwc_otg/dwc_otg_cil_intr.c
@@ -45,7 +45,6 @@
#ifdef DEBUG
inline const char *op_state_str(dwc_otg_core_if_t * core_if)
-@@ -1319,7 +1318,7 @@ static int32_t dwc_otg_handle_lpm_intr(dwc_otg_core_if_t * core_if)
+@@ -1319,7 +1318,7 @@ static int32_t dwc_otg_handle_lpm_intr(d
/**
* This function returns the Core Interrupt register.
*/
{
gahbcfg_data_t gahbcfg = {.d32 = 0 };
gintsts_data_t gintsts;
-@@ -1345,16 +1344,15 @@ static inline uint32_t dwc_otg_read_common_intr(dwc_otg_core_if_t * core_if, gin
+@@ -1345,16 +1344,15 @@ static inline uint32_t dwc_otg_read_comm
}
gintsts.d32 = DWC_READ_REG32(&core_if->core_global_regs->gintsts);
gintmsk.d32 = DWC_READ_REG32(&core_if->core_global_regs->gintmsk);
}
gahbcfg.d32 = DWC_READ_REG32(&core_if->core_global_regs->gahbcfg);
-@@ -1366,13 +1364,15 @@ static inline uint32_t dwc_otg_read_common_intr(dwc_otg_core_if_t * core_if, gin
+@@ -1366,13 +1364,15 @@ static inline uint32_t dwc_otg_read_comm
gintsts.d32, gintmsk.d32);
}
#endif
return ((gintsts.d32 & gintmsk.d32) & gintmsk_common.d32);
}
-@@ -1406,7 +1406,7 @@ int32_t dwc_otg_handle_common_intr(void *dev)
+@@ -1406,7 +1406,7 @@ int32_t dwc_otg_handle_common_intr(void
{
int retval = 0;
gintsts_data_t gintsts;
gpwrdn_data_t gpwrdn = {.d32 = 0 };
dwc_otg_device_t *otg_dev = dev;
dwc_otg_core_if_t *core_if = otg_dev->core_if;
-@@ -1428,7 +1428,10 @@ int32_t dwc_otg_handle_common_intr(void *dev)
+@@ -1428,7 +1428,10 @@ int32_t dwc_otg_handle_common_intr(void
}
if (core_if->hibernation_suspend <= 0) {
if (gintsts.b.modemismatch) {
retval |= dwc_otg_handle_mode_mismatch_intr(core_if);
-@@ -1525,11 +1528,16 @@ int32_t dwc_otg_handle_common_intr(void *dev)
+@@ -1525,11 +1528,16 @@ int32_t dwc_otg_handle_common_intr(void
gintsts.b.portintr = 1;
DWC_WRITE_REG32(&core_if->core_global_regs->gintsts,gintsts.d32);
retval |= 1;
} else {
DWC_DEBUGPL(DBG_ANY, "gpwrdn=%08x\n", gpwrdn.d32);
-@@ -1583,6 +1591,5 @@ int32_t dwc_otg_handle_common_intr(void *dev)
+@@ -1583,6 +1591,5 @@ int32_t dwc_otg_handle_common_intr(void
}
if (core_if->lock)
DWC_SPINUNLOCK(core_if->lock);
-
return retval;
}
-diff --git a/drivers/usb/host/dwc_otg/dwc_otg_driver.c b/drivers/usb/host/dwc_otg/dwc_otg_driver.c
-index f06c3d22..dc7cd32 100644
--- a/drivers/usb/host/dwc_otg/dwc_otg_driver.c
+++ b/drivers/usb/host/dwc_otg/dwc_otg_driver.c
@@ -56,6 +56,7 @@
extern int pcd_init(
#ifdef LM_INTERFACE
-@@ -240,13 +240,14 @@ static struct dwc_otg_driver_module_params dwc_otg_module_params = {
+@@ -240,13 +240,14 @@ static struct dwc_otg_driver_module_para
.adp_enable = -1,
};
#endif
DWC_DEBUGPL(DBG_CIL, "registering (common) handler for irq%d\n",
devirq);
-@@ -1071,9 +1071,9 @@ static int __init dwc_otg_driver_init(void)
+@@ -1071,9 +1071,9 @@ static int __init dwc_otg_driver_init(vo
int error;
struct device_driver *drv;
}
printk(KERN_INFO "%s: version %s (%s bus)\n", dwc_driver_name,
-@@ -1095,9 +1095,9 @@ static int __init dwc_otg_driver_init(void)
+@@ -1095,9 +1095,9 @@ static int __init dwc_otg_driver_init(vo
printk(KERN_ERR "%s retval=%d\n", __func__, retval);
return retval;
}
error = driver_create_file(drv, &driver_attr_version);
#ifdef DEBUG
-@@ -1378,12 +1378,19 @@ MODULE_PARM_DESC(otg_ver, "OTG revision supported 0=OTG 1.3 1=OTG 2.0");
+@@ -1378,12 +1378,19 @@ MODULE_PARM_DESC(otg_ver, "OTG revision
module_param(microframe_schedule, bool, 0444);
MODULE_PARM_DESC(microframe_schedule, "Enable the microframe scheduler");
/** @page "Module Parameters"
*
-diff --git a/drivers/usb/host/dwc_otg/dwc_otg_fiq_fsm.c b/drivers/usb/host/dwc_otg/dwc_otg_fiq_fsm.c
-new file mode 100644
-index 0000000..7aad7f7
--- /dev/null
+++ b/drivers/usb/host/dwc_otg/dwc_otg_fiq_fsm.c
@@ -0,0 +1,1290 @@
+ state->fiq_done++;
+ mb();
+}
-diff --git a/drivers/usb/host/dwc_otg/dwc_otg_fiq_fsm.h b/drivers/usb/host/dwc_otg/dwc_otg_fiq_fsm.h
-new file mode 100644
-index 0000000..7572958
--- /dev/null
+++ b/drivers/usb/host/dwc_otg/dwc_otg_fiq_fsm.h
@@ -0,0 +1,353 @@
+extern void dwc_otg_fiq_nop(struct fiq_state *state);
+
+#endif /* DWC_OTG_FIQ_FSM_H_ */
-diff --git a/drivers/usb/host/dwc_otg/dwc_otg_fiq_stub.S b/drivers/usb/host/dwc_otg/dwc_otg_fiq_stub.S
-new file mode 100644
-index 0000000..8cfe364
--- /dev/null
+++ b/drivers/usb/host/dwc_otg/dwc_otg_fiq_stub.S
@@ -0,0 +1,81 @@
+_dwc_otg_fiq_stub_end:
+END(_dwc_otg_fiq_stub)
+
-diff --git a/drivers/usb/host/dwc_otg/dwc_otg_hcd.c b/drivers/usb/host/dwc_otg/dwc_otg_hcd.c
-index 22300f0..daea770 100644
--- a/drivers/usb/host/dwc_otg/dwc_otg_hcd.c
+++ b/drivers/usb/host/dwc_otg/dwc_otg_hcd.c
@@ -45,9 +45,10 @@
//#define DEBUG_HOST_CHANNELS
#ifdef DEBUG_HOST_CHANNELS
-@@ -57,12 +58,6 @@ static int last_sel_trans_num_avail_hc_at_start = 0;
+@@ -57,12 +58,6 @@ static int last_sel_trans_num_avail_hc_a
static int last_sel_trans_num_avail_hc_at_end = 0;
#endif /* DEBUG_HOST_CHANNELS */
dwc_otg_hcd_t *dwc_otg_hcd_alloc_hcd(void)
{
-@@ -295,7 +290,7 @@ static int32_t dwc_otg_hcd_disconnect_cb(void *p)
+@@ -295,7 +290,7 @@ static int32_t dwc_otg_hcd_disconnect_cb
*/
dwc_otg_hcd->flags.b.port_connect_status_change = 1;
dwc_otg_hcd->flags.b.port_connect_status = 0;
local_fiq_disable();
/*
* Shutdown any transfers in process by clearing the Tx FIFO Empty
-@@ -392,20 +387,15 @@ static int32_t dwc_otg_hcd_disconnect_cb(void *p)
+@@ -392,20 +387,15 @@ static int32_t dwc_otg_hcd_disconnect_cb
channel->qh = NULL;
}
}
local_fiq_enable();
if (dwc_otg_hcd->fops->disconnect) {
-@@ -542,7 +532,7 @@ int dwc_otg_hcd_urb_enqueue(dwc_otg_hcd_t * hcd,
+@@ -542,7 +532,7 @@ int dwc_otg_hcd_urb_enqueue(dwc_otg_hcd_
}
#endif
intr_mask.d32 = DWC_READ_REG32(&hcd->core_if->core_global_regs->gintmsk);
if((((dwc_otg_qh_t *)ep_handle)->ep_type == UE_BULK) && !(qtd->urb->flags & URB_GIVEBACK_ASAP))
/* Do not schedule SG transactions until qtd has URB_GIVEBACK_ASAP set */
needs_scheduling = 0;
-@@ -613,6 +603,7 @@ int dwc_otg_hcd_urb_dequeue(dwc_otg_hcd_t * hcd,
+@@ -613,6 +603,7 @@ int dwc_otg_hcd_urb_dequeue(dwc_otg_hcd_
if (urb_qtd->in_process && qh->channel) {
/* The QTD is in process (it has been assigned to a channel). */
if (hcd->flags.b.port_connect_status) {
/*
* If still connected (i.e. in host mode), halt the
* channel so it can be used for other transfers. If
-@@ -620,10 +611,16 @@ int dwc_otg_hcd_urb_dequeue(dwc_otg_hcd_t * hcd,
+@@ -620,10 +611,16 @@ int dwc_otg_hcd_urb_dequeue(dwc_otg_hcd_
* written to halt the channel since the core is in
* device mode.
*/
}
}
-@@ -759,7 +756,6 @@ static void completion_tasklet_func(void *ptr)
+@@ -759,7 +756,6 @@ static void completion_tasklet_func(void
usb_hcd_giveback_urb(hcd->priv, urb, urb->status);
/**
* Frees secondary storage associated with the dwc_otg_hcd structure contained
* in the struct usb_hcd field.
-@@ -907,6 +931,7 @@ static void dwc_otg_hcd_free(dwc_otg_hcd_t * dwc_otg_hcd)
+@@ -907,6 +931,7 @@ static void dwc_otg_hcd_free(dwc_otg_hcd
DWC_TIMER_FREE(dwc_otg_hcd->conn_timer);
DWC_TASK_FREE(dwc_otg_hcd->reset_tasklet);
DWC_TASK_FREE(dwc_otg_hcd->completion_tasklet);
#ifdef DWC_DEV_SRPCAP
if (dwc_otg_hcd->core_if->power_down == 2 &&
-@@ -979,6 +1004,59 @@ int dwc_otg_hcd_init(dwc_otg_hcd_t * hcd, dwc_otg_core_if_t * core_if)
+@@ -979,6 +1004,59 @@ int dwc_otg_hcd_init(dwc_otg_hcd_t * hcd
channel);
}
/* Initialize the Connection timeout timer. */
hcd->conn_timer = DWC_TIMER_ALLOC("Connection timer",
dwc_otg_hcd_connect_timeout, 0);
-@@ -1176,7 +1254,8 @@ static void assign_and_init_hc(dwc_otg_hcd_t * hcd, dwc_otg_qh_t * qh)
+@@ -1176,7 +1254,8 @@ static void assign_and_init_hc(dwc_otg_h
hc->do_split = 1;
hc->xact_pos = qtd->isoc_split_pos;
/* We don't need to do complete splits anymore */
hc->complete_split = qtd->complete_split = 0;
else
hc->complete_split = qtd->complete_split;
-@@ -1327,62 +1406,487 @@ static void assign_and_init_hc(dwc_otg_hcd_t * hcd, dwc_otg_qh_t * qh)
+@@ -1327,62 +1406,487 @@ static void assign_and_init_hc(dwc_otg_h
hc->qh = qh;
}
+ int nr_iso_frames = urb->packet_count;
+ int i;
+ uint32_t ptr;
-+
+
+- if(!fiq_split_enable)
+- return 0;
+ if (nr_iso_frames < 2)
+ return 0;
+ for (i = 0; i < nr_iso_frames; i++) {
+ return 0;
+}
-- if(!fiq_split_enable)
-- return 0;
+- hcd->fops->hub_info(hcd, DWC_CIRCLEQ_FIRST(&qh->qtd_list)->urb->priv, &hub_addr, &port_addr);
+/**
+ * fiq_fsm_setup_periodic_dma() - Set up DMA bounce buffers
+ * @hcd: Pointer to the dwc_otg_hcd struct
+ } else {
+ if (qh->ep_type == UE_ISOCHRONOUS) {
-- hcd->fops->hub_info(hcd, DWC_CIRCLEQ_FIRST(&qh->qtd_list)->urb->priv, &hub_addr, &port_addr);
-+ dwc_otg_qtd_t *qtd = DWC_CIRCLEQ_FIRST(&qh->qtd_list);
-
- if(hcd->hub_port[hub_addr] & (1 << port_addr))
- {
- fiq_print(FIQDBG_PORTHUB, "H%dP%d:S%02d", hub_addr, port_addr, qh->skip_count);
-+ frame_desc = &qtd->urb->iso_descs[qtd->isoc_frame_index];
-+ frame_length = frame_desc->length;
++ dwc_otg_qtd_t *qtd = DWC_CIRCLEQ_FIRST(&qh->qtd_list);
- qh->skip_count++;
-+ /* Virtual address for bounce buffers */
-+ blob = hcd->fiq_dmab;
++ frame_desc = &qtd->urb->iso_descs[qtd->isoc_frame_index];
++ frame_length = frame_desc->length;
- if(qh->skip_count > 40000)
- {
- printk_once(KERN_ERR "Error: Having to skip port allocation");
- local_fiq_disable();
- BUG();
++ /* Virtual address for bounce buffers */
++ blob = hcd->fiq_dmab;
++
+ ptr = qtd->urb->buf + frame_desc->offset;
+ if (frame_length == 0) {
+ /*
+ if (st->fsm != FIQ_PASSTHROUGH)
+ return 0;
+ st->nr_errors = 0;
-+
+
+- hcd->fops->hub_info(hcd, DWC_CIRCLEQ_FIRST(&qh->qtd_list)->urb->priv, &hub_addr, &port_addr);
+ st->hcchar_copy.d32 = 0;
+ st->hcchar_copy.b.mps = hc->max_packet;
+ st->hcchar_copy.b.epdir = hc->ep_is_in;
+ }
+ st->hcchar_copy.b.lspddev = (hc->speed == DWC_OTG_EP_SPEED_LOW) ? 1 : 0;
+ /* Enable the channel later as a final register write. */
-+
+
+- hcd->hub_port[hub_addr] &= ~(1 << port_addr);
+-#ifdef FIQ_DEBUG
+- hcd->hub_port_alloc[hub_addr * 16 + port_addr] = -1;
+-#endif
+- fiq_print(FIQDBG_PORTHUB, "H%dP%d:RO%d", hub_addr, port_addr, DWC_CIRCLEQ_FIRST(&qh->qtd_list)->urb->pipe_info.ep_num);
+ st->hcsplt_copy.d32 = 0;
+ if(qh->do_split) {
+ hcd->fops->hub_info(hcd, DWC_CIRCLEQ_FIRST(&qh->qtd_list)->urb->priv, &hub_addr, &port_addr);
+ st->hub_addr = hub_addr;
+ st->port_addr = port_addr;
+ }
-
-- hcd->fops->hub_info(hcd, DWC_CIRCLEQ_FIRST(&qh->qtd_list)->urb->priv, &hub_addr, &port_addr);
++
+ st->hctsiz_copy.d32 = 0;
+ st->hctsiz_copy.b.dopng = 0;
+ st->hctsiz_copy.b.pid = hc->data_pid_start;
-
-- hcd->hub_port[hub_addr] &= ~(1 << port_addr);
--#ifdef FIQ_DEBUG
-- hcd->hub_port_alloc[hub_addr * 16 + port_addr] = -1;
--#endif
-- fiq_print(FIQDBG_PORTHUB, "H%dP%d:RO%d", hub_addr, port_addr, DWC_CIRCLEQ_FIRST(&qh->qtd_list)->urb->pipe_info.ep_num);
++
+ if (hc->ep_is_in || (hc->xfer_len > hc->max_packet)) {
+ hc->xfer_len = hc->max_packet;
+ } else if (!hc->ep_is_in && (hc->xfer_len > 188)) {
+ hc->xfer_len = 188;
+ }
+ st->hctsiz_copy.b.xfersize = hc->xfer_len;
-+
-+ st->hctsiz_copy.b.pktcnt = 1;
++ st->hctsiz_copy.b.pktcnt = 1;
++
+ if (hc->ep_type & 0x1) {
+ /*
+ * For potentially multi-packet transfers, must use the DMA bounce buffers. For IN transfers,
}
-@@ -1399,16 +1903,11 @@ dwc_otg_transaction_type_e dwc_otg_hcd_select_transactions(dwc_otg_hcd_t * hcd)
+@@ -1399,16 +1903,11 @@ dwc_otg_transaction_type_e dwc_otg_hcd_s
{
dwc_list_link_t *qh_ptr;
dwc_otg_qh_t *qh;
#ifdef DEBUG_HOST_CHANNELS
last_sel_trans_num_per_scheduled = 0;
last_sel_trans_num_nonper_scheduled = 0;
-@@ -1423,26 +1922,11 @@ dwc_otg_transaction_type_e dwc_otg_hcd_select_transactions(dwc_otg_hcd_t * hcd)
+@@ -1423,26 +1922,11 @@ dwc_otg_transaction_type_e dwc_otg_hcd_s
qh = DWC_LIST_ENTRY(qh_ptr, dwc_otg_qh_t, qh_list_entry);
break;
}
hcd->available_host_channels--;
-@@ -1478,27 +1962,24 @@ dwc_otg_transaction_type_e dwc_otg_hcd_select_transactions(dwc_otg_hcd_t * hcd)
+@@ -1478,27 +1962,24 @@ dwc_otg_transaction_type_e dwc_otg_hcd_s
!DWC_CIRCLEQ_EMPTY(&hcd->free_hc_list)) {
qh = DWC_LIST_ENTRY(qh_ptr, dwc_otg_qh_t, qh_list_entry);
}
}
-@@ -1527,12 +2008,31 @@ dwc_otg_transaction_type_e dwc_otg_hcd_select_transactions(dwc_otg_hcd_t * hcd)
+@@ -1527,12 +2008,31 @@ dwc_otg_transaction_type_e dwc_otg_hcd_s
&qh->qh_list_entry);
DWC_SPINUNLOCK_IRQRESTORE(channel_lock, flags);
if(!DWC_LIST_EMPTY(&hcd->periodic_sched_assigned))
ret_val |= DWC_OTG_TRANSACTION_PERIODIC;
-@@ -1577,6 +2077,12 @@ static int queue_transaction(dwc_otg_hcd_t * hcd,
+@@ -1577,6 +2077,12 @@ static int queue_transaction(dwc_otg_hcd
hc->qh->ping_state = 0;
}
} else if (!hc->xfer_started) {
dwc_otg_hc_start_transfer(hcd->core_if, hc);
hc->qh->ping_state = 0;
}
-@@ -1629,7 +2135,7 @@ static void process_periodic_channels(dwc_otg_hcd_t * hcd)
+@@ -1629,7 +2135,7 @@ static void process_periodic_channels(dw
hptxsts_data_t tx_status;
dwc_list_link_t *qh_ptr;
dwc_otg_qh_t *qh;
int no_queue_space = 0;
int no_fifo_space = 0;
-@@ -1658,27 +2164,34 @@ static void process_periodic_channels(dwc_otg_hcd_t * hcd)
+@@ -1658,27 +2164,34 @@ static void process_periodic_channels(dw
// Do not send a split start transaction any later than frame .6
// Note, we have to schedule a periodic in .5 to make it go in .6
}
/*
-@@ -1795,25 +2308,19 @@ static void process_non_periodic_channels(dwc_otg_hcd_t * hcd)
+@@ -1795,25 +2308,19 @@ static void process_non_periodic_channel
qh = DWC_LIST_ENTRY(hcd->non_periodic_qh_ptr, dwc_otg_qh_t,
qh_list_entry);
/* Advance to next QH, skipping start-of-list entry. */
hcd->non_periodic_qh_ptr = hcd->non_periodic_qh_ptr->next;
if (hcd->non_periodic_qh_ptr == &hcd->non_periodic_sched_active) {
-diff --git a/drivers/usb/host/dwc_otg/dwc_otg_hcd.h b/drivers/usb/host/dwc_otg/dwc_otg_hcd.h
-index 0007fa1..da2986244 100644
--- a/drivers/usb/host/dwc_otg/dwc_otg_hcd.h
+++ b/drivers/usb/host/dwc_otg/dwc_otg_hcd.h
@@ -40,6 +40,8 @@
#ifdef DEBUG
uint32_t frrem_samples;
uint64_t frrem_accum;
-@@ -615,6 +623,9 @@ extern void dwc_otg_hcd_queue_transactions(dwc_otg_hcd_t * hcd,
+@@ -615,6 +623,9 @@ extern void dwc_otg_hcd_queue_transactio
int dwc_otg_hcd_allocate_port(dwc_otg_hcd_t * hcd, dwc_otg_qh_t *qh);
void dwc_otg_hcd_release_port(dwc_otg_hcd_t * dwc_otg_hcd, dwc_otg_qh_t *qh);
/** @} */
-diff --git a/drivers/usb/host/dwc_otg/dwc_otg_hcd_intr.c b/drivers/usb/host/dwc_otg/dwc_otg_hcd_intr.c
-index 64d33a5..d3e2035 100644
--- a/drivers/usb/host/dwc_otg/dwc_otg_hcd_intr.c
+++ b/drivers/usb/host/dwc_otg/dwc_otg_hcd_intr.c
@@ -34,7 +34,6 @@
#ifdef FIQ_DEBUG
char buffer[1000*16];
int wptr;
-@@ -83,12 +57,10 @@ void notrace _fiq_print(FIQDBG_T dbg_lvl, char *fmt, ...)
+@@ -83,12 +57,10 @@ void notrace _fiq_print(FIQDBG_T dbg_lvl
va_list args;
char text[17];
hfnum_data_t hfnum = { .d32 = FIQ_READ(dwc_regs_base + 0x408) };
snprintf(text, 9, "%4d%d:%d ", hfnum.b.frnum/8, hfnum.b.frnum%8, 8 - hfnum.b.frrem/937);
va_start(args, fmt);
vsnprintf(text+8, 9, fmt, args);
-@@ -96,410 +68,21 @@ void notrace _fiq_print(FIQDBG_T dbg_lvl, char *fmt, ...)
+@@ -96,410 +68,21 @@ void notrace _fiq_print(FIQDBG_T dbg_lvl
memcpy(buffer + wptr, text, 16);
wptr = (wptr + 16) % sizeof(buffer);
#ifdef DEBUG
dwc_otg_core_global_regs_t *global_regs = core_if->core_global_regs;
-@@ -516,15 +99,29 @@ int32_t dwc_otg_hcd_handle_intr(dwc_otg_hcd_t * dwc_otg_hcd)
+@@ -516,15 +99,29 @@ int32_t dwc_otg_hcd_handle_intr(dwc_otg_
DWC_SPINLOCK(dwc_otg_hcd->lock);
/* Check if HOST Mode */
if (dwc_otg_is_host_mode(core_if)) {
#ifdef DEBUG
// We should be OK doing this because the common interrupts should already have been serviced
-@@ -544,12 +141,7 @@ int32_t dwc_otg_hcd_handle_intr(dwc_otg_hcd_t * dwc_otg_hcd)
+@@ -544,12 +141,7 @@ int32_t dwc_otg_hcd_handle_intr(dwc_otg_
gintsts.d32, core_if);
#endif
hfnum.d32 = DWC_READ_REG32(&dwc_otg_hcd->core_if->host_if->host_global_regs->hfnum);
retval |= dwc_otg_hcd_handle_sof_intr(dwc_otg_hcd);
}
-@@ -604,37 +196,43 @@ int32_t dwc_otg_hcd_handle_intr(dwc_otg_hcd_t * dwc_otg_hcd)
+@@ -604,37 +196,43 @@ int32_t dwc_otg_hcd_handle_intr(dwc_otg_
}
exit_handler_routine:
- mphi_int_count = 0;
- }
- int_done++;
+- }
+-
+- // Unmask handled interrupts
+- FIQ_WRITE(dwc_regs_base + 0x18, gintmsk.d32);
+- //DWC_MODIFY_REG32((uint32_t *)IO_ADDRESS(USB_BASE + 0x8), 0 , 1);
+ gintmsk_new.d32 = *(volatile uint32_t *)&dwc_otg_hcd->fiq_state->gintmsk_saved.d32;
+ if(fiq_fsm_enable)
+ haintmsk_new.d32 = *(volatile uint32_t *)&dwc_otg_hcd->fiq_state->haintmsk_saved.d32;
+ else
+ haintmsk_new.d32 = 0x0000FFFF;
-+
+
+ /* The FIQ could have sneaked another interrupt in. If so, don't clear MPHI */
+ if ((gintmsk_new.d32 == ~0) && (haintmsk_new.d32 == 0x0000FFFF)) {
+ DWC_WRITE_REG32(dwc_otg_hcd->fiq_state->mphi_regs.intstat, (1<<16));
+ dwc_otg_hcd->fiq_state->mphi_int_count = 0;
+ }
+ int_done++;
- }
--
-- // Unmask handled interrupts
-- FIQ_WRITE(dwc_regs_base + 0x18, gintmsk.d32);
-- //DWC_MODIFY_REG32((uint32_t *)IO_ADDRESS(USB_BASE + 0x8), 0 , 1);
--
++ }
+ haintmsk.d32 = DWC_READ_REG32(&core_if->host_if->host_global_regs->haintmsk);
+ /* Re-enable interrupts that the FIQ masked (first time round) */
+ FIQ_WRITE(dwc_otg_hcd->fiq_state->dwc_regs_base + GINTMSK, gintmsk.d32);
}
}
-@@ -686,6 +284,7 @@ static inline void track_missed_sofs(uint16_t curr_frame_number)
+@@ -686,6 +284,7 @@ static inline void track_missed_sofs(uin
int32_t dwc_otg_hcd_handle_sof_intr(dwc_otg_hcd_t * hcd)
{
hfnum_data_t hfnum;
dwc_list_link_t *qh_entry;
dwc_otg_qh_t *qh;
dwc_otg_transaction_type_e tr_type;
-@@ -732,8 +331,8 @@ int32_t dwc_otg_hcd_handle_sof_intr(dwc_otg_hcd_t * hcd)
+@@ -732,8 +331,8 @@ int32_t dwc_otg_hcd_handle_sof_intr(dwc_
}
}
}
tr_type = dwc_otg_hcd_select_transactions(hcd);
if (tr_type != DWC_OTG_TRANSACTION_NONE) {
-@@ -741,10 +340,11 @@ int32_t dwc_otg_hcd_handle_sof_intr(dwc_otg_hcd_t * hcd)
+@@ -741,10 +340,11 @@ int32_t dwc_otg_hcd_handle_sof_intr(dwc_
did_something = 1;
}
return 1;
}
-@@ -1020,19 +620,21 @@ int32_t dwc_otg_hcd_handle_hc_intr(dwc_otg_hcd_t * dwc_otg_hcd)
+@@ -1020,19 +620,21 @@ int32_t dwc_otg_hcd_handle_hc_intr(dwc_o
{
int i;
int retval = 0;
local_fiq_enable();
}
-@@ -1076,9 +678,7 @@ static uint32_t get_actual_xfer_length(dwc_hc_t * hc,
+@@ -1076,9 +678,7 @@ static uint32_t get_actual_xfer_length(d
*short_read = (hctsiz.b.xfersize != 0);
}
} else if (hc->qh->do_split) {
length = qtd->ssplit_out_xfer_count;
} else {
length = hc->xfer_len;
-@@ -1325,19 +925,17 @@ static void release_channel(dwc_otg_hcd_t * hcd,
+@@ -1325,19 +925,17 @@ static void release_channel(dwc_otg_hcd_
int free_qtd;
dwc_irqflags_t flags;
dwc_spinlock_t *channel_lock = hcd->channel_lock;
/* Try to queue more transfers now that there's a free channel. */
tr_type = dwc_otg_hcd_select_transactions(hcd);
if (tr_type != DWC_OTG_TRANSACTION_NONE) {
-@@ -1858,7 +1441,7 @@ static int32_t handle_hc_nak_intr(dwc_otg_hcd_t * hcd,
+@@ -1858,7 +1441,7 @@ static int32_t handle_hc_nak_intr(dwc_ot
switch(dwc_otg_hcd_get_pipe_type(&qtd->urb->pipe_info)) {
case UE_BULK:
case UE_CONTROL:
hc->qh->nak_frame = dwc_otg_hcd_get_frame_number(hcd);
}
-@@ -2074,7 +1657,7 @@ static int32_t handle_hc_nyet_intr(dwc_otg_hcd_t * hcd,
+@@ -2074,7 +1657,7 @@ static int32_t handle_hc_nyet_intr(dwc_o
// With the FIQ running we only ever see the failed NYET
if (dwc_full_frame_num(frnum) !=
dwc_full_frame_num(hc->qh->sched_frame) ||
/*
* No longer in the same full speed frame.
* Treat this as a transaction error.
-@@ -2460,12 +2043,11 @@ static inline int halt_status_ok(dwc_otg_hcd_t * hcd,
+@@ -2460,12 +2043,11 @@ static inline int halt_status_ok(dwc_otg
static void handle_hc_chhltd_intr_dma(dwc_otg_hcd_t * hcd,
dwc_hc_t * hc,
dwc_otg_hc_regs_t * hc_regs,
/* For core with OUT NAK enhancement, the flow for high-
* speed CONTROL/BULK OUT is handled a little differently.
*/
-@@ -2495,11 +2077,9 @@ static void handle_hc_chhltd_intr_dma(dwc_otg_hcd_t * hcd,
+@@ -2495,11 +2077,9 @@ static void handle_hc_chhltd_intr_dma(dw
}
/* Read the HCINTn register to determine the cause for the halt. */
if (hcint.b.xfercomp) {
/** @todo This is here because of a possible hardware bug. Spec
-@@ -2624,15 +2204,13 @@ static void handle_hc_chhltd_intr_dma(dwc_otg_hcd_t * hcd,
+@@ -2624,15 +2204,13 @@ static void handle_hc_chhltd_intr_dma(dw
static int32_t handle_hc_chhltd_intr(dwc_otg_hcd_t * hcd,
dwc_hc_t * hc,
dwc_otg_hc_regs_t * hc_regs,
} else {
#ifdef DEBUG
if (!halt_status_ok(hcd, hc, hc_regs, qtd)) {
-@@ -2645,11 +2223,372 @@ static int32_t handle_hc_chhltd_intr(dwc_otg_hcd_t * hcd,
+@@ -2645,11 +2223,372 @@ static int32_t handle_hc_chhltd_intr(dwc
return 1;
}
hcintmsk_data_t hcintmsk;
dwc_hc_t *hc;
dwc_otg_hc_regs_t *hc_regs;
-@@ -2668,24 +2607,32 @@ int32_t dwc_otg_hcd_handle_hc_n_intr(dwc_otg_hcd_t * dwc_otg_hcd, uint32_t num)
+@@ -2668,24 +2607,32 @@ int32_t dwc_otg_hcd_handle_hc_n_intr(dwc
}
qtd = DWC_CIRCLEQ_FIRST(&hc->qh->qtd_list);
if (!dwc_otg_hcd->core_if->dma_enable) {
if (hcint.b.chhltd && hcint.d32 != 0x2) {
hcint.b.chhltd = 0;
-@@ -2703,7 +2650,7 @@ int32_t dwc_otg_hcd_handle_hc_n_intr(dwc_otg_hcd_t * dwc_otg_hcd, uint32_t num)
+@@ -2703,7 +2650,7 @@ int32_t dwc_otg_hcd_handle_hc_n_intr(dwc
hcint.b.nyet = 0;
}
if (hcint.b.chhltd) {
}
if (hcint.b.ahberr) {
retval |= handle_hc_ahberr_intr(dwc_otg_hcd, hc, hc_regs, qtd);
-diff --git a/drivers/usb/host/dwc_otg/dwc_otg_hcd_linux.c b/drivers/usb/host/dwc_otg/dwc_otg_hcd_linux.c
-index ee8eec9..07b1808 100644
--- a/drivers/usb/host/dwc_otg/dwc_otg_hcd_linux.c
+++ b/drivers/usb/host/dwc_otg/dwc_otg_hcd_linux.c
@@ -58,6 +58,7 @@
/** @name Linux HC Driver API Functions */
/** @{ */
-@@ -351,7 +353,6 @@ static int _complete(dwc_otg_hcd_t * hcd, void *urb_handle,
+@@ -351,7 +353,6 @@ static int _complete(dwc_otg_hcd_t * hcd
urb);
}
}
DWC_FREE(dwc_otg_urb);
if (!new_entry) {
DWC_ERROR("dwc_otg_hcd: complete: cannot allocate URB TQ entry\n");
-@@ -395,13 +396,9 @@ static struct dwc_otg_hcd_function_ops hcd_fops = {
+@@ -395,13 +396,9 @@ static struct dwc_otg_hcd_function_ops h
static struct fiq_handler fh = {
.name = "usb_fiq",
};
}
#ifdef DEBUG
-diff --git a/drivers/usb/host/dwc_otg/dwc_otg_hcd_queue.c b/drivers/usb/host/dwc_otg/dwc_otg_hcd_queue.c
-index db95851..8706a5c 100644
--- a/drivers/usb/host/dwc_otg/dwc_otg_hcd_queue.c
+++ b/drivers/usb/host/dwc_otg/dwc_otg_hcd_queue.c
@@ -41,7 +41,6 @@
extern bool microframe_schedule;
-@@ -576,7 +575,6 @@ static int check_max_xfer_size(dwc_otg_hcd_t * hcd, dwc_otg_qh_t * qh)
+@@ -576,7 +575,6 @@ static int check_max_xfer_size(dwc_otg_h
}
/**
* Schedules an interrupt or isochronous transfer in the periodic schedule.
-@@ -636,9 +634,9 @@ static int schedule_periodic(dwc_otg_hcd_t * hcd, dwc_otg_qh_t * qh)
+@@ -636,9 +634,9 @@ static int schedule_periodic(dwc_otg_hcd
DWC_LIST_INSERT_TAIL(&hcd->periodic_sched_ready, &qh->qh_list_entry);
}
else {
}
/* Always start in the inactive schedule. */
-@@ -679,7 +677,7 @@ int dwc_otg_hcd_qh_add(dwc_otg_hcd_t * hcd, dwc_otg_qh_t * qh)
+@@ -679,7 +677,7 @@ int dwc_otg_hcd_qh_add(dwc_otg_hcd_t * h
/* Always start in the inactive schedule. */
DWC_LIST_INSERT_TAIL(&hcd->non_periodic_sched_inactive,
&qh->qh_list_entry);
} else {
status = schedule_periodic(hcd, qh);
if ( !hcd->periodic_qh_count ) {
-@@ -739,13 +737,12 @@ void dwc_otg_hcd_qh_remove(dwc_otg_hcd_t * hcd, dwc_otg_qh_t * qh)
+@@ -739,13 +737,12 @@ void dwc_otg_hcd_qh_remove(dwc_otg_hcd_t
hcd->non_periodic_qh_ptr->next;
}
DWC_LIST_REMOVE_INIT(&qh->qh_list_entry);
intr_mask.b.sofintr = 1;
DWC_MODIFY_REG32(&hcd->core_if->core_global_regs->gintmsk,
intr_mask.d32, 0);
-@@ -770,28 +767,11 @@ void dwc_otg_hcd_qh_deactivate(dwc_otg_hcd_t * hcd, dwc_otg_qh_t * qh,
+@@ -770,28 +767,11 @@ void dwc_otg_hcd_qh_deactivate(dwc_otg_h
int sched_next_periodic_split)
{
if (dwc_qh_is_non_per(qh)) {
}
} else {
uint16_t frame_number = dwc_otg_hcd_get_frame_number(hcd);
-@@ -850,9 +830,9 @@ void dwc_otg_hcd_qh_deactivate(dwc_otg_hcd_t * hcd, dwc_otg_qh_t * qh,
+@@ -850,9 +830,9 @@ void dwc_otg_hcd_qh_deactivate(dwc_otg_h
DWC_LIST_MOVE_HEAD(&hcd->periodic_sched_ready,
&qh->qh_list_entry);
} else {
}
DWC_LIST_MOVE_HEAD
-@@ -943,6 +923,9 @@ int dwc_otg_hcd_qtd_add(dwc_otg_qtd_t * qtd,
+@@ -943,6 +923,9 @@ int dwc_otg_hcd_qtd_add(dwc_otg_qtd_t *
if (*qh == NULL) {
retval = -DWC_E_NO_MEMORY;
goto done;
}
}
retval = dwc_otg_hcd_qh_add(hcd, *qh);
-diff --git a/drivers/usb/host/dwc_otg/dwc_otg_mphi_fix.c b/drivers/usb/host/dwc_otg/dwc_otg_mphi_fix.c
-deleted file mode 100755
-index 50b94a8..0000000
--- a/drivers/usb/host/dwc_otg/dwc_otg_mphi_fix.c
+++ /dev/null
@@ -1,113 +0,0 @@
-
- return;
-}
-diff --git a/drivers/usb/host/dwc_otg/dwc_otg_mphi_fix.h b/drivers/usb/host/dwc_otg/dwc_otg_mphi_fix.h
-deleted file mode 100755
-index ca17379..0000000
--- a/drivers/usb/host/dwc_otg/dwc_otg_mphi_fix.h
+++ /dev/null
@@ -1,48 +0,0 @@
-extern bool fiq_fix_enable, nak_holdoff_enable, fiq_split_enable;
-
-#endif
-diff --git a/drivers/usb/host/dwc_otg/dwc_otg_pcd_linux.c b/drivers/usb/host/dwc_otg/dwc_otg_pcd_linux.c
-index 5d310df..4b32941 100644
--- a/drivers/usb/host/dwc_otg/dwc_otg_pcd_linux.c
+++ b/drivers/usb/host/dwc_otg/dwc_otg_pcd_linux.c
@@ -59,6 +59,8 @@
free_wrapper(gadget_wrapper);
return -EBUSY;
}
---
-1.9.1
-
create mode 100644 drivers/media/platform/bcm2835/mmal-vchiq.c
create mode 100644 drivers/media/platform/bcm2835/mmal-vchiq.h
-diff --git a/Documentation/video4linux/bcm2835-v4l2.txt b/Documentation/video4linux/bcm2835-v4l2.txt
-new file mode 100644
-index 0000000..c585a8f
--- /dev/null
+++ b/Documentation/video4linux/bcm2835-v4l2.txt
@@ -0,0 +1,60 @@
+List of available formats:
+
+$ v4l2-ctl --list-formats
-diff --git a/drivers/media/platform/Kconfig b/drivers/media/platform/Kconfig
-index b2a4403..c1f82ec 100644
--- a/drivers/media/platform/Kconfig
+++ b/drivers/media/platform/Kconfig
@@ -118,6 +118,7 @@ config VIDEO_S3C_CAMIF
endif # V4L_PLATFORM_DRIVERS
-diff --git a/drivers/media/platform/Makefile b/drivers/media/platform/Makefile
-index e5269da..6e01549 100644
--- a/drivers/media/platform/Makefile
+++ b/drivers/media/platform/Makefile
@@ -51,4 +51,6 @@ obj-y += davinci/
+obj-$(CONFIG_VIDEO_BCM2835) += bcm2835/
+
ccflags-y += -I$(srctree)/drivers/media/i2c
-diff --git a/drivers/media/platform/bcm2835/Kconfig b/drivers/media/platform/bcm2835/Kconfig
-new file mode 100644
-index 0000000..a8fd172
--- /dev/null
+++ b/drivers/media/platform/bcm2835/Kconfig
@@ -0,0 +1,25 @@
+
+
+endif # VIDEO_BM2835
-diff --git a/drivers/media/platform/bcm2835/Makefile b/drivers/media/platform/bcm2835/Makefile
-new file mode 100644
-index 0000000..f17c79c
--- /dev/null
+++ b/drivers/media/platform/bcm2835/Makefile
@@ -0,0 +1,5 @@
+obj-$(CONFIG_VIDEO_BCM2835_MMAL) += bcm2835-v4l2.o
+
+ccflags-$(CONFIG_VIDEO_BCM2835) += -Idrivers/misc/vc04_services -Idrivers/misc/vc04_services/interface/vcos/linuxkernel -D__VCCOREVER__=0x04000000
-diff --git a/drivers/media/platform/bcm2835/bcm2835-camera.c b/drivers/media/platform/bcm2835/bcm2835-camera.c
-new file mode 100644
-index 0000000..47fe45d
--- /dev/null
+++ b/drivers/media/platform/bcm2835/bcm2835-camera.c
@@ -0,0 +1,1478 @@
+
+module_init(bm2835_mmal_init);
+module_exit(bm2835_mmal_exit);
-diff --git a/drivers/media/platform/bcm2835/bcm2835-camera.h b/drivers/media/platform/bcm2835/bcm2835-camera.h
-new file mode 100644
-index 0000000..883eab7
--- /dev/null
+++ b/drivers/media/platform/bcm2835/bcm2835-camera.h
@@ -0,0 +1,113 @@
+ (pix_fmt)->pixelformat, (pix_fmt)->bytesperline, \
+ (pix_fmt)->sizeimage, (pix_fmt)->colorspace, (pix_fmt)->priv); \
+}
-diff --git a/drivers/media/platform/bcm2835/controls.c b/drivers/media/platform/bcm2835/controls.c
-new file mode 100644
-index 0000000..d1408e5
--- /dev/null
+++ b/drivers/media/platform/bcm2835/controls.c
@@ -0,0 +1,725 @@
+
+ return 0;
+}
-diff --git a/drivers/media/platform/bcm2835/mmal-common.h b/drivers/media/platform/bcm2835/mmal-common.h
-new file mode 100644
-index 0000000..602b4a7
--- /dev/null
+++ b/drivers/media/platform/bcm2835/mmal-common.h
@@ -0,0 +1,52 @@
+ u32 v;
+};
+
-diff --git a/drivers/media/platform/bcm2835/mmal-encodings.h b/drivers/media/platform/bcm2835/mmal-encodings.h
-new file mode 100644
-index 0000000..856e80e
--- /dev/null
+++ b/drivers/media/platform/bcm2835/mmal-encodings.h
@@ -0,0 +1,93 @@
+#define MMAL_ENCODING_VARIANT_H264_AVC1 MMAL_FOURCC('A', 'V', 'C', '1')
+/** Implicitly delineated NAL units without emulation prevention */
+#define MMAL_ENCODING_VARIANT_H264_RAW MMAL_FOURCC('R', 'A', 'W', ' ')
-diff --git a/drivers/media/platform/bcm2835/mmal-msg-common.h b/drivers/media/platform/bcm2835/mmal-msg-common.h
-new file mode 100644
-index 0000000..66e8a6e
--- /dev/null
+++ b/drivers/media/platform/bcm2835/mmal-msg-common.h
@@ -0,0 +1,50 @@
+};
+
+#endif /* MMAL_MSG_COMMON_H */
-diff --git a/drivers/media/platform/bcm2835/mmal-msg-format.h b/drivers/media/platform/bcm2835/mmal-msg-format.h
-new file mode 100644
-index 0000000..123d86e
--- /dev/null
+++ b/drivers/media/platform/bcm2835/mmal-msg-format.h
@@ -0,0 +1,81 @@
+};
+
+#endif /* MMAL_MSG_FORMAT_H */
-diff --git a/drivers/media/platform/bcm2835/mmal-msg-port.h b/drivers/media/platform/bcm2835/mmal-msg-port.h
-new file mode 100644
-index 0000000..a55c1ea
--- /dev/null
+++ b/drivers/media/platform/bcm2835/mmal-msg-port.h
@@ -0,0 +1,107 @@
+ */
+
+};
-diff --git a/drivers/media/platform/bcm2835/mmal-msg.h b/drivers/media/platform/bcm2835/mmal-msg.h
-new file mode 100644
-index 0000000..67b1076
--- /dev/null
+++ b/drivers/media/platform/bcm2835/mmal-msg.h
@@ -0,0 +1,404 @@
+ u8 payload[MMAL_MSG_MAX_PAYLOAD];
+ } u;
+};
-diff --git a/drivers/media/platform/bcm2835/mmal-parameters.h b/drivers/media/platform/bcm2835/mmal-parameters.h
-new file mode 100644
-index 0000000..c611b58
--- /dev/null
+++ b/drivers/media/platform/bcm2835/mmal-parameters.h
@@ -0,0 +1,539 @@
+ u32 num_effect_params;
+ u32 effect_parameter[MMAL_MAX_IMAGEFX_PARAMETERS];
+};
-diff --git a/drivers/media/platform/bcm2835/mmal-vchiq.c b/drivers/media/platform/bcm2835/mmal-vchiq.c
-new file mode 100644
-index 0000000..a06fb44
--- /dev/null
+++ b/drivers/media/platform/bcm2835/mmal-vchiq.c
@@ -0,0 +1,1916 @@
+ kfree(instance);
+ return -ENODEV;
+}
-diff --git a/drivers/media/platform/bcm2835/mmal-vchiq.h b/drivers/media/platform/bcm2835/mmal-vchiq.h
-new file mode 100644
-index 0000000..9d1d11e
--- /dev/null
+++ b/drivers/media/platform/bcm2835/mmal-vchiq.h
@@ -0,0 +1,178 @@
+ struct mmal_buffer *buf);
+
+#endif /* MMAL_VCHIQ_H */
---
-1.9.1
-
drivers/media/platform/bcm2835/mmal-vchiq.c | 4 +-
8 files changed, 1292 insertions(+), 178 deletions(-)
-diff --git a/arch/arm/configs/bcmrpi_defconfig b/arch/arm/configs/bcmrpi_defconfig
-index e89e430..d70da44 100644
--- a/arch/arm/configs/bcmrpi_defconfig
+++ b/arch/arm/configs/bcmrpi_defconfig
@@ -694,6 +694,9 @@ CONFIG_DVB_B2C2_FLEXCOP_USB=m
CONFIG_RADIO_SI470X=y
CONFIG_USB_SI470X=m
CONFIG_I2C_SI470X=m
-diff --git a/drivers/media/platform/bcm2835/bcm2835-camera.c b/drivers/media/platform/bcm2835/bcm2835-camera.c
-index 47fe45d..f809b83 100644
--- a/drivers/media/platform/bcm2835/bcm2835-camera.c
+++ b/drivers/media/platform/bcm2835/bcm2835-camera.c
@@ -36,7 +36,8 @@
};
static struct mmal_fmt *get_format(struct v4l2_format *f)
-@@ -229,7 +336,8 @@ static void buffer_cb(struct vchiq_mmal_instance *instance,
+@@ -229,7 +336,8 @@ static void buffer_cb(struct vchiq_mmal_
}
} else {
if (dev->capture.frame_count) {
s64 runtime_us = pts -
dev->capture.vc_start_timestamp;
u32 div = 0;
-@@ -250,7 +358,7 @@ static void buffer_cb(struct vchiq_mmal_instance *instance,
+@@ -250,7 +358,7 @@ static void buffer_cb(struct vchiq_mmal_
USEC_PER_SEC;
}
v4l2_dbg(1, bcm2835_v4l2_debug, &dev->v4l2_dev,
"with offset %llu to %d.%06d\n",
(int)dev->capture.kernel_start_ts.
tv_sec,
-@@ -425,7 +533,15 @@ static int start_streaming(struct vb2_queue *vq, unsigned int count)
+@@ -425,7 +533,15 @@ static int start_streaming(struct vb2_qu
vchiq_mmal_port_enable(dev->instance, dev->capture.port, buffer_cb);
if (ret) {
v4l2_err(&dev->v4l2_dev,
return -1;
}
-@@ -530,6 +646,7 @@ static int vidioc_enum_fmt_vid_overlay(struct file *file, void *priv,
+@@ -530,6 +646,7 @@ static int vidioc_enum_fmt_vid_overlay(s
strlcpy(f->description, fmt->name, sizeof(f->description));
f->pixelformat = fmt->fourcc;
return 0;
}
-@@ -647,10 +764,18 @@ static int vidioc_g_fbuf(struct file *file, void *fh,
+@@ -647,10 +764,18 @@ static int vidioc_g_fbuf(struct file *fi
{
/* The video overlay must stay within the framebuffer and can't be
positioned independently. */
return 0;
}
-@@ -717,6 +842,8 @@ static int vidioc_enum_fmt_vid_cap(struct file *file, void *priv,
+@@ -717,6 +842,8 @@ static int vidioc_enum_fmt_vid_cap(struc
strlcpy(f->description, fmt->name, sizeof(f->description));
f->pixelformat = fmt->fourcc;
return 0;
}
-@@ -729,20 +856,13 @@ static int vidioc_g_fmt_vid_cap(struct file *file, void *priv,
+@@ -729,20 +856,13 @@ static int vidioc_g_fmt_vid_cap(struct f
f->fmt.pix.height = dev->capture.height;
f->fmt.pix.field = V4L2_FIELD_NONE;
f->fmt.pix.pixelformat = dev->capture.fmt->fourcc;
f->fmt.pix.priv = 0;
v4l2_dump_pix_format(1, bcm2835_v4l2_debug, &dev->v4l2_dev, &f->fmt.pix,
-@@ -766,21 +886,35 @@ static int vidioc_try_fmt_vid_cap(struct file *file, void *priv,
+@@ -766,21 +886,35 @@ static int vidioc_try_fmt_vid_cap(struct
}
f->fmt.pix.field = V4L2_FIELD_NONE;
v4l2_dump_pix_format(1, bcm2835_v4l2_debug, &dev->v4l2_dev, &f->fmt.pix,
__func__);
return 0;
-@@ -818,8 +952,8 @@ static int mmal_setup_components(struct bm2835_mmal_dev *dev,
+@@ -818,8 +952,8 @@ static int mmal_setup_components(struct
switch (mfmt->mmal_component) {
case MMAL_COMPONENT_CAMERA:
/* Make a further decision on port based on resolution */
camera_port = port =
&dev->component[MMAL_COMPONENT_CAMERA]->
output[MMAL_CAMERA_PORT_VIDEO];
-@@ -861,8 +995,9 @@ static int mmal_setup_components(struct bm2835_mmal_dev *dev,
+@@ -861,8 +995,9 @@ static int mmal_setup_components(struct
camera_port->es.video.crop.y = 0;
camera_port->es.video.crop.width = f->fmt.pix.width;
camera_port->es.video.crop.height = f->fmt.pix.height;
ret = vchiq_mmal_port_set_format(dev->instance, camera_port);
-@@ -896,8 +1031,10 @@ static int mmal_setup_components(struct bm2835_mmal_dev *dev,
+@@ -896,8 +1031,10 @@ static int mmal_setup_components(struct
preview_port->es.video.crop.y = 0;
preview_port->es.video.crop.width = f->fmt.pix.width;
preview_port->es.video.crop.height = f->fmt.pix.height;
ret = vchiq_mmal_port_set_format(dev->instance, preview_port);
if (overlay_enabled) {
ret = vchiq_mmal_port_connect_tunnel(
-@@ -913,7 +1050,9 @@ static int mmal_setup_components(struct bm2835_mmal_dev *dev,
+@@ -913,7 +1050,9 @@ static int mmal_setup_components(struct
if (ret) {
v4l2_dbg(1, bcm2835_v4l2_debug, &dev->v4l2_dev,
/* ensure capture is not going to be tried */
dev->capture.port = NULL;
} else {
-@@ -927,69 +1066,91 @@ static int mmal_setup_components(struct bm2835_mmal_dev *dev,
+@@ -927,69 +1066,91 @@ static int mmal_setup_components(struct
camera_port->current_buffer.num =
camera_port->recommended_buffer.num;
}
} else {
/* configure buffering */
-@@ -1001,13 +1162,20 @@ static int mmal_setup_components(struct bm2835_mmal_dev *dev,
+@@ -1001,13 +1162,20 @@ static int mmal_setup_components(struct
if (!ret) {
dev->capture.fmt = mfmt;
dev->capture.stride = f->fmt.pix.bytesperline;
}
}
-@@ -1048,14 +1216,115 @@ static int vidioc_s_fmt_vid_cap(struct file *file, void *priv,
+@@ -1048,14 +1216,115 @@ static int vidioc_s_fmt_vid_cap(struct f
}
ret = mmal_setup_components(dev, f);
static const struct v4l2_ioctl_ops camera0_ioctl_ops = {
/* overlay */
.vidioc_enum_fmt_vid_overlay = vidioc_enum_fmt_vid_overlay,
-@@ -1084,6 +1353,51 @@ static const struct v4l2_ioctl_ops camera0_ioctl_ops = {
+@@ -1084,6 +1353,51 @@ static const struct v4l2_ioctl_ops camer
.vidioc_querybuf = vb2_ioctl_querybuf,
.vidioc_qbuf = vb2_ioctl_qbuf,
.vidioc_dqbuf = vb2_ioctl_dqbuf,
.vidioc_streamon = vb2_ioctl_streamon,
.vidioc_streamoff = vb2_ioctl_streamoff,
-@@ -1122,8 +1436,10 @@ static int set_camera_parameters(struct vchiq_mmal_instance *instance,
+@@ -1122,8 +1436,10 @@ static int set_camera_parameters(struct
.max_stills_h = MAX_HEIGHT,
.stills_yuv422 = 1,
.one_shot_stills = 1,
.num_preview_video_frames = 3,
.stills_capture_circular_buffer_height = 0,
.fast_preview_resume = 0,
-@@ -1141,6 +1457,7 @@ static int __init mmal_init(struct bm2835_mmal_dev *dev)
+@@ -1141,6 +1457,7 @@ static int __init mmal_init(struct bm283
{
int ret;
struct mmal_es_format *format;
ret = vchiq_mmal_init(&dev->instance);
if (ret < 0)
-@@ -1176,8 +1493,8 @@ static int __init mmal_init(struct bm2835_mmal_dev *dev)
+@@ -1176,8 +1493,8 @@ static int __init mmal_init(struct bm283
format->es->video.crop.y = 0;
format->es->video.crop.width = 1024;
format->es->video.crop.height = 768;
format =
&dev->component[MMAL_COMPONENT_CAMERA]->
-@@ -1192,8 +1509,14 @@ static int __init mmal_init(struct bm2835_mmal_dev *dev)
+@@ -1192,8 +1509,14 @@ static int __init mmal_init(struct bm283
format->es->video.crop.y = 0;
format->es->video.crop.width = 1024;
format->es->video.crop.height = 768;
format =
&dev->component[MMAL_COMPONENT_CAMERA]->
-@@ -1207,13 +1530,22 @@ static int __init mmal_init(struct bm2835_mmal_dev *dev)
+@@ -1207,13 +1530,22 @@ static int __init mmal_init(struct bm283
format->es->video.crop.y = 0;
format->es->video.crop.width = 2592;
format->es->video.crop.height = 1944;
/* get the preview component ready */
ret = vchiq_mmal_component_init(
-@@ -1260,6 +1592,14 @@ static int __init mmal_init(struct bm2835_mmal_dev *dev)
+@@ -1260,6 +1592,14 @@ static int __init mmal_init(struct bm283
}
{
unsigned int enable = 1;
vchiq_mmal_port_parameter_set(
dev->instance,
-@@ -1312,6 +1652,11 @@ static int __init bm2835_mmal_init_device(struct bm2835_mmal_dev *dev,
+@@ -1312,6 +1652,11 @@ static int __init bm2835_mmal_init_devic
int ret;
*vfd = vdev_template;
vfd->v4l2_dev = &dev->v4l2_dev;
-@@ -1328,8 +1673,9 @@ static int __init bm2835_mmal_init_device(struct bm2835_mmal_dev *dev,
+@@ -1328,8 +1673,9 @@ static int __init bm2835_mmal_init_devic
if (ret < 0)
return ret;
return 0;
}
-@@ -1337,9 +1683,9 @@ static int __init bm2835_mmal_init_device(struct bm2835_mmal_dev *dev,
+@@ -1337,9 +1683,9 @@ static int __init bm2835_mmal_init_devic
static struct v4l2_format default_v4l2_format = {
.fmt.pix.pixelformat = V4L2_PIX_FMT_JPEG,
.fmt.pix.width = 1024,
ret = mmal_setup_components(dev, &default_v4l2_format);
if (ret < 0) {
v4l2_err(&dev->v4l2_dev,
-diff --git a/drivers/media/platform/bcm2835/bcm2835-camera.h b/drivers/media/platform/bcm2835/bcm2835-camera.h
-index 883eab7..7fe9f65 100644
--- a/drivers/media/platform/bcm2835/bcm2835-camera.h
+++ b/drivers/media/platform/bcm2835/bcm2835-camera.h
@@ -15,7 +15,7 @@
/* Debug helpers */
-diff --git a/drivers/media/platform/bcm2835/controls.c b/drivers/media/platform/bcm2835/controls.c
-index d1408e5..3017b94 100644
--- a/drivers/media/platform/bcm2835/controls.c
+++ b/drivers/media/platform/bcm2835/controls.c
@@ -30,11 +30,23 @@
};
struct v4l2_to_mmal_effects_setting {
-@@ -126,6 +145,25 @@ static const struct v4l2_to_mmal_effects_setting
+@@ -126,6 +145,25 @@ static const struct v4l2_to_mmal_effects
1, 1, 0, 0, 0, {0, 0, 0, 0, 0} }
};
/* control handlers*/
-@@ -133,10 +171,7 @@ static int ctrl_set_rational(struct bm2835_mmal_dev *dev,
+@@ -133,10 +171,7 @@ static int ctrl_set_rational(struct bm28
struct v4l2_ctrl *ctrl,
const struct bm2835_mmal_v4l2_ctrl *mmal_ctrl)
{
struct vchiq_mmal_port *control;
control = &dev->component[MMAL_COMPONENT_CAMERA]->control;
-@@ -166,6 +201,41 @@ static int ctrl_set_value(struct bm2835_mmal_dev *dev,
+@@ -166,6 +201,41 @@ static int ctrl_set_value(struct bm2835_
&u32_value, sizeof(u32_value));
}
static int ctrl_set_rotate(struct bm2835_mmal_dev *dev,
struct v4l2_ctrl *ctrl,
const struct bm2835_mmal_v4l2_ctrl *mmal_ctrl)
-@@ -245,37 +315,97 @@ static int ctrl_set_exposure(struct bm2835_mmal_dev *dev,
+@@ -245,37 +315,97 @@ static int ctrl_set_exposure(struct bm28
struct v4l2_ctrl *ctrl,
const struct bm2835_mmal_v4l2_ctrl *mmal_ctrl)
{
struct v4l2_ctrl *ctrl,
const struct bm2835_mmal_v4l2_ctrl *mmal_ctrl)
{
-@@ -285,24 +415,18 @@ static int ctrl_set_metering_mode(struct bm2835_mmal_dev *dev,
+@@ -285,24 +415,18 @@ static int ctrl_set_metering_mode(struct
control = &dev->component[MMAL_COMPONENT_CAMERA]->control;
switch (ctrl->val) {
}
return vchiq_mmal_port_parameter_set(dev->instance, control,
-@@ -367,6 +491,29 @@ static int ctrl_set_awb_mode(struct bm2835_mmal_dev *dev,
+@@ -367,6 +491,29 @@ static int ctrl_set_awb_mode(struct bm28
&u32_value, sizeof(u32_value));
}
static int ctrl_set_image_effect(struct bm2835_mmal_dev *dev,
struct v4l2_ctrl *ctrl,
const struct bm2835_mmal_v4l2_ctrl *mmal_ctrl)
-@@ -443,8 +590,8 @@ static int ctrl_set_colfx(struct bm2835_mmal_dev *dev,
+@@ -443,8 +590,8 @@ static int ctrl_set_colfx(struct bm2835_
&dev->colourfx, sizeof(dev->colourfx));
v4l2_dbg(1, bcm2835_v4l2_debug, &dev->v4l2_dev,
(ret == 0 ? 0 : -EINVAL));
return (ret == 0 ? 0 : EINVAL);
}
-@@ -494,7 +641,7 @@ static int ctrl_set_bitrate_mode(struct bm2835_mmal_dev *dev,
+@@ -494,7 +641,7 @@ static int ctrl_set_bitrate_mode(struct
return 0;
}
struct v4l2_ctrl *ctrl,
const struct bm2835_mmal_v4l2_ctrl *mmal_ctrl)
{
-@@ -510,12 +657,247 @@ static int ctrl_set_q_factor(struct bm2835_mmal_dev *dev,
+@@ -510,12 +657,247 @@ static int ctrl_set_q_factor(struct bm28
&u32_value, sizeof(u32_value));
}
if ((mmal_ctrl == NULL) ||
(mmal_ctrl->id != ctrl->id) ||
-@@ -524,7 +906,13 @@ static int bm2835_mmal_s_ctrl(struct v4l2_ctrl *ctrl)
+@@ -524,7 +906,13 @@ static int bm2835_mmal_s_ctrl(struct v4l
return -EINVAL;
}
}
static const struct v4l2_ctrl_ops bm2835_mmal_ctrl_ops = {
-@@ -537,40 +925,54 @@ static const struct bm2835_mmal_v4l2_ctrl v4l2_ctrls[V4L2_CTRL_COUNT] = {
+@@ -537,40 +925,54 @@ static const struct bm2835_mmal_v4l2_ctr
{
V4L2_CID_SATURATION, MMAL_CONTROL_TYPE_STD,
-100, 100, 0, 1, NULL,
},
/* todo this needs mixing in with set exposure
{
-@@ -578,83 +980,258 @@ static const struct bm2835_mmal_v4l2_ctrl v4l2_ctrls[V4L2_CTRL_COUNT] = {
+@@ -578,83 +980,258 @@ static const struct bm2835_mmal_v4l2_ctr
},
*/
{
int bm2835_mmal_init_controls(struct bm2835_mmal_dev *dev,
struct v4l2_ctrl_handler *hdl)
{
-@@ -674,10 +1251,30 @@ int bm2835_mmal_init_controls(struct bm2835_mmal_dev *dev,
+@@ -674,10 +1251,30 @@ int bm2835_mmal_init_controls(struct bm2
break;
case MMAL_CONTROL_TYPE_STD_MENU:
case MMAL_CONTROL_TYPE_INT_MENU:
dev->ctrls[c] = v4l2_ctrl_new_int_menu(hdl,
-diff --git a/drivers/media/platform/bcm2835/mmal-common.h b/drivers/media/platform/bcm2835/mmal-common.h
-index 602b4a7..076f9a8 100644
--- a/drivers/media/platform/bcm2835/mmal-common.h
+++ b/drivers/media/platform/bcm2835/mmal-common.h
@@ -26,6 +26,7 @@
u32 mmal;
int depth;
u32 mmal_component; /* MMAL component index to be used to encode */
-diff --git a/drivers/media/platform/bcm2835/mmal-encodings.h b/drivers/media/platform/bcm2835/mmal-encodings.h
-index 856e80e..024d620 100644
--- a/drivers/media/platform/bcm2835/mmal-encodings.h
+++ b/drivers/media/platform/bcm2835/mmal-encodings.h
@@ -12,6 +12,8 @@
+/* @} MmalColorSpace List */
+
+#endif /* MMAL_ENCODINGS_H */
-diff --git a/drivers/media/platform/bcm2835/mmal-parameters.h b/drivers/media/platform/bcm2835/mmal-parameters.h
-index c611b58..aa0fd18 100644
--- a/drivers/media/platform/bcm2835/mmal-parameters.h
+++ b/drivers/media/platform/bcm2835/mmal-parameters.h
@@ -57,7 +57,8 @@ enum mmal_parameter_common_type {
};
enum mmal_parameter_camera_config_timestamp_mode {
-@@ -176,6 +184,14 @@ enum mmal_parameter_camera_config_timestamp_mode {
+@@ -176,6 +184,14 @@ enum mmal_parameter_camera_config_timest
*/
};
};
/** Valid mirror modes */
-diff --git a/drivers/media/platform/bcm2835/mmal-vchiq.c b/drivers/media/platform/bcm2835/mmal-vchiq.c
-index a06fb44..76f249e 100644
--- a/drivers/media/platform/bcm2835/mmal-vchiq.c
+++ b/drivers/media/platform/bcm2835/mmal-vchiq.c
-@@ -742,7 +742,7 @@ static int send_synchronous_mmal_msg(struct vchiq_mmal_instance *instance,
+@@ -742,7 +742,7 @@ static int send_synchronous_mmal_msg(str
return ret;
}
if (ret <= 0) {
pr_err("error %d waiting for sync completion\n", ret);
if (ret == 0)
-@@ -1326,7 +1326,7 @@ static int port_parameter_get(struct vchiq_mmal_instance *instance,
+@@ -1326,7 +1326,7 @@ static int port_parameter_get(struct vch
memcpy(value, &rmsg->u.port_parameter_get_reply.value,
rmsg->u.port_parameter_get_reply.size);
ret, port->component->handle, port->handle, parameter_id);
release_msg:
---
-1.9.1
-
sound/arm/bcm2835.h | 9 ++++
4 files changed, 250 insertions(+), 19 deletions(-)
-diff --git a/sound/arm/bcm2835-ctl.c b/sound/arm/bcm2835-ctl.c
-index 8c5334a..aad905f 100755
--- a/sound/arm/bcm2835-ctl.c
+++ b/sound/arm/bcm2835-ctl.c
@@ -30,6 +30,7 @@
#include "bcm2835.h"
-@@ -183,6 +184,122 @@ static struct snd_kcontrol_new snd_bcm2835_ctl[] = {
+@@ -183,6 +184,122 @@ static struct snd_kcontrol_new snd_bcm28
},
};
int snd_bcm2835_new_ctl(bcm2835_chip_t * chip)
{
int err;
-@@ -196,5 +313,11 @@ int snd_bcm2835_new_ctl(bcm2835_chip_t * chip)
+@@ -196,5 +313,11 @@ int snd_bcm2835_new_ctl(bcm2835_chip_t *
if (err < 0)
return err;
}
+ }
return 0;
}
-diff --git a/sound/arm/bcm2835-pcm.c b/sound/arm/bcm2835-pcm.c
-index b4084bb..ebd3f62 100755
--- a/sound/arm/bcm2835-pcm.c
+++ b/sound/arm/bcm2835-pcm.c
@@ -15,6 +15,8 @@
#include "bcm2835.h"
/* hardware definition */
-@@ -34,6 +36,23 @@ static struct snd_pcm_hardware snd_bcm2835_playback_hw = {
+@@ -34,6 +36,23 @@ static struct snd_pcm_hardware snd_bcm28
.periods_max = 128,
};
static void snd_bcm2835_playback_free(struct snd_pcm_runtime *runtime)
{
audio_info("Freeing up alsa stream here ..\n");
-@@ -89,7 +108,8 @@ static irqreturn_t bcm2835_playback_fifo_irq(int irq, void *dev_id)
+@@ -89,7 +108,8 @@ static irqreturn_t bcm2835_playback_fifo
}
/* open callback */
{
bcm2835_chip_t *chip = snd_pcm_substream_chip(substream);
struct snd_pcm_runtime *runtime = substream->runtime;
-@@ -102,6 +122,11 @@ static int snd_bcm2835_playback_open(struct snd_pcm_substream *substream)
+@@ -102,6 +122,11 @@ static int snd_bcm2835_playback_open(str
audio_info("Alsa open (%d)\n", substream->number);
idx = substream->number;
if (idx > MAX_SUBSTREAMS) {
audio_error
("substream(%d) device doesn't exist max(%d) substreams allowed\n",
-@@ -143,13 +168,20 @@ static int snd_bcm2835_playback_open(struct snd_pcm_substream *substream)
+@@ -143,13 +168,20 @@ static int snd_bcm2835_playback_open(str
}
runtime->private_data = alsa_stream;
runtime->private_free = snd_bcm2835_playback_free;
/* close callback */
static int snd_bcm2835_playback_close(struct snd_pcm_substream *substream)
{
-@@ -166,6 +208,7 @@ static int snd_bcm2835_playback_close(struct snd_pcm_substream *substream)
+@@ -166,6 +208,7 @@ static int snd_bcm2835_playback_close(st
struct snd_pcm_runtime *runtime = substream->runtime;
bcm2835_alsa_stream_t *alsa_stream = runtime->private_data;
audio_info(" .. IN\n");
audio_info("Alsa close\n");
-@@ -196,6 +239,8 @@ static int snd_bcm2835_playback_close(struct snd_pcm_substream *substream)
+@@ -196,6 +239,8 @@ static int snd_bcm2835_playback_close(st
* runtime->private_free callback we registered in *_open above
*/
audio_info(" .. OUT\n");
return 0;
-@@ -205,10 +250,9 @@ static int snd_bcm2835_playback_close(struct snd_pcm_substream *substream)
+@@ -205,10 +250,9 @@ static int snd_bcm2835_playback_close(st
static int snd_bcm2835_pcm_hw_params(struct snd_pcm_substream *substream,
struct snd_pcm_hw_params *params)
{
audio_info(" .. IN\n");
-@@ -219,19 +263,9 @@ static int snd_bcm2835_pcm_hw_params(struct snd_pcm_substream *substream,
+@@ -219,19 +263,9 @@ static int snd_bcm2835_pcm_hw_params(str
return err;
}
audio_info(" .. OUT\n");
return err;
-@@ -247,11 +281,35 @@ static int snd_bcm2835_pcm_hw_free(struct snd_pcm_substream *substream)
+@@ -247,11 +281,35 @@ static int snd_bcm2835_pcm_hw_free(struc
/* prepare callback */
static int snd_bcm2835_pcm_prepare(struct snd_pcm_substream *substream)
{
memset(&alsa_stream->pcm_indirect, 0, sizeof(alsa_stream->pcm_indirect));
alsa_stream->pcm_indirect.hw_buffer_size =
-@@ -392,6 +450,18 @@ static struct snd_pcm_ops snd_bcm2835_playback_ops = {
+@@ -392,6 +450,18 @@ static struct snd_pcm_ops snd_bcm2835_pl
.ack = snd_bcm2835_pcm_ack,
};
/* create a pcm device */
int snd_bcm2835_new_pcm(bcm2835_chip_t * chip)
{
-@@ -424,3 +494,25 @@ int snd_bcm2835_new_pcm(bcm2835_chip_t * chip)
+@@ -424,3 +494,25 @@ int snd_bcm2835_new_pcm(bcm2835_chip_t *
return 0;
}
+
+ return 0;
+}
-diff --git a/sound/arm/bcm2835.c b/sound/arm/bcm2835.c
-index e2047a7..4136760 100755
--- a/sound/arm/bcm2835.c
+++ b/sound/arm/bcm2835.c
-@@ -104,7 +104,7 @@ static int snd_bcm2835_alsa_probe(struct platform_device *pdev)
+@@ -104,7 +104,7 @@ static int snd_bcm2835_alsa_probe(struct
goto out;
snd_card_set_dev(g_card, &pdev->dev);
strcpy(g_card->shortname, "bcm2835 ALSA");
sprintf(g_card->longname, "%s", g_card->shortname);
-@@ -121,6 +121,12 @@ static int snd_bcm2835_alsa_probe(struct platform_device *pdev)
+@@ -121,6 +121,12 @@ static int snd_bcm2835_alsa_probe(struct
goto out_bcm2835_new_pcm;
}
out_bcm2835_new_pcm:
out_bcm2835_create:
BUG_ON(!g_card);
-diff --git a/sound/arm/bcm2835.h b/sound/arm/bcm2835.h
-index 36afee3..8c2fe26 100755
--- a/sound/arm/bcm2835.h
+++ b/sound/arm/bcm2835.h
@@ -97,6 +97,7 @@ typedef enum {
int bcm2835_audio_open(bcm2835_alsa_stream_t * alsa_stream);
int bcm2835_audio_close(bcm2835_alsa_stream_t * alsa_stream);
---
-1.9.1
-
3 files changed, 595 insertions(+)
create mode 100644 drivers/dma/bcm2708-dmaengine.c
-diff --git a/drivers/dma/Kconfig b/drivers/dma/Kconfig
-index 605b016..edd5842 100644
--- a/drivers/dma/Kconfig
+++ b/drivers/dma/Kconfig
@@ -312,6 +312,12 @@ config DMA_BCM2835
config TI_CPPI41
tristate "AM33xx CPPI41 DMA support"
depends on ARCH_OMAP
-diff --git a/drivers/dma/Makefile b/drivers/dma/Makefile
-index a029d0f4..f4d9516 100644
--- a/drivers/dma/Makefile
+++ b/drivers/dma/Makefile
@@ -39,6 +39,7 @@ obj-$(CONFIG_DMA_SA11X0) += sa11x0-dma.o
obj-$(CONFIG_MMP_PDMA) += mmp_pdma.o
obj-$(CONFIG_DMA_JZ4740) += dma-jz4740.o
obj-$(CONFIG_TI_CPPI41) += cppi41.o
-diff --git a/drivers/dma/bcm2708-dmaengine.c b/drivers/dma/bcm2708-dmaengine.c
-new file mode 100644
-index 0000000..b244293
--- /dev/null
+++ b/drivers/dma/bcm2708-dmaengine.c
@@ -0,0 +1,588 @@
+MODULE_DESCRIPTION("BCM2708 DMA engine driver");
+MODULE_AUTHOR("Florian Meier <florian.meier@koalo.de>");
+MODULE_LICENSE("GPL v2");
---
-1.9.1
-
3 files changed, 955 insertions(+)
create mode 100644 sound/soc/bcm/bcm2708-i2s.c
-diff --git a/sound/soc/bcm/Kconfig b/sound/soc/bcm/Kconfig
-index 6a834e1..7e5b945 100644
--- a/sound/soc/bcm/Kconfig
+++ b/sound/soc/bcm/Kconfig
@@ -7,3 +7,14 @@ config SND_BCM2835_SOC_I2S
+ Say Y or M if you want to add support for codecs attached to
+ the BCM2708 I2S interface. You will also need
+ to select the audio interfaces to support below.
-diff --git a/sound/soc/bcm/Makefile b/sound/soc/bcm/Makefile
-index bc816b7..f8bbe1f 100644
--- a/sound/soc/bcm/Makefile
+++ b/sound/soc/bcm/Makefile
-@@ -3,3 +3,7 @@ snd-soc-bcm2835-i2s-objs := bcm2835-i2s.o
+@@ -3,3 +3,7 @@ snd-soc-bcm2835-i2s-objs := bcm2835-i2s.
obj-$(CONFIG_SND_BCM2835_SOC_I2S) += snd-soc-bcm2835-i2s.o
+snd-soc-bcm2708-i2s-objs := bcm2708-i2s.o
+
+obj-$(CONFIG_SND_BCM2708_SOC_I2S) += snd-soc-bcm2708-i2s.o
-diff --git a/sound/soc/bcm/bcm2708-i2s.c b/sound/soc/bcm/bcm2708-i2s.c
-new file mode 100644
-index 0000000..ebaf3d6
--- /dev/null
+++ b/sound/soc/bcm/bcm2708-i2s.c
@@ -0,0 +1,940 @@
+MODULE_DESCRIPTION("BCM2708 I2S interface");
+MODULE_AUTHOR("Florian Meier <florian.meier@koalo.de>");
+MODULE_LICENSE("GPL v2");
---
-1.9.1
-
arch/arm/mach-bcm2708/include/mach/platform.h | 2 ++
2 files changed, 4 insertions(+)
-diff --git a/arch/arm/mach-bcm2708/include/mach/dma.h b/arch/arm/mach-bcm2708/include/mach/dma.h
-index 6d2f9a0..a4aac4c 100644
--- a/arch/arm/mach-bcm2708/include/mach/dma.h
+++ b/arch/arm/mach-bcm2708/include/mach/dma.h
@@ -45,6 +45,8 @@
#define BCM2708_DMA_NEXTCB 0x1C
#define BCM2708_DMA_DEBUG 0x20
-diff --git a/arch/arm/mach-bcm2708/include/mach/platform.h b/arch/arm/mach-bcm2708/include/mach/platform.h
-index 992a630..2e7e1bb 100644
--- a/arch/arm/mach-bcm2708/include/mach/platform.h
+++ b/arch/arm/mach-bcm2708/include/mach/platform.h
@@ -62,10 +62,12 @@
#define SPI0_BASE (BCM2708_PERI_BASE + 0x204000) /* SPI0 */
#define BSC0_BASE (BCM2708_PERI_BASE + 0x205000) /* BSC0 I2C/TWI */
#define UART1_BASE (BCM2708_PERI_BASE + 0x215000) /* Uart 1 */
---
-1.9.1
-
3 files changed, 69 insertions(+)
create mode 100644 sound/soc/codecs/pcm5102a.c
-diff --git a/sound/soc/codecs/Kconfig b/sound/soc/codecs/Kconfig
-index 983d087a..f0d76ec 100644
--- a/sound/soc/codecs/Kconfig
+++ b/sound/soc/codecs/Kconfig
@@ -59,6 +59,7 @@ config SND_SOC_ALL_CODECS
config SND_SOC_RT5631
tristate
-diff --git a/sound/soc/codecs/Makefile b/sound/soc/codecs/Makefile
-index bc12676..612f414 100644
--- a/sound/soc/codecs/Makefile
+++ b/sound/soc/codecs/Makefile
@@ -46,6 +46,7 @@ snd-soc-hdmi-codec-objs := hdmi.o
snd-soc-rt5631-objs := rt5631.o
snd-soc-rt5640-objs := rt5640.o
snd-soc-sgtl5000-objs := sgtl5000.o
-@@ -179,6 +180,7 @@ obj-$(CONFIG_SND_SOC_HDMI_CODEC) += snd-soc-hdmi-codec.o
+@@ -179,6 +180,7 @@ obj-$(CONFIG_SND_SOC_HDMI_CODEC) += snd-
obj-$(CONFIG_SND_SOC_PCM1681) += snd-soc-pcm1681.o
obj-$(CONFIG_SND_SOC_PCM1792A) += snd-soc-pcm1792a-codec.o
obj-$(CONFIG_SND_SOC_PCM3008) += snd-soc-pcm3008.o
obj-$(CONFIG_SND_SOC_RT5631) += snd-soc-rt5631.o
obj-$(CONFIG_SND_SOC_RT5640) += snd-soc-rt5640.o
obj-$(CONFIG_SND_SOC_SGTL5000) += snd-soc-sgtl5000.o
-diff --git a/sound/soc/codecs/pcm5102a.c b/sound/soc/codecs/pcm5102a.c
-new file mode 100644
-index 0000000..126f1e9
--- /dev/null
+++ b/sound/soc/codecs/pcm5102a.c
@@ -0,0 +1,63 @@
+MODULE_DESCRIPTION("ASoC PCM5102A codec driver");
+MODULE_AUTHOR("Florian Meier <florian.meier@koalo.de>");
+MODULE_LICENSE("GPL v2");
---
-1.9.1
-
arch/arm/mach-bcm2708/bcm2708.c | 26 ++++++++++++++++++++++++++
1 file changed, 26 insertions(+)
-diff --git a/arch/arm/mach-bcm2708/bcm2708.c b/arch/arm/mach-bcm2708/bcm2708.c
-index 89d0824..07da1fd 100644
--- a/arch/arm/mach-bcm2708/bcm2708.c
+++ b/arch/arm/mach-bcm2708/bcm2708.c
-@@ -615,6 +615,28 @@ static struct platform_device bcm2835_thermal_device = {
+@@ -615,6 +615,28 @@ static struct platform_device bcm2835_th
.name = "bcm2835_thermal",
};
for (i = 0; i < ARRAY_SIZE(amba_devs); i++) {
struct amba_device *d = amba_devs[i];
amba_device_register(d, &iomem_resource);
---
-1.9.1
-
3 files changed, 112 insertions(+)
create mode 100644 sound/soc/bcm/hifiberry_dac.c
-diff --git a/sound/soc/bcm/Kconfig b/sound/soc/bcm/Kconfig
-index 7e5b945..b36a62f 100644
--- a/sound/soc/bcm/Kconfig
+++ b/sound/soc/bcm/Kconfig
@@ -18,3 +18,10 @@ config SND_BCM2708_SOC_I2S
+ select SND_SOC_PCM5102A
+ help
+ Say Y or M if you want to add support for HifiBerry DAC.
-diff --git a/sound/soc/bcm/Makefile b/sound/soc/bcm/Makefile
-index f8bbe1f..be90a49cb 100644
--- a/sound/soc/bcm/Makefile
+++ b/sound/soc/bcm/Makefile
-@@ -7,3 +7,8 @@ obj-$(CONFIG_SND_BCM2835_SOC_I2S) += snd-soc-bcm2835-i2s.o
+@@ -7,3 +7,8 @@ obj-$(CONFIG_SND_BCM2835_SOC_I2S) += snd
snd-soc-bcm2708-i2s-objs := bcm2708-i2s.o
obj-$(CONFIG_SND_BCM2708_SOC_I2S) += snd-soc-bcm2708-i2s.o
+snd-soc-hifiberry-dac-objs := hifiberry_dac.o
+
+obj-$(CONFIG_SND_BCM2708_SOC_HIFIBERRY_DAC) += snd-soc-hifiberry-dac.o
-diff --git a/sound/soc/bcm/hifiberry_dac.c b/sound/soc/bcm/hifiberry_dac.c
-new file mode 100644
-index 0000000..4b70b45
--- /dev/null
+++ b/sound/soc/bcm/hifiberry_dac.c
@@ -0,0 +1,100 @@
+MODULE_AUTHOR("Florian Meier <florian.meier@koalo.de>");
+MODULE_DESCRIPTION("ASoC Driver for HifiBerry DAC");
+MODULE_LICENSE("GPL v2");
---
-1.9.1
-
arch/arm/mach-bcm2708/bcm2708.c | 19 +++++++++++++++++++
1 file changed, 19 insertions(+)
-diff --git a/arch/arm/mach-bcm2708/bcm2708.c b/arch/arm/mach-bcm2708/bcm2708.c
-index 07da1fd..82b09a5 100644
--- a/arch/arm/mach-bcm2708/bcm2708.c
+++ b/arch/arm/mach-bcm2708/bcm2708.c
-@@ -637,6 +637,20 @@ static struct platform_device bcm2708_i2s_device = {
+@@ -637,6 +637,20 @@ static struct platform_device bcm2708_i2
};
#endif
for (i = 0; i < ARRAY_SIZE(amba_devs); i++) {
struct amba_device *d = amba_devs[i];
amba_device_register(d, &iomem_resource);
---
-1.9.1
-
sound/soc/bcm/bcm2708-i2s.c | 13 +++++++++----
1 file changed, 9 insertions(+), 4 deletions(-)
-diff --git a/sound/soc/bcm/bcm2708-i2s.c b/sound/soc/bcm/bcm2708-i2s.c
-index ebaf3d6..a179216 100644
--- a/sound/soc/bcm/bcm2708-i2s.c
+++ b/sound/soc/bcm/bcm2708-i2s.c
-@@ -346,6 +346,10 @@ static int bcm2708_i2s_hw_params(struct snd_pcm_substream *substream,
+@@ -346,6 +346,10 @@ static int bcm2708_i2s_hw_params(struct
data_length = 16;
bclk_ratio = 40;
break;
case SNDRV_PCM_FORMAT_S32_LE:
data_length = 32;
bclk_ratio = 80;
-@@ -424,7 +428,7 @@ static int bcm2708_i2s_hw_params(struct snd_pcm_substream *substream,
+@@ -424,7 +428,7 @@ static int bcm2708_i2s_hw_params(struct
/* Setup the frame format */
format = BCM2708_I2S_CHEN;
format |= BCM2708_I2S_CHWEX;
format |= BCM2708_I2S_CHWID((data_length-8)&0xf);
-@@ -714,6 +718,7 @@ static struct snd_soc_dai_driver bcm2708_i2s_dai = {
+@@ -714,6 +718,7 @@ static struct snd_soc_dai_driver bcm2708
.channels_max = 2,
.rates = SNDRV_PCM_RATE_8000_192000,
.formats = SNDRV_PCM_FMTBIT_S16_LE
| SNDRV_PCM_FMTBIT_S32_LE
},
.capture = {
-@@ -721,6 +726,7 @@ static struct snd_soc_dai_driver bcm2708_i2s_dai = {
+@@ -721,6 +726,7 @@ static struct snd_soc_dai_driver bcm2708
.channels_max = 2,
.rates = SNDRV_PCM_RATE_8000_192000,
.formats = SNDRV_PCM_FMTBIT_S16_LE
SNDRV_PCM_FMTBIT_S32_LE,
.period_bytes_min = 32,
.period_bytes_max = 64 * PAGE_SIZE,
---
-1.9.1
-
arch/arm/configs/bcmrpi_defconfig | 11 +++++++++++
1 file changed, 11 insertions(+)
-diff --git a/arch/arm/configs/bcmrpi_defconfig b/arch/arm/configs/bcmrpi_defconfig
-index d70da44..36e7473 100644
--- a/arch/arm/configs/bcmrpi_defconfig
+++ b/arch/arm/configs/bcmrpi_defconfig
@@ -739,6 +739,13 @@ CONFIG_SND_USB_UA101=m
CONFIG_UIO=m
CONFIG_UIO_PDRV_GENIRQ=m
CONFIG_STAGING=y
---
-1.9.1
-
create mode 100644 sound/soc/bcm/rpi-dac.c
create mode 100644 sound/soc/codecs/pcm1794a.c
-diff --git a/arch/arm/configs/bcmrpi_defconfig b/arch/arm/configs/bcmrpi_defconfig
-index 36e7473..f877ab2 100644
--- a/arch/arm/configs/bcmrpi_defconfig
+++ b/arch/arm/configs/bcmrpi_defconfig
@@ -744,8 +744,10 @@ CONFIG_SND_SOC_DMAENGINE_PCM=y
CONFIG_SOUND_PRIME=m
CONFIG_HIDRAW=y
CONFIG_HID_A4TECH=m
-diff --git a/arch/arm/mach-bcm2708/bcm2708.c b/arch/arm/mach-bcm2708/bcm2708.c
-index 82b09a5..cf10f74 100644
--- a/arch/arm/mach-bcm2708/bcm2708.c
+++ b/arch/arm/mach-bcm2708/bcm2708.c
-@@ -651,6 +651,20 @@ static struct platform_device snd_pcm5102a_codec_device = {
+@@ -651,6 +651,20 @@ static struct platform_device snd_pcm510
};
#endif
for (i = 0; i < ARRAY_SIZE(amba_devs); i++) {
struct amba_device *d = amba_devs[i];
amba_device_register(d, &iomem_resource);
-diff --git a/sound/soc/bcm/Kconfig b/sound/soc/bcm/Kconfig
-index b36a62f..714841d 100644
--- a/sound/soc/bcm/Kconfig
+++ b/sound/soc/bcm/Kconfig
@@ -25,3 +25,10 @@ config SND_BCM2708_SOC_HIFIBERRY_DAC
+ select SND_SOC_PCM1794A
+ help
+ Say Y or M if you want to add support for RPi-DAC.
-diff --git a/sound/soc/bcm/Makefile b/sound/soc/bcm/Makefile
-index be90a49cb..ccc9809 100644
--- a/sound/soc/bcm/Makefile
+++ b/sound/soc/bcm/Makefile
-@@ -10,5 +10,7 @@ obj-$(CONFIG_SND_BCM2708_SOC_I2S) += snd-soc-bcm2708-i2s.o
+@@ -10,5 +10,7 @@ obj-$(CONFIG_SND_BCM2708_SOC_I2S) += snd
# BCM2708 Machine Support
snd-soc-hifiberry-dac-objs := hifiberry_dac.o
obj-$(CONFIG_SND_BCM2708_SOC_HIFIBERRY_DAC) += snd-soc-hifiberry-dac.o
+obj-$(CONFIG_SND_BCM2708_SOC_RPI_DAC) += snd-soc-rpi-dac.o
-diff --git a/sound/soc/bcm/rpi-dac.c b/sound/soc/bcm/rpi-dac.c
-new file mode 100644
-index 0000000..ef3cd93
--- /dev/null
+++ b/sound/soc/bcm/rpi-dac.c
@@ -0,0 +1,97 @@
+MODULE_AUTHOR("Florian Meier <florian.meier@koalo.de>");
+MODULE_DESCRIPTION("ASoC Driver for RPi-DAC");
+MODULE_LICENSE("GPL v2");
-diff --git a/sound/soc/codecs/Kconfig b/sound/soc/codecs/Kconfig
-index f0d76ec..4d2569e 100644
--- a/sound/soc/codecs/Kconfig
+++ b/sound/soc/codecs/Kconfig
@@ -59,6 +59,7 @@ config SND_SOC_ALL_CODECS
config SND_SOC_PCM5102A
tristate
-diff --git a/sound/soc/codecs/Makefile b/sound/soc/codecs/Makefile
-index 612f414..9b806a2 100644
--- a/sound/soc/codecs/Makefile
+++ b/sound/soc/codecs/Makefile
@@ -46,6 +46,7 @@ snd-soc-hdmi-codec-objs := hdmi.o
snd-soc-pcm5102a-objs := pcm5102a.o
snd-soc-rt5631-objs := rt5631.o
snd-soc-rt5640-objs := rt5640.o
-@@ -180,6 +181,7 @@ obj-$(CONFIG_SND_SOC_HDMI_CODEC) += snd-soc-hdmi-codec.o
+@@ -180,6 +181,7 @@ obj-$(CONFIG_SND_SOC_HDMI_CODEC) += snd-
obj-$(CONFIG_SND_SOC_PCM1681) += snd-soc-pcm1681.o
obj-$(CONFIG_SND_SOC_PCM1792A) += snd-soc-pcm1792a-codec.o
obj-$(CONFIG_SND_SOC_PCM3008) += snd-soc-pcm3008.o
obj-$(CONFIG_SND_SOC_PCM5102A) += snd-soc-pcm5102a.o
obj-$(CONFIG_SND_SOC_RT5631) += snd-soc-rt5631.o
obj-$(CONFIG_SND_SOC_RT5640) += snd-soc-rt5640.o
-diff --git a/sound/soc/codecs/pcm1794a.c b/sound/soc/codecs/pcm1794a.c
-new file mode 100644
-index 0000000..b4eaa44
--- /dev/null
+++ b/sound/soc/codecs/pcm1794a.c
@@ -0,0 +1,62 @@
+MODULE_DESCRIPTION("ASoC PCM1794A codec driver");
+MODULE_AUTHOR("Florian Meier <florian.meier@koalo.de>");
+MODULE_LICENSE("GPL v2");
---
-1.9.1
-
sound/soc/codecs/wm8804.h | 4 ++++
2 files changed, 19 insertions(+), 4 deletions(-)
-diff --git a/sound/soc/codecs/wm8804.c b/sound/soc/codecs/wm8804.c
-index 9bc8206..c35b4f3 100644
--- a/sound/soc/codecs/wm8804.c
+++ b/sound/soc/codecs/wm8804.c
@@ -63,6 +63,7 @@ struct wm8804_priv {
};
static int txsrc_get(struct snd_kcontrol *kcontrol,
-@@ -277,6 +278,7 @@ static int wm8804_hw_params(struct snd_pcm_substream *substream,
+@@ -277,6 +278,7 @@ static int wm8804_hw_params(struct snd_p
blen = 0x1;
break;
case SNDRV_PCM_FORMAT_S24_LE:
{
u64 Kpart;
unsigned long int K, Ndiv, Nmod, tmp;
-@@ -330,7 +332,8 @@ static int pll_factors(struct pll_div *pll_div, unsigned int target,
+@@ -330,7 +332,8 @@ static int pll_factors(struct pll_div *p
*/
for (i = 0; i < ARRAY_SIZE(post_table); i++) {
tmp = target * post_table[i].div;
pll_div->freqmode = post_table[i].freqmode;
pll_div->mclkdiv = post_table[i].mclkdiv;
target *= post_table[i].div;
-@@ -387,8 +390,11 @@ static int wm8804_set_pll(struct snd_soc_dai *dai, int pll_id,
+@@ -387,8 +390,11 @@ static int wm8804_set_pll(struct snd_soc
} else {
int ret;
struct pll_div pll_div;
if (ret)
return ret;
-@@ -452,6 +458,7 @@ static int wm8804_set_clkdiv(struct snd_soc_dai *dai,
+@@ -452,6 +458,7 @@ static int wm8804_set_clkdiv(struct snd_
int div_id, int div)
{
struct snd_soc_codec *codec;
codec = dai->codec;
switch (div_id) {
-@@ -459,6 +466,10 @@ static int wm8804_set_clkdiv(struct snd_soc_dai *dai,
+@@ -459,6 +466,10 @@ static int wm8804_set_clkdiv(struct snd_
snd_soc_update_bits(codec, WM8804_PLL5, 0x30,
(div & 0x3) << 4);
break;
default:
dev_err(dai->dev, "Unknown clock divider: %d\n", div_id);
return -EINVAL;
-@@ -641,7 +652,7 @@ static const struct snd_soc_dai_ops wm8804_dai_ops = {
+@@ -641,7 +652,7 @@ static const struct snd_soc_dai_ops wm88
};
#define WM8804_FORMATS (SNDRV_PCM_FMTBIT_S16_LE | SNDRV_PCM_FMTBIT_S20_3LE | \
#define WM8804_RATES (SNDRV_PCM_RATE_32000 | SNDRV_PCM_RATE_44100 | \
SNDRV_PCM_RATE_48000 | SNDRV_PCM_RATE_64000 | \
-diff --git a/sound/soc/codecs/wm8804.h b/sound/soc/codecs/wm8804.h
-index 8ec14f5..e72d4f4 100644
--- a/sound/soc/codecs/wm8804.h
+++ b/sound/soc/codecs/wm8804.h
@@ -57,5 +57,9 @@
+#define WM8804_MCLKDIV_128FS 1
#endif /* _WM8804_H */
---
-1.9.1
-
3 files changed, 162 insertions(+)
create mode 100644 sound/soc/bcm/hifiberry_digi.c
-diff --git a/sound/soc/bcm/Kconfig b/sound/soc/bcm/Kconfig
-index 714841d..e563dbc 100644
--- a/sound/soc/bcm/Kconfig
+++ b/sound/soc/bcm/Kconfig
@@ -26,6 +26,13 @@ config SND_BCM2708_SOC_HIFIBERRY_DAC
config SND_BCM2708_SOC_RPI_DAC
tristate "Support for RPi-DAC"
depends on SND_BCM2708_SOC_I2S
-diff --git a/sound/soc/bcm/Makefile b/sound/soc/bcm/Makefile
-index ccc9809..826df7d 100644
--- a/sound/soc/bcm/Makefile
+++ b/sound/soc/bcm/Makefile
-@@ -10,7 +10,9 @@ obj-$(CONFIG_SND_BCM2708_SOC_I2S) += snd-soc-bcm2708-i2s.o
+@@ -10,7 +10,9 @@ obj-$(CONFIG_SND_BCM2708_SOC_I2S) += snd
# BCM2708 Machine Support
snd-soc-hifiberry-dac-objs := hifiberry_dac.o
obj-$(CONFIG_SND_BCM2708_SOC_HIFIBERRY_DAC) += snd-soc-hifiberry-dac.o
+obj-$(CONFIG_SND_BCM2708_SOC_HIFIBERRY_DIGI) += snd-soc-hifiberry-digi.o
obj-$(CONFIG_SND_BCM2708_SOC_RPI_DAC) += snd-soc-rpi-dac.o
-diff --git a/sound/soc/bcm/hifiberry_digi.c b/sound/soc/bcm/hifiberry_digi.c
-new file mode 100644
-index 0000000..e4f769d
--- /dev/null
+++ b/sound/soc/bcm/hifiberry_digi.c
@@ -0,0 +1,153 @@
+MODULE_AUTHOR("Daniel Matuschek <info@crazy-audio.com>");
+MODULE_DESCRIPTION("ASoC Driver for HifiBerry Digi");
+MODULE_LICENSE("GPL v2");
---
-1.9.1
-
arch/arm/mach-bcm2708/bcm2708.c | 20 ++++++++++++++++++++
1 file changed, 20 insertions(+)
-diff --git a/arch/arm/mach-bcm2708/bcm2708.c b/arch/arm/mach-bcm2708/bcm2708.c
-index cf10f74..beb2eca 100644
--- a/arch/arm/mach-bcm2708/bcm2708.c
+++ b/arch/arm/mach-bcm2708/bcm2708.c
-@@ -651,6 +651,21 @@ static struct platform_device snd_pcm5102a_codec_device = {
+@@ -651,6 +651,21 @@ static struct platform_device snd_pcm510
};
#endif
#if defined(CONFIG_SND_BCM2708_SOC_RPI_DAC) || defined(CONFIG_SND_BCM2708_SOC_RPI_DAC_MODULE)
bcm_register_device(&snd_rpi_dac_device);
bcm_register_device(&snd_pcm1794a_codec_device);
---
-1.9.1
-
arch/arm/configs/bcmrpi_defconfig | 2 ++
1 file changed, 2 insertions(+)
-diff --git a/arch/arm/configs/bcmrpi_defconfig b/arch/arm/configs/bcmrpi_defconfig
-index f877ab2..3d3c8ab 100644
--- a/arch/arm/configs/bcmrpi_defconfig
+++ b/arch/arm/configs/bcmrpi_defconfig
@@ -742,8 +742,10 @@ CONFIG_SND_USB_6FIRE=m
CONFIG_SND_BCM2708_SOC_RPI_DAC=m
CONFIG_SND_SOC_I2C_AND_SPI=m
CONFIG_SND_SOC_PCM5102A=m
---
-1.9.1
-
sound/soc/codecs/wm8804.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
-diff --git a/sound/soc/codecs/wm8804.c b/sound/soc/codecs/wm8804.c
-index c35b4f3..8915d08 100644
--- a/sound/soc/codecs/wm8804.c
+++ b/sound/soc/codecs/wm8804.c
-@@ -685,7 +685,7 @@ static struct snd_soc_codec_driver soc_codec_dev_wm8804 = {
+@@ -685,7 +685,7 @@ static struct snd_soc_codec_driver soc_c
.suspend = wm8804_suspend,
.resume = wm8804_resume,
.set_bias_level = wm8804_set_bias_level,
.controls = wm8804_snd_controls,
.num_controls = ARRAY_SIZE(wm8804_snd_controls),
---
-1.9.1
-
sound/soc/codecs/pcm5102a.c | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
-diff --git a/sound/soc/bcm/bcm2708-i2s.c b/sound/soc/bcm/bcm2708-i2s.c
-index a179216..b25e158 100644
--- a/sound/soc/bcm/bcm2708-i2s.c
+++ b/sound/soc/bcm/bcm2708-i2s.c
-@@ -718,7 +718,7 @@ static struct snd_soc_dai_driver bcm2708_i2s_dai = {
+@@ -718,7 +718,7 @@ static struct snd_soc_dai_driver bcm2708
.channels_max = 2,
.rates = SNDRV_PCM_RATE_8000_192000,
.formats = SNDRV_PCM_FMTBIT_S16_LE
| SNDRV_PCM_FMTBIT_S32_LE
},
.capture = {
-diff --git a/sound/soc/codecs/pcm5102a.c b/sound/soc/codecs/pcm5102a.c
-index 126f1e9..7812d34 100644
--- a/sound/soc/codecs/pcm5102a.c
+++ b/sound/soc/codecs/pcm5102a.c
-@@ -28,7 +28,7 @@ static struct snd_soc_dai_driver pcm5102a_dai = {
+@@ -28,7 +28,7 @@ static struct snd_soc_dai_driver pcm5102
.channels_max = 2,
.rates = SNDRV_PCM_RATE_8000_192000,
.formats = SNDRV_PCM_FMTBIT_S16_LE |
SNDRV_PCM_FMTBIT_S32_LE
},
};
---
-1.9.1
-
create mode 100644 sound/soc/codecs/pcm512x.c
create mode 100644 sound/soc/codecs/pcm512x.h
-diff --git a/arch/arm/configs/bcmrpi_defconfig b/arch/arm/configs/bcmrpi_defconfig
-index 3d3c8ab..a024670 100644
--- a/arch/arm/configs/bcmrpi_defconfig
+++ b/arch/arm/configs/bcmrpi_defconfig
@@ -750,6 +750,7 @@ CONFIG_SND_BCM2708_SOC_RPI_DAC=m
CONFIG_SOUND_PRIME=m
CONFIG_HIDRAW=y
CONFIG_HID_A4TECH=m
-diff --git a/arch/arm/mach-bcm2708/bcm2708.c b/arch/arm/mach-bcm2708/bcm2708.c
-index beb2eca..95a47fa 100644
--- a/arch/arm/mach-bcm2708/bcm2708.c
+++ b/arch/arm/mach-bcm2708/bcm2708.c
-@@ -680,6 +680,22 @@ static struct platform_device snd_pcm1794a_codec_device = {
+@@ -680,6 +680,22 @@ static struct platform_device snd_pcm179
};
#endif
for (i = 0; i < ARRAY_SIZE(amba_devs); i++) {
struct amba_device *d = amba_devs[i];
amba_device_register(d, &iomem_resource);
-diff --git a/sound/soc/bcm/Kconfig b/sound/soc/bcm/Kconfig
-index e563dbc..84e4f27 100644
--- a/sound/soc/bcm/Kconfig
+++ b/sound/soc/bcm/Kconfig
@@ -39,3 +39,10 @@ config SND_BCM2708_SOC_RPI_DAC
+ select SND_SOC_PCM512x
+ help
+ Say Y or M if you want to add support for IQaudIO-DAC.
-diff --git a/sound/soc/bcm/Makefile b/sound/soc/bcm/Makefile
-index 826df7d..d597fb0 100644
--- a/sound/soc/bcm/Makefile
+++ b/sound/soc/bcm/Makefile
-@@ -12,7 +12,9 @@ obj-$(CONFIG_SND_BCM2708_SOC_I2S) += snd-soc-bcm2708-i2s.o
+@@ -12,7 +12,9 @@ obj-$(CONFIG_SND_BCM2708_SOC_I2S) += snd
snd-soc-hifiberry-dac-objs := hifiberry_dac.o
snd-soc-hifiberry-digi-objs := hifiberry_digi.o
snd-soc-rpi-dac-objs := rpi-dac.o
obj-$(CONFIG_SND_BCM2708_SOC_HIFIBERRY_DIGI) += snd-soc-hifiberry-digi.o
obj-$(CONFIG_SND_BCM2708_SOC_RPI_DAC) += snd-soc-rpi-dac.o
+obj-$(CONFIG_SND_BCM2708_SOC_IQAUDIO_DAC) += snd-soc-iqaudio-dac.o
-diff --git a/sound/soc/bcm/iqaudio-dac.c b/sound/soc/bcm/iqaudio-dac.c
-new file mode 100644
-index 0000000..515f044
--- /dev/null
+++ b/sound/soc/bcm/iqaudio-dac.c
@@ -0,0 +1,111 @@
+MODULE_AUTHOR("Florian Meier <florian.meier@koalo.de>");
+MODULE_DESCRIPTION("ASoC Driver for IQAudio DAC");
+MODULE_LICENSE("GPL v2");
-diff --git a/sound/soc/codecs/Kconfig b/sound/soc/codecs/Kconfig
-index 4d2569e..ac28805 100644
--- a/sound/soc/codecs/Kconfig
+++ b/sound/soc/codecs/Kconfig
@@ -61,6 +61,7 @@ config SND_SOC_ALL_CODECS
config SND_SOC_RT5631
tristate
-diff --git a/sound/soc/codecs/Makefile b/sound/soc/codecs/Makefile
-index 9b806a2..61461c1 100644
--- a/sound/soc/codecs/Makefile
+++ b/sound/soc/codecs/Makefile
-@@ -48,6 +48,7 @@ snd-soc-pcm1792a-codec-objs := pcm1792a.o
+@@ -48,6 +48,7 @@ snd-soc-pcm1792a-codec-objs := pcm1792a.
snd-soc-pcm3008-objs := pcm3008.o
snd-soc-pcm1794a-objs := pcm1794a.o
snd-soc-pcm5102a-objs := pcm5102a.o
snd-soc-rt5631-objs := rt5631.o
snd-soc-rt5640-objs := rt5640.o
snd-soc-sgtl5000-objs := sgtl5000.o
-@@ -183,6 +184,7 @@ obj-$(CONFIG_SND_SOC_PCM1792A) += snd-soc-pcm1792a-codec.o
+@@ -183,6 +184,7 @@ obj-$(CONFIG_SND_SOC_PCM1792A) += snd-so
obj-$(CONFIG_SND_SOC_PCM3008) += snd-soc-pcm3008.o
obj-$(CONFIG_SND_SOC_PCM1794A) += snd-soc-pcm1794a.o
obj-$(CONFIG_SND_SOC_PCM5102A) += snd-soc-pcm5102a.o
obj-$(CONFIG_SND_SOC_RT5631) += snd-soc-rt5631.o
obj-$(CONFIG_SND_SOC_RT5640) += snd-soc-rt5640.o
obj-$(CONFIG_SND_SOC_SGTL5000) += snd-soc-sgtl5000.o
-diff --git a/sound/soc/codecs/pcm512x.c b/sound/soc/codecs/pcm512x.c
-new file mode 100644
-index 0000000..55b6200
--- /dev/null
+++ b/sound/soc/codecs/pcm512x.c
@@ -0,0 +1,677 @@
+MODULE_DESCRIPTION("ASoC PCM512x codec driver");
+MODULE_AUTHOR("Mark Brown <broonie@linaro.org>");
+MODULE_LICENSE("GPL v2");
-diff --git a/sound/soc/codecs/pcm512x.h b/sound/soc/codecs/pcm512x.h
-new file mode 100644
-index 0000000..b2f518e
--- /dev/null
+++ b/sound/soc/codecs/pcm512x.h
@@ -0,0 +1,142 @@
+#define PCM512x_AMLR_SHIFT 0
+
+#endif
---
-1.9.1
-
sound/soc/soc-core.c | 22 ++++++++++------------
1 file changed, 10 insertions(+), 12 deletions(-)
-diff --git a/sound/soc/soc-core.c b/sound/soc/soc-core.c
-index fe1df50..c3f41e7 100644
--- a/sound/soc/soc-core.c
+++ b/sound/soc/soc-core.c
-@@ -3038,8 +3038,8 @@ int snd_soc_info_volsw_range(struct snd_kcontrol *kcontrol,
+@@ -3038,8 +3038,8 @@ int snd_soc_info_volsw_range(struct snd_
uinfo->type = SNDRV_CTL_ELEM_TYPE_INTEGER;
uinfo->count = snd_soc_volsw_is_stereo(mc) ? 2 : 1;
return 0;
}
-@@ -3070,9 +3070,10 @@ int snd_soc_put_volsw_range(struct snd_kcontrol *kcontrol,
+@@ -3070,9 +3070,10 @@ int snd_soc_put_volsw_range(struct snd_k
unsigned int val, val_mask;
int ret;
val_mask = mask << shift;
val = val << shift;
-@@ -3081,9 +3082,10 @@ int snd_soc_put_volsw_range(struct snd_kcontrol *kcontrol,
+@@ -3081,9 +3082,10 @@ int snd_soc_put_volsw_range(struct snd_k
return ret;
if (snd_soc_volsw_is_stereo(mc)) {
val_mask = mask << shift;
val = val << shift;
-@@ -3121,18 +3123,14 @@ int snd_soc_get_volsw_range(struct snd_kcontrol *kcontrol,
+@@ -3121,18 +3123,14 @@ int snd_soc_get_volsw_range(struct snd_k
(snd_soc_read(codec, reg) >> shift) & mask;
if (invert)
ucontrol->value.integer.value[0] =
}
return 0;
---
-1.9.1
-
sound/soc/codecs/pcm512x.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
-diff --git a/sound/soc/codecs/pcm512x.c b/sound/soc/codecs/pcm512x.c
-index 55b6200..2653311 100644
--- a/sound/soc/codecs/pcm512x.c
+++ b/sound/soc/codecs/pcm512x.c
-@@ -240,8 +240,8 @@ static const struct soc_enum pcm512x_veds =
+@@ -240,8 +240,8 @@ static const struct soc_enum pcm512x_ved
pcm512x_ramp_step_text);
static const struct snd_kcontrol_new pcm512x_controls[] = {
SOC_DOUBLE("Playback Digital Switch", PCM512x_MUTE, PCM512x_RQML_SHIFT,
PCM512x_RQMR_SHIFT, 1, 1),
---
-1.9.1
-
sound/soc/soc-core.c | 8 ++++----
2 files changed, 6 insertions(+), 5 deletions(-)
-diff --git a/sound/soc/codecs/pcm512x.c b/sound/soc/codecs/pcm512x.c
-index 2653311..b669e15 100644
--- a/sound/soc/codecs/pcm512x.c
+++ b/sound/soc/codecs/pcm512x.c
-@@ -239,9 +239,10 @@ static const struct soc_enum pcm512x_veds =
+@@ -239,9 +239,10 @@ static const struct soc_enum pcm512x_ved
SOC_ENUM_SINGLE(PCM512x_DIGITAL_MUTE_2, PCM512x_VEDS_SHIFT, 4,
pcm512x_ramp_step_text);
SOC_DOUBLE("Playback Digital Switch", PCM512x_MUTE, PCM512x_RQML_SHIFT,
PCM512x_RQMR_SHIFT, 1, 1),
-diff --git a/sound/soc/soc-core.c b/sound/soc/soc-core.c
-index c3f41e7..a8a753f 100644
--- a/sound/soc/soc-core.c
+++ b/sound/soc/soc-core.c
-@@ -3072,8 +3072,8 @@ int snd_soc_put_volsw_range(struct snd_kcontrol *kcontrol,
+@@ -3072,8 +3072,8 @@ int snd_soc_put_volsw_range(struct snd_k
if (invert)
val = ((max - ucontrol->value.integer.value[0] + min) & mask);
val_mask = mask << shift;
val = val << shift;
-@@ -3084,8 +3084,8 @@ int snd_soc_put_volsw_range(struct snd_kcontrol *kcontrol,
+@@ -3084,8 +3084,8 @@ int snd_soc_put_volsw_range(struct snd_k
if (snd_soc_volsw_is_stereo(mc)) {
if (invert)
val = ((max - ucontrol->value.integer.value[1] + min) & mask);
val_mask = mask << shift;
val = val << shift;
---
-1.9.1
-
sound/soc/bcm/bcm2708-i2s.c | 55 +++++++++++++++++++++++----------------------
1 file changed, 28 insertions(+), 27 deletions(-)
-diff --git a/sound/soc/bcm/bcm2708-i2s.c b/sound/soc/bcm/bcm2708-i2s.c
-index b25e158..9976571 100644
--- a/sound/soc/bcm/bcm2708-i2s.c
+++ b/sound/soc/bcm/bcm2708-i2s.c
-@@ -305,6 +305,31 @@ static int bcm2708_i2s_set_dai_bclk_ratio(struct snd_soc_dai *dai,
+@@ -305,6 +305,31 @@ static int bcm2708_i2s_set_dai_bclk_rati
return 0;
}
static int bcm2708_i2s_hw_params(struct snd_pcm_substream *substream,
struct snd_pcm_hw_params *params,
struct snd_soc_dai *dai)
-@@ -334,6 +359,9 @@ static int bcm2708_i2s_hw_params(struct snd_pcm_substream *substream,
+@@ -334,6 +359,9 @@ static int bcm2708_i2s_hw_params(struct
if (csreg & (BCM2708_I2S_TXON | BCM2708_I2S_RXON))
return 0;
/*
* Adjust the data length according to the format.
* We prefill the half frame length with an integer
-@@ -790,31 +818,6 @@ static const struct snd_soc_component_driver bcm2708_i2s_component = {
+@@ -790,31 +818,6 @@ static const struct snd_soc_component_dr
.name = "bcm2708-i2s-comp",
};
static const struct snd_pcm_hardware bcm2708_pcm_hardware = {
.info = SNDRV_PCM_INFO_INTERLEAVED |
SNDRV_PCM_INFO_JOINT_DUPLEX,
-@@ -865,8 +868,6 @@ static int bcm2708_i2s_probe(struct platform_device *pdev)
+@@ -865,8 +868,6 @@ static int bcm2708_i2s_probe(struct plat
if (IS_ERR(dev))
return PTR_ERR(dev);
dev->i2s_regmap = regmap[0];
dev->clk_regmap = regmap[1];
---
-1.9.1
-
drivers/video/bcm2708_fb.c | 15 +++++++++------
1 file changed, 9 insertions(+), 6 deletions(-)
-diff --git a/drivers/video/bcm2708_fb.c b/drivers/video/bcm2708_fb.c
-index 798eb52..b3b1e04 100644
--- a/drivers/video/bcm2708_fb.c
+++ b/drivers/video/bcm2708_fb.c
@@ -89,6 +89,7 @@ struct bcm2708_fb {
};
#define to_bcm2708(info) container_of(info, struct bcm2708_fb, fb)
-@@ -314,13 +315,15 @@ static int bcm2708_fb_set_par(struct fb_info *info)
+@@ -314,13 +315,15 @@ static int bcm2708_fb_set_par(struct fb_
else
fb->fb.fix.visual = FB_VISUAL_TRUECOLOR;
if (!fb->fb.screen_base) {
/* the console may currently be locked */
console_trylock();
-@@ -331,7 +334,7 @@ static int bcm2708_fb_set_par(struct fb_info *info)
+@@ -331,7 +334,7 @@ static int bcm2708_fb_set_par(struct fb_
}
print_debug
("BCM2708FB: start = %p,%p width=%d, height=%d, bpp=%d, pitch=%d size=%d success=%d\n",
fbinfo->xres, fbinfo->yres, fbinfo->bpp,
fbinfo->pitch, (int)fb->fb.screen_size, val);
-@@ -457,11 +460,11 @@ static void bcm2708_fb_copyarea(struct fb_info *info,
+@@ -457,11 +460,11 @@ static void bcm2708_fb_copyarea(struct f
for (y = 0; y < region->height; y += scanlines_per_cb) {
dma_addr_t src =
bytes_per_pixel * region->dx +
(region->dy + y) * fb->fb.fix.line_length;
-@@ -499,10 +502,10 @@ static void bcm2708_fb_copyarea(struct fb_info *info,
+@@ -499,10 +502,10 @@ static void bcm2708_fb_copyarea(struct f
stride = -fb->fb.fix.line_length;
}
set_dma_cb(cb, burst_size,
bytes_per_pixel * region->sx,
stride,
region->width * bytes_per_pixel,
---
-1.9.1
-
--- a/drivers/mtd/bcm47xxpart.c
+++ b/drivers/mtd/bcm47xxpart.c
-@@ -89,6 +89,7 @@ static int bcm47xxpart_parse(struct mtd_
+@@ -93,6 +93,7 @@ static int bcm47xxpart_parse(struct mtd_
int trx_part = -1;
int last_trx_part = -1;
int possible_nvram_sizes[] = { 0x8000, 0xF000, 0x10000, };
if (blocksize <= 0x10000)
blocksize = 0x10000;
-@@ -269,12 +270,23 @@ static int bcm47xxpart_parse(struct mtd_
+@@ -280,12 +281,23 @@ static int bcm47xxpart_parse(struct mtd_
if (buf[0] == NVRAM_HEADER) {
bcm47xxpart_add_part(&parts[curr_part++], "nvram",
master->size - blocksize, 0);
break;
--- a/arch/mips/bcm47xx/leds.c
+++ b/arch/mips/bcm47xx/leds.c
-@@ -64,6 +64,11 @@ bcm47xx_leds_asus_wl330ge[] __initconst
+@@ -64,6 +64,11 @@ bcm47xx_leds_asus_wl330ge[] __initconst
};
static const struct gpio_led
break;
--- a/arch/mips/bcm47xx/leds.c
+++ b/arch/mips/bcm47xx/leds.c
-@@ -35,6 +35,15 @@ bcm47xx_leds_asus_rtn12[] __initconst =
+@@ -35,6 +35,15 @@ bcm47xx_leds_asus_rtn12[] __initconst =
};
static const struct gpio_led
bcm47xx_leds_asus_rtn16[] __initconst = {
BCM47XX_GPIO_LED(1, "blue", "power", 1, LEDS_GPIO_DEFSTATE_ON),
BCM47XX_GPIO_LED(7, "blue", "wlan", 0, LEDS_GPIO_DEFSTATE_OFF),
-@@ -42,8 +51,8 @@ bcm47xx_leds_asus_rtn16[] __initconst =
+@@ -42,8 +51,8 @@ bcm47xx_leds_asus_rtn16[] __initconst =
static const struct gpio_led
bcm47xx_leds_asus_rtn66u[] __initconst = {
BCM47XX_GPIO_LED(7, "amber", "wps", 0, LEDS_GPIO_DEFSTATE_OFF),
BCM47XX_GPIO_LED(8, "blue", "wps", 0, LEDS_GPIO_DEFSTATE_OFF),
};
-@@ -319,6 +328,16 @@ bcm47xx_leds_linksys_wrt54g_type_0101[]
+@@ -319,6 +328,16 @@ bcm47xx_leds_linksys_wrt54g_type_0101[]
BCM47XX_GPIO_LED(7, "green", "dmz", 1, LEDS_GPIO_DEFSTATE_OFF),
};
--- a/arch/mips/bcm47xx/prom.c
+++ b/arch/mips/bcm47xx/prom.c
-@@ -51,6 +51,8 @@ __init void bcm47xx_set_system_type(u16
+@@ -51,6 +51,8 @@ __init void bcm47xx_set_system_type(u16
chip_id);
}
}
--- a/arch/mips/mm/tlbex.c
+++ b/arch/mips/mm/tlbex.c
-@@ -1277,6 +1277,9 @@ static void build_r4000_tlb_refill_handl
+@@ -1280,6 +1280,9 @@ static void build_r4000_tlb_refill_handl
/* No need for uasm_i_nop */
}
#ifdef CONFIG_64BIT
build_get_pmde64(&p, &l, &r, K0, K1); /* get pmd in K1 */
#else
-@@ -1835,6 +1838,9 @@ build_r4000_tlbchange_handler_head(u32 *
+@@ -1840,6 +1843,9 @@ build_r4000_tlbchange_handler_head(u32 *
{
struct work_registers wr = build_get_work_registers(p);
extern void build_clear_page(void);
extern void build_copy_page(void);
-@@ -105,13 +106,16 @@ static inline void clear_user_page(void
+@@ -105,13 +106,16 @@ static inline void clear_user_page(void
flush_data_cache_page((unsigned long)addr);
}
drivers/mtd/bcm47xxpart.c | 8 ++++++--
1 file changed, 6 insertions(+), 2 deletions(-)
-diff --git a/drivers/mtd/bcm47xxpart.c b/drivers/mtd/bcm47xxpart.c
-index dfd57a0..948f535 100644
--- a/drivers/mtd/bcm47xxpart.c
+++ b/drivers/mtd/bcm47xxpart.c
-@@ -95,8 +95,12 @@ static int bcm47xxpart_parse(struct mtd_info *master,
+@@ -95,8 +95,12 @@ static int bcm47xxpart_parse(struct mtd_
int possible_nvram_sizes[] = { 0x8000, 0xF000, 0x10000, };
bool found_nvram = false;
/* Alloc */
parts = kzalloc(sizeof(struct mtd_partition) * BCM47XXPART_MAX_PARTS,
---
-1.8.4.5
-
drivers/bcma/driver_chipcommon_sflash.c | 29 +++++++++++++++++++++++++++++
1 file changed, 29 insertions(+)
-diff --git a/drivers/bcma/driver_chipcommon_sflash.c b/drivers/bcma/driver_chipcommon_sflash.c
-index 7e11ef4..25d9e17 100644
--- a/drivers/bcma/driver_chipcommon_sflash.c
+++ b/drivers/bcma/driver_chipcommon_sflash.c
@@ -9,6 +9,7 @@
static struct resource bcma_sflash_resource = {
.name = "bcma_sflash",
-@@ -41,6 +42,13 @@ static const struct bcma_sflash_tbl_e bcma_sflash_st_tbl[] = {
+@@ -41,6 +42,13 @@ static const struct bcma_sflash_tbl_e bc
{ NULL },
};
static const struct bcma_sflash_tbl_e bcma_sflash_sst_tbl[] = {
{ "SST25WF512", 1, 0x1000, 16, },
{ "SST25VF512", 0x48, 0x1000, 16, },
-@@ -84,6 +92,23 @@ static void bcma_sflash_cmd(struct bcma_drv_cc *cc, u32 opcode)
+@@ -84,6 +92,23 @@ static void bcma_sflash_cmd(struct bcma_
bcma_err(cc->core->bus, "SFLASH control command failed (timeout)!\n");
}
/* Initialize serial flash access */
int bcma_sflash_init(struct bcma_drv_cc *cc)
{
-@@ -114,6 +139,10 @@ int bcma_sflash_init(struct bcma_drv_cc *cc)
+@@ -114,6 +139,10 @@ int bcma_sflash_init(struct bcma_drv_cc
case 0x13:
return -ENOTSUPP;
default:
for (e = bcma_sflash_st_tbl; e->name; e++) {
if (e->id == id)
break;
---
-1.8.4.5
-
UASM_i_LA_mostly(p, ptr, pgdc);
#endif
uasm_i_mfc0(p, tmp, C0_BADVADDR); /* get faulting address */
-@@ -1277,12 +1280,12 @@ static void build_r4000_tlb_refill_handl
+@@ -1280,12 +1283,12 @@ static void build_r4000_tlb_refill_handl
/* No need for uasm_i_nop */
}
build_get_pgde32(&p, K0, K1); /* get pgd in K1 */
#endif
-@@ -1294,6 +1297,9 @@ static void build_r4000_tlb_refill_handl
+@@ -1297,6 +1300,9 @@ static void build_r4000_tlb_refill_handl
build_update_entries(&p, K0, K1);
build_tlb_write_entry(&p, &l, &r, tlb_random);
uasm_l_leave(&l, p);
uasm_i_eret(&p); /* return from trap */
}
#ifdef CONFIG_MIPS_HUGE_TLB_SUPPORT
-@@ -1838,12 +1844,12 @@ build_r4000_tlbchange_handler_head(u32 *
+@@ -1843,12 +1849,12 @@ build_r4000_tlbchange_handler_head(u32 *
{
struct work_registers wr = build_get_work_registers(p);
build_get_pgde32(p, wr.r1, wr.r2); /* get pgd in ptr */
#endif
-@@ -1882,6 +1888,9 @@ build_r4000_tlbchange_handler_tail(u32 *
+@@ -1887,6 +1893,9 @@ build_r4000_tlbchange_handler_tail(u32 *
build_tlb_write_entry(p, l, r, tlb_indexed);
uasm_l_leave(l, *p);
build_restore_work_registers(p);
#endif
--- a/arch/arm/mm/Kconfig
+++ b/arch/arm/mm/Kconfig
-@@ -843,6 +843,17 @@ config DMA_CACHE_RWFO
+@@ -844,6 +844,17 @@ config DMA_CACHE_RWFO
in hardware, other workarounds are needed (e.g. cache
maintenance broadcasting in software via FIQ).
*/
--- a/arch/arm/mm/Kconfig
+++ b/arch/arm/mm/Kconfig
-@@ -826,7 +826,7 @@ config KUSER_HELPERS
+@@ -827,7 +827,7 @@ config KUSER_HELPERS
config DMA_CACHE_RWFO
bool "Enable read/write for ownership DMA cache maintenance"
pci_write_config_byte(dev, PCI_INTERRUPT_LINE, dev->irq);
readrq = pcie_get_readrq(dev);
-@@ -617,6 +617,6 @@ int bcma_core_pci_pcibios_map_irq(const
+@@ -617,6 +617,6 @@ int bcma_core_pci_pcibios_map_irq(const
pc_host = container_of(dev->bus->ops, struct bcma_drv_pci_host,
pci_ops);
+#endif /* LINUX_BCMA_DRIVER_PCIE2_H_ */
--- a/drivers/bcma/scan.c
+++ b/drivers/bcma/scan.c
-@@ -32,17 +32,17 @@ static const struct bcma_device_id_name
+@@ -32,17 +32,17 @@ static const struct bcma_device_id_name
{ BCMA_CORE_4706_CHIPCOMMON, "BCM4706 ChipCommon" },
{ BCMA_CORE_4706_SOC_RAM, "BCM4706 SOC RAM" },
{ BCMA_CORE_4706_MAC_GBIT, "BCM4706 GBit MAC" },
static void bcma_core_mips_set_irq(struct bcma_device *dev, unsigned int irq)
{
unsigned int oldirq = bcma_core_mips_irq(dev);
-@@ -229,11 +230,51 @@ u32 bcma_cpu_clock(struct bcma_drv_mips
+@@ -229,11 +230,51 @@ u32 bcma_cpu_clock(struct bcma_drv_mips
}
EXPORT_SYMBOL(bcma_cpu_clock);
void dma_free_noncoherent(struct device *dev, size_t size, void *vaddr,
-@@ -159,8 +137,8 @@ void dma_free_noncoherent(struct device
+@@ -159,8 +137,8 @@ void dma_free_noncoherent(struct device
}
EXPORT_SYMBOL(dma_free_noncoherent);
void dma_cache_sync(struct device *dev, void *vaddr, size_t size,
enum dma_data_direction direction)
-@@ -347,23 +225,10 @@ void dma_cache_sync(struct device *dev,
+@@ -347,23 +225,10 @@ void dma_cache_sync(struct device *dev,
EXPORT_SYMBOL(dma_cache_sync);
#ifdef MODULE
#define __MODULE_INFO(tag, name, info) \
static const char __UNIQUE_ID(name)[] \
-@@ -23,8 +33,7 @@ static const char __UNIQUE_ID(name)[]
+@@ -23,8 +33,7 @@ static const char __UNIQUE_ID(name)[]
= __stringify(tag) "=" info
#else /* !MODULE */
/* This struct is here for syntactic coherency, it is not used */
#endif
#define __MODULE_PARM_TYPE(name, _type) \
__MODULE_INFO(parmtype, name##type, #name ":" _type)
-@@ -32,7 +41,7 @@ static const char __UNIQUE_ID(name)[]
+@@ -32,7 +41,7 @@ static const char __UNIQUE_ID(name)[]
/* One for each parameter, describing how to use it. Some files do
multiple of these per line, so can't just use MODULE_INFO. */
#define MODULE_PARM_DESC(_parm, desc) \
--- a/scripts/Makefile.lib
+++ b/scripts/Makefile.lib
-@@ -304,7 +304,7 @@ cmd_bzip2 = (cat $(filter-out FORCE,$^)
+@@ -304,7 +304,7 @@ cmd_bzip2 = (cat $(filter-out FORCE,$^)
quiet_cmd_lzma = LZMA $@
cmd_lzma = (cat $(filter-out FORCE,$^) | \
--- a/arch/mips/include/asm/string.h
+++ b/arch/mips/include/asm/string.h
-@@ -133,11 +133,44 @@ strncmp(__const__ char *__cs, __const__
+@@ -133,11 +133,44 @@ strncmp(__const__ char *__cs, __const__
#define __HAVE_ARCH_MEMSET
extern void *memset(void *__s, int __c, size_t __count);
default y
--- a/drivers/mtd/mtdpart.c
+++ b/drivers/mtd/mtdpart.c
-@@ -668,6 +668,47 @@ mtd_pad_erasesize(struct mtd_info *mtd,
+@@ -668,6 +668,47 @@ mtd_pad_erasesize(struct mtd_info *mtd,
return len;
}
u64 offset, uint32_t mask_flags)
{
part->name = name;
-@@ -58,6 +59,26 @@ static void bcm47xxpart_add_part(struct
+@@ -58,6 +59,26 @@ static void bcm47xxpart_add_part(struct
part->mask_flags = mask_flags;
}
/****************************************************************************/
enum read_type {
-@@ -1192,7 +1198,7 @@ static int m25p_probe(struct spi_device
+@@ -1192,7 +1198,7 @@ static int m25p_probe(struct spi_device
flash->mtd._write = m25p80_write;
/* prefer "small sector" erase if possible */
static struct proc_dir_entry *my_proc_entry;
static char *yaffs_dump_dev_part0(char *buf, struct yaffs_dev *dev)
-@@ -3398,6 +3399,7 @@ static int yaffs_proc_write(struct file
+@@ -3398,6 +3399,7 @@ static int yaffs_proc_write(struct file
return yaffs_proc_debug_write(file, buf, count, data);
return yaffs_proc_write_trace_options(file, buf, count, data);
}
/* LzmaDecode
--- a/lib/lzma/LzmaDec.c
+++ b/lib/lzma/LzmaDec.c
-@@ -682,7 +682,7 @@ static void LzmaDec_InitRc(CLzmaDec *p,
+@@ -682,7 +682,7 @@ static void LzmaDec_InitRc(CLzmaDec *p,
p->needFlush = 0;
}
{
UInt32 dicSize;
Byte d;
-@@ -935,7 +883,7 @@ static SRes LzmaDec_AllocateProbs2(CLzma
+@@ -935,33 +883,11 @@ static SRes LzmaDec_AllocateProbs2(CLzma
return SZ_OK;
}
-SRes LzmaDec_AllocateProbs(CLzmaDec *p, const Byte *props, unsigned propsSize, ISzAlloc *alloc)
-+static SRes LzmaDec_AllocateProbs(CLzmaDec *p, const Byte *props, unsigned propsSize, ISzAlloc *alloc)
- {
- CLzmaProps propNew;
- RINOK(LzmaProps_Decode(&propNew, props, propsSize));
-@@ -943,28 +891,6 @@ SRes LzmaDec_AllocateProbs(CLzmaDec *p,
- p->prop = propNew;
- return SZ_OK;
- }
--
--SRes LzmaDec_Allocate(CLzmaDec *p, const Byte *props, unsigned propsSize, ISzAlloc *alloc)
-{
- CLzmaProps propNew;
-- SizeT dicBufSize;
- RINOK(LzmaProps_Decode(&propNew, props, propsSize));
- RINOK(LzmaDec_AllocateProbs2(p, &propNew, alloc));
+- p->prop = propNew;
+- return SZ_OK;
+-}
+-
+-SRes LzmaDec_Allocate(CLzmaDec *p, const Byte *props, unsigned propsSize, ISzAlloc *alloc)
++static SRes LzmaDec_AllocateProbs(CLzmaDec *p, const Byte *props, unsigned propsSize, ISzAlloc *alloc)
+ {
+ CLzmaProps propNew;
+- SizeT dicBufSize;
+ RINOK(LzmaProps_Decode(&propNew, props, propsSize));
+ RINOK(LzmaDec_AllocateProbs2(p, &propNew, alloc));
- dicBufSize = propNew.dicSize;
- if (p->dic == 0 || dicBufSize != p->dicBufSize)
- {
- }
- }
- p->dicBufSize = dicBufSize;
-- p->prop = propNew;
-- return SZ_OK;
--}
-
- SRes LzmaDecode(Byte *dest, SizeT *destLen, const Byte *src, SizeT *srcLen,
- const Byte *propData, unsigned propSize, ELzmaFinishMode finishMode,
+ p->prop = propNew;
+ return SZ_OK;
+ }
--- a/include/linux/lzma/LzmaEnc.h
+++ b/include/linux/lzma/LzmaEnc.h
@@ -31,9 +31,6 @@ typedef struct _CLzmaEncProps
void MatchFinder_Construct(CMatchFinder *p);
/* Conditions:
-@@ -70,12 +65,6 @@ int MatchFinder_Create(CMatchFinder *p,
+@@ -70,12 +65,6 @@ int MatchFinder_Create(CMatchFinder *p,
UInt32 keepAddBufferBefore, UInt32 matchMaxLen, UInt32 keepAddBufferAfter,
ISzAlloc *alloc);
void MatchFinder_Free(CMatchFinder *p, ISzAlloc *alloc);
{
memmove(p->bufferBase,
p->buffer - p->keepSizeBefore,
-@@ -97,22 +103,14 @@ void MatchFinder_MoveBlock(CMatchFinder
+@@ -97,22 +103,14 @@ void MatchFinder_MoveBlock(CMatchFinder
p->buffer = p->bufferBase + p->keepSizeBefore;
}
depends on NETFILTER_ADVANCED
--- a/net/netfilter/Makefile
+++ b/net/netfilter/Makefile
-@@ -158,6 +158,7 @@ obj-$(CONFIG_NETFILTER_XT_MATCH_RECENT)
+@@ -158,6 +158,7 @@ obj-$(CONFIG_NETFILTER_XT_MATCH_RECENT)
obj-$(CONFIG_NETFILTER_XT_MATCH_SCTP) += xt_sctp.o
obj-$(CONFIG_NETFILTER_XT_MATCH_SOCKET) += xt_socket.o
obj-$(CONFIG_NETFILTER_XT_MATCH_STATE) += xt_state.o
#include <net/net_namespace.h>
#ifdef CONFIG_SYSCTL
#include <linux/sysctl.h>
-@@ -268,10 +269,66 @@ static int ct_open(struct inode *inode,
+@@ -268,10 +269,66 @@ static int ct_open(struct inode *inode,
sizeof(struct ct_iter_state));
}
counters = alloc_counters(table);
if (IS_ERR(counters))
-@@ -965,6 +994,14 @@ copy_entries_to_user(unsigned int total_
- ret = -EFAULT;
+@@ -966,6 +995,14 @@ copy_entries_to_user(unsigned int total_
goto free_counters;
}
-+
+
+ flags = e->ip.flags & IPT_F_MASK;
+ if (copy_to_user(userptr + off
+ + offsetof(struct ipt_entry, ip.flags),
+ ret = -EFAULT;
+ goto free_counters;
+ }
-
++
for (i = sizeof(struct ipt_entry);
i < e->target_offset;
+ i += m->u.match_size) {
depends on NETFILTER_ADVANCED
--- a/net/netfilter/Makefile
+++ b/net/netfilter/Makefile
-@@ -136,6 +136,7 @@ obj-$(CONFIG_NETFILTER_XT_MATCH_ESP) +=
+@@ -136,6 +136,7 @@ obj-$(CONFIG_NETFILTER_XT_MATCH_ESP) +=
obj-$(CONFIG_NETFILTER_XT_MATCH_HASHLIMIT) += xt_hashlimit.o
obj-$(CONFIG_NETFILTER_XT_MATCH_HELPER) += xt_helper.o
obj-$(CONFIG_NETFILTER_XT_MATCH_HL) += xt_hl.o
Ethernet bridge, which means that the different Ethernet segments it
--- a/net/ipv6/Makefile
+++ b/net/ipv6/Makefile
-@@ -45,3 +45,4 @@ obj-y += addrconf_core.o exthdrs_core.o
+@@ -45,3 +45,4 @@ obj-y += addrconf_core.o exthdrs_core.o
obj-$(CONFIG_INET) += output_core.o protocol.o $(ipv6-offload)
obj-$(subst m,y,$(CONFIG_IPV6)) += inet6_hashtables.o
}
#endif
-@@ -1465,6 +1492,7 @@ static int br_multicast_ipv4_rcv(struct
+@@ -1465,6 +1492,7 @@ static int br_multicast_ipv4_rcv(struct
struct sk_buff *skb,
u16 vid)
{
struct sk_buff *skb2 = skb;
const struct iphdr *iph;
struct igmphdr *ih;
-@@ -1538,7 +1566,7 @@ static int br_multicast_ipv4_rcv(struct
+@@ -1538,7 +1566,7 @@ static int br_multicast_ipv4_rcv(struct
case IGMP_HOST_MEMBERSHIP_REPORT:
case IGMPV2_HOST_MEMBERSHIP_REPORT:
BR_INPUT_SKB_CB(skb)->mrouters_only = 1;
break;
case IGMPV3_HOST_MEMBERSHIP_REPORT:
err = br_ip4_multicast_igmp3_report(br, port, skb2, vid);
-@@ -1547,7 +1575,7 @@ static int br_multicast_ipv4_rcv(struct
+@@ -1547,7 +1575,7 @@ static int br_multicast_ipv4_rcv(struct
err = br_ip4_multicast_query(br, port, skb2, vid);
break;
case IGMP_HOST_LEAVE_MESSAGE:
break;
}
-@@ -1565,6 +1593,7 @@ static int br_multicast_ipv6_rcv(struct
+@@ -1565,6 +1593,7 @@ static int br_multicast_ipv6_rcv(struct
struct sk_buff *skb,
u16 vid)
{
struct sk_buff *skb2;
const struct ipv6hdr *ip6h;
u8 icmp6_type;
-@@ -1674,7 +1703,8 @@ static int br_multicast_ipv6_rcv(struct
+@@ -1674,7 +1703,8 @@ static int br_multicast_ipv6_rcv(struct
}
mld = (struct mld_msg *)skb_transport_header(skb2);
BR_INPUT_SKB_CB(skb)->mrouters_only = 1;
break;
}
case ICMPV6_MLD2_REPORT:
-@@ -1691,7 +1721,7 @@ static int br_multicast_ipv6_rcv(struct
+@@ -1691,7 +1721,7 @@ static int br_multicast_ipv6_rcv(struct
goto out;
}
mld = (struct mld_msg *)skb_transport_header(skb2);
--- a/net/netlink/af_netlink.c
+++ b/net/netlink/af_netlink.c
-@@ -1740,27 +1740,7 @@ void netlink_detachskb(struct sock *sk,
+@@ -1740,27 +1740,7 @@ void netlink_detachskb(struct sock *sk,
static struct sk_buff *netlink_trim(struct sk_buff *skb, gfp_t allocation)
{
}
--- a/net/sched/sch_fifo.c
+++ b/net/sched/sch_fifo.c
-@@ -29,17 +29,21 @@ static int bfifo_enqueue(struct sk_buff
+@@ -29,17 +29,21 @@ static int bfifo_enqueue(struct sk_buff
static int pfifo_enqueue(struct sk_buff *skb, struct Qdisc *sch)
{
err = ip6_tnl_xmit2(skb, dev, dsfield, &fl6, encap_limit, &mtu);
if (err != 0) {
/* XXX: send ICMP error even if DF is not set. */
-@@ -1257,6 +1407,14 @@ ip6_tnl_change(struct ip6_tnl *t, const
+@@ -1257,6 +1407,14 @@ ip6_tnl_change(struct ip6_tnl *t, const
t->parms.flowinfo = p->flowinfo;
t->parms.link = p->link;
t->parms.proto = p->proto;
--- a/net/ipv4/fib_semantics.c
+++ b/net/ipv4/fib_semantics.c
-@@ -138,6 +138,10 @@ const struct fib_prop fib_props[RTN_MAX
+@@ -138,6 +138,10 @@ const struct fib_prop fib_props[RTN_MAX
.error = -EINVAL,
.scope = RT_SCOPE_NOWHERE,
},
--- a/drivers/net/wireless/hostap/hostap_ap.c
+++ b/drivers/net/wireless/hostap/hostap_ap.c
-@@ -2403,13 +2403,13 @@ int prism2_ap_get_sta_qual(local_info_t
+@@ -2403,13 +2403,13 @@ int prism2_ap_get_sta_qual(local_info_t
addr[count].sa_family = ARPHRD_ETHER;
memcpy(addr[count].sa_data, sta->addr, ETH_ALEN);
if (sta->last_rx_silence == 0)
#include <bcm47xx_nvram.h>
static const struct bcma_device_id bgmac_bcma_tbl[] = {
-@@ -1405,6 +1406,17 @@ static void bgmac_mii_unregister(struct
+@@ -1405,6 +1406,17 @@ static void bgmac_mii_unregister(struct
mdiobus_free(mii_bus);
}
default y
--- a/drivers/pci/quirks.c
+++ b/drivers/pci/quirks.c
-@@ -41,6 +41,7 @@ static void quirk_mmio_always_on(struct
+@@ -41,6 +41,7 @@ static void quirk_mmio_always_on(struct
DECLARE_PCI_FIXUP_CLASS_EARLY(PCI_ANY_ID, PCI_ANY_ID,
PCI_CLASS_BRIDGE_HOST, 8, quirk_mmio_always_on);
--- a/fs/locks.c
+++ b/fs/locks.c
-@@ -2429,6 +2429,8 @@ static const struct file_operations proc
+@@ -2441,6 +2441,8 @@ static const struct file_operations proc
static int __init proc_locks_init(void)
{
&fib_triestat_fops))
goto out2;
-@@ -2594,17 +2596,21 @@ int __net_init fib_proc_init(struct net
+@@ -2594,17 +2596,21 @@ int __net_init fib_proc_init(struct net
return 0;
out3:
* All of these routines try to estimate how many bits of randomness a
* particular randomness source. They do this by keeping track of the
* first and second order deltas of the event timings.
-@@ -889,6 +899,63 @@ void add_disk_randomness(struct gendisk
+@@ -889,6 +899,63 @@ void add_disk_randomness(struct gendisk
}
#endif
};
uart4 {
-@@ -1106,6 +1157,15 @@
- >;
+@@ -1107,6 +1158,15 @@
};
};
-+
+
+ uart5 {
+ pinctrl_uart5_1: uart5grp-1 {
+ fsl,pins = <
+ >;
+ };
+ };
-
++
usbotg {
pinctrl_usbotg_1: usbotggrp-1 {
+ fsl,pins = <
#ifdef CONFIG_IGB_HWMON
igb_sysfs_exit(adapter);
#endif
-@@ -3038,6 +3170,12 @@ static int __igb_open(struct net_device
+@@ -3038,6 +3170,12 @@ static int __igb_open(struct net_device
if (!resuming)
pm_runtime_put(&pdev->dev);
--- a/drivers/net/phy/Kconfig
+++ b/drivers/net/phy/Kconfig
-@@ -270,6 +270,14 @@ endif # RTL8366_SMI
+@@ -278,6 +278,14 @@ endif # RTL8366_SMI
source "drivers/net/phy/b53/Kconfig"
config MICREL_KS8995MA
--- a/drivers/net/phy/Makefile
+++ b/drivers/net/phy/Makefile
-@@ -39,6 +39,7 @@ obj-$(CONFIG_NATIONAL_PHY) += national.o
+@@ -40,6 +40,7 @@ obj-$(CONFIG_NATIONAL_PHY) += national.o
obj-$(CONFIG_DP83640_PHY) += dp83640.o
obj-$(CONFIG_STE10XP) += ste10Xp.o
obj-$(CONFIG_MICREL_PHY) += micrel.o
--- a/arch/arm/mach-ixp4xx/fsg-setup.c
+++ b/arch/arm/mach-ixp4xx/fsg-setup.c
-@@ -142,12 +142,14 @@ static struct platform_device fsg_eth[]
+@@ -142,12 +142,14 @@ static struct platform_device fsg_eth[]
.id = IXP4XX_ETH_NPEB,
.dev = {
.platform_data = fsg_plat_eth,
-Index: linux-3.14.25/drivers/gpio/Kconfig
-===================================================================
---- linux-3.14.25.orig/drivers/gpio/Kconfig 2014-11-30 15:25:59.554663011 +0100
-+++ linux-3.14.25/drivers/gpio/Kconfig 2014-11-30 15:26:36.399907220 +0100
-@@ -722,6 +722,14 @@
+--- a/drivers/gpio/Kconfig
++++ b/drivers/gpio/Kconfig
+@@ -722,6 +722,14 @@ config GPIO_RDC321X
Support for the RDC R321x SoC GPIOs over southbridge
PCI configuration space.
comment "SPI GPIO expanders:"
config GPIO_MAX7301
-Index: linux-3.14.25/drivers/gpio/Makefile
-===================================================================
---- linux-3.14.25.orig/drivers/gpio/Makefile 2014-11-30 15:25:59.554663011 +0100
-+++ linux-3.14.25/drivers/gpio/Makefile 2014-11-30 15:26:36.399907220 +0100
-@@ -99,3 +99,4 @@
+--- a/drivers/gpio/Makefile
++++ b/drivers/gpio/Makefile
+@@ -99,3 +99,4 @@ obj-$(CONFIG_GPIO_WM8350) += gpio-wm8350
obj-$(CONFIG_GPIO_WM8994) += gpio-wm8994.o
obj-$(CONFIG_GPIO_XILINX) += gpio-xilinx.o
obj-$(CONFIG_GPIO_XTENSA) += gpio-xtensa.o
+obj-$(CONFIG_GPIO_GW_I2C_PLD) += gw_i2c_pld.o
-Index: linux-3.14.25/drivers/gpio/gw_i2c_pld.c
-===================================================================
---- /dev/null 1970-01-01 00:00:00.000000000 +0000
-+++ linux-3.14.25/drivers/gpio/gw_i2c_pld.c 2014-12-01 07:15:30.030979315 +0100
+--- /dev/null
++++ b/drivers/gpio/gw_i2c_pld.c
@@ -0,0 +1,374 @@
+/*
+ * Gateworks I2C PLD GPIO expander
+
+MODULE_LICENSE("GPL");
+MODULE_AUTHOR("Chris Lang");
-Index: linux-3.14.25/include/linux/i2c/gw_i2c_pld.h
-===================================================================
---- /dev/null 1970-01-01 00:00:00.000000000 +0000
-+++ linux-3.14.25/include/linux/i2c/gw_i2c_pld.h 2014-11-30 15:26:36.403907355 +0100
+--- /dev/null
++++ b/include/linux/i2c/gw_i2c_pld.h
@@ -0,0 +1,20 @@
+#ifndef __LINUX_GW_I2C_PLD_H
+#define __LINUX_GW_I2C_PLD_H
-Index: linux-3.14.25/arch/arm/mach-ixp4xx/common.c
-===================================================================
---- linux-3.14.25.orig/arch/arm/mach-ixp4xx/common.c 2014-11-21 18:23:44.000000000 +0100
-+++ linux-3.14.25/arch/arm/mach-ixp4xx/common.c 2014-12-01 07:16:02.172180453 +0100
-@@ -84,22 +84,7 @@
+--- a/arch/arm/mach-ixp4xx/common.c
++++ b/arch/arm/mach-ixp4xx/common.c
+@@ -84,22 +84,7 @@ void __init ixp4xx_map_io(void)
/*
* GPIO-functions
*/
{
if (direction == IXP4XX_GPIO_IN)
*IXP4XX_GPIO_GPOER |= (1 << line);
-@@ -107,12 +92,12 @@
+@@ -107,12 +92,12 @@ static void gpio_line_config(u8 line, u3
*IXP4XX_GPIO_GPOER &= ~(1 << line);
}
{
if (value == IXP4XX_GPIO_HIGH)
*IXP4XX_GPIO_GPOUTR |= (1 << line);
-Index: linux-3.14.25/arch/arm/mach-ixp4xx/include/mach/platform.h
-===================================================================
---- linux-3.14.25.orig/arch/arm/mach-ixp4xx/include/mach/platform.h 2014-11-30 15:26:43.020130937 +0100
-+++ linux-3.14.25/arch/arm/mach-ixp4xx/include/mach/platform.h 2014-12-01 07:16:22.024919689 +0100
-@@ -142,5 +142,21 @@
+--- a/arch/arm/mach-ixp4xx/include/mach/platform.h
++++ b/arch/arm/mach-ixp4xx/include/mach/platform.h
+@@ -131,5 +131,21 @@ struct pci_sys_data;
extern int ixp4xx_setup(int nr, struct pci_sys_data *sys);
extern struct pci_ops ixp4xx_ops;
-Index: linux-3.14.25/arch/arm/mach-ixp4xx/Kconfig
-===================================================================
---- linux-3.14.25.orig/arch/arm/mach-ixp4xx/Kconfig 2014-11-30 15:26:41.488079161 +0100
-+++ linux-3.14.25/arch/arm/mach-ixp4xx/Kconfig 2014-12-01 07:28:47.406514014 +0100
-@@ -21,6 +21,14 @@
+--- a/arch/arm/mach-ixp4xx/Kconfig
++++ b/arch/arm/mach-ixp4xx/Kconfig
+@@ -21,6 +21,14 @@ config MACH_AVILA
Avila Network Platform. For more information on this platform,
see <file:Documentation/arm/IXP4xx>.
config MACH_LOFT
bool "Loft"
depends on MACH_AVILA
-@@ -218,7 +226,7 @@
+@@ -218,7 +226,7 @@ config CPU_IXP46X
config CPU_IXP43X
bool
default y
config MACH_GTWX5715
-Index: linux-3.14.25/arch/arm/mach-ixp4xx/Makefile
-===================================================================
---- linux-3.14.25.orig/arch/arm/mach-ixp4xx/Makefile 2014-11-30 15:26:41.488079161 +0100
-+++ linux-3.14.25/arch/arm/mach-ixp4xx/Makefile 2014-12-01 07:28:47.406514014 +0100
-@@ -7,6 +7,7 @@
+--- a/arch/arm/mach-ixp4xx/Makefile
++++ b/arch/arm/mach-ixp4xx/Makefile
+@@ -7,6 +7,7 @@ obj-pci-n :=
obj-pci-$(CONFIG_ARCH_IXDP4XX) += ixdp425-pci.o
obj-pci-$(CONFIG_MACH_AVILA) += avila-pci.o
obj-pci-$(CONFIG_MACH_IXDPG425) += ixdpg425-pci.o
obj-pci-$(CONFIG_ARCH_ADI_COYOTE) += coyote-pci.o
obj-pci-$(CONFIG_MACH_GTWX5715) += gtwx5715-pci.o
-@@ -31,6 +32,7 @@
+@@ -31,6 +32,7 @@ obj-y += common.o
obj-$(CONFIG_ARCH_IXDP4XX) += ixdp425-setup.o
obj-$(CONFIG_MACH_AVILA) += avila-setup.o
obj-$(CONFIG_MACH_IXDPG425) += coyote-setup.o
obj-$(CONFIG_ARCH_ADI_COYOTE) += coyote-setup.o
obj-$(CONFIG_MACH_GTWX5715) += gtwx5715-setup.o
-Index: linux-3.14.25/arch/arm/mach-ixp4xx/cambria-pci.c
-===================================================================
---- /dev/null 1970-01-01 00:00:00.000000000 +0000
-+++ linux-3.14.25/arch/arm/mach-ixp4xx/cambria-pci.c 2014-11-30 15:26:41.728087272 +0100
+--- /dev/null
++++ b/arch/arm/mach-ixp4xx/cambria-pci.c
@@ -0,0 +1,78 @@
+/*
+ * arch/arch/mach-ixp4xx/cambria-pci.c
+}
+
+subsys_initcall(cambria_pci_init);
-Index: linux-3.14.25/arch/arm/mach-ixp4xx/cambria-setup.c
-===================================================================
---- /dev/null 1970-01-01 00:00:00.000000000 +0000
-+++ linux-3.14.25/arch/arm/mach-ixp4xx/cambria-setup.c 2014-11-30 16:06:45.622389213 +0100
+--- /dev/null
++++ b/arch/arm/mach-ixp4xx/cambria-setup.c
@@ -0,0 +1,1003 @@
+/*
+ * arch/arm/mach-ixp4xx/cambria-setup.c
-Index: linux-3.14.25/arch/arm/mach-ixp4xx/avila-pci.c
-===================================================================
---- linux-3.14.25.orig/arch/arm/mach-ixp4xx/avila-pci.c 2014-11-30 15:25:58.890640602 +0100
-+++ linux-3.14.25/arch/arm/mach-ixp4xx/avila-pci.c 2014-11-30 15:26:43.548148782 +0100
+--- a/arch/arm/mach-ixp4xx/avila-pci.c
++++ b/arch/arm/mach-ixp4xx/avila-pci.c
@@ -27,8 +27,8 @@
#include <mach/hardware.h>
#include <asm/mach-types.h>
#define IRQ_LINES 4
/* PCI controller GPIO to IRQ pin mappings */
-@@ -55,10 +55,8 @@
+@@ -55,10 +55,8 @@ static int __init avila_map_irq(const st
IXP4XX_GPIO_IRQ(INTD)
};
return -1;
}
-Index: linux-3.14.25/arch/arm/mach-ixp4xx/avila-setup.c
-===================================================================
---- linux-3.14.25.orig/arch/arm/mach-ixp4xx/avila-setup.c 2014-11-30 15:25:58.890640602 +0100
-+++ linux-3.14.25/arch/arm/mach-ixp4xx/avila-setup.c 2014-11-30 16:03:14.803148025 +0100
+--- a/arch/arm/mach-ixp4xx/avila-setup.c
++++ b/arch/arm/mach-ixp4xx/avila-setup.c
@@ -14,9 +14,16 @@
#include <linux/kernel.h>
#include <linux/init.h>
static struct flash_platform_data avila_flash_data = {
.map_name = "cfi_probe",
.width = 2,
-@@ -105,14 +127,69 @@
+@@ -105,14 +127,69 @@ static struct platform_device avila_uart
.resource = avila_uart_resources
};
.name = "intrq",
.start = IRQ_IXP4XX_GPIO12,
.end = IRQ_IXP4XX_GPIO12,
-@@ -133,21 +210,237 @@
+@@ -133,21 +210,237 @@ static struct platform_device avila_pata
.resource = avila_pata_resources,
};
avila_pata_resources[0].start = IXP4XX_EXP_BUS_BASE(1);
avila_pata_resources[0].end = IXP4XX_EXP_BUS_END(1);
-@@ -159,8 +452,335 @@
+@@ -159,8 +452,335 @@ static void __init avila_init(void)
avila_pata_data.cs1_cfg = IXP4XX_EXP_CS2;
platform_device_register(&avila_pata);
--- a/arch/arm/mach-ixp4xx/ixdp425-pci.c
+++ b/arch/arm/mach-ixp4xx/ixdp425-pci.c
-@@ -53,7 +53,7 @@ static int __init ixdp425_map_irq(const
+@@ -53,7 +53,7 @@ static int __init ixdp425_map_irq(const
};
if (slot >= 1 && slot <= MAX_DEV && pin >= 1 && pin <= IRQ_LINES)
create mode 100644 arch/mips/pci/ifxmips_pcie_vr9.h
create mode 100644 arch/mips/pci/pcie-lantiq.h
-diff --git a/arch/mips/lantiq/Kconfig b/arch/mips/lantiq/Kconfig
-index c002191..1621b1d 100644
--- a/arch/mips/lantiq/Kconfig
+++ b/arch/mips/lantiq/Kconfig
@@ -17,6 +17,7 @@ config SOC_XWAY
config XRX200_PHY_FW
bool "XRX200 PHY firmware loader"
depends on SOC_XWAY
-diff --git a/arch/mips/lantiq/xway/sysctrl.c b/arch/mips/lantiq/xway/sysctrl.c
-index 51804b1..510a387 100644
--- a/arch/mips/lantiq/xway/sysctrl.c
+++ b/arch/mips/lantiq/xway/sysctrl.c
@@ -377,6 +377,8 @@ void __init ltq_soc_init(void)
} else if (of_machine_is_compatible("lantiq,ar9")) {
clkdev_add_static(ltq_ar9_cpu_hz(), ltq_ar9_fpi_hz(),
ltq_ar9_fpi_hz(), CLOCK_250M);
-diff --git a/arch/mips/pci/Makefile b/arch/mips/pci/Makefile
-index 137f2a6..1e1726f 100644
--- a/arch/mips/pci/Makefile
+++ b/arch/mips/pci/Makefile
-@@ -42,6 +42,8 @@ obj-$(CONFIG_SNI_RM) += fixup-sni.o ops-sni.o
+@@ -42,6 +42,8 @@ obj-$(CONFIG_SNI_RM) += fixup-sni.o ops
obj-$(CONFIG_LANTIQ) += fixup-lantiq.o
obj-$(CONFIG_PCI_LANTIQ) += pci-lantiq.o ops-lantiq.o
obj-$(CONFIG_SOC_RT3883) += pci-rt3883.o
obj-$(CONFIG_TANBAC_TB0219) += fixup-tb0219.o
obj-$(CONFIG_TANBAC_TB0226) += fixup-tb0226.o
obj-$(CONFIG_TANBAC_TB0287) += fixup-tb0287.o
-diff --git a/arch/mips/pci/fixup-lantiq-pcie.c b/arch/mips/pci/fixup-lantiq-pcie.c
-new file mode 100644
-index 0000000..3325e24
--- /dev/null
+++ b/arch/mips/pci/fixup-lantiq-pcie.c
@@ -0,0 +1,82 @@
+
+DECLARE_PCI_FIXUP_EARLY(PCI_VENDOR_ID_LANTIQ, PCI_DEVICE_ID_LANTIQ_PCIE,
+ ifx_pcie_rc_class_early_fixup);
-diff --git a/arch/mips/pci/fixup-lantiq.c b/arch/mips/pci/fixup-lantiq.c
-index c2ce41e..c110c10 100644
--- a/arch/mips/pci/fixup-lantiq.c
+++ b/arch/mips/pci/fixup-lantiq.c
@@ -11,11 +11,12 @@
if (ltq_pci_plat_dev_init)
return ltq_pci_plat_dev_init(dev);
-@@ -25,5 +26,7 @@ int pcibios_plat_dev_init(struct pci_dev *dev)
+@@ -25,5 +26,7 @@ int pcibios_plat_dev_init(struct pci_dev
int __init pcibios_map_irq(const struct pci_dev *dev, u8 slot, u8 pin)
{
+ return ltq_pci_map_irq(dev, slot, pin);
return of_irq_parse_and_map_pci(dev, slot, pin);
}
-diff --git a/arch/mips/pci/ifxmips_pci_common.h b/arch/mips/pci/ifxmips_pci_common.h
-new file mode 100644
-index 0000000..46f4cb2
--- /dev/null
+++ b/arch/mips/pci/ifxmips_pci_common.h
@@ -0,0 +1,57 @@
+
+#endif /* IFXMIPS_PCI_COMMON_H */
+
-diff --git a/arch/mips/pci/ifxmips_pcie.c b/arch/mips/pci/ifxmips_pcie.c
-new file mode 100644
-index 0000000..4128898
--- /dev/null
+++ b/arch/mips/pci/ifxmips_pcie.c
@@ -0,0 +1,1099 @@
+MODULE_SUPPORTED_DEVICE("Infineon builtin PCIe RC module");
+MODULE_DESCRIPTION("Infineon builtin PCIe RC driver");
+
-diff --git a/arch/mips/pci/ifxmips_pcie.h b/arch/mips/pci/ifxmips_pcie.h
-new file mode 100644
-index 0000000..c6f92f5
--- /dev/null
+++ b/arch/mips/pci/ifxmips_pcie.h
@@ -0,0 +1,135 @@
+
+#endif /* IFXMIPS_PCIE_H */
+
-diff --git a/arch/mips/pci/ifxmips_pcie_ar10.h b/arch/mips/pci/ifxmips_pcie_ar10.h
-new file mode 100644
-index 0000000..99ff463
--- /dev/null
+++ b/arch/mips/pci/ifxmips_pcie_ar10.h
@@ -0,0 +1,290 @@
+}
+
+#endif /* IFXMIPS_PCIE_AR10_H */
-diff --git a/arch/mips/pci/ifxmips_pcie_msi.c b/arch/mips/pci/ifxmips_pcie_msi.c
-new file mode 100644
-index 0000000..bffd6fa
--- /dev/null
+++ b/arch/mips/pci/ifxmips_pcie_msi.c
@@ -0,0 +1,392 @@
+MODULE_SUPPORTED_DEVICE("Infineon PCIe IP builtin MSI PIC module");
+MODULE_DESCRIPTION("Infineon PCIe IP builtin MSI PIC driver");
+
-diff --git a/arch/mips/pci/ifxmips_pcie_phy.c b/arch/mips/pci/ifxmips_pcie_phy.c
-new file mode 100644
-index 0000000..f5b0f13
--- /dev/null
+++ b/arch/mips/pci/ifxmips_pcie_phy.c
@@ -0,0 +1,478 @@
+#endif
+}
+
-diff --git a/arch/mips/pci/ifxmips_pcie_pm.c b/arch/mips/pci/ifxmips_pcie_pm.c
-new file mode 100644
-index 0000000..a10ecad
--- /dev/null
+++ b/arch/mips/pci/ifxmips_pcie_pm.c
@@ -0,0 +1,176 @@
+ ifx_pmcu_unregister(&pmcuUnRegister);
+}
+
-diff --git a/arch/mips/pci/ifxmips_pcie_pm.h b/arch/mips/pci/ifxmips_pcie_pm.h
-new file mode 100644
-index 0000000..6ece20d
--- /dev/null
+++ b/arch/mips/pci/ifxmips_pcie_pm.h
@@ -0,0 +1,36 @@
+
+#endif /* IFXMIPS_PCIE_PM_H */
+
-diff --git a/arch/mips/pci/ifxmips_pcie_reg.h b/arch/mips/pci/ifxmips_pcie_reg.h
-new file mode 100644
-index 0000000..e7e4b6c
--- /dev/null
+++ b/arch/mips/pci/ifxmips_pcie_reg.h
@@ -0,0 +1,1001 @@
+
+#endif /* IFXMIPS_PCIE_REG_H */
+
-diff --git a/arch/mips/pci/ifxmips_pcie_vr9.h b/arch/mips/pci/ifxmips_pcie_vr9.h
-new file mode 100644
-index 0000000..57d9368
--- /dev/null
+++ b/arch/mips/pci/ifxmips_pcie_vr9.h
@@ -0,0 +1,271 @@
+
+#endif /* IFXMIPS_PCIE_VR9_H */
+
-diff --git a/arch/mips/pci/pci.c b/arch/mips/pci/pci.c
-index 1bf60b1..31ee19b 100644
--- a/arch/mips/pci/pci.c
+++ b/arch/mips/pci/pci.c
@@ -251,6 +251,31 @@ static int __init pcibios_init(void)
static int pcibios_enable_resources(struct pci_dev *dev, int mask)
{
u16 cmd, old_cmd;
-diff --git a/arch/mips/pci/pcie-lantiq.h b/arch/mips/pci/pcie-lantiq.h
-new file mode 100644
-index 0000000..d877c23
--- /dev/null
+++ b/arch/mips/pci/pcie-lantiq.h
@@ -0,0 +1,1305 @@
+
+#endif /* IFXMIPS_PCIE_VR9_H */
+
-diff --git a/drivers/pci/pcie/aer/Kconfig b/drivers/pci/pcie/aer/Kconfig
-index 50e94e0..4bf848f 100644
--- a/drivers/pci/pcie/aer/Kconfig
+++ b/drivers/pci/pcie/aer/Kconfig
@@ -5,7 +5,7 @@
help
This enables PCI Express Root Port Advanced Error Reporting
(AER) driver support. Error reporting messages sent to Root
-diff --git a/include/linux/pci.h b/include/linux/pci.h
-index 33aa2ca..f5e4a13 100644
--- a/include/linux/pci.h
+++ b/include/linux/pci.h
-@@ -1120,6 +1120,8 @@ void pci_walk_bus(struct pci_bus *top, int (*cb)(struct pci_dev *, void *),
+@@ -1121,6 +1121,8 @@ void pci_walk_bus(struct pci_bus *top, i
void *userdata);
int pci_cfg_space_size(struct pci_dev *dev);
unsigned char pci_bus_max_busnr(struct pci_bus *bus);
void pci_setup_bridge(struct pci_bus *bus);
resource_size_t pcibios_window_alignment(struct pci_bus *bus,
unsigned long type);
-diff --git a/include/linux/pci_ids.h b/include/linux/pci_ids.h
-index 97fbecd..cb3bde3 100644
--- a/include/linux/pci_ids.h
+++ b/include/linux/pci_ids.h
@@ -1045,6 +1045,12 @@
#define PCI_VENDOR_ID_WINBOND 0x10ad
#define PCI_DEVICE_ID_WINBOND_82C105 0x0105
#define PCI_DEVICE_ID_WINBOND_83C553 0x0565
---
-1.7.10.4
-
arch/mips/lantiq/prom.c | 4 +++-
2 files changed, 3 insertions(+), 3 deletions(-)
-diff --git a/arch/mips/lantiq/Makefile b/arch/mips/lantiq/Makefile
-index d6bdc57..690257a 100644
--- a/arch/mips/lantiq/Makefile
+++ b/arch/mips/lantiq/Makefile
@@ -6,8 +6,6 @@
obj-$(CONFIG_EARLY_PRINTK) += early_printk.o
obj-$(CONFIG_SOC_TYPE_XWAY) += xway/
-diff --git a/arch/mips/lantiq/prom.c b/arch/mips/lantiq/prom.c
-index 19686c5..202e118 100644
--- a/arch/mips/lantiq/prom.c
+++ b/arch/mips/lantiq/prom.c
-@@ -58,6 +58,8 @@ static void __init prom_init_cmdline(void)
+@@ -58,6 +58,8 @@ static void __init prom_init_cmdline(voi
}
}
}
void __init device_tree_init(void)
---
-1.7.10.4
-
2 files changed, 65 insertions(+)
create mode 100644 arch/mips/lantiq/xway/vmmc.c
-diff --git a/arch/mips/lantiq/xway/Makefile b/arch/mips/lantiq/xway/Makefile
-index 087497d..a2edc53 100644
--- a/arch/mips/lantiq/xway/Makefile
+++ b/arch/mips/lantiq/xway/Makefile
@@ -1,3 +1,5 @@
+obj-y += vmmc.o
+
obj-$(CONFIG_XRX200_PHY_FW) += xrx200_phy_fw.o
-diff --git a/arch/mips/lantiq/xway/vmmc.c b/arch/mips/lantiq/xway/vmmc.c
-new file mode 100644
-index 0000000..cea0ff9
--- /dev/null
+++ b/arch/mips/lantiq/xway/vmmc.c
@@ -0,0 +1,63 @@
+};
+
+module_platform_driver(vmmc_driver);
---
-1.7.10.4
-
create mode 100644 arch/mips/include/asm/mach-lantiq/lantiq_atm.h
create mode 100644 arch/mips/include/asm/mach-lantiq/lantiq_ptm.h
-diff --git a/arch/mips/include/asm/mach-lantiq/lantiq_atm.h b/arch/mips/include/asm/mach-lantiq/lantiq_atm.h
-new file mode 100644
-index 0000000..bf045a9
--- /dev/null
+++ b/arch/mips/include/asm/mach-lantiq/lantiq_atm.h
@@ -0,0 +1,196 @@
+
+#endif // IFX_ATM_H
+
-diff --git a/arch/mips/include/asm/mach-lantiq/lantiq_ptm.h b/arch/mips/include/asm/mach-lantiq/lantiq_ptm.h
-new file mode 100644
-index 0000000..698e5c3
--- /dev/null
+++ b/arch/mips/include/asm/mach-lantiq/lantiq_ptm.h
@@ -0,0 +1,203 @@
+
+#endif // IFX_PTM_H
+
-diff --git a/arch/mips/lantiq/irq.c b/arch/mips/lantiq/irq.c
-index 85685e1..6b94cc7 100644
--- a/arch/mips/lantiq/irq.c
+++ b/arch/mips/lantiq/irq.c
@@ -14,6 +14,7 @@
#include <asm/bootinfo.h>
#include <asm/irq_cpu.h>
-@@ -99,6 +100,7 @@ void ltq_mask_and_ack_irq(struct irq_data *d)
+@@ -99,6 +100,7 @@ void ltq_mask_and_ack_irq(struct irq_dat
ltq_icu_w32(im, ltq_icu_r32(im, ier) & ~BIT(offset), ier);
ltq_icu_w32(im, BIT(offset), isr);
}
static void ltq_ack_irq(struct irq_data *d)
{
-diff --git a/arch/mips/mm/cache.c b/arch/mips/mm/cache.c
-index fde7e56..e5bd72f 100644
--- a/arch/mips/mm/cache.c
+++ b/arch/mips/mm/cache.c
-@@ -57,6 +57,8 @@ void (*_dma_cache_wback)(unsigned long start, unsigned long size);
+@@ -58,6 +58,8 @@ void (*_dma_cache_wback)(unsigned long s
void (*_dma_cache_inv)(unsigned long start, unsigned long size);
EXPORT_SYMBOL(_dma_cache_wback_inv);
#endif /* CONFIG_DMA_NONCOHERENT */
-diff --git a/include/uapi/linux/atm.h b/include/uapi/linux/atm.h
-index 88399db..78c8bbc 100644
--- a/include/uapi/linux/atm.h
+++ b/include/uapi/linux/atm.h
@@ -130,8 +130,14 @@
struct atm_trafprm {
unsigned char traffic_class; /* traffic class (ATM_UBR, ...) */
int max_pcr; /* maximum PCR in cells per second */
-diff --git a/net/atm/common.c b/net/atm/common.c
-index 7b49100..d2af929 100644
--- a/net/atm/common.c
+++ b/net/atm/common.c
-@@ -62,11 +62,17 @@ static void vcc_remove_socket(struct sock *sk)
+@@ -62,11 +62,17 @@ static void vcc_remove_socket(struct soc
write_unlock_irq(&vcc_sklist_lock);
}
if (sk_wmem_alloc_get(sk) && !atm_may_send(vcc, size)) {
pr_debug("Sorry: wmem_alloc = %d, size = %d, sndbuf = %d\n",
sk_wmem_alloc_get(sk), size, sk->sk_sndbuf);
-diff --git a/net/atm/proc.c b/net/atm/proc.c
-index bbb6461..ecb584a 100644
--- a/net/atm/proc.c
+++ b/net/atm/proc.c
-@@ -154,7 +154,7 @@ static void *vcc_seq_next(struct seq_file *seq, void *v, loff_t *pos)
+@@ -154,7 +154,7 @@ static void *vcc_seq_next(struct seq_fil
static void pvc_info(struct seq_file *seq, struct atm_vcc *vcc)
{
static const char *const class_name[] = {
static const char *const aal_name[] = {
"---", "1", "2", "3/4", /* 0- 3 */
"???", "5", "???", "???", /* 4- 7 */
---
-1.7.10.4
-
arch/mips/lantiq/xway/reset.c | 61 +++++++++++++++++++++++++++++++++++++++++
1 file changed, 61 insertions(+)
-diff --git a/arch/mips/lantiq/xway/reset.c b/arch/mips/lantiq/xway/reset.c
-index 1fa0f17..a1e06b7 100644
--- a/arch/mips/lantiq/xway/reset.c
+++ b/arch/mips/lantiq/xway/reset.c
@@ -14,6 +14,7 @@
#include <asm/reboot.h>
-@@ -113,6 +114,66 @@ void ltq_reset_once(unsigned int module, ulong u)
+@@ -113,6 +114,66 @@ void ltq_reset_once(unsigned int module,
ltq_rcu_w32(ltq_rcu_r32(RCU_RST_REQ) & ~module, RCU_RST_REQ);
}
static void ltq_machine_restart(char *command)
{
local_irq_disable();
---
-1.7.10.4
-
arch/mips/lantiq/xway/reset.c | 9 ++++++++-
1 file changed, 8 insertions(+), 1 deletion(-)
-diff --git a/arch/mips/lantiq/xway/reset.c b/arch/mips/lantiq/xway/reset.c
-index a1e06b7..fe68f9a 100644
--- a/arch/mips/lantiq/xway/reset.c
+++ b/arch/mips/lantiq/xway/reset.c
@@ -176,8 +176,15 @@ void ltq_rst_init(void)
unreachable();
}
---
-1.7.10.4
-
2 files changed, 88 insertions(+), 1 deletion(-)
create mode 100644 arch/mips/lantiq/xway/tffs.c
-diff --git a/arch/mips/lantiq/xway/Makefile b/arch/mips/lantiq/xway/Makefile
-index a2edc53..c73d3f2 100644
--- a/arch/mips/lantiq/xway/Makefile
+++ b/arch/mips/lantiq/xway/Makefile
@@ -1,5 +1,5 @@
+obj-y += vmmc.o tffs.o
obj-$(CONFIG_XRX200_PHY_FW) += xrx200_phy_fw.o
-diff --git a/arch/mips/lantiq/xway/tffs.c b/arch/mips/lantiq/xway/tffs.c
-new file mode 100644
-index 0000000..c9c6e19
--- /dev/null
+++ b/arch/mips/lantiq/xway/tffs.c
@@ -0,0 +1,87 @@
+}
+late_initcall(tffs_init);
+
---
-1.7.10.4
-
create mode 100644 arch/mips/include/asm/mach-lantiq/lantiq_timer.h
create mode 100644 arch/mips/lantiq/xway/timer.c
-diff --git a/arch/mips/include/asm/mach-lantiq/lantiq_timer.h b/arch/mips/include/asm/mach-lantiq/lantiq_timer.h
-new file mode 100644
-index 0000000..ef564ab
--- /dev/null
+++ b/arch/mips/include/asm/mach-lantiq/lantiq_timer.h
@@ -0,0 +1,155 @@
+ u32 reload, unsigned long arg1, unsigned long arg2);
+
+#endif /* __DANUBE_GPTU_DEV_H__2005_07_26__10_19__ */
-diff --git a/arch/mips/lantiq/xway/Makefile b/arch/mips/lantiq/xway/Makefile
-index c73d3f2..2dd442c 100644
--- a/arch/mips/lantiq/xway/Makefile
+++ b/arch/mips/lantiq/xway/Makefile
@@ -1,4 +1,4 @@
obj-y += vmmc.o tffs.o
-diff --git a/arch/mips/lantiq/xway/timer.c b/arch/mips/lantiq/xway/timer.c
-new file mode 100644
-index 0000000..1c0fdb8
--- /dev/null
+++ b/arch/mips/lantiq/xway/timer.c
@@ -0,0 +1,845 @@
+module_exit(lq_gptu_exit);
+
+#endif
---
-1.7.10.4
-
arch/mips/lantiq/prom.c | 2 ++
1 file changed, 2 insertions(+)
-diff --git a/arch/mips/lantiq/prom.c b/arch/mips/lantiq/prom.c
-index 202e118..227feed 100644
--- a/arch/mips/lantiq/prom.c
+++ b/arch/mips/lantiq/prom.c
@@ -74,6 +74,8 @@ void __init plat_mem_setup(void)
}
void __init device_tree_init(void)
---
-1.7.10.4
-
arch/mips/lantiq/prom.c | 5 +++++
2 files changed, 7 insertions(+)
-diff --git a/arch/mips/include/asm/mach-lantiq/lantiq.h b/arch/mips/include/asm/mach-lantiq/lantiq.h
-index f196cce..4e5ae65 100644
--- a/arch/mips/include/asm/mach-lantiq/lantiq.h
+++ b/arch/mips/include/asm/mach-lantiq/lantiq.h
@@ -48,6 +48,8 @@ extern struct clk *clk_get_ppe(void);
#define IOPORT_RESOURCE_START 0x10000000
#define IOPORT_RESOURCE_END 0xffffffff
-diff --git a/arch/mips/lantiq/prom.c b/arch/mips/lantiq/prom.c
-index 227feed..4c652c6 100644
--- a/arch/mips/lantiq/prom.c
+++ b/arch/mips/lantiq/prom.c
@@ -36,6 +36,11 @@ const char *get_system_type(void)
void prom_free_prom_memory(void)
{
}
---
-1.7.10.4
-
arch/mips/lantiq/xway/xrx200_phy_fw.c | 18 +++++++++++++++++-
1 file changed, 17 insertions(+), 1 deletion(-)
-diff --git a/arch/mips/lantiq/xway/xrx200_phy_fw.c b/arch/mips/lantiq/xway/xrx200_phy_fw.c
-index d4d9d31..3479b77 100644
--- a/arch/mips/lantiq/xway/xrx200_phy_fw.c
+++ b/arch/mips/lantiq/xway/xrx200_phy_fw.c
-@@ -24,7 +24,23 @@ static dma_addr_t xway_gphy_load(struct platform_device *pdev)
+@@ -24,7 +24,23 @@ static dma_addr_t xway_gphy_load(struct
void *fw_addr;
size_t size;
dev_err(&pdev->dev, "failed to load firmware filename\n");
return 0;
}
---
-1.7.10.4
-
drivers/pinctrl/pinctrl-xway.c | 28 ++++++++++++++++++++++++++--
1 file changed, 26 insertions(+), 2 deletions(-)
-diff --git a/drivers/pinctrl/pinctrl-xway.c b/drivers/pinctrl/pinctrl-xway.c
-index e66f4ca..b5f43c8 100644
--- a/drivers/pinctrl/pinctrl-xway.c
+++ b/drivers/pinctrl/pinctrl-xway.c
-@@ -609,10 +609,9 @@ static struct pinctrl_desc xway_pctrl_desc = {
+@@ -609,10 +609,9 @@ static struct pinctrl_desc xway_pctrl_de
.confops = &xway_pinconf_ops,
};
int port = PORT(pin);
u32 alt1_reg = GPIO_ALT1(pin);
-@@ -632,6 +631,14 @@ static inline int xway_mux_apply(struct pinctrl_dev *pctrldev,
+@@ -632,6 +631,14 @@ static inline int xway_mux_apply(struct
return 0;
}
static const struct ltq_cfg_param xway_cfg_params[] = {
{"lantiq,pull", LTQ_PINCONF_PARAM_PULL},
{"lantiq,open-drain", LTQ_PINCONF_PARAM_OPEN_DRAIN},
-@@ -676,6 +683,10 @@ static int xway_gpio_dir_out(struct gpio_chip *chip, unsigned int pin, int val)
+@@ -676,6 +683,10 @@ static int xway_gpio_dir_out(struct gpio
{
struct ltq_pinmux_info *info = dev_get_drvdata(chip->dev);
gpio_setbit(info->membase[0], GPIO_DIR(pin), PORT_PIN(pin));
xway_gpio_set(chip, pin, val);
-@@ -696,6 +707,18 @@ static void xway_gpio_free(struct gpio_chip *chip, unsigned offset)
+@@ -696,6 +707,18 @@ static void xway_gpio_free(struct gpio_c
pinctrl_free_gpio(gpio);
}
.base = -1,
};
---
-1.7.10.4
-
drivers/mtd/nand/xway_nand.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
-diff --git a/drivers/mtd/nand/xway_nand.c b/drivers/mtd/nand/xway_nand.c
-index 3f81dc8..169a91d 100644
--- a/drivers/mtd/nand/xway_nand.c
+++ b/drivers/mtd/nand/xway_nand.c
-@@ -124,7 +124,7 @@ static unsigned char xway_read_byte(struct mtd_info *mtd)
+@@ -124,7 +124,7 @@ static unsigned char xway_read_byte(stru
int ret;
spin_lock_irqsave(&ebu_lock, flags);
spin_unlock_irqrestore(&ebu_lock, flags);
return ret;
---
-1.7.10.4
-
drivers/mtd/nand/xway_nand.c | 12 ++++++------
1 file changed, 6 insertions(+), 6 deletions(-)
-diff --git a/drivers/mtd/nand/xway_nand.c b/drivers/mtd/nand/xway_nand.c
-index 169a91d..7f2bdd1 100644
--- a/drivers/mtd/nand/xway_nand.c
+++ b/drivers/mtd/nand/xway_nand.c
@@ -54,6 +54,8 @@
static void xway_reset_chip(struct nand_chip *chip)
{
unsigned long nandaddr = (unsigned long) chip->IO_ADDR_W;
-@@ -94,17 +96,15 @@ static void xway_cmd_ctrl(struct mtd_info *mtd, int cmd, unsigned int ctrl)
+@@ -94,17 +96,15 @@ static void xway_cmd_ctrl(struct mtd_inf
unsigned long flags;
if (ctrl & NAND_CTRL_CHANGE) {
while ((ltq_ebu_r32(EBU_NAND_WAIT) & NAND_WAIT_WR_C) == 0)
;
spin_unlock_irqrestore(&ebu_lock, flags);
---
-1.7.10.4
-
drivers/mtd/nand/xway_nand.c | 10 ++++++++--
1 file changed, 8 insertions(+), 2 deletions(-)
-diff --git a/drivers/mtd/nand/xway_nand.c b/drivers/mtd/nand/xway_nand.c
-index 7f2bdd1..8d14f1b 100644
--- a/drivers/mtd/nand/xway_nand.c
+++ b/drivers/mtd/nand/xway_nand.c
@@ -59,16 +59,22 @@ static u32 xway_latchcmd;
spin_unlock_irqrestore(&ebu_lock, flags);
}
---
-1.7.10.4
-
drivers/mtd/nand/xway_nand.c | 28 ++++++++++++++++++++++++++++
1 file changed, 28 insertions(+)
-diff --git a/drivers/mtd/nand/xway_nand.c b/drivers/mtd/nand/xway_nand.c
-index 8d14f1b..f813a55 100644
--- a/drivers/mtd/nand/xway_nand.c
+++ b/drivers/mtd/nand/xway_nand.c
-@@ -136,6 +136,32 @@ static unsigned char xway_read_byte(struct mtd_info *mtd)
+@@ -136,6 +136,32 @@ static unsigned char xway_read_byte(stru
return ret;
}
static int xway_nand_probe(struct platform_device *pdev)
{
struct nand_chip *this = platform_get_drvdata(pdev);
-@@ -181,6 +207,8 @@ static struct platform_nand_data xway_nand_data = {
+@@ -181,6 +207,8 @@ static struct platform_nand_data xway_na
.dev_ready = xway_dev_ready,
.select_chip = xway_select_chip,
.read_byte = xway_read_byte,
}
};
---
-1.7.10.4
-
drivers/mtd/nand/xway_nand.c | 15 +++------------
1 file changed, 3 insertions(+), 12 deletions(-)
-diff --git a/drivers/mtd/nand/xway_nand.c b/drivers/mtd/nand/xway_nand.c
-index f813a55..e430f2d 100644
--- a/drivers/mtd/nand/xway_nand.c
+++ b/drivers/mtd/nand/xway_nand.c
-@@ -80,13 +80,16 @@ static void xway_reset_chip(struct nand_chip *chip)
+@@ -80,13 +80,16 @@ static void xway_reset_chip(struct nand_
static void xway_select_chip(struct mtd_info *mtd, int chip)
{
ltq_ebu_w32_mask(0, NAND_CON_NANDM, EBU_NAND_CON);
ltq_ebu_w32_mask(0, NAND_CON_CE, EBU_NAND_CON);
break;
-@@ -99,7 +102,6 @@ static void xway_cmd_ctrl(struct mtd_info *mtd, int cmd, unsigned int ctrl)
+@@ -99,7 +102,6 @@ static void xway_cmd_ctrl(struct mtd_inf
{
struct nand_chip *this = mtd->priv;
unsigned long nandaddr = (unsigned long) this->IO_ADDR_W;
if (ctrl & NAND_CTRL_CHANGE) {
if (ctrl & NAND_CLE)
-@@ -109,11 +111,9 @@ static void xway_cmd_ctrl(struct mtd_info *mtd, int cmd, unsigned int ctrl)
+@@ -109,11 +111,9 @@ static void xway_cmd_ctrl(struct mtd_inf
}
if (cmd != NAND_CMD_NONE) {
}
}
-@@ -126,12 +126,9 @@ static unsigned char xway_read_byte(struct mtd_info *mtd)
+@@ -126,12 +126,9 @@ static unsigned char xway_read_byte(stru
{
struct nand_chip *this = mtd->priv;
unsigned long nandaddr = (unsigned long) this->IO_ADDR_R;
return ret;
}
-@@ -140,26 +137,20 @@ static void xway_read_buf(struct mtd_info *mtd, u_char *buf, int len)
+@@ -140,26 +137,20 @@ static void xway_read_buf(struct mtd_inf
{
struct nand_chip *this = mtd->priv;
unsigned long nandaddr = (unsigned long) this->IO_ADDR_R;
}
static int xway_nand_probe(struct platform_device *pdev)
---
-1.7.10.4
-
drivers/mtd/nand/xway_nand.c | 63 ++++++++++++++++++++++++++++++++++++++++++
1 file changed, 63 insertions(+)
-diff --git a/drivers/mtd/nand/xway_nand.c b/drivers/mtd/nand/xway_nand.c
-index e430f2d..fedf2c4 100644
--- a/drivers/mtd/nand/xway_nand.c
+++ b/drivers/mtd/nand/xway_nand.c
@@ -54,8 +54,27 @@
static void xway_reset_chip(struct nand_chip *chip)
{
unsigned long nandaddr = (unsigned long) chip->IO_ADDR_W;
-@@ -86,12 +105,24 @@ static void xway_select_chip(struct mtd_info *mtd, int chip)
+@@ -86,12 +105,24 @@ static void xway_select_chip(struct mtd_
case -1:
ltq_ebu_w32_mask(NAND_CON_CE, 0, EBU_NAND_CON);
ltq_ebu_w32_mask(NAND_CON_NANDM, 0, EBU_NAND_CON);
break;
default:
BUG();
-@@ -103,6 +134,12 @@ static void xway_cmd_ctrl(struct mtd_info *mtd, int cmd, unsigned int ctrl)
+@@ -103,6 +134,12 @@ static void xway_cmd_ctrl(struct mtd_inf
struct nand_chip *this = mtd->priv;
unsigned long nandaddr = (unsigned long) this->IO_ADDR_W;
if (ctrl & NAND_CTRL_CHANGE) {
if (ctrl & NAND_CLE)
xway_latchcmd = NAND_WRITE_CMD;
-@@ -115,6 +152,24 @@ static void xway_cmd_ctrl(struct mtd_info *mtd, int cmd, unsigned int ctrl)
+@@ -115,6 +152,24 @@ static void xway_cmd_ctrl(struct mtd_inf
while ((ltq_ebu_r32(EBU_NAND_WAIT) & NAND_WAIT_WR_C) == 0)
;
}
}
static int xway_dev_ready(struct mtd_info *mtd)
-@@ -157,6 +212,8 @@ static int xway_nand_probe(struct platform_device *pdev)
+@@ -157,6 +212,8 @@ static int xway_nand_probe(struct platfo
{
struct nand_chip *this = platform_get_drvdata(pdev);
unsigned long nandaddr = (unsigned long) this->IO_ADDR_W;
const __be32 *cs = of_get_property(pdev->dev.of_node,
"lantiq,cs", NULL);
u32 cs_flag = 0;
-@@ -165,6 +222,12 @@ static int xway_nand_probe(struct platform_device *pdev)
+@@ -165,6 +222,12 @@ static int xway_nand_probe(struct platfo
if (cs && (*cs == 1))
cs_flag = NAND_CON_IN_CS1 | NAND_CON_OUT_CS1;
/* setup the EBU to run in NAND mode on our base addr */
ltq_ebu_w32(CPHYSADDR(nandaddr)
| ADDSEL1_MASK(3) | ADDSEL1_REGEN, EBU_ADDSEL1);
---
-1.7.10.4
-
3 files changed, 92 insertions(+)
create mode 100644 drivers/mtd/nand/falcon_nand.c
-diff --git a/drivers/mtd/nand/Kconfig b/drivers/mtd/nand/Kconfig
-index 90ff447..7064f0e 100644
--- a/drivers/mtd/nand/Kconfig
+++ b/drivers/mtd/nand/Kconfig
@@ -510,4 +510,12 @@ config MTD_NAND_XWAY
+ attached to the External Bus Unit (EBU).
+
endif # MTD_NAND
-diff --git a/drivers/mtd/nand/Makefile b/drivers/mtd/nand/Makefile
-index 542b568..78a1cd2 100644
--- a/drivers/mtd/nand/Makefile
+++ b/drivers/mtd/nand/Makefile
-@@ -49,5 +49,6 @@ obj-$(CONFIG_MTD_NAND_JZ4740) += jz4740_nand.o
+@@ -49,5 +49,6 @@ obj-$(CONFIG_MTD_NAND_JZ4740) += jz4740
obj-$(CONFIG_MTD_NAND_GPMI_NAND) += gpmi-nand/
obj-$(CONFIG_MTD_NAND_XWAY) += xway_nand.o
obj-$(CONFIG_MTD_NAND_BCM47XXNFLASH) += bcm47xxnflash/
+obj-$(CONFIG_MTD_NAND_FALCON) += falcon_nand.o
nand-objs := nand_base.o nand_bbt.o
-diff --git a/drivers/mtd/nand/falcon_nand.c b/drivers/mtd/nand/falcon_nand.c
-new file mode 100644
-index 0000000..13458d3
--- /dev/null
+++ b/drivers/mtd/nand/falcon_nand.c
@@ -0,0 +1,83 @@
+}
+
+arch_initcall(falcon_register_nand);
---
-1.7.10.4
-
drivers/mtd/maps/lantiq-flash.c | 6 +++++-
1 file changed, 5 insertions(+), 1 deletion(-)
-diff --git a/drivers/mtd/maps/lantiq-flash.c b/drivers/mtd/maps/lantiq-flash.c
-index 93c507a..710d699 100644
--- a/drivers/mtd/maps/lantiq-flash.c
+++ b/drivers/mtd/maps/lantiq-flash.c
-@@ -140,7 +140,11 @@ ltq_mtd_probe(struct platform_device *pdev)
+@@ -140,7 +140,11 @@ ltq_mtd_probe(struct platform_device *pd
if (!ltq_mtd->map)
return -ENOMEM;
ltq_mtd->map->size = resource_size(ltq_mtd->res);
ltq_mtd->map->virt = devm_ioremap_resource(&pdev->dev, ltq_mtd->res);
if (IS_ERR(ltq_mtd->map->virt))
---
-1.7.10.4
-
drivers/mtd/maps/lantiq-flash.c | 10 +++++++++-
1 file changed, 9 insertions(+), 1 deletion(-)
-diff --git a/drivers/mtd/maps/lantiq-flash.c b/drivers/mtd/maps/lantiq-flash.c
-index 710d699..dd1e853 100644
--- a/drivers/mtd/maps/lantiq-flash.c
+++ b/drivers/mtd/maps/lantiq-flash.c
-@@ -117,6 +117,11 @@ ltq_mtd_probe(struct platform_device *pdev)
+@@ -117,6 +117,11 @@ ltq_mtd_probe(struct platform_device *pd
struct cfi_private *cfi;
int err;
if (of_machine_is_compatible("lantiq,falcon") &&
(ltq_boot_select() != BS_FLASH)) {
dev_err(&pdev->dev, "invalid bootstrap options\n");
-@@ -158,7 +163,10 @@ ltq_mtd_probe(struct platform_device *pdev)
+@@ -158,7 +163,10 @@ ltq_mtd_probe(struct platform_device *pd
ltq_mtd->map->copy_to = ltq_copy_to;
ltq_mtd->map->map_priv_1 = LTQ_NOR_PROBING;
ltq_mtd->map->map_priv_1 = LTQ_NOR_NORMAL;
if (!ltq_mtd->mtd) {
---
-1.7.10.4
-
drivers/mtd/devices/m25p80.c | 6 ++++++
1 file changed, 6 insertions(+)
-diff --git a/drivers/mtd/devices/m25p80.c b/drivers/mtd/devices/m25p80.c
-index ad19139..9f7b35a 100644
--- a/drivers/mtd/devices/m25p80.c
+++ b/drivers/mtd/devices/m25p80.c
-@@ -1097,6 +1097,10 @@ static int m25p_probe(struct spi_device *spi)
+@@ -1105,6 +1105,10 @@ static int m25p_probe(struct spi_device
struct mtd_part_parser_data ppdata;
struct device_node *np = spi->dev.of_node;
int ret;
/* Platform data helps sort out which chip type we have, as
* well as how this board partitions it. If we don't have
-@@ -1169,6 +1173,8 @@ static int m25p_probe(struct spi_device *spi)
+@@ -1177,6 +1181,8 @@ static int m25p_probe(struct spi_device
if (data && data->name)
flash->mtd.name = data->name;
else
flash->mtd.name = dev_name(&spi->dev);
---
-1.7.10.4
-
3 files changed, 237 insertions(+)
create mode 100644 drivers/net/phy/lantiq.c
-diff --git a/drivers/net/phy/Kconfig b/drivers/net/phy/Kconfig
-index 9b5d46c..f3724b1 100644
--- a/drivers/net/phy/Kconfig
+++ b/drivers/net/phy/Kconfig
-@@ -106,6 +106,11 @@ config MICREL_PHY
+@@ -157,6 +157,11 @@ config MICREL_PHY
---help---
- Supports the KSZ9021, VSC8201, KS8001 PHYs.
+ Currently has a driver for the KSZ8041
+config LANTIQ_PHY
+ tristate "Driver for Lantiq PHYs"
config FIXED_PHY
bool "Driver for MDIO Bus/PHY emulation with fixed speed/link PHYs"
depends on PHYLIB=y
-diff --git a/drivers/net/phy/Makefile b/drivers/net/phy/Makefile
-index 9013dfa..b5e030f 100644
--- a/drivers/net/phy/Makefile
+++ b/drivers/net/phy/Makefile
-@@ -23,6 +23,7 @@ obj-$(CONFIG_NATIONAL_PHY) += national.o
+@@ -40,6 +40,7 @@ obj-$(CONFIG_NATIONAL_PHY) += national.o
obj-$(CONFIG_DP83640_PHY) += dp83640.o
obj-$(CONFIG_STE10XP) += ste10Xp.o
obj-$(CONFIG_MICREL_PHY) += micrel.o
obj-$(CONFIG_MDIO_OCTEON) += mdio-octeon.o
obj-$(CONFIG_MICREL_KS8995MA) += spi_ks8995.o
obj-$(CONFIG_AT803X_PHY) += at803x.o
-diff --git a/drivers/net/phy/lantiq.c b/drivers/net/phy/lantiq.c
-new file mode 100644
-index 0000000..f109bb9
--- /dev/null
+++ b/drivers/net/phy/lantiq.c
@@ -0,0 +1,231 @@
+MODULE_DESCRIPTION("Lantiq PHY drivers");
+MODULE_AUTHOR("Daniel Schwierzeck <daniel.schwierzeck@googlemail.com>");
+MODULE_LICENSE("GPL");
---
-1.7.10.4
-
create mode 100644 firmware/lantiq/COPYING
create mode 100644 firmware/lantiq/README
-diff --git a/firmware/Makefile b/firmware/Makefile
-index cbb09ce..171ebab 100644
--- a/firmware/Makefile
+++ b/firmware/Makefile
-@@ -134,6 +134,10 @@ fw-shipped-$(CONFIG_USB_SERIAL_KEYSPAN_PDA) += keyspan_pda/keyspan_pda.fw
+@@ -134,6 +134,10 @@ fw-shipped-$(CONFIG_USB_SERIAL_KEYSPAN_P
fw-shipped-$(CONFIG_USB_SERIAL_XIRCOM) += keyspan_pda/xircom_pgs.fw
fw-shipped-$(CONFIG_USB_VICAM) += vicam/firmware.fw
fw-shipped-$(CONFIG_VIDEO_CPIA2) += cpia2/stv0672_vp4.bin
fw-shipped-$(CONFIG_YAM) += yam/1200.bin yam/9600.bin
fw-shipped-all := $(fw-shipped-y) $(fw-shipped-m) $(fw-shipped-)
-diff --git a/firmware/lantiq/COPYING b/firmware/lantiq/COPYING
-new file mode 100644
-index 0000000..5ec70b2
--- /dev/null
+++ b/firmware/lantiq/COPYING
@@ -0,0 +1,286 @@
+POSSIBILITY OF SUCH DAMAGES.
+
+ END OF TERMS AND CONDITIONS
-diff --git a/firmware/lantiq/README b/firmware/lantiq/README
-new file mode 100644
-index 0000000..1b666d4
--- /dev/null
+++ b/firmware/lantiq/README
@@ -0,0 +1,45 @@
+# GPHY core on Lantiq XWAY VR9 v1.2
+lantiq/vr9_phy11g_a2x.bin
+lantiq/vr9_phy22f_a2x.bin
---
-1.7.10.4
-
create mode 100644 drivers/net/ethernet/lantiq_xrx200.c
create mode 100644 drivers/net/ethernet/lantiq_xrx200_sw.h
-Index: linux-3.14.18/drivers/net/ethernet/Kconfig
-===================================================================
---- linux-3.14.18.orig/drivers/net/ethernet/Kconfig 2014-09-06 01:34:59.000000000 +0200
-+++ linux-3.14.18/drivers/net/ethernet/Kconfig 2014-09-13 05:02:42.601066602 +0200
-@@ -84,7 +84,13 @@
+--- a/drivers/net/ethernet/Kconfig
++++ b/drivers/net/ethernet/Kconfig
+@@ -84,7 +84,13 @@ config LANTIQ_ETOP
tristate "Lantiq SoC ETOP driver"
depends on SOC_TYPE_XWAY
---help---
source "drivers/net/ethernet/marvell/Kconfig"
source "drivers/net/ethernet/mellanox/Kconfig"
-Index: linux-3.14.18/drivers/net/ethernet/Makefile
-===================================================================
---- linux-3.14.18.orig/drivers/net/ethernet/Makefile 2014-09-06 01:34:59.000000000 +0200
-+++ linux-3.14.18/drivers/net/ethernet/Makefile 2014-09-13 05:02:42.601066602 +0200
-@@ -38,6 +38,7 @@
+--- a/drivers/net/ethernet/Makefile
++++ b/drivers/net/ethernet/Makefile
+@@ -38,6 +38,7 @@ obj-$(CONFIG_IP1000) += icplus/
obj-$(CONFIG_JME) += jme.o
obj-$(CONFIG_KORINA) += korina.o
obj-$(CONFIG_LANTIQ_ETOP) += lantiq_etop.o
obj-$(CONFIG_NET_VENDOR_MARVELL) += marvell/
obj-$(CONFIG_NET_VENDOR_MELLANOX) += mellanox/
obj-$(CONFIG_NET_VENDOR_MICREL) += micrel/
-Index: linux-3.14.18/drivers/net/ethernet/lantiq_pce.h
-===================================================================
---- /dev/null 1970-01-01 00:00:00.000000000 +0000
-+++ linux-3.14.18/drivers/net/ethernet/lantiq_pce.h 2014-09-13 05:02:42.601066602 +0200
+--- /dev/null
++++ b/drivers/net/ethernet/lantiq_pce.h
@@ -0,0 +1,163 @@
+/*
+ * This program is free software; you can redistribute it and/or modify it
+ MC_ENTRY(0x0000, 0x0000, 39, OUT_NONE, 0, INSTR, FLAG_END, 0),
+ MC_ENTRY(0x0000, 0x0000, 39, OUT_NONE, 0, INSTR, FLAG_END, 0),
+};
-Index: linux-3.14.18/drivers/net/ethernet/lantiq_xrx200.c
-===================================================================
---- /dev/null 1970-01-01 00:00:00.000000000 +0000
-+++ linux-3.14.18/drivers/net/ethernet/lantiq_xrx200.c 2014-09-13 05:04:05.185068633 +0200
+--- /dev/null
++++ b/drivers/net/ethernet/lantiq_xrx200.c
@@ -0,0 +1,1796 @@
+/*
+ * This program is free software; you can redistribute it and/or modify it
+MODULE_AUTHOR("John Crispin <blogic@openwrt.org>");
+MODULE_DESCRIPTION("Lantiq SoC XRX200 ethernet");
+MODULE_LICENSE("GPL");
-Index: linux-3.14.18/drivers/net/ethernet/lantiq_xrx200_sw.h
-===================================================================
---- /dev/null 1970-01-01 00:00:00.000000000 +0000
-+++ linux-3.14.18/drivers/net/ethernet/lantiq_xrx200_sw.h 2014-09-13 05:02:42.605066602 +0200
+--- /dev/null
++++ b/drivers/net/ethernet/lantiq_xrx200_sw.h
@@ -0,0 +1,1328 @@
+/*
+ * This program is free software; you can redistribute it and/or modify it
include/linux/phy.h | 1 +
2 files changed, 7 insertions(+), 3 deletions(-)
-diff --git a/drivers/net/phy/phy.c b/drivers/net/phy/phy.c
-index 76d96b9..371f0b6 100644
--- a/drivers/net/phy/phy.c
+++ b/drivers/net/phy/phy.c
-@@ -715,7 +715,8 @@ void phy_state_machine(struct work_struct *work)
+@@ -764,7 +764,8 @@ void phy_state_machine(struct work_struc
/* If the link is down, give up on negotiation for now */
if (!phydev->link) {
phydev->state = PHY_NOLINK;
phydev->adjust_link(phydev->attached_dev);
break;
}
-@@ -781,7 +782,8 @@ void phy_state_machine(struct work_struct *work)
+@@ -830,7 +831,8 @@ void phy_state_machine(struct work_struc
netif_carrier_on(phydev->attached_dev);
} else {
phydev->state = PHY_NOLINK;
}
phydev->adjust_link(phydev->attached_dev);
-@@ -793,7 +795,8 @@ void phy_state_machine(struct work_struct *work)
+@@ -842,7 +844,8 @@ void phy_state_machine(struct work_struc
case PHY_HALTED:
if (phydev->link) {
phydev->link = 0;
phydev->adjust_link(phydev->attached_dev);
do_suspend = 1;
}
-diff --git a/include/linux/phy.h b/include/linux/phy.h
-index 565188c..91b93f7 100644
--- a/include/linux/phy.h
+++ b/include/linux/phy.h
@@ -308,6 +308,7 @@ struct phy_device {
enum phy_state state;
---
-1.7.10.4
-
include/linux/of_net.h | 1 +
2 files changed, 38 insertions(+)
-diff --git a/drivers/of/of_net.c b/drivers/of/of_net.c
-index a208a45..de93111 100644
--- a/drivers/of/of_net.c
+++ b/drivers/of/of_net.c
@@ -10,6 +10,7 @@
/**
* It maps 'enum phy_interface_t' found in include/linux/phy.h
-@@ -94,3 +95,39 @@ const void *of_get_mac_address(struct device_node *np)
+@@ -94,3 +95,39 @@ const void *of_get_mac_address(struct de
return NULL;
}
EXPORT_SYMBOL(of_get_mac_address);
+ return ret;
+}
+EXPORT_SYMBOL_GPL(of_get_mac_address_mtd);
-diff --git a/include/linux/of_net.h b/include/linux/of_net.h
-index 34597c8..cdfbc60 100644
--- a/include/linux/of_net.h
+++ b/include/linux/of_net.h
@@ -11,6 +11,7 @@
#else
static inline int of_get_phy_mode(struct device_node *np)
{
---
-1.7.10.4
-
drivers/net/ethernet/lantiq_etop.c | 555 +++++++++++++++++++++++++-----------
1 file changed, 389 insertions(+), 166 deletions(-)
-diff --git a/drivers/net/ethernet/lantiq_etop.c b/drivers/net/ethernet/lantiq_etop.c
-index fd4b6ae..1712382 100644
--- a/drivers/net/ethernet/lantiq_etop.c
+++ b/drivers/net/ethernet/lantiq_etop.c
@@ -11,7 +11,7 @@
-#define ETOP_MII_REVERSE 0xe
#define ETOP_PLEN_UNDER 0x40
-#define ETOP_CGEN 0x800
--
++#define ETOP_CFG_MII0 0x01
+
-/* use 2 static channels for TX/RX */
-#define LTQ_ETOP_TX_CHANNEL 1
-#define LTQ_ETOP_RX_CHANNEL 6
-#define IS_TX(x) (x == LTQ_ETOP_TX_CHANNEL)
-#define IS_RX(x) (x == LTQ_ETOP_RX_CHANNEL)
--
-+#define ETOP_CFG_MII0 0x01
-+
+#define ETOP_CFG_MASK 0xfff
+#define ETOP_CFG_FEN0 (1 << 8)
+#define ETOP_CFG_SEN0 (1 << 6)
+#define MDIO_XR9_REG_OFFSET 0
+#define MDIO_XR9_ADDR_OFFSET 5
+#define MDIO_XR9_WR_OFFSET 16
-+
+
+#define LTQ_DMA_ETOP ((of_machine_is_compatible("lantiq,ase")) ? \
+ (INT_NUM_IM3_IRL0) : (INT_NUM_IM2_IRL0))
+
if (!ch->skb[ch->dma.desc])
return -ENOMEM;
ch->dma.desc_base[ch->dma.desc].addr = dma_map_single(NULL,
-@@ -148,8 +213,11 @@ ltq_etop_hw_receive(struct ltq_etop_chan *ch)
+@@ -148,8 +213,11 @@ ltq_etop_hw_receive(struct ltq_etop_chan
spin_unlock_irqrestore(&priv->lock, flags);
skb_put(skb, len);
}
static int
-@@ -157,8 +225,10 @@ ltq_etop_poll_rx(struct napi_struct *napi, int budget)
+@@ -157,8 +225,10 @@ ltq_etop_poll_rx(struct napi_struct *nap
{
struct ltq_etop_chan *ch = container_of(napi,
struct ltq_etop_chan, napi);
while ((rx < budget) && !complete) {
struct ltq_dma_desc *desc = &ch->dma.desc_base[ch->dma.desc];
-@@ -172,7 +242,9 @@ ltq_etop_poll_rx(struct napi_struct *napi, int budget)
+@@ -172,7 +242,9 @@ ltq_etop_poll_rx(struct napi_struct *nap
}
if (complete || !rx) {
napi_complete(&ch->napi);
}
return rx;
}
-@@ -184,12 +256,14 @@ ltq_etop_poll_tx(struct napi_struct *napi, int budget)
+@@ -184,12 +256,14 @@ ltq_etop_poll_tx(struct napi_struct *nap
container_of(napi, struct ltq_etop_chan, napi);
struct ltq_etop_priv *priv = netdev_priv(ch->netdev);
struct netdev_queue *txq =
dev_kfree_skb_any(ch->skb[ch->tx_free]);
ch->skb[ch->tx_free] = NULL;
memset(&ch->dma.desc_base[ch->tx_free], 0,
-@@ -202,7 +276,9 @@ ltq_etop_poll_tx(struct napi_struct *napi, int budget)
+@@ -202,7 +276,9 @@ ltq_etop_poll_tx(struct napi_struct *nap
if (netif_tx_queue_stopped(txq))
netif_tx_start_queue(txq);
napi_complete(&ch->napi);
return IRQ_HANDLED;
}
-@@ -224,7 +301,7 @@ ltq_etop_free_channel(struct net_device *dev, struct ltq_etop_chan *ch)
+@@ -224,7 +301,7 @@ ltq_etop_free_channel(struct net_device
ltq_dma_free(&ch->dma);
if (ch->dma.irq)
free_irq(ch->dma.irq, priv);
struct ltq_etop_priv *priv = netdev_priv(dev);
- int i;
+ int mii_mode = priv->mii_mode;
-+
-+ clk_enable(priv->clk_ppe);
- ltq_pmu_enable(PMU_PPE);
++ clk_enable(priv->clk_ppe);
++
+ if (of_machine_is_compatible("lantiq,ar9")) {
+ ltq_etop_gbit_init(dev);
+ /* force the etops link to the gbit to MII */
}
static void
-@@ -309,7 +454,10 @@ ltq_etop_get_settings(struct net_device *dev, struct ethtool_cmd *cmd)
+@@ -309,7 +454,10 @@ ltq_etop_get_settings(struct net_device
{
struct ltq_etop_priv *priv = netdev_priv(dev);
}
static int
-@@ -317,7 +465,10 @@ ltq_etop_set_settings(struct net_device *dev, struct ethtool_cmd *cmd)
+@@ -317,7 +465,10 @@ ltq_etop_set_settings(struct net_device
{
struct ltq_etop_priv *priv = netdev_priv(dev);
}
static int
-@@ -325,7 +476,10 @@ ltq_etop_nway_reset(struct net_device *dev)
+@@ -325,7 +476,10 @@ ltq_etop_nway_reset(struct net_device *d
{
struct ltq_etop_priv *priv = netdev_priv(dev);
}
static const struct ethtool_ops ltq_etop_ethtool_ops = {
-@@ -336,6 +490,39 @@ static const struct ethtool_ops ltq_etop_ethtool_ops = {
+@@ -336,6 +490,39 @@ static const struct ethtool_ops ltq_etop
};
static int
ltq_etop_mdio_wr(struct mii_bus *bus, int phy_addr, int phy_reg, u16 phy_data)
{
u32 val = MDIO_REQUEST |
-@@ -343,9 +530,9 @@ ltq_etop_mdio_wr(struct mii_bus *bus, int phy_addr, int phy_reg, u16 phy_data)
+@@ -343,9 +530,9 @@ ltq_etop_mdio_wr(struct mii_bus *bus, in
((phy_reg & MDIO_REG_MASK) << MDIO_REG_OFFSET) |
phy_data;
return 0;
}
-@@ -356,12 +543,12 @@ ltq_etop_mdio_rd(struct mii_bus *bus, int phy_addr, int phy_reg)
+@@ -356,12 +543,12 @@ ltq_etop_mdio_rd(struct mii_bus *bus, in
((phy_addr & MDIO_ADDR_MASK) << MDIO_ADDR_OFFSET) |
((phy_reg & MDIO_REG_MASK) << MDIO_REG_OFFSET);
return val;
}
-@@ -376,14 +563,18 @@ ltq_etop_mdio_probe(struct net_device *dev)
+@@ -376,14 +563,18 @@ ltq_etop_mdio_probe(struct net_device *d
{
struct ltq_etop_priv *priv = netdev_priv(dev);
struct phy_device *phydev = NULL;
- int phy_addr;
--
-- for (phy_addr = 0; phy_addr < PHY_MAX_ADDR; phy_addr++) {
-- if (priv->mii_bus->phy_map[phy_addr]) {
-- phydev = priv->mii_bus->phy_map[phy_addr];
-- break;
-- }
-- }
+ u32 phy_supported = (SUPPORTED_10baseT_Half
+ | SUPPORTED_10baseT_Full
+ | SUPPORTED_100baseT_Half
+ | SUPPORTED_Autoneg
+ | SUPPORTED_MII
+ | SUPPORTED_TP);
-+
+
+- for (phy_addr = 0; phy_addr < PHY_MAX_ADDR; phy_addr++) {
+- if (priv->mii_bus->phy_map[phy_addr]) {
+- phydev = priv->mii_bus->phy_map[phy_addr];
+- break;
+- }
+- }
+ if (of_machine_is_compatible("lantiq,ase"))
+ phydev = priv->mii_bus->phy_map[8];
+ else
if (!phydev) {
netdev_err(dev, "no PHY found\n");
-@@ -391,21 +582,18 @@ ltq_etop_mdio_probe(struct net_device *dev)
+@@ -391,21 +582,18 @@ ltq_etop_mdio_probe(struct net_device *d
}
phydev = phy_connect(dev, dev_name(&phydev->dev),
phydev->advertising = phydev->supported;
priv->phydev = phydev;
pr_info("%s: attached PHY [%s] (phy_addr=%s, irq=%d)\n",
-@@ -430,8 +618,13 @@ ltq_etop_mdio_init(struct net_device *dev)
+@@ -430,8 +618,13 @@ ltq_etop_mdio_init(struct net_device *de
}
priv->mii_bus->priv = dev;
- phy_stop(priv->phydev);
- for (i = 0; i < MAX_DMA_CHAN; i++) {
- struct ltq_etop_chan *ch = &priv->ch[i];
+-
+- if (!IS_RX(i) && !IS_TX(i))
+- continue;
+- napi_disable(&ch->napi);
+- ltq_dma_close(&ch->dma);
+- }
+ if (priv->phydev)
+ phy_stop(priv->phydev);
+ napi_disable(&priv->txch.napi);
+ ltq_dma_close(&priv->txch.dma);
+ ltq_dma_close(&priv->rxch.dma);
+ spin_unlock_irqrestore(&priv->lock, flags);
-
-- if (!IS_RX(i) && !IS_TX(i))
-- continue;
-- napi_disable(&ch->napi);
-- ltq_dma_close(&ch->dma);
-- }
++
return 0;
}
-@@ -520,16 +716,16 @@ ltq_etop_tx(struct sk_buff *skb, struct net_device *dev)
+@@ -520,16 +716,16 @@ ltq_etop_tx(struct sk_buff *skb, struct
int queue = skb_get_queue_mapping(skb);
struct netdev_queue *txq = netdev_get_tx_queue(dev, queue);
struct ltq_etop_priv *priv = netdev_priv(dev);
netdev_err(dev, "tx ring full\n");
netif_tx_stop_queue(txq);
return NETDEV_TX_BUSY;
-@@ -537,7 +733,7 @@ ltq_etop_tx(struct sk_buff *skb, struct net_device *dev)
+@@ -537,7 +733,7 @@ ltq_etop_tx(struct sk_buff *skb, struct
/* dma needs to start on a 16 byte aligned address */
byte_offset = CPHYSADDR(skb->data) % 16;
dev->trans_start = jiffies;
-@@ -547,11 +743,11 @@ ltq_etop_tx(struct sk_buff *skb, struct net_device *dev)
+@@ -547,11 +743,11 @@ ltq_etop_tx(struct sk_buff *skb, struct
wmb();
desc->ctl = LTQ_DMA_OWN | LTQ_DMA_SOP | LTQ_DMA_EOP |
LTQ_DMA_TX_OFFSET(byte_offset) | (len & LTQ_DMA_SIZE_MASK);
netif_tx_stop_queue(txq);
return NETDEV_TX_OK;
-@@ -566,8 +762,10 @@ ltq_etop_change_mtu(struct net_device *dev, int new_mtu)
+@@ -566,8 +762,10 @@ ltq_etop_change_mtu(struct net_device *d
struct ltq_etop_priv *priv = netdev_priv(dev);
unsigned long flags;
return 0;
err_netdev:
-@@ -678,6 +875,9 @@ ltq_etop_tx_timeout(struct net_device *dev)
+@@ -678,6 +875,9 @@ ltq_etop_tx_timeout(struct net_device *d
err = ltq_etop_hw_init(dev);
if (err)
goto err_hw;
dev->trans_start = jiffies;
netif_wake_queue(dev);
return;
-@@ -701,14 +901,18 @@ static const struct net_device_ops ltq_eth_netdev_ops = {
+@@ -701,14 +901,18 @@ static const struct net_device_ops ltq_e
.ndo_tx_timeout = ltq_etop_tx_timeout,
};
res = platform_get_resource(pdev, IORESOURCE_MEM, 0);
if (!res) {
-@@ -734,30 +938,58 @@ ltq_etop_probe(struct platform_device *pdev)
+@@ -734,30 +938,58 @@ ltq_etop_probe(struct platform_device *p
goto err_out;
}
err = register_netdev(dev);
if (err)
-@@ -786,32 +1018,23 @@ ltq_etop_remove(struct platform_device *pdev)
+@@ -786,32 +1018,23 @@ ltq_etop_remove(struct platform_device *
return 0;
}
MODULE_AUTHOR("John Crispin <blogic@openwrt.org>");
MODULE_DESCRIPTION("Lantiq SoC ETOP");
---
-1.7.10.4
-
3 files changed, 354 insertions(+)
create mode 100644 drivers/gpio/gpio-falcon.c
-diff --git a/drivers/gpio/Kconfig b/drivers/gpio/Kconfig
-index 903f24d..670c064 100644
--- a/drivers/gpio/Kconfig
+++ b/drivers/gpio/Kconfig
@@ -145,6 +145,11 @@ config GPIO_EP93XX
config GPIO_MM_LANTIQ
bool "Lantiq Memory mapped GPIOs"
depends on LANTIQ && SOC_XWAY
-diff --git a/drivers/gpio/Makefile b/drivers/gpio/Makefile
-index 5d50179..c92db39 100644
--- a/drivers/gpio/Makefile
+++ b/drivers/gpio/Makefile
-@@ -26,6 +26,7 @@ obj-$(CONFIG_GPIO_DAVINCI) += gpio-davinci.o
+@@ -26,6 +26,7 @@ obj-$(CONFIG_GPIO_DAVINCI) += gpio-davin
obj-$(CONFIG_GPIO_EM) += gpio-em.o
obj-$(CONFIG_GPIO_EP93XX) += gpio-ep93xx.o
obj-$(CONFIG_GPIO_F7188X) += gpio-f7188x.o
obj-$(CONFIG_GPIO_GE_FPGA) += gpio-ge.o
obj-$(CONFIG_GPIO_GRGPIO) += gpio-grgpio.o
obj-$(CONFIG_GPIO_ICH) += gpio-ich.o
-diff --git a/drivers/gpio/gpio-falcon.c b/drivers/gpio/gpio-falcon.c
-new file mode 100644
-index 0000000..ae3bdfb
--- /dev/null
+++ b/drivers/gpio/gpio-falcon.c
@@ -0,0 +1,348 @@
+}
+
+subsys_initcall(falcon_gpio_init);
---
-1.7.10.4
-
include/linux/gpio/consumer.h | 8 +++++
4 files changed, 90 insertions(+), 2 deletions(-)
-diff --git a/drivers/gpio/gpiolib-of.c b/drivers/gpio/gpiolib-of.c
-index e0a98f5..f16f271 100644
--- a/drivers/gpio/gpiolib-of.c
+++ b/drivers/gpio/gpiolib-of.c
@@ -21,6 +21,8 @@
struct gpio_desc;
-@@ -296,3 +298,69 @@ void of_gpiochip_remove(struct gpio_chip *chip)
+@@ -296,3 +298,69 @@ void of_gpiochip_remove(struct gpio_chip
if (chip->of_node)
of_node_put(chip->of_node);
}
+ return platform_driver_probe(&gpio_export_driver, of_gpio_export_probe);
+}
+device_initcall(of_gpio_export_init);
-diff --git a/drivers/gpio/gpiolib.c b/drivers/gpio/gpiolib.c
-index 50c4922..aece9f1 100644
--- a/drivers/gpio/gpiolib.c
+++ b/drivers/gpio/gpiolib.c
@@ -803,7 +803,7 @@ static struct class gpio_class = {
{
unsigned long flags;
int status;
-@@ -843,7 +843,8 @@ int gpiod_export(struct gpio_desc *desc, bool direction_may_change)
+@@ -843,7 +843,8 @@ int gpiod_export(struct gpio_desc *desc,
offset = gpio_chip_hwgpio(desc);
if (desc->chip->names && desc->chip->names[offset])
ioname = desc->chip->names[offset];
EXPORT_SYMBOL_GPL(gpiod_export);
static int match_export(struct device *dev, const void *data)
-diff --git a/include/asm-generic/gpio.h b/include/asm-generic/gpio.h
-index a5f56a0..70a32ee 100644
--- a/include/asm-generic/gpio.h
+++ b/include/asm-generic/gpio.h
-@@ -126,6 +126,11 @@ static inline int gpio_export(unsigned gpio, bool direction_may_change)
+@@ -126,6 +126,11 @@ static inline int gpio_export(unsigned g
return gpiod_export(gpio_to_desc(gpio), direction_may_change);
}
static inline int gpio_export_link(struct device *dev, const char *name,
unsigned gpio)
{
-diff --git a/include/linux/gpio/consumer.h b/include/linux/gpio/consumer.h
-index 7a8144f..085c31c 100644
--- a/include/linux/gpio/consumer.h
+++ b/include/linux/gpio/consumer.h
-@@ -219,6 +219,7 @@ static inline struct gpio_chip *gpiod_to_chip(const struct gpio_desc *desc)
+@@ -219,6 +219,7 @@ static inline struct gpio_chip *gpiod_to
#if IS_ENABLED(CONFIG_GPIOLIB) && IS_ENABLED(CONFIG_GPIO_SYSFS)
int gpiod_export(struct gpio_desc *desc, bool direction_may_change);
int gpiod_export_link(struct device *dev, const char *name,
struct gpio_desc *desc);
-@@ -227,6 +228,13 @@ void gpiod_unexport(struct gpio_desc *desc);
+@@ -227,6 +228,13 @@ void gpiod_unexport(struct gpio_desc *de
#else /* CONFIG_GPIOLIB && CONFIG_GPIO_SYSFS */
static inline int gpiod_export(struct gpio_desc *desc,
bool direction_may_change)
{
---
-1.7.10.4
-
create mode 100644 drivers/i2c/busses/i2c-lantiq.c
create mode 100644 drivers/i2c/busses/i2c-lantiq.h
-diff --git a/drivers/i2c/busses/Kconfig b/drivers/i2c/busses/Kconfig
-index de17c55..3e003c4 100644
--- a/drivers/i2c/busses/Kconfig
+++ b/drivers/i2c/busses/Kconfig
-@@ -514,6 +514,16 @@ config I2C_KEMPLD
+@@ -515,6 +515,16 @@ config I2C_KEMPLD
This driver can also be built as a module. If so, the module
will be called i2c-kempld.
config I2C_MPC
tristate "MPC107/824x/85xx/512x/52xx/83xx/86xx"
depends on PPC
-diff --git a/drivers/i2c/busses/Makefile b/drivers/i2c/busses/Makefile
-index a08931f..4417097 100644
--- a/drivers/i2c/busses/Makefile
+++ b/drivers/i2c/busses/Makefile
-@@ -49,6 +49,7 @@ obj-$(CONFIG_I2C_IBM_IIC) += i2c-ibm_iic.o
+@@ -49,6 +49,7 @@ obj-$(CONFIG_I2C_IBM_IIC) += i2c-ibm_iic
obj-$(CONFIG_I2C_IMX) += i2c-imx.o
obj-$(CONFIG_I2C_IOP3XX) += i2c-iop3xx.o
obj-$(CONFIG_I2C_KEMPLD) += i2c-kempld.o
obj-$(CONFIG_I2C_MPC) += i2c-mpc.o
obj-$(CONFIG_I2C_MV64XXX) += i2c-mv64xxx.o
obj-$(CONFIG_I2C_MXS) += i2c-mxs.o
-diff --git a/drivers/i2c/busses/i2c-lantiq.c b/drivers/i2c/busses/i2c-lantiq.c
-new file mode 100644
-index 0000000..9a5f58b
--- /dev/null
+++ b/drivers/i2c/busses/i2c-lantiq.c
@@ -0,0 +1,747 @@
+MODULE_ALIAS("platform:" DRV_NAME);
+MODULE_LICENSE("GPL");
+MODULE_VERSION(DRV_VERSION);
-diff --git a/drivers/i2c/busses/i2c-lantiq.h b/drivers/i2c/busses/i2c-lantiq.h
-new file mode 100644
-index 0000000..7a86b89
--- /dev/null
+++ b/drivers/i2c/busses/i2c-lantiq.h
@@ -0,0 +1,234 @@
+
+
+#endif /* I2C_LANTIQ_H */
---
-1.7.10.4
-
drivers/usb/core/hub.c | 2 +-
2 files changed, 2 insertions(+), 1 deletion(-)
-diff --git a/arch/mips/lantiq/Kconfig b/arch/mips/lantiq/Kconfig
-index 1621b1d..4c9a241 100644
--- a/arch/mips/lantiq/Kconfig
+++ b/arch/mips/lantiq/Kconfig
@@ -3,6 +3,7 @@ if LANTIQ
default n
choice
-diff --git a/drivers/usb/core/hub.c b/drivers/usb/core/hub.c
-index 64ea219..30f4bdf 100644
--- a/drivers/usb/core/hub.c
+++ b/drivers/usb/core/hub.c
-@@ -4077,7 +4077,7 @@ hub_port_init (struct usb_hub *hub, struct usb_device *udev, int port1,
+@@ -4156,7 +4156,7 @@ hub_port_init (struct usb_hub *hub, stru
udev->ttport = hdev->ttport;
} else if (udev->speed != USB_SPEED_HIGH
&& hdev->speed == USB_SPEED_HIGH) {
dev_err(&udev->dev, "parent hub has no TT\n");
retval = -EINVAL;
goto fail;
---
-1.7.10.4
-
3 files changed, 986 insertions(+)
create mode 100644 drivers/spi/spi-xway.c
-diff --git a/drivers/spi/Kconfig b/drivers/spi/Kconfig
-index 581ee2a..b2cd93c 100644
--- a/drivers/spi/Kconfig
+++ b/drivers/spi/Kconfig
-@@ -527,6 +527,14 @@ config SPI_NUC900
+@@ -536,6 +536,14 @@ config SPI_NUC900
help
SPI driver for Nuvoton NUC900 series ARM SoCs
#
# Add new SPI master controllers in alphabetical order above this line
#
-diff --git a/drivers/spi/Makefile b/drivers/spi/Makefile
-index 95af48d..82d3799 100644
--- a/drivers/spi/Makefile
+++ b/drivers/spi/Makefile
-@@ -79,3 +79,4 @@ obj-$(CONFIG_SPI_TOPCLIFF_PCH) += spi-topcliff-pch.o
+@@ -80,3 +80,4 @@ obj-$(CONFIG_SPI_TOPCLIFF_PCH) += spi-t
obj-$(CONFIG_SPI_TXX9) += spi-txx9.o
obj-$(CONFIG_SPI_XCOMM) += spi-xcomm.o
obj-$(CONFIG_SPI_XILINX) += spi-xilinx.o
+obj-$(CONFIG_SPI_XWAY) += spi-xway.o
-diff --git a/drivers/spi/spi-xway.c b/drivers/spi/spi-xway.c
-new file mode 100644
-index 0000000..61532e3
--- /dev/null
+++ b/drivers/spi/spi-xway.c
@@ -0,0 +1,977 @@
+MODULE_AUTHOR("Daniel Schwierzeck <daniel.schwierzeck@googlemail.com>");
+MODULE_LICENSE("GPL");
+MODULE_ALIAS("platform:spi-xway");
---
-1.7.10.4
-
include/linux/reset.h | 43 ++++++++++++++++++++++++++++++++++++++
2 files changed, 59 insertions(+)
-diff --git a/include/linux/reset-controller.h b/include/linux/reset-controller.h
-index 41a4695..f38f530 100644
--- a/include/linux/reset-controller.h
+++ b/include/linux/reset-controller.h
@@ -46,7 +46,23 @@ struct reset_controller_dev {
+#endif
+
#endif
-diff --git a/include/linux/reset.h b/include/linux/reset.h
-index 6082247..1b36c9e 100644
--- a/include/linux/reset.h
+++ b/include/linux/reset.h
@@ -1,9 +1,13 @@
int reset_control_reset(struct reset_control *rstc);
int reset_control_assert(struct reset_control *rstc);
int reset_control_deassert(struct reset_control *rstc);
-@@ -14,4 +18,43 @@ struct reset_control *devm_reset_control_get(struct device *dev, const char *id)
+@@ -14,4 +18,43 @@ struct reset_control *devm_reset_control
int device_reset(struct device *dev);
+#endif
+
#endif
---
-1.7.10.4
-
create mode 100644 arch/mips/lantiq/xway/pci-ath-fixup.c
create mode 100644 arch/mips/lantiq/xway/rt_eep.c
-diff --git a/arch/mips/include/asm/mach-lantiq/pci-ath-fixup.h b/arch/mips/include/asm/mach-lantiq/pci-ath-fixup.h
-new file mode 100644
-index 0000000..095d261
--- /dev/null
+++ b/arch/mips/include/asm/mach-lantiq/pci-ath-fixup.h
@@ -0,0 +1,6 @@
+void ltq_pci_ath_fixup(unsigned slot, u16 *cal_data) __init;
+
+#endif /* _PCI_ATH_FIXUP */
-diff --git a/arch/mips/include/asm/mach-lantiq/xway/lantiq_soc.h b/arch/mips/include/asm/mach-lantiq/xway/lantiq_soc.h
-index 133336b..779715c 100644
--- a/arch/mips/include/asm/mach-lantiq/xway/lantiq_soc.h
+++ b/arch/mips/include/asm/mach-lantiq/xway/lantiq_soc.h
-@@ -90,5 +90,8 @@ int xrx200_gphy_boot(struct device *dev, unsigned int id, dma_addr_t dev_addr);
+@@ -90,5 +90,8 @@ int xrx200_gphy_boot(struct device *dev,
extern void ltq_pmu_enable(unsigned int module);
extern void ltq_pmu_disable(unsigned int module);
+
#endif /* CONFIG_SOC_TYPE_XWAY */
#endif /* _LTQ_XWAY_H__ */
-diff --git a/arch/mips/lantiq/xway/Makefile b/arch/mips/lantiq/xway/Makefile
-index 2dd442c..de876e1 100644
--- a/arch/mips/lantiq/xway/Makefile
+++ b/arch/mips/lantiq/xway/Makefile
-@@ -2,4 +2,7 @@ obj-y := prom.o sysctrl.o clk.o reset.o dma.o timer.o dcdc.o
+@@ -2,4 +2,7 @@ obj-y := prom.o sysctrl.o clk.o reset.o
obj-y += vmmc.o tffs.o
+obj-$(CONFIG_PCI) += ath_eep.o rt_eep.o pci-ath-fixup.o
+
obj-$(CONFIG_XRX200_PHY_FW) += xrx200_phy_fw.o
-diff --git a/arch/mips/lantiq/xway/ath_eep.c b/arch/mips/lantiq/xway/ath_eep.c
-new file mode 100644
-index 0000000..aff42ac
--- /dev/null
+++ b/arch/mips/lantiq/xway/ath_eep.c
@@ -0,0 +1,282 @@
+ return platform_driver_probe(&ath5k_eeprom_driver, of_ath5k_eeprom_probe);
+}
+device_initcall(of_ath5k_eeprom_init);
-diff --git a/arch/mips/lantiq/xway/eth_mac.c b/arch/mips/lantiq/xway/eth_mac.c
-new file mode 100644
-index 0000000..d288a0e
--- /dev/null
+++ b/arch/mips/lantiq/xway/eth_mac.c
@@ -0,0 +1,76 @@
+ return platform_driver_probe(ð_mac_driver, of_eth_mac_probe);
+}
+device_initcall(of_eth_mac_init);
-diff --git a/arch/mips/lantiq/xway/pci-ath-fixup.c b/arch/mips/lantiq/xway/pci-ath-fixup.c
-new file mode 100644
-index 0000000..c87ffb2
--- /dev/null
+++ b/arch/mips/lantiq/xway/pci-ath-fixup.c
@@ -0,0 +1,109 @@
+ ath_fixups[ath_num_fixups].cal_data = cal_data;
+ ath_num_fixups++;
+}
-diff --git a/arch/mips/lantiq/xway/rt_eep.c b/arch/mips/lantiq/xway/rt_eep.c
-new file mode 100644
-index 0000000..00f2d4c
--- /dev/null
+++ b/arch/mips/lantiq/xway/rt_eep.c
@@ -0,0 +1,60 @@
+ return platform_driver_probe(&ralink_eeprom_driver, of_ralink_eeprom_probe);
+}
+device_initcall(of_ralink_eeprom_init);
---
-1.7.10.4
-
arch/mips/kernel/head.S | 3 +++
1 file changed, 3 insertions(+)
-diff --git a/arch/mips/kernel/head.S b/arch/mips/kernel/head.S
-index 7b6a5b3..78518b8 100644
--- a/arch/mips/kernel/head.S
+++ b/arch/mips/kernel/head.S
-@@ -101,6 +101,9 @@ FEXPORT(__kernel_entry)
- j kernel_entry
- #endif
+@@ -107,6 +107,9 @@ EXPORT(__image_cmdline)
+ .fill 0x400
+ #endif /* CONFIG_IMAGE_CMDLINE_HACK */
+ .ascii "OWRTDTB:"
+ EXPORT(__image_dtb)
__REF
NESTED(kernel_entry, 16, sp) # kernel entry point
---
-1.7.10.4
-
arch/mips/lantiq/irq.c | 48 ++++++++++++++++++++++++------------------------
1 file changed, 24 insertions(+), 24 deletions(-)
-diff --git a/arch/mips/lantiq/irq.c b/arch/mips/lantiq/irq.c
-index 6b94cc7..3bbedf6 100644
--- a/arch/mips/lantiq/irq.c
+++ b/arch/mips/lantiq/irq.c
-@@ -380,30 +380,6 @@ int __init icu_of_init(struct device_node *node, struct device_node *parent)
+@@ -380,30 +380,6 @@ int __init icu_of_init(struct device_nod
panic("Failed to remap icu memory");
}
/* turn off all irqs by default */
for (i = 0; i < MAX_IM; i++) {
/* make sure all irqs are turned off by default */
-@@ -460,6 +436,30 @@ int __init icu_of_init(struct device_node *node, struct device_node *parent)
+@@ -460,6 +436,30 @@ int __init icu_of_init(struct device_nod
if (MIPS_CPU_TIMER_IRQ != 7)
irq_create_mapping(ltq_domain, MIPS_CPU_TIMER_IRQ);
return 0;
}
---
-1.7.10.4
-
-Index: linux-3.14.18/arch/mips/lantiq/xway/Makefile
-===================================================================
---- linux-3.14.18.orig/arch/mips/lantiq/xway/Makefile 2014-09-11 16:31:10.000000000 +0200
-+++ linux-3.14.18/arch/mips/lantiq/xway/Makefile 2014-09-11 16:32:52.188968735 +0200
+--- a/arch/mips/lantiq/xway/Makefile
++++ b/arch/mips/lantiq/xway/Makefile
@@ -1,6 +1,6 @@
obj-y := prom.o sysctrl.o clk.o reset.o dma.o timer.o dcdc.o
obj-y += eth_mac.o
obj-$(CONFIG_PCI) += ath_eep.o rt_eep.o pci-ath-fixup.o
-Index: linux-3.14.18/arch/mips/lantiq/xway/mtd_split.c
-===================================================================
---- /dev/null 1970-01-01 00:00:00.000000000 +0000
-+++ linux-3.14.18/arch/mips/lantiq/xway/mtd_split.c 2014-09-11 16:31:51.712967248 +0200
+--- /dev/null
++++ b/arch/mips/lantiq/xway/mtd_split.c
@@ -0,0 +1,129 @@
+#include <linux/magic.h>
+#include <linux/root_dev.h>
+ split_eva_kernel(master, name, offset, size);
+ split_brnimage_kernel(master, name, offset, size);
+}
-Index: linux-3.14.18/include/linux/mtd/partitions.h
-===================================================================
---- linux-3.14.18.orig/include/linux/mtd/partitions.h 2014-09-11 16:31:10.752966240 +0200
-+++ linux-3.14.18/include/linux/mtd/partitions.h 2014-09-11 16:44:49.432986380 +0200
-@@ -89,12 +89,17 @@
+--- a/include/linux/mtd/partitions.h
++++ b/include/linux/mtd/partitions.h
+@@ -89,12 +89,17 @@ extern void deregister_mtd_parser(struct
int mtd_is_partition(const struct mtd_info *mtd);
int mtd_add_partition(struct mtd_info *master, const char *name,
long long offset, long long length);
int parse_mtd_partitions_by_type(struct mtd_info *master,
enum mtd_parser_type type,
-Index: linux-3.14.18/drivers/mtd/mtdpart.c
-===================================================================
---- linux-3.14.18.orig/drivers/mtd/mtdpart.c 2014-09-11 16:31:10.752966240 +0200
-+++ linux-3.14.18/drivers/mtd/mtdpart.c 2014-09-11 16:33:11.732969216 +0200
-@@ -617,7 +617,7 @@
+--- a/drivers/mtd/mtdpart.c
++++ b/drivers/mtd/mtdpart.c
+@@ -617,7 +617,7 @@ out_register:
}
__mtd_add_partition(struct mtd_info *master, const char *name,
long long offset, long long length, bool dup_check)
{
-@@ -738,7 +738,7 @@
+@@ -738,7 +738,7 @@ run_parsers_by_type(struct mtd_part *sla
return nr_parts;
}
mtd_pad_erasesize(struct mtd_info *mtd, int offset, int len)
{
unsigned long mask = mtd->erasesize - 1;
-@@ -807,7 +807,6 @@
+@@ -808,7 +808,6 @@ static void split_uimage(struct mtd_info
return;
len = be32_to_cpu(hdr.size) + 0x40;
---- linux-3.14.18.orig/drivers/pinctrl/pinctrl-xway.c.orig 2014-09-27 14:55:20.000000000 +0200
-+++ linux-3.14.18/drivers/pinctrl/pinctrl-xway.c 2014-10-05 21:15:02.000000000 +0200
-@@ -152,10 +152,10 @@
+--- a/drivers/pinctrl/pinctrl-xway.c
++++ b/drivers/pinctrl/pinctrl-xway.c
+@@ -152,10 +152,10 @@ static const struct ltq_mfp_pin xway_mfp
MFP_XWAY(GPIO41, GPIO, NONE, NONE, NONE),
MFP_XWAY(GPIO42, GPIO, MDIO, NONE, NONE),
MFP_XWAY(GPIO43, GPIO, MDIO, NONE, NONE),
---- linux-3.14.18.orig/arch/mips/pci/ifxmips_pcie.c 2014-09-27 14:55:19.000000000 +0200
-+++ linux-3.14.18/arch/mips/pci/ifxmips_pcie.c 2014-10-09 13:45:12.000000000 +0200
+--- a/arch/mips/pci/ifxmips_pcie.c
++++ b/arch/mips/pci/ifxmips_pcie.c
@@ -18,6 +18,8 @@
#include <linux/pci_regs.h>
#include <linux/module.h>
#include "ifxmips_pcie.h"
#include "ifxmips_pcie_reg.h"
-@@ -1048,7 +1050,7 @@
+@@ -1048,7 +1050,7 @@ pcie_rc_initialize(int pcie_port)
extern int (*ltq_pci_plat_arch_init)(struct pci_dev *dev);
extern int (*ltq_pci_map_irq)(const struct pci_dev *dev, u8 slot, u8 pin);
{
void __iomem *io_map_base;
int pcie_port;
-@@ -1090,6 +1092,30 @@
+@@ -1090,6 +1092,30 @@ static int __init ifx_pcie_bios_init(voi
return 0;
}
---- "a/drivers/mtd/maps/lantiq-flash.c"
-+++ "b/drivers/mtd/maps/lantiq-flash.c"
+--- a/drivers/mtd/maps/lantiq-flash.c
++++ b/drivers/mtd/maps/lantiq-flash.c
@@ -20,6 +20,7 @@
#include <linux/mtd/cfi.h>
#include <linux/platform_device.h>
#include <linux/of.h>
#include <lantiq_soc.h>
-@@ -39,10 +40,12 @@
+@@ -39,10 +40,12 @@ enum {
LTQ_NOR_NORMAL
};
};
static const char ltq_map_name[] = "ltq_nor";
-@@ -110,12 +113,39 @@
+@@ -110,12 +113,39 @@ ltq_copy_to(struct map_info *map, unsign
}
static int
static const char *rom_probe_types[] = {
"cfi_probe", "jedec_probe", NULL
-@@ -134,79 +164,88 @@
+@@ -134,79 +164,88 @@ ltq_mtd_probe(struct platform_device *pd
platform_set_drvdata(pdev, ltq_mtd);
int of_get_nand_bus_width(struct device_node *np);
bool of_get_nand_on_flash_bbt(struct device_node *np);
-@@ -22,6 +24,16 @@ static inline int of_get_nand_ecc_mode(s
- {
+@@ -23,6 +25,16 @@ static inline int of_get_nand_ecc_mode(s
return -ENOSYS;
}
-+
+
+static inline int of_get_nand_ecc_step_size(struct device_node *np)
+{
+ return -ENOSYS;
+{
+ return -ENOSYS;
+}
-
++
static inline int of_get_nand_bus_width(struct device_node *np)
{
+ return -ENOSYS;
u16 regs[MII_REGS_NUM];
struct phy_device *phydev;
struct fixed_phy_status status;
-@@ -104,8 +104,8 @@ static int fixed_phy_update_regs(struct
+@@ -104,8 +104,8 @@ static int fixed_phy_update_regs(struct
if (fp->status.asym_pause)
lpa |= LPA_PAUSE_ASYM;
fp->regs[MII_BMSR] = bmsr;
fp->regs[MII_BMCR] = bmcr;
-@@ -115,7 +115,7 @@ static int fixed_phy_update_regs(struct
+@@ -115,7 +115,7 @@ static int fixed_phy_update_regs(struct
return 0;
}
struct fixed_phy_status *status)
{
int ret;
-@@ -184,9 +184,9 @@ int fixed_phy_add(unsigned int irq, int
+@@ -184,9 +184,9 @@ int fixed_phy_add(unsigned int irq, int
memset(fp->regs, 0xFF, sizeof(fp->regs[0]) * MII_REGS_NUM);
#include <linux/of.h>
#include <linux/of_irq.h>
#include <linux/of_mdio.h>
-@@ -280,3 +281,69 @@ struct phy_device *of_phy_attach(struct
+@@ -280,3 +281,69 @@ struct phy_device *of_phy_attach(struct
return phy_attach_direct(dev, phy, flags, iface) ? NULL : phy;
}
EXPORT_SYMBOL(of_phy_attach);
--- a/arch/mips/cavium-octeon/executive/cvmx-helper.c
+++ b/arch/mips/cavium-octeon/executive/cvmx-helper.c
-@@ -104,6 +104,158 @@ int cvmx_helper_ports_on_interface(int i
- }
+@@ -106,6 +106,158 @@ int cvmx_helper_ports_on_interface(int i
+ EXPORT_SYMBOL_GPL(cvmx_helper_ports_on_interface);
/**
+ * @INTERNAL
* Get the operating mode of an interface. Depending on the Octeon
* chip and configuration, this function returns an enumeration
* of the type of packet I/O supported by an interface.
-@@ -116,6 +268,20 @@ int cvmx_helper_ports_on_interface(int i
+@@ -118,6 +270,20 @@ EXPORT_SYMBOL_GPL(cvmx_helper_ports_on_i
cvmx_helper_interface_mode_t cvmx_helper_interface_get_mode(int interface)
{
union cvmx_gmxx_inf_mode mode;
-Index: linux-3.14.18/arch/arm/include/asm/glue-cache.h
-===================================================================
---- linux-3.14.18.orig/arch/arm/include/asm/glue-cache.h
-+++ linux-3.14.18/arch/arm/include/asm/glue-cache.h
+--- a/arch/arm/include/asm/glue-cache.h
++++ b/arch/arm/include/asm/glue-cache.h
@@ -156,11 +156,19 @@ extern inline void nop_dma_unmap_area(co
#define __cpuc_flush_user_range __glue(_CACHE,_flush_user_cache_range)
#define __cpuc_coherent_kern_range __glue(_CACHE,_coherent_kern_range)
#endif
#endif
-Index: linux-3.14.18/arch/arm/mm/Kconfig
-===================================================================
---- linux-3.14.18.orig/arch/arm/mm/Kconfig
-+++ linux-3.14.18/arch/arm/mm/Kconfig
-@@ -843,6 +843,17 @@ config DMA_CACHE_RWFO
+--- a/arch/arm/mm/Kconfig
++++ b/arch/arm/mm/Kconfig
+@@ -844,6 +844,17 @@ config DMA_CACHE_RWFO
in hardware, other workarounds are needed (e.g. cache
maintenance broadcasting in software via FIQ).
config OUTER_CACHE
bool
-Index: linux-3.14.18/arch/arm/mm/flush.c
-===================================================================
---- linux-3.14.18.orig/arch/arm/mm/flush.c
-+++ linux-3.14.18/arch/arm/mm/flush.c
+--- a/arch/arm/mm/flush.c
++++ b/arch/arm/mm/flush.c
@@ -291,7 +291,11 @@ void flush_dcache_page(struct page *page
mapping = page_mapping(page);
-Index: linux-3.13.7/drivers/reset/core.c
-===================================================================
---- linux-3.13.7.orig/drivers/reset/core.c
-+++ linux-3.13.7/drivers/reset/core.c
+--- a/drivers/reset/core.c
++++ b/drivers/reset/core.c
@@ -127,15 +127,16 @@ int reset_control_deassert(struct reset_
EXPORT_SYMBOL_GPL(reset_control_deassert);
EXPORT_SYMBOL_GPL(reset_control_get);
/**
-Index: linux-3.13.7/include/linux/reset.h
-===================================================================
---- linux-3.13.7.orig/include/linux/reset.h
-+++ linux-3.13.7/include/linux/reset.h
+--- a/include/linux/reset.h
++++ b/include/linux/reset.h
@@ -1,6 +1,8 @@
#ifndef _LINUX_RESET_H_
#define _LINUX_RESET_H_
-Index: linux-3.14.18/Documentation/devicetree/bindings/vendor-prefixes.txt
-===================================================================
---- linux-3.14.18.orig/Documentation/devicetree/bindings/vendor-prefixes.txt
-+++ linux-3.14.18/Documentation/devicetree/bindings/vendor-prefixes.txt
+--- a/Documentation/devicetree/bindings/vendor-prefixes.txt
++++ b/Documentation/devicetree/bindings/vendor-prefixes.txt
@@ -65,6 +65,7 @@ onnn ON Semiconductor Corp.
panasonic Panasonic Corporation
phytec PHYTEC Messtechnik GmbH
-Index: linux-3.14.18/arch/arm/Kconfig
-===================================================================
---- linux-3.14.18.orig/arch/arm/Kconfig
-+++ linux-3.14.18/arch/arm/Kconfig
+--- a/arch/arm/Kconfig
++++ b/arch/arm/Kconfig
@@ -367,6 +367,17 @@ config ARCH_VERSATILE
help
This enables support for ARM Ltd Versatile board.
source "arch/arm/mach-picoxcell/Kconfig"
source "arch/arm/mach-pxa/Kconfig"
-Index: linux-3.14.18/arch/arm/Makefile
-===================================================================
---- linux-3.14.18.orig/arch/arm/Makefile
-+++ linux-3.14.18/arch/arm/Makefile
+--- a/arch/arm/Makefile
++++ b/arch/arm/Makefile
@@ -183,6 +183,7 @@ machine-$(CONFIG_ARCH_NSPIRE) += nspire
machine-$(CONFIG_ARCH_OMAP1) += omap1
machine-$(CONFIG_ARCH_OMAP2PLUS) += omap2
machine-$(CONFIG_ARCH_PICOXCELL) += picoxcell
machine-$(CONFIG_ARCH_PXA) += pxa
machine-$(CONFIG_ARCH_REALVIEW) += realview
-Index: linux-3.14.18/arch/arm/boot/dts/Makefile
-===================================================================
---- linux-3.14.18.orig/arch/arm/boot/dts/Makefile
-+++ linux-3.14.18/arch/arm/boot/dts/Makefile
+--- a/arch/arm/boot/dts/Makefile
++++ b/arch/arm/boot/dts/Makefile
@@ -233,6 +233,7 @@ dtb-$(CONFIG_ARCH_OMAP2PLUS) += omap2420
am43x-epos-evm.dtb \
dra7-evm.dtb
dtb-$(CONFIG_ARCH_PRIMA2) += prima2-evb.dtb
dtb-$(CONFIG_ARCH_U8500) += ste-snowball.dtb \
ste-hrefprev60-stuib.dtb \
-Index: linux-3.14.18/arch/arm/tools/mach-types
-===================================================================
---- linux-3.14.18.orig/arch/arm/tools/mach-types
-+++ linux-3.14.18/arch/arm/tools/mach-types
+--- a/arch/arm/tools/mach-types
++++ b/arch/arm/tools/mach-types
@@ -228,6 +228,7 @@ edb9302a MACH_EDB9302A EDB9302A 1127
edb9307a MACH_EDB9307A EDB9307A 1128
omap_3430sdp MACH_OMAP_3430SDP OMAP_3430SDP 1138
micro9m MACH_MICRO9M MICRO9M 1169
bug MACH_BUG BUG 1179
at91sam9263ek MACH_AT91SAM9263EK AT91SAM9263EK 1202
-Index: linux-3.14.18/drivers/clk/Makefile
-===================================================================
---- linux-3.14.18.orig/drivers/clk/Makefile
-+++ linux-3.14.18/drivers/clk/Makefile
+--- a/drivers/clk/Makefile
++++ b/drivers/clk/Makefile
@@ -19,6 +19,7 @@ obj-$(CONFIG_MACH_LOONGSON1) += clk-ls1
obj-$(CONFIG_COMMON_CLK_MAX77686) += clk-max77686.o
obj-$(CONFIG_ARCH_NOMADIK) += clk-nomadik.o
-Index: linux-3.14.18/drivers/clocksource/Kconfig
-===================================================================
---- linux-3.14.18.orig/drivers/clocksource/Kconfig
-+++ linux-3.14.18/drivers/clocksource/Kconfig
+--- a/drivers/clocksource/Kconfig
++++ b/drivers/clocksource/Kconfig
@@ -140,3 +140,9 @@ config VF_PIT_TIMER
bool
help
+ select CLKSRC_MMIO
+ help
+ This option enables support for the oxnas rps timers.
-Index: linux-3.14.18/drivers/clocksource/Makefile
-===================================================================
---- linux-3.14.18.orig/drivers/clocksource/Makefile
-+++ linux-3.14.18/drivers/clocksource/Makefile
+--- a/drivers/clocksource/Makefile
++++ b/drivers/clocksource/Makefile
@@ -37,3 +37,5 @@ obj-$(CONFIG_ARM_ARCH_TIMER) += arm_arc
obj-$(CONFIG_ARM_GLOBAL_TIMER) += arm_global_timer.o
obj-$(CONFIG_CLKSRC_METAG_GENERIC) += metag_generic.o
-Index: linux-3.14.18/drivers/irqchip/Kconfig
-===================================================================
---- linux-3.14.18.orig/drivers/irqchip/Kconfig
-+++ linux-3.14.18/drivers/irqchip/Kconfig
+--- a/drivers/irqchip/Kconfig
++++ b/drivers/irqchip/Kconfig
@@ -10,6 +10,11 @@ config ARM_GIC
config GIC_NON_BANKED
bool
config ARM_NVIC
bool
select IRQ_DOMAIN
-Index: linux-3.14.18/drivers/irqchip/Makefile
-===================================================================
---- linux-3.14.18.orig/drivers/irqchip/Makefile
-+++ linux-3.14.18/drivers/irqchip/Makefile
+--- a/drivers/irqchip/Makefile
++++ b/drivers/irqchip/Makefile
@@ -20,6 +20,7 @@ obj-$(CONFIG_IMGPDC_IRQ) += irq-imgpdc.
obj-$(CONFIG_SIRF_IRQ) += irq-sirfsoc.o
obj-$(CONFIG_RENESAS_INTC_IRQPIN) += irq-renesas-intc-irqpin.o
obj-$(CONFIG_VERSATILE_FPGA_IRQ) += irq-versatile-fpga.o
obj-$(CONFIG_ARCH_NSPIRE) += irq-zevio.o
obj-$(CONFIG_ARCH_VT8500) += irq-vt8500.o
-Index: linux-3.14.18/drivers/irqchip/irq-gic.c
-===================================================================
---- linux-3.14.18.orig/drivers/irqchip/irq-gic.c
-+++ linux-3.14.18/drivers/irqchip/irq-gic.c
-@@ -1015,6 +1015,7 @@ IRQCHIP_DECLARE(gic_400, "arm,gic-400",
+--- a/drivers/irqchip/irq-gic.c
++++ b/drivers/irqchip/irq-gic.c
+@@ -1015,6 +1015,7 @@ IRQCHIP_DECLARE(gic_400, "arm,gic-400",
IRQCHIP_DECLARE(cortex_a15_gic, "arm,cortex-a15-gic", gic_of_init);
IRQCHIP_DECLARE(cortex_a9_gic, "arm,cortex-a9-gic", gic_of_init);
IRQCHIP_DECLARE(cortex_a7_gic, "arm,cortex-a7-gic", gic_of_init);
-Index: linux-3.14.18/drivers/pinctrl/Kconfig
-===================================================================
---- linux-3.14.18.orig/drivers/pinctrl/Kconfig
-+++ linux-3.14.18/drivers/pinctrl/Kconfig
+--- a/drivers/pinctrl/Kconfig
++++ b/drivers/pinctrl/Kconfig
@@ -87,6 +87,15 @@ config PINCTRL_AT91
help
Say Y here to enable the at91 pinctrl driver
config PINCTRL_BAYTRAIL
bool "Intel Baytrail GPIO pin control"
depends on GPIOLIB && ACPI && X86
-Index: linux-3.14.18/drivers/pinctrl/Makefile
-===================================================================
---- linux-3.14.18.orig/drivers/pinctrl/Makefile
-+++ linux-3.14.18/drivers/pinctrl/Makefile
+--- a/drivers/pinctrl/Makefile
++++ b/drivers/pinctrl/Makefile
@@ -67,6 +67,7 @@ obj-$(CONFIG_PINCTRL_LANTIQ) += pinctrl-
obj-$(CONFIG_PINCTRL_TB10X) += pinctrl-tb10x.o
obj-$(CONFIG_PINCTRL_ST) += pinctrl-st.o
-Index: linux-3.14.18/drivers/pci/host/Kconfig
-===================================================================
---- linux-3.14.18.orig/drivers/pci/host/Kconfig
-+++ linux-3.14.18/drivers/pci/host/Kconfig
+--- a/drivers/pci/host/Kconfig
++++ b/drivers/pci/host/Kconfig
@@ -33,4 +33,9 @@ config PCI_RCAR_GEN2
There are 3 internal PCI controllers available with a single
built-in EHCI/OHCI host controller present on each one.
+ select PCIEPORTBUS
+
endmenu
-Index: linux-3.14.18/drivers/pci/host/Makefile
-===================================================================
---- linux-3.14.18.orig/drivers/pci/host/Makefile
-+++ linux-3.14.18/drivers/pci/host/Makefile
+--- a/drivers/pci/host/Makefile
++++ b/drivers/pci/host/Makefile
@@ -4,3 +4,4 @@ obj-$(CONFIG_PCI_IMX6) += pci-imx6.o
obj-$(CONFIG_PCI_MVEBU) += pci-mvebu.o
obj-$(CONFIG_PCI_TEGRA) += pci-tegra.o
-Index: linux-3.14.18/drivers/reset/Kconfig
-===================================================================
---- linux-3.14.18.orig/drivers/reset/Kconfig
-+++ linux-3.14.18/drivers/reset/Kconfig
+--- a/drivers/reset/Kconfig
++++ b/drivers/reset/Kconfig
@@ -11,3 +11,7 @@ menuconfig RESET_CONTROLLER
via GPIOs or SoC-internal reset controller modules.
+config RESET_CONTROLLER_OXNAS
+ bool
+ select RESET_CONTROLLER
-Index: linux-3.14.18/drivers/reset/Makefile
-===================================================================
---- linux-3.14.18.orig/drivers/reset/Makefile
-+++ linux-3.14.18/drivers/reset/Makefile
+--- a/drivers/reset/Makefile
++++ b/drivers/reset/Makefile
@@ -1,2 +1,3 @@
obj-$(CONFIG_RESET_CONTROLLER) += core.o
+obj-$(CONFIG_RESET_CONTROLLER_OXNAS) += reset-ox820.o
-Index: linux-3.14.18/drivers/mtd/nand/Kconfig
-===================================================================
---- linux-3.14.18.orig/drivers/mtd/nand/Kconfig
-+++ linux-3.14.18/drivers/mtd/nand/Kconfig
+--- a/drivers/mtd/nand/Kconfig
++++ b/drivers/mtd/nand/Kconfig
@@ -510,4 +510,12 @@ config MTD_NAND_XWAY
Enables support for NAND Flash chips on Lantiq XWAY SoCs. NAND is attached
to the External Bus Unit (EBU).
+ to the STATIC Unit.
+
endif # MTD_NAND
-Index: linux-3.14.18/drivers/mtd/nand/Makefile
-===================================================================
---- linux-3.14.18.orig/drivers/mtd/nand/Makefile
-+++ linux-3.14.18/drivers/mtd/nand/Makefile
+--- a/drivers/mtd/nand/Makefile
++++ b/drivers/mtd/nand/Makefile
@@ -49,5 +49,6 @@ obj-$(CONFIG_MTD_NAND_JZ4740) += jz4740
obj-$(CONFIG_MTD_NAND_GPMI_NAND) += gpmi-nand/
obj-$(CONFIG_MTD_NAND_XWAY) += xway_nand.o
-Index: linux-3.14.18/drivers/ata/Kconfig
-===================================================================
---- linux-3.14.18.orig/drivers/ata/Kconfig
-+++ linux-3.14.18/drivers/ata/Kconfig
+--- a/drivers/ata/Kconfig
++++ b/drivers/ata/Kconfig
@@ -330,6 +330,13 @@ config SATA_VITESSE
If unsure, say N.
comment "PATA SFF controllers with BMDMA"
config PATA_ALI
-Index: linux-3.14.18/drivers/ata/Makefile
-===================================================================
---- linux-3.14.18.orig/drivers/ata/Makefile
-+++ linux-3.14.18/drivers/ata/Makefile
+--- a/drivers/ata/Makefile
++++ b/drivers/ata/Makefile
@@ -31,6 +31,7 @@ obj-$(CONFIG_SATA_SVW) += sata_svw.o
obj-$(CONFIG_SATA_ULI) += sata_uli.o
obj-$(CONFIG_SATA_VIA) += sata_via.o
-Index: linux-3.14.18/drivers/usb/host/Kconfig
-===================================================================
---- linux-3.14.18.orig/drivers/usb/host/Kconfig
-+++ linux-3.14.18/drivers/usb/host/Kconfig
+--- a/drivers/usb/host/Kconfig
++++ b/drivers/usb/host/Kconfig
@@ -273,6 +273,13 @@ config USB_OCTEON_EHCI
USB 2.0 device support. All CN6XXX based chips with USB are
supported.
endif # USB_EHCI_HCD
config USB_OXU210HP_HCD
-Index: linux-3.14.18/drivers/usb/host/Makefile
-===================================================================
---- linux-3.14.18.orig/drivers/usb/host/Makefile
-+++ linux-3.14.18/drivers/usb/host/Makefile
+--- a/drivers/usb/host/Makefile
++++ b/drivers/usb/host/Makefile
@@ -37,6 +37,7 @@ obj-$(CONFIG_USB_EHCI_HCD_AT91) += ehci-
obj-$(CONFIG_USB_EHCI_MSM) += ehci-msm.o
obj-$(CONFIG_USB_EHCI_TEGRA) += ehci-tegra.o
-Index: linux-3.14.18/arch/arm/boot/dts/Makefile
-===================================================================
---- linux-3.14.18.orig/arch/arm/boot/dts/Makefile
-+++ linux-3.14.18/arch/arm/boot/dts/Makefile
+--- a/arch/arm/boot/dts/Makefile
++++ b/arch/arm/boot/dts/Makefile
@@ -233,7 +233,10 @@ dtb-$(CONFIG_ARCH_OMAP2PLUS) += omap2420
am43x-epos-evm.dtb \
dra7-evm.dtb
create mode 100644 arch/mips/ralink/malta-amon.c
create mode 100644 arch/mips/ralink/mt7621.c
-Index: linux-3.14.18/arch/mips/include/asm/gic.h
-===================================================================
---- linux-3.14.18.orig/arch/mips/include/asm/gic.h 2014-09-06 01:34:59.000000000 +0200
-+++ linux-3.14.18/arch/mips/include/asm/gic.h 2014-11-12 18:15:37.293244085 +0100
+--- a/arch/mips/include/asm/gic.h
++++ b/arch/mips/include/asm/gic.h
@@ -19,7 +19,11 @@
#define GIC_TRIG_EDGE 1
#define GIC_TRIG_LEVEL 0
#define MSK(n) ((1 << (n)) - 1)
#define REG32(addr) (*(volatile unsigned int *) (addr))
-Index: linux-3.14.18/arch/mips/include/asm/mach-ralink/irq.h
-===================================================================
---- /dev/null 1970-01-01 00:00:00.000000000 +0000
-+++ linux-3.14.18/arch/mips/include/asm/mach-ralink/irq.h 2014-11-12 18:15:37.297244234 +0100
+--- /dev/null
++++ b/arch/mips/include/asm/mach-ralink/irq.h
@@ -0,0 +1,9 @@
+#ifndef __ASM_MACH_RALINK_IRQ_H
+#define __ASM_MACH_RALINK_IRQ_H
+#include_next <irq.h>
+
+#endif
-Index: linux-3.14.18/arch/mips/include/asm/mach-ralink/mt7621.h
-===================================================================
---- /dev/null 1970-01-01 00:00:00.000000000 +0000
-+++ linux-3.14.18/arch/mips/include/asm/mach-ralink/mt7621.h 2014-11-12 18:15:37.297244234 +0100
+--- /dev/null
++++ b/arch/mips/include/asm/mach-ralink/mt7621.h
@@ -0,0 +1,39 @@
+/*
+ * This program is free software; you can redistribute it and/or modify it
+#define MIPS_GIC_IRQ_BASE (MIPS_CPU_IRQ_BASE + 8)
+
+#endif
-Index: linux-3.14.18/arch/mips/kernel/vmlinux.lds.S
-===================================================================
---- linux-3.14.18.orig/arch/mips/kernel/vmlinux.lds.S 2014-11-12 18:15:35.441175040 +0100
-+++ linux-3.14.18/arch/mips/kernel/vmlinux.lds.S 2014-11-12 18:15:37.297244234 +0100
-@@ -51,6 +51,7 @@
+--- a/arch/mips/kernel/vmlinux.lds.S
++++ b/arch/mips/kernel/vmlinux.lds.S
+@@ -51,6 +51,7 @@ SECTIONS
/* read-only */
_text = .; /* Text and read-only data */
.text : {
TEXT_TEXT
SCHED_TEXT
LOCK_TEXT
-Index: linux-3.14.18/arch/mips/ralink/Kconfig
-===================================================================
---- linux-3.14.18.orig/arch/mips/ralink/Kconfig 2014-09-06 01:34:59.000000000 +0200
-+++ linux-3.14.18/arch/mips/ralink/Kconfig 2014-11-13 10:37:45.371792998 +0100
-@@ -7,6 +7,11 @@
+--- a/arch/mips/ralink/Kconfig
++++ b/arch/mips/ralink/Kconfig
+@@ -7,6 +7,11 @@ config CLKEVT_RT3352
select CLKSRC_OF
select CLKSRC_MMIO
choice
prompt "Ralink SoC selection"
default SOC_RT305X
-@@ -34,6 +39,15 @@
+@@ -34,6 +39,15 @@ choice
select USB_ARCH_HAS_OHCI
select USB_ARCH_HAS_EHCI
endchoice
choice
-@@ -61,6 +75,10 @@
+@@ -61,6 +75,10 @@ choice
bool "MT7620A eval kit"
depends on SOC_MT7620
endchoice
endif
-Index: linux-3.14.18/arch/mips/ralink/Makefile
-===================================================================
---- linux-3.14.18.orig/arch/mips/ralink/Makefile 2014-11-12 18:15:37.225241550 +0100
-+++ linux-3.14.18/arch/mips/ralink/Makefile 2014-11-13 10:37:43.947738138 +0100
+--- a/arch/mips/ralink/Makefile
++++ b/arch/mips/ralink/Makefile
@@ -6,16 +6,21 @@
# Copyright (C) 2009-2011 Gabor Juhos <juhosg@openwrt.org>
# Copyright (C) 2013 John Crispin <blogic@openwrt.org>
obj-$(CONFIG_EARLY_PRINTK) += early_printk.o
-Index: linux-3.14.18/arch/mips/ralink/Platform
-===================================================================
---- linux-3.14.18.orig/arch/mips/ralink/Platform 2014-09-06 01:34:59.000000000 +0200
-+++ linux-3.14.18/arch/mips/ralink/Platform 2014-11-12 18:15:37.297244234 +0100
-@@ -27,3 +27,8 @@
+--- a/arch/mips/ralink/Platform
++++ b/arch/mips/ralink/Platform
+@@ -27,3 +27,8 @@ cflags-$(CONFIG_SOC_RT3883) += -I$(srctr
#
load-$(CONFIG_SOC_MT7620) += 0xffffffff80000000
cflags-$(CONFIG_SOC_MT7620) += -I$(srctree)/arch/mips/include/asm/mach-ralink/mt7620
+#
+load-$(CONFIG_SOC_MT7621) += 0xffffffff80001000
+cflags-$(CONFIG_SOC_MT7621) += -I$(srctree)/arch/mips/include/asm/mach-ralink/mt7621
-Index: linux-3.14.18/arch/mips/ralink/irq-gic.c
-===================================================================
---- /dev/null 1970-01-01 00:00:00.000000000 +0000
-+++ linux-3.14.18/arch/mips/ralink/irq-gic.c 2014-11-12 18:15:37.297244234 +0100
+--- /dev/null
++++ b/arch/mips/ralink/irq-gic.c
@@ -0,0 +1,271 @@
+#include <linux/init.h>
+#include <linux/sched.h>
+{
+ of_irq_init(of_irq_ids);
+}
-Index: linux-3.14.18/arch/mips/ralink/malta-amon.c
-===================================================================
---- /dev/null 1970-01-01 00:00:00.000000000 +0000
-+++ linux-3.14.18/arch/mips/ralink/malta-amon.c 2014-11-12 18:15:37.297244234 +0100
+--- /dev/null
++++ b/arch/mips/ralink/malta-amon.c
@@ -0,0 +1,81 @@
+/*
+ * Copyright (C) 2007 MIPS Technologies, Inc.
+ smp_rmb(); /* Target will be updating flags soon */
+ pr_debug("launch: cpu%d gone!\n", cpu);
+}
-Index: linux-3.14.18/arch/mips/ralink/mt7621.c
-===================================================================
---- /dev/null 1970-01-01 00:00:00.000000000 +0000
-+++ linux-3.14.18/arch/mips/ralink/mt7621.c 2014-11-13 10:32:56.960683223 +0100
+--- /dev/null
++++ b/arch/mips/ralink/mt7621.c
@@ -0,0 +1,183 @@
+/*
+ * This program is free software; you can redistribute it and/or modify it
DEFINE_PER_CPU(struct clock_event_device, mips_clockevent_device);
int cp0_timer_irq_installed;
-@@ -90,9 +84,38 @@ struct irqaction c0_compare_irqaction =
+@@ -90,9 +84,38 @@ struct irqaction c0_compare_irqaction =
.name = "timer",
};
static void systick_set_clock_mode(enum clock_event_mode mode,
struct clock_event_device *evt)
{
-@@ -101,9 +122,13 @@ static void systick_set_clock_mode(enum
+@@ -101,9 +122,13 @@ static void systick_set_clock_mode(enum
sdev->irq_requested = 1;
iowrite32(CFG_EXT_STK_EN | CFG_CNT_EN,
systick.membase + SYSTICK_CONFIG);
if (sdev->irq_requested)
free_irq(systick.dev.irq, &systick_irqaction);
sdev->irq_requested = 0;
-@@ -116,12 +141,23 @@ static void systick_set_clock_mode(enum
+@@ -116,12 +141,23 @@ static void systick_set_clock_mode(enum
}
}
- .gpio_first = 72,
- .gpio_last = 72,
- }, {0}
-+static struct rt2880_pmx_func i2c_grp[] = { FUNC("i2c", 0, 1, 2) };
-+static struct rt2880_pmx_func spi_grp[] = { FUNC("spi", 0, 3, 4) };
-+static struct rt2880_pmx_func uartlite_grp[] = { FUNC("uartlite", 0, 15, 2) };
-+static struct rt2880_pmx_func mdio_grp[] = { FUNC("mdio", 0, 22, 2) };
-+static struct rt2880_pmx_func rgmii1_grp[] = { FUNC("rgmii1", 0, 24, 12) };
-+static struct rt2880_pmx_func refclk_grp[] = { FUNC("spi refclk", 0, 37, 3) };
-+static struct rt2880_pmx_func ephy_grp[] = { FUNC("ephy", 0, 40, 5) };
-+static struct rt2880_pmx_func rgmii2_grp[] = { FUNC("rgmii2", 0, 60, 12) };
-+static struct rt2880_pmx_func wled_grp[] = { FUNC("wled", 0, 72, 1) };
-+static struct rt2880_pmx_func pa_grp[] = { FUNC("pa", 0, 18, 4) };
-+static struct rt2880_pmx_func uartf_grp[] = {
-+ FUNC("uartf", MT7620_GPIO_MODE_UARTF, 7, 8),
-+ FUNC("pcm uartf", MT7620_GPIO_MODE_PCM_UARTF, 7, 8),
-+ FUNC("pcm i2s", MT7620_GPIO_MODE_PCM_I2S, 7, 8),
-+ FUNC("i2s uartf", MT7620_GPIO_MODE_I2S_UARTF, 7, 8),
-+ FUNC("pcm gpio", MT7620_GPIO_MODE_PCM_GPIO, 11, 4),
-+ FUNC("gpio uartf", MT7620_GPIO_MODE_GPIO_UARTF, 7, 4),
-+ FUNC("gpio i2s", MT7620_GPIO_MODE_GPIO_I2S, 7, 4),
- };
+-};
-
-static struct ralink_pinmux_grp uart_mux[] = {
- {
- .name = "gpio",
- .mask = MT7620_GPIO_MODE_GPIO,
- }, {0}
+-};
+-
+-struct ralink_pinmux rt_gpio_pinmux = {
+- .mode = mode_mux,
+- .uart = uart_mux,
+- .uart_shift = MT7620_GPIO_MODE_UART0_SHIFT,
+- .uart_mask = MT7620_GPIO_MODE_UART0_MASK,
++static struct rt2880_pmx_func i2c_grp[] = { FUNC("i2c", 0, 1, 2) };
++static struct rt2880_pmx_func spi_grp[] = { FUNC("spi", 0, 3, 4) };
++static struct rt2880_pmx_func uartlite_grp[] = { FUNC("uartlite", 0, 15, 2) };
++static struct rt2880_pmx_func mdio_grp[] = { FUNC("mdio", 0, 22, 2) };
++static struct rt2880_pmx_func rgmii1_grp[] = { FUNC("rgmii1", 0, 24, 12) };
++static struct rt2880_pmx_func refclk_grp[] = { FUNC("spi refclk", 0, 37, 3) };
++static struct rt2880_pmx_func ephy_grp[] = { FUNC("ephy", 0, 40, 5) };
++static struct rt2880_pmx_func rgmii2_grp[] = { FUNC("rgmii2", 0, 60, 12) };
++static struct rt2880_pmx_func wled_grp[] = { FUNC("wled", 0, 72, 1) };
++static struct rt2880_pmx_func pa_grp[] = { FUNC("pa", 0, 18, 4) };
++static struct rt2880_pmx_func uartf_grp[] = {
++ FUNC("uartf", MT7620_GPIO_MODE_UARTF, 7, 8),
++ FUNC("pcm uartf", MT7620_GPIO_MODE_PCM_UARTF, 7, 8),
++ FUNC("pcm i2s", MT7620_GPIO_MODE_PCM_I2S, 7, 8),
++ FUNC("i2s uartf", MT7620_GPIO_MODE_I2S_UARTF, 7, 8),
++ FUNC("pcm gpio", MT7620_GPIO_MODE_PCM_GPIO, 11, 4),
++ FUNC("gpio uartf", MT7620_GPIO_MODE_GPIO_UARTF, 7, 4),
++ FUNC("gpio i2s", MT7620_GPIO_MODE_GPIO_I2S, 7, 4),
++};
+static struct rt2880_pmx_func wdt_grp[] = {
+ FUNC("wdt rst", 0, 17, 1),
+ FUNC("wdt refclk", 0, 17, 1),
+static struct rt2880_pmx_func nd_sd_grp[] = {
+ FUNC("nand", MT7620_GPIO_MODE_NAND, 45, 15),
+ FUNC("sd", MT7620_GPIO_MODE_SD, 45, 15)
- };
-
--struct ralink_pinmux rt_gpio_pinmux = {
-- .mode = mode_mux,
-- .uart = uart_mux,
-- .uart_shift = MT7620_GPIO_MODE_UART0_SHIFT,
-- .uart_mask = MT7620_GPIO_MODE_UART0_MASK,
++};
++
+static struct rt2880_pmx_group mt7620a_pinmux_data[] = {
+ GRP("i2c", i2c_grp, 1, MT7620_GPIO_MODE_I2C),
+ GRP("uartf", uartf_grp, MT7620_GPIO_MODE_UART0_MASK,
3 files changed, 365 insertions(+)
create mode 100644 arch/mips/pci/pci-mt7620.c
-Index: linux-3.14.18/arch/mips/pci/Makefile
-===================================================================
---- linux-3.14.18.orig/arch/mips/pci/Makefile 2014-11-17 16:02:34.009553392 +0100
-+++ linux-3.14.18/arch/mips/pci/Makefile 2014-11-17 16:02:34.017553694 +0100
-@@ -42,6 +42,7 @@
+--- a/arch/mips/pci/Makefile
++++ b/arch/mips/pci/Makefile
+@@ -42,6 +42,7 @@ obj-$(CONFIG_SNI_RM) += fixup-sni.o ops
obj-$(CONFIG_LANTIQ) += fixup-lantiq.o
obj-$(CONFIG_PCI_LANTIQ) += pci-lantiq.o ops-lantiq.o
obj-$(CONFIG_SOC_MT7621) += pci-mt7621.o
obj-$(CONFIG_SOC_RT2880) += pci-rt2880.o
obj-$(CONFIG_SOC_RT3883) += pci-rt3883.o
obj-$(CONFIG_TANBAC_TB0219) += fixup-tb0219.o
-Index: linux-3.14.18/arch/mips/pci/pci-mt7620.c
-===================================================================
---- /dev/null 1970-01-01 00:00:00.000000000 +0000
-+++ linux-3.14.18/arch/mips/pci/pci-mt7620.c 2014-11-17 16:09:52.814075085 +0100
+--- /dev/null
++++ b/arch/mips/pci/pci-mt7620.c
@@ -0,0 +1,396 @@
+/*
+ * Ralink MT7620A SoC PCI support
+}
+
+arch_initcall(mt7620_pci_init);
-Index: linux-3.14.18/arch/mips/ralink/Kconfig
-===================================================================
---- linux-3.14.18.orig/arch/mips/ralink/Kconfig 2014-11-17 16:02:34.009553392 +0100
-+++ linux-3.14.18/arch/mips/ralink/Kconfig 2014-11-17 16:02:34.021553845 +0100
-@@ -39,6 +39,7 @@
+--- a/arch/mips/ralink/Kconfig
++++ b/arch/mips/ralink/Kconfig
+@@ -39,6 +39,7 @@ choice
bool "MT7620/8"
select USB_ARCH_HAS_OHCI
select USB_ARCH_HAS_EHCI
config SOC_MT7621
bool "MT7621"
-Index: linux-3.14.18/arch/mips/include/asm/mach-ralink/mt7620.h
-===================================================================
---- linux-3.14.18.orig/arch/mips/include/asm/mach-ralink/mt7620.h 2014-11-17 16:02:33.993552790 +0100
-+++ linux-3.14.18/arch/mips/include/asm/mach-ralink/mt7620.h 2014-11-17 16:10:00.002345398 +0100
-@@ -19,6 +19,7 @@
+--- a/arch/mips/include/asm/mach-ralink/mt7620.h
++++ b/arch/mips/include/asm/mach-ralink/mt7620.h
+@@ -19,6 +19,7 @@ enum mt762x_soc_type {
MT762X_SOC_MT7620N,
MT762X_SOC_MT7628AN,
};
return 1;
}
-@@ -2991,6 +2994,7 @@ static int prepare_ring(struct xhci_hcd
+@@ -2990,6 +2993,7 @@ static int prepare_ring(struct xhci_hcd
next = ring->enqueue;
while (last_trb(xhci, ring, ring->enq_seg, next)) {
/* If we're not dealing with 0.95 hardware or isoc rings
* on AMD 0.96 host, clear the chain bit.
*/
-@@ -3000,7 +3004,9 @@ static int prepare_ring(struct xhci_hcd
+@@ -2999,7 +3003,9 @@ static int prepare_ring(struct xhci_hcd
next->link.control &= cpu_to_le32(~TRB_CHAIN);
else
next->link.control |= cpu_to_le32(TRB_CHAIN);
wmb();
next->link.control ^= cpu_to_le32(TRB_CYCLE);
-@@ -3130,6 +3136,9 @@ static void giveback_first_trb(struct xh
+@@ -3129,6 +3135,9 @@ static void giveback_first_trb(struct xh
start_trb->field[3] |= cpu_to_le32(start_cycle);
else
start_trb->field[3] &= cpu_to_le32(~TRB_CYCLE);
xhci_ring_ep_doorbell(xhci, slot_id, ep_index, stream_id);
}
-@@ -3185,6 +3194,29 @@ static u32 xhci_td_remainder(unsigned in
+@@ -3184,6 +3193,29 @@ static u32 xhci_td_remainder(unsigned in
return (remainder >> 10) << 17;
}
/*
* For xHCI 1.0 host controllers, TD size is the number of max packet sized
* packets remaining in the TD (*not* including this TRB).
-@@ -3322,6 +3354,7 @@ static int queue_bulk_sg_tx(struct xhci_
+@@ -3321,6 +3353,7 @@ static int queue_bulk_sg_tx(struct xhci_
}
/* Set the TRB length, TD size, and interrupter fields. */
if (xhci->hci_version < 0x100) {
remainder = xhci_td_remainder(
urb->transfer_buffer_length -
-@@ -3331,6 +3364,13 @@ static int queue_bulk_sg_tx(struct xhci_
+@@ -3330,6 +3363,13 @@ static int queue_bulk_sg_tx(struct xhci_
trb_buff_len, total_packet_count, urb,
num_trbs - 1);
}
length_field = TRB_LEN(trb_buff_len) |
remainder |
TRB_INTR_TARGET(0);
-@@ -3393,6 +3433,9 @@ int xhci_queue_bulk_tx(struct xhci_hcd *
+@@ -3392,6 +3432,9 @@ int xhci_queue_bulk_tx(struct xhci_hcd *
int running_total, trb_buff_len, ret;
unsigned int total_packet_count;
u64 addr;
if (urb->num_sgs)
return queue_bulk_sg_tx(xhci, mem_flags, urb, slot_id, ep_index);
-@@ -3418,6 +3461,25 @@ int xhci_queue_bulk_tx(struct xhci_hcd *
+@@ -3417,6 +3460,25 @@ int xhci_queue_bulk_tx(struct xhci_hcd *
running_total += TRB_MAX_BUFF_SIZE;
}
/* FIXME: this doesn't deal with URB_ZERO_PACKET - need one more */
ret = prepare_transfer(xhci, xhci->devs[slot_id],
ep_index, urb->stream_id,
-@@ -3477,6 +3539,7 @@ int xhci_queue_bulk_tx(struct xhci_hcd *
+@@ -3476,6 +3538,7 @@ int xhci_queue_bulk_tx(struct xhci_hcd *
field |= TRB_ISP;
/* Set the TRB length, TD size, and interrupter fields. */
if (xhci->hci_version < 0x100) {
remainder = xhci_td_remainder(
urb->transfer_buffer_length -
-@@ -3486,6 +3549,10 @@ int xhci_queue_bulk_tx(struct xhci_hcd *
+@@ -3485,6 +3548,10 @@ int xhci_queue_bulk_tx(struct xhci_hcd *
trb_buff_len, total_packet_count, urb,
num_trbs - 1);
}
length_field = TRB_LEN(trb_buff_len) |
remainder |
TRB_INTR_TARGET(0);
-@@ -3575,7 +3642,11 @@ int xhci_queue_ctrl_tx(struct xhci_hcd *
+@@ -3574,7 +3641,11 @@ int xhci_queue_ctrl_tx(struct xhci_hcd *
field |= 0x1;
/* xHCI 1.0 6.4.1.2.1: Transfer Type field */
if (urb->transfer_buffer_length > 0) {
if (setup->bRequestType & USB_DIR_IN)
field |= TRB_TX_TYPE(TRB_DATA_IN);
-@@ -3599,7 +3670,12 @@ int xhci_queue_ctrl_tx(struct xhci_hcd *
+@@ -3598,7 +3669,12 @@ int xhci_queue_ctrl_tx(struct xhci_hcd *
field = TRB_TYPE(TRB_DATA);
length_field = TRB_LEN(urb->transfer_buffer_length) |
TRB_INTR_TARGET(0);
if (urb->transfer_buffer_length > 0) {
if (setup->bRequestType & USB_DIR_IN)
-@@ -3610,7 +3686,7 @@ int xhci_queue_ctrl_tx(struct xhci_hcd *
+@@ -3609,7 +3685,7 @@ int xhci_queue_ctrl_tx(struct xhci_hcd *
length_field,
field | ep_ring->cycle_state);
}
/* Save the DMA address of the last TRB in the TD */
td->last_trb = ep_ring->enqueue;
-@@ -3722,6 +3798,9 @@ static int xhci_queue_isoc_tx(struct xhc
+@@ -3721,6 +3797,9 @@ static int xhci_queue_isoc_tx(struct xhc
u64 start_addr, addr;
int i, j;
bool more_trbs_coming;
ep_ring = xhci->devs[slot_id]->eps[ep_index].ring;
-@@ -3735,6 +3814,21 @@ static int xhci_queue_isoc_tx(struct xhc
+@@ -3734,6 +3813,21 @@ static int xhci_queue_isoc_tx(struct xhc
start_trb = &ep_ring->enqueue->generic;
start_cycle = ep_ring->cycle_state;
urb_priv = urb->hcpriv;
/* Queue the first TRB, even if it's zero-length */
for (i = 0; i < num_tds; i++) {
-@@ -3806,9 +3900,13 @@ static int xhci_queue_isoc_tx(struct xhc
+@@ -3805,9 +3899,13 @@ static int xhci_queue_isoc_tx(struct xhc
} else {
td->last_trb = ep_ring->enqueue;
field |= TRB_IOC;
/* Set BEI bit except for the last td */
if (i < num_tds - 1)
field |= TRB_BEI;
-@@ -3823,6 +3921,7 @@ static int xhci_queue_isoc_tx(struct xhc
+@@ -3822,6 +3920,7 @@ static int xhci_queue_isoc_tx(struct xhc
trb_buff_len = td_remain_len;
/* Set the TRB length, TD size, & interrupter fields. */
if (xhci->hci_version < 0x100) {
remainder = xhci_td_remainder(
td_len - running_total);
-@@ -3832,6 +3931,10 @@ static int xhci_queue_isoc_tx(struct xhc
+@@ -3831,6 +3930,10 @@ static int xhci_queue_isoc_tx(struct xhc
total_packet_count, urb,
(trbs_per_td - j - 1));
}
#define DRIVER_AUTHOR "Sarah Sharp"
#define DRIVER_DESC "'eXtensible' Host Controller (xHC) Driver"
-@@ -44,6 +54,18 @@ static unsigned int quirks;
+@@ -46,6 +56,18 @@ static unsigned int quirks;
module_param(quirks, uint, S_IRUGO);
MODULE_PARM_DESC(quirks, "Bit flags for quirks to be enabled as default");
/* TODO: copied from ehci-hcd.c - can this be refactored? */
/*
* xhci_handshake - spin reading hc until handshake completes or fails
-@@ -196,7 +218,7 @@ int xhci_reset(struct xhci_hcd *xhci)
+@@ -198,7 +220,7 @@ int xhci_reset(struct xhci_hcd *xhci)
return ret;
}
static int xhci_free_msi(struct xhci_hcd *xhci)
{
int i;
-@@ -399,6 +421,7 @@ static int xhci_try_enable_msi(struct us
+@@ -401,6 +423,7 @@ static int xhci_try_enable_msi(struct us
return ret;
}
hcd->irq = pdev->irq;
return 0;
}
-@@ -442,6 +465,11 @@ static void compliance_mode_recovery(uns
+@@ -444,6 +467,11 @@ static void compliance_mode_recovery(uns
"Attempting compliance mode recovery");
hcd = xhci->shared_hcd;
if (hcd->state == HC_STATE_SUSPENDED)
usb_hcd_resume_root_hub(hcd);
-@@ -491,6 +519,9 @@ bool xhci_compliance_mode_recovery_timer
+@@ -493,6 +521,9 @@ bool xhci_compliance_mode_recovery_timer
{
const char *dmi_product_name, *dmi_sys_vendor;
dmi_product_name = dmi_get_system_info(DMI_PRODUCT_NAME);
dmi_sys_vendor = dmi_get_system_info(DMI_SYS_VENDOR);
if (!dmi_product_name || !dmi_sys_vendor)
-@@ -536,6 +567,10 @@ int xhci_init(struct usb_hcd *hcd)
+@@ -538,6 +569,10 @@ int xhci_init(struct usb_hcd *hcd)
xhci_dbg_trace(xhci, trace_xhci_dbg_init,
"xHCI doesn't need link TRB QUIRK");
}
retval = xhci_mem_init(xhci, GFP_KERNEL);
xhci_dbg_trace(xhci, trace_xhci_dbg_init, "Finished xhci_init");
-@@ -620,7 +655,11 @@ int xhci_run(struct usb_hcd *hcd)
+@@ -622,7 +657,11 @@ int xhci_run(struct usb_hcd *hcd)
"// Set the interrupt modulation register");
temp = readl(&xhci->ir_set->irq_control);
temp &= ~ER_IRQ_INTERVAL_MASK;
writel(temp, &xhci->ir_set->irq_control);
/* Set the HCD state before we enable the irqs */
-@@ -641,6 +680,9 @@ int xhci_run(struct usb_hcd *hcd)
+@@ -643,6 +682,9 @@ int xhci_run(struct usb_hcd *hcd)
xhci_queue_vendor_command(xhci, 0, 0, 0,
TRB_TYPE(TRB_NEC_GET_FW));
xhci_dbg_trace(xhci, trace_xhci_dbg_init,
"Finished xhci_run for USB2 roothub");
return 0;
-@@ -970,7 +1012,6 @@ int xhci_resume(struct xhci_hcd *xhci, b
+@@ -1010,7 +1052,6 @@ int xhci_resume(struct xhci_hcd *xhci, b
/* If restore operation fails, re-initialize the HC during resume */
if ((temp & STS_SRE) || hibernated) {
if ((xhci->quirks & XHCI_COMP_MODE_QUIRK) &&
!(xhci_all_ports_seen_u0(xhci))) {
del_timer_sync(&xhci->comp_mode_recovery_timer);
-@@ -1573,6 +1614,13 @@ int xhci_drop_endpoint(struct usb_hcd *h
+@@ -1613,6 +1654,13 @@ int xhci_drop_endpoint(struct usb_hcd *h
u32 drop_flag;
u32 new_add_flags, new_drop_flags, new_slot_info;
int ret;
ret = xhci_check_args(hcd, udev, ep, 1, true, __func__);
if (ret <= 0)
-@@ -1630,6 +1678,40 @@ int xhci_drop_endpoint(struct usb_hcd *h
+@@ -1670,6 +1718,40 @@ int xhci_drop_endpoint(struct usb_hcd *h
xhci_endpoint_zero(xhci, xhci->devs[udev->slot_id], ep);
xhci_dbg(xhci, "drop ep 0x%x, slot id %d, new drop flags = %#x, new add flags = %#x, new slot info = %#x\n",
(unsigned int) ep->desc.bEndpointAddress,
udev->slot_id,
-@@ -1665,6 +1747,18 @@ int xhci_add_endpoint(struct usb_hcd *hc
+@@ -1705,6 +1787,18 @@ int xhci_add_endpoint(struct usb_hcd *hc
u32 new_add_flags, new_drop_flags, new_slot_info;
struct xhci_virt_device *virt_dev;
int ret = 0;
ret = xhci_check_args(hcd, udev, ep, 1, true, __func__);
if (ret <= 0) {
-@@ -1732,6 +1826,56 @@ int xhci_add_endpoint(struct usb_hcd *hc
+@@ -1772,6 +1866,56 @@ int xhci_add_endpoint(struct usb_hcd *hc
return -ENOMEM;
}
ctrl_ctx->add_flags |= cpu_to_le32(added_ctxs);
new_add_flags = le32_to_cpu(ctrl_ctx->add_flags);
-@@ -2726,7 +2870,7 @@ int xhci_check_bandwidth(struct usb_hcd
+@@ -2766,7 +2910,7 @@ int xhci_check_bandwidth(struct usb_hcd
if (ctrl_ctx->add_flags == cpu_to_le32(SLOT_FLAG) &&
ctrl_ctx->drop_flags == 0)
return 0;
xhci_dbg(xhci, "New Input Control Context:\n");
slot_ctx = xhci_get_slot_ctx(xhci, virt_dev->in_ctx);
xhci_dbg_ctx(xhci, virt_dev->in_ctx,
-@@ -4352,10 +4496,14 @@ static u16 xhci_call_host_update_timeout
+@@ -4400,10 +4544,14 @@ static u16 xhci_call_host_update_timeout
u16 *timeout)
{
if (state == USB3_LPM_U1) {
return xhci_calculate_intel_u2_timeout(udev, desc);
}
-@@ -4740,7 +4888,9 @@ int xhci_gen_setup(struct usb_hcd *hcd,
+@@ -4788,7 +4936,9 @@ int xhci_gen_setup(struct usb_hcd *hcd,
hcd->self.no_sg_constraint = 1;
/* XHCI controllers don't stop the ep queue on short packets :| */
if (usb_hcd_is_primary_hcd(hcd)) {
xhci = kzalloc(sizeof(struct xhci_hcd), GFP_KERNEL);
-@@ -4803,6 +4953,10 @@ int xhci_gen_setup(struct usb_hcd *hcd,
+@@ -4851,6 +5001,10 @@ int xhci_gen_setup(struct usb_hcd *hcd,
goto error;
xhci_dbg(xhci, "Reset complete\n");
/* Set dma_mask and coherent_dma_mask to 64-bits,
* if xHC supports 64-bit addressing */
if (HCC_64BIT_ADDR(xhci->hcc_params) &&
-@@ -4827,8 +4981,21 @@ MODULE_DESCRIPTION(DRIVER_DESC);
+@@ -4875,8 +5029,21 @@ MODULE_DESCRIPTION(DRIVER_DESC);
MODULE_AUTHOR(DRIVER_AUTHOR);
MODULE_LICENSE("GPL");
int retval;
retval = xhci_register_pci();
-@@ -4841,6 +5008,33 @@ static int __init xhci_hcd_init(void)
+@@ -4889,6 +5056,33 @@ static int __init xhci_hcd_init(void)
pr_debug("Problem registering platform driver.\n");
goto unreg_pci;
}
/*
* Check the compiler generated sizes of structures that must be laid
* out in specific ways for hardware access.
-@@ -4858,6 +5052,7 @@ static int __init xhci_hcd_init(void)
+@@ -4906,6 +5100,7 @@ static int __init xhci_hcd_init(void)
BUILD_BUG_ON(sizeof(struct xhci_intr_reg) != 8*32/8);
/* xhci_run_regs has eight fields and embeds 128 xhci_intr_regs */
BUILD_BUG_ON(sizeof(struct xhci_run_regs) != (8+8*128)*32/8);
};
/* convert between an HCD pointer and the corresponding EHCI_HCD */
-@@ -1726,7 +1745,7 @@ void xhci_urb_free_priv(struct xhci_hcd
+@@ -1726,7 +1745,7 @@ void xhci_urb_free_priv(struct xhci_hcd
void xhci_free_command(struct xhci_hcd *xhci,
struct xhci_command *command);
/*
* Write an address range to the flash chip. Data must be written in
* FLASH_PAGESIZE chunks. The address range may be any size provided
-@@ -649,6 +701,76 @@ static int m25p80_write(struct mtd_info
+@@ -649,6 +701,76 @@ static int m25p80_write(struct mtd_info
return 0;
}
static int sst_write(struct mtd_info *mtd, loff_t to, size_t len,
size_t *retlen, const u_char *buf)
{
-@@ -1260,6 +1382,12 @@ static int m25p_probe(struct spi_device
+@@ -1260,6 +1382,12 @@ static int m25p_probe(struct spi_device
return -EINVAL;
}
create mode 100644 arch/mips/include/asm/mach-ralink/gpio.h
create mode 100644 drivers/gpio/gpio-ralink.c
-Index: linux-3.14.18/arch/mips/include/asm/mach-ralink/gpio.h
-===================================================================
---- /dev/null 1970-01-01 00:00:00.000000000 +0000
-+++ linux-3.14.18/arch/mips/include/asm/mach-ralink/gpio.h 2014-09-13 02:13:22.536816660 +0200
+--- /dev/null
++++ b/arch/mips/include/asm/mach-ralink/gpio.h
@@ -0,0 +1,24 @@
+/*
+ * Ralink SoC GPIO API support
+#define gpio_to_irq __gpio_to_irq
+
+#endif /* __ASM_MACH_RALINK_GPIO_H */
-Index: linux-3.14.18/drivers/gpio/Kconfig
-===================================================================
---- linux-3.14.18.orig/drivers/gpio/Kconfig 2014-09-06 01:34:59.000000000 +0200
-+++ linux-3.14.18/drivers/gpio/Kconfig 2014-10-02 21:52:28.693719524 +0200
-@@ -260,6 +260,12 @@
+--- a/drivers/gpio/Kconfig
++++ b/drivers/gpio/Kconfig
+@@ -260,6 +260,12 @@ config GPIO_SCH311X
To compile this driver as a module, choose M here: the module will
be called gpio-sch311x.
config GPIO_SPEAR_SPICS
bool "ST SPEAr13xx SPI Chip Select as GPIO support"
depends on PLAT_SPEAR
-Index: linux-3.14.18/drivers/gpio/Makefile
-===================================================================
---- linux-3.14.18.orig/drivers/gpio/Makefile 2014-09-06 01:34:59.000000000 +0200
-+++ linux-3.14.18/drivers/gpio/Makefile 2014-10-02 21:52:28.693719524 +0200
-@@ -63,6 +63,7 @@
+--- a/drivers/gpio/Makefile
++++ b/drivers/gpio/Makefile
+@@ -63,6 +63,7 @@ obj-$(CONFIG_GPIO_PCF857X) += gpio-pcf85
obj-$(CONFIG_GPIO_PCH) += gpio-pch.o
obj-$(CONFIG_GPIO_PL061) += gpio-pl061.o
obj-$(CONFIG_GPIO_PXA) += gpio-pxa.o
obj-$(CONFIG_GPIO_RC5T583) += gpio-rc5t583.o
obj-$(CONFIG_GPIO_RDC321X) += gpio-rdc321x.o
obj-$(CONFIG_GPIO_RCAR) += gpio-rcar.o
-Index: linux-3.14.18/drivers/gpio/gpio-ralink.c
-===================================================================
---- /dev/null 1970-01-01 00:00:00.000000000 +0000
-+++ linux-3.14.18/drivers/gpio/gpio-ralink.c 2014-10-02 21:52:24.081719605 +0200
+--- /dev/null
++++ b/drivers/gpio/gpio-ralink.c
@@ -0,0 +1,353 @@
+/*
+ * This program is free software; you can redistribute it and/or modify it
4 files changed, 187 insertions(+)
create mode 100644 drivers/gpio/gpio-mt7621.c
-Index: linux-3.14.18/arch/mips/Kconfig
-===================================================================
---- linux-3.14.18.orig/arch/mips/Kconfig 2014-11-14 14:22:08.782141921 +0100
-+++ linux-3.14.18/arch/mips/Kconfig 2014-11-14 14:22:08.994149701 +0100
-@@ -437,6 +437,9 @@
+--- a/arch/mips/Kconfig
++++ b/arch/mips/Kconfig
+@@ -437,6 +437,9 @@ config RALINK
select RESET_CONTROLLER
select PINCTRL
select PINCTRL_RT2880
config SGI_IP22
bool "SGI IP22 (Indy/Indigo2)"
-Index: linux-3.14.18/drivers/gpio/Kconfig
-===================================================================
---- linux-3.14.18.orig/drivers/gpio/Kconfig 2014-11-14 14:22:08.982149261 +0100
-+++ linux-3.14.18/drivers/gpio/Kconfig 2014-11-14 14:22:08.998149848 +0100
-@@ -827,6 +827,12 @@
+--- a/drivers/gpio/Kconfig
++++ b/drivers/gpio/Kconfig
+@@ -827,6 +827,12 @@ config GPIO_BCM_KONA
help
Turn on GPIO support for Broadcom "Kona" chips.
comment "USB GPIO expanders:"
config GPIO_VIPERBOARD
-Index: linux-3.14.18/drivers/gpio/Makefile
-===================================================================
---- linux-3.14.18.orig/drivers/gpio/Makefile 2014-11-14 14:22:08.982149261 +0100
-+++ linux-3.14.18/drivers/gpio/Makefile 2014-11-14 14:22:08.998149848 +0100
-@@ -100,3 +100,4 @@
+--- a/drivers/gpio/Makefile
++++ b/drivers/gpio/Makefile
+@@ -100,3 +100,4 @@ obj-$(CONFIG_GPIO_WM8350) += gpio-wm8350
obj-$(CONFIG_GPIO_WM8994) += gpio-wm8994.o
obj-$(CONFIG_GPIO_XILINX) += gpio-xilinx.o
obj-$(CONFIG_GPIO_XTENSA) += gpio-xtensa.o
+obj-$(CONFIG_GPIO_MT7621) += gpio-mt7621.o
-Index: linux-3.14.18/drivers/gpio/gpio-mt7621.c
-===================================================================
---- /dev/null 1970-01-01 00:00:00.000000000 +0000
-+++ linux-3.14.18/drivers/gpio/gpio-mt7621.c 2014-11-14 14:36:19.321724539 +0100
+--- /dev/null
++++ b/drivers/gpio/gpio-mt7621.c
@@ -0,0 +1,178 @@
+/*
+ * This program is free software; you can redistribute it and/or modify it
create mode 100644 Documentation/devicetree/bindings/i2c/i2c-ralink.txt
create mode 100644 drivers/i2c/busses/i2c-ralink.c
-Index: linux-3.14.18/Documentation/devicetree/bindings/i2c/i2c-ralink.txt
-===================================================================
---- /dev/null 1970-01-01 00:00:00.000000000 +0000
-+++ linux-3.14.18/Documentation/devicetree/bindings/i2c/i2c-ralink.txt 2014-10-06 14:28:14.296590159 +0200
+--- /dev/null
++++ b/Documentation/devicetree/bindings/i2c/i2c-ralink.txt
@@ -0,0 +1,27 @@
+I2C for Ralink platforms
+
+ };
+ };
+};
-Index: linux-3.14.18/drivers/i2c/busses/Kconfig
-===================================================================
---- linux-3.14.18.orig/drivers/i2c/busses/Kconfig 2014-09-06 01:34:59.000000000 +0200
-+++ linux-3.14.18/drivers/i2c/busses/Kconfig 2014-10-06 14:28:14.296590159 +0200
-@@ -659,6 +659,10 @@
+--- a/drivers/i2c/busses/Kconfig
++++ b/drivers/i2c/busses/Kconfig
+@@ -659,6 +659,10 @@ config I2C_RIIC
This driver can also be built as a module. If so, the module
will be called i2c-riic.
config HAVE_S3C2410_I2C
bool
help
-Index: linux-3.14.18/drivers/i2c/busses/Makefile
-===================================================================
---- linux-3.14.18.orig/drivers/i2c/busses/Makefile 2014-09-06 01:34:59.000000000 +0200
-+++ linux-3.14.18/drivers/i2c/busses/Makefile 2014-10-06 14:28:14.296590159 +0200
-@@ -63,6 +63,7 @@
+--- a/drivers/i2c/busses/Makefile
++++ b/drivers/i2c/busses/Makefile
+@@ -63,6 +63,7 @@ obj-$(CONFIG_I2C_PNX) += i2c-pnx.o
obj-$(CONFIG_I2C_PUV3) += i2c-puv3.o
obj-$(CONFIG_I2C_PXA) += i2c-pxa.o
obj-$(CONFIG_I2C_PXA_PCI) += i2c-pxa-pci.o
obj-$(CONFIG_I2C_RIIC) += i2c-riic.o
obj-$(CONFIG_I2C_S3C2410) += i2c-s3c2410.o
obj-$(CONFIG_I2C_S6000) += i2c-s6000.o
-Index: linux-3.14.18/drivers/i2c/busses/i2c-ralink.c
-===================================================================
---- /dev/null 1970-01-01 00:00:00.000000000 +0000
-+++ linux-3.14.18/drivers/i2c/busses/i2c-ralink.c 2014-10-09 19:38:29.242416182 +0200
+--- /dev/null
++++ b/drivers/i2c/busses/i2c-ralink.c
@@ -0,0 +1,299 @@
+/*
+ * drivers/i2c/busses/i2c-ralink.c
create mode 100644 drivers/mmc/host/mtk-mmc/mt6575_sd.h
create mode 100644 drivers/mmc/host/mtk-mmc/sd.c
-Index: linux-3.14.18/drivers/mmc/host/Kconfig
-===================================================================
---- linux-3.14.18.orig/drivers/mmc/host/Kconfig 2014-11-15 14:13:20.210278242 +0100
-+++ linux-3.14.18/drivers/mmc/host/Kconfig 2014-11-15 14:13:20.998305852 +0100
-@@ -714,3 +714,5 @@
+--- a/drivers/mmc/host/Kconfig
++++ b/drivers/mmc/host/Kconfig
+@@ -714,3 +714,5 @@ config MMC_REALTEK_PCI
help
Say Y here to include driver code to support SD/MMC card interface
of Realtek PCI-E card reader
+
+source "drivers/mmc/host/mtk-mmc/Kconfig"
-Index: linux-3.14.18/drivers/mmc/host/Makefile
-===================================================================
---- linux-3.14.18.orig/drivers/mmc/host/Makefile 2014-11-15 14:13:20.210278242 +0100
-+++ linux-3.14.18/drivers/mmc/host/Makefile 2014-11-15 14:13:20.998305852 +0100
+--- a/drivers/mmc/host/Makefile
++++ b/drivers/mmc/host/Makefile
@@ -2,6 +2,7 @@
# Makefile for MMC/SD host controller drivers
#
obj-$(CONFIG_MMC_ARMMMCI) += mmci.o
obj-$(CONFIG_MMC_PXA) += pxamci.o
obj-$(CONFIG_MMC_MXC) += mxcmmc.o
-Index: linux-3.14.18/drivers/mmc/host/mtk-mmc/Kconfig
-===================================================================
---- /dev/null 1970-01-01 00:00:00.000000000 +0000
-+++ linux-3.14.18/drivers/mmc/host/mtk-mmc/Kconfig 2014-11-15 14:13:20.998305852 +0100
+--- /dev/null
++++ b/drivers/mmc/host/mtk-mmc/Kconfig
@@ -0,0 +1,16 @@
+config MTK_MMC
+ tristate "MTK SD/MMC"
+ bool "eMMC 8-bit support"
+ depends on MTK_MMC && RALINK_MT7628
+
-Index: linux-3.14.18/drivers/mmc/host/mtk-mmc/Makefile
-===================================================================
---- /dev/null 1970-01-01 00:00:00.000000000 +0000
-+++ linux-3.14.18/drivers/mmc/host/mtk-mmc/Makefile 2014-11-15 14:13:20.998305852 +0100
+--- /dev/null
++++ b/drivers/mmc/host/mtk-mmc/Makefile
@@ -0,0 +1,42 @@
+# Copyright Statement:
+#
+
+clean:
+ @rm -f *.o modules.order .*.cmd
-Index: linux-3.14.18/drivers/mmc/host/mtk-mmc/board.h
-===================================================================
---- /dev/null 1970-01-01 00:00:00.000000000 +0000
-+++ linux-3.14.18/drivers/mmc/host/mtk-mmc/board.h 2014-11-15 14:13:20.998305852 +0100
+--- /dev/null
++++ b/drivers/mmc/host/mtk-mmc/board.h
@@ -0,0 +1,137 @@
+/* Copyright Statement:
+ *
+
+#endif /* __ARCH_ARM_MACH_BOARD_H */
+
-Index: linux-3.14.18/drivers/mmc/host/mtk-mmc/dbg.c
-===================================================================
---- /dev/null 1970-01-01 00:00:00.000000000 +0000
-+++ linux-3.14.18/drivers/mmc/host/mtk-mmc/dbg.c 2014-11-15 14:13:20.998305852 +0100
+--- /dev/null
++++ b/drivers/mmc/host/mtk-mmc/dbg.c
@@ -0,0 +1,347 @@
+/* Copyright Statement:
+ *
+}
+EXPORT_SYMBOL_GPL(msdc_debug_proc_init);
+#endif
-Index: linux-3.14.18/drivers/mmc/host/mtk-mmc/dbg.h
-===================================================================
---- /dev/null 1970-01-01 00:00:00.000000000 +0000
-+++ linux-3.14.18/drivers/mmc/host/mtk-mmc/dbg.h 2014-11-15 14:13:20.998305852 +0100
+--- /dev/null
++++ b/drivers/mmc/host/mtk-mmc/dbg.h
@@ -0,0 +1,156 @@
+/* Copyright Statement:
+ *
+void msdc_performance(u32 opcode, u32 sizes, u32 bRx, u32 ticks);
+
+#endif
-Index: linux-3.14.18/drivers/mmc/host/mtk-mmc/mt6575_sd.h
-===================================================================
---- /dev/null 1970-01-01 00:00:00.000000000 +0000
-+++ linux-3.14.18/drivers/mmc/host/mtk-mmc/mt6575_sd.h 2014-11-15 14:13:20.998305852 +0100
+--- /dev/null
++++ b/drivers/mmc/host/mtk-mmc/mt6575_sd.h
@@ -0,0 +1,1001 @@
+/* Copyright Statement:
+ *
+
+#endif
+
-Index: linux-3.14.18/drivers/mmc/host/mtk-mmc/sd.c
-===================================================================
---- /dev/null 1970-01-01 00:00:00.000000000 +0000
-+++ linux-3.14.18/drivers/mmc/host/mtk-mmc/sd.c 2014-11-15 14:41:50.334227875 +0100
+--- /dev/null
++++ b/drivers/mmc/host/mtk-mmc/sd.c
@@ -0,0 +1,3047 @@
+/* Copyright Statement:
+ *
create mode 100644 sound/soc/ralink/mt7620-i2s.c
create mode 100644 sound/soc/ralink/mt7620-wm8960.c
-Index: linux-3.14.18/arch/mips/ralink/of.c
-===================================================================
---- linux-3.14.18.orig/arch/mips/ralink/of.c 2014-11-18 10:45:55.010989756 +0100
-+++ linux-3.14.18/arch/mips/ralink/of.c 2014-11-18 13:54:21.586438562 +0100
+--- a/arch/mips/ralink/of.c
++++ b/arch/mips/ralink/of.c
@@ -15,6 +15,7 @@
#include <linux/of_fdt.h>
#include <linux/kernel.h>
__iomem void *rt_memc_membase;
extern struct boot_param_header __dtb_start;
-Index: linux-3.14.18/sound/soc/Kconfig
-===================================================================
---- linux-3.14.18.orig/sound/soc/Kconfig 2014-09-06 01:34:59.000000000 +0200
-+++ linux-3.14.18/sound/soc/Kconfig 2014-11-18 10:45:55.351159766 +0100
-@@ -47,6 +47,7 @@
+--- a/sound/soc/Kconfig
++++ b/sound/soc/Kconfig
+@@ -47,6 +47,7 @@ source "sound/soc/kirkwood/Kconfig"
source "sound/soc/intel/Kconfig"
source "sound/soc/mxs/Kconfig"
source "sound/soc/pxa/Kconfig"
source "sound/soc/samsung/Kconfig"
source "sound/soc/s6000/Kconfig"
source "sound/soc/sh/Kconfig"
-Index: linux-3.14.18/sound/soc/Makefile
-===================================================================
---- linux-3.14.18.orig/sound/soc/Makefile 2014-09-06 01:34:59.000000000 +0200
-+++ linux-3.14.18/sound/soc/Makefile 2014-11-18 10:45:55.351159766 +0100
-@@ -24,6 +24,7 @@
+--- a/sound/soc/Makefile
++++ b/sound/soc/Makefile
+@@ -24,6 +24,7 @@ obj-$(CONFIG_SND_SOC) += nuc900/
obj-$(CONFIG_SND_SOC) += omap/
obj-$(CONFIG_SND_SOC) += kirkwood/
obj-$(CONFIG_SND_SOC) += pxa/
obj-$(CONFIG_SND_SOC) += samsung/
obj-$(CONFIG_SND_SOC) += s6000/
obj-$(CONFIG_SND_SOC) += sh/
-Index: linux-3.14.18/sound/soc/ralink/Kconfig
-===================================================================
---- /dev/null 1970-01-01 00:00:00.000000000 +0000
-+++ linux-3.14.18/sound/soc/ralink/Kconfig 2014-11-18 10:45:55.351159766 +0100
+--- /dev/null
++++ b/sound/soc/ralink/Kconfig
@@ -0,0 +1,15 @@
+config SND_MT7620_SOC_I2S
+ depends on SOC_MT7620 && SND_SOC
+ help
+ Say Y if you want to add support for ASoC audio on the Qi LB60 board
+ a.k.a Qi Ben NanoNote.
-Index: linux-3.14.18/sound/soc/ralink/Makefile
-===================================================================
---- /dev/null 1970-01-01 00:00:00.000000000 +0000
-+++ linux-3.14.18/sound/soc/ralink/Makefile 2014-11-18 10:45:55.351159766 +0100
+--- /dev/null
++++ b/sound/soc/ralink/Makefile
@@ -0,0 +1,11 @@
+#
+# Jz4740 Platform Support
+snd-soc-mt7620-wm8960-objs := mt7620-wm8960.o
+
+obj-$(CONFIG_SND_MT7620_SOC_WM8960) += snd-soc-mt7620-wm8960.o
-Index: linux-3.14.18/sound/soc/ralink/mt7620-i2s.c
-===================================================================
---- /dev/null 1970-01-01 00:00:00.000000000 +0000
-+++ linux-3.14.18/sound/soc/ralink/mt7620-i2s.c 2014-11-18 10:45:55.351159766 +0100
+--- /dev/null
++++ b/sound/soc/ralink/mt7620-i2s.c
@@ -0,0 +1,436 @@
+/*
+ * Copyright (C) 2010, Lars-Peter Clausen <lars@metafoo.de>
+MODULE_DESCRIPTION("Ingenic JZ4740 SoC I2S driver");
+MODULE_LICENSE("GPL");
+MODULE_ALIAS("platform:mt7620-i2s");
-Index: linux-3.14.18/sound/soc/ralink/mt7620-wm8960.c
-===================================================================
---- /dev/null 1970-01-01 00:00:00.000000000 +0000
-+++ linux-3.14.18/sound/soc/ralink/mt7620-wm8960.c 2014-11-18 11:56:57.570299500 +0100
+--- /dev/null
++++ b/sound/soc/ralink/mt7620-wm8960.c
@@ -0,0 +1,233 @@
+/*
+ * Copyright 2013 Freescale Semiconductor, Inc.
+MODULE_DESCRIPTION("Freescale i.MX WM8962 ASoC machine driver");
+MODULE_LICENSE("GPL v2");
+MODULE_ALIAS("platform:mt7620-wm8962");
-Index: linux-3.14.18/sound/soc/soc-io.c
-===================================================================
---- linux-3.14.18.orig/sound/soc/soc-io.c 2014-09-06 01:34:59.000000000 +0200
-+++ linux-3.14.18/sound/soc/soc-io.c 2014-11-18 10:45:55.355161766 +0100
+--- a/sound/soc/soc-io.c
++++ b/sound/soc/soc-io.c
@@ -19,7 +19,6 @@
#include <trace/events/asoc.h>
static int hw_write(struct snd_soc_codec *codec, unsigned int reg,
unsigned int value)
{
-@@ -135,12 +134,3 @@
+@@ -135,12 +134,3 @@ int snd_soc_codec_set_cache_io(struct sn
return PTR_ERR_OR_ZERO(codec->control_data);
}
EXPORT_SYMBOL_GPL(snd_soc_codec_set_cache_io);
--- a/drivers/media/usb/uvc/uvc_driver.c
+++ b/drivers/media/usb/uvc/uvc_driver.c
-@@ -2467,6 +2467,20 @@ static struct usb_device_id uvc_ids[] =
+@@ -2476,6 +2476,20 @@ static struct usb_device_id uvc_ids[] =
.bInterfaceProtocol = 0,
.driver_info = UVC_QUIRK_PROBE_MINMAX
| UVC_QUIRK_IGNORE_SELECTOR_UNIT },
-Index: linux-3.14.18/arch/mips/include/asm/mach-ralink/mt7620.h
-===================================================================
---- linux-3.14.18.orig/arch/mips/include/asm/mach-ralink/mt7620.h 2014-11-17 19:54:59.683128174 +0100
-+++ linux-3.14.18/arch/mips/include/asm/mach-ralink/mt7620.h 2014-11-17 19:54:59.975139185 +0100
+--- a/arch/mips/include/asm/mach-ralink/mt7620.h
++++ b/arch/mips/include/asm/mach-ralink/mt7620.h
@@ -13,14 +13,6 @@
#ifndef _MT7620_REGS_H_
#define _MT7620_REGS_H_
#define MT7620_SYSC_BASE 0x10000000
#define SYSC_REG_CHIP_NAME0 0x00
-Index: linux-3.14.18/arch/mips/include/asm/mach-ralink/ralink_regs.h
-===================================================================
---- linux-3.14.18.orig/arch/mips/include/asm/mach-ralink/ralink_regs.h 2014-11-17 19:54:59.379116714 +0100
-+++ linux-3.14.18/arch/mips/include/asm/mach-ralink/ralink_regs.h 2014-11-17 19:54:59.975139185 +0100
+--- a/arch/mips/include/asm/mach-ralink/ralink_regs.h
++++ b/arch/mips/include/asm/mach-ralink/ralink_regs.h
@@ -13,6 +13,20 @@
#ifndef _RALINK_REGS_H_
#define _RALINK_REGS_H_
extern __iomem void *rt_sysc_membase;
extern __iomem void *rt_memc_membase;
-Index: linux-3.14.18/arch/mips/include/asm/mach-ralink/rt305x.h
-===================================================================
---- linux-3.14.18.orig/arch/mips/include/asm/mach-ralink/rt305x.h 2014-11-17 19:54:59.663127421 +0100
-+++ linux-3.14.18/arch/mips/include/asm/mach-ralink/rt305x.h 2014-11-17 19:54:59.975139185 +0100
+--- a/arch/mips/include/asm/mach-ralink/rt305x.h
++++ b/arch/mips/include/asm/mach-ralink/rt305x.h
@@ -13,25 +13,16 @@
#ifndef _RT305X_REGS_H_
#define _RT305X_REGS_H_
}
static inline int soc_is_rt305x(void)
-@@ -41,17 +32,17 @@
+@@ -41,17 +32,17 @@ static inline int soc_is_rt305x(void)
static inline int soc_is_rt3350(void)
{
}
#define RT305X_SYSC_BASE 0x10000000
-Index: linux-3.14.18/arch/mips/ralink/mt7620.c
-===================================================================
---- linux-3.14.18.orig/arch/mips/ralink/mt7620.c 2014-11-17 19:54:59.663127421 +0100
-+++ linux-3.14.18/arch/mips/ralink/mt7620.c 2014-11-17 19:54:59.975139185 +0100
+--- a/arch/mips/ralink/mt7620.c
++++ b/arch/mips/ralink/mt7620.c
@@ -43,8 +43,6 @@
#define CLKCFG_FFRAC_MASK 0x001f
#define CLKCFG_FFRAC_USB_VAL 0x0003
/* does the board have sdram or ddram */
static int dram_type;
-@@ -375,7 +373,7 @@
+@@ -375,7 +373,7 @@ void __init ralink_clk_init(void)
#define RINT(x) ((x) / 1000000)
#define RFRAC(x) (((x) / 1000) % 1000)
if (xtal_rate == MHZ(40))
cpu_rate = MHZ(580);
else
-@@ -418,7 +416,7 @@
+@@ -418,7 +416,7 @@ void __init ralink_clk_init(void)
ralink_clk_add("10000c00.uartlite", periph_rate);
ralink_clk_add("10180000.wmac", xtal_rate);
/*
* When the CPU goes into sleep mode, the BUS clock will be too low for
* USB to function properly
-@@ -506,11 +504,11 @@
+@@ -506,11 +504,11 @@ void prom_soc_init(struct ralink_soc_inf
if (n0 == MT7620_CHIP_NAME0 && n1 == MT7620_CHIP_NAME1) {
if (bga) {
name = "MT7620N";
soc_info->compatible = "ralink,mt7620n-soc";
#ifdef CONFIG_PCI
-@@ -518,7 +516,7 @@
+@@ -518,7 +516,7 @@ void prom_soc_init(struct ralink_soc_inf
#endif
}
} else if (n0 == MT7620_CHIP_NAME0 && n1 == MT7628_CHIP_NAME1) {
name = "MT7628AN";
soc_info->compatible = "ralink,mt7628an-soc";
} else {
-@@ -535,7 +533,7 @@
+@@ -535,7 +533,7 @@ void prom_soc_init(struct ralink_soc_inf
dram_type = (cfg0 >> SYSCFG0_DRAM_TYPE_SHIFT) & SYSCFG0_DRAM_TYPE_MASK;
soc_info->mem_base = MT7620_DRAM_BASE;
mt7628_dram_init(soc_info);
else
mt7620_dram_init(soc_info);
-@@ -548,7 +546,7 @@
+@@ -548,7 +546,7 @@ void prom_soc_init(struct ralink_soc_inf
pr_info("Digital PMU set to %s control\n",
(pmu1 & DIG_SW_SEL) ? ("sw") : ("hw"));
rt2880_pinmux_data = mt7628an_pinmux_data;
else
rt2880_pinmux_data = mt7620a_pinmux_data;
-Index: linux-3.14.18/arch/mips/ralink/rt305x.c
-===================================================================
---- linux-3.14.18.orig/arch/mips/ralink/rt305x.c 2014-11-17 19:54:59.715129381 +0100
-+++ linux-3.14.18/arch/mips/ralink/rt305x.c 2014-11-17 19:54:59.975139185 +0100
+--- a/arch/mips/ralink/rt305x.c
++++ b/arch/mips/ralink/rt305x.c
@@ -21,8 +21,6 @@
#include "common.h"
static struct rt2880_pmx_func i2c_func[] = { FUNC("i2c", 0, 1, 2) };
static struct rt2880_pmx_func spi_func[] = { FUNC("spi", 0, 3, 4) };
static struct rt2880_pmx_func uartf_func[] = {
-@@ -234,24 +232,24 @@
+@@ -234,24 +232,24 @@ void prom_soc_init(struct ralink_soc_inf
icache_sets = (read_c0_config1() >> 22) & 7;
if (icache_sets == 1) {
name = "RT5350";
soc_info->compatible = "ralink,rt5350-soc";
} else {
-Index: linux-3.14.18/arch/mips/ralink/prom.c
-===================================================================
---- linux-3.14.18.orig/arch/mips/ralink/prom.c 2014-09-06 01:34:59.000000000 +0200
-+++ linux-3.14.18/arch/mips/ralink/prom.c 2014-11-17 19:54:59.975139185 +0100
+--- a/arch/mips/ralink/prom.c
++++ b/arch/mips/ralink/prom.c
@@ -15,9 +15,13 @@
#include <asm/bootinfo.h>
#include <asm/addrspace.h>
const char *get_system_type(void)
{
-Index: linux-3.14.18/arch/mips/ralink/mt7621.c
-===================================================================
---- linux-3.14.18.orig/arch/mips/ralink/mt7621.c 2014-11-17 19:54:59.471120181 +0100
-+++ linux-3.14.18/arch/mips/ralink/mt7621.c 2014-11-17 19:58:52.667916008 +0100
-@@ -175,6 +175,7 @@
+--- a/arch/mips/ralink/mt7621.c
++++ b/arch/mips/ralink/mt7621.c
+@@ -175,6 +175,7 @@ void prom_soc_init(struct ralink_soc_inf
soc_info->mem_size_min = MT7621_DDR2_SIZE_MIN;
soc_info->mem_size_max = MT7621_DDR2_SIZE_MAX;
soc_info->mem_base = MT7621_DRAM_BASE;
--- a/drivers/mtd/mtdpart.c
+++ b/drivers/mtd/mtdpart.c
-@@ -807,10 +807,6 @@ static void split_uimage(struct mtd_info
+@@ -808,10 +808,6 @@ static void split_uimage(struct mtd_info
return;
len = be32_to_cpu(hdr.size) + 0x40;
--- a/drivers/mtd/mtdpart.c
+++ b/drivers/mtd/mtdpart.c
-@@ -795,8 +795,11 @@ static void split_uimage(struct mtd_info
+@@ -796,8 +796,11 @@ static void split_uimage(struct mtd_info
{
struct {
__be32 magic;
} hdr;
size_t len;
-@@ -806,7 +809,11 @@ static void split_uimage(struct mtd_info
+@@ -807,7 +810,11 @@ static void split_uimage(struct mtd_info
if (len != sizeof(hdr) || hdr.magic != cpu_to_be32(UBOOT_MAGIC))
return;
unsigned count = 0;
u8 *rx = xfer->rx_buf;
const u8 *tx = xfer->tx_buf;
-@@ -279,9 +335,9 @@ rt2880_spi_write_read(struct spi_device
+@@ -279,9 +335,9 @@ rt2880_spi_write_read(struct spi_device
if (tx) {
for (count = 0; count < xfer->len; count++) {
if (err) {
dev_err(&spi->dev, "TX failed, err=%d\n", err);
goto out;
-@@ -291,13 +347,13 @@ rt2880_spi_write_read(struct spi_device
+@@ -291,13 +347,13 @@ rt2880_spi_write_read(struct spi_device
if (rx) {
for (count = 0; count < xfer->len; count++) {
}
}
-@@ -364,7 +420,7 @@ mt7621_spi_write_read(struct spi_device
+@@ -364,7 +420,7 @@ mt7621_spi_write_read(struct spi_device
trans |= SPI_CTL_START;
rt2880_spi_write(rs, MT7621_SPI_TRANS, trans);
-Index: linux-3.14.18/arch/mips/ralink/reset.c
-===================================================================
---- linux-3.14.18.orig/arch/mips/ralink/reset.c 2014-09-06 01:34:59.000000000 +0200
-+++ linux-3.14.18/arch/mips/ralink/reset.c 2014-11-14 14:28:44.548764125 +0100
-@@ -98,7 +98,6 @@
+--- a/arch/mips/ralink/reset.c
++++ b/arch/mips/ralink/reset.c
+@@ -98,7 +98,6 @@ static int __init mips_reboot_setup(void
{
_machine_restart = ralink_restart;
_machine_halt = ralink_halt;
-Index: linux-3.14.18/arch/mips/ralink/mt7620.c
-===================================================================
---- linux-3.14.18.orig/arch/mips/ralink/mt7620.c 2014-11-18 20:57:21.506801623 +0100
-+++ linux-3.14.18/arch/mips/ralink/mt7620.c 2014-11-18 22:12:05.133116492 +0100
-@@ -511,9 +511,6 @@
+--- a/arch/mips/ralink/mt7620.c
++++ b/arch/mips/ralink/mt7620.c
+@@ -511,9 +511,6 @@ void prom_soc_init(struct ralink_soc_inf
ralink_soc = MT762X_SOC_MT7620N;
name = "MT7620N";
soc_info->compatible = "ralink,mt7620n-soc";
-Index: linux-3.14.18/arch/mips/ralink/reset.c
-===================================================================
---- linux-3.14.18.orig/arch/mips/ralink/reset.c 2014-11-23 00:32:23.268612766 +0100
-+++ linux-3.14.18/arch/mips/ralink/reset.c 2014-11-23 02:55:41.492326840 +0100
+--- a/arch/mips/ralink/reset.c
++++ b/arch/mips/ralink/reset.c
@@ -11,6 +11,7 @@
#include <linux/pm.h>
#include <linux/io.h>
static int ralink_assert_device(struct reset_controller_dev *rcdev,
unsigned long id)
-@@ -83,6 +86,11 @@
+@@ -83,6 +86,11 @@ void ralink_rst_init(void)
static void ralink_restart(char *command)
{
--- a/arch/mips/rb532/prom.c
+++ b/arch/mips/rb532/prom.c
-@@ -67,6 +67,7 @@ static inline unsigned long tag2ul(char
+@@ -67,6 +67,7 @@ static inline unsigned long tag2ul(char
return simple_strtoul(num, 0, 10);
}
---- a/arch/mips/rb532/devices.c 2014-07-07 01:05:10.000000000 +0300
-+++ b/arch/mips/rb532/devices.c 2014-07-07 01:05:27.268505016 +0300
+--- a/arch/mips/rb532/devices.c
++++ b/arch/mips/rb532/devices.c
@@ -202,7 +202,7 @@ static struct mtd_partition rb532_partit
.offset = 0,
.size = 4 * 1024 * 1024,
-diff -ruN old/arch/arm/boot/dts/sun7i-a20-cubietruck.dts new/arch/arm/boot/dts/sun7i-a20-cubietruck.dts
---- old/arch/arm/boot/dts/sun7i-a20-cubietruck.dts 2014-09-06 01:34:59.000000000 +0200
-+++ new/arch/arm/boot/dts/sun7i-a20-cubietruck.dts 2014-11-04 22:14:48.756886672 +0100
+--- a/arch/arm/boot/dts/sun7i-a20-cubietruck.dts
++++ b/arch/arm/boot/dts/sun7i-a20-cubietruck.dts
@@ -26,6 +26,20 @@
allwinner,drive = <0>;
allwinner,pull = <0>;
--- a/arch/arm/boot/dts/sun7i-a20-cubietruck.dts
+++ b/arch/arm/boot/dts/sun7i-a20-cubietruck.dts
-@@ -47,6 +47,18 @@
- pinctrl-0 = <&uart0_pins_a>;
+@@ -65,6 +65,18 @@
+ pinctrl-0 = <&i2c2_pins_a>;
status = "okay";
};
+
emac: ethernet@01c0b000 {
compatible = "allwinner,sun4i-a10-emac";
reg = <0x01c0b000 0x1000>;
-@@ -415,6 +437,28 @@
- status = "disabled";
- #address-cells = <1>;
+@@ -417,6 +439,28 @@
#size-cells = <0>;
-+ };
-+
+ };
+
+ spi2: spi@01c17000 {
+ compatible = "allwinner,sun4i-a10-spi";
+ reg = <0x01c17000 0x1000>;
+ status = "disabled";
+ #address-cells = <1>;
+ #size-cells = <0>;
- };
-
++ };
++
pio: pinctrl@01c20800 {
+ compatible = "allwinner,sun7i-a20-pinctrl";
+ reg = <0x01c20800 0x400>;
emac: ethernet@01c0b000 {
compatible = "allwinner,sun4i-a10-emac";
reg = <0x01c0b000 0x1000>;
-@@ -353,6 +375,28 @@
- status = "disabled";
- #address-cells = <1>;
+@@ -355,6 +377,28 @@
#size-cells = <0>;
-+ };
-+
+ };
+
+ spi2: spi@01c17000 {
+ compatible = "allwinner,sun4i-a10-spi";
+ reg = <0x01c17000 0x1000>;
+ status = "disabled";
+ #address-cells = <1>;
+ #size-cells = <0>;
- };
-
++ };
++
intc: interrupt-controller@01c20400 {
+ compatible = "allwinner,sun4i-ic";
+ reg = <0x01c20400 0x400>;
led_pins_cubietruck: led_pins@0 {
allwinner,pins = "PH7", "PH11", "PH20", "PH21";
allwinner,function = "gpio_out";
-@@ -86,4 +99,10 @@
+@@ -104,4 +117,10 @@
gpios = <&pio 7 7 0>;
};
};
arch/arm/mach-sunxi/sunxi.c | 2 ++
1 file changed, 2 insertions(+)
-diff --git a/arch/arm/mach-sunxi/sunxi.c b/arch/arm/mach-sunxi/sunxi.c
-index aeea6ce..c310df6 100644
--- a/arch/arm/mach-sunxi/sunxi.c
+++ b/arch/arm/mach-sunxi/sunxi.c
-@@ -95,7 +95,9 @@ static void sun6i_restart(enum reboot_mode mode, const char *cmd)
+@@ -95,7 +95,9 @@ static void sun6i_restart(enum reboot_mo
static struct of_device_id sunxi_restart_ids[] = {
{ .compatible = "allwinner,sun4i-wdt" },
pinctrl@01c20800 {
ahci_pwr_pin_cubietruck: ahci_pwr_pin@1 {
allwinner,pins = "PH12";
-@@ -105,4 +127,12 @@
+@@ -123,4 +145,12 @@
gpio = <&pio 7 12 0>;
status = "okay";
};
--- a/drivers/ata/ahci.c
+++ b/drivers/ata/ahci.c
-@@ -583,6 +583,7 @@ static int ahci_vt8251_hardreset(struct
+@@ -606,6 +606,7 @@ static int ahci_vt8251_hardreset(struct
unsigned long deadline)
{
struct ata_port *ap = link->ap;
bool online;
int rc;
-@@ -593,7 +594,7 @@ static int ahci_vt8251_hardreset(struct
+@@ -616,7 +617,7 @@ static int ahci_vt8251_hardreset(struct
rc = sata_link_hardreset(link, sata_ehc_deb_timing(&link->eh_context),
deadline, &online, NULL);
DPRINTK("EXIT, rc=%d, class=%u\n", rc, *class);
-@@ -608,6 +609,7 @@ static int ahci_p5wdh_hardreset(struct a
+@@ -631,6 +632,7 @@ static int ahci_p5wdh_hardreset(struct a
{
struct ata_port *ap = link->ap;
struct ahci_port_priv *pp = ap->private_data;
u8 *d2h_fis = pp->rx_fis + RX_FIS_D2H_REG;
struct ata_taskfile tf;
bool online;
-@@ -623,7 +625,7 @@ static int ahci_p5wdh_hardreset(struct a
+@@ -646,7 +648,7 @@ static int ahci_p5wdh_hardreset(struct a
rc = sata_link_hardreset(link, sata_ehc_deb_timing(&link->eh_context),
deadline, &online, NULL);
};
--- a/drivers/usb/host/xhci-plat.c
+++ b/drivers/usb/host/xhci-plat.c
-@@ -226,6 +226,7 @@ static const struct dev_pm_ops xhci_plat
+@@ -234,6 +234,7 @@ static const struct dev_pm_ops xhci_plat
#ifdef CONFIG_OF
static const struct of_device_id usb_xhci_of_match[] = {
--- a/drivers/irqchip/Makefile
+++ b/drivers/irqchip/Makefile
-@@ -12,6 +12,7 @@ obj-$(CONFIG_METAG_PERFCOUNTER_IRQS) +=
+@@ -12,6 +12,7 @@ obj-$(CONFIG_METAG_PERFCOUNTER_IRQS) +=
obj-$(CONFIG_ARCH_MOXART) += irq-moxart.o
obj-$(CONFIG_ORION_IRQCHIP) += irq-orion.o
obj-$(CONFIG_ARCH_SUNXI) += irq-sun4i.o
+ };
};
- gmac: ethernet@01c50000 {
+ i2c0: i2c@01c2ac00 {
--- a/arch/arm/boot/dts/sun7i-a20-olinuxino-micro.dts
+++ b/arch/arm/boot/dts/sun7i-a20-olinuxino-micro.dts
@@ -127,6 +127,16 @@
--- a/arch/arm/boot/dts/sun7i-a20-cubietruck.dts
+++ b/arch/arm/boot/dts/sun7i-a20-cubietruck.dts
-@@ -112,6 +112,24 @@
+@@ -130,6 +130,24 @@
reg = <1>;
};
};
--- a/drivers/net/wireless/brcm80211/brcmfmac/bcmsdh.c
+++ b/drivers/net/wireless/brcm80211/brcmfmac/bcmsdh.c
-@@ -827,7 +827,7 @@ brcmf_sdiod_ramrw(struct brcmf_sdio_dev
+@@ -827,7 +827,7 @@ brcmf_sdiod_ramrw(struct brcmf_sdio_dev
}
if (!write)
memcpy(data, pkt->data, dsize);
skb_trim(pkt, pkt->len - tail_chop);
skb_trim(pkt_pad, tail_pad + tail_chop);
__skb_queue_after(pktq, pkt, pkt_pad);
-@@ -2003,7 +2003,7 @@ brcmf_sdio_txpkt_prep(struct brcmf_sdio
+@@ -2003,7 +2003,7 @@ brcmf_sdio_txpkt_prep(struct brcmf_sdio
* already properly aligned and does not
* need an sdpcm header.
*/
if (dummy_flags & ALIGN_SKB_FLAG) {
chop_len = dummy_flags & ALIGN_SKB_CHOP_LEN_MASK;
if (chop_len) {
-@@ -2554,6 +2554,8 @@ static int brcmf_sdio_bus_txdata(struct
+@@ -2554,6 +2554,8 @@ static int brcmf_sdio_bus_txdata(struct
/* Priority based enq */
spin_lock_irqsave(&bus->txqlock, flags);
ahci_pwr_pin_cubietruck: ahci_pwr_pin@1 {
allwinner,pins = "PH12";
allwinner,function = "gpio_out";
-@@ -83,6 +112,13 @@
- allwinner,drive = <0>;
- allwinner,pull = <2>;
+@@ -99,6 +128,13 @@
+
+ /include/ "x-powers-axp209.dtsi"
};
+
+ wifi_host_wake_pin: wifi_host_wake_pin@0 {
+ };
};
- uart0: serial@01c28000 {
-@@ -171,4 +207,15 @@
+ i2c0: i2c@01c2ac00 {
+@@ -189,4 +225,15 @@
reg_usb2_vbus: usb2-vbus {
status = "okay";
};
--- a/arch/arm/boot/dts/sun7i-a20-cubietruck.dts
+++ b/arch/arm/boot/dts/sun7i-a20-cubietruck.dts
-@@ -119,6 +119,20 @@
+@@ -135,6 +135,20 @@
allwinner,drive = <0>;
allwinner,pull = <0>;
};
+ };
};
- uart0: serial@01c28000 {
-@@ -149,6 +163,12 @@
+ i2c0: i2c@01c2ac00 {
+@@ -167,6 +181,12 @@
};
};
i2c0: i2c@01c2ac00 {
pinctrl-names = "default";
pinctrl-0 = <&i2c0_pins_a>;
-@@ -218,4 +238,20 @@
+@@ -236,4 +256,20 @@
enable-active-high;
gpio = <&pio 7 9 0>;
};
-diff --git a/drivers/clk/sunxi/clk-sunxi.c b/drivers/clk/sunxi/clk-sunxi.c
-index a393df1..0393f85 100644
--- a/drivers/clk/sunxi/clk-sunxi.c
+++ b/drivers/clk/sunxi/clk-sunxi.c
-@@ -326,7 +326,7 @@ static void sun4i_get_apb1_factors(u32 *freq, u32 parent_rate,
+@@ -299,7 +299,7 @@ static void sun4i_get_apb1_factors(u32 *
if (parent_rate < *freq)
*freq = parent_rate;
/* Invalid rate! */
if (parent_rate > 32)
-@@ -371,7 +371,7 @@ static void sun4i_get_mod0_factors(u32 *freq, u32 parent_rate,
+@@ -344,7 +344,7 @@ static void sun4i_get_mod0_factors(u32 *
if (*freq > parent_rate)
*freq = parent_rate;
if (div < 16)
calcp = 0;
-@@ -412,7 +412,7 @@ static void sun7i_a20_get_out_factors(u32 *freq, u32 parent_rate,
+@@ -385,7 +385,7 @@ static void sun7i_a20_get_out_factors(u3
if (*freq > parent_rate)
*freq = parent_rate;
3 files changed, 329 insertions(+)
create mode 100644 drivers/media/rc/sunxi-cir.c
-diff --git a/drivers/media/rc/Kconfig b/drivers/media/rc/Kconfig
-index 8fbd377..9427fad 100644
--- a/drivers/media/rc/Kconfig
+++ b/drivers/media/rc/Kconfig
-@@ -343,4 +343,14 @@ config RC_ST
+@@ -332,4 +332,14 @@ config RC_ST
If you're not sure, select N here.
+ be called sunxi-ir.
+
endif #RC_DEVICES
-diff --git a/drivers/media/rc/Makefile b/drivers/media/rc/Makefile
-index f8b54ff..9ee9ee7 100644
--- a/drivers/media/rc/Makefile
+++ b/drivers/media/rc/Makefile
-@@ -32,3 +32,4 @@ obj-$(CONFIG_IR_GPIO_CIR) += gpio-ir-recv.o
+@@ -31,3 +31,4 @@ obj-$(CONFIG_IR_GPIO_CIR) += gpio-ir-rec
obj-$(CONFIG_IR_IGUANA) += iguanair.o
obj-$(CONFIG_IR_TTUSBIR) += ttusbir.o
obj-$(CONFIG_RC_ST) += st_rc.o
+obj-$(CONFIG_IR_SUNXI) += sunxi-cir.o
-diff --git a/drivers/media/rc/sunxi-cir.c b/drivers/media/rc/sunxi-cir.c
-new file mode 100644
-index 0000000..5971b69
--- /dev/null
+++ b/drivers/media/rc/sunxi-cir.c
@@ -0,0 +1,318 @@
arch/arm/boot/dts/sun7i-a20.dtsi | 14 ++++++++++++++
1 file changed, 14 insertions(+)
-diff --git a/arch/arm/boot/dts/sun7i-a20.dtsi b/arch/arm/boot/dts/sun7i-a20.dtsi
-index e67e451..4e4d6ce 100644
--- a/arch/arm/boot/dts/sun7i-a20.dtsi
+++ b/arch/arm/boot/dts/sun7i-a20.dtsi
-@@ -738,6 +738,20 @@
+@@ -746,6 +746,20 @@
allwinner,drive = <2>;
allwinner,pull = <0>;
};
arch/arm/boot/dts/sun7i-a20.dtsi | 18 ++++++++++++++++++
1 file changed, 18 insertions(+)
-diff --git a/arch/arm/boot/dts/sun7i-a20.dtsi b/arch/arm/boot/dts/sun7i-a20.dtsi
-index 4e4d6ce..3050369 100644
--- a/arch/arm/boot/dts/sun7i-a20.dtsi
+++ b/arch/arm/boot/dts/sun7i-a20.dtsi
-@@ -784,6 +784,24 @@
- #pwm-cells = <3>;
+@@ -785,6 +785,24 @@
+ interrupts = <0 24 4>;
};
+ ir0: ir@01c21800 {
arch/arm/boot/dts/sun7i-a20-cubietruck.dts | 6 ++++++
2 files changed, 12 insertions(+)
-diff --git a/arch/arm/boot/dts/sun7i-a20-cubieboard2.dts b/arch/arm/boot/dts/sun7i-a20-cubieboard2.dts
-index 97bcb2a..81bf3df 100644
--- a/arch/arm/boot/dts/sun7i-a20-cubieboard2.dts
+++ b/arch/arm/boot/dts/sun7i-a20-cubieboard2.dts
-@@ -66,6 +66,12 @@
+@@ -64,6 +64,12 @@
};
};
uart0: serial@01c28000 {
pinctrl-names = "default";
pinctrl-0 = <&uart0_pins_a>;
-diff --git a/arch/arm/boot/dts/sun7i-a20-cubietruck.dts b/arch/arm/boot/dts/sun7i-a20-cubietruck.dts
-index 624e0a5..3931986 100644
--- a/arch/arm/boot/dts/sun7i-a20-cubietruck.dts
+++ b/arch/arm/boot/dts/sun7i-a20-cubietruck.dts
@@ -114,6 +114,12 @@
- status = "okay";
+ };
};
+ ir0: ir@01c21800 {
include/media/rc-core.h | 29 +++++++
3 files changed, 223 insertions(+)
-diff --git a/Documentation/ABI/testing/sysfs-class-rc b/Documentation/ABI/testing/sysfs-class-rc
-index 52bc057..c0e1d14 100644
-diff --git a/drivers/media/rc/rc-main.c b/drivers/media/rc/rc-main.c
-index f1b67db..fa8b957 100644
---- a/drivers/media/rc/rc-main.c
-+++ b/drivers/media/rc/rc-main.c
-@@ -969,6 +969,130 @@ static ssize_t store_protocols(struct device *device,
- return ret;
- }
-
-+/**
-+ * struct rc_filter_attribute - Device attribute relating to a filter type.
-+ * @attr: Device attribute.
-+ * @type: Filter type.
-+ * @mask: false for filter value, true for filter mask.
-+ */
-+struct rc_filter_attribute {
-+ struct device_attribute attr;
-+ enum rc_filter_type type;
-+ bool mask;
-+};
-+#define to_rc_filter_attr(a) container_of(a, struct rc_filter_attribute, attr)
-+
-+#define RC_FILTER_ATTR(_name, _mode, _show, _store, _type, _mask) \
-+ struct rc_filter_attribute dev_attr_##_name = { \
-+ .attr = __ATTR(_name, _mode, _show, _store), \
-+ .type = (_type), \
-+ .mask = (_mask), \
-+ }
-+
-+/**
-+ * show_filter() - shows the current scancode filter value or mask
-+ * @device: the device descriptor
-+ * @attr: the device attribute struct
-+ * @buf: a pointer to the output buffer
-+ *
-+ * This routine is a callback routine to read a scancode filter value or mask.
-+ * It is trigged by reading /sys/class/rc/rc?/[wakeup_]filter[_mask].
-+ * It prints the current scancode filter value or mask of the appropriate filter
-+ * type in hexadecimal into @buf and returns the size of the buffer.
-+ *
-+ * Bits of the filter value corresponding to set bits in the filter mask are
-+ * compared against input scancodes and non-matching scancodes are discarded.
-+ *
-+ * dev->lock is taken to guard against races between device registration,
-+ * store_filter and show_filter.
-+ */
-+static ssize_t show_filter(struct device *device,
-+ struct device_attribute *attr,
-+ char *buf)
-+{
-+ struct rc_dev *dev = to_rc_dev(device);
-+ struct rc_filter_attribute *fattr = to_rc_filter_attr(attr);
-+ u32 val;
-+
-+ /* Device is being removed */
-+ if (!dev)
-+ return -EINVAL;
-+
-+ mutex_lock(&dev->lock);
-+ if (!dev->s_filter)
-+ val = 0;
-+ else if (fattr->mask)
-+ val = dev->scancode_filters[fattr->type].mask;
-+ else
-+ val = dev->scancode_filters[fattr->type].data;
-+ mutex_unlock(&dev->lock);
-+
-+ return sprintf(buf, "%#x\n", val);
-+}
-+
-+/**
-+ * store_filter() - changes the scancode filter value
-+ * @device: the device descriptor
-+ * @attr: the device attribute struct
-+ * @buf: a pointer to the input buffer
-+ * @len: length of the input buffer
-+ *
-+ * This routine is for changing a scancode filter value or mask.
-+ * It is trigged by writing to /sys/class/rc/rc?/[wakeup_]filter[_mask].
-+ * Returns -EINVAL if an invalid filter value for the current protocol was
-+ * specified or if scancode filtering is not supported by the driver, otherwise
-+ * returns @len.
-+ *
-+ * Bits of the filter value corresponding to set bits in the filter mask are
-+ * compared against input scancodes and non-matching scancodes are discarded.
-+ *
-+ * dev->lock is taken to guard against races between device registration,
-+ * store_filter and show_filter.
-+ */
-+static ssize_t store_filter(struct device *device,
-+ struct device_attribute *attr,
-+ const char *buf,
-+ size_t count)
-+{
-+ struct rc_dev *dev = to_rc_dev(device);
-+ struct rc_filter_attribute *fattr = to_rc_filter_attr(attr);
-+ struct rc_scancode_filter local_filter, *filter;
-+ int ret;
-+ unsigned long val;
-+
-+ /* Device is being removed */
-+ if (!dev)
-+ return -EINVAL;
-+
-+ ret = kstrtoul(buf, 0, &val);
-+ if (ret < 0)
-+ return ret;
-+
-+ /* Scancode filter not supported (but still accept 0) */
-+ if (!dev->s_filter)
-+ return val ? -EINVAL : count;
-+
-+ mutex_lock(&dev->lock);
-+
-+ /* Tell the driver about the new filter */
-+ filter = &dev->scancode_filters[fattr->type];
-+ local_filter = *filter;
-+ if (fattr->mask)
-+ local_filter.mask = val;
-+ else
-+ local_filter.data = val;
-+ ret = dev->s_filter(dev, fattr->type, &local_filter);
-+ if (ret < 0)
-+ goto unlock;
-+
-+ /* Success, commit the new filter */
-+ *filter = local_filter;
-+
-+unlock:
-+ mutex_unlock(&dev->lock);
-+ return count;
-+}
-+
- static void rc_dev_release(struct device *device)
- {
- }
-@@ -1000,9 +1124,21 @@ static int rc_dev_uevent(struct device *device, struct kobj_uevent_env *env)
- */
- static DEVICE_ATTR(protocols, S_IRUGO | S_IWUSR,
- show_protocols, store_protocols);
-+static RC_FILTER_ATTR(filter, S_IRUGO|S_IWUSR,
-+ show_filter, store_filter, RC_FILTER_NORMAL, false);
-+static RC_FILTER_ATTR(filter_mask, S_IRUGO|S_IWUSR,
-+ show_filter, store_filter, RC_FILTER_NORMAL, true);
-+static RC_FILTER_ATTR(wakeup_filter, S_IRUGO|S_IWUSR,
-+ show_filter, store_filter, RC_FILTER_WAKEUP, false);
-+static RC_FILTER_ATTR(wakeup_filter_mask, S_IRUGO|S_IWUSR,
-+ show_filter, store_filter, RC_FILTER_WAKEUP, true);
-
- static struct attribute *rc_dev_attrs[] = {
- &dev_attr_protocols.attr,
-+ &dev_attr_filter.attr.attr,
-+ &dev_attr_filter_mask.attr.attr,
-+ &dev_attr_wakeup_filter.attr.attr,
-+ &dev_attr_wakeup_filter_mask.attr.attr,
- NULL,
- };
-
-diff --git a/include/media/rc-core.h b/include/media/rc-core.h
-index 2f6f1f7..4a72176 100644
---- a/include/media/rc-core.h
-+++ b/include/media/rc-core.h
-@@ -35,6 +35,29 @@ enum rc_driver_type {
- };
-
- /**
-+ * struct rc_scancode_filter - Filter scan codes.
-+ * @data: Scancode data to match.
-+ * @mask: Mask of bits of scancode to compare.
-+ */
-+struct rc_scancode_filter {
-+ u32 data;
-+ u32 mask;
-+};
-+
-+/**
-+ * enum rc_filter_type - Filter type constants.
-+ * @RC_FILTER_NORMAL: Filter for normal operation.
-+ * @RC_FILTER_WAKEUP: Filter for waking from suspend.
-+ * @RC_FILTER_MAX: Number of filter types.
-+ */
-+enum rc_filter_type {
-+ RC_FILTER_NORMAL = 0,
-+ RC_FILTER_WAKEUP,
-+
-+ RC_FILTER_MAX
-+};
-+
-+/**
- * struct rc_dev - represents a remote control device
- * @dev: driver model's view of this device
- * @input_name: name of the input child device
-@@ -70,6 +93,7 @@ enum rc_driver_type {
- * @max_timeout: maximum timeout supported by device
- * @rx_resolution : resolution (in ns) of input sampler
- * @tx_resolution: resolution (in ns) of output sampler
-+ * @scancode_filters: scancode filters (indexed by enum rc_filter_type)
- * @change_protocol: allow changing the protocol used on hardware decoders
- * @open: callback to allow drivers to enable polling/irq when IR input device
- * is opened.
-@@ -84,6 +108,7 @@ enum rc_driver_type {
- * device doesn't interrupt host until it sees IR pulses
- * @s_learning_mode: enable wide band receiver used for learning
- * @s_carrier_report: enable carrier reports
-+ * @s_filter: set the scancode filter of a given type
- */
- struct rc_dev {
- struct device dev;
-@@ -116,6 +141,7 @@ struct rc_dev {
- u32 max_timeout;
- u32 rx_resolution;
- u32 tx_resolution;
-+ struct rc_scancode_filter scancode_filters[RC_FILTER_MAX];
- int (*change_protocol)(struct rc_dev *dev, u64 *rc_type);
- int (*open)(struct rc_dev *dev);
- void (*close)(struct rc_dev *dev);
-@@ -127,6 +153,9 @@ struct rc_dev {
- void (*s_idle)(struct rc_dev *dev, bool enable);
- int (*s_learning_mode)(struct rc_dev *dev, int enable);
- int (*s_carrier_report) (struct rc_dev *dev, int enable);
-+ int (*s_filter)(struct rc_dev *dev,
-+ enum rc_filter_type type,
-+ struct rc_scancode_filter *filter);
- };
-
- #define to_rc_dev(d) container_of(d, struct rc_dev, dev)
From 7b802ce7e8c67510389fdbbe29edd87a75df3a93 Mon Sep 17 00:00:00 2001
From: James Hogan <james.hogan@imgtec.com>
Date: Mon, 10 Feb 2014 18:31:56 -0300
drivers/media/rc/rc-main.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
-diff --git a/drivers/media/rc/rc-main.c b/drivers/media/rc/rc-main.c
-index 2ec60f8..6448128 100644
---- a/drivers/media/rc/rc-main.c
-+++ b/drivers/media/rc/rc-main.c
-@@ -1090,7 +1090,7 @@ static ssize_t store_filter(struct device *device,
-
- unlock:
- mutex_unlock(&dev->lock);
-- return count;
-+ return (ret < 0) ? ret : count;
- }
-
- static void rc_dev_release(struct device *device)
From b8c7d915087c97a21fa415fa0e860e59739da202 Mon Sep 17 00:00:00 2001
From: James Hogan <james.hogan@imgtec.com>
Date: Fri, 28 Feb 2014 20:17:02 -0300
drivers/media/rc/rc-main.c | 20 +++++++++++++-------
1 file changed, 13 insertions(+), 7 deletions(-)
-diff --git a/drivers/media/rc/rc-main.c b/drivers/media/rc/rc-main.c
-index 6448128..0a4f680f 100644
---- a/drivers/media/rc/rc-main.c
-+++ b/drivers/media/rc/rc-main.c
-@@ -633,6 +633,7 @@ EXPORT_SYMBOL_GPL(rc_repeat);
- static void ir_do_keydown(struct rc_dev *dev, int scancode,
- u32 keycode, u8 toggle)
- {
-+ struct rc_scancode_filter *filter;
- bool new_event = !dev->keypressed ||
- dev->last_scancode != scancode ||
- dev->last_toggle != toggle;
-@@ -640,6 +641,11 @@ static void ir_do_keydown(struct rc_dev *dev, int scancode,
- if (new_event && dev->keypressed)
- ir_do_keyup(dev, false);
-
-+ /* Generic scancode filtering */
-+ filter = &dev->scancode_filters[RC_FILTER_NORMAL];
-+ if (filter->mask && ((scancode ^ filter->data) & filter->mask))
-+ return;
-+
- input_event(dev->input_dev, EV_MSC, MSC_SCAN, scancode);
-
- if (new_event && keycode != KEY_RESERVED) {
-@@ -1019,9 +1025,7 @@ static ssize_t show_filter(struct device *device,
- return -EINVAL;
-
- mutex_lock(&dev->lock);
-- if (!dev->s_filter)
-- val = 0;
-- else if (fattr->mask)
-+ if (fattr->mask)
- val = dev->scancode_filters[fattr->type].mask;
- else
- val = dev->scancode_filters[fattr->type].data;
-@@ -1069,7 +1073,7 @@ static ssize_t store_filter(struct device *device,
- return ret;
-
- /* Scancode filter not supported (but still accept 0) */
-- if (!dev->s_filter)
-+ if (!dev->s_filter && fattr->type != RC_FILTER_NORMAL)
- return val ? -EINVAL : count;
-
- mutex_lock(&dev->lock);
-@@ -1081,9 +1085,11 @@ static ssize_t store_filter(struct device *device,
- local_filter.mask = val;
- else
- local_filter.data = val;
-- ret = dev->s_filter(dev, fattr->type, &local_filter);
-- if (ret < 0)
-- goto unlock;
-+ if (dev->s_filter) {
-+ ret = dev->s_filter(dev, fattr->type, &local_filter);
-+ if (ret < 0)
-+ goto unlock;
-+ }
-
- /* Success, commit the new filter */
- *filter = local_filter;
From 1a1934fab0c920f0d3bceeb60c9fe2dae8a56be9 Mon Sep 17 00:00:00 2001
From: James Hogan <james.hogan@imgtec.com>
Date: Fri, 28 Feb 2014 20:17:03 -0300
include/media/rc-core.h | 22 ++++++++++++++++++++++
36 files changed, 73 insertions(+), 50 deletions(-)
-diff --git a/drivers/hid/hid-picolcd_cir.c b/drivers/hid/hid-picolcd_cir.c
-index 59d5eb1..cf1a9f1 100644
---- a/drivers/hid/hid-picolcd_cir.c
-+++ b/drivers/hid/hid-picolcd_cir.c
-@@ -114,7 +114,7 @@ int picolcd_init_cir(struct picolcd_data *data, struct hid_report *report)
-
- rdev->priv = data;
- rdev->driver_type = RC_DRIVER_IR_RAW;
-- rdev->allowed_protos = RC_BIT_ALL;
+From acff5f24732acc8a55d0a0f0ee1d19442267df63 Mon Sep 17 00:00:00 2001
+From: James Hogan <james.hogan@imgtec.com>
+Date: Fri, 28 Feb 2014 20:17:04 -0300
+Subject: [PATCH] [media] rc: add allowed/enabled wakeup protocol masks
+MIME-Version: 1.0
+Content-Type: text/plain; charset=UTF-8
+Content-Transfer-Encoding: 8bit
+
+Only a single allowed and enabled protocol mask currently exists in
+struct rc_dev, however to support a separate wakeup filter protocol two
+of each are needed, ideally as an array.
+
+Therefore make both rc_dev::allowed_protos and rc_dev::enabled_protocols
+arrays, update all users to reference the first element
+(RC_FILTER_NORMAL), and add a couple more helper functions for drivers
+to use for setting the allowed and enabled wakeup protocols.
+
+We also rename allowed_protos to allowed_protocols while we're at it,
+which is more consistent with enabled_protocols.
+
+Signed-off-by: James Hogan <james.hogan@imgtec.com>
+Reviewed-by: Antti Seppälä <a.seppala@gmail.com>
+Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
+---
+ drivers/media/rc/rc-main.c | 10 +++++-----
+ include/media/rc-core.h | 32 ++++++++++++++++++++++++--------
+ 2 files changed, 29 insertions(+), 13 deletions(-)
+
+From ab88c66deace78989aa71cb139284cf7fb227ba4 Mon Sep 17 00:00:00 2001
+From: James Hogan <james.hogan@imgtec.com>
+Date: Fri, 28 Feb 2014 20:17:05 -0300
+Subject: [PATCH] [media] rc: add wakeup_protocols sysfs file
+MIME-Version: 1.0
+Content-Type: text/plain; charset=UTF-8
+Content-Transfer-Encoding: 8bit
+
+Add a wakeup_protocols sysfs file which controls the new
+rc_dev::enabled_protocols[RC_FILTER_WAKEUP], which is the mask of
+protocols that are used for the wakeup filter.
+
+A new RC driver callback change_wakeup_protocol() is called to change
+the wakeup protocol mask.
+
+Signed-off-by: James Hogan <james.hogan@imgtec.com>
+Reviewed-by: Antti Seppälä <a.seppala@gmail.com>
+Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
+---
+ Documentation/ABI/testing/sysfs-class-rc | 23 +++++-
+ .../DocBook/media/v4l/remote_controllers.xml | 20 +++++-
+ drivers/media/rc/rc-main.c | 82 +++++++++++++---------
+ include/media/rc-core.h | 3 +
+ 4 files changed, 90 insertions(+), 38 deletions(-)
+
+From 6bea25af147fcddcd8fd4557f4184c847c5c6ffd Mon Sep 17 00:00:00 2001
+From: James Hogan <james.hogan@imgtec.com>
+Date: Fri, 28 Feb 2014 20:17:06 -0300
+Subject: [PATCH] [media] rc-main: automatically refresh filter on protocol
+ change
+MIME-Version: 1.0
+Content-Type: text/plain; charset=UTF-8
+Content-Transfer-Encoding: 8bit
+
+When either of the normal or wakeup filter protocols are changed,
+refresh the corresponding scancode filter, i.e. try and set the same
+scancode filter with the new protocol. If that fails clear the filter
+instead.
+
+If no protocol was selected the filter is just cleared, and if no
+s_filter callback exists the filter is left unmodified.
+
+Similarly clear the filter mask when the filter is set if no protocol is
+currently selected.
+
+This simplifies driver code which no longer has to explicitly worry
+about modifying the filter on a protocol change. This also allows the
+change_wakeup_protocol callback to be omitted entirely if there is only
+a single available wakeup protocol at a time, since selecting no
+protocol will automatically clear the wakeup filter, disabling wakeup.
+
+Signed-off-by: James Hogan <james.hogan@imgtec.com>
+Reviewed-by: Antti Seppälä <a.seppala@gmail.com>
+Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
+---
+ drivers/media/rc/rc-main.c | 41 +++++++++++++++++++++++++++++++++++++++--
+ 1 file changed, 39 insertions(+), 2 deletions(-)
+
+From 262912335c823a2bbcc87003ee55d62cc27f4e48 Mon Sep 17 00:00:00 2001
+From: James Hogan <james.hogan@imgtec.com>
+Date: Sat, 1 Mar 2014 19:52:25 -0300
+Subject: [PATCH] [media] rc-main: fix missing unlock if no devno left
+
+While playing with make coccicheck I noticed this message:
+drivers/media/rc/rc-main.c:1245:3-9: preceding lock on line 1238
+
+It was introduced by commit 587d1b06e07b ([media] rc-core: reuse device
+numbers) which returns -ENOMEM after a mutex_lock without first
+unlocking it when there are no more device numbers left. The added code
+doesn't depend on the device lock, so move it before the lock is taken.
+
+Signed-off-by: James Hogan <james.hogan@imgtec.com>
+Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
+---
+ drivers/media/rc/rc-main.c | 16 ++++++++--------
+ 1 file changed, 8 insertions(+), 8 deletions(-)
+
+--- a/drivers/hid/hid-picolcd_cir.c
++++ b/drivers/hid/hid-picolcd_cir.c
+@@ -114,7 +114,7 @@ int picolcd_init_cir(struct picolcd_data
+
+ rdev->priv = data;
+ rdev->driver_type = RC_DRIVER_IR_RAW;
+- rdev->allowed_protos = RC_BIT_ALL;
+ rc_set_allowed_protocols(rdev, RC_BIT_ALL);
rdev->open = picolcd_cir_open;
rdev->close = picolcd_cir_close;
rdev->input_name = data->hdev->name;
-diff --git a/drivers/media/common/siano/smsir.c b/drivers/media/common/siano/smsir.c
-index b8c5cad..6d7c0c8 100644
--- a/drivers/media/common/siano/smsir.c
+++ b/drivers/media/common/siano/smsir.c
-@@ -88,7 +88,7 @@ int sms_ir_init(struct smscore_device_t *coredev)
+@@ -88,7 +88,7 @@ int sms_ir_init(struct smscore_device_t
dev->priv = coredev;
dev->driver_type = RC_DRIVER_IR_RAW;
dev->map_name = sms_get_board(board_id)->rc_codes;
dev->driver_name = MODULE_NAME;
-diff --git a/drivers/media/i2c/ir-kbd-i2c.c b/drivers/media/i2c/ir-kbd-i2c.c
-index 99ee456..c8fe135 100644
--- a/drivers/media/i2c/ir-kbd-i2c.c
+++ b/drivers/media/i2c/ir-kbd-i2c.c
-@@ -431,8 +431,8 @@ static int ir_probe(struct i2c_client *client, const struct i2c_device_id *id)
+@@ -431,8 +431,8 @@ static int ir_probe(struct i2c_client *c
* Initialize the other fields of rc_dev
*/
rc->map_name = ir->ir_codes;
if (!rc->driver_name)
rc->driver_name = MODULE_NAME;
-diff --git a/drivers/media/pci/cx23885/cx23885-input.c b/drivers/media/pci/cx23885/cx23885-input.c
-index 8a49e7c..097d0a0 100644
--- a/drivers/media/pci/cx23885/cx23885-input.c
+++ b/drivers/media/pci/cx23885/cx23885-input.c
-@@ -346,7 +346,7 @@ int cx23885_input_init(struct cx23885_dev *dev)
+@@ -346,7 +346,7 @@ int cx23885_input_init(struct cx23885_de
}
rc->dev.parent = &dev->pci->dev;
rc->driver_type = driver_type;
rc->priv = kernel_ir;
rc->open = cx23885_input_ir_open;
rc->close = cx23885_input_ir_close;
-diff --git a/drivers/media/pci/cx88/cx88-input.c b/drivers/media/pci/cx88/cx88-input.c
-index f29e18c..f991696 100644
--- a/drivers/media/pci/cx88/cx88-input.c
+++ b/drivers/media/pci/cx88/cx88-input.c
-@@ -469,7 +469,7 @@ int cx88_ir_init(struct cx88_core *core, struct pci_dev *pci)
+@@ -469,7 +469,7 @@ int cx88_ir_init(struct cx88_core *core,
dev->timeout = 10 * 1000 * 1000; /* 10 ms */
} else {
dev->driver_type = RC_DRIVER_SCANCODE;
}
ir->core = core;
-diff --git a/drivers/media/rc/ati_remote.c b/drivers/media/rc/ati_remote.c
-index 4d6a63f..2df7c55 100644
--- a/drivers/media/rc/ati_remote.c
+++ b/drivers/media/rc/ati_remote.c
-@@ -784,7 +784,7 @@ static void ati_remote_rc_init(struct ati_remote *ati_remote)
+@@ -784,7 +784,7 @@ static void ati_remote_rc_init(struct at
rdev->priv = ati_remote;
rdev->driver_type = RC_DRIVER_SCANCODE;
rdev->driver_name = "ati_remote";
rdev->open = ati_remote_rc_open;
-diff --git a/drivers/media/rc/ene_ir.c b/drivers/media/rc/ene_ir.c
-index c1444f8..fc9d23f 100644
--- a/drivers/media/rc/ene_ir.c
+++ b/drivers/media/rc/ene_ir.c
-@@ -1059,7 +1059,7 @@ static int ene_probe(struct pnp_dev *pnp_dev, const struct pnp_device_id *id)
+@@ -1059,7 +1059,7 @@ static int ene_probe(struct pnp_dev *pnp
learning_mode_force = false;
rdev->driver_type = RC_DRIVER_IR_RAW;
rdev->priv = dev;
rdev->open = ene_open;
rdev->close = ene_close;
-diff --git a/drivers/media/rc/fintek-cir.c b/drivers/media/rc/fintek-cir.c
-index d6fa441..46b66e5 100644
--- a/drivers/media/rc/fintek-cir.c
+++ b/drivers/media/rc/fintek-cir.c
-@@ -541,7 +541,7 @@ static int fintek_probe(struct pnp_dev *pdev, const struct pnp_device_id *dev_id
+@@ -541,7 +541,7 @@ static int fintek_probe(struct pnp_dev *
/* Set up the rc device */
rdev->priv = fintek;
rdev->driver_type = RC_DRIVER_IR_RAW;
rdev->open = fintek_open;
rdev->close = fintek_close;
rdev->input_name = FINTEK_DESCRIPTION;
-diff --git a/drivers/media/rc/gpio-ir-recv.c b/drivers/media/rc/gpio-ir-recv.c
-index 80c611c..29b5f89 100644
--- a/drivers/media/rc/gpio-ir-recv.c
+++ b/drivers/media/rc/gpio-ir-recv.c
-@@ -145,9 +145,9 @@ static int gpio_ir_recv_probe(struct platform_device *pdev)
+@@ -145,9 +145,9 @@ static int gpio_ir_recv_probe(struct pla
rcdev->dev.parent = &pdev->dev;
rcdev->driver_name = GPIO_IR_DRIVER_NAME;
if (pdata->allowed_protos)
rcdev->map_name = pdata->map_name ?: RC_MAP_EMPTY;
gpio_dev->rcdev = rcdev;
-diff --git a/drivers/media/rc/iguanair.c b/drivers/media/rc/iguanair.c
-index a83519a..627ddfd 100644
--- a/drivers/media/rc/iguanair.c
+++ b/drivers/media/rc/iguanair.c
-@@ -495,7 +495,7 @@ static int iguanair_probe(struct usb_interface *intf,
+@@ -494,7 +494,7 @@ static int iguanair_probe(struct usb_int
usb_to_input_id(ir->udev, &rc->input_id);
rc->dev.parent = &intf->dev;
rc->driver_type = RC_DRIVER_IR_RAW;
rc->priv = ir;
rc->open = iguanair_open;
rc->close = iguanair_close;
-diff --git a/drivers/media/rc/imon.c b/drivers/media/rc/imon.c
-index 822b9f4..6f24e77 100644
--- a/drivers/media/rc/imon.c
+++ b/drivers/media/rc/imon.c
-@@ -1017,7 +1017,7 @@ static int imon_ir_change_protocol(struct rc_dev *rc, u64 *rc_type)
+@@ -1017,7 +1017,7 @@ static int imon_ir_change_protocol(struc
unsigned char ir_proto_packet[] = {
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x86 };
dev_warn(dev, "Looks like you're trying to use an IR protocol "
"this device does not support\n");
-@@ -1867,7 +1867,8 @@ static struct rc_dev *imon_init_rdev(struct imon_context *ictx)
+@@ -1867,7 +1867,8 @@ static struct rc_dev *imon_init_rdev(str
rdev->priv = ictx;
rdev->driver_type = RC_DRIVER_SCANCODE;
rdev->change_protocol = imon_ir_change_protocol;
rdev->driver_name = MOD_NAME;
-@@ -1880,7 +1881,7 @@ static struct rc_dev *imon_init_rdev(struct imon_context *ictx)
+@@ -1880,7 +1881,7 @@ static struct rc_dev *imon_init_rdev(str
if (ictx->product == 0xffdc) {
imon_get_ffdc_type(ictx);
}
imon_set_display_type(ictx);
-diff --git a/drivers/media/rc/ir-jvc-decoder.c b/drivers/media/rc/ir-jvc-decoder.c
-index 3948138..4ea62a1 100644
--- a/drivers/media/rc/ir-jvc-decoder.c
+++ b/drivers/media/rc/ir-jvc-decoder.c
-@@ -47,7 +47,7 @@ static int ir_jvc_decode(struct rc_dev *dev, struct ir_raw_event ev)
+@@ -47,7 +47,7 @@ static int ir_jvc_decode(struct rc_dev *
{
struct jvc_dec *data = &dev->raw->jvc;
return 0;
if (!is_timing_event(ev)) {
-diff --git a/drivers/media/rc/ir-lirc-codec.c b/drivers/media/rc/ir-lirc-codec.c
-index ed2c8a1..d731da6 100644
--- a/drivers/media/rc/ir-lirc-codec.c
+++ b/drivers/media/rc/ir-lirc-codec.c
-@@ -35,7 +35,7 @@ static int ir_lirc_decode(struct rc_dev *dev, struct ir_raw_event ev)
+@@ -35,7 +35,7 @@ static int ir_lirc_decode(struct rc_dev
struct lirc_codec *lirc = &dev->raw->lirc;
int sample;
return 0;
if (!dev->raw->lirc.drv || !dev->raw->lirc.drv->rbuf)
-diff --git a/drivers/media/rc/ir-mce_kbd-decoder.c b/drivers/media/rc/ir-mce_kbd-decoder.c
-index 9f3c9b5..0c55f79 100644
--- a/drivers/media/rc/ir-mce_kbd-decoder.c
+++ b/drivers/media/rc/ir-mce_kbd-decoder.c
-@@ -216,7 +216,7 @@ static int ir_mce_kbd_decode(struct rc_dev *dev, struct ir_raw_event ev)
+@@ -216,7 +216,7 @@ static int ir_mce_kbd_decode(struct rc_d
u32 scancode;
unsigned long delay;
return 0;
if (!is_timing_event(ev)) {
-diff --git a/drivers/media/rc/ir-nec-decoder.c b/drivers/media/rc/ir-nec-decoder.c
-index e687a42..9de1791 100644
--- a/drivers/media/rc/ir-nec-decoder.c
+++ b/drivers/media/rc/ir-nec-decoder.c
-@@ -52,7 +52,7 @@ static int ir_nec_decode(struct rc_dev *dev, struct ir_raw_event ev)
+@@ -52,7 +52,7 @@ static int ir_nec_decode(struct rc_dev *
u8 address, not_address, command, not_command;
bool send_32bits = false;
return 0;
if (!is_timing_event(ev)) {
-diff --git a/drivers/media/rc/ir-raw.c b/drivers/media/rc/ir-raw.c
-index f0656fa..763c9d1 100644
--- a/drivers/media/rc/ir-raw.c
+++ b/drivers/media/rc/ir-raw.c
-@@ -256,7 +256,7 @@ int ir_raw_event_register(struct rc_dev *dev)
+@@ -256,7 +256,7 @@ int ir_raw_event_register(struct rc_dev
return -ENOMEM;
dev->raw->dev = dev;
rc = kfifo_alloc(&dev->raw->kfifo,
sizeof(struct ir_raw_event) * MAX_IR_EVENT_SIZE,
GFP_KERNEL);
-diff --git a/drivers/media/rc/ir-rc5-decoder.c b/drivers/media/rc/ir-rc5-decoder.c
-index 1085e17..4295d9b2 100644
--- a/drivers/media/rc/ir-rc5-decoder.c
+++ b/drivers/media/rc/ir-rc5-decoder.c
-@@ -52,7 +52,7 @@ static int ir_rc5_decode(struct rc_dev *dev, struct ir_raw_event ev)
+@@ -52,7 +52,7 @@ static int ir_rc5_decode(struct rc_dev *
u8 toggle;
u32 scancode;
return 0;
if (!is_timing_event(ev)) {
-@@ -128,7 +128,7 @@ static int ir_rc5_decode(struct rc_dev *dev, struct ir_raw_event ev)
+@@ -128,7 +128,7 @@ again:
if (data->wanted_bits == RC5X_NBITS) {
/* RC5X */
u8 xdata, command, system;
data->state = STATE_INACTIVE;
return 0;
}
-@@ -145,7 +145,7 @@ static int ir_rc5_decode(struct rc_dev *dev, struct ir_raw_event ev)
+@@ -145,7 +145,7 @@ again:
} else {
/* RC5 */
u8 command, system;
data->state = STATE_INACTIVE;
return 0;
}
-diff --git a/drivers/media/rc/ir-rc5-sz-decoder.c b/drivers/media/rc/ir-rc5-sz-decoder.c
-index 984e5b9..dc18b74 100644
--- a/drivers/media/rc/ir-rc5-sz-decoder.c
+++ b/drivers/media/rc/ir-rc5-sz-decoder.c
-@@ -48,7 +48,7 @@ static int ir_rc5_sz_decode(struct rc_dev *dev, struct ir_raw_event ev)
+@@ -48,7 +48,7 @@ static int ir_rc5_sz_decode(struct rc_de
u8 toggle, command, system;
u32 scancode;
return 0;
if (!is_timing_event(ev)) {
-diff --git a/drivers/media/rc/ir-rc6-decoder.c b/drivers/media/rc/ir-rc6-decoder.c
-index 7cba7d3..cfbd64e 100644
--- a/drivers/media/rc/ir-rc6-decoder.c
+++ b/drivers/media/rc/ir-rc6-decoder.c
-@@ -89,9 +89,9 @@ static int ir_rc6_decode(struct rc_dev *dev, struct ir_raw_event ev)
+@@ -89,9 +89,9 @@ static int ir_rc6_decode(struct rc_dev *
u32 scancode;
u8 toggle;
return 0;
if (!is_timing_event(ev)) {
-diff --git a/drivers/media/rc/ir-sanyo-decoder.c b/drivers/media/rc/ir-sanyo-decoder.c
-index e1351ed..eb715f0 100644
--- a/drivers/media/rc/ir-sanyo-decoder.c
+++ b/drivers/media/rc/ir-sanyo-decoder.c
-@@ -58,7 +58,7 @@ static int ir_sanyo_decode(struct rc_dev *dev, struct ir_raw_event ev)
+@@ -58,7 +58,7 @@ static int ir_sanyo_decode(struct rc_dev
u32 scancode;
u8 address, command, not_command;
return 0;
if (!is_timing_event(ev)) {
-diff --git a/drivers/media/rc/ir-sharp-decoder.c b/drivers/media/rc/ir-sharp-decoder.c
-index 4895bc7..66d2039 100644
-diff --git a/drivers/media/rc/ir-sony-decoder.c b/drivers/media/rc/ir-sony-decoder.c
-index 29ab9c2..599c19a 100644
--- a/drivers/media/rc/ir-sony-decoder.c
+++ b/drivers/media/rc/ir-sony-decoder.c
-@@ -45,8 +45,8 @@ static int ir_sony_decode(struct rc_dev *dev, struct ir_raw_event ev)
+@@ -45,8 +45,8 @@ static int ir_sony_decode(struct rc_dev
u32 scancode;
u8 device, subdevice, function;
return 0;
if (!is_timing_event(ev)) {
-@@ -124,7 +124,7 @@ static int ir_sony_decode(struct rc_dev *dev, struct ir_raw_event ev)
+@@ -124,7 +124,7 @@ static int ir_sony_decode(struct rc_dev
switch (data->count) {
case 12:
data->state = STATE_INACTIVE;
return 0;
}
-@@ -133,7 +133,7 @@ static int ir_sony_decode(struct rc_dev *dev, struct ir_raw_event ev)
+@@ -133,7 +133,7 @@ static int ir_sony_decode(struct rc_dev
function = bitrev8((data->bits >> 4) & 0xFE);
break;
case 15:
data->state = STATE_INACTIVE;
return 0;
}
-@@ -142,7 +142,7 @@ static int ir_sony_decode(struct rc_dev *dev, struct ir_raw_event ev)
+@@ -142,7 +142,7 @@ static int ir_sony_decode(struct rc_dev
function = bitrev8((data->bits >> 7) & 0xFE);
break;
case 20:
data->state = STATE_INACTIVE;
return 0;
}
-diff --git a/drivers/media/rc/ite-cir.c b/drivers/media/rc/ite-cir.c
-index 63b4225..ab24cc6 100644
--- a/drivers/media/rc/ite-cir.c
+++ b/drivers/media/rc/ite-cir.c
-@@ -1563,7 +1563,7 @@ static int ite_probe(struct pnp_dev *pdev, const struct pnp_device_id
+@@ -1563,7 +1563,7 @@ static int ite_probe(struct pnp_dev *pde
/* set up ir-core props */
rdev->priv = itdev;
rdev->driver_type = RC_DRIVER_IR_RAW;
rdev->open = ite_open;
rdev->close = ite_close;
rdev->s_idle = ite_s_idle;
-diff --git a/drivers/media/rc/mceusb.c b/drivers/media/rc/mceusb.c
-index c01b4c1..5d8f3d4 100644
--- a/drivers/media/rc/mceusb.c
+++ b/drivers/media/rc/mceusb.c
-@@ -1211,7 +1211,7 @@ static struct rc_dev *mceusb_init_rc_dev(struct mceusb_dev *ir)
+@@ -1217,7 +1217,7 @@ static struct rc_dev *mceusb_init_rc_dev
rc->dev.parent = dev;
rc->priv = ir;
rc->driver_type = RC_DRIVER_IR_RAW;
rc->timeout = MS_TO_NS(100);
if (!ir->flags.no_tx) {
rc->s_tx_mask = mceusb_set_tx_mask;
-diff --git a/drivers/media/rc/nuvoton-cir.c b/drivers/media/rc/nuvoton-cir.c
-index b81325d..d244e1a 100644
--- a/drivers/media/rc/nuvoton-cir.c
+++ b/drivers/media/rc/nuvoton-cir.c
-@@ -1044,7 +1044,7 @@ static int nvt_probe(struct pnp_dev *pdev, const struct pnp_device_id *dev_id)
+@@ -1042,7 +1042,7 @@ static int nvt_probe(struct pnp_dev *pde
/* Set up the rc device */
rdev->priv = nvt;
rdev->driver_type = RC_DRIVER_IR_RAW;
rdev->open = nvt_open;
rdev->close = nvt_close;
rdev->tx_ir = nvt_tx_ir;
-diff --git a/drivers/media/rc/rc-loopback.c b/drivers/media/rc/rc-loopback.c
-index 53d0282..0a88e0c 100644
--- a/drivers/media/rc/rc-loopback.c
+++ b/drivers/media/rc/rc-loopback.c
@@ -195,7 +195,7 @@ static int __init loop_init(void)
rc->timeout = 100 * 1000 * 1000; /* 100 ms */
rc->min_timeout = 1;
rc->max_timeout = UINT_MAX;
-diff --git a/drivers/media/rc/redrat3.c b/drivers/media/rc/redrat3.c
-index a5d4f88..47cd373 100644
---- a/drivers/media/rc/redrat3.c
-+++ b/drivers/media/rc/redrat3.c
-@@ -922,7 +922,7 @@ static struct rc_dev *redrat3_init_rc_dev(struct redrat3_dev *rr3)
- rc->dev.parent = dev;
- rc->priv = rr3;
- rc->driver_type = RC_DRIVER_IR_RAW;
-- rc->allowed_protos = RC_BIT_ALL;
-+ rc_set_allowed_protocols(rc, RC_BIT_ALL);
- rc->timeout = US_TO_NS(2750);
- rc->tx_ir = redrat3_transmit_ir;
- rc->s_tx_carrier = redrat3_set_tx_carrier;
-diff --git a/drivers/media/rc/st_rc.c b/drivers/media/rc/st_rc.c
-index 8f0cddb..22e4c1f 100644
---- a/drivers/media/rc/st_rc.c
-+++ b/drivers/media/rc/st_rc.c
-@@ -287,7 +287,7 @@ static int st_rc_probe(struct platform_device *pdev)
- st_rc_hardware_init(rc_dev);
+--- a/drivers/media/rc/rc-main.c
++++ b/drivers/media/rc/rc-main.c
+@@ -633,6 +633,7 @@ EXPORT_SYMBOL_GPL(rc_repeat);
+ static void ir_do_keydown(struct rc_dev *dev, int scancode,
+ u32 keycode, u8 toggle)
+ {
++ struct rc_scancode_filter *filter;
+ bool new_event = !dev->keypressed ||
+ dev->last_scancode != scancode ||
+ dev->last_toggle != toggle;
+@@ -640,6 +641,11 @@ static void ir_do_keydown(struct rc_dev
+ if (new_event && dev->keypressed)
+ ir_do_keyup(dev, false);
- rdev->driver_type = RC_DRIVER_IR_RAW;
-- rdev->allowed_protos = RC_BIT_ALL;
-+ rc_set_allowed_protocols(rdev, RC_BIT_ALL);
- /* rx sampling rate is 10Mhz */
- rdev->rx_resolution = 100;
- rdev->timeout = US_TO_NS(MAX_SYMB_TIME);
-diff --git a/drivers/media/rc/streamzap.c b/drivers/media/rc/streamzap.c
-index d7b11e6..f4e0bc3 100644
---- a/drivers/media/rc/streamzap.c
-+++ b/drivers/media/rc/streamzap.c
-@@ -322,7 +322,7 @@ static struct rc_dev *streamzap_init_rc_dev(struct streamzap_ir *sz)
- rdev->dev.parent = dev;
- rdev->priv = sz;
- rdev->driver_type = RC_DRIVER_IR_RAW;
-- rdev->allowed_protos = RC_BIT_ALL;
-+ rc_set_allowed_protocols(rdev, RC_BIT_ALL);
- rdev->driver_name = DRIVER_NAME;
- rdev->map_name = RC_MAP_STREAMZAP;
++ /* Generic scancode filtering */
++ filter = &dev->scancode_filters[RC_FILTER_NORMAL];
++ if (filter->mask && ((scancode ^ filter->data) & filter->mask))
++ return;
++
+ input_event(dev->input_dev, EV_MSC, MSC_SCAN, scancode);
-diff --git a/drivers/media/rc/ttusbir.c b/drivers/media/rc/ttusbir.c
-index d8de205..c5be38e 100644
---- a/drivers/media/rc/ttusbir.c
-+++ b/drivers/media/rc/ttusbir.c
-@@ -318,7 +318,7 @@ static int ttusbir_probe(struct usb_interface *intf,
- usb_to_input_id(tt->udev, &rc->input_id);
- rc->dev.parent = &intf->dev;
- rc->driver_type = RC_DRIVER_IR_RAW;
-- rc->allowed_protos = RC_BIT_ALL;
-+ rc_set_allowed_protocols(rc, RC_BIT_ALL);
- rc->priv = tt;
- rc->driver_name = DRIVER_NAME;
- rc->map_name = RC_MAP_TT_1500;
-diff --git a/drivers/media/rc/winbond-cir.c b/drivers/media/rc/winbond-cir.c
-index 904baf4..a8b981f 100644
---- a/drivers/media/rc/winbond-cir.c
-+++ b/drivers/media/rc/winbond-cir.c
-@@ -1082,7 +1082,7 @@ wbcir_probe(struct pnp_dev *device, const struct pnp_device_id *dev_id)
- data->dev->dev.parent = &device->dev;
- data->dev->timeout = MS_TO_NS(100);
- data->dev->rx_resolution = US_TO_NS(2);
-- data->dev->allowed_protos = RC_BIT_ALL;
-+ rc_set_allowed_protocols(data->dev, RC_BIT_ALL);
+ if (new_event && keycode != KEY_RESERVED) {
+@@ -795,13 +801,38 @@ static struct {
+ };
- err = rc_register_device(data->dev);
- if (err)
-diff --git a/drivers/media/usb/dvb-usb-v2/dvb_usb_core.c b/drivers/media/usb/dvb-usb-v2/dvb_usb_core.c
-index 8a054d6..de02db8 100644
---- a/drivers/media/usb/dvb-usb-v2/dvb_usb_core.c
-+++ b/drivers/media/usb/dvb-usb-v2/dvb_usb_core.c
-@@ -164,7 +164,7 @@ static int dvb_usbv2_remote_init(struct dvb_usb_device *d)
- dev->driver_name = (char *) d->props->driver_name;
- dev->map_name = d->rc.map_name;
- dev->driver_type = d->rc.driver_type;
-- dev->allowed_protos = d->rc.allowed_protos;
-+ rc_set_allowed_protocols(dev, d->rc.allowed_protos);
- dev->change_protocol = d->rc.change_protocol;
- dev->priv = d;
-
-diff --git a/drivers/media/usb/dvb-usb/dvb-usb-remote.c b/drivers/media/usb/dvb-usb/dvb-usb-remote.c
-index 41bacff..4058aea 100644
---- a/drivers/media/usb/dvb-usb/dvb-usb-remote.c
-+++ b/drivers/media/usb/dvb-usb/dvb-usb-remote.c
-@@ -272,7 +272,7 @@ static int rc_core_dvb_usb_remote_init(struct dvb_usb_device *d)
- dev->driver_name = d->props.rc.core.module_name;
- dev->map_name = d->props.rc.core.rc_codes;
- dev->change_protocol = d->props.rc.core.change_protocol;
-- dev->allowed_protos = d->props.rc.core.allowed_protos;
-+ rc_set_allowed_protocols(dev, d->props.rc.core.allowed_protos);
- dev->driver_type = d->props.rc.core.driver_type;
- usb_to_input_id(d->udev, &dev->input_id);
- dev->input_name = "IR-receiver inside an USB DVB receiver";
-diff --git a/drivers/media/usb/em28xx/em28xx-input.c b/drivers/media/usb/em28xx/em28xx-input.c
-index 2a9bf66..56ef49d 100644
---- a/drivers/media/usb/em28xx/em28xx-input.c
-+++ b/drivers/media/usb/em28xx/em28xx-input.c
-@@ -727,7 +727,7 @@ static int em28xx_ir_init(struct em28xx *dev)
- case EM2820_BOARD_HAUPPAUGE_WINTV_USB_2:
- rc->map_name = RC_MAP_HAUPPAUGE;
- ir->get_key_i2c = em28xx_get_key_em_haup;
-- rc->allowed_protos = RC_BIT_RC5;
-+ rc_set_allowed_protocols(rc, RC_BIT_RC5);
- break;
- case EM2820_BOARD_LEADTEK_WINFAST_USBII_DELUXE:
- rc->map_name = RC_MAP_WINFAST_USBII_DELUXE;
-@@ -743,7 +743,7 @@ static int em28xx_ir_init(struct em28xx *dev)
- switch (dev->chip_id) {
- case CHIP_ID_EM2860:
- case CHIP_ID_EM2883:
-- rc->allowed_protos = RC_BIT_RC5 | RC_BIT_NEC;
-+ rc_set_allowed_protocols(rc, RC_BIT_RC5 | RC_BIT_NEC);
- ir->get_key = default_polling_getkey;
- break;
- case CHIP_ID_EM2884:
-@@ -751,8 +751,8 @@ static int em28xx_ir_init(struct em28xx *dev)
- case CHIP_ID_EM28174:
- case CHIP_ID_EM28178:
- ir->get_key = em2874_polling_getkey;
-- rc->allowed_protos = RC_BIT_RC5 | RC_BIT_NEC |
-- RC_BIT_RC6_0;
-+ rc_set_allowed_protocols(rc, RC_BIT_RC5 | RC_BIT_NEC |
-+ RC_BIT_RC6_0);
- break;
- default:
- err = -ENODEV;
-diff --git a/drivers/media/usb/tm6000/tm6000-input.c b/drivers/media/usb/tm6000/tm6000-input.c
-index 8a6bbf1..d1af543 100644
---- a/drivers/media/usb/tm6000/tm6000-input.c
-+++ b/drivers/media/usb/tm6000/tm6000-input.c
-@@ -422,7 +422,7 @@ int tm6000_ir_init(struct tm6000_core *dev)
- ir->rc = rc;
-
- /* input setup */
-- rc->allowed_protos = RC_BIT_RC5 | RC_BIT_NEC;
-+ rc_set_allowed_protocols(rc, RC_BIT_RC5 | RC_BIT_NEC);
- /* Neded, in order to support NEC remotes with 24 or 32 bits */
- rc->scanmask = 0xffff;
- rc->priv = ir;
-diff --git a/include/media/rc-core.h b/include/media/rc-core.h
-index 5e7197e..6f3c3d9 100644
---- a/include/media/rc-core.h
-+++ b/include/media/rc-core.h
-@@ -160,6 +160,28 @@ struct rc_dev {
-
- #define to_rc_dev(d) container_of(d, struct rc_dev, dev)
-
-+static inline bool rc_protocols_allowed(struct rc_dev *rdev, u64 protos)
-+{
-+ return rdev->allowed_protos & protos;
-+}
-+
-+/* should be called prior to registration or with mutex held */
-+static inline void rc_set_allowed_protocols(struct rc_dev *rdev, u64 protos)
-+{
-+ rdev->allowed_protos = protos;
-+}
-+
-+static inline bool rc_protocols_enabled(struct rc_dev *rdev, u64 protos)
-+{
-+ return rdev->enabled_protocols & protos;
-+}
-+
-+/* should be called prior to registration or with mutex held */
-+static inline void rc_set_enabled_protocols(struct rc_dev *rdev, u64 protos)
-+{
-+ rdev->enabled_protocols = protos;
-+}
-+
- /*
- * From rc-main.c
- * Those functions can be used on any type of Remote Controller. They
-From acff5f24732acc8a55d0a0f0ee1d19442267df63 Mon Sep 17 00:00:00 2001
-From: James Hogan <james.hogan@imgtec.com>
-Date: Fri, 28 Feb 2014 20:17:04 -0300
-Subject: [PATCH] [media] rc: add allowed/enabled wakeup protocol masks
-MIME-Version: 1.0
-Content-Type: text/plain; charset=UTF-8
-Content-Transfer-Encoding: 8bit
-
-Only a single allowed and enabled protocol mask currently exists in
-struct rc_dev, however to support a separate wakeup filter protocol two
-of each are needed, ideally as an array.
-
-Therefore make both rc_dev::allowed_protos and rc_dev::enabled_protocols
-arrays, update all users to reference the first element
-(RC_FILTER_NORMAL), and add a couple more helper functions for drivers
-to use for setting the allowed and enabled wakeup protocols.
-
-We also rename allowed_protos to allowed_protocols while we're at it,
-which is more consistent with enabled_protocols.
-
-Signed-off-by: James Hogan <james.hogan@imgtec.com>
-Reviewed-by: Antti Seppälä <a.seppala@gmail.com>
-Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
----
- drivers/media/rc/rc-main.c | 10 +++++-----
- include/media/rc-core.h | 32 ++++++++++++++++++++++++--------
- 2 files changed, 29 insertions(+), 13 deletions(-)
-
-diff --git a/drivers/media/rc/rc-main.c b/drivers/media/rc/rc-main.c
-index 0a4f680f..309d791 100644
---- a/drivers/media/rc/rc-main.c
-+++ b/drivers/media/rc/rc-main.c
-@@ -830,9 +830,9 @@ static ssize_t show_protocols(struct device *device,
+ /**
+- * show_protocols() - shows the current IR protocol(s)
++ * struct rc_filter_attribute - Device attribute relating to a filter type.
++ * @attr: Device attribute.
++ * @type: Filter type.
++ * @mask: false for filter value, true for filter mask.
++ */
++struct rc_filter_attribute {
++ struct device_attribute attr;
++ enum rc_filter_type type;
++ bool mask;
++};
++#define to_rc_filter_attr(a) container_of(a, struct rc_filter_attribute, attr)
++
++#define RC_PROTO_ATTR(_name, _mode, _show, _store, _type) \
++ struct rc_filter_attribute dev_attr_##_name = { \
++ .attr = __ATTR(_name, _mode, _show, _store), \
++ .type = (_type), \
++ }
++#define RC_FILTER_ATTR(_name, _mode, _show, _store, _type, _mask) \
++ struct rc_filter_attribute dev_attr_##_name = { \
++ .attr = __ATTR(_name, _mode, _show, _store), \
++ .type = (_type), \
++ .mask = (_mask), \
++ }
++
++/**
++ * show_protocols() - shows the current/wakeup IR protocol(s)
+ * @device: the device descriptor
+ * @mattr: the device attribute struct (unused)
+ * @buf: a pointer to the output buffer
+ *
+ * This routine is a callback routine for input read the IR protocol type(s).
+- * it is trigged by reading /sys/class/rc/rc?/protocols.
++ * it is trigged by reading /sys/class/rc/rc?/[wakeup_]protocols.
+ * It returns the protocol names of supported protocols.
+ * Enabled protocols are printed in brackets.
+ *
+@@ -812,6 +843,7 @@ static ssize_t show_protocols(struct dev
+ struct device_attribute *mattr, char *buf)
+ {
+ struct rc_dev *dev = to_rc_dev(device);
++ struct rc_filter_attribute *fattr = to_rc_filter_attr(mattr);
+ u64 allowed, enabled;
+ char *tmp = buf;
+ int i;
+@@ -822,9 +854,10 @@ static ssize_t show_protocols(struct dev
mutex_lock(&dev->lock);
- enabled = dev->enabled_protocols;
-+ enabled = dev->enabled_protocols[RC_FILTER_NORMAL];
- if (dev->driver_type == RC_DRIVER_SCANCODE)
-- allowed = dev->allowed_protos;
-+ allowed = dev->allowed_protocols[RC_FILTER_NORMAL];
- else if (dev->raw)
- allowed = ir_raw_get_allowed_protocols();
- else {
-@@ -906,7 +906,7 @@ static ssize_t store_protocols(struct device *device,
- ret = -EINVAL;
- goto out;
- }
-- type = dev->enabled_protocols;
-+ type = dev->enabled_protocols[RC_FILTER_NORMAL];
-
- while ((tmp = strsep((char **) &data, " \n")) != NULL) {
- if (!*tmp)
-@@ -964,7 +964,7 @@ static ssize_t store_protocols(struct device *device,
- }
- }
-
-- dev->enabled_protocols = type;
-+ dev->enabled_protocols[RC_FILTER_NORMAL] = type;
- IR_dprintk(1, "Current protocol(s): 0x%llx\n",
- (long long)type);
-
-@@ -1316,7 +1316,7 @@ int rc_register_device(struct rc_dev *dev)
- rc = dev->change_protocol(dev, &rc_type);
- if (rc < 0)
- goto out_raw;
-- dev->enabled_protocols = rc_type;
-+ dev->enabled_protocols[RC_FILTER_NORMAL] = rc_type;
- }
-
- mutex_unlock(&dev->lock);
-diff --git a/include/media/rc-core.h b/include/media/rc-core.h
-index 6f3c3d9..f165115 100644
---- a/include/media/rc-core.h
-+++ b/include/media/rc-core.h
-@@ -73,8 +73,10 @@ enum rc_filter_type {
- * @input_dev: the input child device used to communicate events to userspace
- * @driver_type: specifies if protocol decoding is done in hardware or software
- * @idle: used to keep track of RX state
-- * @allowed_protos: bitmask with the supported RC_BIT_* protocols
-- * @enabled_protocols: bitmask with the enabled RC_BIT_* protocols
-+ * @allowed_protocols: bitmask with the supported RC_BIT_* protocols for each
-+ * filter type
-+ * @enabled_protocols: bitmask with the enabled RC_BIT_* protocols for each
-+ * filter type
- * @scanmask: some hardware decoders are not capable of providing the full
- * scancode to the application. As this is a hardware limit, we can't do
- * anything with it. Yet, as the same keycode table can be used with other
-@@ -124,8 +126,8 @@ struct rc_dev {
- struct input_dev *input_dev;
- enum rc_driver_type driver_type;
- bool idle;
-- u64 allowed_protos;
-- u64 enabled_protocols;
-+ u64 allowed_protocols[RC_FILTER_MAX];
-+ u64 enabled_protocols[RC_FILTER_MAX];
- u32 users;
- u32 scanmask;
- void *priv;
-@@ -162,24 +164,38 @@ struct rc_dev {
-
- static inline bool rc_protocols_allowed(struct rc_dev *rdev, u64 protos)
- {
-- return rdev->allowed_protos & protos;
-+ return rdev->allowed_protocols[RC_FILTER_NORMAL] & protos;
- }
-
- /* should be called prior to registration or with mutex held */
- static inline void rc_set_allowed_protocols(struct rc_dev *rdev, u64 protos)
- {
-- rdev->allowed_protos = protos;
-+ rdev->allowed_protocols[RC_FILTER_NORMAL] = protos;
- }
-
- static inline bool rc_protocols_enabled(struct rc_dev *rdev, u64 protos)
- {
-- return rdev->enabled_protocols & protos;
-+ return rdev->enabled_protocols[RC_FILTER_NORMAL] & protos;
- }
-
- /* should be called prior to registration or with mutex held */
- static inline void rc_set_enabled_protocols(struct rc_dev *rdev, u64 protos)
- {
-- rdev->enabled_protocols = protos;
-+ rdev->enabled_protocols[RC_FILTER_NORMAL] = protos;
-+}
-+
-+/* should be called prior to registration or with mutex held */
-+static inline void rc_set_allowed_wakeup_protocols(struct rc_dev *rdev,
-+ u64 protos)
-+{
-+ rdev->allowed_protocols[RC_FILTER_WAKEUP] = protos;
-+}
-+
-+/* should be called prior to registration or with mutex held */
-+static inline void rc_set_enabled_wakeup_protocols(struct rc_dev *rdev,
-+ u64 protos)
-+{
-+ rdev->enabled_protocols[RC_FILTER_WAKEUP] = protos;
- }
-
- /*
-From ab88c66deace78989aa71cb139284cf7fb227ba4 Mon Sep 17 00:00:00 2001
-From: James Hogan <james.hogan@imgtec.com>
-Date: Fri, 28 Feb 2014 20:17:05 -0300
-Subject: [PATCH] [media] rc: add wakeup_protocols sysfs file
-MIME-Version: 1.0
-Content-Type: text/plain; charset=UTF-8
-Content-Transfer-Encoding: 8bit
-
-Add a wakeup_protocols sysfs file which controls the new
-rc_dev::enabled_protocols[RC_FILTER_WAKEUP], which is the mask of
-protocols that are used for the wakeup filter.
-
-A new RC driver callback change_wakeup_protocol() is called to change
-the wakeup protocol mask.
-
-Signed-off-by: James Hogan <james.hogan@imgtec.com>
-Reviewed-by: Antti Seppälä <a.seppala@gmail.com>
-Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
----
- Documentation/ABI/testing/sysfs-class-rc | 23 +++++-
- .../DocBook/media/v4l/remote_controllers.xml | 20 +++++-
- drivers/media/rc/rc-main.c | 82 +++++++++++++---------
- include/media/rc-core.h | 3 +
- 4 files changed, 90 insertions(+), 38 deletions(-)
-
-diff --git a/Documentation/ABI/testing/sysfs-class-rc b/Documentation/ABI/testing/sysfs-class-rc
-index c0e1d14..b65674d 100644
-diff --git a/Documentation/DocBook/media/v4l/remote_controllers.xml b/Documentation/DocBook/media/v4l/remote_controllers.xml
-index c440a81..5124a6c 100644
-diff --git a/drivers/media/rc/rc-main.c b/drivers/media/rc/rc-main.c
-index 309d791..e6e3ec7 100644
---- a/drivers/media/rc/rc-main.c
-+++ b/drivers/media/rc/rc-main.c
-@@ -803,13 +803,38 @@ static struct {
- };
-
- /**
-- * show_protocols() - shows the current IR protocol(s)
-+ * struct rc_filter_attribute - Device attribute relating to a filter type.
-+ * @attr: Device attribute.
-+ * @type: Filter type.
-+ * @mask: false for filter value, true for filter mask.
-+ */
-+struct rc_filter_attribute {
-+ struct device_attribute attr;
-+ enum rc_filter_type type;
-+ bool mask;
-+};
-+#define to_rc_filter_attr(a) container_of(a, struct rc_filter_attribute, attr)
-+
-+#define RC_PROTO_ATTR(_name, _mode, _show, _store, _type) \
-+ struct rc_filter_attribute dev_attr_##_name = { \
-+ .attr = __ATTR(_name, _mode, _show, _store), \
-+ .type = (_type), \
-+ }
-+#define RC_FILTER_ATTR(_name, _mode, _show, _store, _type, _mask) \
-+ struct rc_filter_attribute dev_attr_##_name = { \
-+ .attr = __ATTR(_name, _mode, _show, _store), \
-+ .type = (_type), \
-+ .mask = (_mask), \
-+ }
-+
-+/**
-+ * show_protocols() - shows the current/wakeup IR protocol(s)
- * @device: the device descriptor
- * @mattr: the device attribute struct (unused)
- * @buf: a pointer to the output buffer
- *
- * This routine is a callback routine for input read the IR protocol type(s).
-- * it is trigged by reading /sys/class/rc/rc?/protocols.
-+ * it is trigged by reading /sys/class/rc/rc?/[wakeup_]protocols.
- * It returns the protocol names of supported protocols.
- * Enabled protocols are printed in brackets.
- *
-@@ -820,6 +845,7 @@ static ssize_t show_protocols(struct device *device,
- struct device_attribute *mattr, char *buf)
- {
- struct rc_dev *dev = to_rc_dev(device);
-+ struct rc_filter_attribute *fattr = to_rc_filter_attr(mattr);
- u64 allowed, enabled;
- char *tmp = buf;
- int i;
-@@ -830,9 +856,10 @@ static ssize_t show_protocols(struct device *device,
-
- mutex_lock(&dev->lock);
-
-- enabled = dev->enabled_protocols[RC_FILTER_NORMAL];
- if (dev->driver_type == RC_DRIVER_SCANCODE)
-- allowed = dev->allowed_protocols[RC_FILTER_NORMAL];
+- allowed = dev->allowed_protos;
+ enabled = dev->enabled_protocols[fattr->type];
+ if (dev->driver_type == RC_DRIVER_SCANCODE ||
+ fattr->type == RC_FILTER_WAKEUP)
else if (dev->raw)
allowed = ir_raw_get_allowed_protocols();
else {
-@@ -864,14 +891,14 @@ static ssize_t show_protocols(struct device *device,
+@@ -856,14 +889,14 @@ static ssize_t show_protocols(struct dev
}
/**
* Writing "+proto" will add a protocol to the list of enabled protocols.
* Writing "-proto" will remove a protocol from the list of enabled protocols.
* Writing "proto" will enable only "proto".
-@@ -888,12 +915,14 @@ static ssize_t store_protocols(struct device *device,
+@@ -880,12 +913,15 @@ static ssize_t store_protocols(struct de
size_t len)
{
struct rc_dev *dev = to_rc_dev(device);
+ struct rc_filter_attribute *fattr = to_rc_filter_attr(mattr);
bool enable, disable;
const char *tmp;
- u64 type;
+- u64 type;
++ u64 old_type, type;
u64 mask;
int rc, i, count = 0;
ssize_t ret;
+ int (*change_protocol)(struct rc_dev *dev, u64 *rc_type);
++ struct rc_scancode_filter local_filter, *filter;
/* Device is being removed */
if (!dev)
-@@ -906,7 +935,7 @@ static ssize_t store_protocols(struct device *device,
+@@ -898,7 +934,8 @@ static ssize_t store_protocols(struct de
ret = -EINVAL;
goto out;
}
-- type = dev->enabled_protocols[RC_FILTER_NORMAL];
-+ type = dev->enabled_protocols[fattr->type];
+- type = dev->enabled_protocols;
++ old_type = dev->enabled_protocols[fattr->type];
++ type = old_type;
while ((tmp = strsep((char **) &data, " \n")) != NULL) {
if (!*tmp)
-@@ -954,8 +983,10 @@ static ssize_t store_protocols(struct device *device,
+@@ -946,8 +983,10 @@ static ssize_t store_protocols(struct de
goto out;
}
if (rc < 0) {
IR_dprintk(1, "Error setting protocols to 0x%llx\n",
(long long)type);
-@@ -964,7 +995,7 @@ static ssize_t store_protocols(struct device *device,
+@@ -956,10 +995,40 @@ static ssize_t store_protocols(struct de
}
}
-- dev->enabled_protocols[RC_FILTER_NORMAL] = type;
+- dev->enabled_protocols = type;
+ dev->enabled_protocols[fattr->type] = type;
IR_dprintk(1, "Current protocol(s): 0x%llx\n",
(long long)type);
-@@ -976,26 +1007,6 @@ static ssize_t store_protocols(struct device *device,
- }
-
- /**
-- * struct rc_filter_attribute - Device attribute relating to a filter type.
-- * @attr: Device attribute.
-- * @type: Filter type.
-- * @mask: false for filter value, true for filter mask.
-- */
--struct rc_filter_attribute {
-- struct device_attribute attr;
-- enum rc_filter_type type;
-- bool mask;
--};
--#define to_rc_filter_attr(a) container_of(a, struct rc_filter_attribute, attr)
--
--#define RC_FILTER_ATTR(_name, _mode, _show, _store, _type, _mask) \
-- struct rc_filter_attribute dev_attr_##_name = { \
-- .attr = __ATTR(_name, _mode, _show, _store), \
-- .type = (_type), \
-- .mask = (_mask), \
-- }
--
--/**
- * show_filter() - shows the current scancode filter value or mask
- * @device: the device descriptor
- * @attr: the device attribute struct
-@@ -1128,8 +1139,10 @@ static int rc_dev_uevent(struct device *device, struct kobj_uevent_env *env)
- /*
- * Static device attribute struct with the sysfs attributes for IR's
- */
--static DEVICE_ATTR(protocols, S_IRUGO | S_IWUSR,
-- show_protocols, store_protocols);
-+static RC_PROTO_ATTR(protocols, S_IRUGO | S_IWUSR,
-+ show_protocols, store_protocols, RC_FILTER_NORMAL);
-+static RC_PROTO_ATTR(wakeup_protocols, S_IRUGO | S_IWUSR,
-+ show_protocols, store_protocols, RC_FILTER_WAKEUP);
- static RC_FILTER_ATTR(filter, S_IRUGO|S_IWUSR,
- show_filter, store_filter, RC_FILTER_NORMAL, false);
- static RC_FILTER_ATTR(filter_mask, S_IRUGO|S_IWUSR,
-@@ -1140,7 +1153,8 @@ static RC_FILTER_ATTR(wakeup_filter_mask, S_IRUGO|S_IWUSR,
- show_filter, store_filter, RC_FILTER_WAKEUP, true);
-
- static struct attribute *rc_dev_attrs[] = {
-- &dev_attr_protocols.attr,
-+ &dev_attr_protocols.attr.attr,
-+ &dev_attr_wakeup_protocols.attr.attr,
- &dev_attr_filter.attr.attr,
- &dev_attr_filter_mask.attr.attr,
- &dev_attr_wakeup_filter.attr.attr,
-diff --git a/include/media/rc-core.h b/include/media/rc-core.h
-index f165115..0b9f890 100644
---- a/include/media/rc-core.h
-+++ b/include/media/rc-core.h
-@@ -97,6 +97,8 @@ enum rc_filter_type {
- * @tx_resolution: resolution (in ns) of output sampler
- * @scancode_filters: scancode filters (indexed by enum rc_filter_type)
- * @change_protocol: allow changing the protocol used on hardware decoders
-+ * @change_wakeup_protocol: allow changing the protocol used for wakeup
-+ * filtering
- * @open: callback to allow drivers to enable polling/irq when IR input device
- * is opened.
- * @close: callback to allow drivers to disable polling/irq when IR input device
-@@ -145,6 +147,7 @@ struct rc_dev {
- u32 tx_resolution;
- struct rc_scancode_filter scancode_filters[RC_FILTER_MAX];
- int (*change_protocol)(struct rc_dev *dev, u64 *rc_type);
-+ int (*change_wakeup_protocol)(struct rc_dev *dev, u64 *rc_type);
- int (*open)(struct rc_dev *dev);
- void (*close)(struct rc_dev *dev);
- int (*s_tx_mask)(struct rc_dev *dev, u32 mask);
-From 6bea25af147fcddcd8fd4557f4184c847c5c6ffd Mon Sep 17 00:00:00 2001
-From: James Hogan <james.hogan@imgtec.com>
-Date: Fri, 28 Feb 2014 20:17:06 -0300
-Subject: [PATCH] [media] rc-main: automatically refresh filter on protocol
- change
-MIME-Version: 1.0
-Content-Type: text/plain; charset=UTF-8
-Content-Transfer-Encoding: 8bit
-
-When either of the normal or wakeup filter protocols are changed,
-refresh the corresponding scancode filter, i.e. try and set the same
-scancode filter with the new protocol. If that fails clear the filter
-instead.
-
-If no protocol was selected the filter is just cleared, and if no
-s_filter callback exists the filter is left unmodified.
-
-Similarly clear the filter mask when the filter is set if no protocol is
-currently selected.
-
-This simplifies driver code which no longer has to explicitly worry
-about modifying the filter on a protocol change. This also allows the
-change_wakeup_protocol callback to be omitted entirely if there is only
-a single available wakeup protocol at a time, since selecting no
-protocol will automatically clear the wakeup filter, disabling wakeup.
-
-Signed-off-by: James Hogan <james.hogan@imgtec.com>
-Reviewed-by: Antti Seppälä <a.seppala@gmail.com>
-Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
----
- drivers/media/rc/rc-main.c | 41 +++++++++++++++++++++++++++++++++++++++--
- 1 file changed, 39 insertions(+), 2 deletions(-)
-
-diff --git a/drivers/media/rc/rc-main.c b/drivers/media/rc/rc-main.c
-index e6e3ec7..b1a6900 100644
---- a/drivers/media/rc/rc-main.c
-+++ b/drivers/media/rc/rc-main.c
-@@ -918,11 +918,12 @@ static ssize_t store_protocols(struct device *device,
- struct rc_filter_attribute *fattr = to_rc_filter_attr(mattr);
- bool enable, disable;
- const char *tmp;
-- u64 type;
-+ u64 old_type, type;
- u64 mask;
- int rc, i, count = 0;
- ssize_t ret;
- int (*change_protocol)(struct rc_dev *dev, u64 *rc_type);
-+ struct rc_scancode_filter local_filter, *filter;
-
- /* Device is being removed */
- if (!dev)
-@@ -935,7 +936,8 @@ static ssize_t store_protocols(struct device *device,
- ret = -EINVAL;
- goto out;
- }
-- type = dev->enabled_protocols[fattr->type];
-+ old_type = dev->enabled_protocols[fattr->type];
-+ type = old_type;
-
- while ((tmp = strsep((char **) &data, " \n")) != NULL) {
- if (!*tmp)
-@@ -999,6 +1001,36 @@ static ssize_t store_protocols(struct device *device,
- IR_dprintk(1, "Current protocol(s): 0x%llx\n",
- (long long)type);
-
+ /*
+ * If the protocol is changed the filter needs updating.
+ * Try setting the same filter with the new protocol (if any).
ret = len;
out:
-@@ -1096,6 +1128,11 @@ static ssize_t store_filter(struct device *device,
- local_filter.mask = val;
- else
- local_filter.data = val;
+@@ -967,6 +1036,115 @@ out:
+ return ret;
+ }
+
++/**
++ * show_filter() - shows the current scancode filter value or mask
++ * @device: the device descriptor
++ * @attr: the device attribute struct
++ * @buf: a pointer to the output buffer
++ *
++ * This routine is a callback routine to read a scancode filter value or mask.
++ * It is trigged by reading /sys/class/rc/rc?/[wakeup_]filter[_mask].
++ * It prints the current scancode filter value or mask of the appropriate filter
++ * type in hexadecimal into @buf and returns the size of the buffer.
++ *
++ * Bits of the filter value corresponding to set bits in the filter mask are
++ * compared against input scancodes and non-matching scancodes are discarded.
++ *
++ * dev->lock is taken to guard against races between device registration,
++ * store_filter and show_filter.
++ */
++static ssize_t show_filter(struct device *device,
++ struct device_attribute *attr,
++ char *buf)
++{
++ struct rc_dev *dev = to_rc_dev(device);
++ struct rc_filter_attribute *fattr = to_rc_filter_attr(attr);
++ u32 val;
++
++ /* Device is being removed */
++ if (!dev)
++ return -EINVAL;
++
++ mutex_lock(&dev->lock);
++ if (fattr->mask)
++ val = dev->scancode_filters[fattr->type].mask;
++ else
++ val = dev->scancode_filters[fattr->type].data;
++ mutex_unlock(&dev->lock);
++
++ return sprintf(buf, "%#x\n", val);
++}
++
++/**
++ * store_filter() - changes the scancode filter value
++ * @device: the device descriptor
++ * @attr: the device attribute struct
++ * @buf: a pointer to the input buffer
++ * @len: length of the input buffer
++ *
++ * This routine is for changing a scancode filter value or mask.
++ * It is trigged by writing to /sys/class/rc/rc?/[wakeup_]filter[_mask].
++ * Returns -EINVAL if an invalid filter value for the current protocol was
++ * specified or if scancode filtering is not supported by the driver, otherwise
++ * returns @len.
++ *
++ * Bits of the filter value corresponding to set bits in the filter mask are
++ * compared against input scancodes and non-matching scancodes are discarded.
++ *
++ * dev->lock is taken to guard against races between device registration,
++ * store_filter and show_filter.
++ */
++static ssize_t store_filter(struct device *device,
++ struct device_attribute *attr,
++ const char *buf,
++ size_t count)
++{
++ struct rc_dev *dev = to_rc_dev(device);
++ struct rc_filter_attribute *fattr = to_rc_filter_attr(attr);
++ struct rc_scancode_filter local_filter, *filter;
++ int ret;
++ unsigned long val;
++
++ /* Device is being removed */
++ if (!dev)
++ return -EINVAL;
++
++ ret = kstrtoul(buf, 0, &val);
++ if (ret < 0)
++ return ret;
++
++ /* Scancode filter not supported (but still accept 0) */
++ if (!dev->s_filter && fattr->type != RC_FILTER_NORMAL)
++ return val ? -EINVAL : count;
++
++ mutex_lock(&dev->lock);
++
++ /* Tell the driver about the new filter */
++ filter = &dev->scancode_filters[fattr->type];
++ local_filter = *filter;
++ if (fattr->mask)
++ local_filter.mask = val;
++ else
++ local_filter.data = val;
+ if (!dev->enabled_protocols[fattr->type] && local_filter.mask) {
+ /* refuse to set a filter unless a protocol is enabled */
+ ret = -EINVAL;
+ goto unlock;
+ }
- if (dev->s_filter) {
- ret = dev->s_filter(dev, fattr->type, &local_filter);
- if (ret < 0)
-From 262912335c823a2bbcc87003ee55d62cc27f4e48 Mon Sep 17 00:00:00 2001
-From: James Hogan <james.hogan@imgtec.com>
-Date: Sat, 1 Mar 2014 19:52:25 -0300
-Subject: [PATCH] [media] rc-main: fix missing unlock if no devno left
-
-While playing with make coccicheck I noticed this message:
-drivers/media/rc/rc-main.c:1245:3-9: preceding lock on line 1238
-
-It was introduced by commit 587d1b06e07b ([media] rc-core: reuse device
-numbers) which returns -ENOMEM after a mutex_lock without first
-unlocking it when there are no more device numbers left. The added code
-doesn't depend on the device lock, so move it before the lock is taken.
-
-Signed-off-by: James Hogan <james.hogan@imgtec.com>
-Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
----
- drivers/media/rc/rc-main.c | 16 ++++++++--------
- 1 file changed, 8 insertions(+), 8 deletions(-)
-
-diff --git a/drivers/media/rc/rc-main.c b/drivers/media/rc/rc-main.c
-index b1a6900..f87e0f0 100644
---- a/drivers/media/rc/rc-main.c
-+++ b/drivers/media/rc/rc-main.c
-@@ -1286,14 +1286,6 @@ int rc_register_device(struct rc_dev *dev)
++ if (dev->s_filter) {
++ ret = dev->s_filter(dev, fattr->type, &local_filter);
++ if (ret < 0)
++ goto unlock;
++ }
++
++ /* Success, commit the new filter */
++ *filter = local_filter;
++
++unlock:
++ mutex_unlock(&dev->lock);
++ return (ret < 0) ? ret : count;
++}
++
+ static void rc_dev_release(struct device *device)
+ {
+ }
+@@ -996,11 +1174,26 @@ static int rc_dev_uevent(struct device *
+ /*
+ * Static device attribute struct with the sysfs attributes for IR's
+ */
+-static DEVICE_ATTR(protocols, S_IRUGO | S_IWUSR,
+- show_protocols, store_protocols);
++static RC_PROTO_ATTR(protocols, S_IRUGO | S_IWUSR,
++ show_protocols, store_protocols, RC_FILTER_NORMAL);
++static RC_PROTO_ATTR(wakeup_protocols, S_IRUGO | S_IWUSR,
++ show_protocols, store_protocols, RC_FILTER_WAKEUP);
++static RC_FILTER_ATTR(filter, S_IRUGO|S_IWUSR,
++ show_filter, store_filter, RC_FILTER_NORMAL, false);
++static RC_FILTER_ATTR(filter_mask, S_IRUGO|S_IWUSR,
++ show_filter, store_filter, RC_FILTER_NORMAL, true);
++static RC_FILTER_ATTR(wakeup_filter, S_IRUGO|S_IWUSR,
++ show_filter, store_filter, RC_FILTER_WAKEUP, false);
++static RC_FILTER_ATTR(wakeup_filter_mask, S_IRUGO|S_IWUSR,
++ show_filter, store_filter, RC_FILTER_WAKEUP, true);
+
+ static struct attribute *rc_dev_attrs[] = {
+- &dev_attr_protocols.attr,
++ &dev_attr_protocols.attr.attr,
++ &dev_attr_wakeup_protocols.attr.attr,
++ &dev_attr_filter.attr.attr,
++ &dev_attr_filter_mask.attr.attr,
++ &dev_attr_wakeup_filter.attr.attr,
++ &dev_attr_wakeup_filter_mask.attr.attr,
+ NULL,
+ };
+
+@@ -1091,14 +1284,6 @@ int rc_register_device(struct rc_dev *de
if (dev->close)
dev->input_dev->close = ir_close;
do {
devno = find_first_zero_bit(ir_core_dev_number,
IRRCV_NUM_DEVICES);
-@@ -1302,6 +1294,14 @@ int rc_register_device(struct rc_dev *dev)
+@@ -1107,6 +1292,14 @@ int rc_register_device(struct rc_dev *de
return -ENOMEM;
} while (test_and_set_bit(devno, ir_core_dev_number));
dev->devno = devno;
dev_set_name(&dev->dev, "rc%ld", dev->devno);
dev_set_drvdata(&dev->dev, dev);
+@@ -1172,7 +1365,7 @@ int rc_register_device(struct rc_dev *de
+ rc = dev->change_protocol(dev, &rc_type);
+ if (rc < 0)
+ goto out_raw;
+- dev->enabled_protocols = rc_type;
++ dev->enabled_protocols[RC_FILTER_NORMAL] = rc_type;
+ }
+
+ mutex_unlock(&dev->lock);
+--- a/drivers/media/rc/redrat3.c
++++ b/drivers/media/rc/redrat3.c
+@@ -922,7 +922,7 @@ static struct rc_dev *redrat3_init_rc_de
+ rc->dev.parent = dev;
+ rc->priv = rr3;
+ rc->driver_type = RC_DRIVER_IR_RAW;
+- rc->allowed_protos = RC_BIT_ALL;
++ rc_set_allowed_protocols(rc, RC_BIT_ALL);
+ rc->timeout = US_TO_NS(2750);
+ rc->tx_ir = redrat3_transmit_ir;
+ rc->s_tx_carrier = redrat3_set_tx_carrier;
+--- a/drivers/media/rc/st_rc.c
++++ b/drivers/media/rc/st_rc.c
+@@ -287,7 +287,7 @@ static int st_rc_probe(struct platform_d
+ st_rc_hardware_init(rc_dev);
+
+ rdev->driver_type = RC_DRIVER_IR_RAW;
+- rdev->allowed_protos = RC_BIT_ALL;
++ rc_set_allowed_protocols(rdev, RC_BIT_ALL);
+ /* rx sampling rate is 10Mhz */
+ rdev->rx_resolution = 100;
+ rdev->timeout = US_TO_NS(MAX_SYMB_TIME);
+--- a/drivers/media/rc/streamzap.c
++++ b/drivers/media/rc/streamzap.c
+@@ -322,7 +322,7 @@ static struct rc_dev *streamzap_init_rc_
+ rdev->dev.parent = dev;
+ rdev->priv = sz;
+ rdev->driver_type = RC_DRIVER_IR_RAW;
+- rdev->allowed_protos = RC_BIT_ALL;
++ rc_set_allowed_protocols(rdev, RC_BIT_ALL);
+ rdev->driver_name = DRIVER_NAME;
+ rdev->map_name = RC_MAP_STREAMZAP;
+
+--- a/drivers/media/rc/ttusbir.c
++++ b/drivers/media/rc/ttusbir.c
+@@ -318,7 +318,7 @@ static int ttusbir_probe(struct usb_inte
+ usb_to_input_id(tt->udev, &rc->input_id);
+ rc->dev.parent = &intf->dev;
+ rc->driver_type = RC_DRIVER_IR_RAW;
+- rc->allowed_protos = RC_BIT_ALL;
++ rc_set_allowed_protocols(rc, RC_BIT_ALL);
+ rc->priv = tt;
+ rc->driver_name = DRIVER_NAME;
+ rc->map_name = RC_MAP_TT_1500;
+--- a/drivers/media/rc/winbond-cir.c
++++ b/drivers/media/rc/winbond-cir.c
+@@ -1082,7 +1082,7 @@ wbcir_probe(struct pnp_dev *device, cons
+ data->dev->dev.parent = &device->dev;
+ data->dev->timeout = MS_TO_NS(100);
+ data->dev->rx_resolution = US_TO_NS(2);
+- data->dev->allowed_protos = RC_BIT_ALL;
++ rc_set_allowed_protocols(data->dev, RC_BIT_ALL);
+
+ err = rc_register_device(data->dev);
+ if (err)
+--- a/drivers/media/usb/dvb-usb/dvb-usb-remote.c
++++ b/drivers/media/usb/dvb-usb/dvb-usb-remote.c
+@@ -272,7 +272,7 @@ static int rc_core_dvb_usb_remote_init(s
+ dev->driver_name = d->props.rc.core.module_name;
+ dev->map_name = d->props.rc.core.rc_codes;
+ dev->change_protocol = d->props.rc.core.change_protocol;
+- dev->allowed_protos = d->props.rc.core.allowed_protos;
++ rc_set_allowed_protocols(dev, d->props.rc.core.allowed_protos);
+ dev->driver_type = d->props.rc.core.driver_type;
+ usb_to_input_id(d->udev, &dev->input_id);
+ dev->input_name = "IR-receiver inside an USB DVB receiver";
+--- a/drivers/media/usb/dvb-usb-v2/dvb_usb_core.c
++++ b/drivers/media/usb/dvb-usb-v2/dvb_usb_core.c
+@@ -164,7 +164,7 @@ static int dvb_usbv2_remote_init(struct
+ dev->driver_name = (char *) d->props->driver_name;
+ dev->map_name = d->rc.map_name;
+ dev->driver_type = d->rc.driver_type;
+- dev->allowed_protos = d->rc.allowed_protos;
++ rc_set_allowed_protocols(dev, d->rc.allowed_protos);
+ dev->change_protocol = d->rc.change_protocol;
+ dev->priv = d;
+
+--- a/drivers/media/usb/em28xx/em28xx-input.c
++++ b/drivers/media/usb/em28xx/em28xx-input.c
+@@ -725,7 +725,7 @@ static int em28xx_ir_init(struct em28xx
+ case EM2820_BOARD_HAUPPAUGE_WINTV_USB_2:
+ rc->map_name = RC_MAP_HAUPPAUGE;
+ ir->get_key_i2c = em28xx_get_key_em_haup;
+- rc->allowed_protos = RC_BIT_RC5;
++ rc_set_allowed_protocols(rc, RC_BIT_RC5);
+ break;
+ case EM2820_BOARD_LEADTEK_WINFAST_USBII_DELUXE:
+ rc->map_name = RC_MAP_WINFAST_USBII_DELUXE;
+@@ -741,7 +741,7 @@ static int em28xx_ir_init(struct em28xx
+ switch (dev->chip_id) {
+ case CHIP_ID_EM2860:
+ case CHIP_ID_EM2883:
+- rc->allowed_protos = RC_BIT_RC5 | RC_BIT_NEC;
++ rc_set_allowed_protocols(rc, RC_BIT_RC5 | RC_BIT_NEC);
+ ir->get_key = default_polling_getkey;
+ break;
+ case CHIP_ID_EM2884:
+@@ -749,8 +749,8 @@ static int em28xx_ir_init(struct em28xx
+ case CHIP_ID_EM28174:
+ case CHIP_ID_EM28178:
+ ir->get_key = em2874_polling_getkey;
+- rc->allowed_protos = RC_BIT_RC5 | RC_BIT_NEC |
+- RC_BIT_RC6_0;
++ rc_set_allowed_protocols(rc, RC_BIT_RC5 | RC_BIT_NEC |
++ RC_BIT_RC6_0);
+ break;
+ default:
+ err = -ENODEV;
+--- a/drivers/media/usb/tm6000/tm6000-input.c
++++ b/drivers/media/usb/tm6000/tm6000-input.c
+@@ -422,7 +422,7 @@ int tm6000_ir_init(struct tm6000_core *d
+ ir->rc = rc;
+
+ /* input setup */
+- rc->allowed_protos = RC_BIT_RC5 | RC_BIT_NEC;
++ rc_set_allowed_protocols(rc, RC_BIT_RC5 | RC_BIT_NEC);
+ /* Neded, in order to support NEC remotes with 24 or 32 bits */
+ rc->scanmask = 0xffff;
+ rc->priv = ir;
+--- a/include/media/rc-core.h
++++ b/include/media/rc-core.h
+@@ -35,6 +35,29 @@ enum rc_driver_type {
+ };
+
+ /**
++ * struct rc_scancode_filter - Filter scan codes.
++ * @data: Scancode data to match.
++ * @mask: Mask of bits of scancode to compare.
++ */
++struct rc_scancode_filter {
++ u32 data;
++ u32 mask;
++};
++
++/**
++ * enum rc_filter_type - Filter type constants.
++ * @RC_FILTER_NORMAL: Filter for normal operation.
++ * @RC_FILTER_WAKEUP: Filter for waking from suspend.
++ * @RC_FILTER_MAX: Number of filter types.
++ */
++enum rc_filter_type {
++ RC_FILTER_NORMAL = 0,
++ RC_FILTER_WAKEUP,
++
++ RC_FILTER_MAX
++};
++
++/**
+ * struct rc_dev - represents a remote control device
+ * @dev: driver model's view of this device
+ * @input_name: name of the input child device
+@@ -50,8 +73,10 @@ enum rc_driver_type {
+ * @input_dev: the input child device used to communicate events to userspace
+ * @driver_type: specifies if protocol decoding is done in hardware or software
+ * @idle: used to keep track of RX state
+- * @allowed_protos: bitmask with the supported RC_BIT_* protocols
+- * @enabled_protocols: bitmask with the enabled RC_BIT_* protocols
++ * @allowed_protocols: bitmask with the supported RC_BIT_* protocols for each
++ * filter type
++ * @enabled_protocols: bitmask with the enabled RC_BIT_* protocols for each
++ * filter type
+ * @scanmask: some hardware decoders are not capable of providing the full
+ * scancode to the application. As this is a hardware limit, we can't do
+ * anything with it. Yet, as the same keycode table can be used with other
+@@ -70,7 +95,10 @@ enum rc_driver_type {
+ * @max_timeout: maximum timeout supported by device
+ * @rx_resolution : resolution (in ns) of input sampler
+ * @tx_resolution: resolution (in ns) of output sampler
++ * @scancode_filters: scancode filters (indexed by enum rc_filter_type)
+ * @change_protocol: allow changing the protocol used on hardware decoders
++ * @change_wakeup_protocol: allow changing the protocol used for wakeup
++ * filtering
+ * @open: callback to allow drivers to enable polling/irq when IR input device
+ * is opened.
+ * @close: callback to allow drivers to disable polling/irq when IR input device
+@@ -84,6 +112,7 @@ enum rc_driver_type {
+ * device doesn't interrupt host until it sees IR pulses
+ * @s_learning_mode: enable wide band receiver used for learning
+ * @s_carrier_report: enable carrier reports
++ * @s_filter: set the scancode filter of a given type
+ */
+ struct rc_dev {
+ struct device dev;
+@@ -99,8 +128,8 @@ struct rc_dev {
+ struct input_dev *input_dev;
+ enum rc_driver_type driver_type;
+ bool idle;
+- u64 allowed_protos;
+- u64 enabled_protocols;
++ u64 allowed_protocols[RC_FILTER_MAX];
++ u64 enabled_protocols[RC_FILTER_MAX];
+ u32 users;
+ u32 scanmask;
+ void *priv;
+@@ -116,7 +145,9 @@ struct rc_dev {
+ u32 max_timeout;
+ u32 rx_resolution;
+ u32 tx_resolution;
++ struct rc_scancode_filter scancode_filters[RC_FILTER_MAX];
+ int (*change_protocol)(struct rc_dev *dev, u64 *rc_type);
++ int (*change_wakeup_protocol)(struct rc_dev *dev, u64 *rc_type);
+ int (*open)(struct rc_dev *dev);
+ void (*close)(struct rc_dev *dev);
+ int (*s_tx_mask)(struct rc_dev *dev, u32 mask);
+@@ -127,10 +158,49 @@ struct rc_dev {
+ void (*s_idle)(struct rc_dev *dev, bool enable);
+ int (*s_learning_mode)(struct rc_dev *dev, int enable);
+ int (*s_carrier_report) (struct rc_dev *dev, int enable);
++ int (*s_filter)(struct rc_dev *dev,
++ enum rc_filter_type type,
++ struct rc_scancode_filter *filter);
+ };
+
+ #define to_rc_dev(d) container_of(d, struct rc_dev, dev)
+
++static inline bool rc_protocols_allowed(struct rc_dev *rdev, u64 protos)
++{
++ return rdev->allowed_protocols[RC_FILTER_NORMAL] & protos;
++}
++
++/* should be called prior to registration or with mutex held */
++static inline void rc_set_allowed_protocols(struct rc_dev *rdev, u64 protos)
++{
++ rdev->allowed_protocols[RC_FILTER_NORMAL] = protos;
++}
++
++static inline bool rc_protocols_enabled(struct rc_dev *rdev, u64 protos)
++{
++ return rdev->enabled_protocols[RC_FILTER_NORMAL] & protos;
++}
++
++/* should be called prior to registration or with mutex held */
++static inline void rc_set_enabled_protocols(struct rc_dev *rdev, u64 protos)
++{
++ rdev->enabled_protocols[RC_FILTER_NORMAL] = protos;
++}
++
++/* should be called prior to registration or with mutex held */
++static inline void rc_set_allowed_wakeup_protocols(struct rc_dev *rdev,
++ u64 protos)
++{
++ rdev->allowed_protocols[RC_FILTER_WAKEUP] = protos;
++}
++
++/* should be called prior to registration or with mutex held */
++static inline void rc_set_enabled_wakeup_protocols(struct rc_dev *rdev,
++ u64 protos)
++{
++ rdev->enabled_protocols[RC_FILTER_WAKEUP] = protos;
++}
++
+ /*
+ * From rc-main.c
+ * Those functions can be used on any type of Remote Controller. They
-diff -ruN old/arch/arm/boot/dts/sun7i-a20-bananapi.dts new/arch/arm/boot/dts/sun7i-a20-bananapi.dts
-diff -ruN old/arch/arm/boot/dts/sun7i-a20-cubietruck.dts new/arch/arm/boot/dts/sun7i-a20-cubietruck.dts
-diff -ruN old/arch/arm/boot/dts/sun7i-a20-pcduino3.dts new/arch/arm/boot/dts/sun7i-a20-pcduino3.dts
---- old/arch/arm/boot/dts/sun7i-a20-pcduino3.dts 1970-01-01 01:00:00.000000000 +0100
-+++ new/arch/arm/boot/dts/sun7i-a20-pcduino3.dts 2014-10-23 15:44:48.000000000 +0200
+--- /dev/null
++++ b/arch/arm/boot/dts/sun7i-a20-pcduino3.dts
@@ -0,0 +1,153 @@
+/*
+ * Copyright 2014 Zoltan HERPAI
-diff -ruN old/arch/arm/boot/dts/sun7i-a20-bananapi.dts new/arch/arm/boot/dts/sun7i-a20-bananapi.dts
---- old/arch/arm/boot/dts/sun7i-a20-bananapi.dts 1970-01-01 01:00:00.000000000 +0100
-+++ new/arch/arm/boot/dts/sun7i-a20-bananapi.dts 2014-10-23 15:44:48.000000000 +0200
+--- /dev/null
++++ b/arch/arm/boot/dts/sun7i-a20-bananapi.dts
@@ -0,0 +1,160 @@
+/*
+ * Copyright 2014 Zoltan HERPAI
+ };
+ };
+};
-diff -ruN old/arch/arm/boot/dts/sun7i-a20-cubietruck.dts new/arch/arm/boot/dts/sun7i-a20-cubietruck.dts
-diff -ruN old/arch/arm/boot/dts/sun7i-a20-pcduino3.dts new/arch/arm/boot/dts/sun7i-a20-pcduino3.dts
-diff -ruN old/arch/arm/boot/dts/sun7i-a20-pcduino3.dts new/arch/arm/boot/dts/sun7i-a20-pcduino3.dts
---- old/arch/arm/boot/dts/sun7i-a20-pcduino3.dts 2014-09-17 02:13:59.000000000 +0200
-+++ new/arch/arm/boot/dts/sun7i-a20-pcduino3.dts 2014-09-18 01:03:31.356359755 +0200
+--- a/arch/arm/boot/dts/sun7i-a20-pcduino3.dts
++++ b/arch/arm/boot/dts/sun7i-a20-pcduino3.dts
@@ -149,4 +149,17 @@
default-state = "on";
};
-diff -ruN old/arch/arm/boot/dts/sun7i-a20-bananapi.dts new/arch/arm/boot/dts/sun7i-a20-bananapi.dts
---- old/arch/arm/boot/dts/sun7i-a20-bananapi.dts 2014-09-17 02:13:59.000000000 +0200
-+++ new/arch/arm/boot/dts/sun7i-a20-bananapi.dts 2014-09-18 01:03:31.356359755 +0200
-@@ -149,4 +149,17 @@
+--- a/arch/arm/boot/dts/sun7i-a20-bananapi.dts
++++ b/arch/arm/boot/dts/sun7i-a20-bananapi.dts
+@@ -156,4 +156,17 @@
default-state = "on";
};
};
-diff -ruN old/arch/arm/boot/dts/sun7i-a20-bananapi.dts new/arch/arm/boot/dts/sun7i-a20-bananapi.dts
---- old/arch/arm/boot/dts/sun7i-a20-bananapi.dts 2014-09-19 01:08:58.000000000 +0200
-+++ new/arch/arm/boot/dts/sun7i-a20-bananapi.dts 2014-09-19 01:05:02.000000000 +0200
+--- a/arch/arm/boot/dts/sun7i-a20-bananapi.dts
++++ b/arch/arm/boot/dts/sun7i-a20-bananapi.dts
@@ -86,6 +86,13 @@
allwinner,drive = <0>;
allwinner,pull = <1>;
-diff -ruN old/arch/arm/boot/dts/sun7i-a20-bananapi.dts new/arch/arm/boot/dts/sun7i-a20-bananapi.dts
---- old/arch/arm/boot/dts/sun7i-a20-bananapi.dts 2014-09-21 19:34:10.000000000 +0200
-+++ new/arch/arm/boot/dts/sun7i-a20-bananapi.dts 2014-09-21 19:37:36.823824016 +0200
-@@ -131,6 +131,14 @@
+--- a/arch/arm/boot/dts/sun7i-a20-bananapi.dts
++++ b/arch/arm/boot/dts/sun7i-a20-bananapi.dts
+@@ -125,6 +125,14 @@
pinctrl-names = "default";
pinctrl-0 = <&i2c0_pins_a>;
status = "okay";
-diff -ruN old/arch/arm/boot/dts/sun7i-a20-pcduino3.dts new/arch/arm/boot/dts/sun7i-a20-pcduino3.dts
---- old/arch/arm/boot/dts/sun7i-a20-pcduino3.dts 2014-09-21 19:38:51.000000000 +0200
-+++ new/arch/arm/boot/dts/sun7i-a20-pcduino3.dts 2014-09-21 22:16:11.287396074 +0200
+--- a/arch/arm/boot/dts/sun7i-a20-pcduino3.dts
++++ b/arch/arm/boot/dts/sun7i-a20-pcduino3.dts
@@ -111,6 +111,14 @@
pinctrl-names = "default";
pinctrl-0 = <&i2c0_pins_a>;
arch/arm/boot/dts/sun7i-a20-cubietruck.dts | 6 ++++++
2 files changed, 12 insertions(+)
-diff --git a/arch/arm/boot/dts/sun7i-a20-bananapi.dts b/arch/arm/boot/dts/sun7i-a20-bananapi.dts
-index 97bcb2a..81bf3df 100644
--- a/arch/arm/boot/dts/sun7i-a20-bananapi.dts
+++ b/arch/arm/boot/dts/sun7i-a20-bananapi.dts
-@@ -66,6 +66,12 @@
- };
+@@ -103,6 +103,12 @@
+ status = "okay";
};
+ ir0: ir@01c21800 {