brcm63xx: remove linux 3.14 support
authorFelix Fietkau <nbd@openwrt.org>
Sat, 28 Mar 2015 13:21:09 +0000 (13:21 +0000)
committerFelix Fietkau <nbd@openwrt.org>
Sat, 28 Mar 2015 13:21:09 +0000 (13:21 +0000)
Signed-off-by: Felix Fietkau <nbd@openwrt.org>
SVN-Revision: 45089

184 files changed:
target/linux/brcm63xx/config-3.14 [deleted file]
target/linux/brcm63xx/patches-3.14/001-of-Create-unlocked-version-of-for_each_child_of_node.patch [deleted file]
target/linux/brcm63xx/patches-3.14/001-spi-spi-gpio-Add-dt-support-for-a-single-device-with.patch [deleted file]
target/linux/brcm63xx/patches-3.14/002-lib-add-glibc-style-strchrnul-variant.patch [deleted file]
target/linux/brcm63xx/patches-3.14/003-of-Make-of_find_node_by_path-handle-aliases.patch [deleted file]
target/linux/brcm63xx/patches-3.14/010-MIPS-BCM63XX-remove-RUNTIME_DETECT-code-from-registe.patch [deleted file]
target/linux/brcm63xx/patches-3.14/011-MIPS-BCM63XX-remove-RUNTIME_DETECT-from-irq-setup-co.patch [deleted file]
target/linux/brcm63xx/patches-3.14/012-MIPS-BCM63XX-remove-RUNTIME_DETECT-from-reset-code.patch [deleted file]
target/linux/brcm63xx/patches-3.14/013-MIPS-BCM63XX-remove-RUNTIME_DETECT-code-from-gpio.patch [deleted file]
target/linux/brcm63xx/patches-3.14/014-MIPS-BCM63XX-remove-RUNTIME_DETECT-from-spi-code.patch [deleted file]
target/linux/brcm63xx/patches-3.14/015-MIPS-BCM63XX-remove-RUNTIME_DETECT-usage-from-enet-c.patch [deleted file]
target/linux/brcm63xx/patches-3.14/016-MIPS-BCM63XX-remove-RUNTIME_DETECT-in-cpu-feature-ov.patch [deleted file]
target/linux/brcm63xx/patches-3.14/017-MIPS-BCM63XX-remove-RUNTIME_DETECT-code-for-bcmcpu_g.patch [deleted file]
target/linux/brcm63xx/patches-3.14/018-MIPS-BCM63XX-add-width-to-__dispatch_internal.patch [deleted file]
target/linux/brcm63xx/patches-3.14/019-MIPS-BCM63XX-move-bcm63xx_init_irq-down.patch [deleted file]
target/linux/brcm63xx/patches-3.14/020-MIPS-BCM63XX-replace-irq-dispatch-code-with-a-generi.patch [deleted file]
target/linux/brcm63xx/patches-3.14/021-MIPS-BCM63XX-append-irq-line-to-irq_-stat-mask.patch [deleted file]
target/linux/brcm63xx/patches-3.14/022-MIPS-BCM63XX-populate-irq_-stat-mask-_addr-for-secon.patch [deleted file]
target/linux/brcm63xx/patches-3.14/023-MIPS-BCM63XX-add-cpu-argument-to-dispatch-internal.patch [deleted file]
target/linux/brcm63xx/patches-3.14/024-MIPS-BCM63XX-protect-irq-register-accesses.patch [deleted file]
target/linux/brcm63xx/patches-3.14/025-MIPS-BCM63XX-wire-up-the-second-cpu-s-irq-line.patch [deleted file]
target/linux/brcm63xx/patches-3.14/026-MIPS-BCM63XX-use-irq_desc-as-argument-for-un-mask.patch [deleted file]
target/linux/brcm63xx/patches-3.14/027-MIPS-BCM63XX-allow-setting-affinity-for-IPIC.patch [deleted file]
target/linux/brcm63xx/patches-3.14/030-MIPS-Always-use-IRQ-domains-for-CPU-IRQs.patch [deleted file]
target/linux/brcm63xx/patches-3.14/031-MIPS-Rename-mips_cpu_intc_init-mips_cpu_irq_of_init.patch [deleted file]
target/linux/brcm63xx/patches-3.14/032-MIPS-Provide-a-generic-plat_irq_dispatch.patch [deleted file]
target/linux/brcm63xx/patches-3.14/100-MIPS-BCM63XX-add-USB-host-clock-enable-delay.patch [deleted file]
target/linux/brcm63xx/patches-3.14/101-MIPS-BCM63XX-add-USB-device-clock-enable-delay-to-cl.patch [deleted file]
target/linux/brcm63xx/patches-3.14/101-MIPS-BCM63XX-sync-mips-counter-during-cpu-bringup.patch [deleted file]
target/linux/brcm63xx/patches-3.14/102-MIPS-BCM63XX-move-code-touching-the-USB-private-regi.patch [deleted file]
target/linux/brcm63xx/patches-3.14/103-MIPS-BCM63XX-add-OHCI-EHCI-configuration-bits-to-com.patch [deleted file]
target/linux/brcm63xx/patches-3.14/104-MIPS-BCM63XX-introduce-BCM63XX_OHCI-configuration-sy.patch [deleted file]
target/linux/brcm63xx/patches-3.14/105-MIPS-BCM63XX-add-support-for-the-on-chip-OHCI-contro.patch [deleted file]
target/linux/brcm63xx/patches-3.14/106-MIPS-BCM63XX-register-OHCI-controller-if-board-enabl.patch [deleted file]
target/linux/brcm63xx/patches-3.14/107-MIPS-BCM63XX-introduce-BCM63XX_EHCI-configuration-sy.patch [deleted file]
target/linux/brcm63xx/patches-3.14/108-MIPS-BCM63XX-add-support-for-the-on-chip-EHCI-contro.patch [deleted file]
target/linux/brcm63xx/patches-3.14/109-MIPS-BCM63XX-register-EHCI-controller-if-board-enabl.patch [deleted file]
target/linux/brcm63xx/patches-3.14/110-MIPS-BCM63XX-EHCI-controller-does-not-support-overcu.patch [deleted file]
target/linux/brcm63xx/patches-3.14/201-SPI-Allow-specifying-the-parsers-for-SPI-flash.patch [deleted file]
target/linux/brcm63xx/patches-3.14/202-MTD-DEVICES-m25p80-use-parsers-if-provided-in-flash-.patch [deleted file]
target/linux/brcm63xx/patches-3.14/203-MTD-DEVICES-m25p80-add-support-for-limiting-reads.patch [deleted file]
target/linux/brcm63xx/patches-3.14/204-USB-OHCI-allow-other-arches-to-use-the-BE-frame-numb.patch [deleted file]
target/linux/brcm63xx/patches-3.14/206-USB-EHCI-allow-limiting-ports-for-ehci-platform.patch [deleted file]
target/linux/brcm63xx/patches-3.14/207-MIPS-BCM63XX-move-device-registration-code-into-its-.patch [deleted file]
target/linux/brcm63xx/patches-3.14/208-MIPS-BCM63XX-pass-a-mac-addresss-allocator-to-board-.patch [deleted file]
target/linux/brcm63xx/patches-3.14/300-reset_buttons.patch [deleted file]
target/linux/brcm63xx/patches-3.14/301-led_count.patch [deleted file]
target/linux/brcm63xx/patches-3.14/302-extended-platform-devices.patch [deleted file]
target/linux/brcm63xx/patches-3.14/303-spi-board-info.patch [deleted file]
target/linux/brcm63xx/patches-3.14/309-cfe_version_mod.patch [deleted file]
target/linux/brcm63xx/patches-3.14/310-cfe_simplify_detection.patch [deleted file]
target/linux/brcm63xx/patches-3.14/311-bcm63xxpart_use_cfedetection.patch [deleted file]
target/linux/brcm63xx/patches-3.14/320-irqchip-add-support-for-bcm6345-style-periphery-irq-.patch [deleted file]
target/linux/brcm63xx/patches-3.14/321-irqchip-add-support-for-bcm6345-style-external-inter.patch [deleted file]
target/linux/brcm63xx/patches-3.14/322-MIPS-BCM63XX-switch-to-IRQ_DOMAIN.patch [deleted file]
target/linux/brcm63xx/patches-3.14/323-MIPS-BCM63XX-wire-up-BCM6358-s-external-interrupts-4.patch [deleted file]
target/linux/brcm63xx/patches-3.14/330-MIPS-BCM63XX-add-a-new-cpu-variant-helper.patch [deleted file]
target/linux/brcm63xx/patches-3.14/331-MIPS-BCM63XX-define-variant-id-field.patch [deleted file]
target/linux/brcm63xx/patches-3.14/332-MIPS-BCM63XX-detect-BCM6328-variants.patch [deleted file]
target/linux/brcm63xx/patches-3.14/333-MIPS-BCM63XX-detect-BCM6362-variants.patch [deleted file]
target/linux/brcm63xx/patches-3.14/334-MIPS-BCM63XX-detect-BCM6368-variants.patch [deleted file]
target/linux/brcm63xx/patches-3.14/335-MIPS-BCM63XX-fix-PCIe-memory-window-size.patch [deleted file]
target/linux/brcm63xx/patches-3.14/336-MIPS-BCM63XX-dynamically-set-the-pcie-memory-windows.patch [deleted file]
target/linux/brcm63xx/patches-3.14/337-MIPS-BCM63XX-widen-cpuid-field.patch [deleted file]
target/linux/brcm63xx/patches-3.14/338-MIPS-BCM63XX-increase-number-of-IRQs.patch [deleted file]
target/linux/brcm63xx/patches-3.14/339-MIPS-BCM63XX-add-support-for-BCM63268.patch [deleted file]
target/linux/brcm63xx/patches-3.14/340-MIPS-BCM63XX-add-pcie-support-for-BCM63268.patch [deleted file]
target/linux/brcm63xx/patches-3.14/341-MIPS-BCM63XX-add-support-for-BCM6318.patch [deleted file]
target/linux/brcm63xx/patches-3.14/342-MIPS-BCM63XX-split-PCIe-reset-signals.patch [deleted file]
target/linux/brcm63xx/patches-3.14/343-MIPS-BCM63XX-add-PCIe-support-for-BCM6318.patch [deleted file]
target/linux/brcm63xx/patches-3.14/344-MIPS-BCM63XX-detect-flash-type-early-and-store-the-r.patch [deleted file]
target/linux/brcm63xx/patches-3.14/345-MIPS-BCM63XX-fixup-mapped-SPI-flash-access-on-boot.patch [deleted file]
target/linux/brcm63xx/patches-3.14/346-MIPS-BCM63XX-USB-ENETSW-6318-clocks.patch [deleted file]
target/linux/brcm63xx/patches-3.14/347-MIPS-BCM6318-USB-support.patch [deleted file]
target/linux/brcm63xx/patches-3.14/348-MIPS-BCM63XX-fix-BCM63268-USB-clock.patch [deleted file]
target/linux/brcm63xx/patches-3.14/349-MIPS-BCM63XX-add-BCM63268-USB-support.patch [deleted file]
target/linux/brcm63xx/patches-3.14/350-MIPS-BCM63XX-support-settings-num-usbh-ports.patch [deleted file]
target/linux/brcm63xx/patches-3.14/351-set-board-usbh-ports.patch [deleted file]
target/linux/brcm63xx/patches-3.14/354-MIPS-BCM63XX-allow-building-support-for-more-than-on.patch [deleted file]
target/linux/brcm63xx/patches-3.14/355-MIPS-BCM63XX-allow-board-implementations-to-force-fl.patch [deleted file]
target/linux/brcm63xx/patches-3.14/356-MIPS-BCM63XX-move-fallback-sprom-support-into-its-ow.patch [deleted file]
target/linux/brcm63xx/patches-3.14/357-MIPS-BCM63XX-use-platform-data-for-the-sprom.patch [deleted file]
target/linux/brcm63xx/patches-3.14/358-MIPS-BCM63XX-make-fallback-sprom-optional.patch [deleted file]
target/linux/brcm63xx/patches-3.14/359-MIPS-BCM63XX-allow-different-types-of-sprom.patch [deleted file]
target/linux/brcm63xx/patches-3.14/360-MIPS-BCM63XX-add-support-for-raw-sproms.patch [deleted file]
target/linux/brcm63xx/patches-3.14/361-MIPS-BCM63XX-add-raw-fallback-sproms-for-most-common.patch [deleted file]
target/linux/brcm63xx/patches-3.14/362-MIPS-BCM63XX-also-register-a-fallback-sprom-for-bcma.patch [deleted file]
target/linux/brcm63xx/patches-3.14/363-MIPS-BCM63XX-add-BCMA-based-sprom-templates.patch [deleted file]
target/linux/brcm63xx/patches-3.14/364-MIPS-BCM63XX-allow-board-files-to-provide-sprom-fixu.patch [deleted file]
target/linux/brcm63xx/patches-3.14/365-MIPS-BCM63XX-allow-setting-a-pci-bus-device-for-fall.patch [deleted file]
target/linux/brcm63xx/patches-3.14/366-MIPS-add-support-for-vmlinux.bin-appended-DTB.patch [deleted file]
target/linux/brcm63xx/patches-3.14/367-MIPS-BCM63XX-add-support-for-loading-DTB.patch [deleted file]
target/linux/brcm63xx/patches-3.14/368-MIPS-BCM63XX-add-support-for-matching-the-board_info.patch [deleted file]
target/linux/brcm63xx/patches-3.14/369-MIPS-BCM63XX-populate-the-compatible-to-board_info-l.patch [deleted file]
target/linux/brcm63xx/patches-3.14/371_add_of_node_available_by_alias.patch [deleted file]
target/linux/brcm63xx/patches-3.14/372_dont_register_pflash_when_available_in_dtb.patch [deleted file]
target/linux/brcm63xx/patches-3.14/373-MIPS-BCM63XX-register-interrupt-controllers-through-.patch [deleted file]
target/linux/brcm63xx/patches-3.14/374-gpio-add-a-simple-GPIO-driver-for-bcm63xx.patch [deleted file]
target/linux/brcm63xx/patches-3.14/375-MIPS-BCM63XX-switch-to-new-gpio-driver.patch [deleted file]
target/linux/brcm63xx/patches-3.14/376-net-bcm63xx_enet-use-named-gpio-for-ephy-reset-gpio.patch [deleted file]
target/linux/brcm63xx/patches-3.14/377-MIPS-BCM63XX-register-lookup-for-ephy-reset-gpio.patch [deleted file]
target/linux/brcm63xx/patches-3.14/378-MIPS-BCM63XX-do-not-register-gpio-controller-if-pres.patch [deleted file]
target/linux/brcm63xx/patches-3.14/379-MIPS-BCM63XX-provide-a-gpio-lookup-for-the-pcmcia-re.patch [deleted file]
target/linux/brcm63xx/patches-3.14/380-pcmcia-bcm63xx_pmcia-use-the-new-named-gpio.patch [deleted file]
target/linux/brcm63xx/patches-3.14/400-bcm963xx_flashmap.patch [deleted file]
target/linux/brcm63xx/patches-3.14/401-bcm963xx_real_rootfs_length.patch [deleted file]
target/linux/brcm63xx/patches-3.14/402_bcm63xx_enet_vlan_incoming_fixed.patch [deleted file]
target/linux/brcm63xx/patches-3.14/403-6358-enet1-external-mii-clk.patch [deleted file]
target/linux/brcm63xx/patches-3.14/404-NET-bcm63xx_enet-move-phy_-dis-connect-into-probe-re.patch [deleted file]
target/linux/brcm63xx/patches-3.14/408-bcm63xx_enet-enable-rgmii-clock-on-external-ports.patch [deleted file]
target/linux/brcm63xx/patches-3.14/411-MIPS-BCM63XX-Register-SPI-flash-if-present.patch [deleted file]
target/linux/brcm63xx/patches-3.14/412-MTD-physmap-allow-passing-pp_data.patch [deleted file]
target/linux/brcm63xx/patches-3.14/413-BCM63XX-allow-providing-fixup-data-in-board-data.patch [deleted file]
target/linux/brcm63xx/patches-3.14/414-MTD-m25p80-allow-passing-pp_data.patch [deleted file]
target/linux/brcm63xx/patches-3.14/415-MIPS-BCM63XX-export-the-attached-flash-type.patch [deleted file]
target/linux/brcm63xx/patches-3.14/416-BCM63XX-add-a-fixup-for-ath9k-devices.patch [deleted file]
target/linux/brcm63xx/patches-3.14/417-MTD-bcm63xxpart-allow-passing-a-caldata-offset.patch [deleted file]
target/linux/brcm63xx/patches-3.14/418-MIPS-BCM63XX-pass-caldata-info-to-flash.patch [deleted file]
target/linux/brcm63xx/patches-3.14/420-BCM63XX-add-endian-check-for-ath9k.patch [deleted file]
target/linux/brcm63xx/patches-3.14/421-BCM63XX-add-led-pin-for-ath9k.patch [deleted file]
target/linux/brcm63xx/patches-3.14/422-BCM63XX-add-a-fixup-for-rt2x00-devices.patch [deleted file]
target/linux/brcm63xx/patches-3.14/423-bcm63xx_enet_add_b53_support.patch [deleted file]
target/linux/brcm63xx/patches-3.14/424-bcm63xx_enet_no_request_mem_region.patch [deleted file]
target/linux/brcm63xx/patches-3.14/425-bcm63xxpart_parse_paritions_from_dt.patch [deleted file]
target/linux/brcm63xx/patches-3.14/426-bcm63xx_enet-fix-napi-poll-return-value.patch [deleted file]
target/linux/brcm63xx/patches-3.14/499-allow_better_context_for_board_patches.patch [deleted file]
target/linux/brcm63xx/patches-3.14/500-board-D4PW.patch [deleted file]
target/linux/brcm63xx/patches-3.14/501-board-NB4.patch [deleted file]
target/linux/brcm63xx/patches-3.14/502-board-96338W2_E7T.patch [deleted file]
target/linux/brcm63xx/patches-3.14/503-board-CPVA642.patch [deleted file]
target/linux/brcm63xx/patches-3.14/504-board_dsl_274xb_rev_c.patch [deleted file]
target/linux/brcm63xx/patches-3.14/505-board_spw500v.patch [deleted file]
target/linux/brcm63xx/patches-3.14/506-board_gw6200_gw6000.patch [deleted file]
target/linux/brcm63xx/patches-3.14/507-board-MAGIC.patch [deleted file]
target/linux/brcm63xx/patches-3.14/508-board_hw553.patch [deleted file]
target/linux/brcm63xx/patches-3.14/509-board_rta1320_16m.patch [deleted file]
target/linux/brcm63xx/patches-3.14/510-board_spw303v.patch [deleted file]
target/linux/brcm63xx/patches-3.14/511-board_V2500V.patch [deleted file]
target/linux/brcm63xx/patches-3.14/512-board_BTV2110.patch [deleted file]
target/linux/brcm63xx/patches-3.14/513-MIPS-BCM63XX-add-inventel-Livebox-support.patch [deleted file]
target/linux/brcm63xx/patches-3.14/514-board_ct536_ct5621.patch [deleted file]
target/linux/brcm63xx/patches-3.14/515-board_DWV-S0_fixes.patch [deleted file]
target/linux/brcm63xx/patches-3.14/516-board_96348A-122.patch [deleted file]
target/linux/brcm63xx/patches-3.14/517-RTA1205W_16_uart_fixes.patch [deleted file]
target/linux/brcm63xx/patches-3.14/519_board_CPVA502plus.patch [deleted file]
target/linux/brcm63xx/patches-3.14/520-bcm63xx-add-support-for-96368MVWG-board.patch [deleted file]
target/linux/brcm63xx/patches-3.14/521-bcm63xx-add-support-for-96368MVNgr-board.patch [deleted file]
target/linux/brcm63xx/patches-3.14/522-MIPS-BCM63XX-add-96328avng-reference-board.patch [deleted file]
target/linux/brcm63xx/patches-3.14/523-MIPS-BCM63XX-add-963281TAN-reference-board.patch [deleted file]
target/linux/brcm63xx/patches-3.14/524-board_dsl_274xb_rev_f.patch [deleted file]
target/linux/brcm63xx/patches-3.14/525-board_96348w3.patch [deleted file]
target/linux/brcm63xx/patches-3.14/526-board_CT6373-1.patch [deleted file]
target/linux/brcm63xx/patches-3.14/527-board_dva-g3810bn-tl-1.patch [deleted file]
target/linux/brcm63xx/patches-3.14/528-board_nb6.patch [deleted file]
target/linux/brcm63xx/patches-3.14/529-board_fast2604.patch [deleted file]
target/linux/brcm63xx/patches-3.14/530-board_A4001N1.patch [deleted file]
target/linux/brcm63xx/patches-3.14/531-board_AR-5387un.patch [deleted file]
target/linux/brcm63xx/patches-3.14/532-board_AR-5381u.patch [deleted file]
target/linux/brcm63xx/patches-3.14/533-board_rta770bw.patch [deleted file]
target/linux/brcm63xx/patches-3.14/534-board_hw556.patch [deleted file]
target/linux/brcm63xx/patches-3.14/535-board_rta770w.patch [deleted file]
target/linux/brcm63xx/patches-3.14/536-board_fast2704.patch [deleted file]
target/linux/brcm63xx/patches-3.14/537-board_fast2504n.patch [deleted file]
target/linux/brcm63xx/patches-3.14/550-MIPS-BCM63XX-remove-leds-and-buttons.patch [deleted file]
target/linux/brcm63xx/patches-3.14/553-boards_probe_switch.patch [deleted file]
target/linux/brcm63xx/patches-3.14/555-board_96318ref.patch [deleted file]
target/linux/brcm63xx/patches-3.14/556-board_96318ref_p300.patch [deleted file]
target/linux/brcm63xx/patches-3.14/557-board_bcm963269bhr.patch [deleted file]
target/linux/brcm63xx/patches-3.14/558-board_AR1004G.patch [deleted file]
target/linux/brcm63xx/patches-3.14/559-board_vw6339gu.patch [deleted file]
target/linux/brcm63xx/patches-3.14/560-board_963268gu_p300.patch [deleted file]
target/linux/brcm63xx/patches-3.14/561-board_WAP-5813n.patch [deleted file]
target/linux/brcm63xx/patches-3.14/562-board_VR-3025u.patch [deleted file]
target/linux/brcm63xx/patches-3.14/563-board_VR-3025un.patch [deleted file]
target/linux/brcm63xx/patches-3.14/564-board_P870HW-51a_v2.patch [deleted file]
target/linux/brcm63xx/patches-3.14/565-board_hw520.patch [deleted file]
target/linux/brcm63xx/patches-3.14/566-board_A4001N.patch [deleted file]
target/linux/brcm63xx/patches-3.14/567-board_dsl-2751b_e1.patch [deleted file]
target/linux/brcm63xx/patches-3.14/568-board_DGND3700v1_3800B.patch [deleted file]
target/linux/brcm63xx/patches-3.14/800-wl_exports.patch [deleted file]
target/linux/brcm63xx/patches-3.14/801-ssb_export_fallback_sprom.patch [deleted file]
target/linux/brcm63xx/patches-3.14/802-rtl8367r_fix_RGMII_support.patch [deleted file]
target/linux/brcm63xx/patches-3.14/803-jffs2-work-around-unaligned-accesses-failing-on-bcm6.patch [deleted file]
target/linux/brcm63xx/patches-3.14/810-BCM63XX-move-kernel-behind-CFE.patch [deleted file]

diff --git a/target/linux/brcm63xx/config-3.14 b/target/linux/brcm63xx/config-3.14
deleted file mode 100644 (file)
index 76ece46..0000000
+++ /dev/null
@@ -1,223 +0,0 @@
-CONFIG_ARCH_BINFMT_ELF_RANDOMIZE_PIE=y
-CONFIG_ARCH_DISCARD_MEMBLOCK=y
-CONFIG_ARCH_HAS_ATOMIC64_DEC_IF_POSITIVE=y
-CONFIG_ARCH_HAVE_CUSTOM_GPIO_H=y
-CONFIG_ARCH_HIBERNATION_POSSIBLE=y
-CONFIG_ARCH_MIGHT_HAVE_PC_PARPORT=y
-CONFIG_ARCH_MIGHT_HAVE_PC_SERIO=y
-CONFIG_ARCH_REQUIRE_GPIOLIB=y
-CONFIG_ARCH_SUSPEND_POSSIBLE=y
-CONFIG_ARCH_WANT_IPC_PARSE_VERSION=y
-CONFIG_B53=y
-CONFIG_B53_MMAP_DRIVER=y
-CONFIG_B53_PHY_DRIVER=y
-CONFIG_B53_PHY_FIXUP=y
-CONFIG_B53_SPI_DRIVER=y
-# CONFIG_B53_SRAB_DRIVER is not set
-CONFIG_BCM6345_EXT_IRQ=y
-CONFIG_BCM6345_PERIPH_IRQ=y
-CONFIG_BCM63XX=y
-CONFIG_BCM63XX_CPU_3368=y
-CONFIG_BCM63XX_CPU_6318=y
-CONFIG_BCM63XX_CPU_63268=y
-CONFIG_BCM63XX_CPU_6328=y
-CONFIG_BCM63XX_CPU_6338=y
-CONFIG_BCM63XX_CPU_6345=y
-CONFIG_BCM63XX_CPU_6348=y
-CONFIG_BCM63XX_CPU_6358=y
-CONFIG_BCM63XX_CPU_6362=y
-CONFIG_BCM63XX_CPU_6368=y
-CONFIG_BCM63XX_EHCI=y
-CONFIG_BCM63XX_ENET=y
-CONFIG_BCM63XX_OHCI=y
-CONFIG_BCM63XX_PHY=y
-CONFIG_BCM63XX_WDT=y
-CONFIG_BCMA=y
-CONFIG_BCMA_BLOCKIO=y
-# CONFIG_BCMA_DEBUG is not set
-# CONFIG_BCMA_DRIVER_GMAC_CMN is not set
-# CONFIG_BCMA_DRIVER_MIPS is not set
-# CONFIG_BCMA_DRIVER_PCI_HOSTMODE is not set
-CONFIG_BCMA_HOST_PCI=y
-CONFIG_BCMA_HOST_PCI_POSSIBLE=y
-# CONFIG_BCMA_HOST_SOC is not set
-CONFIG_BOARD_BCM63XX_DT=y
-CONFIG_BOARD_BCM963XX=y
-CONFIG_BOARD_LIVEBOX=y
-CONFIG_CC_OPTIMIZE_FOR_SIZE=y
-CONFIG_CEVT_R4K=y
-CONFIG_CLONE_BACKWARDS=y
-CONFIG_CMDLINE="root=/dev/mtdblock2 rootfstype=squashfs,jffs2 noinitrd console=ttyS0,115200"
-CONFIG_CMDLINE_BOOL=y
-# CONFIG_CMDLINE_OVERRIDE is not set
-CONFIG_CPU_BIG_ENDIAN=y
-CONFIG_CPU_BMIPS=y
-CONFIG_CPU_BMIPS32_3300=y
-CONFIG_CPU_BMIPS4350=y
-CONFIG_CPU_GENERIC_DUMP_TLB=y
-CONFIG_CPU_HAS_PREFETCH=y
-CONFIG_CPU_HAS_SYNC=y
-CONFIG_CPU_MIPS32=y
-CONFIG_CPU_R4K_CACHE_TLB=y
-CONFIG_CPU_R4K_FPU=y
-CONFIG_CPU_SUPPORTS_32BIT_KERNEL=y
-CONFIG_CPU_SUPPORTS_HIGHMEM=y
-CONFIG_CSRC_R4K=y
-CONFIG_DMA_NONCOHERENT=y
-CONFIG_DTC=y
-CONFIG_EARLY_PRINTK=y
-CONFIG_FIRMWARE_IN_KERNEL=y
-CONFIG_GENERIC_ATOMIC64=y
-CONFIG_GENERIC_CLOCKEVENTS=y
-CONFIG_GENERIC_CLOCKEVENTS_BUILD=y
-CONFIG_GENERIC_CMOS_UPDATE=y
-CONFIG_GENERIC_IO=y
-CONFIG_GENERIC_IRQ_SHOW=y
-CONFIG_GENERIC_PCI_IOMAP=y
-CONFIG_GENERIC_SMP_IDLE_THREAD=y
-CONFIG_GPIOLIB=y
-CONFIG_GPIO_74X164=y
-CONFIG_GPIO_BCM63XX=y
-CONFIG_GPIO_DEVRES=y
-CONFIG_GPIO_GENERIC=y
-CONFIG_GPIO_SYSFS=y
-CONFIG_HAS_DMA=y
-CONFIG_HAS_IOMEM=y
-CONFIG_HAS_IOPORT=y
-# CONFIG_HAVE_64BIT_ALIGNED_ACCESS is not set
-CONFIG_HAVE_ARCH_JUMP_LABEL=y
-CONFIG_HAVE_ARCH_KGDB=y
-CONFIG_HAVE_ARCH_TRACEHOOK=y
-# CONFIG_HAVE_BOOTMEM_INFO_NODE is not set
-CONFIG_HAVE_CC_STACKPROTECTOR=y
-CONFIG_HAVE_CLK=y
-CONFIG_HAVE_CONTEXT_TRACKING=y
-CONFIG_HAVE_C_RECORDMCOUNT=y
-CONFIG_HAVE_DEBUG_KMEMLEAK=y
-CONFIG_HAVE_DEBUG_STACKOVERFLOW=y
-CONFIG_HAVE_DMA_API_DEBUG=y
-CONFIG_HAVE_DMA_ATTRS=y
-CONFIG_HAVE_DYNAMIC_FTRACE=y
-CONFIG_HAVE_FTRACE_MCOUNT_RECORD=y
-CONFIG_HAVE_FUNCTION_GRAPH_TRACER=y
-CONFIG_HAVE_FUNCTION_TRACER=y
-CONFIG_HAVE_FUNCTION_TRACE_MCOUNT_TEST=y
-CONFIG_HAVE_GENERIC_DMA_COHERENT=y
-CONFIG_HAVE_IDE=y
-CONFIG_HAVE_MEMBLOCK=y
-CONFIG_HAVE_MEMBLOCK_NODE_MAP=y
-CONFIG_HAVE_MOD_ARCH_SPECIFIC=y
-CONFIG_HAVE_NET_DSA=y
-CONFIG_HAVE_OPROFILE=y
-CONFIG_HAVE_PERF_EVENTS=y
-CONFIG_HAVE_SYSCALL_TRACEPOINTS=y
-CONFIG_HW_HAS_PCI=y
-CONFIG_HW_RANDOM=y
-CONFIG_HW_RANDOM_BCM63XX=y
-CONFIG_HZ=250
-# CONFIG_HZ_100 is not set
-CONFIG_HZ_250=y
-CONFIG_HZ_PERIODIC=y
-CONFIG_IMAGE_CMDLINE_HACK=y
-CONFIG_INITRAMFS_SOURCE=""
-CONFIG_IP_PIMSM_V1=y
-CONFIG_IP_PIMSM_V2=y
-CONFIG_IRQCHIP=y
-CONFIG_IRQ_CPU=y
-CONFIG_IRQ_DOMAIN=y
-CONFIG_IRQ_FORCED_THREADING=y
-CONFIG_IRQ_WORK=y
-CONFIG_KEXEC=y
-CONFIG_LEDS_GPIO=y
-CONFIG_MDIO_BOARDINFO=y
-CONFIG_MIPS=y
-CONFIG_MIPS_APPENDED_DTB=y
-# CONFIG_MIPS_HUGE_TLB_SUPPORT is not set
-CONFIG_MIPS_L1_CACHE_SHIFT=4
-CONFIG_MIPS_L1_CACHE_SHIFT_4=y
-# CONFIG_MIPS_MACHINE is not set
-CONFIG_MIPS_MT_DISABLED=y
-CONFIG_MODULES_USE_ELF_REL=y
-CONFIG_MODULE_FORCE_LOAD=y
-CONFIG_MODULE_FORCE_UNLOAD=y
-CONFIG_MTD_BCM63XX_PARTS=y
-CONFIG_MTD_CFI_ADV_OPTIONS=y
-CONFIG_MTD_CFI_BE_BYTE_SWAP=y
-# CONFIG_MTD_CFI_GEOMETRY is not set
-# CONFIG_MTD_CFI_NOSWAP is not set
-CONFIG_MTD_CFI_STAA=y
-CONFIG_MTD_CMDLINE_PARTS=y
-# CONFIG_MTD_COMPLEX_MAPPINGS is not set
-CONFIG_MTD_JEDECPROBE=y
-CONFIG_MTD_M25P80=y
-CONFIG_MTD_PHYSMAP=y
-CONFIG_MTD_REDBOOT_PARTS=y
-CONFIG_MTD_REDBOOT_PARTS_UNALLOCATED=y
-CONFIG_NEED_DMA_MAP_STATE=y
-CONFIG_NEED_PER_CPU_KM=y
-CONFIG_NO_GENERIC_PCI_IOPORT_MAP=y
-CONFIG_OF=y
-CONFIG_OF_ADDRESS=y
-CONFIG_OF_EARLY_FLATTREE=y
-CONFIG_OF_FLATTREE=y
-CONFIG_OF_GPIO=y
-CONFIG_OF_IRQ=y
-CONFIG_OF_MDIO=y
-CONFIG_OF_MTD=y
-CONFIG_OF_NET=y
-CONFIG_OF_PCI=y
-CONFIG_OF_PCI_IRQ=y
-CONFIG_PAGEFLAGS_EXTENDED=y
-CONFIG_PCI=y
-# CONFIG_PCIEAER is not set
-CONFIG_PCIEPORTBUS=y
-CONFIG_PCI_DOMAINS=y
-CONFIG_PERF_USE_VMALLOC=y
-CONFIG_PHYLIB=y
-CONFIG_POSIX_MQUEUE=y
-CONFIG_POSIX_MQUEUE_SYSCTL=y
-# CONFIG_PREEMPT_RCU is not set
-CONFIG_PROC_DEVICETREE=y
-# CONFIG_RCU_STALL_COMMON is not set
-CONFIG_RELAY=y
-CONFIG_RTL8366_SMI=y
-CONFIG_RTL8367_PHY=y
-# CONFIG_SCSI_DMA is not set
-# CONFIG_SERIAL_8250 is not set
-CONFIG_SERIAL_BCM63XX=y
-CONFIG_SERIAL_BCM63XX_CONSOLE=y
-CONFIG_SPI=y
-CONFIG_SPI_BCM63XX=y
-CONFIG_SPI_BCM63XX_HSSPI=y
-CONFIG_SPI_BITBANG=y
-CONFIG_SPI_GPIO=y
-CONFIG_SPI_MASTER=y
-CONFIG_SQUASHFS_EMBEDDED=y
-CONFIG_SSB=y
-CONFIG_SSB_B43_PCI_BRIDGE=y
-CONFIG_SSB_BLOCKIO=y
-# CONFIG_SSB_DRIVER_MIPS is not set
-CONFIG_SSB_DRIVER_PCICORE=y
-CONFIG_SSB_DRIVER_PCICORE_POSSIBLE=y
-CONFIG_SSB_PCIHOST=y
-CONFIG_SSB_PCIHOST_POSSIBLE=y
-CONFIG_SSB_SPROM=y
-CONFIG_SWAP_IO_SPACE=y
-CONFIG_SWCONFIG=y
-CONFIG_SYNC_R4K=y
-CONFIG_SYS_HAS_CPU_BMIPS=y
-CONFIG_SYS_HAS_CPU_BMIPS32_3300=y
-CONFIG_SYS_HAS_CPU_BMIPS4350=y
-CONFIG_SYS_HAS_EARLY_PRINTK=y
-CONFIG_SYS_SUPPORTS_32BIT_KERNEL=y
-CONFIG_SYS_SUPPORTS_ARBIT_HZ=y
-CONFIG_SYS_SUPPORTS_BIG_ENDIAN=y
-CONFIG_SYS_SUPPORTS_HOTPLUG_CPU=y
-CONFIG_SYS_SUPPORTS_SMP=y
-CONFIG_TICK_CPU_ACCOUNTING=y
-CONFIG_USB_SUPPORT=y
-CONFIG_USE_OF=y
-CONFIG_VM_EVENT_COUNTERS=y
-CONFIG_WATCHDOG_NOWAYOUT=y
-CONFIG_WEAK_ORDERING=y
-CONFIG_ZONE_DMA_FLAG=0
diff --git a/target/linux/brcm63xx/patches-3.14/001-of-Create-unlocked-version-of-for_each_child_of_node.patch b/target/linux/brcm63xx/patches-3.14/001-of-Create-unlocked-version-of-for_each_child_of_node.patch
deleted file mode 100644 (file)
index 1395789..0000000
+++ /dev/null
@@ -1,52 +0,0 @@
-From 0d0e02d605c5696a5076510f564fefe659127aa4 Mon Sep 17 00:00:00 2001
-From: Grant Likely <grant.likely@linaro.org>
-Date: Thu, 22 May 2014 01:04:17 +0900
-Subject: [PATCH] of: Create unlocked version of for_each_child_of_node()
-
-When iterating over nodes, sometimes it needs to be done when the DT
-lock is already held. This patch makes an unlocked version of the
-for_each_child_of_node() macro.
-
-Signed-off-by: Grant Likely <grant.likely@linaro.org>
----
- drivers/of/base.c | 22 +++++++++++++++++-----
- 1 file changed, 17 insertions(+), 5 deletions(-)
-
---- a/drivers/of/base.c
-+++ b/drivers/of/base.c
-@@ -545,6 +545,22 @@ struct device_node *of_get_next_parent(s
- }
- EXPORT_SYMBOL(of_get_next_parent);
-+static struct device_node *__of_get_next_child(const struct device_node *node,
-+                                              struct device_node *prev)
-+{
-+      struct device_node *next;
-+
-+      next = prev ? prev->sibling : node->child;
-+      for (; next; next = next->sibling)
-+              if (of_node_get(next))
-+                      break;
-+      of_node_put(prev);
-+      return next;
-+}
-+#define __for_each_child_of_node(parent, child) \
-+      for (child = __of_get_next_child(parent, NULL); child != NULL; \
-+           child = __of_get_next_child(parent, child))
-+
- /**
-  *    of_get_next_child - Iterate a node childs
-  *    @node:  parent node
-@@ -560,11 +576,7 @@ struct device_node *of_get_next_child(co
-       unsigned long flags;
-       raw_spin_lock_irqsave(&devtree_lock, flags);
--      next = prev ? prev->sibling : node->child;
--      for (; next; next = next->sibling)
--              if (of_node_get(next))
--                      break;
--      of_node_put(prev);
-+      next = __of_get_next_child(node, prev);
-       raw_spin_unlock_irqrestore(&devtree_lock, flags);
-       return next;
- }
diff --git a/target/linux/brcm63xx/patches-3.14/001-spi-spi-gpio-Add-dt-support-for-a-single-device-with.patch b/target/linux/brcm63xx/patches-3.14/001-spi-spi-gpio-Add-dt-support-for-a-single-device-with.patch
deleted file mode 100644 (file)
index d4a36e8..0000000
+++ /dev/null
@@ -1,91 +0,0 @@
-From d1d81802522ade84128a2c66c0d500e372474dca Mon Sep 17 00:00:00 2001
-From: Torsten Fleischer <torfl6749@gmail.com>
-Date: Mon, 3 Nov 2014 17:17:55 +0100
-Subject: [PATCH] spi: spi-gpio: Add dt support for a single device with no
- chip select
-
-In order to describe a single slave device that has no chip select line
-the 'num-chipselects' property has to be <0> and the 'cs-gpios' property
-doesn't need to be set.
-
-Signed-off-by: Torsten Fleischer <torfl6749@gmail.com>
-Signed-off-by: Mark Brown <broonie@kernel.org>
----
- Documentation/devicetree/bindings/spi/spi-gpio.txt |  6 ++++--
- drivers/spi/spi-gpio.c                             | 21 +++++++++++++++------
- 2 files changed, 19 insertions(+), 8 deletions(-)
-
---- a/Documentation/devicetree/bindings/spi/spi-gpio.txt
-+++ b/Documentation/devicetree/bindings/spi/spi-gpio.txt
-@@ -8,8 +8,10 @@ Required properties:
-  - gpio-sck: GPIO spec for the SCK line to use
-  - gpio-miso: GPIO spec for the MISO line to use
-  - gpio-mosi: GPIO spec for the MOSI line to use
-- - cs-gpios: GPIOs to use for chipselect lines
-- - num-chipselects: number of chipselect lines
-+ - cs-gpios: GPIOs to use for chipselect lines.
-+             Not needed if num-chipselects = <0>.
-+ - num-chipselects: Number of chipselect lines. Should be <0> if a single device
-+                    with no chip select is connected.
- Example:
---- a/drivers/spi/spi-gpio.c
-+++ b/drivers/spi/spi-gpio.c
-@@ -425,6 +425,7 @@ static int spi_gpio_probe(struct platfor
-       struct spi_gpio_platform_data   *pdata;
-       u16 master_flags = 0;
-       bool use_of = 0;
-+      int num_devices;
-       status = spi_gpio_probe_dt(pdev);
-       if (status < 0)
-@@ -434,16 +435,21 @@ static int spi_gpio_probe(struct platfor
-       pdata = dev_get_platdata(&pdev->dev);
- #ifdef GENERIC_BITBANG
--      if (!pdata || !pdata->num_chipselect)
-+      if (!pdata || (!use_of && !pdata->num_chipselect))
-               return -ENODEV;
- #endif
-+      if (use_of && !SPI_N_CHIPSEL)
-+              num_devices = 1;
-+      else
-+              num_devices = SPI_N_CHIPSEL;
-+
-       status = spi_gpio_request(pdata, dev_name(&pdev->dev), &master_flags);
-       if (status < 0)
-               return status;
-       master = spi_alloc_master(&pdev->dev, sizeof(*spi_gpio) +
--                                      (sizeof(int) * SPI_N_CHIPSEL));
-+                                      (sizeof(int) * num_devices));
-       if (!master) {
-               status = -ENOMEM;
-               goto gpio_free;
-@@ -458,7 +464,7 @@ static int spi_gpio_probe(struct platfor
-       master->bits_per_word_mask = SPI_BPW_RANGE_MASK(1, 32);
-       master->flags = master_flags;
-       master->bus_num = pdev->id;
--      master->num_chipselect = SPI_N_CHIPSEL;
-+      master->num_chipselect = num_devices;
-       master->setup = spi_gpio_setup;
-       master->cleanup = spi_gpio_cleanup;
- #ifdef CONFIG_OF
-@@ -473,9 +479,12 @@ static int spi_gpio_probe(struct platfor
-                * property of the node.
-                */
--              for (i = 0; i < SPI_N_CHIPSEL; i++)
--                      spi_gpio->cs_gpios[i] =
--                              of_get_named_gpio(np, "cs-gpios", i);
-+              if (!SPI_N_CHIPSEL)
-+                      spi_gpio->cs_gpios[0] = SPI_GPIO_NO_CHIPSELECT;
-+              else
-+                      for (i = 0; i < SPI_N_CHIPSEL; i++)
-+                              spi_gpio->cs_gpios[i] =
-+                                      of_get_named_gpio(np, "cs-gpios", i);
-       }
- #endif
diff --git a/target/linux/brcm63xx/patches-3.14/002-lib-add-glibc-style-strchrnul-variant.patch b/target/linux/brcm63xx/patches-3.14/002-lib-add-glibc-style-strchrnul-variant.patch
deleted file mode 100644 (file)
index 33d7c9f..0000000
+++ /dev/null
@@ -1,56 +0,0 @@
-From 11d200e95f3e84c1102e4cc9863a3614fd41f3ad Mon Sep 17 00:00:00 2001
-From: Grant Likely <grant.likely@linaro.org>
-Date: Fri, 14 Mar 2014 17:00:14 +0000
-Subject: [PATCH] lib: add glibc style strchrnul() variant
-
-The strchrnul() variant helpfully returns a the end of the string
-instead of a NULL if the requested character is not found. This can
-simplify string parsing code since it doesn't need to expicitly check
-for a NULL return. If a valid string pointer is passed in, then a valid
-null terminated string will always come back out.
-
-Signed-off-by: Grant Likely <grant.likely@linaro.org>
----
- include/linux/string.h |  3 +++
- lib/string.c           | 18 ++++++++++++++++++
- 2 files changed, 21 insertions(+)
-
---- a/include/linux/string.h
-+++ b/include/linux/string.h
-@@ -52,6 +52,9 @@ extern int strncasecmp(const char *s1, c
- #ifndef __HAVE_ARCH_STRCHR
- extern char * strchr(const char *,int);
- #endif
-+#ifndef __HAVE_ARCH_STRCHRNUL
-+extern char * strchrnul(const char *,int);
-+#endif
- #ifndef __HAVE_ARCH_STRNCHR
- extern char * strnchr(const char *, size_t, int);
- #endif
---- a/lib/string.c
-+++ b/lib/string.c
-@@ -301,6 +301,24 @@ char *strchr(const char *s, int c)
- EXPORT_SYMBOL(strchr);
- #endif
-+#ifndef __HAVE_ARCH_STRCHRNUL
-+/**
-+ * strchrnul - Find and return a character in a string, or end of string
-+ * @s: The string to be searched
-+ * @c: The character to search for
-+ *
-+ * Returns pointer to first occurrence of 'c' in s. If c is not found, then
-+ * return a pointer to the null byte at the end of s.
-+ */
-+char *strchrnul(const char *s, int c)
-+{
-+      while (*s && *s != (char)c)
-+              s++;
-+      return (char *)s;
-+}
-+EXPORT_SYMBOL(strchrnul);
-+#endif
-+
- #ifndef __HAVE_ARCH_STRRCHR
- /**
-  * strrchr - Find the last occurrence of a character in a string
diff --git a/target/linux/brcm63xx/patches-3.14/003-of-Make-of_find_node_by_path-handle-aliases.patch b/target/linux/brcm63xx/patches-3.14/003-of-Make-of_find_node_by_path-handle-aliases.patch
deleted file mode 100644 (file)
index 9ad0780..0000000
+++ /dev/null
@@ -1,106 +0,0 @@
-From c22e650e66b862babe9c00bebb20b8029c7b0362 Mon Sep 17 00:00:00 2001
-From: Grant Likely <grant.likely@linaro.org>
-Date: Fri, 14 Mar 2014 17:07:12 +0000
-Subject: [PATCH] of: Make of_find_node_by_path() handle /aliases
-
-Make of_find_node_by_path() handle aliases as prefixes. To make this
-work the name search is refactored to search by path component instead
-of by full string. This should be a more efficient search, and it makes
-it possible to start a search at a subnode of a tree.
-
-Signed-off-by: David Daney <david.daney@cavium.com>
-Signed-off-by: Pantelis Antoniou <pantelis.antoniou@konsulko.com>
-[grant.likely: Rework to not require allocating at runtime]
-Acked-by: Rob Herring <robh@kernel.org>
-Signed-off-by: Grant Likely <grant.likely@linaro.org>
----
- drivers/of/base.c | 67 ++++++++++++++++++++++++++++++++++++++++++++++++++-----
- 1 file changed, 61 insertions(+), 6 deletions(-)
-
---- a/drivers/of/base.c
-+++ b/drivers/of/base.c
-@@ -633,23 +633,78 @@ struct device_node *of_get_child_by_name
- }
- EXPORT_SYMBOL(of_get_child_by_name);
-+static struct device_node *__of_find_node_by_path(struct device_node *parent,
-+                                              const char *path)
-+{
-+      struct device_node *child;
-+      int len = strchrnul(path, '/') - path;
-+
-+      if (!len)
-+              return NULL;
-+
-+      __for_each_child_of_node(parent, child) {
-+              const char *name = strrchr(child->full_name, '/');
-+              if (WARN(!name, "malformed device_node %s\n", child->full_name))
-+                      continue;
-+              name++;
-+              if (strncmp(path, name, len) == 0 && (strlen(name) == len))
-+                      return child;
-+      }
-+      return NULL;
-+}
-+
- /**
-  *    of_find_node_by_path - Find a node matching a full OF path
-- *    @path:  The full path to match
-+ *    @path: Either the full path to match, or if the path does not
-+ *           start with '/', the name of a property of the /aliases
-+ *           node (an alias).  In the case of an alias, the node
-+ *           matching the alias' value will be returned.
-+ *
-+ *    Valid paths:
-+ *            /foo/bar        Full path
-+ *            foo             Valid alias
-+ *            foo/bar         Valid alias + relative path
-  *
-  *    Returns a node pointer with refcount incremented, use
-  *    of_node_put() on it when done.
-  */
- struct device_node *of_find_node_by_path(const char *path)
- {
--      struct device_node *np = of_allnodes;
-+      struct device_node *np = NULL;
-+      struct property *pp;
-       unsigned long flags;
-+      if (strcmp(path, "/") == 0)
-+              return of_node_get(of_allnodes);
-+
-+      /* The path could begin with an alias */
-+      if (*path != '/') {
-+              char *p = strchrnul(path, '/');
-+              int len = p - path;
-+
-+              /* of_aliases must not be NULL */
-+              if (!of_aliases)
-+                      return NULL;
-+
-+              for_each_property_of_node(of_aliases, pp) {
-+                      if (strlen(pp->name) == len && !strncmp(pp->name, path, len)) {
-+                              np = of_find_node_by_path(pp->value);
-+                              break;
-+                      }
-+              }
-+              if (!np)
-+                      return NULL;
-+              path = p;
-+      }
-+
-+      /* Step down the tree matching path components */
-       raw_spin_lock_irqsave(&devtree_lock, flags);
--      for (; np; np = np->allnext) {
--              if (np->full_name && (of_node_cmp(np->full_name, path) == 0)
--                  && of_node_get(np))
--                      break;
-+      if (!np)
-+              np = of_node_get(of_allnodes);
-+      while (np && *path == '/') {
-+              path++; /* Increment past '/' delimiter */
-+              np = __of_find_node_by_path(np, path);
-+              path = strchrnul(path, '/');
-       }
-       raw_spin_unlock_irqrestore(&devtree_lock, flags);
-       return np;
diff --git a/target/linux/brcm63xx/patches-3.14/010-MIPS-BCM63XX-remove-RUNTIME_DETECT-code-from-registe.patch b/target/linux/brcm63xx/patches-3.14/010-MIPS-BCM63XX-remove-RUNTIME_DETECT-code-from-registe.patch
deleted file mode 100644 (file)
index 04b3426..0000000
+++ /dev/null
@@ -1,61 +0,0 @@
-From 082a49f0490008b999db80e3ccf1521c7dd21cec Mon Sep 17 00:00:00 2001
-From: Jonas Gorski <jogo@openwrt.org>
-Date: Mon, 2 Dec 2013 12:32:44 +0100
-Subject: [PATCH 1/8] MIPS: BCM63XX: remove !RUNTIME_DETECT code from register
- sets
-
-Signed-off-by: Jonas Gorski <jogo@openwrt.org>
----
- arch/mips/include/asm/mach-bcm63xx/bcm63xx_cpu.h | 33 ------------------------
- 1 file changed, 33 deletions(-)
-
---- a/arch/mips/include/asm/mach-bcm63xx/bcm63xx_cpu.h
-+++ b/arch/mips/include/asm/mach-bcm63xx/bcm63xx_cpu.h
-@@ -598,10 +598,6 @@ enum bcm63xx_regs_set {
- extern const unsigned long *bcm63xx_regs_base;
--#define __GEN_RSET_BASE(__cpu, __rset)                                        \
--      case RSET_## __rset :                                           \
--              return BCM_## __cpu ##_## __rset ##_BASE;
--
- #define __GEN_RSET(__cpu)                                             \
-       switch (set) {                                                  \
-       __GEN_RSET_BASE(__cpu, DSL_LMEM)                                \
-@@ -693,36 +689,7 @@ extern const unsigned long *bcm63xx_regs
- static inline unsigned long bcm63xx_regset_address(enum bcm63xx_regs_set set)
- {
--#ifdef BCMCPU_RUNTIME_DETECT
-       return bcm63xx_regs_base[set];
--#else
--#ifdef CONFIG_BCM63XX_CPU_3368
--      __GEN_RSET(3368)
--#endif
--#ifdef CONFIG_BCM63XX_CPU_6328
--      __GEN_RSET(6328)
--#endif
--#ifdef CONFIG_BCM63XX_CPU_6338
--      __GEN_RSET(6338)
--#endif
--#ifdef CONFIG_BCM63XX_CPU_6345
--      __GEN_RSET(6345)
--#endif
--#ifdef CONFIG_BCM63XX_CPU_6348
--      __GEN_RSET(6348)
--#endif
--#ifdef CONFIG_BCM63XX_CPU_6358
--      __GEN_RSET(6358)
--#endif
--#ifdef CONFIG_BCM63XX_CPU_6362
--      __GEN_RSET(6362)
--#endif
--#ifdef CONFIG_BCM63XX_CPU_6368
--      __GEN_RSET(6368)
--#endif
--#endif
--      /* unreached */
--      return 0;
- }
- /*
diff --git a/target/linux/brcm63xx/patches-3.14/011-MIPS-BCM63XX-remove-RUNTIME_DETECT-from-irq-setup-co.patch b/target/linux/brcm63xx/patches-3.14/011-MIPS-BCM63XX-remove-RUNTIME_DETECT-from-irq-setup-co.patch
deleted file mode 100644 (file)
index 9226530..0000000
+++ /dev/null
@@ -1,135 +0,0 @@
-From 07d0224576cbb2e6ac680b4ade4bba7a49bd0a07 Mon Sep 17 00:00:00 2001
-From: Jonas Gorski <jogo@openwrt.org>
-Date: Mon, 2 Dec 2013 12:34:11 +0100
-Subject: [PATCH 2/8] MIPS: BCM63XX: remove !RUNTIME_DETECT from irq setup code
-
-Signed-off-by: Jonas Gorski <jogo@openwrt.org>
----
- arch/mips/bcm63xx/irq.c | 109 ------------------------------------------------
- 1 file changed, 109 deletions(-)
-
---- a/arch/mips/bcm63xx/irq.c
-+++ b/arch/mips/bcm63xx/irq.c
-@@ -26,114 +26,6 @@ static void __internal_irq_mask_64(unsig
- static void __internal_irq_unmask_32(unsigned int irq) __maybe_unused;
- static void __internal_irq_unmask_64(unsigned int irq) __maybe_unused;
--#ifndef BCMCPU_RUNTIME_DETECT
--#ifdef CONFIG_BCM63XX_CPU_3368
--#define irq_stat_reg          PERF_IRQSTAT_3368_REG
--#define irq_mask_reg          PERF_IRQMASK_3368_REG
--#define irq_bits              32
--#define is_ext_irq_cascaded   0
--#define ext_irq_start         0
--#define ext_irq_end           0
--#define ext_irq_count         4
--#define ext_irq_cfg_reg1      PERF_EXTIRQ_CFG_REG_3368
--#define ext_irq_cfg_reg2      0
--#endif
--#ifdef CONFIG_BCM63XX_CPU_6328
--#define irq_stat_reg          PERF_IRQSTAT_6328_REG
--#define irq_mask_reg          PERF_IRQMASK_6328_REG
--#define irq_bits              64
--#define is_ext_irq_cascaded   1
--#define ext_irq_start         (BCM_6328_EXT_IRQ0 - IRQ_INTERNAL_BASE)
--#define ext_irq_end           (BCM_6328_EXT_IRQ3 - IRQ_INTERNAL_BASE)
--#define ext_irq_count         4
--#define ext_irq_cfg_reg1      PERF_EXTIRQ_CFG_REG_6328
--#define ext_irq_cfg_reg2      0
--#endif
--#ifdef CONFIG_BCM63XX_CPU_6338
--#define irq_stat_reg          PERF_IRQSTAT_6338_REG
--#define irq_mask_reg          PERF_IRQMASK_6338_REG
--#define irq_bits              32
--#define is_ext_irq_cascaded   0
--#define ext_irq_start         0
--#define ext_irq_end           0
--#define ext_irq_count         4
--#define ext_irq_cfg_reg1      PERF_EXTIRQ_CFG_REG_6338
--#define ext_irq_cfg_reg2      0
--#endif
--#ifdef CONFIG_BCM63XX_CPU_6345
--#define irq_stat_reg          PERF_IRQSTAT_6345_REG
--#define irq_mask_reg          PERF_IRQMASK_6345_REG
--#define irq_bits              32
--#define is_ext_irq_cascaded   0
--#define ext_irq_start         0
--#define ext_irq_end           0
--#define ext_irq_count         4
--#define ext_irq_cfg_reg1      PERF_EXTIRQ_CFG_REG_6345
--#define ext_irq_cfg_reg2      0
--#endif
--#ifdef CONFIG_BCM63XX_CPU_6348
--#define irq_stat_reg          PERF_IRQSTAT_6348_REG
--#define irq_mask_reg          PERF_IRQMASK_6348_REG
--#define irq_bits              32
--#define is_ext_irq_cascaded   0
--#define ext_irq_start         0
--#define ext_irq_end           0
--#define ext_irq_count         4
--#define ext_irq_cfg_reg1      PERF_EXTIRQ_CFG_REG_6348
--#define ext_irq_cfg_reg2      0
--#endif
--#ifdef CONFIG_BCM63XX_CPU_6358
--#define irq_stat_reg          PERF_IRQSTAT_6358_REG
--#define irq_mask_reg          PERF_IRQMASK_6358_REG
--#define irq_bits              32
--#define is_ext_irq_cascaded   1
--#define ext_irq_start         (BCM_6358_EXT_IRQ0 - IRQ_INTERNAL_BASE)
--#define ext_irq_end           (BCM_6358_EXT_IRQ3 - IRQ_INTERNAL_BASE)
--#define ext_irq_count         4
--#define ext_irq_cfg_reg1      PERF_EXTIRQ_CFG_REG_6358
--#define ext_irq_cfg_reg2      0
--#endif
--#ifdef CONFIG_BCM63XX_CPU_6362
--#define irq_stat_reg          PERF_IRQSTAT_6362_REG
--#define irq_mask_reg          PERF_IRQMASK_6362_REG
--#define irq_bits              64
--#define is_ext_irq_cascaded   1
--#define ext_irq_start         (BCM_6362_EXT_IRQ0 - IRQ_INTERNAL_BASE)
--#define ext_irq_end           (BCM_6362_EXT_IRQ3 - IRQ_INTERNAL_BASE)
--#define ext_irq_count         4
--#define ext_irq_cfg_reg1      PERF_EXTIRQ_CFG_REG_6362
--#define ext_irq_cfg_reg2      0
--#endif
--#ifdef CONFIG_BCM63XX_CPU_6368
--#define irq_stat_reg          PERF_IRQSTAT_6368_REG
--#define irq_mask_reg          PERF_IRQMASK_6368_REG
--#define irq_bits              64
--#define is_ext_irq_cascaded   1
--#define ext_irq_start         (BCM_6368_EXT_IRQ0 - IRQ_INTERNAL_BASE)
--#define ext_irq_end           (BCM_6368_EXT_IRQ5 - IRQ_INTERNAL_BASE)
--#define ext_irq_count         6
--#define ext_irq_cfg_reg1      PERF_EXTIRQ_CFG_REG_6368
--#define ext_irq_cfg_reg2      PERF_EXTIRQ_CFG_REG2_6368
--#endif
--
--#if irq_bits == 32
--#define dispatch_internal                     __dispatch_internal
--#define internal_irq_mask                     __internal_irq_mask_32
--#define internal_irq_unmask                   __internal_irq_unmask_32
--#else
--#define dispatch_internal                     __dispatch_internal_64
--#define internal_irq_mask                     __internal_irq_mask_64
--#define internal_irq_unmask                   __internal_irq_unmask_64
--#endif
--
--#define irq_stat_addr (bcm63xx_regset_address(RSET_PERF) + irq_stat_reg)
--#define irq_mask_addr (bcm63xx_regset_address(RSET_PERF) + irq_mask_reg)
--
--static inline void bcm63xx_init_irq(void)
--{
--}
--#else /* ! BCMCPU_RUNTIME_DETECT */
--
- static u32 irq_stat_addr, irq_mask_addr;
- static void (*dispatch_internal)(void);
- static int is_ext_irq_cascaded;
-@@ -234,7 +126,6 @@ static void bcm63xx_init_irq(void)
-               internal_irq_unmask = __internal_irq_unmask_64;
-       }
- }
--#endif /* ! BCMCPU_RUNTIME_DETECT */
- static inline u32 get_ext_irq_perf_reg(int irq)
- {
diff --git a/target/linux/brcm63xx/patches-3.14/012-MIPS-BCM63XX-remove-RUNTIME_DETECT-from-reset-code.patch b/target/linux/brcm63xx/patches-3.14/012-MIPS-BCM63XX-remove-RUNTIME_DETECT-from-reset-code.patch
deleted file mode 100644 (file)
index f26624e..0000000
+++ /dev/null
@@ -1,85 +0,0 @@
-From 72578a46543821c5b9544842e45fcbed0c1b7eb8 Mon Sep 17 00:00:00 2001
-From: Jonas Gorski <jogo@openwrt.org>
-Date: Tue, 3 Dec 2013 13:35:12 +0100
-Subject: [PATCH 3/8] MIPS: BCM63XX: remove !RUNTIME_DETECT from reset code
-
----
- arch/mips/bcm63xx/reset.c | 60 -----------------------------------------------
- 1 file changed, 60 deletions(-)
-
---- a/arch/mips/bcm63xx/reset.c
-+++ b/arch/mips/bcm63xx/reset.c
-@@ -125,8 +125,6 @@
- #define BCM6368_RESET_PCIE    0
- #define BCM6368_RESET_PCIE_EXT        0
--#ifdef BCMCPU_RUNTIME_DETECT
--
- /*
-  * core reset bits
-  */
-@@ -188,64 +186,6 @@ static int __init bcm63xx_reset_bits_ini
-       return 0;
- }
--#else
--
--#ifdef CONFIG_BCM63XX_CPU_3368
--static const u32 bcm63xx_reset_bits[] = {
--      __GEN_RESET_BITS_TABLE(3368)
--};
--#define reset_reg PERF_SOFTRESET_6358_REG
--#endif
--
--#ifdef CONFIG_BCM63XX_CPU_6328
--static const u32 bcm63xx_reset_bits[] = {
--      __GEN_RESET_BITS_TABLE(6328)
--};
--#define reset_reg PERF_SOFTRESET_6328_REG
--#endif
--
--#ifdef CONFIG_BCM63XX_CPU_6338
--static const u32 bcm63xx_reset_bits[] = {
--      __GEN_RESET_BITS_TABLE(6338)
--};
--#define reset_reg PERF_SOFTRESET_REG
--#endif
--
--#ifdef CONFIG_BCM63XX_CPU_6345
--static const u32 bcm63xx_reset_bits[] = { };
--#define reset_reg 0
--#endif
--
--#ifdef CONFIG_BCM63XX_CPU_6348
--static const u32 bcm63xx_reset_bits[] = {
--      __GEN_RESET_BITS_TABLE(6348)
--};
--#define reset_reg PERF_SOFTRESET_REG
--#endif
--
--#ifdef CONFIG_BCM63XX_CPU_6358
--static const u32 bcm63xx_reset_bits[] = {
--      __GEN_RESET_BITS_TABLE(6358)
--};
--#define reset_reg PERF_SOFTRESET_6358_REG
--#endif
--
--#ifdef CONFIG_BCM63XX_CPU_6362
--static const u32 bcm63xx_reset_bits[] = {
--      __GEN_RESET_BITS_TABLE(6362)
--};
--#define reset_reg PERF_SOFTRESET_6362_REG
--#endif
--
--#ifdef CONFIG_BCM63XX_CPU_6368
--static const u32 bcm63xx_reset_bits[] = {
--      __GEN_RESET_BITS_TABLE(6368)
--};
--#define reset_reg PERF_SOFTRESET_6368_REG
--#endif
--
--static int __init bcm63xx_reset_bits_init(void) { return 0; }
--#endif
- static DEFINE_SPINLOCK(reset_mutex);
diff --git a/target/linux/brcm63xx/patches-3.14/013-MIPS-BCM63XX-remove-RUNTIME_DETECT-code-from-gpio.patch b/target/linux/brcm63xx/patches-3.14/013-MIPS-BCM63XX-remove-RUNTIME_DETECT-code-from-gpio.patch
deleted file mode 100644 (file)
index 49a3475..0000000
+++ /dev/null
@@ -1,39 +0,0 @@
-From 1aab93c5c97c55fef130726a6f58c9a1fd5b6240 Mon Sep 17 00:00:00 2001
-From: Jonas Gorski <jogo@openwrt.org>
-Date: Tue, 3 Dec 2013 13:36:45 +0100
-Subject: [PATCH 4/8] MIPS: BCM63XX: remove !RUNTIME_DETECT code from gpio
-
----
- arch/mips/bcm63xx/gpio.c | 14 --------------
- 1 file changed, 14 deletions(-)
-
---- a/arch/mips/bcm63xx/gpio.c
-+++ b/arch/mips/bcm63xx/gpio.c
-@@ -18,19 +18,6 @@
- #include <bcm63xx_io.h>
- #include <bcm63xx_regs.h>
--#ifndef BCMCPU_RUNTIME_DETECT
--#define gpio_out_low_reg      GPIO_DATA_LO_REG
--#ifdef CONFIG_BCM63XX_CPU_6345
--#ifdef gpio_out_low_reg
--#undef gpio_out_low_reg
--#define gpio_out_low_reg      GPIO_DATA_LO_REG_6345
--#endif /* gpio_out_low_reg */
--#endif /* CONFIG_BCM63XX_CPU_6345 */
--
--static inline void bcm63xx_gpio_out_low_reg_init(void)
--{
--}
--#else /* ! BCMCPU_RUNTIME_DETECT */
- static u32 gpio_out_low_reg;
- static void bcm63xx_gpio_out_low_reg_init(void)
-@@ -44,7 +31,6 @@ static void bcm63xx_gpio_out_low_reg_ini
-               break;
-       }
- }
--#endif /* ! BCMCPU_RUNTIME_DETECT */
- static DEFINE_SPINLOCK(bcm63xx_gpio_lock);
- static u32 gpio_out_low, gpio_out_high;
diff --git a/target/linux/brcm63xx/patches-3.14/014-MIPS-BCM63XX-remove-RUNTIME_DETECT-from-spi-code.patch b/target/linux/brcm63xx/patches-3.14/014-MIPS-BCM63XX-remove-RUNTIME_DETECT-from-spi-code.patch
deleted file mode 100644 (file)
index afde39b..0000000
+++ /dev/null
@@ -1,80 +0,0 @@
-From 94f819bc230bb61a9ff21da6c860a40ca68c2805 Mon Sep 17 00:00:00 2001
-From: Jonas Gorski <jogo@openwrt.org>
-Date: Tue, 3 Dec 2013 13:43:35 +0100
-Subject: [PATCH 5/8] MIPS: BCM63XX: remove !RUNTIME_DETECT from spi code
-
----
- arch/mips/bcm63xx/dev-spi.c                        |  4 ---
- .../include/asm/mach-bcm63xx/bcm63xx_dev_spi.h     | 31 ----------------------
- 2 files changed, 35 deletions(-)
-
---- a/arch/mips/bcm63xx/dev-spi.c
-+++ b/arch/mips/bcm63xx/dev-spi.c
-@@ -18,7 +18,6 @@
- #include <bcm63xx_dev_spi.h>
- #include <bcm63xx_regs.h>
--#ifdef BCMCPU_RUNTIME_DETECT
- /*
-  * register offsets
-  */
-@@ -41,9 +40,6 @@ static __init void bcm63xx_spi_regs_init
-               BCMCPU_IS_6362() || BCMCPU_IS_6368())
-               bcm63xx_regs_spi = bcm6358_regs_spi;
- }
--#else
--static __init void bcm63xx_spi_regs_init(void) { }
--#endif
- static struct resource spi_resources[] = {
-       {
---- a/arch/mips/include/asm/mach-bcm63xx/bcm63xx_dev_spi.h
-+++ b/arch/mips/include/asm/mach-bcm63xx/bcm63xx_dev_spi.h
-@@ -30,26 +30,6 @@ enum bcm63xx_regs_spi {
-       SPI_RX_DATA,
- };
--#define __GEN_SPI_RSET_BASE(__cpu, __rset)                            \
--      case SPI_## __rset:                                             \
--              return SPI_## __cpu ##_## __rset;
--
--#define __GEN_SPI_RSET(__cpu)                                         \
--      switch (reg) {                                                  \
--      __GEN_SPI_RSET_BASE(__cpu, CMD)                                 \
--      __GEN_SPI_RSET_BASE(__cpu, INT_STATUS)                          \
--      __GEN_SPI_RSET_BASE(__cpu, INT_MASK_ST)                         \
--      __GEN_SPI_RSET_BASE(__cpu, INT_MASK)                            \
--      __GEN_SPI_RSET_BASE(__cpu, ST)                                  \
--      __GEN_SPI_RSET_BASE(__cpu, CLK_CFG)                             \
--      __GEN_SPI_RSET_BASE(__cpu, FILL_BYTE)                           \
--      __GEN_SPI_RSET_BASE(__cpu, MSG_TAIL)                            \
--      __GEN_SPI_RSET_BASE(__cpu, RX_TAIL)                             \
--      __GEN_SPI_RSET_BASE(__cpu, MSG_CTL)                             \
--      __GEN_SPI_RSET_BASE(__cpu, MSG_DATA)                            \
--      __GEN_SPI_RSET_BASE(__cpu, RX_DATA)                             \
--      }
--
- #define __GEN_SPI_REGS_TABLE(__cpu)                                   \
-       [SPI_CMD]               = SPI_## __cpu ##_CMD,                  \
-       [SPI_INT_STATUS]        = SPI_## __cpu ##_INT_STATUS,           \
-@@ -66,20 +46,9 @@ enum bcm63xx_regs_spi {
- static inline unsigned long bcm63xx_spireg(enum bcm63xx_regs_spi reg)
- {
--#ifdef BCMCPU_RUNTIME_DETECT
-       extern const unsigned long *bcm63xx_regs_spi;
-       return bcm63xx_regs_spi[reg];
--#else
--#if defined(CONFIG_BCM63XX_CPU_6338) || defined(CONFIG_BCM63XX_CPU_6348)
--      __GEN_SPI_RSET(6348)
--#endif
--#if defined(CONFIG_BCM63XX_CPU_6358) || defined(CONFIG_BCM63XX_CPU_6362) || \
--      defined(CONFIG_BCM63XX_CPU_6368)
--      __GEN_SPI_RSET(6358)
--#endif
--#endif
--      return 0;
- }
- #endif /* BCM63XX_DEV_SPI_H */
diff --git a/target/linux/brcm63xx/patches-3.14/015-MIPS-BCM63XX-remove-RUNTIME_DETECT-usage-from-enet-c.patch b/target/linux/brcm63xx/patches-3.14/015-MIPS-BCM63XX-remove-RUNTIME_DETECT-usage-from-enet-c.patch
deleted file mode 100644 (file)
index 0dba2e2..0000000
+++ /dev/null
@@ -1,89 +0,0 @@
-From ed6c71de07ad042691ec02e9eb97375ddc91ed01 Mon Sep 17 00:00:00 2001
-From: Jonas Gorski <jogo@openwrt.org>
-Date: Tue, 3 Dec 2013 13:45:22 +0100
-Subject: [PATCH 6/8] MIPS: BCM63XX: remove !RUNTIME_DETECT usage from enet
- code
-
----
- arch/mips/bcm63xx/dev-enet.c                       |  4 --
- .../include/asm/mach-bcm63xx/bcm63xx_dev_enet.h    | 46 ----------------------
- 2 files changed, 50 deletions(-)
-
---- a/arch/mips/bcm63xx/dev-enet.c
-+++ b/arch/mips/bcm63xx/dev-enet.c
-@@ -14,7 +14,6 @@
- #include <bcm63xx_io.h>
- #include <bcm63xx_regs.h>
--#ifdef BCMCPU_RUNTIME_DETECT
- static const unsigned long bcm6348_regs_enetdmac[] = {
-       [ENETDMAC_CHANCFG]      = ENETDMAC_CHANCFG_REG,
-       [ENETDMAC_IR]           = ENETDMAC_IR_REG,
-@@ -43,9 +42,6 @@ static __init void bcm63xx_enetdmac_regs
-       else
-               bcm63xx_regs_enetdmac = bcm6348_regs_enetdmac;
- }
--#else
--static __init void bcm63xx_enetdmac_regs_init(void) { }
--#endif
- static struct resource shared_res[] = {
-       {
---- a/arch/mips/include/asm/mach-bcm63xx/bcm63xx_dev_enet.h
-+++ b/arch/mips/include/asm/mach-bcm63xx/bcm63xx_dev_enet.h
-@@ -112,55 +112,9 @@ enum bcm63xx_regs_enetdmac {
- static inline unsigned long bcm63xx_enetdmacreg(enum bcm63xx_regs_enetdmac reg)
- {
--#ifdef BCMCPU_RUNTIME_DETECT
-       extern const unsigned long *bcm63xx_regs_enetdmac;
-       return bcm63xx_regs_enetdmac[reg];
--#else
--#ifdef CONFIG_BCM63XX_CPU_6345
--      switch (reg) {
--      case ENETDMAC_CHANCFG:
--              return ENETDMA_6345_CHANCFG_REG;
--      case ENETDMAC_IR:
--              return ENETDMA_6345_IR_REG;
--      case ENETDMAC_IRMASK:
--              return ENETDMA_6345_IRMASK_REG;
--      case ENETDMAC_MAXBURST:
--              return ENETDMA_6345_MAXBURST_REG;
--      case ENETDMAC_BUFALLOC:
--              return ENETDMA_6345_BUFALLOC_REG;
--      case ENETDMAC_RSTART:
--              return ENETDMA_6345_RSTART_REG;
--      case ENETDMAC_FC:
--              return ENETDMA_6345_FC_REG;
--      case ENETDMAC_LEN:
--              return ENETDMA_6345_LEN_REG;
--      }
--#endif
--#if defined(CONFIG_BCM63XX_CPU_6328) || \
--      defined(CONFIG_BCM63XX_CPU_6338) || \
--      defined(CONFIG_BCM63XX_CPU_6348) || \
--      defined(CONFIG_BCM63XX_CPU_6358) || \
--      defined(CONFIG_BCM63XX_CPU_6362) || \
--      defined(CONFIG_BCM63XX_CPU_6368)
--      switch (reg) {
--      case ENETDMAC_CHANCFG:
--              return ENETDMAC_CHANCFG_REG;
--      case ENETDMAC_IR:
--              return ENETDMAC_IR_REG;
--      case ENETDMAC_IRMASK:
--              return ENETDMAC_IRMASK_REG;
--      case ENETDMAC_MAXBURST:
--              return ENETDMAC_MAXBURST_REG;
--      case ENETDMAC_BUFALLOC:
--      case ENETDMAC_RSTART:
--      case ENETDMAC_FC:
--      case ENETDMAC_LEN:
--              return 0;
--      }
--#endif
--#endif
--      return 0;
- }
diff --git a/target/linux/brcm63xx/patches-3.14/016-MIPS-BCM63XX-remove-RUNTIME_DETECT-in-cpu-feature-ov.patch b/target/linux/brcm63xx/patches-3.14/016-MIPS-BCM63XX-remove-RUNTIME_DETECT-in-cpu-feature-ov.patch
deleted file mode 100644 (file)
index 6316b8d..0000000
+++ /dev/null
@@ -1,23 +0,0 @@
-From 12c6957004d6770f4b34d59d8a3cafd5d8bfce15 Mon Sep 17 00:00:00 2001
-From: Jonas Gorski <jogo@openwrt.org>
-Date: Tue, 3 Dec 2013 14:06:12 +0100
-Subject: [PATCH 7/8] MIPS: BCM63XX: remove !RUNTIME_DETECT in
- cpu-feature-overrides
-
-All three SoCs have in common they have a BMIPS32/BMIPS3300 CPU, so
-we can replace this as no SoC with BMIPS4350 support enabled.
----
- arch/mips/include/asm/mach-bcm63xx/cpu-feature-overrides.h | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
---- a/arch/mips/include/asm/mach-bcm63xx/cpu-feature-overrides.h
-+++ b/arch/mips/include/asm/mach-bcm63xx/cpu-feature-overrides.h
-@@ -24,7 +24,7 @@
- #define cpu_has_smartmips             0
- #define cpu_has_vtag_icache           0
--#if !defined(BCMCPU_RUNTIME_DETECT) && (defined(CONFIG_BCM63XX_CPU_6348) || defined(CONFIG_BCM63XX_CPU_6345) || defined(CONFIG_BCM63XX_CPU_6338))
-+#if !defined(CONFIG_SYS_HAS_CPU_BMIPS4350)
- #define cpu_has_dc_aliases            0
- #endif
diff --git a/target/linux/brcm63xx/patches-3.14/017-MIPS-BCM63XX-remove-RUNTIME_DETECT-code-for-bcmcpu_g.patch b/target/linux/brcm63xx/patches-3.14/017-MIPS-BCM63XX-remove-RUNTIME_DETECT-code-for-bcmcpu_g.patch
deleted file mode 100644 (file)
index e40cfa0..0000000
+++ /dev/null
@@ -1,199 +0,0 @@
-From 78c3d2e796a28ad55f6c2310a11ab22e91bb52fc Mon Sep 17 00:00:00 2001
-From: Jonas Gorski <jogo@openwrt.org>
-Date: Mon, 2 Dec 2013 12:30:44 +0100
-Subject: [PATCH 8/8] MIPS: BCM63XX: remove !RUNTIME_DETECT code for
- bcmcpu_get_id
-
-Use the same pattern as with get_*_cpu_type() to allow the compiler
-to remove code for non enabled devices.
-
-Signed-off-by: Jonas Gorski <jogo@openwrt.org>
----
- arch/mips/bcm63xx/cpu.c                          |  11 +--
- arch/mips/include/asm/mach-bcm63xx/bcm63xx_cpu.h | 120 +++++++----------------
- 2 files changed, 38 insertions(+), 93 deletions(-)
-
---- a/arch/mips/bcm63xx/cpu.c
-+++ b/arch/mips/bcm63xx/cpu.c
-@@ -24,7 +24,9 @@ EXPORT_SYMBOL(bcm63xx_regs_base);
- const int *bcm63xx_irqs;
- EXPORT_SYMBOL(bcm63xx_irqs);
--static u16 bcm63xx_cpu_id;
-+u16 bcm63xx_cpu_id __read_mostly;
-+EXPORT_SYMBOL(bcm63xx_cpu_id);
-+
- static u8 bcm63xx_cpu_rev;
- static unsigned int bcm63xx_cpu_freq;
- static unsigned int bcm63xx_memory_size;
-@@ -97,13 +99,6 @@ static const int bcm6368_irqs[] = {
- };
--u16 __bcm63xx_get_cpu_id(void)
--{
--      return bcm63xx_cpu_id;
--}
--
--EXPORT_SYMBOL(__bcm63xx_get_cpu_id);
--
- u8 bcm63xx_get_cpu_rev(void)
- {
-       return bcm63xx_cpu_rev;
---- a/arch/mips/include/asm/mach-bcm63xx/bcm63xx_cpu.h
-+++ b/arch/mips/include/asm/mach-bcm63xx/bcm63xx_cpu.h
-@@ -19,118 +19,68 @@
- #define BCM6368_CPU_ID                0x6368
- void __init bcm63xx_cpu_init(void);
--u16 __bcm63xx_get_cpu_id(void);
- u8 bcm63xx_get_cpu_rev(void);
- unsigned int bcm63xx_get_cpu_freq(void);
-+static inline u16 __pure __bcm63xx_get_cpu_id(const u16 cpu_id)
-+{
-+      switch (cpu_id) {
- #ifdef CONFIG_BCM63XX_CPU_3368
--# ifdef bcm63xx_get_cpu_id
--#  undef bcm63xx_get_cpu_id
--#  define bcm63xx_get_cpu_id()        __bcm63xx_get_cpu_id()
--#  define BCMCPU_RUNTIME_DETECT
--# else
--#  define bcm63xx_get_cpu_id()        BCM3368_CPU_ID
--# endif
--# define BCMCPU_IS_3368()     (bcm63xx_get_cpu_id() == BCM3368_CPU_ID)
--#else
--# define BCMCPU_IS_3368()     (0)
-+              case BCM3368_CPU_ID:
- #endif
- #ifdef CONFIG_BCM63XX_CPU_6328
--# ifdef bcm63xx_get_cpu_id
--#  undef bcm63xx_get_cpu_id
--#  define bcm63xx_get_cpu_id()        __bcm63xx_get_cpu_id()
--#  define BCMCPU_RUNTIME_DETECT
--# else
--#  define bcm63xx_get_cpu_id()        BCM6328_CPU_ID
--# endif
--# define BCMCPU_IS_6328()     (bcm63xx_get_cpu_id() == BCM6328_CPU_ID)
--#else
--# define BCMCPU_IS_6328()     (0)
-+              case BCM6328_CPU_ID:
- #endif
- #ifdef CONFIG_BCM63XX_CPU_6338
--# ifdef bcm63xx_get_cpu_id
--#  undef bcm63xx_get_cpu_id
--#  define bcm63xx_get_cpu_id()        __bcm63xx_get_cpu_id()
--#  define BCMCPU_RUNTIME_DETECT
--# else
--#  define bcm63xx_get_cpu_id()        BCM6338_CPU_ID
--# endif
--# define BCMCPU_IS_6338()     (bcm63xx_get_cpu_id() == BCM6338_CPU_ID)
--#else
--# define BCMCPU_IS_6338()     (0)
-+              case BCM6338_CPU_ID:
- #endif
- #ifdef CONFIG_BCM63XX_CPU_6345
--# ifdef bcm63xx_get_cpu_id
--#  undef bcm63xx_get_cpu_id
--#  define bcm63xx_get_cpu_id()        __bcm63xx_get_cpu_id()
--#  define BCMCPU_RUNTIME_DETECT
--# else
--#  define bcm63xx_get_cpu_id()        BCM6345_CPU_ID
--# endif
--# define BCMCPU_IS_6345()     (bcm63xx_get_cpu_id() == BCM6345_CPU_ID)
--#else
--# define BCMCPU_IS_6345()     (0)
-+              case BCM6345_CPU_ID:
- #endif
- #ifdef CONFIG_BCM63XX_CPU_6348
--# ifdef bcm63xx_get_cpu_id
--#  undef bcm63xx_get_cpu_id
--#  define bcm63xx_get_cpu_id()        __bcm63xx_get_cpu_id()
--#  define BCMCPU_RUNTIME_DETECT
--# else
--#  define bcm63xx_get_cpu_id()        BCM6348_CPU_ID
--# endif
--# define BCMCPU_IS_6348()     (bcm63xx_get_cpu_id() == BCM6348_CPU_ID)
--#else
--# define BCMCPU_IS_6348()     (0)
-+              case BCM6348_CPU_ID:
- #endif
- #ifdef CONFIG_BCM63XX_CPU_6358
--# ifdef bcm63xx_get_cpu_id
--#  undef bcm63xx_get_cpu_id
--#  define bcm63xx_get_cpu_id()        __bcm63xx_get_cpu_id()
--#  define BCMCPU_RUNTIME_DETECT
--# else
--#  define bcm63xx_get_cpu_id()        BCM6358_CPU_ID
--# endif
--# define BCMCPU_IS_6358()     (bcm63xx_get_cpu_id() == BCM6358_CPU_ID)
--#else
--# define BCMCPU_IS_6358()     (0)
-+              case BCM6358_CPU_ID:
- #endif
- #ifdef CONFIG_BCM63XX_CPU_6362
--# ifdef bcm63xx_get_cpu_id
--#  undef bcm63xx_get_cpu_id
--#  define bcm63xx_get_cpu_id()        __bcm63xx_get_cpu_id()
--#  define BCMCPU_RUNTIME_DETECT
--# else
--#  define bcm63xx_get_cpu_id()        BCM6362_CPU_ID
--# endif
--# define BCMCPU_IS_6362()     (bcm63xx_get_cpu_id() == BCM6362_CPU_ID)
--#else
--# define BCMCPU_IS_6362()     (0)
-+              case BCM6362_CPU_ID:
- #endif
--
- #ifdef CONFIG_BCM63XX_CPU_6368
--# ifdef bcm63xx_get_cpu_id
--#  undef bcm63xx_get_cpu_id
--#  define bcm63xx_get_cpu_id()        __bcm63xx_get_cpu_id()
--#  define BCMCPU_RUNTIME_DETECT
--# else
--#  define bcm63xx_get_cpu_id()        BCM6368_CPU_ID
--# endif
--# define BCMCPU_IS_6368()     (bcm63xx_get_cpu_id() == BCM6368_CPU_ID)
--#else
--# define BCMCPU_IS_6368()     (0)
--#endif
--
--#ifndef bcm63xx_get_cpu_id
--#error "No CPU support configured"
-+              case BCM6368_CPU_ID:
- #endif
-+              break;
-+      default:
-+              unreachable();
-+      }
-+
-+      return cpu_id;
-+}
-+
-+extern u16 bcm63xx_cpu_id;
-+
-+static inline u16 __pure bcm63xx_get_cpu_id(void)
-+{
-+      const u16 cpu_id = bcm63xx_cpu_id;
-+
-+      return __bcm63xx_get_cpu_id(cpu_id);
-+}
-+
-+#define BCMCPU_IS_3368()      (bcm63xx_get_cpu_id() == BCM3368_CPU_ID)
-+#define BCMCPU_IS_6328()      (bcm63xx_get_cpu_id() == BCM6328_CPU_ID)
-+#define BCMCPU_IS_6338()      (bcm63xx_get_cpu_id() == BCM6338_CPU_ID)
-+#define BCMCPU_IS_6345()      (bcm63xx_get_cpu_id() == BCM6345_CPU_ID)
-+#define BCMCPU_IS_6348()      (bcm63xx_get_cpu_id() == BCM6348_CPU_ID)
-+#define BCMCPU_IS_6358()      (bcm63xx_get_cpu_id() == BCM6358_CPU_ID)
-+#define BCMCPU_IS_6362()      (bcm63xx_get_cpu_id() == BCM6362_CPU_ID)
-+#define BCMCPU_IS_6368()      (bcm63xx_get_cpu_id() == BCM6368_CPU_ID)
- /*
-  * While registers sets are (mostly) the same across 63xx CPU, base
diff --git a/target/linux/brcm63xx/patches-3.14/018-MIPS-BCM63XX-add-width-to-__dispatch_internal.patch b/target/linux/brcm63xx/patches-3.14/018-MIPS-BCM63XX-add-width-to-__dispatch_internal.patch
deleted file mode 100644 (file)
index dc8f8b3..0000000
+++ /dev/null
@@ -1,41 +0,0 @@
-From a2015bfad293a7eb79519beb60381cb996c6e298 Mon Sep 17 00:00:00 2001
-From: Jonas Gorski <jogo@openwrt.org>
-Date: Thu, 21 Mar 2013 17:05:15 +0100
-Subject: [PATCH 01/10] MIPS: BCM63XX: add width to __dispatch_internal
-
-Make it follow the same naming convention as the other functions.
-
-Signed-off-by: Jonas Gorski <jogo@openwrt.org>
----
- arch/mips/bcm63xx/irq.c | 6 +++---
- 1 file changed, 3 insertions(+), 3 deletions(-)
-
---- a/arch/mips/bcm63xx/irq.c
-+++ b/arch/mips/bcm63xx/irq.c
-@@ -19,7 +19,7 @@
- #include <bcm63xx_io.h>
- #include <bcm63xx_irq.h>
--static void __dispatch_internal(void) __maybe_unused;
-+static void __dispatch_internal_32(void) __maybe_unused;
- static void __dispatch_internal_64(void) __maybe_unused;
- static void __internal_irq_mask_32(unsigned int irq) __maybe_unused;
- static void __internal_irq_mask_64(unsigned int irq) __maybe_unused;
-@@ -117,7 +117,7 @@ static void bcm63xx_init_irq(void)
-       }
-       if (irq_bits == 32) {
--              dispatch_internal = __dispatch_internal;
-+              dispatch_internal = __dispatch_internal_32;
-               internal_irq_mask = __internal_irq_mask_32;
-               internal_irq_unmask = __internal_irq_unmask_32;
-       } else {
-@@ -149,7 +149,7 @@ static inline void handle_internal(int i
-  * will resume the loop where it ended the last time we left this
-  * function.
-  */
--static void __dispatch_internal(void)
-+static void __dispatch_internal_32(void)
- {
-       u32 pending;
-       static int i;
diff --git a/target/linux/brcm63xx/patches-3.14/019-MIPS-BCM63XX-move-bcm63xx_init_irq-down.patch b/target/linux/brcm63xx/patches-3.14/019-MIPS-BCM63XX-move-bcm63xx_init_irq-down.patch
deleted file mode 100644 (file)
index c9dc4ce..0000000
+++ /dev/null
@@ -1,225 +0,0 @@
-From 6e79c6dd02aa56e37eb071797f0eb5e3fb588cba Mon Sep 17 00:00:00 2001
-From: Jonas Gorski <jogo@openwrt.org>
-Date: Sun, 15 Dec 2013 20:52:53 +0100
-Subject: [PATCH 02/10] MIPS: BCM63XX: move bcm63xx_init_irq down
-
-Allows up to drop the prototypes from the top.
-
-Signed-off-by: Jonas Gorski <jogo@openwrt.org>
----
- arch/mips/bcm63xx/irq.c | 190 +++++++++++++++++++++++-------------------------
- 1 file changed, 92 insertions(+), 98 deletions(-)
-
---- a/arch/mips/bcm63xx/irq.c
-+++ b/arch/mips/bcm63xx/irq.c
-@@ -19,13 +19,6 @@
- #include <bcm63xx_io.h>
- #include <bcm63xx_irq.h>
--static void __dispatch_internal_32(void) __maybe_unused;
--static void __dispatch_internal_64(void) __maybe_unused;
--static void __internal_irq_mask_32(unsigned int irq) __maybe_unused;
--static void __internal_irq_mask_64(unsigned int irq) __maybe_unused;
--static void __internal_irq_unmask_32(unsigned int irq) __maybe_unused;
--static void __internal_irq_unmask_64(unsigned int irq) __maybe_unused;
--
- static u32 irq_stat_addr, irq_mask_addr;
- static void (*dispatch_internal)(void);
- static int is_ext_irq_cascaded;
-@@ -35,97 +28,6 @@ static unsigned int ext_irq_cfg_reg1, ex
- static void (*internal_irq_mask)(unsigned int irq);
- static void (*internal_irq_unmask)(unsigned int irq);
--static void bcm63xx_init_irq(void)
--{
--      int irq_bits;
--
--      irq_stat_addr = bcm63xx_regset_address(RSET_PERF);
--      irq_mask_addr = bcm63xx_regset_address(RSET_PERF);
--
--      switch (bcm63xx_get_cpu_id()) {
--      case BCM3368_CPU_ID:
--              irq_stat_addr += PERF_IRQSTAT_3368_REG;
--              irq_mask_addr += PERF_IRQMASK_3368_REG;
--              irq_bits = 32;
--              ext_irq_count = 4;
--              ext_irq_cfg_reg1 = PERF_EXTIRQ_CFG_REG_3368;
--              break;
--      case BCM6328_CPU_ID:
--              irq_stat_addr += PERF_IRQSTAT_6328_REG;
--              irq_mask_addr += PERF_IRQMASK_6328_REG;
--              irq_bits = 64;
--              ext_irq_count = 4;
--              is_ext_irq_cascaded = 1;
--              ext_irq_start = BCM_6328_EXT_IRQ0 - IRQ_INTERNAL_BASE;
--              ext_irq_end = BCM_6328_EXT_IRQ3 - IRQ_INTERNAL_BASE;
--              ext_irq_cfg_reg1 = PERF_EXTIRQ_CFG_REG_6328;
--              break;
--      case BCM6338_CPU_ID:
--              irq_stat_addr += PERF_IRQSTAT_6338_REG;
--              irq_mask_addr += PERF_IRQMASK_6338_REG;
--              irq_bits = 32;
--              ext_irq_count = 4;
--              ext_irq_cfg_reg1 = PERF_EXTIRQ_CFG_REG_6338;
--              break;
--      case BCM6345_CPU_ID:
--              irq_stat_addr += PERF_IRQSTAT_6345_REG;
--              irq_mask_addr += PERF_IRQMASK_6345_REG;
--              irq_bits = 32;
--              ext_irq_count = 4;
--              ext_irq_cfg_reg1 = PERF_EXTIRQ_CFG_REG_6345;
--              break;
--      case BCM6348_CPU_ID:
--              irq_stat_addr += PERF_IRQSTAT_6348_REG;
--              irq_mask_addr += PERF_IRQMASK_6348_REG;
--              irq_bits = 32;
--              ext_irq_count = 4;
--              ext_irq_cfg_reg1 = PERF_EXTIRQ_CFG_REG_6348;
--              break;
--      case BCM6358_CPU_ID:
--              irq_stat_addr += PERF_IRQSTAT_6358_REG;
--              irq_mask_addr += PERF_IRQMASK_6358_REG;
--              irq_bits = 32;
--              ext_irq_count = 4;
--              is_ext_irq_cascaded = 1;
--              ext_irq_start = BCM_6358_EXT_IRQ0 - IRQ_INTERNAL_BASE;
--              ext_irq_end = BCM_6358_EXT_IRQ3 - IRQ_INTERNAL_BASE;
--              ext_irq_cfg_reg1 = PERF_EXTIRQ_CFG_REG_6358;
--              break;
--      case BCM6362_CPU_ID:
--              irq_stat_addr += PERF_IRQSTAT_6362_REG;
--              irq_mask_addr += PERF_IRQMASK_6362_REG;
--              irq_bits = 64;
--              ext_irq_count = 4;
--              is_ext_irq_cascaded = 1;
--              ext_irq_start = BCM_6362_EXT_IRQ0 - IRQ_INTERNAL_BASE;
--              ext_irq_end = BCM_6362_EXT_IRQ3 - IRQ_INTERNAL_BASE;
--              ext_irq_cfg_reg1 = PERF_EXTIRQ_CFG_REG_6362;
--              break;
--      case BCM6368_CPU_ID:
--              irq_stat_addr += PERF_IRQSTAT_6368_REG;
--              irq_mask_addr += PERF_IRQMASK_6368_REG;
--              irq_bits = 64;
--              ext_irq_count = 6;
--              is_ext_irq_cascaded = 1;
--              ext_irq_start = BCM_6368_EXT_IRQ0 - IRQ_INTERNAL_BASE;
--              ext_irq_end = BCM_6368_EXT_IRQ5 - IRQ_INTERNAL_BASE;
--              ext_irq_cfg_reg1 = PERF_EXTIRQ_CFG_REG_6368;
--              ext_irq_cfg_reg2 = PERF_EXTIRQ_CFG_REG2_6368;
--              break;
--      default:
--              BUG();
--      }
--
--      if (irq_bits == 32) {
--              dispatch_internal = __dispatch_internal_32;
--              internal_irq_mask = __internal_irq_mask_32;
--              internal_irq_unmask = __internal_irq_unmask_32;
--      } else {
--              dispatch_internal = __dispatch_internal_64;
--              internal_irq_mask = __internal_irq_mask_64;
--              internal_irq_unmask = __internal_irq_unmask_64;
--      }
--}
- static inline u32 get_ext_irq_perf_reg(int irq)
- {
-@@ -451,6 +353,98 @@ static struct irqaction cpu_ext_cascade_
-       .flags          = IRQF_NO_THREAD,
- };
-+static void bcm63xx_init_irq(void)
-+{
-+      int irq_bits;
-+
-+      irq_stat_addr = bcm63xx_regset_address(RSET_PERF);
-+      irq_mask_addr = bcm63xx_regset_address(RSET_PERF);
-+
-+      switch (bcm63xx_get_cpu_id()) {
-+      case BCM3368_CPU_ID:
-+              irq_stat_addr += PERF_IRQSTAT_3368_REG;
-+              irq_mask_addr += PERF_IRQMASK_3368_REG;
-+              irq_bits = 32;
-+              ext_irq_count = 4;
-+              ext_irq_cfg_reg1 = PERF_EXTIRQ_CFG_REG_3368;
-+              break;
-+      case BCM6328_CPU_ID:
-+              irq_stat_addr += PERF_IRQSTAT_6328_REG;
-+              irq_mask_addr += PERF_IRQMASK_6328_REG;
-+              irq_bits = 64;
-+              ext_irq_count = 4;
-+              is_ext_irq_cascaded = 1;
-+              ext_irq_start = BCM_6328_EXT_IRQ0 - IRQ_INTERNAL_BASE;
-+              ext_irq_end = BCM_6328_EXT_IRQ3 - IRQ_INTERNAL_BASE;
-+              ext_irq_cfg_reg1 = PERF_EXTIRQ_CFG_REG_6328;
-+              break;
-+      case BCM6338_CPU_ID:
-+              irq_stat_addr += PERF_IRQSTAT_6338_REG;
-+              irq_mask_addr += PERF_IRQMASK_6338_REG;
-+              irq_bits = 32;
-+              ext_irq_count = 4;
-+              ext_irq_cfg_reg1 = PERF_EXTIRQ_CFG_REG_6338;
-+              break;
-+      case BCM6345_CPU_ID:
-+              irq_stat_addr += PERF_IRQSTAT_6345_REG;
-+              irq_mask_addr += PERF_IRQMASK_6345_REG;
-+              irq_bits = 32;
-+              ext_irq_count = 4;
-+              ext_irq_cfg_reg1 = PERF_EXTIRQ_CFG_REG_6345;
-+              break;
-+      case BCM6348_CPU_ID:
-+              irq_stat_addr += PERF_IRQSTAT_6348_REG;
-+              irq_mask_addr += PERF_IRQMASK_6348_REG;
-+              irq_bits = 32;
-+              ext_irq_count = 4;
-+              ext_irq_cfg_reg1 = PERF_EXTIRQ_CFG_REG_6348;
-+              break;
-+      case BCM6358_CPU_ID:
-+              irq_stat_addr += PERF_IRQSTAT_6358_REG;
-+              irq_mask_addr += PERF_IRQMASK_6358_REG;
-+              irq_bits = 32;
-+              ext_irq_count = 4;
-+              is_ext_irq_cascaded = 1;
-+              ext_irq_start = BCM_6358_EXT_IRQ0 - IRQ_INTERNAL_BASE;
-+              ext_irq_end = BCM_6358_EXT_IRQ3 - IRQ_INTERNAL_BASE;
-+              ext_irq_cfg_reg1 = PERF_EXTIRQ_CFG_REG_6358;
-+              break;
-+      case BCM6362_CPU_ID:
-+              irq_stat_addr += PERF_IRQSTAT_6362_REG;
-+              irq_mask_addr += PERF_IRQMASK_6362_REG;
-+              irq_bits = 64;
-+              ext_irq_count = 4;
-+              is_ext_irq_cascaded = 1;
-+              ext_irq_start = BCM_6362_EXT_IRQ0 - IRQ_INTERNAL_BASE;
-+              ext_irq_end = BCM_6362_EXT_IRQ3 - IRQ_INTERNAL_BASE;
-+              ext_irq_cfg_reg1 = PERF_EXTIRQ_CFG_REG_6362;
-+              break;
-+      case BCM6368_CPU_ID:
-+              irq_stat_addr += PERF_IRQSTAT_6368_REG;
-+              irq_mask_addr += PERF_IRQMASK_6368_REG;
-+              irq_bits = 64;
-+              ext_irq_count = 6;
-+              is_ext_irq_cascaded = 1;
-+              ext_irq_start = BCM_6368_EXT_IRQ0 - IRQ_INTERNAL_BASE;
-+              ext_irq_end = BCM_6368_EXT_IRQ5 - IRQ_INTERNAL_BASE;
-+              ext_irq_cfg_reg1 = PERF_EXTIRQ_CFG_REG_6368;
-+              ext_irq_cfg_reg2 = PERF_EXTIRQ_CFG_REG2_6368;
-+              break;
-+      default:
-+              BUG();
-+      }
-+
-+      if (irq_bits == 32) {
-+              dispatch_internal = __dispatch_internal_32;
-+              internal_irq_mask = __internal_irq_mask_32;
-+              internal_irq_unmask = __internal_irq_unmask_32;
-+      } else {
-+              dispatch_internal = __dispatch_internal_64;
-+              internal_irq_mask = __internal_irq_mask_64;
-+              internal_irq_unmask = __internal_irq_unmask_64;
-+      }
-+}
-+
- void __init arch_init_irq(void)
- {
-       int i;
diff --git a/target/linux/brcm63xx/patches-3.14/020-MIPS-BCM63XX-replace-irq-dispatch-code-with-a-generi.patch b/target/linux/brcm63xx/patches-3.14/020-MIPS-BCM63XX-replace-irq-dispatch-code-with-a-generi.patch
deleted file mode 100644 (file)
index 021d0d9..0000000
+++ /dev/null
@@ -1,174 +0,0 @@
-From 39b46ed1c9fe71890566e129d9ac5feb8421b3b4 Mon Sep 17 00:00:00 2001
-From: Jonas Gorski <jogo@openwrt.org>
-Date: Thu, 18 Apr 2013 21:14:49 +0200
-Subject: [PATCH 03/10] MIPS: BCM63XX: replace irq dispatch code with a generic
- version
-
-The generic version uses a variable length of u32 registers instead of u32/u64.
-This allows easier support for "wider" registers without having to rewrite
-everything.
-
-This "generic" version is as fast as the old version in the best case
-(i == next set bit), and twice as fast in the worst case in 64 bits.
-
-Using a macro was chosen over a (forced) inline version because gcc generated
-more compact code with the macro.
-
-The change from (signed) int to unsigned int for i and to_call was intentional
-as the value can be only between 0 and (width - 1) anyway, and allowed gcc to
-optimise the code a bit further.
-
-Signed-off-by: Jonas Gorski <jogo@openwrt.org>
----
- arch/mips/bcm63xx/irq.c | 130 +++++++++++++++++++++---------------------------
- 1 file changed, 56 insertions(+), 74 deletions(-)
-
---- a/arch/mips/bcm63xx/irq.c
-+++ b/arch/mips/bcm63xx/irq.c
-@@ -51,47 +51,65 @@ static inline void handle_internal(int i
-  * will resume the loop where it ended the last time we left this
-  * function.
-  */
--static void __dispatch_internal_32(void)
--{
--      u32 pending;
--      static int i;
--
--      pending = bcm_readl(irq_stat_addr) & bcm_readl(irq_mask_addr);
--
--      if (!pending)
--              return ;
--
--      while (1) {
--              int to_call = i;
--              i = (i + 1) & 0x1f;
--              if (pending & (1 << to_call)) {
--                      handle_internal(to_call);
--                      break;
--              }
--      }
-+#define BUILD_IPIC_INTERNAL(width)                                    \
-+void __dispatch_internal_##width(void)                                        \
-+{                                                                     \
-+      u32 pending[width / 32];                                        \
-+      unsigned int src, tgt;                                          \
-+      bool irqs_pending = false;                                      \
-+      static unsigned int i;                                          \
-+                                                                      \
-+      /* read registers in reverse order */                           \
-+      for (src = 0, tgt = (width / 32); src < (width / 32); src++) {  \
-+              u32 val;                                                \
-+                                                                      \
-+              val = bcm_readl(irq_stat_addr + src * sizeof(u32));     \
-+              val &= bcm_readl(irq_mask_addr + src * sizeof(u32));    \
-+              pending[--tgt] = val;                                   \
-+                                                                      \
-+              if (val)                                                \
-+                      irqs_pending = true;                            \
-+      }                                                               \
-+                                                                      \
-+      if (!irqs_pending)                                              \
-+              return;                                                 \
-+                                                                      \
-+      while (1) {                                                     \
-+              unsigned int to_call = i;                               \
-+                                                                      \
-+              i = (i + 1) & (width - 1);                              \
-+              if (pending[to_call / 32] & (1 << (to_call & 0x1f))) {  \
-+                      handle_internal(to_call);                       \
-+                      break;                                          \
-+              }                                                       \
-+      }                                                               \
-+}                                                                     \
-+                                                                      \
-+static void __internal_irq_mask_##width(unsigned int irq)             \
-+{                                                                     \
-+      u32 val;                                                        \
-+      unsigned reg = (irq / 32) ^ (width/32 - 1);                     \
-+      unsigned bit = irq & 0x1f;                                      \
-+                                                                      \
-+      val = bcm_readl(irq_mask_addr + reg * sizeof(u32));             \
-+      val &= ~(1 << bit);                                             \
-+      bcm_writel(val, irq_mask_addr + reg * sizeof(u32));             \
-+}                                                                     \
-+                                                                      \
-+static void __internal_irq_unmask_##width(unsigned int irq)           \
-+{                                                                     \
-+      u32 val;                                                        \
-+      unsigned reg = (irq / 32) ^ (width/32 - 1);                     \
-+      unsigned bit = irq & 0x1f;                                      \
-+                                                                      \
-+      val = bcm_readl(irq_mask_addr + reg * sizeof(u32));             \
-+      val |= (1 << bit);                                              \
-+      bcm_writel(val, irq_mask_addr + reg * sizeof(u32));             \
- }
--static void __dispatch_internal_64(void)
--{
--      u64 pending;
--      static int i;
--
--      pending = bcm_readq(irq_stat_addr) & bcm_readq(irq_mask_addr);
--
--      if (!pending)
--              return ;
--
--      while (1) {
--              int to_call = i;
--
--              i = (i + 1) & 0x3f;
--              if (pending & (1ull << to_call)) {
--                      handle_internal(to_call);
--                      break;
--              }
--      }
--}
-+BUILD_IPIC_INTERNAL(32);
-+BUILD_IPIC_INTERNAL(64);
- asmlinkage void plat_irq_dispatch(void)
- {
-@@ -128,42 +146,6 @@ asmlinkage void plat_irq_dispatch(void)
-  * internal IRQs operations: only mask/unmask on PERF irq mask
-  * register.
-  */
--static void __internal_irq_mask_32(unsigned int irq)
--{
--      u32 mask;
--
--      mask = bcm_readl(irq_mask_addr);
--      mask &= ~(1 << irq);
--      bcm_writel(mask, irq_mask_addr);
--}
--
--static void __internal_irq_mask_64(unsigned int irq)
--{
--      u64 mask;
--
--      mask = bcm_readq(irq_mask_addr);
--      mask &= ~(1ull << irq);
--      bcm_writeq(mask, irq_mask_addr);
--}
--
--static void __internal_irq_unmask_32(unsigned int irq)
--{
--      u32 mask;
--
--      mask = bcm_readl(irq_mask_addr);
--      mask |= (1 << irq);
--      bcm_writel(mask, irq_mask_addr);
--}
--
--static void __internal_irq_unmask_64(unsigned int irq)
--{
--      u64 mask;
--
--      mask = bcm_readq(irq_mask_addr);
--      mask |= (1ull << irq);
--      bcm_writeq(mask, irq_mask_addr);
--}
--
- static void bcm63xx_internal_irq_mask(struct irq_data *d)
- {
-       internal_irq_mask(d->irq - IRQ_INTERNAL_BASE);
diff --git a/target/linux/brcm63xx/patches-3.14/021-MIPS-BCM63XX-append-irq-line-to-irq_-stat-mask.patch b/target/linux/brcm63xx/patches-3.14/021-MIPS-BCM63XX-append-irq-line-to-irq_-stat-mask.patch
deleted file mode 100644 (file)
index 5b63488..0000000
+++ /dev/null
@@ -1,182 +0,0 @@
-From 96ce0a9d195b2781d6f8d919dea8056b1c409703 Mon Sep 17 00:00:00 2001
-From: Jonas Gorski <jogo@openwrt.org>
-Date: Thu, 25 Apr 2013 00:24:06 +0200
-Subject: [PATCH 04/10] MIPS: BCM63XX: append irq line to irq_{stat,mask}*
-
-The SMP capable irq controllers have two interrupt output pins which are
-controlled through separate registers, so make the variables arrays.
-
-Signed-off-by: Jonas Gorski <jogo@openwrt.org>
----
- arch/mips/bcm63xx/irq.c                           | 51 ++++++++++++-----------
- arch/mips/include/asm/mach-bcm63xx/bcm63xx_regs.h | 16 +++----
- 2 files changed, 34 insertions(+), 33 deletions(-)
-
---- a/arch/mips/bcm63xx/irq.c
-+++ b/arch/mips/bcm63xx/irq.c
-@@ -19,7 +19,8 @@
- #include <bcm63xx_io.h>
- #include <bcm63xx_irq.h>
--static u32 irq_stat_addr, irq_mask_addr;
-+static u32 irq_stat_addr[2];
-+static u32 irq_mask_addr[2];
- static void (*dispatch_internal)(void);
- static int is_ext_irq_cascaded;
- static unsigned int ext_irq_count;
-@@ -64,8 +65,8 @@ void __dispatch_internal_##width(void)
-       for (src = 0, tgt = (width / 32); src < (width / 32); src++) {  \
-               u32 val;                                                \
-                                                                       \
--              val = bcm_readl(irq_stat_addr + src * sizeof(u32));     \
--              val &= bcm_readl(irq_mask_addr + src * sizeof(u32));    \
-+              val = bcm_readl(irq_stat_addr[0] + src * sizeof(u32));  \
-+              val &= bcm_readl(irq_mask_addr[0] + src * sizeof(u32)); \
-               pending[--tgt] = val;                                   \
-                                                                       \
-               if (val)                                                \
-@@ -92,9 +93,9 @@ static void __internal_irq_mask_##width(
-       unsigned reg = (irq / 32) ^ (width/32 - 1);                     \
-       unsigned bit = irq & 0x1f;                                      \
-                                                                       \
--      val = bcm_readl(irq_mask_addr + reg * sizeof(u32));             \
-+      val = bcm_readl(irq_mask_addr[0] + reg * sizeof(u32));          \
-       val &= ~(1 << bit);                                             \
--      bcm_writel(val, irq_mask_addr + reg * sizeof(u32));             \
-+      bcm_writel(val, irq_mask_addr[0] + reg * sizeof(u32));          \
- }                                                                     \
-                                                                       \
- static void __internal_irq_unmask_##width(unsigned int irq)           \
-@@ -103,9 +104,9 @@ static void __internal_irq_unmask_##widt
-       unsigned reg = (irq / 32) ^ (width/32 - 1);                     \
-       unsigned bit = irq & 0x1f;                                      \
-                                                                       \
--      val = bcm_readl(irq_mask_addr + reg * sizeof(u32));             \
-+      val = bcm_readl(irq_mask_addr[0] + reg * sizeof(u32));          \
-       val |= (1 << bit);                                              \
--      bcm_writel(val, irq_mask_addr + reg * sizeof(u32));             \
-+      bcm_writel(val, irq_mask_addr[0] + reg * sizeof(u32));          \
- }
- BUILD_IPIC_INTERNAL(32);
-@@ -339,20 +340,20 @@ static void bcm63xx_init_irq(void)
- {
-       int irq_bits;
--      irq_stat_addr = bcm63xx_regset_address(RSET_PERF);
--      irq_mask_addr = bcm63xx_regset_address(RSET_PERF);
-+      irq_stat_addr[0] = bcm63xx_regset_address(RSET_PERF);
-+      irq_mask_addr[0] = bcm63xx_regset_address(RSET_PERF);
-       switch (bcm63xx_get_cpu_id()) {
-       case BCM3368_CPU_ID:
--              irq_stat_addr += PERF_IRQSTAT_3368_REG;
--              irq_mask_addr += PERF_IRQMASK_3368_REG;
-+              irq_stat_addr[0] += PERF_IRQSTAT_3368_REG;
-+              irq_mask_addr[0] += PERF_IRQMASK_3368_REG;
-               irq_bits = 32;
-               ext_irq_count = 4;
-               ext_irq_cfg_reg1 = PERF_EXTIRQ_CFG_REG_3368;
-               break;
-       case BCM6328_CPU_ID:
--              irq_stat_addr += PERF_IRQSTAT_6328_REG;
--              irq_mask_addr += PERF_IRQMASK_6328_REG;
-+              irq_stat_addr[0] += PERF_IRQSTAT_6328_REG(0);
-+              irq_mask_addr[0] += PERF_IRQMASK_6328_REG(0);
-               irq_bits = 64;
-               ext_irq_count = 4;
-               is_ext_irq_cascaded = 1;
-@@ -361,29 +362,29 @@ static void bcm63xx_init_irq(void)
-               ext_irq_cfg_reg1 = PERF_EXTIRQ_CFG_REG_6328;
-               break;
-       case BCM6338_CPU_ID:
--              irq_stat_addr += PERF_IRQSTAT_6338_REG;
--              irq_mask_addr += PERF_IRQMASK_6338_REG;
-+              irq_stat_addr[0] += PERF_IRQSTAT_6338_REG;
-+              irq_mask_addr[0] += PERF_IRQMASK_6338_REG;
-               irq_bits = 32;
-               ext_irq_count = 4;
-               ext_irq_cfg_reg1 = PERF_EXTIRQ_CFG_REG_6338;
-               break;
-       case BCM6345_CPU_ID:
--              irq_stat_addr += PERF_IRQSTAT_6345_REG;
--              irq_mask_addr += PERF_IRQMASK_6345_REG;
-+              irq_stat_addr[0] += PERF_IRQSTAT_6345_REG;
-+              irq_mask_addr[0] += PERF_IRQMASK_6345_REG;
-               irq_bits = 32;
-               ext_irq_count = 4;
-               ext_irq_cfg_reg1 = PERF_EXTIRQ_CFG_REG_6345;
-               break;
-       case BCM6348_CPU_ID:
--              irq_stat_addr += PERF_IRQSTAT_6348_REG;
--              irq_mask_addr += PERF_IRQMASK_6348_REG;
-+              irq_stat_addr[0] += PERF_IRQSTAT_6348_REG;
-+              irq_mask_addr[0] += PERF_IRQMASK_6348_REG;
-               irq_bits = 32;
-               ext_irq_count = 4;
-               ext_irq_cfg_reg1 = PERF_EXTIRQ_CFG_REG_6348;
-               break;
-       case BCM6358_CPU_ID:
--              irq_stat_addr += PERF_IRQSTAT_6358_REG;
--              irq_mask_addr += PERF_IRQMASK_6358_REG;
-+              irq_stat_addr[0] += PERF_IRQSTAT_6358_REG(0);
-+              irq_mask_addr[0] += PERF_IRQMASK_6358_REG(0);
-               irq_bits = 32;
-               ext_irq_count = 4;
-               is_ext_irq_cascaded = 1;
-@@ -392,8 +393,8 @@ static void bcm63xx_init_irq(void)
-               ext_irq_cfg_reg1 = PERF_EXTIRQ_CFG_REG_6358;
-               break;
-       case BCM6362_CPU_ID:
--              irq_stat_addr += PERF_IRQSTAT_6362_REG;
--              irq_mask_addr += PERF_IRQMASK_6362_REG;
-+              irq_stat_addr[0] += PERF_IRQSTAT_6362_REG(0);
-+              irq_mask_addr[0] += PERF_IRQMASK_6362_REG(0);
-               irq_bits = 64;
-               ext_irq_count = 4;
-               is_ext_irq_cascaded = 1;
-@@ -402,8 +403,8 @@ static void bcm63xx_init_irq(void)
-               ext_irq_cfg_reg1 = PERF_EXTIRQ_CFG_REG_6362;
-               break;
-       case BCM6368_CPU_ID:
--              irq_stat_addr += PERF_IRQSTAT_6368_REG;
--              irq_mask_addr += PERF_IRQMASK_6368_REG;
-+              irq_stat_addr[0] += PERF_IRQSTAT_6368_REG(0);
-+              irq_mask_addr[0] += PERF_IRQMASK_6368_REG(0);
-               irq_bits = 64;
-               ext_irq_count = 6;
-               is_ext_irq_cascaded = 1;
---- a/arch/mips/include/asm/mach-bcm63xx/bcm63xx_regs.h
-+++ b/arch/mips/include/asm/mach-bcm63xx/bcm63xx_regs.h
-@@ -215,23 +215,23 @@
- /* Interrupt Mask register */
- #define PERF_IRQMASK_3368_REG         0xc
--#define PERF_IRQMASK_6328_REG         0x20
-+#define PERF_IRQMASK_6328_REG(x)      (0x20 + (x) * 0x10)
- #define PERF_IRQMASK_6338_REG         0xc
- #define PERF_IRQMASK_6345_REG         0xc
- #define PERF_IRQMASK_6348_REG         0xc
--#define PERF_IRQMASK_6358_REG         0xc
--#define PERF_IRQMASK_6362_REG         0x20
--#define PERF_IRQMASK_6368_REG         0x20
-+#define PERF_IRQMASK_6358_REG(x)      (0xc + (x) * 0x2c)
-+#define PERF_IRQMASK_6362_REG(x)      (0x20 + (x) * 0x10)
-+#define PERF_IRQMASK_6368_REG(x)      (0x20 + (x) * 0x10)
- /* Interrupt Status register */
- #define PERF_IRQSTAT_3368_REG         0x10
--#define PERF_IRQSTAT_6328_REG         0x28
-+#define PERF_IRQSTAT_6328_REG(x)      (0x28 + (x) * 0x10)
- #define PERF_IRQSTAT_6338_REG         0x10
- #define PERF_IRQSTAT_6345_REG         0x10
- #define PERF_IRQSTAT_6348_REG         0x10
--#define PERF_IRQSTAT_6358_REG         0x10
--#define PERF_IRQSTAT_6362_REG         0x28
--#define PERF_IRQSTAT_6368_REG         0x28
-+#define PERF_IRQSTAT_6358_REG(x)      (0x10 + (x) * 0x2c)
-+#define PERF_IRQSTAT_6362_REG(x)      (0x28 + (x) * 0x10)
-+#define PERF_IRQSTAT_6368_REG(x)      (0x28 + (x) * 0x10)
- /* External Interrupt Configuration register */
- #define PERF_EXTIRQ_CFG_REG_3368      0x14
diff --git a/target/linux/brcm63xx/patches-3.14/022-MIPS-BCM63XX-populate-irq_-stat-mask-_addr-for-secon.patch b/target/linux/brcm63xx/patches-3.14/022-MIPS-BCM63XX-populate-irq_-stat-mask-_addr-for-secon.patch
deleted file mode 100644 (file)
index 5f94583..0000000
+++ /dev/null
@@ -1,94 +0,0 @@
-From ff61c72a7a260ab4c4abbddb72c3cd2aea5e0687 Mon Sep 17 00:00:00 2001
-From: Jonas Gorski <jogo@openwrt.org>
-Date: Thu, 25 Apr 2013 00:31:29 +0200
-Subject: [PATCH 05/10] MIPS: BCM63XX: populate irq_{stat,mask}_addr for second
- cpu
-
-Set it to zero if there is no second set.
-
-Signed-off-by: Jonas Gorski <jogo@openwrt.org>
----
- arch/mips/bcm63xx/irq.c | 18 ++++++++++++++++++
- 1 file changed, 18 insertions(+)
-
---- a/arch/mips/bcm63xx/irq.c
-+++ b/arch/mips/bcm63xx/irq.c
-@@ -342,11 +342,15 @@ static void bcm63xx_init_irq(void)
-       irq_stat_addr[0] = bcm63xx_regset_address(RSET_PERF);
-       irq_mask_addr[0] = bcm63xx_regset_address(RSET_PERF);
-+      irq_stat_addr[1] = bcm63xx_regset_address(RSET_PERF);
-+      irq_mask_addr[1] = bcm63xx_regset_address(RSET_PERF);
-       switch (bcm63xx_get_cpu_id()) {
-       case BCM3368_CPU_ID:
-               irq_stat_addr[0] += PERF_IRQSTAT_3368_REG;
-               irq_mask_addr[0] += PERF_IRQMASK_3368_REG;
-+              irq_stat_addr[1] = 0;
-+              irq_stat_addr[1] = 0;
-               irq_bits = 32;
-               ext_irq_count = 4;
-               ext_irq_cfg_reg1 = PERF_EXTIRQ_CFG_REG_3368;
-@@ -354,6 +358,8 @@ static void bcm63xx_init_irq(void)
-       case BCM6328_CPU_ID:
-               irq_stat_addr[0] += PERF_IRQSTAT_6328_REG(0);
-               irq_mask_addr[0] += PERF_IRQMASK_6328_REG(0);
-+              irq_stat_addr[1] += PERF_IRQSTAT_6328_REG(1);
-+              irq_stat_addr[1] += PERF_IRQMASK_6328_REG(1);
-               irq_bits = 64;
-               ext_irq_count = 4;
-               is_ext_irq_cascaded = 1;
-@@ -364,6 +370,8 @@ static void bcm63xx_init_irq(void)
-       case BCM6338_CPU_ID:
-               irq_stat_addr[0] += PERF_IRQSTAT_6338_REG;
-               irq_mask_addr[0] += PERF_IRQMASK_6338_REG;
-+              irq_stat_addr[1] = 0;
-+              irq_mask_addr[1] = 0;
-               irq_bits = 32;
-               ext_irq_count = 4;
-               ext_irq_cfg_reg1 = PERF_EXTIRQ_CFG_REG_6338;
-@@ -371,6 +379,8 @@ static void bcm63xx_init_irq(void)
-       case BCM6345_CPU_ID:
-               irq_stat_addr[0] += PERF_IRQSTAT_6345_REG;
-               irq_mask_addr[0] += PERF_IRQMASK_6345_REG;
-+              irq_stat_addr[1] = 0;
-+              irq_mask_addr[1] = 0;
-               irq_bits = 32;
-               ext_irq_count = 4;
-               ext_irq_cfg_reg1 = PERF_EXTIRQ_CFG_REG_6345;
-@@ -378,6 +388,8 @@ static void bcm63xx_init_irq(void)
-       case BCM6348_CPU_ID:
-               irq_stat_addr[0] += PERF_IRQSTAT_6348_REG;
-               irq_mask_addr[0] += PERF_IRQMASK_6348_REG;
-+              irq_stat_addr[1] = 0;
-+              irq_mask_addr[1] = 0;
-               irq_bits = 32;
-               ext_irq_count = 4;
-               ext_irq_cfg_reg1 = PERF_EXTIRQ_CFG_REG_6348;
-@@ -385,6 +397,8 @@ static void bcm63xx_init_irq(void)
-       case BCM6358_CPU_ID:
-               irq_stat_addr[0] += PERF_IRQSTAT_6358_REG(0);
-               irq_mask_addr[0] += PERF_IRQMASK_6358_REG(0);
-+              irq_stat_addr[1] += PERF_IRQSTAT_6358_REG(1);
-+              irq_mask_addr[1] += PERF_IRQMASK_6358_REG(1);
-               irq_bits = 32;
-               ext_irq_count = 4;
-               is_ext_irq_cascaded = 1;
-@@ -395,6 +409,8 @@ static void bcm63xx_init_irq(void)
-       case BCM6362_CPU_ID:
-               irq_stat_addr[0] += PERF_IRQSTAT_6362_REG(0);
-               irq_mask_addr[0] += PERF_IRQMASK_6362_REG(0);
-+              irq_stat_addr[1] += PERF_IRQSTAT_6362_REG(1);
-+              irq_mask_addr[1] += PERF_IRQMASK_6362_REG(1);
-               irq_bits = 64;
-               ext_irq_count = 4;
-               is_ext_irq_cascaded = 1;
-@@ -405,6 +421,8 @@ static void bcm63xx_init_irq(void)
-       case BCM6368_CPU_ID:
-               irq_stat_addr[0] += PERF_IRQSTAT_6368_REG(0);
-               irq_mask_addr[0] += PERF_IRQMASK_6368_REG(0);
-+              irq_stat_addr[1] += PERF_IRQSTAT_6368_REG(1);
-+              irq_mask_addr[1] += PERF_IRQMASK_6368_REG(1);
-               irq_bits = 64;
-               ext_irq_count = 6;
-               is_ext_irq_cascaded = 1;
diff --git a/target/linux/brcm63xx/patches-3.14/023-MIPS-BCM63XX-add-cpu-argument-to-dispatch-internal.patch b/target/linux/brcm63xx/patches-3.14/023-MIPS-BCM63XX-add-cpu-argument-to-dispatch-internal.patch
deleted file mode 100644 (file)
index 395dc13..0000000
+++ /dev/null
@@ -1,70 +0,0 @@
-From 43ebef8162adfa7789cb915e60e46103965d7efd Mon Sep 17 00:00:00 2001
-From: Jonas Gorski <jogo@openwrt.org>
-Date: Fri, 26 Apr 2013 11:21:16 +0200
-Subject: [PATCH 06/10] MIPS: BCM63XX: add cpu argument to dispatch internal
-
-Signed-off-by: Jonas Gorski <jogo@openwrt.org>
----
- arch/mips/bcm63xx/irq.c | 18 ++++++++++--------
- 1 file changed, 10 insertions(+), 8 deletions(-)
-
---- a/arch/mips/bcm63xx/irq.c
-+++ b/arch/mips/bcm63xx/irq.c
-@@ -19,9 +19,10 @@
- #include <bcm63xx_io.h>
- #include <bcm63xx_irq.h>
-+
- static u32 irq_stat_addr[2];
- static u32 irq_mask_addr[2];
--static void (*dispatch_internal)(void);
-+static void (*dispatch_internal)(int cpu);
- static int is_ext_irq_cascaded;
- static unsigned int ext_irq_count;
- static unsigned int ext_irq_start, ext_irq_end;
-@@ -54,19 +55,20 @@ static inline void handle_internal(int i
-  */
- #define BUILD_IPIC_INTERNAL(width)                                    \
--void __dispatch_internal_##width(void)                                        \
-+void __dispatch_internal_##width(int cpu)                             \
- {                                                                     \
-       u32 pending[width / 32];                                        \
-       unsigned int src, tgt;                                          \
-       bool irqs_pending = false;                                      \
--      static unsigned int i;                                          \
-+      static unsigned int i[2];                                       \
-+      unsigned int *next = &i[cpu];                                   \
-                                                                       \
-       /* read registers in reverse order */                           \
-       for (src = 0, tgt = (width / 32); src < (width / 32); src++) {  \
-               u32 val;                                                \
-                                                                       \
--              val = bcm_readl(irq_stat_addr[0] + src * sizeof(u32));  \
--              val &= bcm_readl(irq_mask_addr[0] + src * sizeof(u32)); \
-+              val = bcm_readl(irq_stat_addr[cpu] + src * sizeof(u32)); \
-+              val &= bcm_readl(irq_mask_addr[cpu] + src * sizeof(u32)); \
-               pending[--tgt] = val;                                   \
-                                                                       \
-               if (val)                                                \
-@@ -77,9 +79,9 @@ void __dispatch_internal_##width(void)
-               return;                                                 \
-                                                                       \
-       while (1) {                                                     \
--              unsigned int to_call = i;                               \
-+              unsigned int to_call = *next;                           \
-                                                                       \
--              i = (i + 1) & (width - 1);                              \
-+              *next = (*next + 1) & (width - 1);                      \
-               if (pending[to_call / 32] & (1 << (to_call & 0x1f))) {  \
-                       handle_internal(to_call);                       \
-                       break;                                          \
-@@ -129,7 +131,7 @@ asmlinkage void plat_irq_dispatch(void)
-               if (cause & CAUSEF_IP1)
-                       do_IRQ(1);
-               if (cause & CAUSEF_IP2)
--                      dispatch_internal();
-+                      dispatch_internal(0);
-               if (!is_ext_irq_cascaded) {
-                       if (cause & CAUSEF_IP3)
-                               do_IRQ(IRQ_EXT_0);
diff --git a/target/linux/brcm63xx/patches-3.14/024-MIPS-BCM63XX-protect-irq-register-accesses.patch b/target/linux/brcm63xx/patches-3.14/024-MIPS-BCM63XX-protect-irq-register-accesses.patch
deleted file mode 100644 (file)
index 18669a1..0000000
+++ /dev/null
@@ -1,162 +0,0 @@
-From 5e86f3988854c62c0788e4820caf722fec7c791b Mon Sep 17 00:00:00 2001
-From: Jonas Gorski <jogo@openwrt.org>
-Date: Sun, 21 Apr 2013 15:38:56 +0200
-Subject: [PATCH 07/10] MIPS: BCM63XX: protect irq register accesses
-
-Since we will have the chance of accessing the registers concurrently,
-protect any accesses through a spinlock.
-
-Signed-off-by: Jonas Gorski <jogo@openwrt.org>
----
- arch/mips/bcm63xx/irq.c | 26 ++++++++++++++++++++++++++
- 1 file changed, 26 insertions(+)
-
---- a/arch/mips/bcm63xx/irq.c
-+++ b/arch/mips/bcm63xx/irq.c
-@@ -12,6 +12,7 @@
- #include <linux/interrupt.h>
- #include <linux/module.h>
- #include <linux/irq.h>
-+#include <linux/spinlock.h>
- #include <asm/irq_cpu.h>
- #include <asm/mipsregs.h>
- #include <bcm63xx_cpu.h>
-@@ -20,6 +21,9 @@
- #include <bcm63xx_irq.h>
-+static DEFINE_SPINLOCK(ipic_lock);
-+static DEFINE_SPINLOCK(epic_lock);
-+
- static u32 irq_stat_addr[2];
- static u32 irq_mask_addr[2];
- static void (*dispatch_internal)(int cpu);
-@@ -62,8 +66,10 @@ void __dispatch_internal_##width(int cpu
-       bool irqs_pending = false;                                      \
-       static unsigned int i[2];                                       \
-       unsigned int *next = &i[cpu];                                   \
-+      unsigned long flags;                                            \
-                                                                       \
-       /* read registers in reverse order */                           \
-+      spin_lock_irqsave(&ipic_lock, flags);                           \
-       for (src = 0, tgt = (width / 32); src < (width / 32); src++) {  \
-               u32 val;                                                \
-                                                                       \
-@@ -74,6 +80,7 @@ void __dispatch_internal_##width(int cpu
-               if (val)                                                \
-                       irqs_pending = true;                            \
-       }                                                               \
-+      spin_unlock_irqrestore(&ipic_lock, flags);                      \
-                                                                       \
-       if (!irqs_pending)                                              \
-               return;                                                 \
-@@ -94,10 +101,13 @@ static void __internal_irq_mask_##width(
-       u32 val;                                                        \
-       unsigned reg = (irq / 32) ^ (width/32 - 1);                     \
-       unsigned bit = irq & 0x1f;                                      \
-+      unsigned long flags;                                            \
-                                                                       \
-+      spin_lock_irqsave(&ipic_lock, flags);                           \
-       val = bcm_readl(irq_mask_addr[0] + reg * sizeof(u32));          \
-       val &= ~(1 << bit);                                             \
-       bcm_writel(val, irq_mask_addr[0] + reg * sizeof(u32));          \
-+      spin_unlock_irqrestore(&ipic_lock, flags);                      \
- }                                                                     \
-                                                                       \
- static void __internal_irq_unmask_##width(unsigned int irq)           \
-@@ -105,10 +115,13 @@ static void __internal_irq_unmask_##widt
-       u32 val;                                                        \
-       unsigned reg = (irq / 32) ^ (width/32 - 1);                     \
-       unsigned bit = irq & 0x1f;                                      \
-+      unsigned long flags;                                            \
-                                                                       \
-+      spin_lock_irqsave(&ipic_lock, flags);                           \
-       val = bcm_readl(irq_mask_addr[0] + reg * sizeof(u32));          \
-       val |= (1 << bit);                                              \
-       bcm_writel(val, irq_mask_addr[0] + reg * sizeof(u32));          \
-+      spin_unlock_irqrestore(&ipic_lock, flags);                      \
- }
- BUILD_IPIC_INTERNAL(32);
-@@ -167,8 +180,10 @@ static void bcm63xx_external_irq_mask(st
- {
-       unsigned int irq = d->irq - IRQ_EXTERNAL_BASE;
-       u32 reg, regaddr;
-+      unsigned long flags;
-       regaddr = get_ext_irq_perf_reg(irq);
-+      spin_lock_irqsave(&epic_lock, flags);
-       reg = bcm_perf_readl(regaddr);
-       if (BCMCPU_IS_6348())
-@@ -177,6 +192,8 @@ static void bcm63xx_external_irq_mask(st
-               reg &= ~EXTIRQ_CFG_MASK(irq % 4);
-       bcm_perf_writel(reg, regaddr);
-+      spin_unlock_irqrestore(&epic_lock, flags);
-+
-       if (is_ext_irq_cascaded)
-               internal_irq_mask(irq + ext_irq_start);
- }
-@@ -185,8 +202,10 @@ static void bcm63xx_external_irq_unmask(
- {
-       unsigned int irq = d->irq - IRQ_EXTERNAL_BASE;
-       u32 reg, regaddr;
-+      unsigned long flags;
-       regaddr = get_ext_irq_perf_reg(irq);
-+      spin_lock_irqsave(&epic_lock, flags);
-       reg = bcm_perf_readl(regaddr);
-       if (BCMCPU_IS_6348())
-@@ -195,6 +214,7 @@ static void bcm63xx_external_irq_unmask(
-               reg |= EXTIRQ_CFG_MASK(irq % 4);
-       bcm_perf_writel(reg, regaddr);
-+      spin_unlock_irqrestore(&epic_lock, flags);
-       if (is_ext_irq_cascaded)
-               internal_irq_unmask(irq + ext_irq_start);
-@@ -204,8 +224,10 @@ static void bcm63xx_external_irq_clear(s
- {
-       unsigned int irq = d->irq - IRQ_EXTERNAL_BASE;
-       u32 reg, regaddr;
-+      unsigned long flags;
-       regaddr = get_ext_irq_perf_reg(irq);
-+      spin_lock_irqsave(&epic_lock, flags);
-       reg = bcm_perf_readl(regaddr);
-       if (BCMCPU_IS_6348())
-@@ -214,6 +236,7 @@ static void bcm63xx_external_irq_clear(s
-               reg |= EXTIRQ_CFG_CLEAR(irq % 4);
-       bcm_perf_writel(reg, regaddr);
-+      spin_unlock_irqrestore(&epic_lock, flags);
- }
- static int bcm63xx_external_irq_set_type(struct irq_data *d,
-@@ -222,6 +245,7 @@ static int bcm63xx_external_irq_set_type
-       unsigned int irq = d->irq - IRQ_EXTERNAL_BASE;
-       u32 reg, regaddr;
-       int levelsense, sense, bothedge;
-+      unsigned long flags;
-       flow_type &= IRQ_TYPE_SENSE_MASK;
-@@ -256,6 +280,7 @@ static int bcm63xx_external_irq_set_type
-       }
-       regaddr = get_ext_irq_perf_reg(irq);
-+      spin_lock_irqsave(&epic_lock, flags);
-       reg = bcm_perf_readl(regaddr);
-       irq %= 4;
-@@ -300,6 +325,7 @@ static int bcm63xx_external_irq_set_type
-       }
-       bcm_perf_writel(reg, regaddr);
-+      spin_unlock_irqrestore(&epic_lock, flags);
-       irqd_set_trigger_type(d, flow_type);
-       if (flow_type & (IRQ_TYPE_LEVEL_LOW | IRQ_TYPE_LEVEL_HIGH))
diff --git a/target/linux/brcm63xx/patches-3.14/025-MIPS-BCM63XX-wire-up-the-second-cpu-s-irq-line.patch b/target/linux/brcm63xx/patches-3.14/025-MIPS-BCM63XX-wire-up-the-second-cpu-s-irq-line.patch
deleted file mode 100644 (file)
index 6e84890..0000000
+++ /dev/null
@@ -1,93 +0,0 @@
-From 6e74b82aca08a5ecc4d2f0780254468659427e82 Mon Sep 17 00:00:00 2001
-From: Jonas Gorski <jogo@openwrt.org>
-Date: Fri, 26 Apr 2013 12:03:15 +0200
-Subject: [PATCH 08/10] MIPS: BCM63XX: wire up the second cpu's irq line
-
-Signed-off-by: Jonas Gorski <jogo@openwrt.org>
----
- arch/mips/bcm63xx/irq.c | 44 +++++++++++++++++++++++++++++++++++++-------
- 1 file changed, 37 insertions(+), 7 deletions(-)
-
---- a/arch/mips/bcm63xx/irq.c
-+++ b/arch/mips/bcm63xx/irq.c
-@@ -102,11 +102,17 @@ static void __internal_irq_mask_##width(
-       unsigned reg = (irq / 32) ^ (width/32 - 1);                     \
-       unsigned bit = irq & 0x1f;                                      \
-       unsigned long flags;                                            \
-+      int cpu;                                                        \
-                                                                       \
-       spin_lock_irqsave(&ipic_lock, flags);                           \
--      val = bcm_readl(irq_mask_addr[0] + reg * sizeof(u32));          \
--      val &= ~(1 << bit);                                             \
--      bcm_writel(val, irq_mask_addr[0] + reg * sizeof(u32));          \
-+      for_each_present_cpu(cpu) {                                     \
-+              if (!irq_mask_addr[cpu])                                \
-+                      break;                                          \
-+                                                                      \
-+              val = bcm_readl(irq_mask_addr[cpu] + reg * sizeof(u32));\
-+              val &= ~(1 << bit);                                     \
-+              bcm_writel(val, irq_mask_addr[cpu] + reg * sizeof(u32));\
-+      }                                                               \
-       spin_unlock_irqrestore(&ipic_lock, flags);                      \
- }                                                                     \
-                                                                       \
-@@ -116,11 +122,20 @@ static void __internal_irq_unmask_##widt
-       unsigned reg = (irq / 32) ^ (width/32 - 1);                     \
-       unsigned bit = irq & 0x1f;                                      \
-       unsigned long flags;                                            \
-+      int cpu;                                                        \
-                                                                       \
-       spin_lock_irqsave(&ipic_lock, flags);                           \
--      val = bcm_readl(irq_mask_addr[0] + reg * sizeof(u32));          \
--      val |= (1 << bit);                                              \
--      bcm_writel(val, irq_mask_addr[0] + reg * sizeof(u32));          \
-+      for_each_present_cpu(cpu) {                                     \
-+              if (!irq_mask_addr[cpu])                                \
-+                      break;                                          \
-+                                                                      \
-+              val = bcm_readl(irq_mask_addr[cpu] + reg * sizeof(u32));\
-+              if (cpu_online(cpu))                                    \
-+                      val |= (1 << bit);                              \
-+              else                                                    \
-+                      val &= ~(1 << bit);                             \
-+              bcm_writel(val, irq_mask_addr[cpu] + reg * sizeof(u32));\
-+      }                                                               \
-       spin_unlock_irqrestore(&ipic_lock, flags);                      \
- }
-@@ -145,7 +160,10 @@ asmlinkage void plat_irq_dispatch(void)
-                       do_IRQ(1);
-               if (cause & CAUSEF_IP2)
-                       dispatch_internal(0);
--              if (!is_ext_irq_cascaded) {
-+              if (is_ext_irq_cascaded) {
-+                      if (cause & CAUSEF_IP3)
-+                              dispatch_internal(1);
-+              } else {
-                       if (cause & CAUSEF_IP3)
-                               do_IRQ(IRQ_EXT_0);
-                       if (cause & CAUSEF_IP4)
-@@ -358,6 +376,14 @@ static struct irqaction cpu_ip2_cascade_
-       .flags          = IRQF_NO_THREAD,
- };
-+#ifdef CONFIG_SMP
-+static struct irqaction cpu_ip3_cascade_action = {
-+      .handler        = no_action,
-+      .name           = "cascade_ip3",
-+      .flags          = IRQF_NO_THREAD,
-+};
-+#endif
-+
- static struct irqaction cpu_ext_cascade_action = {
-       .handler        = no_action,
-       .name           = "cascade_extirq",
-@@ -494,4 +520,8 @@ void __init arch_init_irq(void)
-       }
-       setup_irq(MIPS_CPU_IRQ_BASE + 2, &cpu_ip2_cascade_action);
-+#ifdef CONFIG_SMP
-+      if (is_ext_irq_cascaded)
-+              setup_irq(MIPS_CPU_IRQ_BASE + 3, &cpu_ip3_cascade_action);
-+#endif
- }
diff --git a/target/linux/brcm63xx/patches-3.14/026-MIPS-BCM63XX-use-irq_desc-as-argument-for-un-mask.patch b/target/linux/brcm63xx/patches-3.14/026-MIPS-BCM63XX-use-irq_desc-as-argument-for-un-mask.patch
deleted file mode 100644 (file)
index fc07b4b..0000000
+++ /dev/null
@@ -1,83 +0,0 @@
-From e23dc903cd69d32d407ea1b7310bc9a71e00d359 Mon Sep 17 00:00:00 2001
-From: Jonas Gorski <jogo@openwrt.org>
-Date: Tue, 30 Apr 2013 11:26:53 +0200
-Subject: [PATCH 09/10] MIPS: BCM63XX: use irq_desc as argument for (un)mask
-
-In preparation for applying affinity, use the irq descriptor as the
-argument for (un)mask.
-
-Signed-off-by: Jonas Gorski <jogo@openwrt.org>
----
- arch/mips/bcm63xx/irq.c | 18 ++++++++++--------
- 1 file changed, 10 insertions(+), 8 deletions(-)
-
---- a/arch/mips/bcm63xx/irq.c
-+++ b/arch/mips/bcm63xx/irq.c
-@@ -31,8 +31,8 @@ static int is_ext_irq_cascaded;
- static unsigned int ext_irq_count;
- static unsigned int ext_irq_start, ext_irq_end;
- static unsigned int ext_irq_cfg_reg1, ext_irq_cfg_reg2;
--static void (*internal_irq_mask)(unsigned int irq);
--static void (*internal_irq_unmask)(unsigned int irq);
-+static void (*internal_irq_mask)(struct irq_data *d);
-+static void (*internal_irq_unmask)(struct irq_data *d);
- static inline u32 get_ext_irq_perf_reg(int irq)
-@@ -96,9 +96,10 @@ void __dispatch_internal_##width(int cpu
-       }                                                               \
- }                                                                     \
-                                                                       \
--static void __internal_irq_mask_##width(unsigned int irq)             \
-+static void __internal_irq_mask_##width(struct irq_data *d)           \
- {                                                                     \
-       u32 val;                                                        \
-+      unsigned irq = d->irq - IRQ_INTERNAL_BASE;                      \
-       unsigned reg = (irq / 32) ^ (width/32 - 1);                     \
-       unsigned bit = irq & 0x1f;                                      \
-       unsigned long flags;                                            \
-@@ -116,9 +117,10 @@ static void __internal_irq_mask_##width(
-       spin_unlock_irqrestore(&ipic_lock, flags);                      \
- }                                                                     \
-                                                                       \
--static void __internal_irq_unmask_##width(unsigned int irq)           \
-+static void __internal_irq_unmask_##width(struct irq_data *d)         \
- {                                                                     \
-       u32 val;                                                        \
-+      unsigned irq = d->irq - IRQ_INTERNAL_BASE;                      \
-       unsigned reg = (irq / 32) ^ (width/32 - 1);                     \
-       unsigned bit = irq & 0x1f;                                      \
-       unsigned long flags;                                            \
-@@ -182,12 +184,12 @@ asmlinkage void plat_irq_dispatch(void)
-  */
- static void bcm63xx_internal_irq_mask(struct irq_data *d)
- {
--      internal_irq_mask(d->irq - IRQ_INTERNAL_BASE);
-+      internal_irq_mask(d);
- }
- static void bcm63xx_internal_irq_unmask(struct irq_data *d)
- {
--      internal_irq_unmask(d->irq - IRQ_INTERNAL_BASE);
-+      internal_irq_unmask(d);
- }
- /*
-@@ -213,7 +215,7 @@ static void bcm63xx_external_irq_mask(st
-       spin_unlock_irqrestore(&epic_lock, flags);
-       if (is_ext_irq_cascaded)
--              internal_irq_mask(irq + ext_irq_start);
-+              internal_irq_mask(irq_get_irq_data(irq + ext_irq_start));
- }
- static void bcm63xx_external_irq_unmask(struct irq_data *d)
-@@ -235,7 +237,7 @@ static void bcm63xx_external_irq_unmask(
-       spin_unlock_irqrestore(&epic_lock, flags);
-       if (is_ext_irq_cascaded)
--              internal_irq_unmask(irq + ext_irq_start);
-+              internal_irq_unmask(irq_get_irq_data(irq + ext_irq_start));
- }
- static void bcm63xx_external_irq_clear(struct irq_data *d)
diff --git a/target/linux/brcm63xx/patches-3.14/027-MIPS-BCM63XX-allow-setting-affinity-for-IPIC.patch b/target/linux/brcm63xx/patches-3.14/027-MIPS-BCM63XX-allow-setting-affinity-for-IPIC.patch
deleted file mode 100644 (file)
index a625b2e..0000000
+++ /dev/null
@@ -1,118 +0,0 @@
-From 23493b47d8caaa59b18627a01bf443c3b50bb530 Mon Sep 17 00:00:00 2001
-From: Jonas Gorski <jogo@openwrt.org>
-Date: Fri, 26 Apr 2013 12:06:03 +0200
-Subject: [PATCH 10/10] MIPS: BCM63XX: allow setting affinity for IPIC
-
-Wire up the set_affinity call for the internal PIC if booting on
-a cpu supporting it.
-Affinity is kept to boot cpu as default.
-
-Signed-off-by: Jonas Gorski <jogo@openwrt.org>
----
- arch/mips/bcm63xx/irq.c | 46 ++++++++++++++++++++++++++++++++++++++++------
- 1 file changed, 40 insertions(+), 6 deletions(-)
-
---- a/arch/mips/bcm63xx/irq.c
-+++ b/arch/mips/bcm63xx/irq.c
-@@ -32,7 +32,7 @@ static unsigned int ext_irq_count;
- static unsigned int ext_irq_start, ext_irq_end;
- static unsigned int ext_irq_cfg_reg1, ext_irq_cfg_reg2;
- static void (*internal_irq_mask)(struct irq_data *d);
--static void (*internal_irq_unmask)(struct irq_data *d);
-+static void (*internal_irq_unmask)(struct irq_data *d, const struct cpumask *m);
- static inline u32 get_ext_irq_perf_reg(int irq)
-@@ -51,6 +51,20 @@ static inline void handle_internal(int i
-               do_IRQ(intbit + IRQ_INTERNAL_BASE);
- }
-+static inline int enable_irq_for_cpu(int cpu, struct irq_data *d,
-+                                   const struct cpumask *m)
-+{
-+      bool enable = cpu_online(cpu);
-+
-+#ifdef CONFIG_SMP
-+      if (m)
-+              enable &= cpu_isset(cpu, *m);
-+      else if (irqd_affinity_was_set(d))
-+              enable &= cpu_isset(cpu, *d->affinity);
-+#endif
-+      return enable;
-+}
-+
- /*
-  * dispatch internal devices IRQ (uart, enet, watchdog, ...). do not
-  * prioritize any interrupt relatively to another. the static counter
-@@ -117,7 +131,8 @@ static void __internal_irq_mask_##width(
-       spin_unlock_irqrestore(&ipic_lock, flags);                      \
- }                                                                     \
-                                                                       \
--static void __internal_irq_unmask_##width(struct irq_data *d)         \
-+static void __internal_irq_unmask_##width(struct irq_data *d,         \
-+                                        const struct cpumask *m)      \
- {                                                                     \
-       u32 val;                                                        \
-       unsigned irq = d->irq - IRQ_INTERNAL_BASE;                      \
-@@ -132,7 +147,7 @@ static void __internal_irq_unmask_##widt
-                       break;                                          \
-                                                                       \
-               val = bcm_readl(irq_mask_addr[cpu] + reg * sizeof(u32));\
--              if (cpu_online(cpu))                                    \
-+              if (enable_irq_for_cpu(cpu, d, m))                      \
-                       val |= (1 << bit);                              \
-               else                                                    \
-                       val &= ~(1 << bit);                             \
-@@ -189,7 +204,7 @@ static void bcm63xx_internal_irq_mask(st
- static void bcm63xx_internal_irq_unmask(struct irq_data *d)
- {
--      internal_irq_unmask(d);
-+      internal_irq_unmask(d, NULL);
- }
- /*
-@@ -237,7 +252,8 @@ static void bcm63xx_external_irq_unmask(
-       spin_unlock_irqrestore(&epic_lock, flags);
-       if (is_ext_irq_cascaded)
--              internal_irq_unmask(irq_get_irq_data(irq + ext_irq_start));
-+              internal_irq_unmask(irq_get_irq_data(irq + ext_irq_start),
-+                                  NULL);
- }
- static void bcm63xx_external_irq_clear(struct irq_data *d)
-@@ -356,6 +372,18 @@ static int bcm63xx_external_irq_set_type
-       return IRQ_SET_MASK_OK_NOCOPY;
- }
-+#ifdef CONFIG_SMP
-+static int bcm63xx_internal_set_affinity(struct irq_data *data,
-+                                       const struct cpumask *dest,
-+                                       bool force)
-+{
-+      if (!irqd_irq_disabled(data))
-+              internal_irq_unmask(data, dest);
-+
-+      return 0;
-+}
-+#endif
-+
- static struct irq_chip bcm63xx_internal_irq_chip = {
-       .name           = "bcm63xx_ipic",
-       .irq_mask       = bcm63xx_internal_irq_mask,
-@@ -523,7 +551,13 @@ void __init arch_init_irq(void)
-       setup_irq(MIPS_CPU_IRQ_BASE + 2, &cpu_ip2_cascade_action);
- #ifdef CONFIG_SMP
--      if (is_ext_irq_cascaded)
-+      if (is_ext_irq_cascaded) {
-               setup_irq(MIPS_CPU_IRQ_BASE + 3, &cpu_ip3_cascade_action);
-+              bcm63xx_internal_irq_chip.irq_set_affinity =
-+                      bcm63xx_internal_set_affinity;
-+
-+              cpumask_clear(irq_default_affinity);
-+              cpumask_set_cpu(smp_processor_id(), irq_default_affinity);
-+      }
- #endif
- }
diff --git a/target/linux/brcm63xx/patches-3.14/030-MIPS-Always-use-IRQ-domains-for-CPU-IRQs.patch b/target/linux/brcm63xx/patches-3.14/030-MIPS-Always-use-IRQ-domains-for-CPU-IRQs.patch
deleted file mode 100644 (file)
index 21b69ab..0000000
+++ /dev/null
@@ -1,98 +0,0 @@
-From 0f84c305351c993e4307e1e8c128d44760314e31 Mon Sep 17 00:00:00 2001
-From: Andrew Bresticker <abrestic@chromium.org>
-Date: Thu, 18 Sep 2014 14:47:07 -0700
-Subject: [PATCH 1/3] MIPS: Always use IRQ domains for CPU IRQs
-
-Use an IRQ domain for the 8 CPU IRQs in both the DT and non-DT cases.
-
-Signed-off-by: Andrew Bresticker <abrestic@chromium.org>
-Reviewed-by: Qais Yousef <qais.yousef@imgtec.com>
-Tested-by: Qais Yousef <qais.yousef@imgtec.com>
-Cc: Thomas Gleixner <tglx@linutronix.de>
-Cc: Jason Cooper <jason@lakedaemon.net>
-Cc: Andrew Bresticker <abrestic@chromium.org>
-Cc: Jeffrey Deans <jeffrey.deans@imgtec.com>
-Cc: Markos Chandras <markos.chandras@imgtec.com>
-Cc: Paul Burton <paul.burton@imgtec.com>
-Cc: Qais Yousef <qais.yousef@imgtec.com>
-Cc: Jonas Gorski <jogo@openwrt.org>
-Cc: John Crispin <blogic@openwrt.org>
-Cc: David Daney <ddaney.cavm@gmail.com>
-Cc: linux-mips@linux-mips.org
-Cc: linux-kernel@vger.kernel.org
-Patchwork: https://patchwork.linux-mips.org/patch/7799/
-Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
----
- arch/mips/Kconfig          |    1 +
- arch/mips/kernel/irq_cpu.c |   36 +++++++++++-------------------------
- 2 files changed, 12 insertions(+), 25 deletions(-)
-
---- a/arch/mips/Kconfig
-+++ b/arch/mips/Kconfig
-@@ -1026,6 +1026,7 @@ config MIPS_HUGE_TLB_SUPPORT
- config IRQ_CPU
-       bool
-+      select IRQ_DOMAIN
- config IRQ_CPU_RM7K
-       bool
---- a/arch/mips/kernel/irq_cpu.c
-+++ b/arch/mips/kernel/irq_cpu.c
-@@ -98,28 +98,6 @@ static struct irq_chip mips_mt_cpu_irq_c
-       .irq_enable     = unmask_mips_irq,
- };
--void __init mips_cpu_irq_init(void)
--{
--      int irq_base = MIPS_CPU_IRQ_BASE;
--      int i;
--
--      /* Mask interrupts. */
--      clear_c0_status(ST0_IM);
--      clear_c0_cause(CAUSEF_IP);
--
--      /* Software interrupts are used for MT/CMT IPI */
--      for (i = irq_base; i < irq_base + 2; i++)
--              irq_set_chip_and_handler(i, cpu_has_mipsmt ?
--                                       &mips_mt_cpu_irq_controller :
--                                       &mips_cpu_irq_controller,
--                                       handle_percpu_irq);
--
--      for (i = irq_base + 2; i < irq_base + 8; i++)
--              irq_set_chip_and_handler(i, &mips_cpu_irq_controller,
--                                       handle_percpu_irq);
--}
--
--#ifdef CONFIG_IRQ_DOMAIN
- static int mips_cpu_intc_map(struct irq_domain *d, unsigned int irq,
-                            irq_hw_number_t hw)
- {
-@@ -142,8 +120,7 @@ static const struct irq_domain_ops mips_
-       .xlate = irq_domain_xlate_onecell,
- };
--int __init mips_cpu_intc_init(struct device_node *of_node,
--                            struct device_node *parent)
-+static void __init __mips_cpu_irq_init(struct device_node *of_node)
- {
-       struct irq_domain *domain;
-@@ -155,7 +132,16 @@ int __init mips_cpu_intc_init(struct dev
-                                      &mips_cpu_intc_irq_domain_ops, NULL);
-       if (!domain)
-               panic("Failed to add irqdomain for MIPS CPU");
-+}
-+void __init mips_cpu_irq_init(void)
-+{
-+      __mips_cpu_irq_init(NULL);
-+}
-+
-+int __init mips_cpu_intc_init(struct device_node *of_node,
-+                            struct device_node *parent)
-+{
-+      __mips_cpu_irq_init(of_node);
-       return 0;
- }
--#endif /* CONFIG_IRQ_DOMAIN */
diff --git a/target/linux/brcm63xx/patches-3.14/031-MIPS-Rename-mips_cpu_intc_init-mips_cpu_irq_of_init.patch b/target/linux/brcm63xx/patches-3.14/031-MIPS-Rename-mips_cpu_intc_init-mips_cpu_irq_of_init.patch
deleted file mode 100644 (file)
index 141644f..0000000
+++ /dev/null
@@ -1,89 +0,0 @@
-From afe8dc254711b72ba8144295f4a8fcc66d30572d Mon Sep 17 00:00:00 2001
-From: Andrew Bresticker <abrestic@chromium.org>
-Date: Thu, 18 Sep 2014 14:47:08 -0700
-Subject: [PATCH 2/3] MIPS: Rename mips_cpu_intc_init() ->
- mips_cpu_irq_of_init()
-
-mips_cpu_intc_init() is used for DT-based initialization of the CPU
-IRQ domain.  Give it a more appropriate name.
-
-Signed-off-by: Andrew Bresticker <abrestic@chromium.org>
-Reviewed-by: Qais Yousef <qais.yousef@imgtec.com>
-Tested-by: Qais Yousef <qais.yousef@imgtec.com>
-Cc: Thomas Gleixner <tglx@linutronix.de>
-Cc: Jason Cooper <jason@lakedaemon.net>
-Cc: Andrew Bresticker <abrestic@chromium.org>
-Cc: Jeffrey Deans <jeffrey.deans@imgtec.com>
-Cc: Markos Chandras <markos.chandras@imgtec.com>
-Cc: Paul Burton <paul.burton@imgtec.com>
-Cc: Qais Yousef <qais.yousef@imgtec.com>
-Cc: Jonas Gorski <jogo@openwrt.org>
-Cc: John Crispin <blogic@openwrt.org>
-Cc: David Daney <ddaney.cavm@gmail.com>
-Cc: linux-mips@linux-mips.org
-Cc: linux-kernel@vger.kernel.org
-Patchwork: https://patchwork.linux-mips.org/patch/7800/
-Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
----
- Documentation/devicetree/bindings/mips/cpu_irq.txt |    4 ++--
- arch/mips/include/asm/irq_cpu.h                    |    4 ++--
- arch/mips/kernel/irq_cpu.c                         |    4 ++--
- arch/mips/ralink/irq.c                             |    2 +-
- 4 files changed, 7 insertions(+), 7 deletions(-)
-
---- a/Documentation/devicetree/bindings/mips/cpu_irq.txt
-+++ b/Documentation/devicetree/bindings/mips/cpu_irq.txt
-@@ -1,6 +1,6 @@
- MIPS CPU interrupt controller
--On MIPS the mips_cpu_intc_init() helper can be used to initialize the 8 CPU
-+On MIPS the mips_cpu_irq_of_init() helper can be used to initialize the 8 CPU
- IRQs from a devicetree file and create a irq_domain for IRQ controller.
- With the irq_domain in place we can describe how the 8 IRQs are wired to the
-@@ -36,7 +36,7 @@ Example devicetree:
- Example platform irq.c:
- static struct of_device_id __initdata of_irq_ids[] = {
--      { .compatible = "mti,cpu-interrupt-controller", .data = mips_cpu_intc_init },
-+      { .compatible = "mti,cpu-interrupt-controller", .data = mips_cpu_irq_of_init },
-       { .compatible = "ralink,rt2880-intc", .data = intc_of_init },
-       {},
- };
---- a/arch/mips/include/asm/irq_cpu.h
-+++ b/arch/mips/include/asm/irq_cpu.h
-@@ -19,8 +19,8 @@ extern void rm9k_cpu_irq_init(void);
- #ifdef CONFIG_IRQ_DOMAIN
- struct device_node;
--extern int mips_cpu_intc_init(struct device_node *of_node,
--                            struct device_node *parent);
-+extern int mips_cpu_irq_of_init(struct device_node *of_node,
-+                              struct device_node *parent);
- #endif
- #endif /* _ASM_IRQ_CPU_H */
---- a/arch/mips/kernel/irq_cpu.c
-+++ b/arch/mips/kernel/irq_cpu.c
-@@ -139,8 +139,8 @@ void __init mips_cpu_irq_init(void)
-       __mips_cpu_irq_init(NULL);
- }
--int __init mips_cpu_intc_init(struct device_node *of_node,
--                            struct device_node *parent)
-+int __init mips_cpu_irq_of_init(struct device_node *of_node,
-+                              struct device_node *parent)
- {
-       __mips_cpu_irq_init(of_node);
-       return 0;
---- a/arch/mips/ralink/irq.c
-+++ b/arch/mips/ralink/irq.c
-@@ -173,7 +173,7 @@ static int __init intc_of_init(struct de
- }
- static struct of_device_id __initdata of_irq_ids[] = {
--      { .compatible = "mti,cpu-interrupt-controller", .data = mips_cpu_intc_init },
-+      { .compatible = "mti,cpu-interrupt-controller", .data = mips_cpu_irq_of_init },
-       { .compatible = "ralink,rt2880-intc", .data = intc_of_init },
-       {},
- };
diff --git a/target/linux/brcm63xx/patches-3.14/032-MIPS-Provide-a-generic-plat_irq_dispatch.patch b/target/linux/brcm63xx/patches-3.14/032-MIPS-Provide-a-generic-plat_irq_dispatch.patch
deleted file mode 100644 (file)
index 8f5bd31..0000000
+++ /dev/null
@@ -1,58 +0,0 @@
-From 85f7cdacbb81db8c4cc8e474837eab1f0e4ff77b Mon Sep 17 00:00:00 2001
-From: Andrew Bresticker <abrestic@chromium.org>
-Date: Thu, 18 Sep 2014 14:47:09 -0700
-Subject: [PATCH 3/3] MIPS: Provide a generic plat_irq_dispatch
-
-For platforms which boot with device-tree or have correctly chained
-all external interrupt controllers, a generic plat_irq_dispatch() can
-be used.  Implement a plat_irq_dispatch() which simply handles all the
-pending interrupts as reported by C0_Cause.
-
-Signed-off-by: Andrew Bresticker <abrestic@chromium.org>
-Reviewed-by: Qais Yousef <qais.yousef@imgtec.com>
-Tested-by: Qais Yousef <qais.yousef@imgtec.com>
-Cc: Thomas Gleixner <tglx@linutronix.de>
-Cc: Jason Cooper <jason@lakedaemon.net>
-Cc: Andrew Bresticker <abrestic@chromium.org>
-Cc: Jeffrey Deans <jeffrey.deans@imgtec.com>
-Cc: Markos Chandras <markos.chandras@imgtec.com>
-Cc: Paul Burton <paul.burton@imgtec.com>
-Cc: Qais Yousef <qais.yousef@imgtec.com>
-Cc: Jonas Gorski <jogo@openwrt.org>
-Cc: John Crispin <blogic@openwrt.org>
-Cc: David Daney <ddaney.cavm@gmail.com>
-Cc: linux-mips@linux-mips.org
-Cc: linux-kernel@vger.kernel.org
-Patchwork: https://patchwork.linux-mips.org/patch/7801/
-Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
----
- arch/mips/kernel/irq_cpu.c |   18 ++++++++++++++++++
- 1 file changed, 18 insertions(+)
-
---- a/arch/mips/kernel/irq_cpu.c
-+++ b/arch/mips/kernel/irq_cpu.c
-@@ -98,6 +98,24 @@ static struct irq_chip mips_mt_cpu_irq_c
-       .irq_enable     = unmask_mips_irq,
- };
-+asmlinkage void __weak plat_irq_dispatch(void)
-+{
-+      unsigned long pending = read_c0_cause() & read_c0_status() & ST0_IM;
-+      int irq;
-+
-+      if (!pending) {
-+              spurious_interrupt();
-+              return;
-+      }
-+
-+      pending >>= CAUSEB_IP;
-+      while (pending) {
-+              irq = fls(pending) - 1;
-+              do_IRQ(MIPS_CPU_IRQ_BASE + irq);
-+              pending &= ~BIT(irq);
-+      }
-+}
-+
- static int mips_cpu_intc_map(struct irq_domain *d, unsigned int irq,
-                            irq_hw_number_t hw)
- {
diff --git a/target/linux/brcm63xx/patches-3.14/100-MIPS-BCM63XX-add-USB-host-clock-enable-delay.patch b/target/linux/brcm63xx/patches-3.14/100-MIPS-BCM63XX-add-USB-host-clock-enable-delay.patch
deleted file mode 100644 (file)
index 63d385b..0000000
+++ /dev/null
@@ -1,28 +0,0 @@
-From 80a2f983e9f44dbc3e01ae31c62d877846a7f791 Mon Sep 17 00:00:00 2001
-From: Florian Fainelli <florian@openwrt.org>
-Date: Mon, 28 Jan 2013 20:06:19 +0100
-Subject: [PATCH 01/11] MIPS: BCM63XX: add USB host clock enable delay
-
-Knowledge of the clock setup delay should remain at the clock level (so
-it can be clock specific and CPU specific). Add the 100 milliseconds
-required clock delay for the USB host clock when it gets enabled.
-
-Signed-off-by: Florian Fainelli <florian@openwrt.org>
----
- arch/mips/bcm63xx/clk.c |    5 +++++
- 1 file changed, 5 insertions(+)
-
---- a/arch/mips/bcm63xx/clk.c
-+++ b/arch/mips/bcm63xx/clk.c
-@@ -177,6 +177,11 @@ static void usbh_set(struct clk *clk, in
-               bcm_hwclock_set(CKCTL_6362_USBH_EN, enable);
-       else if (BCMCPU_IS_6368())
-               bcm_hwclock_set(CKCTL_6368_USBH_EN, enable);
-+      else
-+              return;
-+
-+      if (enable)
-+              msleep(100);
- }
- static struct clk clk_usbh = {
diff --git a/target/linux/brcm63xx/patches-3.14/101-MIPS-BCM63XX-add-USB-device-clock-enable-delay-to-cl.patch b/target/linux/brcm63xx/patches-3.14/101-MIPS-BCM63XX-add-USB-device-clock-enable-delay-to-cl.patch
deleted file mode 100644 (file)
index 031dab4..0000000
+++ /dev/null
@@ -1,41 +0,0 @@
-From 8e9bf528a122741f0171b89c297b63041116d704 Mon Sep 17 00:00:00 2001
-From: Florian Fainelli <florian@openwrt.org>
-Date: Mon, 28 Jan 2013 20:06:20 +0100
-Subject: [PATCH 02/11] MIPS: BCM63XX: add USB device clock enable delay to
- clock code
-
-This patch adds the required 10 micro seconds delay to the USB device
-clock enable operation. Put this where the correct clock knowledege is,
-which is in the clock code, and remove this delay from the bcm63xx_udc
-gadget driver where it was before.
-
-Signed-off-by: Florian Fainelli <florian@openwrt.org>
----
- arch/mips/bcm63xx/clk.c          |    5 +++++
- drivers/usb/gadget/bcm63xx_udc.c |    1 -
- 2 files changed, 5 insertions(+), 1 deletion(-)
-
---- a/arch/mips/bcm63xx/clk.c
-+++ b/arch/mips/bcm63xx/clk.c
-@@ -199,6 +199,11 @@ static void usbd_set(struct clk *clk, in
-               bcm_hwclock_set(CKCTL_6362_USBD_EN, enable);
-       else if (BCMCPU_IS_6368())
-               bcm_hwclock_set(CKCTL_6368_USBD_EN, enable);
-+      else
-+              return;
-+
-+      if (enable)
-+              udelay(10);
- }
- static struct clk clk_usbd = {
---- a/drivers/usb/gadget/bcm63xx_udc.c
-+++ b/drivers/usb/gadget/bcm63xx_udc.c
-@@ -391,7 +391,6 @@ static inline void set_clocks(struct bcm
-       if (is_enabled) {
-               clk_enable(udc->usbh_clk);
-               clk_enable(udc->usbd_clk);
--              udelay(10);
-       } else {
-               clk_disable(udc->usbd_clk);
-               clk_disable(udc->usbh_clk);
diff --git a/target/linux/brcm63xx/patches-3.14/101-MIPS-BCM63XX-sync-mips-counter-during-cpu-bringup.patch b/target/linux/brcm63xx/patches-3.14/101-MIPS-BCM63XX-sync-mips-counter-during-cpu-bringup.patch
deleted file mode 100644 (file)
index f303c61..0000000
+++ /dev/null
@@ -1,27 +0,0 @@
-From 23c21090f49a64b532755542a71e9aa3e4fc84d9 Mon Sep 17 00:00:00 2001
-From: Jonas Gorski <jogo@openwrt.org>
-Date: Sat, 5 Apr 2014 20:07:25 +0200
-Subject: [PATCH] MIPS: BCM63XX: sync mips counter during cpu bringup
-
-We are using the mips counters as the clock source, so we need to ensure
-they are synced, else e.g. gettimeofday will return different values
-depending on which core it was run.
-
-Observed difference was about 8 seconds, causing ~8 seconds ping or time
-running backwards for some programs.
-
-Signed-off-by: Jonas Gorski <jogo@openwrt.org>
----
- arch/mips/Kconfig | 1 +
- 1 file changed, 1 insertion(+)
-
---- a/arch/mips/Kconfig
-+++ b/arch/mips/Kconfig
-@@ -132,6 +132,7 @@ config BCM63XX
-       select BOOT_RAW
-       select CEVT_R4K
-       select CSRC_R4K
-+      select SYNC_R4K
-       select DMA_NONCOHERENT
-       select IRQ_CPU
-       select SYS_SUPPORTS_32BIT_KERNEL
diff --git a/target/linux/brcm63xx/patches-3.14/102-MIPS-BCM63XX-move-code-touching-the-USB-private-regi.patch b/target/linux/brcm63xx/patches-3.14/102-MIPS-BCM63XX-move-code-touching-the-USB-private-regi.patch
deleted file mode 100644 (file)
index f98ae5b..0000000
+++ /dev/null
@@ -1,151 +0,0 @@
-From ac9b0b574d54be28b300bf99ffe092a2c589484f Mon Sep 17 00:00:00 2001
-From: Florian Fainelli <florian@openwrt.org>
-Date: Mon, 28 Jan 2013 20:06:21 +0100
-Subject: [PATCH 03/11] MIPS: BCM63XX: move code touching the USB private
- register
-
-This patch moves the code touching the USB private register in the
-bcm63xx USB gadget driver to arch/mips/bcm63xx/usb-common.c in
-preparation for adding support for OHCI and EHCI host controllers which
-will also touch the USB private register.
-
-Signed-off-by: Florian Fainelli <florian@openwrt.org>
----
- arch/mips/bcm63xx/Makefile                         |    2 +-
- arch/mips/bcm63xx/usb-common.c                     |   53 ++++++++++++++++++++
- .../include/asm/mach-bcm63xx/bcm63xx_usb_priv.h    |    9 ++++
- drivers/usb/gadget/bcm63xx_udc.c                   |   27 ++--------
- 4 files changed, 67 insertions(+), 24 deletions(-)
- create mode 100644 arch/mips/bcm63xx/usb-common.c
- create mode 100644 arch/mips/include/asm/mach-bcm63xx/bcm63xx_usb_priv.h
-
---- a/arch/mips/bcm63xx/Makefile
-+++ b/arch/mips/bcm63xx/Makefile
-@@ -1,7 +1,7 @@
- obj-y         += clk.o cpu.o cs.o gpio.o irq.o nvram.o prom.o reset.o \
-                  setup.o timer.o dev-dsp.o dev-enet.o dev-flash.o \
-                  dev-pcmcia.o dev-rng.o dev-spi.o dev-hsspi.o dev-uart.o \
--                 dev-wdt.o dev-usb-usbd.o
-+                 dev-wdt.o dev-usb-usbd.o usb-common.o
- obj-$(CONFIG_EARLY_PRINTK)    += early_printk.o
- obj-y         += boards/
---- /dev/null
-+++ b/arch/mips/bcm63xx/usb-common.c
-@@ -0,0 +1,53 @@
-+/*
-+ * Broadcom BCM63xx common USB device configuration code
-+ *
-+ * This file is subject to the terms and conditions of the GNU General Public
-+ * License.  See the file "COPYING" in the main directory of this archive
-+ * for more details.
-+ *
-+ * Copyright (C) 2012 Kevin Cernekee <cernekee@gmail.com>
-+ * Copyright (C) 2012 Broadcom Corporation
-+ *
-+ */
-+#include <linux/export.h>
-+
-+#include <bcm63xx_cpu.h>
-+#include <bcm63xx_regs.h>
-+#include <bcm63xx_io.h>
-+#include <bcm63xx_usb_priv.h>
-+
-+void bcm63xx_usb_priv_select_phy_mode(u32 portmask, bool is_device)
-+{
-+      u32 val;
-+
-+      val = bcm_rset_readl(RSET_USBH_PRIV, USBH_PRIV_UTMI_CTL_6368_REG);
-+      if (is_device) {
-+              val |= (portmask << USBH_PRIV_UTMI_CTL_HOSTB_SHIFT);
-+              val |= (portmask << USBH_PRIV_UTMI_CTL_NODRIV_SHIFT);
-+      } else {
-+              val &= ~(portmask << USBH_PRIV_UTMI_CTL_HOSTB_SHIFT);
-+              val &= ~(portmask << USBH_PRIV_UTMI_CTL_NODRIV_SHIFT);
-+      }
-+      bcm_rset_writel(RSET_USBH_PRIV, val, USBH_PRIV_UTMI_CTL_6368_REG);
-+
-+      val = bcm_rset_readl(RSET_USBH_PRIV, USBH_PRIV_SWAP_6368_REG);
-+      if (is_device)
-+              val |= USBH_PRIV_SWAP_USBD_MASK;
-+      else
-+              val &= ~USBH_PRIV_SWAP_USBD_MASK;
-+      bcm_rset_writel(RSET_USBH_PRIV, val, USBH_PRIV_SWAP_6368_REG);
-+}
-+EXPORT_SYMBOL(bcm63xx_usb_priv_select_phy_mode);
-+
-+void bcm63xx_usb_priv_select_pullup(u32 portmask, bool is_on)
-+{
-+      u32 val;
-+
-+      val = bcm_rset_readl(RSET_USBH_PRIV, USBH_PRIV_UTMI_CTL_6368_REG);
-+      if (is_on)
-+              val &= ~(portmask << USBH_PRIV_UTMI_CTL_NODRIV_SHIFT);
-+      else
-+              val |= (portmask << USBH_PRIV_UTMI_CTL_NODRIV_SHIFT);
-+      bcm_rset_writel(RSET_USBH_PRIV, val, USBH_PRIV_UTMI_CTL_6368_REG);
-+}
-+EXPORT_SYMBOL(bcm63xx_usb_priv_select_pullup);
---- /dev/null
-+++ b/arch/mips/include/asm/mach-bcm63xx/bcm63xx_usb_priv.h
-@@ -0,0 +1,9 @@
-+#ifndef BCM63XX_USB_PRIV_H_
-+#define BCM63XX_USB_PRIV_H_
-+
-+#include <linux/types.h>
-+
-+void bcm63xx_usb_priv_select_phy_mode(u32 portmask, bool is_device);
-+void bcm63xx_usb_priv_select_pullup(u32 portmask, bool is_on);
-+
-+#endif /* BCM63XX_USB_PRIV_H_ */
---- a/drivers/usb/gadget/bcm63xx_udc.c
-+++ b/drivers/usb/gadget/bcm63xx_udc.c
-@@ -40,6 +40,7 @@
- #include <bcm63xx_dev_usb_usbd.h>
- #include <bcm63xx_io.h>
- #include <bcm63xx_regs.h>
-+#include <bcm63xx_usb_priv.h>
- #define DRV_MODULE_NAME               "bcm63xx_udc"
-@@ -868,22 +869,7 @@ static void bcm63xx_select_phy_mode(stru
-               bcm_gpio_writel(val, GPIO_PINMUX_OTHR_REG);
-       }
--      val = bcm_rset_readl(RSET_USBH_PRIV, USBH_PRIV_UTMI_CTL_6368_REG);
--      if (is_device) {
--              val |= (portmask << USBH_PRIV_UTMI_CTL_HOSTB_SHIFT);
--              val |= (portmask << USBH_PRIV_UTMI_CTL_NODRIV_SHIFT);
--      } else {
--              val &= ~(portmask << USBH_PRIV_UTMI_CTL_HOSTB_SHIFT);
--              val &= ~(portmask << USBH_PRIV_UTMI_CTL_NODRIV_SHIFT);
--      }
--      bcm_rset_writel(RSET_USBH_PRIV, val, USBH_PRIV_UTMI_CTL_6368_REG);
--
--      val = bcm_rset_readl(RSET_USBH_PRIV, USBH_PRIV_SWAP_6368_REG);
--      if (is_device)
--              val |= USBH_PRIV_SWAP_USBD_MASK;
--      else
--              val &= ~USBH_PRIV_SWAP_USBD_MASK;
--      bcm_rset_writel(RSET_USBH_PRIV, val, USBH_PRIV_SWAP_6368_REG);
-+      bcm63xx_usb_priv_select_phy_mode(portmask, is_device);
- }
- /**
-@@ -897,14 +883,9 @@ static void bcm63xx_select_phy_mode(stru
-  */
- static void bcm63xx_select_pullup(struct bcm63xx_udc *udc, bool is_on)
- {
--      u32 val, portmask = BIT(udc->pd->port_no);
-+      u32 portmask = BIT(udc->pd->port_no);
--      val = bcm_rset_readl(RSET_USBH_PRIV, USBH_PRIV_UTMI_CTL_6368_REG);
--      if (is_on)
--              val &= ~(portmask << USBH_PRIV_UTMI_CTL_NODRIV_SHIFT);
--      else
--              val |= (portmask << USBH_PRIV_UTMI_CTL_NODRIV_SHIFT);
--      bcm_rset_writel(RSET_USBH_PRIV, val, USBH_PRIV_UTMI_CTL_6368_REG);
-+      bcm63xx_usb_priv_select_pullup(portmask, is_on);
- }
- /**
diff --git a/target/linux/brcm63xx/patches-3.14/103-MIPS-BCM63XX-add-OHCI-EHCI-configuration-bits-to-com.patch b/target/linux/brcm63xx/patches-3.14/103-MIPS-BCM63XX-add-OHCI-EHCI-configuration-bits-to-com.patch
deleted file mode 100644 (file)
index 40bbe08..0000000
+++ /dev/null
@@ -1,169 +0,0 @@
-From 28758a9da77954ed323f86123ef448c6a563c037 Mon Sep 17 00:00:00 2001
-From: Florian Fainelli <florian@openwrt.org>
-Date: Mon, 28 Jan 2013 20:06:22 +0100
-Subject: [PATCH 04/11] MIPS: BCM63XX: add OHCI/EHCI configuration bits to
- common USB code
-
-This patch updates the common USB code touching the USB private
-registers with the specific bits to properly enable OHCI and EHCI
-controllers on BCM63xx SoCs. As a result we now need to protect access
-to Read Modify Write sequences using a spinlock because we cannot
-guarantee that any of the exposed helper will not be called
-concurrently.
-
-Signed-off-by: Maxime Bizon <mbizon@freebox.fr>
-Signed-off-by: Florian Fainelli <florian@openwrt.org>
----
- arch/mips/bcm63xx/usb-common.c                     |   97 ++++++++++++++++++++
- .../include/asm/mach-bcm63xx/bcm63xx_usb_priv.h    |    2 +
- 2 files changed, 99 insertions(+)
-
---- a/arch/mips/bcm63xx/usb-common.c
-+++ b/arch/mips/bcm63xx/usb-common.c
-@@ -5,10 +5,12 @@
-  * License.  See the file "COPYING" in the main directory of this archive
-  * for more details.
-  *
-+ * Copyright (C) 2008 Maxime Bizon <mbizon@freebox.fr>
-  * Copyright (C) 2012 Kevin Cernekee <cernekee@gmail.com>
-  * Copyright (C) 2012 Broadcom Corporation
-  *
-  */
-+#include <linux/spinlock.h>
- #include <linux/export.h>
- #include <bcm63xx_cpu.h>
-@@ -16,9 +18,14 @@
- #include <bcm63xx_io.h>
- #include <bcm63xx_usb_priv.h>
-+static DEFINE_SPINLOCK(usb_priv_reg_lock);
-+
- void bcm63xx_usb_priv_select_phy_mode(u32 portmask, bool is_device)
- {
-       u32 val;
-+      unsigned long flags;
-+
-+      spin_lock_irqsave(&usb_priv_reg_lock, flags);
-       val = bcm_rset_readl(RSET_USBH_PRIV, USBH_PRIV_UTMI_CTL_6368_REG);
-       if (is_device) {
-@@ -36,12 +43,17 @@ void bcm63xx_usb_priv_select_phy_mode(u3
-       else
-               val &= ~USBH_PRIV_SWAP_USBD_MASK;
-       bcm_rset_writel(RSET_USBH_PRIV, val, USBH_PRIV_SWAP_6368_REG);
-+
-+      spin_unlock_irqrestore(&usb_priv_reg_lock, flags);
- }
- EXPORT_SYMBOL(bcm63xx_usb_priv_select_phy_mode);
- void bcm63xx_usb_priv_select_pullup(u32 portmask, bool is_on)
- {
-       u32 val;
-+      unsigned long flags;
-+
-+      spin_lock_irqsave(&usb_priv_reg_lock, flags);
-       val = bcm_rset_readl(RSET_USBH_PRIV, USBH_PRIV_UTMI_CTL_6368_REG);
-       if (is_on)
-@@ -49,5 +61,90 @@ void bcm63xx_usb_priv_select_pullup(u32
-       else
-               val |= (portmask << USBH_PRIV_UTMI_CTL_NODRIV_SHIFT);
-       bcm_rset_writel(RSET_USBH_PRIV, val, USBH_PRIV_UTMI_CTL_6368_REG);
-+
-+      spin_unlock_irqrestore(&usb_priv_reg_lock, flags);
- }
- EXPORT_SYMBOL(bcm63xx_usb_priv_select_pullup);
-+
-+/* The following array represents the meaning of the DESC/DATA
-+ * endian swapping with respect to the CPU configured endianness
-+ *
-+ * DATA       ENDN    mmio    descriptor
-+ * 0  0       BE      invalid
-+ * 0  1       BE      LE
-+ * 1  0       BE      BE
-+ * 1  1       BE      invalid
-+ *
-+ * Since BCM63XX SoCs are configured to be in big-endian mode
-+ * we want configuration at line 3.
-+ */
-+void bcm63xx_usb_priv_ohci_cfg_set(void)
-+{
-+      u32 reg;
-+      unsigned long flags;
-+
-+      spin_lock_irqsave(&usb_priv_reg_lock, flags);
-+
-+      if (BCMCPU_IS_6348())
-+              bcm_rset_writel(RSET_OHCI_PRIV, 0, OHCI_PRIV_REG);
-+      else if (BCMCPU_IS_6358()) {
-+              reg = bcm_rset_readl(RSET_USBH_PRIV, USBH_PRIV_SWAP_6358_REG);
-+              reg &= ~USBH_PRIV_SWAP_OHCI_ENDN_MASK;
-+              reg |= USBH_PRIV_SWAP_OHCI_DATA_MASK;
-+              bcm_rset_writel(RSET_USBH_PRIV, reg, USBH_PRIV_SWAP_6358_REG);
-+              /*
-+               * The magic value comes for the original vendor BSP
-+               * and is needed for USB to work. Datasheet does not
-+               * help, so the magic value is used as-is.
-+               */
-+              bcm_rset_writel(RSET_USBH_PRIV, 0x1c0020,
-+                              USBH_PRIV_TEST_6358_REG);
-+
-+      } else if (BCMCPU_IS_6328() || BCMCPU_IS_6362() || BCMCPU_IS_6368()) {
-+              reg = bcm_rset_readl(RSET_USBH_PRIV, USBH_PRIV_SWAP_6368_REG);
-+              reg &= ~USBH_PRIV_SWAP_OHCI_ENDN_MASK;
-+              reg |= USBH_PRIV_SWAP_OHCI_DATA_MASK;
-+              bcm_rset_writel(RSET_USBH_PRIV, reg, USBH_PRIV_SWAP_6368_REG);
-+
-+              reg = bcm_rset_readl(RSET_USBH_PRIV, USBH_PRIV_SETUP_6368_REG);
-+              reg |= USBH_PRIV_SETUP_IOC_MASK;
-+              bcm_rset_writel(RSET_USBH_PRIV, reg, USBH_PRIV_SETUP_6368_REG);
-+      }
-+
-+      spin_unlock_irqrestore(&usb_priv_reg_lock, flags);
-+}
-+
-+void bcm63xx_usb_priv_ehci_cfg_set(void)
-+{
-+      u32 reg;
-+      unsigned long flags;
-+
-+      spin_lock_irqsave(&usb_priv_reg_lock, flags);
-+
-+      if (BCMCPU_IS_6358()) {
-+              reg = bcm_rset_readl(RSET_USBH_PRIV, USBH_PRIV_SWAP_6358_REG);
-+              reg &= ~USBH_PRIV_SWAP_EHCI_ENDN_MASK;
-+              reg |= USBH_PRIV_SWAP_EHCI_DATA_MASK;
-+              bcm_rset_writel(RSET_USBH_PRIV, reg, USBH_PRIV_SWAP_6358_REG);
-+
-+              /*
-+               * The magic value comes for the original vendor BSP
-+               * and is needed for USB to work. Datasheet does not
-+               * help, so the magic value is used as-is.
-+               */
-+              bcm_rset_writel(RSET_USBH_PRIV, 0x1c0020,
-+                              USBH_PRIV_TEST_6358_REG);
-+
-+      } else if (BCMCPU_IS_6328() || BCMCPU_IS_6362() || BCMCPU_IS_6368()) {
-+              reg = bcm_rset_readl(RSET_USBH_PRIV, USBH_PRIV_SWAP_6368_REG);
-+              reg &= ~USBH_PRIV_SWAP_EHCI_ENDN_MASK;
-+              reg |= USBH_PRIV_SWAP_EHCI_DATA_MASK;
-+              bcm_rset_writel(RSET_USBH_PRIV, reg, USBH_PRIV_SWAP_6368_REG);
-+
-+              reg = bcm_rset_readl(RSET_USBH_PRIV, USBH_PRIV_SETUP_6368_REG);
-+              reg |= USBH_PRIV_SETUP_IOC_MASK;
-+              bcm_rset_writel(RSET_USBH_PRIV, reg, USBH_PRIV_SETUP_6368_REG);
-+      }
-+
-+      spin_unlock_irqrestore(&usb_priv_reg_lock, flags);
-+}
---- a/arch/mips/include/asm/mach-bcm63xx/bcm63xx_usb_priv.h
-+++ b/arch/mips/include/asm/mach-bcm63xx/bcm63xx_usb_priv.h
-@@ -5,5 +5,7 @@
- void bcm63xx_usb_priv_select_phy_mode(u32 portmask, bool is_device);
- void bcm63xx_usb_priv_select_pullup(u32 portmask, bool is_on);
-+void bcm63xx_usb_priv_ohci_cfg_set(void);
-+void bcm63xx_usb_priv_ehci_cfg_set(void);
- #endif /* BCM63XX_USB_PRIV_H_ */
diff --git a/target/linux/brcm63xx/patches-3.14/104-MIPS-BCM63XX-introduce-BCM63XX_OHCI-configuration-sy.patch b/target/linux/brcm63xx/patches-3.14/104-MIPS-BCM63XX-introduce-BCM63XX_OHCI-configuration-sy.patch
deleted file mode 100644 (file)
index 768dcca..0000000
+++ /dev/null
@@ -1,62 +0,0 @@
-From 94ec618bd1a6b07fafbbfc9bcc54e7f9360ff9a0 Mon Sep 17 00:00:00 2001
-From: Florian Fainelli <florian@openwrt.org>
-Date: Mon, 28 Jan 2013 20:06:23 +0100
-Subject: [PATCH 05/11] MIPS: BCM63XX: introduce BCM63XX_OHCI configuration
- symbol
-
-This configuration symbol can be used by CPUs supporting the on-chip
-OHCI controller, and ensures that all relevant OHCI-related
-configuration options are correctly selected. So far, OHCI support is
-available for the 6328, 6348, 6358 and 6358 SoCs.
-
-Signed-off-by: Florian Fainelli <florian@openwrt.org>
----
- arch/mips/bcm63xx/Kconfig |   15 ++++++++++-----
- 1 file changed, 10 insertions(+), 5 deletions(-)
-
---- a/arch/mips/bcm63xx/Kconfig
-+++ b/arch/mips/bcm63xx/Kconfig
-@@ -6,10 +6,17 @@ config BCM63XX_CPU_3368
-       select SYS_HAS_CPU_BMIPS4350
-       select HW_HAS_PCI
-+config BCM63XX_OHCI
-+      bool
-+      select USB_ARCH_HAS_OHCI
-+      select USB_OHCI_BIG_ENDIAN_DESC if USB_OHCI_HCD
-+      select USB_OHCI_BIG_ENDIAN_MMIO if USB_OHCI_HCD
-+
- config BCM63XX_CPU_6328
-       bool "support 6328 CPU"
-       select SYS_HAS_CPU_BMIPS4350
-       select HW_HAS_PCI
-+      select BCM63XX_OHCI
- config BCM63XX_CPU_6338
-       bool "support 6338 CPU"
-@@ -24,21 +31,25 @@ config BCM63XX_CPU_6348
-       bool "support 6348 CPU"
-       select SYS_HAS_CPU_BMIPS32_3300
-       select HW_HAS_PCI
-+      select BCM63XX_OHCI
- config BCM63XX_CPU_6358
-       bool "support 6358 CPU"
-       select SYS_HAS_CPU_BMIPS4350
-       select HW_HAS_PCI
-+      select BCM63XX_OHCI
- config BCM63XX_CPU_6362
-       bool "support 6362 CPU"
-       select SYS_HAS_CPU_BMIPS4350
-       select HW_HAS_PCI
-+      select BCM63XX_OHCI
- config BCM63XX_CPU_6368
-       bool "support 6368 CPU"
-       select SYS_HAS_CPU_BMIPS4350
-       select HW_HAS_PCI
-+      select BCM63XX_OHCI
- endmenu
- source "arch/mips/bcm63xx/boards/Kconfig"
diff --git a/target/linux/brcm63xx/patches-3.14/105-MIPS-BCM63XX-add-support-for-the-on-chip-OHCI-contro.patch b/target/linux/brcm63xx/patches-3.14/105-MIPS-BCM63XX-add-support-for-the-on-chip-OHCI-contro.patch
deleted file mode 100644 (file)
index 111d481..0000000
+++ /dev/null
@@ -1,138 +0,0 @@
-From 30d22baef255c99a12c4858ce4ab0d45f0d8c9ae Mon Sep 17 00:00:00 2001
-From: Florian Fainelli <florian@openwrt.org>
-Date: Mon, 28 Jan 2013 20:06:24 +0100
-Subject: [PATCH 06/11] MIPS: BCM63XX: add support for the on-chip OHCI
- controller
-
-Broadcom BCM63XX SoCs include an on-chip OHCI controller which can be
-driven by the ohci-platform generic driver by using specific power
-on/off/suspend callback to manage clocks and hardware specific
-configuration.
-
-Signed-off-by: Maxime Bizon <mbizon@freebox.fr>
-Signed-off-by: Florian Fainelli <florian@openwrt.org>
----
- arch/mips/bcm63xx/Makefile                         |    2 +-
- arch/mips/bcm63xx/dev-usb-ohci.c                   |   94 ++++++++++++++++++++
- .../asm/mach-bcm63xx/bcm63xx_dev_usb_ohci.h        |    6 ++
- 3 files changed, 101 insertions(+), 1 deletion(-)
- create mode 100644 arch/mips/bcm63xx/dev-usb-ohci.c
- create mode 100644 arch/mips/include/asm/mach-bcm63xx/bcm63xx_dev_usb_ohci.h
-
---- a/arch/mips/bcm63xx/Makefile
-+++ b/arch/mips/bcm63xx/Makefile
-@@ -1,7 +1,7 @@
- obj-y         += clk.o cpu.o cs.o gpio.o irq.o nvram.o prom.o reset.o \
-                  setup.o timer.o dev-dsp.o dev-enet.o dev-flash.o \
-                  dev-pcmcia.o dev-rng.o dev-spi.o dev-hsspi.o dev-uart.o \
--                 dev-wdt.o dev-usb-usbd.o usb-common.o
-+                 dev-wdt.o dev-usb-ohci.o dev-usb-usbd.o usb-common.o
- obj-$(CONFIG_EARLY_PRINTK)    += early_printk.o
- obj-y         += boards/
---- /dev/null
-+++ b/arch/mips/bcm63xx/dev-usb-ohci.c
-@@ -0,0 +1,94 @@
-+/*
-+ * This file is subject to the terms and conditions of the GNU General Public
-+ * License.  See the file "COPYING" in the main directory of this archive
-+ * for more details.
-+ *
-+ * Copyright (C) 2008 Maxime Bizon <mbizon@freebox.fr>
-+ * Copyright (C) 2013 Florian Fainelli <florian@openwrt.org>
-+ */
-+
-+#include <linux/init.h>
-+#include <linux/kernel.h>
-+#include <linux/platform_device.h>
-+#include <linux/usb/ohci_pdriver.h>
-+#include <linux/dma-mapping.h>
-+#include <linux/clk.h>
-+#include <linux/delay.h>
-+
-+#include <bcm63xx_cpu.h>
-+#include <bcm63xx_regs.h>
-+#include <bcm63xx_io.h>
-+#include <bcm63xx_usb_priv.h>
-+#include <bcm63xx_dev_usb_ohci.h>
-+
-+static struct resource ohci_resources[] = {
-+      {
-+              .start          = -1, /* filled at runtime */
-+              .end            = -1, /* filled at runtime */
-+              .flags          = IORESOURCE_MEM,
-+      },
-+      {
-+              .start          = -1, /* filled at runtime */
-+              .flags          = IORESOURCE_IRQ,
-+      },
-+};
-+
-+static u64 ohci_dmamask = DMA_BIT_MASK(32);
-+
-+static struct clk *usb_host_clock;
-+
-+static int bcm63xx_ohci_power_on(struct platform_device *pdev)
-+{
-+      usb_host_clock = clk_get(&pdev->dev, "usbh");
-+      if (IS_ERR_OR_NULL(usb_host_clock))
-+              return -ENODEV;
-+
-+      clk_prepare_enable(usb_host_clock);
-+
-+      bcm63xx_usb_priv_ohci_cfg_set();
-+
-+      return 0;
-+}
-+
-+static void bcm63xx_ohci_power_off(struct platform_device *pdev)
-+{
-+      if (!IS_ERR_OR_NULL(usb_host_clock)) {
-+              clk_disable_unprepare(usb_host_clock);
-+              clk_put(usb_host_clock);
-+      }
-+}
-+
-+static struct usb_ohci_pdata bcm63xx_ohci_pdata = {
-+      .big_endian_desc        = 1,
-+      .big_endian_mmio        = 1,
-+      .no_big_frame_no        = 1,
-+      .num_ports              = 1,
-+      .power_on               = bcm63xx_ohci_power_on,
-+      .power_off              = bcm63xx_ohci_power_off,
-+      .power_suspend          = bcm63xx_ohci_power_off,
-+};
-+
-+static struct platform_device bcm63xx_ohci_device = {
-+      .name           = "ohci-platform",
-+      .id             = -1,
-+      .num_resources  = ARRAY_SIZE(ohci_resources),
-+      .resource       = ohci_resources,
-+      .dev            = {
-+              .platform_data          = &bcm63xx_ohci_pdata,
-+              .dma_mask               = &ohci_dmamask,
-+              .coherent_dma_mask      = DMA_BIT_MASK(32),
-+      },
-+};
-+
-+int __init bcm63xx_ohci_register(void)
-+{
-+      if (BCMCPU_IS_6345() || BCMCPU_IS_6338())
-+              return -ENODEV;
-+
-+      ohci_resources[0].start = bcm63xx_regset_address(RSET_OHCI0);
-+      ohci_resources[0].end = ohci_resources[0].start;
-+      ohci_resources[0].end += RSET_OHCI_SIZE - 1;
-+      ohci_resources[1].start = bcm63xx_get_irq_number(IRQ_OHCI0);
-+
-+      return platform_device_register(&bcm63xx_ohci_device);
-+}
---- /dev/null
-+++ b/arch/mips/include/asm/mach-bcm63xx/bcm63xx_dev_usb_ohci.h
-@@ -0,0 +1,6 @@
-+#ifndef BCM63XX_DEV_USB_OHCI_H_
-+#define BCM63XX_DEV_USB_OHCI_H_
-+
-+int bcm63xx_ohci_register(void);
-+
-+#endif /* BCM63XX_DEV_USB_OHCI_H_ */
diff --git a/target/linux/brcm63xx/patches-3.14/106-MIPS-BCM63XX-register-OHCI-controller-if-board-enabl.patch b/target/linux/brcm63xx/patches-3.14/106-MIPS-BCM63XX-register-OHCI-controller-if-board-enabl.patch
deleted file mode 100644 (file)
index 2c26482..0000000
+++ /dev/null
@@ -1,36 +0,0 @@
-From 33ef960aed15f9a98a2c51d8d794cd72418e0be4 Mon Sep 17 00:00:00 2001
-From: Florian Fainelli <florian@openwrt.org>
-Date: Mon, 28 Jan 2013 20:06:25 +0100
-Subject: [PATCH 07/11] MIPS: BCM63XX: register OHCI controller if board
- enables it
-
-BCM63XX-based boards can control the registration of the OHCI controller
-by setting their has_ohci0 flag to 1. Handle this in the generic
-code dealing with board registration and call the actual helper to
-register the OHCI controller.
-
-Signed-off-by: Florian Fainelli <florian@openwrt.org>
----
- arch/mips/bcm63xx/boards/board_bcm963xx.c |    4 ++++
- 1 file changed, 4 insertions(+)
-
---- a/arch/mips/bcm63xx/boards/board_bcm963xx.c
-+++ b/arch/mips/bcm63xx/boards/board_bcm963xx.c
-@@ -26,6 +26,7 @@
- #include <bcm63xx_dev_hsspi.h>
- #include <bcm63xx_dev_pcmcia.h>
- #include <bcm63xx_dev_spi.h>
-+#include <bcm63xx_dev_usb_ohci.h>
- #include <bcm63xx_dev_usb_usbd.h>
- #include <board_bcm963xx.h>
-@@ -898,6 +899,9 @@ int __init board_register_devices(void)
-       if (board.has_usbd)
-               bcm63xx_usbd_register(&board.usbd);
-+      if (board.has_ohci0)
-+              bcm63xx_ohci_register();
-+
-       if (board.has_dsp)
-               bcm63xx_dsp_register(&board.dsp);
diff --git a/target/linux/brcm63xx/patches-3.14/107-MIPS-BCM63XX-introduce-BCM63XX_EHCI-configuration-sy.patch b/target/linux/brcm63xx/patches-3.14/107-MIPS-BCM63XX-introduce-BCM63XX_EHCI-configuration-sy.patch
deleted file mode 100644 (file)
index bce91e3..0000000
+++ /dev/null
@@ -1,62 +0,0 @@
-From 00da1683364e58c6430a4577123d01037f8faddc Mon Sep 17 00:00:00 2001
-From: Florian Fainelli <florian@openwrt.org>
-Date: Mon, 28 Jan 2013 20:06:26 +0100
-Subject: [PATCH 08/11] MIPS: BCM63XX: introduce BCM63XX_EHCI configuration
- symbol
-
-This configuration symbol can be used by CPUs supporting the on-chip
-EHCI controller, and ensures that all relevant EHCI-related
-configuration options are selected. So far BCM6328, BCM6358 and BCM6368
-have an EHCI controller and do select this symbol. Update
-drivers/usb/host/Kconfig with BCM63XX to update direct unmet
-dependencies.
-
-Signed-off-by: Florian Fainelli <florian@openwrt.org>
----
- arch/mips/bcm63xx/Kconfig |    9 +++++++++
- drivers/usb/host/Kconfig  |    5 +++--
- 2 files changed, 12 insertions(+), 2 deletions(-)
-
---- a/arch/mips/bcm63xx/Kconfig
-+++ b/arch/mips/bcm63xx/Kconfig
-@@ -12,11 +12,18 @@ config BCM63XX_OHCI
-       select USB_OHCI_BIG_ENDIAN_DESC if USB_OHCI_HCD
-       select USB_OHCI_BIG_ENDIAN_MMIO if USB_OHCI_HCD
-+config BCM63XX_EHCI
-+      bool
-+      select USB_ARCH_HAS_EHCI
-+      select USB_EHCI_BIG_ENDIAN_DESC if USB_EHCI_HCD
-+      select USB_EHCI_BIG_ENDIAN_MMIO if USB_EHCI_HCD
-+
- config BCM63XX_CPU_6328
-       bool "support 6328 CPU"
-       select SYS_HAS_CPU_BMIPS4350
-       select HW_HAS_PCI
-       select BCM63XX_OHCI
-+      select BCM63XX_EHCI
- config BCM63XX_CPU_6338
-       bool "support 6338 CPU"
-@@ -38,18 +45,21 @@ config BCM63XX_CPU_6358
-       select SYS_HAS_CPU_BMIPS4350
-       select HW_HAS_PCI
-       select BCM63XX_OHCI
-+      select BCM63XX_EHCI
- config BCM63XX_CPU_6362
-       bool "support 6362 CPU"
-       select SYS_HAS_CPU_BMIPS4350
-       select HW_HAS_PCI
-       select BCM63XX_OHCI
-+      select BCM63XX_EHCI
- config BCM63XX_CPU_6368
-       bool "support 6368 CPU"
-       select SYS_HAS_CPU_BMIPS4350
-       select HW_HAS_PCI
-       select BCM63XX_OHCI
-+      select BCM63XX_EHCI
- endmenu
- source "arch/mips/bcm63xx/boards/Kconfig"
diff --git a/target/linux/brcm63xx/patches-3.14/108-MIPS-BCM63XX-add-support-for-the-on-chip-EHCI-contro.patch b/target/linux/brcm63xx/patches-3.14/108-MIPS-BCM63XX-add-support-for-the-on-chip-EHCI-contro.patch
deleted file mode 100644 (file)
index 8b1f8d2..0000000
+++ /dev/null
@@ -1,137 +0,0 @@
-From e38f13bd6408769c0b565bb1079024f496eee121 Mon Sep 17 00:00:00 2001
-From: Florian Fainelli <florian@openwrt.org>
-Date: Mon, 28 Jan 2013 20:06:27 +0100
-Subject: [PATCH 09/11] MIPS: BCM63XX: add support for the on-chip EHCI
- controller
-
-Broadcom BCM63XX SoCs include an on-chip EHCI controller which can be
-driven by the generic ehci-platform driver by using specific power
-on/off/suspend callbacks to manage clocks and hardware specific
-configuration.
-
-Signed-off-by: Maxime Bizon <mbizon@freebox.fr>
-Signed-off-by: Florian Fainelli <florian@openwrt.org>
----
- arch/mips/bcm63xx/Makefile                         |    2 +-
- arch/mips/bcm63xx/dev-usb-ehci.c                   |   92 ++++++++++++++++++++
- .../asm/mach-bcm63xx/bcm63xx_dev_usb_ehci.h        |    6 ++
- 3 files changed, 99 insertions(+), 1 deletion(-)
- create mode 100644 arch/mips/bcm63xx/dev-usb-ehci.c
- create mode 100644 arch/mips/include/asm/mach-bcm63xx/bcm63xx_dev_usb_ehci.h
-
---- a/arch/mips/bcm63xx/Makefile
-+++ b/arch/mips/bcm63xx/Makefile
-@@ -1,7 +1,8 @@
- obj-y         += clk.o cpu.o cs.o gpio.o irq.o nvram.o prom.o reset.o \
-                  setup.o timer.o dev-dsp.o dev-enet.o dev-flash.o \
-                  dev-pcmcia.o dev-rng.o dev-spi.o dev-hsspi.o dev-uart.o \
--                 dev-wdt.o dev-usb-ohci.o dev-usb-usbd.o usb-common.o
-+                 dev-wdt.o dev-usb-ehci.o dev-usb-ohci.o dev-usb-usbd.o \
-+                 usb-common.o
- obj-$(CONFIG_EARLY_PRINTK)    += early_printk.o
- obj-y         += boards/
---- /dev/null
-+++ b/arch/mips/bcm63xx/dev-usb-ehci.c
-@@ -0,0 +1,92 @@
-+/*
-+ * This file is subject to the terms and conditions of the GNU General Public
-+ * License.  See the file "COPYING" in the main directory of this archive
-+ * for more details.
-+ *
-+ * Copyright (C) 2008 Maxime Bizon <mbizon@freebox.fr>
-+ * Copyright (C) 2013 Florian Fainelli <florian@openwrt.org>
-+ */
-+
-+#include <linux/init.h>
-+#include <linux/kernel.h>
-+#include <linux/platform_device.h>
-+#include <linux/clk.h>
-+#include <linux/delay.h>
-+#include <linux/usb/ehci_pdriver.h>
-+#include <linux/dma-mapping.h>
-+
-+#include <bcm63xx_cpu.h>
-+#include <bcm63xx_regs.h>
-+#include <bcm63xx_io.h>
-+#include <bcm63xx_usb_priv.h>
-+#include <bcm63xx_dev_usb_ehci.h>
-+
-+static struct resource ehci_resources[] = {
-+      {
-+              .start          = -1, /* filled at runtime */
-+              .end            = -1, /* filled at runtime */
-+              .flags          = IORESOURCE_MEM,
-+      },
-+      {
-+              .start          = -1, /* filled at runtime */
-+              .flags          = IORESOURCE_IRQ,
-+      },
-+};
-+
-+static u64 ehci_dmamask = DMA_BIT_MASK(32);
-+
-+static struct clk *usb_host_clock;
-+
-+static int bcm63xx_ehci_power_on(struct platform_device *pdev)
-+{
-+      usb_host_clock = clk_get(&pdev->dev, "usbh");
-+      if (IS_ERR_OR_NULL(usb_host_clock))
-+              return -ENODEV;
-+
-+      clk_prepare_enable(usb_host_clock);
-+
-+      bcm63xx_usb_priv_ehci_cfg_set();
-+
-+      return 0;
-+}
-+
-+static void bcm63xx_ehci_power_off(struct platform_device *pdev)
-+{
-+      if (!IS_ERR_OR_NULL(usb_host_clock)) {
-+              clk_disable_unprepare(usb_host_clock);
-+              clk_put(usb_host_clock);
-+      }
-+}
-+
-+static struct usb_ehci_pdata bcm63xx_ehci_pdata = {
-+      .big_endian_desc        = 1,
-+      .big_endian_mmio        = 1,
-+      .power_on               = bcm63xx_ehci_power_on,
-+      .power_off              = bcm63xx_ehci_power_off,
-+      .power_suspend          = bcm63xx_ehci_power_off,
-+};
-+
-+static struct platform_device bcm63xx_ehci_device = {
-+      .name           = "ehci-platform",
-+      .id             = -1,
-+      .num_resources  = ARRAY_SIZE(ehci_resources),
-+      .resource       = ehci_resources,
-+      .dev            = {
-+              .platform_data          = &bcm63xx_ehci_pdata,
-+              .dma_mask               = &ehci_dmamask,
-+              .coherent_dma_mask      = DMA_BIT_MASK(32),
-+      },
-+};
-+
-+int __init bcm63xx_ehci_register(void)
-+{
-+      if (!BCMCPU_IS_6328() && !BCMCPU_IS_6358() && !BCMCPU_IS_6362() && !BCMCPU_IS_6368())
-+              return 0;
-+
-+      ehci_resources[0].start = bcm63xx_regset_address(RSET_EHCI0);
-+      ehci_resources[0].end = ehci_resources[0].start;
-+      ehci_resources[0].end += RSET_EHCI_SIZE - 1;
-+      ehci_resources[1].start = bcm63xx_get_irq_number(IRQ_EHCI0);
-+
-+      return platform_device_register(&bcm63xx_ehci_device);
-+}
---- /dev/null
-+++ b/arch/mips/include/asm/mach-bcm63xx/bcm63xx_dev_usb_ehci.h
-@@ -0,0 +1,6 @@
-+#ifndef BCM63XX_DEV_USB_EHCI_H_
-+#define BCM63XX_DEV_USB_EHCI_H_
-+
-+int bcm63xx_ehci_register(void);
-+
-+#endif /* BCM63XX_DEV_USB_EHCI_H_ */
diff --git a/target/linux/brcm63xx/patches-3.14/109-MIPS-BCM63XX-register-EHCI-controller-if-board-enabl.patch b/target/linux/brcm63xx/patches-3.14/109-MIPS-BCM63XX-register-EHCI-controller-if-board-enabl.patch
deleted file mode 100644 (file)
index 641a57c..0000000
+++ /dev/null
@@ -1,36 +0,0 @@
-From 709ef2034f5ba06da35f89856ad7baf2b7a41287 Mon Sep 17 00:00:00 2001
-From: Florian Fainelli <florian@openwrt.org>
-Date: Mon, 28 Jan 2013 20:06:28 +0100
-Subject: [PATCH 10/11] MIPS: BCM63XX: register EHCI controller if board
- enables it
-
-BCM63XX-based board can control the registration of the EHCI controller
-by setting their has_ehci0 flag to 1. Handle this in the generic
-code dealing with board registration and call the actual helper to register
-the EHCI controller.
-
-Signed-off-by: Florian Fainelli <florian@openwrt.org>
----
- arch/mips/bcm63xx/boards/board_bcm963xx.c |    4 ++++
- 1 file changed, 4 insertions(+)
-
---- a/arch/mips/bcm63xx/boards/board_bcm963xx.c
-+++ b/arch/mips/bcm63xx/boards/board_bcm963xx.c
-@@ -26,6 +26,7 @@
- #include <bcm63xx_dev_hsspi.h>
- #include <bcm63xx_dev_pcmcia.h>
- #include <bcm63xx_dev_spi.h>
-+#include <bcm63xx_dev_usb_ehci.h>
- #include <bcm63xx_dev_usb_ohci.h>
- #include <bcm63xx_dev_usb_usbd.h>
- #include <board_bcm963xx.h>
-@@ -899,6 +900,9 @@ int __init board_register_devices(void)
-       if (board.has_usbd)
-               bcm63xx_usbd_register(&board.usbd);
-+      if (board.has_ehci0)
-+              bcm63xx_ehci_register();
-+
-       if (board.has_ohci0)
-               bcm63xx_ohci_register();
diff --git a/target/linux/brcm63xx/patches-3.14/110-MIPS-BCM63XX-EHCI-controller-does-not-support-overcu.patch b/target/linux/brcm63xx/patches-3.14/110-MIPS-BCM63XX-EHCI-controller-does-not-support-overcu.patch
deleted file mode 100644 (file)
index 6d91129..0000000
+++ /dev/null
@@ -1,24 +0,0 @@
-From 111bbd770441ab34f9da5bb1d85767a9b75227b4 Mon Sep 17 00:00:00 2001
-From: Florian Fainelli <florian@openwrt.org>
-Date: Mon, 28 Jan 2013 20:06:30 +0100
-Subject: [PATCH 12/12] MIPS: BCM63XX: EHCI controller does not support
- overcurrent
-
-This patch sets the ignore_oc flag for the BCM63XX EHCI controller as it
-does not support proper overcurrent reporting.
-
-Signed-off-by: Florian Fainelli <florian@openwrt.org>
----
- arch/mips/bcm63xx/dev-usb-ehci.c |    1 +
- 1 file changed, 1 insertion(+)
-
---- a/arch/mips/bcm63xx/dev-usb-ehci.c
-+++ b/arch/mips/bcm63xx/dev-usb-ehci.c
-@@ -61,6 +61,7 @@ static void bcm63xx_ehci_power_off(struc
- static struct usb_ehci_pdata bcm63xx_ehci_pdata = {
-       .big_endian_desc        = 1,
-       .big_endian_mmio        = 1,
-+      .ignore_oc              = 1,
-       .power_on               = bcm63xx_ehci_power_on,
-       .power_off              = bcm63xx_ehci_power_off,
-       .power_suspend          = bcm63xx_ehci_power_off,
diff --git a/target/linux/brcm63xx/patches-3.14/201-SPI-Allow-specifying-the-parsers-for-SPI-flash.patch b/target/linux/brcm63xx/patches-3.14/201-SPI-Allow-specifying-the-parsers-for-SPI-flash.patch
deleted file mode 100644 (file)
index 00dc9c9..0000000
+++ /dev/null
@@ -1,38 +0,0 @@
-From 3f650fc30aa0badf9d02842ce396cea3eef2eeaa Mon Sep 17 00:00:00 2001
-From: Jonas Gorski <jonas.gorski@gmail.com>
-Date: Fri, 1 Jul 2011 23:16:47 +0200
-Subject: [PATCH 49/79] SPI: Allow specifying the parsers for SPI flash
-
-Signed-off-by: Jonas Gorski <jonas.gorski@gmail.com>
----
- include/linux/spi/flash.h |    5 ++++-
- 1 file changed, 4 insertions(+), 1 deletion(-)
-
---- a/include/linux/spi/flash.h
-+++ b/include/linux/spi/flash.h
-@@ -2,7 +2,7 @@
- #define LINUX_SPI_FLASH_H
- struct mtd_partition;
--
-+struct mtd_part_parser_data;
- /**
-  * struct flash_platform_data: board-specific flash data
-  * @name: optional flash device name (eg, as used with mtdparts=)
-@@ -10,6 +10,8 @@ struct mtd_partition;
-  * @nr_parts: number of mtd_partitions for static partitoning
-  * @type: optional flash device type (e.g. m25p80 vs m25p64), for use
-  *    with chips that can't be queried for JEDEC or other IDs
-+ * @part_probe_types: optional list of MTD parser names to use for
-+ *    partitioning
-  *
-  * Board init code (in arch/.../mach-xxx/board-yyy.c files) can
-  * provide information about SPI flash parts (such as DataFlash) to
-@@ -25,6 +27,7 @@ struct flash_platform_data {
-       char            *type;
-+      const char      **part_probe_types;
-       /* we'll likely add more ... use JEDEC IDs, etc */
- };
diff --git a/target/linux/brcm63xx/patches-3.14/202-MTD-DEVICES-m25p80-use-parsers-if-provided-in-flash-.patch b/target/linux/brcm63xx/patches-3.14/202-MTD-DEVICES-m25p80-use-parsers-if-provided-in-flash-.patch
deleted file mode 100644 (file)
index 7414a3b..0000000
+++ /dev/null
@@ -1,23 +0,0 @@
-From c7c3c338cb25d7f55ddb3f6bfbf3572758ca3896 Mon Sep 17 00:00:00 2001
-From: Jonas Gorski <jonas.gorski@gmail.com>
-Date: Thu, 10 Nov 2011 16:53:08 +0100
-Subject: [PATCH 50/79] MTD: DEVICES: m25p80: use parsers if provided in flash
- platform data
-
-Signed-off-by: Jonas Gorski <jonas.gorski@gmail.com>
----
- drivers/mtd/devices/m25p80.c |    3 ++-
- 1 file changed, 2 insertions(+), 1 deletion(-)
-
---- a/drivers/mtd/devices/m25p80.c
-+++ b/drivers/mtd/devices/m25p80.c
-@@ -1314,7 +1314,8 @@ static int m25p_probe(struct spi_device
-       /* partitions should match sector boundaries; and it may be good to
-        * use readonly partitions for writeprotected sectors (BP2..BP0).
-        */
--      return mtd_device_parse_register(&flash->mtd, NULL, &ppdata,
-+      return mtd_device_parse_register(&flash->mtd,
-+                      data ? data->part_probe_types : NULL, &ppdata,
-                       data ? data->parts : NULL,
-                       data ? data->nr_parts : 0);
- }
diff --git a/target/linux/brcm63xx/patches-3.14/203-MTD-DEVICES-m25p80-add-support-for-limiting-reads.patch b/target/linux/brcm63xx/patches-3.14/203-MTD-DEVICES-m25p80-add-support-for-limiting-reads.patch
deleted file mode 100644 (file)
index e5676dc..0000000
+++ /dev/null
@@ -1,92 +0,0 @@
-From 5fb4e8d7287ac8fcb33aae8b1e9e22c5a3c392bd Mon Sep 17 00:00:00 2001
-From: Jonas Gorski <jonas.gorski@gmail.com>
-Date: Thu, 10 Nov 2011 17:33:40 +0100
-Subject: [PATCH 51/79] MTD: DEVICES: m25p80: add support for limiting reads
-
-Signed-off-by: Jonas Gorski <jonas.gorski@gmail.com>
----
- drivers/mtd/devices/m25p80.c |   29 +++++++++++++++++++++++++++--
- include/linux/spi/flash.h    |    4 ++++
- 2 files changed, 31 insertions(+), 2 deletions(-)
-
---- a/drivers/mtd/devices/m25p80.c
-+++ b/drivers/mtd/devices/m25p80.c
-@@ -115,6 +115,7 @@ struct m25p {
-       u8                      program_opcode;
-       u8                      *command;
-       enum read_type          flash_read;
-+      int                     max_transfer_len;
- };
- static inline struct m25p *mtd_to_m25p(struct mtd_info *mtd)
-@@ -509,10 +510,9 @@ static inline unsigned int m25p80_rx_nbi
-  * Read an address range from the flash chip.  The address range
-  * may be any size provided it is within the physical boundaries.
-  */
--static int m25p80_read(struct mtd_info *mtd, loff_t from, size_t len,
-+static int __m25p80_read(struct m25p *flash, loff_t from, size_t len,
-       size_t *retlen, u_char *buf)
- {
--      struct m25p *flash = mtd_to_m25p(mtd);
-       struct spi_transfer t[2];
-       struct spi_message m;
-       uint8_t opcode;
-@@ -562,6 +562,28 @@ static int m25p80_read(struct mtd_info *
-       return 0;
- }
-+static int m25p80_read(struct mtd_info *mtd, loff_t from, size_t len,
-+      size_t *retlen, u_char *buf)
-+{
-+      struct m25p *flash = mtd_to_m25p(mtd);
-+      size_t off;
-+      size_t read_len = flash->max_transfer_len;
-+      size_t part_len;
-+      int ret = 0;
-+
-+      if (!read_len)
-+              return __m25p80_read(flash, from, len, retlen, buf);
-+
-+      *retlen = 0;
-+
-+      for (off = 0; off < len && !ret; off += read_len) {
-+              ret = __m25p80_read(flash, from + off, min(len - off, read_len),
-+                                  &part_len, buf + off);
-+                      *retlen += part_len;
-+      }
-+
-+      return ret;
-+}
- /*
-  * Write an address range to the flash chip.  Data must be written in
-  * FLASH_PAGESIZE chunks.  The address range may be any size provided
-@@ -1159,6 +1181,9 @@ static int m25p_probe(struct spi_device
-       if (!flash->command)
-               return -ENOMEM;
-+      if (data)
-+              flash->max_transfer_len = data->max_transfer_len;
-+
-       flash->spi = spi;
-       mutex_init(&flash->lock);
-       spi_set_drvdata(spi, flash);
---- a/include/linux/spi/flash.h
-+++ b/include/linux/spi/flash.h
-@@ -13,6 +13,8 @@ struct mtd_part_parser_data;
-  * @part_probe_types: optional list of MTD parser names to use for
-  *    partitioning
-  *
-+ * @max_transfer_len: option maximum read/write length limitation for
-+ *    SPI controllers not able to transfer any length commands.
-  * Board init code (in arch/.../mach-xxx/board-yyy.c files) can
-  * provide information about SPI flash parts (such as DataFlash) to
-  * help set up the device and its appropriate default partitioning.
-@@ -28,6 +30,8 @@ struct flash_platform_data {
-       char            *type;
-       const char      **part_probe_types;
-+
-+      unsigned int    max_transfer_len;
-       /* we'll likely add more ... use JEDEC IDs, etc */
- };
diff --git a/target/linux/brcm63xx/patches-3.14/204-USB-OHCI-allow-other-arches-to-use-the-BE-frame-numb.patch b/target/linux/brcm63xx/patches-3.14/204-USB-OHCI-allow-other-arches-to-use-the-BE-frame-numb.patch
deleted file mode 100644 (file)
index 6e9e6df..0000000
+++ /dev/null
@@ -1,31 +0,0 @@
-From b2f399dcd674a692a64bb3b300b77b78ae57b530 Mon Sep 17 00:00:00 2001
-From: Jonas Gorski <jogo@openwrt.org>
-Date: Sun, 12 Jan 2014 16:47:35 +0100
-Subject: [PATCH] USB: OHCI: allow other arches to use the BE frame number
- quirk
-
-Intead of guarding it with a certain PPC SoC and expanding the list
-for each SoC requiring it, just guard it with USB_OHCI_BIG_ENDIAN_DESC.
-
-This makes it less suprising that passing no_big_frame_no = 1 for the
-platform data does not do what expected (or
-
-Checking it for all big endian descriptor setups should not impact
-performance much as USB1.1 is rather slow anyway.
-
-Signed-off-by: Jonas Gorski <jogo@openwrt.org>
----
- drivers/usb/host/ohci.h | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
---- a/drivers/usb/host/ohci.h
-+++ b/drivers/usb/host/ohci.h
-@@ -641,7 +641,7 @@ static inline u32 hc32_to_cpup (const st
-  * some big-endian SOC implementations.  Same thing happens with PSW access.
-  */
--#ifdef CONFIG_PPC_MPC52xx
-+#ifdef CONFIG_USB_OHCI_BIG_ENDIAN_DESC
- #define big_endian_frame_no_quirk(ohci)       (ohci->flags & OHCI_QUIRK_FRAME_NO)
- #else
- #define big_endian_frame_no_quirk(ohci)       0
diff --git a/target/linux/brcm63xx/patches-3.14/206-USB-EHCI-allow-limiting-ports-for-ehci-platform.patch b/target/linux/brcm63xx/patches-3.14/206-USB-EHCI-allow-limiting-ports-for-ehci-platform.patch
deleted file mode 100644 (file)
index 474171f..0000000
+++ /dev/null
@@ -1,65 +0,0 @@
-From 6ac09efa8f0e189ffe7dd7b0889289de56ee44cc Mon Sep 17 00:00:00 2001
-From: Jonas Gorski <jogo@openwrt.org>
-Date: Sun, 19 Jan 2014 12:18:03 +0100
-Subject: [PATCH] USB: EHCI: allow limiting ports for ehci-platform
-
-In the same way as the ohci platform driver allows limiting ports,
-enable the same for ehci. This prevents a mismatch in the available
-ports between ehci/ohci on USB 2.0 controllers.
-
-This is needed if the USB host controller always reports the maximum
-number of ports regardless of the number of available ports (because
-one might be set to be usb device).
-
-Signed-off-by: Jonas Gorski <jogo@openwrt.org>
----
- drivers/usb/host/ehci-hcd.c      | 4 ++++
- drivers/usb/host/ehci-platform.c | 2 ++
- drivers/usb/host/ehci.h          | 1 +
- include/linux/usb/ehci_pdriver.h | 1 +
- 4 files changed, 8 insertions(+)
-
---- a/drivers/usb/host/ehci-hcd.c
-+++ b/drivers/usb/host/ehci-hcd.c
-@@ -660,6 +660,10 @@ int ehci_setup(struct usb_hcd *hcd)
-       /* cache this readonly data; minimize chip reads */
-       ehci->hcs_params = ehci_readl(ehci, &ehci->caps->hcs_params);
-+      if (ehci->num_ports) {
-+              ehci->hcs_params &= ~0xf; /* bits 3:0, ports on HC */
-+              ehci->hcs_params |= ehci->num_ports;
-+      }
-       ehci->sbrn = HCD_USB2;
---- a/drivers/usb/host/ehci-platform.c
-+++ b/drivers/usb/host/ehci-platform.c
-@@ -48,6 +48,8 @@ static int ehci_platform_reset(struct us
-       ehci->big_endian_desc = pdata->big_endian_desc;
-       ehci->big_endian_mmio = pdata->big_endian_mmio;
-       ehci->ignore_oc = pdata->ignore_oc;
-+      if (pdata->num_ports && pdata->num_ports <= 15)
-+              ehci->num_ports = pdata->num_ports;
-       if (pdata->pre_setup) {
-               retval = pdata->pre_setup(hcd);
---- a/drivers/usb/host/ehci.h
-+++ b/drivers/usb/host/ehci.h
-@@ -213,6 +213,7 @@ struct ehci_hcd {                  /* one per controlle
-       u32                     command;
-       /* SILICON QUIRKS */
-+      unsigned int            num_ports;
-       unsigned                no_selective_suspend:1;
-       unsigned                has_fsl_port_bug:1; /* FreeScale */
-       unsigned                big_endian_mmio:1;
---- a/include/linux/usb/ehci_pdriver.h
-+++ b/include/linux/usb/ehci_pdriver.h
-@@ -40,6 +40,7 @@ struct usb_hcd;
-  */
- struct usb_ehci_pdata {
-       int             caps_offset;
-+      unsigned int    num_ports;
-       unsigned        has_tt:1;
-       unsigned        has_synopsys_hc_bug:1;
-       unsigned        big_endian_desc:1;
diff --git a/target/linux/brcm63xx/patches-3.14/207-MIPS-BCM63XX-move-device-registration-code-into-its-.patch b/target/linux/brcm63xx/patches-3.14/207-MIPS-BCM63XX-move-device-registration-code-into-its-.patch
deleted file mode 100644 (file)
index 4e5e611..0000000
+++ /dev/null
@@ -1,493 +0,0 @@
-From 5a50cb0d53344a2429831b00925d6183d4d332e1 Mon Sep 17 00:00:00 2001
-From: Jonas Gorski <jogo@openwrt.org>
-Date: Sun, 9 Mar 2014 03:54:05 +0100
-Subject: [PATCH 40/44] MIPS: BCM63XX: move device registration code into its
- own file
-
-Move device registration code into its own file to allow sharing it
-between board implementations.
-
-Signed-off-by: Jonas Gorski <jogo@openwrt.org>
----
- arch/mips/bcm63xx/boards/Makefile         |   1 +
- arch/mips/bcm63xx/boards/board_bcm963xx.c | 188 +-------------------------
- arch/mips/bcm63xx/boards/board_common.c   | 215 ++++++++++++++++++++++++++++++
- arch/mips/bcm63xx/boards/board_common.h   |   8 ++
- 4 files changed, 223 insertions(+), 183 deletions(-)
- create mode 100644 arch/mips/bcm63xx/boards/board_common.c
- create mode 100644 arch/mips/bcm63xx/boards/board_common.h
-
---- a/arch/mips/bcm63xx/boards/Makefile
-+++ b/arch/mips/bcm63xx/boards/Makefile
-@@ -1 +1,2 @@
-+obj-y                                 += board_common.o
- obj-$(CONFIG_BOARD_BCM963XX)          += board_bcm963xx.o
---- a/arch/mips/bcm63xx/boards/board_bcm963xx.c
-+++ b/arch/mips/bcm63xx/boards/board_bcm963xx.c
-@@ -10,35 +10,22 @@
- #include <linux/init.h>
- #include <linux/kernel.h>
- #include <linux/string.h>
--#include <linux/platform_device.h>
--#include <linux/ssb/ssb.h>
- #include <asm/addrspace.h>
- #include <bcm63xx_board.h>
- #include <bcm63xx_cpu.h>
--#include <bcm63xx_dev_uart.h>
- #include <bcm63xx_regs.h>
- #include <bcm63xx_io.h>
- #include <bcm63xx_nvram.h>
--#include <bcm63xx_dev_pci.h>
--#include <bcm63xx_dev_enet.h>
--#include <bcm63xx_dev_dsp.h>
--#include <bcm63xx_dev_flash.h>
--#include <bcm63xx_dev_hsspi.h>
--#include <bcm63xx_dev_pcmcia.h>
--#include <bcm63xx_dev_spi.h>
--#include <bcm63xx_dev_usb_ehci.h>
--#include <bcm63xx_dev_usb_ohci.h>
--#include <bcm63xx_dev_usb_usbd.h>
- #include <board_bcm963xx.h>
-+#include "board_common.h"
-+
- #include <uapi/linux/bcm933xx_hcs.h>
- #define PFX   "board_bcm963xx: "
- #define HCS_OFFSET_128K                       0x20000
--static struct board_info board;
--
- /*
-  * known 3368 boards
-  */
-@@ -711,52 +698,6 @@ static const struct board_info __initcon
- };
- /*
-- * Register a sane SPROMv2 to make the on-board
-- * bcm4318 WLAN work
-- */
--#ifdef CONFIG_SSB_PCIHOST
--static struct ssb_sprom bcm63xx_sprom = {
--      .revision               = 0x02,
--      .board_rev              = 0x17,
--      .country_code           = 0x0,
--      .ant_available_bg       = 0x3,
--      .pa0b0                  = 0x15ae,
--      .pa0b1                  = 0xfa85,
--      .pa0b2                  = 0xfe8d,
--      .pa1b0                  = 0xffff,
--      .pa1b1                  = 0xffff,
--      .pa1b2                  = 0xffff,
--      .gpio0                  = 0xff,
--      .gpio1                  = 0xff,
--      .gpio2                  = 0xff,
--      .gpio3                  = 0xff,
--      .maxpwr_bg              = 0x004c,
--      .itssi_bg               = 0x00,
--      .boardflags_lo          = 0x2848,
--      .boardflags_hi          = 0x0000,
--};
--
--int bcm63xx_get_fallback_sprom(struct ssb_bus *bus, struct ssb_sprom *out)
--{
--      if (bus->bustype == SSB_BUSTYPE_PCI) {
--              memcpy(out, &bcm63xx_sprom, sizeof(struct ssb_sprom));
--              return 0;
--      } else {
--              printk(KERN_ERR PFX "unable to fill SPROM for given bustype.\n");
--              return -EINVAL;
--      }
--}
--#endif
--
--/*
-- * return board name for /proc/cpuinfo
-- */
--const char *board_get_name(void)
--{
--      return board.name;
--}
--
--/*
-  * early init callback, read nvram data from flash and checksum it
-  */
- void __init board_prom_init(void)
-@@ -801,141 +742,16 @@ void __init board_prom_init(void)
-               if (strncmp(board_name, bcm963xx_boards[i]->name, 16))
-                       continue;
-               /* copy, board desc array is marked initdata */
--              memcpy(&board, bcm963xx_boards[i], sizeof(board));
-+              board_early_setup(bcm963xx_boards[i]);
-               break;
-       }
--      /* bail out if board is not found, will complain later */
--      if (!board.name[0]) {
-+      /* warn if board is not found, will complain later */
-+      if (i == ARRAY_SIZE(bcm963xx_boards)) {
-               char name[17];
-               memcpy(name, board_name, 16);
-               name[16] = 0;
-               printk(KERN_ERR PFX "unknown bcm963xx board: %s\n",
-                      name);
--              return;
--      }
--
--      /* setup pin multiplexing depending on board enabled device,
--       * this has to be done this early since PCI init is done
--       * inside arch_initcall */
--      val = 0;
--
--#ifdef CONFIG_PCI
--      if (board.has_pci) {
--              bcm63xx_pci_enabled = 1;
--              if (BCMCPU_IS_6348())
--                      val |= GPIO_MODE_6348_G2_PCI;
--      }
--#endif
--
--      if (board.has_pccard) {
--              if (BCMCPU_IS_6348())
--                      val |= GPIO_MODE_6348_G1_MII_PCCARD;
--      }
--
--      if (board.has_enet0 && !board.enet0.use_internal_phy) {
--              if (BCMCPU_IS_6348())
--                      val |= GPIO_MODE_6348_G3_EXT_MII |
--                              GPIO_MODE_6348_G0_EXT_MII;
--      }
--
--      if (board.has_enet1 && !board.enet1.use_internal_phy) {
--              if (BCMCPU_IS_6348())
--                      val |= GPIO_MODE_6348_G3_EXT_MII |
--                              GPIO_MODE_6348_G0_EXT_MII;
--      }
--
--      bcm_gpio_writel(val, GPIO_MODE_REG);
--}
--
--/*
-- * second stage init callback, good time to panic if we couldn't
-- * identify on which board we're running since early printk is working
-- */
--void __init board_setup(void)
--{
--      if (!board.name[0])
--              panic("unable to detect bcm963xx board");
--      printk(KERN_INFO PFX "board name: %s\n", board.name);
--
--      /* make sure we're running on expected cpu */
--      if (bcm63xx_get_cpu_id() != board.expected_cpu_id)
--              panic("unexpected CPU for bcm963xx board");
--}
--
--static struct gpio_led_platform_data bcm63xx_led_data;
--
--static struct platform_device bcm63xx_gpio_leds = {
--      .name                   = "leds-gpio",
--      .id                     = 0,
--      .dev.platform_data      = &bcm63xx_led_data,
--};
--
--/*
-- * third stage init callback, register all board devices.
-- */
--int __init board_register_devices(void)
--{
--      if (board.has_uart0)
--              bcm63xx_uart_register(0);
--
--      if (board.has_uart1)
--              bcm63xx_uart_register(1);
--
--      if (board.has_pccard)
--              bcm63xx_pcmcia_register();
--
--      if (board.has_enet0 &&
--          !bcm63xx_nvram_get_mac_address(board.enet0.mac_addr))
--              bcm63xx_enet_register(0, &board.enet0);
--
--      if (board.has_enet1 &&
--          !bcm63xx_nvram_get_mac_address(board.enet1.mac_addr))
--              bcm63xx_enet_register(1, &board.enet1);
--
--      if (board.has_enetsw &&
--          !bcm63xx_nvram_get_mac_address(board.enetsw.mac_addr))
--              bcm63xx_enetsw_register(&board.enetsw);
--
--      if (board.has_usbd)
--              bcm63xx_usbd_register(&board.usbd);
--
--      if (board.has_ehci0)
--              bcm63xx_ehci_register();
--
--      if (board.has_ohci0)
--              bcm63xx_ohci_register();
--
--      if (board.has_dsp)
--              bcm63xx_dsp_register(&board.dsp);
--
--      /* Generate MAC address for WLAN and register our SPROM,
--       * do this after registering enet devices
--       */
--#ifdef CONFIG_SSB_PCIHOST
--      if (!bcm63xx_nvram_get_mac_address(bcm63xx_sprom.il0mac)) {
--              memcpy(bcm63xx_sprom.et0mac, bcm63xx_sprom.il0mac, ETH_ALEN);
--              memcpy(bcm63xx_sprom.et1mac, bcm63xx_sprom.il0mac, ETH_ALEN);
--              if (ssb_arch_register_fallback_sprom(
--                              &bcm63xx_get_fallback_sprom) < 0)
--                      pr_err(PFX "failed to register fallback SPROM\n");
-       }
--#endif
--
--      bcm63xx_spi_register();
--
--      bcm63xx_hsspi_register();
--
--      bcm63xx_flash_register();
--
--      bcm63xx_led_data.num_leds = ARRAY_SIZE(board.leds);
--      bcm63xx_led_data.leds = board.leds;
--
--      platform_device_register(&bcm63xx_gpio_leds);
--
--      if (board.ephy_reset_gpio && board.ephy_reset_gpio_flags)
--              gpio_request_one(board.ephy_reset_gpio,
--                              board.ephy_reset_gpio_flags, "ephy-reset");
--
--      return 0;
- }
---- /dev/null
-+++ b/arch/mips/bcm63xx/boards/board_common.c
-@@ -0,0 +1,217 @@
-+/*
-+ * This file is subject to the terms and conditions of the GNU General Public
-+ * License.  See the file "COPYING" in the main directory of this archive
-+ * for more details.
-+ *
-+ * Copyright (C) 2008 Maxime Bizon <mbizon@freebox.fr>
-+ * Copyright (C) 2008 Florian Fainelli <florian@openwrt.org>
-+ */
-+
-+#include <linux/init.h>
-+#include <linux/kernel.h>
-+#include <linux/string.h>
-+#include <linux/platform_device.h>
-+#include <linux/ssb/ssb.h>
-+#include <asm/addrspace.h>
-+#include <bcm63xx_board.h>
-+#include <bcm63xx_cpu.h>
-+#include <bcm63xx_dev_uart.h>
-+#include <bcm63xx_regs.h>
-+#include <bcm63xx_io.h>
-+#include <bcm63xx_nvram.h>
-+#include <bcm63xx_dev_pci.h>
-+#include <bcm63xx_dev_enet.h>
-+#include <bcm63xx_dev_dsp.h>
-+#include <bcm63xx_dev_flash.h>
-+#include <bcm63xx_dev_hsspi.h>
-+#include <bcm63xx_dev_pcmcia.h>
-+#include <bcm63xx_dev_spi.h>
-+#include <bcm63xx_dev_usb_ehci.h>
-+#include <bcm63xx_dev_usb_ohci.h>
-+#include <bcm63xx_dev_usb_usbd.h>
-+#include <board_bcm963xx.h>
-+
-+#define PFX   "board: "
-+
-+static struct board_info board;
-+
-+/*
-+ * Register a sane SPROMv2 to make the on-board
-+ * bcm4318 WLAN work
-+ */
-+#ifdef CONFIG_SSB_PCIHOST
-+static struct ssb_sprom bcm63xx_sprom = {
-+      .revision               = 0x02,
-+      .board_rev              = 0x17,
-+      .country_code           = 0x0,
-+      .ant_available_bg       = 0x3,
-+      .pa0b0                  = 0x15ae,
-+      .pa0b1                  = 0xfa85,
-+      .pa0b2                  = 0xfe8d,
-+      .pa1b0                  = 0xffff,
-+      .pa1b1                  = 0xffff,
-+      .pa1b2                  = 0xffff,
-+      .gpio0                  = 0xff,
-+      .gpio1                  = 0xff,
-+      .gpio2                  = 0xff,
-+      .gpio3                  = 0xff,
-+      .maxpwr_bg              = 0x004c,
-+      .itssi_bg               = 0x00,
-+      .boardflags_lo          = 0x2848,
-+      .boardflags_hi          = 0x0000,
-+};
-+
-+int bcm63xx_get_fallback_sprom(struct ssb_bus *bus, struct ssb_sprom *out)
-+{
-+      if (bus->bustype == SSB_BUSTYPE_PCI) {
-+              memcpy(out, &bcm63xx_sprom, sizeof(struct ssb_sprom));
-+              return 0;
-+      } else {
-+              printk(KERN_ERR PFX "unable to fill SPROM for given bustype.\n");
-+              return -EINVAL;
-+      }
-+}
-+#endif
-+
-+/*
-+ * return board name for /proc/cpuinfo
-+ */
-+const char *board_get_name(void)
-+{
-+      return board.name;
-+}
-+
-+/*
-+ * setup board for device registration
-+ */
-+void __init board_early_setup(const struct board_info *target)
-+{
-+      u32 val;
-+
-+      memcpy(&board, target, sizeof(board));
-+
-+      /* setup pin multiplexing depending on board enabled device,
-+       * this has to be done this early since PCI init is done
-+       * inside arch_initcall */
-+      val = 0;
-+
-+#ifdef CONFIG_PCI
-+      if (board.has_pci) {
-+              bcm63xx_pci_enabled = 1;
-+              if (BCMCPU_IS_6348())
-+                      val |= GPIO_MODE_6348_G2_PCI;
-+      }
-+#endif
-+
-+      if (board.has_pccard) {
-+              if (BCMCPU_IS_6348())
-+                      val |= GPIO_MODE_6348_G1_MII_PCCARD;
-+      }
-+
-+      if (board.has_enet0 && !board.enet0.use_internal_phy) {
-+              if (BCMCPU_IS_6348())
-+                      val |= GPIO_MODE_6348_G3_EXT_MII |
-+                              GPIO_MODE_6348_G0_EXT_MII;
-+      }
-+
-+      if (board.has_enet1 && !board.enet1.use_internal_phy) {
-+              if (BCMCPU_IS_6348())
-+                      val |= GPIO_MODE_6348_G3_EXT_MII |
-+                              GPIO_MODE_6348_G0_EXT_MII;
-+      }
-+
-+      bcm_gpio_writel(val, GPIO_MODE_REG);
-+}
-+
-+
-+/*
-+ * second stage init callback, good time to panic if we couldn't
-+ * identify on which board we're running since early printk is working
-+ */
-+void __init board_setup(void)
-+{
-+      if (!board.name[0])
-+              panic("unable to detect bcm963xx board");
-+      printk(KERN_INFO PFX "board name: %s\n", board.name);
-+
-+      /* make sure we're running on expected cpu */
-+      if (bcm63xx_get_cpu_id() != board.expected_cpu_id)
-+              panic("unexpected CPU for bcm963xx board");
-+}
-+
-+static struct gpio_led_platform_data bcm63xx_led_data;
-+
-+static struct platform_device bcm63xx_gpio_leds = {
-+      .name                   = "leds-gpio",
-+      .id                     = 0,
-+      .dev.platform_data      = &bcm63xx_led_data,
-+};
-+
-+/*
-+ * third stage init callback, register all board devices.
-+ */
-+int __init board_register_devices(void)
-+{
-+      if (board.has_uart0)
-+              bcm63xx_uart_register(0);
-+
-+      if (board.has_uart1)
-+              bcm63xx_uart_register(1);
-+
-+      if (board.has_pccard)
-+              bcm63xx_pcmcia_register();
-+
-+      if (board.has_enet0 &&
-+          !bcm63xx_nvram_get_mac_address(board.enet0.mac_addr))
-+              bcm63xx_enet_register(0, &board.enet0);
-+
-+      if (board.has_enet1 &&
-+          !bcm63xx_nvram_get_mac_address(board.enet1.mac_addr))
-+              bcm63xx_enet_register(1, &board.enet1);
-+
-+      if (board.has_enetsw &&
-+          !bcm63xx_nvram_get_mac_address(board.enetsw.mac_addr))
-+              bcm63xx_enetsw_register(&board.enetsw);
-+
-+      if (board.has_usbd)
-+              bcm63xx_usbd_register(&board.usbd);
-+
-+      if (board.has_ehci0)
-+              bcm63xx_ehci_register();
-+
-+      if (board.has_ohci0)
-+              bcm63xx_ohci_register();
-+
-+      if (board.has_dsp)
-+              bcm63xx_dsp_register(&board.dsp);
-+
-+      /* Generate MAC address for WLAN and register our SPROM,
-+       * do this after registering enet devices
-+       */
-+#ifdef CONFIG_SSB_PCIHOST
-+      if (!bcm63xx_nvram_get_mac_address(bcm63xx_sprom.il0mac)) {
-+              memcpy(bcm63xx_sprom.et0mac, bcm63xx_sprom.il0mac, ETH_ALEN);
-+              memcpy(bcm63xx_sprom.et1mac, bcm63xx_sprom.il0mac, ETH_ALEN);
-+              if (ssb_arch_register_fallback_sprom(
-+                              &bcm63xx_get_fallback_sprom) < 0)
-+                      pr_err(PFX "failed to register fallback SPROM\n");
-+      }
-+#endif
-+
-+      bcm63xx_spi_register();
-+
-+      bcm63xx_hsspi_register();
-+
-+      bcm63xx_flash_register();
-+
-+      bcm63xx_led_data.num_leds = ARRAY_SIZE(board.leds);
-+      bcm63xx_led_data.leds = board.leds;
-+
-+      platform_device_register(&bcm63xx_gpio_leds);
-+
-+      if (board.ephy_reset_gpio && board.ephy_reset_gpio_flags)
-+              gpio_request_one(board.ephy_reset_gpio,
-+                              board.ephy_reset_gpio_flags, "ephy-reset");
-+
-+      return 0;
-+}
---- /dev/null
-+++ b/arch/mips/bcm63xx/boards/board_common.h
-@@ -0,0 +1,8 @@
-+#ifndef __BOARD_COMMON_H
-+#define __BOARD_COMMON_H
-+
-+#include <board_bcm963xx.h>
-+
-+void board_early_setup(const struct board_info *board);
-+
-+#endif /* __BOARD_COMMON_H */
diff --git a/target/linux/brcm63xx/patches-3.14/208-MIPS-BCM63XX-pass-a-mac-addresss-allocator-to-board-.patch b/target/linux/brcm63xx/patches-3.14/208-MIPS-BCM63XX-pass-a-mac-addresss-allocator-to-board-.patch
deleted file mode 100644 (file)
index 877030f..0000000
+++ /dev/null
@@ -1,100 +0,0 @@
-From 4e9c34a37bd3442b286ba55441bfe22c1ac5b65f Mon Sep 17 00:00:00 2001
-From: Jonas Gorski <jogo@openwrt.org>
-Date: Sun, 9 Mar 2014 04:08:06 +0100
-Subject: [PATCH 41/44] MIPS: BCM63XX: pass a mac addresss allocator to board
- setup
-
-Pass a mac address allocator to board setup code to allow board
-implementations to work with third party bootloaders not using nvram
-for configuration storage.
-
-Signed-off-by: Jonas Gorski <jogo@openwrt.org>
----
- arch/mips/bcm63xx/boards/board_bcm963xx.c |  3 ++-
- arch/mips/bcm63xx/boards/board_common.c   | 16 ++++++++++------
- arch/mips/bcm63xx/boards/board_common.h   |  3 ++-
- 3 files changed, 14 insertions(+), 8 deletions(-)
-
---- a/arch/mips/bcm63xx/boards/board_bcm963xx.c
-+++ b/arch/mips/bcm63xx/boards/board_bcm963xx.c
-@@ -742,7 +742,8 @@ void __init board_prom_init(void)
-               if (strncmp(board_name, bcm963xx_boards[i]->name, 16))
-                       continue;
-               /* copy, board desc array is marked initdata */
--              board_early_setup(bcm963xx_boards[i]);
-+              board_early_setup(bcm963xx_boards[i],
-+                                bcm63xx_nvram_get_mac_address);
-               break;
-       }
---- a/arch/mips/bcm63xx/boards/board_common.c
-+++ b/arch/mips/bcm63xx/boards/board_common.c
-@@ -18,7 +18,6 @@
- #include <bcm63xx_dev_uart.h>
- #include <bcm63xx_regs.h>
- #include <bcm63xx_io.h>
--#include <bcm63xx_nvram.h>
- #include <bcm63xx_dev_pci.h>
- #include <bcm63xx_dev_enet.h>
- #include <bcm63xx_dev_dsp.h>
-@@ -81,15 +80,20 @@ const char *board_get_name(void)
-       return board.name;
- }
-+static int (*board_get_mac_address)(u8 mac[ETH_ALEN]);
-+
- /*
-  * setup board for device registration
-  */
--void __init board_early_setup(const struct board_info *target)
-+void __init board_early_setup(const struct board_info *target,
-+                            int (*get_mac_address)(u8 mac[ETH_ALEN]))
- {
-       u32 val;
-       memcpy(&board, target, sizeof(board));
-+      board_get_mac_address = get_mac_address;
-+
-       /* setup pin multiplexing depending on board enabled device,
-        * this has to be done this early since PCI init is done
-        * inside arch_initcall */
-@@ -162,15 +166,15 @@ int __init board_register_devices(void)
-               bcm63xx_pcmcia_register();
-       if (board.has_enet0 &&
--          !bcm63xx_nvram_get_mac_address(board.enet0.mac_addr))
-+          !board_get_mac_address(board.enet0.mac_addr))
-               bcm63xx_enet_register(0, &board.enet0);
-       if (board.has_enet1 &&
--          !bcm63xx_nvram_get_mac_address(board.enet1.mac_addr))
-+          !board_get_mac_address(board.enet1.mac_addr))
-               bcm63xx_enet_register(1, &board.enet1);
-       if (board.has_enetsw &&
--          !bcm63xx_nvram_get_mac_address(board.enetsw.mac_addr))
-+          !board_get_mac_address(board.enetsw.mac_addr))
-               bcm63xx_enetsw_register(&board.enetsw);
-       if (board.has_usbd)
-@@ -189,7 +193,7 @@ int __init board_register_devices(void)
-        * do this after registering enet devices
-        */
- #ifdef CONFIG_SSB_PCIHOST
--      if (!bcm63xx_nvram_get_mac_address(bcm63xx_sprom.il0mac)) {
-+      if (!board_get_mac_address(bcm63xx_sprom.il0mac)) {
-               memcpy(bcm63xx_sprom.et0mac, bcm63xx_sprom.il0mac, ETH_ALEN);
-               memcpy(bcm63xx_sprom.et1mac, bcm63xx_sprom.il0mac, ETH_ALEN);
-               if (ssb_arch_register_fallback_sprom(
---- a/arch/mips/bcm63xx/boards/board_common.h
-+++ b/arch/mips/bcm63xx/boards/board_common.h
-@@ -3,6 +3,7 @@
- #include <board_bcm963xx.h>
--void board_early_setup(const struct board_info *board);
-+void board_early_setup(const struct board_info *board,
-+                     int (*get_mac_address)(u8 mac[ETH_ALEN]));
- #endif /* __BOARD_COMMON_H */
diff --git a/target/linux/brcm63xx/patches-3.14/300-reset_buttons.patch b/target/linux/brcm63xx/patches-3.14/300-reset_buttons.patch
deleted file mode 100644 (file)
index 2263b49..0000000
+++ /dev/null
@@ -1,101 +0,0 @@
---- a/arch/mips/bcm63xx/boards/board_bcm963xx.c
-+++ b/arch/mips/bcm63xx/boards/board_bcm963xx.c
-@@ -10,6 +10,8 @@
- #include <linux/init.h>
- #include <linux/kernel.h>
- #include <linux/string.h>
-+#include <linux/gpio_keys.h>
-+#include <linux/input.h>
- #include <asm/addrspace.h>
- #include <bcm63xx_board.h>
- #include <bcm63xx_cpu.h>
-@@ -26,6 +28,9 @@
- #define HCS_OFFSET_128K                       0x20000
-+#define BCM963XX_KEYS_POLL_INTERVAL   20
-+#define BCM963XX_KEYS_DEBOUNCE_INTERVAL       (BCM963XX_KEYS_POLL_INTERVAL * 3)
-+
- /*
-  * known 3368 boards
-  */
---- a/arch/mips/bcm63xx/boards/board_common.c
-+++ b/arch/mips/bcm63xx/boards/board_common.c
-@@ -12,6 +12,7 @@
- #include <linux/string.h>
- #include <linux/platform_device.h>
- #include <linux/ssb/ssb.h>
-+#include <linux/gpio_keys.h>
- #include <asm/addrspace.h>
- #include <bcm63xx_board.h>
- #include <bcm63xx_cpu.h>
-@@ -32,6 +33,8 @@
- #define PFX   "board: "
-+#define BCM963XX_KEYS_POLL_INTERVAL   20
-+
- static struct board_info board;
- /*
-@@ -151,11 +154,23 @@ static struct platform_device bcm63xx_gp
-       .dev.platform_data      = &bcm63xx_led_data,
- };
-+static struct gpio_keys_platform_data bcm63xx_gpio_keys_data = {
-+      .poll_interval  = BCM963XX_KEYS_POLL_INTERVAL,
-+};
-+
-+static struct platform_device bcm63xx_gpio_keys_device = {
-+      .name           = "gpio-keys-polled",
-+      .id             = 0,
-+      .dev.platform_data = &bcm63xx_gpio_keys_data,
-+};
-+
- /*
-  * third stage init callback, register all board devices.
-  */
- int __init board_register_devices(void)
- {
-+      int button_count = 0;
-+
-       if (board.has_uart0)
-               bcm63xx_uart_register(0);
-@@ -217,5 +232,16 @@ int __init board_register_devices(void)
-               gpio_request_one(board.ephy_reset_gpio,
-                               board.ephy_reset_gpio_flags, "ephy-reset");
-+      /* count number of BUTTONs defined by this device */
-+      while (button_count < ARRAY_SIZE(board.buttons) && board.buttons[button_count].desc)
-+              button_count++;
-+
-+      if (button_count) {
-+              bcm63xx_gpio_keys_data.nbuttons = button_count;
-+              bcm63xx_gpio_keys_data.buttons = board.buttons;
-+
-+              platform_device_register(&bcm63xx_gpio_keys_device);
-+      }
-+
-       return 0;
- }
---- a/arch/mips/include/asm/mach-bcm63xx/board_bcm963xx.h
-+++ b/arch/mips/include/asm/mach-bcm63xx/board_bcm963xx.h
-@@ -3,6 +3,7 @@
- #include <linux/types.h>
- #include <linux/gpio.h>
-+#include <linux/gpio_keys.h>
- #include <linux/leds.h>
- #include <bcm63xx_dev_enet.h>
- #include <bcm63xx_dev_usb_usbd.h>
-@@ -48,6 +49,9 @@ struct board_info {
-       /* GPIO LEDs */
-       struct gpio_led leds[5];
-+      /* Buttons */
-+      struct gpio_keys_button buttons[4];
-+
-       /* External PHY reset GPIO */
-       unsigned int ephy_reset_gpio;
diff --git a/target/linux/brcm63xx/patches-3.14/301-led_count.patch b/target/linux/brcm63xx/patches-3.14/301-led_count.patch
deleted file mode 100644 (file)
index 49a1825..0000000
+++ /dev/null
@@ -1,41 +0,0 @@
---- a/arch/mips/bcm63xx/boards/board_common.c
-+++ b/arch/mips/bcm63xx/boards/board_common.c
-@@ -170,6 +170,7 @@ static struct platform_device bcm63xx_gp
- int __init board_register_devices(void)
- {
-       int button_count = 0;
-+      int led_count = 0;
-       if (board.has_uart0)
-               bcm63xx_uart_register(0);
-@@ -223,10 +224,16 @@ int __init board_register_devices(void)
-       bcm63xx_flash_register();
--      bcm63xx_led_data.num_leds = ARRAY_SIZE(board.leds);
--      bcm63xx_led_data.leds = board.leds;
-+      /* count number of LEDs defined by this device */
-+      while (led_count < ARRAY_SIZE(board.leds) && board.leds[led_count].name)
-+              led_count++;
-+
-+      if (led_count) {
-+              bcm63xx_led_data.num_leds = led_count;
-+              bcm63xx_led_data.leds = board.leds;
--      platform_device_register(&bcm63xx_gpio_leds);
-+              platform_device_register(&bcm63xx_gpio_leds);
-+      }
-       if (board.ephy_reset_gpio && board.ephy_reset_gpio_flags)
-               gpio_request_one(board.ephy_reset_gpio,
---- a/arch/mips/include/asm/mach-bcm63xx/board_bcm963xx.h
-+++ b/arch/mips/include/asm/mach-bcm63xx/board_bcm963xx.h
-@@ -47,7 +47,7 @@ struct board_info {
-       struct bcm63xx_dsp_platform_data dsp;
-       /* GPIO LEDs */
--      struct gpio_led leds[5];
-+      struct gpio_led leds[14];
-       /* Buttons */
-       struct gpio_keys_button buttons[4];
diff --git a/target/linux/brcm63xx/patches-3.14/302-extended-platform-devices.patch b/target/linux/brcm63xx/patches-3.14/302-extended-platform-devices.patch
deleted file mode 100644 (file)
index cc61cee..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
---- a/arch/mips/bcm63xx/boards/board_common.c
-+++ b/arch/mips/bcm63xx/boards/board_common.c
-@@ -222,6 +222,9 @@ int __init board_register_devices(void)
-       bcm63xx_hsspi_register();
-+      if (board.num_devs)
-+              platform_add_devices(board.devs, board.num_devs);
-+
-       bcm63xx_flash_register();
-       /* count number of LEDs defined by this device */
---- a/arch/mips/include/asm/mach-bcm63xx/board_bcm963xx.h
-+++ b/arch/mips/include/asm/mach-bcm63xx/board_bcm963xx.h
-@@ -57,6 +57,10 @@ struct board_info {
-       /* External PHY reset GPIO flags from gpio.h */
-       unsigned long ephy_reset_gpio_flags;
-+
-+      /* Additional platform devices */
-+      struct platform_device **devs;
-+      unsigned int    num_devs;
- };
- #endif /* ! BOARD_BCM963XX_H_ */
diff --git a/target/linux/brcm63xx/patches-3.14/303-spi-board-info.patch b/target/linux/brcm63xx/patches-3.14/303-spi-board-info.patch
deleted file mode 100644 (file)
index 878e626..0000000
+++ /dev/null
@@ -1,33 +0,0 @@
---- a/arch/mips/bcm63xx/boards/board_common.c
-+++ b/arch/mips/bcm63xx/boards/board_common.c
-@@ -13,6 +13,7 @@
- #include <linux/platform_device.h>
- #include <linux/ssb/ssb.h>
- #include <linux/gpio_keys.h>
-+#include <linux/spi/spi.h>
- #include <asm/addrspace.h>
- #include <bcm63xx_board.h>
- #include <bcm63xx_cpu.h>
-@@ -225,6 +226,9 @@ int __init board_register_devices(void)
-       if (board.num_devs)
-               platform_add_devices(board.devs, board.num_devs);
-+      if (board.num_spis)
-+              spi_register_board_info(board.spis, board.num_spis);
-+
-       bcm63xx_flash_register();
-       /* count number of LEDs defined by this device */
---- a/arch/mips/include/asm/mach-bcm63xx/board_bcm963xx.h
-+++ b/arch/mips/include/asm/mach-bcm63xx/board_bcm963xx.h
-@@ -61,6 +61,10 @@ struct board_info {
-       /* Additional platform devices */
-       struct platform_device **devs;
-       unsigned int    num_devs;
-+
-+      /* Additional platform devices */
-+      struct spi_board_info *spis;
-+      unsigned int    num_spis;
- };
- #endif /* ! BOARD_BCM963XX_H_ */
diff --git a/target/linux/brcm63xx/patches-3.14/309-cfe_version_mod.patch b/target/linux/brcm63xx/patches-3.14/309-cfe_version_mod.patch
deleted file mode 100644 (file)
index 42af6ae..0000000
+++ /dev/null
@@ -1,27 +0,0 @@
---- a/arch/mips/bcm63xx/boards/board_bcm963xx.c
-+++ b/arch/mips/bcm63xx/boards/board_bcm963xx.c
-@@ -727,10 +727,20 @@ void __init board_prom_init(void)
-       /* dump cfe version */
-       cfe = boot_addr + BCM963XX_CFE_VERSION_OFFSET;
--      if (!memcmp(cfe, "cfe-v", 5))
--              snprintf(cfe_version, sizeof(cfe_version), "%u.%u.%u-%u.%u",
--                       cfe[5], cfe[6], cfe[7], cfe[8], cfe[9]);
--      else
-+      if (strstarts(cfe, "cfe-")) {
-+              if(cfe[4] == 'v') {
-+                      if(cfe[5] == 'd')
-+                              snprintf(cfe_version, 11, "%s", (char *) &cfe[5]);
-+                      else if (cfe[10] > 0)
-+                              snprintf(cfe_version, sizeof(cfe_version), "%u.%u.%u-%u.%u-%u",
-+                                       cfe[5], cfe[6], cfe[7], cfe[8], cfe[9], cfe[10]);
-+                      else
-+                              snprintf(cfe_version, sizeof(cfe_version), "%u.%u.%u-%u.%u",
-+                                       cfe[5], cfe[6], cfe[7], cfe[8], cfe[9]);
-+              } else {
-+                      snprintf(cfe_version, 12, "%s", (char *) &cfe[4]);
-+              }
-+      } else
-               strcpy(cfe_version, "unknown");
-       printk(KERN_INFO PFX "CFE version: %s\n", cfe_version);
diff --git a/target/linux/brcm63xx/patches-3.14/310-cfe_simplify_detection.patch b/target/linux/brcm63xx/patches-3.14/310-cfe_simplify_detection.patch
deleted file mode 100644 (file)
index e05c91d..0000000
+++ /dev/null
@@ -1,20 +0,0 @@
---- a/arch/mips/include/asm/mach-bcm63xx/bcm63xx_board.h
-+++ b/arch/mips/include/asm/mach-bcm63xx/bcm63xx_board.h
-@@ -1,6 +1,8 @@
- #ifndef BCM63XX_BOARD_H_
- #define BCM63XX_BOARD_H_
-+#include <asm/bootinfo.h>
-+
- const char *board_get_name(void);
- void board_prom_init(void);
-@@ -9,4 +11,8 @@ void board_setup(void);
- int board_register_devices(void);
-+static inline bool bcm63xx_is_cfe_present(void) {
-+      return fw_arg3 == 0x43464531;
-+}
-+
- #endif /* ! BCM63XX_BOARD_H_ */
diff --git a/target/linux/brcm63xx/patches-3.14/311-bcm63xxpart_use_cfedetection.patch b/target/linux/brcm63xx/patches-3.14/311-bcm63xxpart_use_cfedetection.patch
deleted file mode 100644 (file)
index 46d9b47..0000000
+++ /dev/null
@@ -1,51 +0,0 @@
---- a/drivers/mtd/bcm63xxpart.c
-+++ b/drivers/mtd/bcm63xxpart.c
-@@ -35,7 +35,7 @@
- #include <asm/mach-bcm63xx/bcm63xx_nvram.h>
- #include <asm/mach-bcm63xx/bcm963xx_tag.h>
--#include <asm/mach-bcm63xx/board_bcm963xx.h>
-+#include <asm/mach-bcm63xx/bcm63xx_board.h>
- #define BCM63XX_EXTENDED_SIZE 0xBFC00000      /* Extended flash address */
-@@ -43,30 +43,6 @@
- #define BCM63XX_CFE_MAGIC_OFFSET 0x4e0
--static int bcm63xx_detect_cfe(struct mtd_info *master)
--{
--      char buf[9];
--      int ret;
--      size_t retlen;
--
--      ret = mtd_read(master, BCM963XX_CFE_VERSION_OFFSET, 5, &retlen,
--                     (void *)buf);
--      buf[retlen] = 0;
--
--      if (ret)
--              return ret;
--
--      if (strncmp("cfe-v", buf, 5) == 0)
--              return 0;
--
--      /* very old CFE's do not have the cfe-v string, so check for magic */
--      ret = mtd_read(master, BCM63XX_CFE_MAGIC_OFFSET, 8, &retlen,
--                     (void *)buf);
--      buf[retlen] = 0;
--
--      return strncmp("CFE1CFE1", buf, 8);
--}
--
- static int bcm63xx_parse_cfe_partitions(struct mtd_info *master,
-                                       struct mtd_partition **pparts,
-                                       struct mtd_part_parser_data *data)
-@@ -85,7 +61,7 @@ static int bcm63xx_parse_cfe_partitions(
-       u32 computed_crc;
-       bool rootfs_first = false;
--      if (bcm63xx_detect_cfe(master))
-+      if (!bcm63xx_is_cfe_present())
-               return -EINVAL;
-       cfe_erasesize = max_t(uint32_t, master->erasesize,
diff --git a/target/linux/brcm63xx/patches-3.14/320-irqchip-add-support-for-bcm6345-style-periphery-irq-.patch b/target/linux/brcm63xx/patches-3.14/320-irqchip-add-support-for-bcm6345-style-periphery-irq-.patch
deleted file mode 100644 (file)
index 8219c98..0000000
+++ /dev/null
@@ -1,457 +0,0 @@
-From 7aaa70416d87434792b73077beb328202975e541 Mon Sep 17 00:00:00 2001
-From: Jonas Gorski <jogo@openwrt.org>
-Date: Sun, 30 Nov 2014 14:53:12 +0100
-Subject: [PATCH 1/5] irqchip: add support for bcm6345-style periphery irq
- controller
-
-Signed-off-by: Jonas Gorski <jogo@openwrt.org>
----
- .../brcm,bcm6345-periph-intc.txt                   |   50 +++
- drivers/irqchip/Kconfig                            |    4 +
- drivers/irqchip/Makefile                           |    1 +
- drivers/irqchip/irq-bcm6345-periph.c               |  325 ++++++++++++++++++++
- include/linux/irqchip/irq-bcm6345-periph.h         |   16 +
- 5 files changed, 396 insertions(+)
- create mode 100644 Documentation/devicetree/bindings/interrupt-controller/brcm,bcm6345-periph-intc.txt
- create mode 100644 drivers/irqchip/irq-bcm6345-periph.c
- create mode 100644 include/linux/irqchip/irq-bcm6345-periph.h
-
---- /dev/null
-+++ b/Documentation/devicetree/bindings/interrupt-controller/brcm,bcm6345-periph-intc.txt
-@@ -0,0 +1,50 @@
-+Broadcom BCM6345 Level 1 periphery interrupt controller
-+
-+This block is a  interrupt controller that is typically connected directly
-+to one of the HW INT lines on each CPU.  Every BCM63XX xDSL chip since
-+BCM6345 has contained this hardware.
-+
-+Key elements of the hardware design include:
-+
-+- 32, 64, or 128 incoming level IRQ lines
-+
-+- All onchip peripherals are wired directly to an L2 input
-+
-+- A separate instance of the register set for each CPU, allowing individual
-+  peripheral IRQs to be routed to any CPU
-+
-+- No atomic mask/unmask operations
-+
-+- No polarity/level/edge settings
-+
-+- No FIFO or priority encoder logic; software is expected to read all
-+  1-4 status words to determine which IRQs are pending
-+
-+Required properties:
-+
-+- compatible: Should be "brcm,bcm6345-periph-intc".
-+- reg: Specifies the base physical address and size of the registers.
-+  Multiple register addresses may be specified, and must match the amount of
-+  parent interrupts.
-+- interrupt-controller: Identifies the node as an interrupt controller.
-+- #interrupt-cells: Specifies the number of cells needed to encode an interrupt
-+  source, should be 1.
-+- interrupt-parent: Specifies the phandle to the parent interrupt controller
-+  this one is cascaded from.
-+- interrupts: Specifies the interrupt line(s) in the interrupt-parent controller
-+  node, valid values depend on the type of parent interrupt controller.
-+  Multiple lines are used to route interrupts to different cpus, with the first
-+  assumed to be for the boot CPU.
-+
-+Example:
-+
-+periph_intc: interrupt-controller@f0406800 {
-+      compatible = "brcm,bcm6345-periph-intc";
-+      reg = <0x10000020 0x10>, <0x10000030 0x10>;
-+
-+      interrupt-controller;
-+      #interrupt-cells = <1>;
-+
-+      interrupt-parent = <&cpu_intc>;
-+      interrupts = <2>, <3>;
-+};
---- a/drivers/irqchip/Kconfig
-+++ b/drivers/irqchip/Kconfig
-@@ -30,6 +30,10 @@ config ARM_VIC_NR
-         The maximum number of VICs available in the system, for
-         power management.
-+config BCM6345_PERIPH_IRQ
-+      bool
-+      select IRQ_DOMAIN
-+
- config DW_APB_ICTL
-       bool
-       select IRQ_DOMAIN
---- a/drivers/irqchip/Makefile
-+++ b/drivers/irqchip/Makefile
-@@ -6,6 +6,7 @@ obj-$(CONFIG_ARCH_MMP)                 += irq-mmp.o
- obj-$(CONFIG_ARCH_MVEBU)              += irq-armada-370-xp.o
- obj-$(CONFIG_ARCH_MXS)                        += irq-mxs.o
- obj-$(CONFIG_ARCH_S3C24XX)            += irq-s3c24xx.o
-+obj-$(CONFIG_BCM6345_PERIPH_IRQ)      += irq-bcm6345-periph.o
- obj-$(CONFIG_DW_APB_ICTL)             += irq-dw-apb-ictl.o
- obj-$(CONFIG_METAG)                   += irq-metag-ext.o
- obj-$(CONFIG_METAG_PERFCOUNTER_IRQS)  += irq-metag.o
---- /dev/null
-+++ b/drivers/irqchip/irq-bcm6345-periph.c
-@@ -0,0 +1,341 @@
-+/*
-+ * This file is subject to the terms and conditions of the GNU General Public
-+ * License.  See the file "COPYING" in the main directory of this archive
-+ * for more details.
-+ *
-+ * Copyright (C) 2014 Jonas Gorski <jogo@openwrt.org>
-+ */
-+
-+#include <linux/ioport.h>
-+#include <linux/irq.h>
-+#include <linux/irqchip/chained_irq.h>
-+#include <linux/irqchip/irq-bcm6345-periph.h>
-+#include <linux/kernel.h>
-+#include <linux/of.h>
-+#include <linux/of_irq.h>
-+#include <linux/of_address.h>
-+#include <linux/slab.h>
-+#include <linux/spinlock.h>
-+
-+#ifdef CONFIG_BCM63XX
-+#include <asm/mach-bcm63xx/bcm63xx_irq.h>
-+
-+#define VIRQ_BASE     IRQ_INTERNAL_BASE
-+#else
-+#define VIRQ_BASE     0
-+#endif
-+
-+#include "irqchip.h"
-+
-+#define MAX_WORDS     4
-+#define MAX_PARENT_IRQS       2
-+#define IRQS_PER_WORD 32
-+
-+struct intc_block {
-+      int parent_irq;
-+      void __iomem *base;
-+      void __iomem *en_reg[MAX_WORDS];
-+      void __iomem *status_reg[MAX_WORDS];
-+      u32 mask_cache[MAX_WORDS];
-+};
-+
-+struct intc_data {
-+      struct irq_chip chip;
-+      struct intc_block block[MAX_PARENT_IRQS];
-+
-+      int num_words;
-+
-+      struct irq_domain *domain;
-+      raw_spinlock_t lock;
-+};
-+
-+static void bcm6345_periph_irq_handle(unsigned int irq, struct irq_desc *desc)
-+{
-+      struct intc_data *data = irq_desc_get_handler_data(desc);
-+      struct irq_chip *chip = irq_desc_get_chip(desc);
-+      struct intc_block *block;
-+      unsigned int idx;
-+
-+      chained_irq_enter(chip, desc);
-+
-+      for (idx = 0; idx < MAX_PARENT_IRQS; idx++)
-+              if (irq == data->block[idx].parent_irq)
-+                      block = &data->block[idx];
-+
-+      for (idx = 0; idx < data->num_words; idx++) {
-+              int base = idx * IRQS_PER_WORD;
-+              unsigned long pending;
-+              int hw_irq;
-+
-+              raw_spin_lock(&data->lock);
-+              pending = __raw_readl(block->en_reg[idx]) &
-+                        __raw_readl(block->status_reg[idx]);
-+              raw_spin_unlock(&data->lock);
-+
-+              for_each_set_bit(hw_irq, &pending, IRQS_PER_WORD) {
-+                      int virq;
-+
-+                      virq  = irq_find_mapping(data->domain, base + hw_irq);
-+                      generic_handle_irq(virq);
-+              }
-+      }
-+
-+      chained_irq_exit(chip, desc);
-+}
-+
-+static void __bcm6345_periph_enable(struct intc_block *block, int reg, int bit,
-+                                  bool enable)
-+{
-+      u32 val;
-+
-+      val = __raw_readl(block->en_reg[reg]);
-+      if (enable)
-+              val |= BIT(bit);
-+      else
-+              val &= ~BIT(bit);
-+      __raw_writel(val, block->en_reg[reg]);
-+}
-+
-+static void bcm6345_periph_irq_mask(struct irq_data *data)
-+{
-+      unsigned int i, reg, bit;
-+      struct intc_data *priv = data->domain->host_data;
-+      irq_hw_number_t hwirq = irqd_to_hwirq(data);
-+
-+      reg = hwirq / IRQS_PER_WORD;
-+      bit = hwirq % IRQS_PER_WORD;
-+
-+      raw_spin_lock(&priv->lock);
-+      for (i = 0; i < MAX_PARENT_IRQS; i++) {
-+              struct intc_block *block = &priv->block[i];
-+
-+              if (!block->parent_irq)
-+                      break;
-+
-+              __bcm6345_periph_enable(block, reg, bit, false);
-+      }
-+      raw_spin_unlock(&priv->lock);
-+}
-+
-+static void bcm6345_periph_irq_unmask(struct irq_data *data)
-+{
-+      struct intc_data *priv = data->domain->host_data;
-+      irq_hw_number_t hwirq = irqd_to_hwirq(data);
-+      unsigned int i, reg, bit;
-+
-+      reg = hwirq / IRQS_PER_WORD;
-+      bit = hwirq % IRQS_PER_WORD;
-+
-+      raw_spin_lock(&priv->lock);
-+      for (i = 0; i < MAX_PARENT_IRQS; i++) {
-+              struct intc_block *block = &priv->block[i];
-+
-+              if (!block->parent_irq)
-+                      break;
-+
-+              if (block->mask_cache[reg] & BIT(bit))
-+                      __bcm6345_periph_enable(block, reg, bit, true);
-+              else
-+                      __bcm6345_periph_enable(block, reg, bit, false);
-+
-+      }
-+      raw_spin_unlock(&priv->lock);
-+}
-+
-+#ifdef CONFIG_SMP
-+static int bcm6345_periph_set_affinity(struct irq_data *data,
-+                                     const struct cpumask *mask, bool force)
-+{
-+      irq_hw_number_t hwirq = irqd_to_hwirq(data);
-+      struct intc_data *priv = data->domain->host_data;
-+      unsigned int i, reg, bit;
-+      unsigned long flags;
-+      bool enabled;
-+      int cpu;
-+
-+      reg = hwirq / IRQS_PER_WORD;
-+      bit = hwirq % IRQS_PER_WORD;
-+
-+      /* we could route to more than one cpu, but performance
-+         suffers, so fix it to one.
-+       */
-+      cpu = cpumask_any_and(mask, cpu_online_mask);
-+      if (cpu >= nr_cpu_ids)
-+              return -EINVAL;
-+
-+      if (cpu >= MAX_PARENT_IRQS)
-+              return -EINVAL;
-+
-+      if (!priv->block[cpu].parent_irq)
-+              return -EINVAL;
-+
-+      raw_spin_lock_irqsave(&priv->lock, flags);
-+      enabled = !irqd_irq_masked(data);
-+      for (i = 0; i < MAX_PARENT_IRQS; i++) {
-+              struct intc_block *block = &priv->block[i];
-+
-+              if (!block->parent_irq)
-+                      break;
-+
-+              if (i == cpu) {
-+                      block->mask_cache[reg] |= BIT(bit);
-+                      __bcm6345_periph_enable(block, reg, bit, enabled);
-+              } else {
-+                      block->mask_cache[reg] &= ~BIT(bit);
-+                      __bcm6345_periph_enable(block, reg, bit, false);
-+              }
-+      }
-+      raw_spin_unlock_irqrestore(&priv->lock, flags);
-+
-+      return 0;
-+}
-+#endif
-+
-+static int bcm6345_periph_map(struct irq_domain *d, unsigned int irq,
-+                            irq_hw_number_t hw)
-+{
-+      struct intc_data *priv = d->host_data;
-+
-+      irq_set_chip_and_handler(irq, &priv->chip, handle_level_irq);
-+
-+      return 0;
-+}
-+
-+static const struct irq_domain_ops bcm6345_periph_domain_ops = {
-+      .xlate = irq_domain_xlate_onecell,
-+      .map = bcm6345_periph_map,
-+};
-+
-+static int __init __bcm6345_periph_intc_init(struct device_node *node,
-+                                           int num_blocks, int *irq,
-+                                           void __iomem **base, int num_words)
-+{
-+      struct intc_data *data;
-+      unsigned int i, w, status_offset;
-+
-+      data = kzalloc(sizeof(*data), GFP_KERNEL);
-+      if (!data)
-+              return -ENOMEM;
-+
-+      raw_spin_lock_init(&data->lock);
-+
-+      status_offset = num_words * sizeof(u32);
-+
-+      for (i = 0; i < num_blocks; i++) {
-+              struct intc_block *block = &data->block[i];
-+
-+              block->parent_irq = irq[i];
-+              block->base = base[i];
-+
-+              for (w = 0; w < num_words; w++) {
-+                      int word_offset = sizeof(u32) * ((num_words - w) - 1);
-+
-+                      block->en_reg[w] = base[i] + word_offset;
-+                      block->status_reg[w] = base[i] + status_offset;
-+                      block->status_reg[w] += word_offset;
-+
-+                      /* route all interrups to line 0 by default */
-+                      if (i == 0)
-+                              block->mask_cache[w] = 0xffffffff;
-+              }
-+
-+              irq_set_handler_data(block->parent_irq, data);
-+              irq_set_chained_handler(block->parent_irq,
-+                                      bcm6345_periph_irq_handle);
-+      }
-+
-+      data->num_words = num_words;
-+
-+      data->chip.name = "bcm6345-periph-intc";
-+      data->chip.irq_mask = bcm6345_periph_irq_mask;
-+      data->chip.irq_unmask = bcm6345_periph_irq_unmask;
-+
-+#ifdef CONFIG_SMP
-+      if (num_blocks > 1)
-+              data->chip.irq_set_affinity = bcm6345_periph_set_affinity;
-+#endif
-+
-+      data->domain = irq_domain_add_simple(node, IRQS_PER_WORD * num_words,
-+                                           VIRQ_BASE,
-+                                           &bcm6345_periph_domain_ops, data);
-+      if (!data->domain) {
-+              kfree(data);
-+              return -EINVAL;
-+      }
-+
-+      return 0;
-+}
-+
-+void __init bcm6345_periph_intc_init(int num_blocks, int *irq,
-+                                   void __iomem **base, int num_words)
-+{
-+      __bcm6345_periph_intc_init(NULL, num_blocks, irq, base, num_words);
-+}
-+
-+#ifdef CONFIG_OF
-+static int __init bcm6345_periph_of_init(struct device_node *node,
-+                                       struct device_node *parent)
-+{
-+      struct resource res;
-+      int num_irqs, ret = -EINVAL;
-+      int irqs[MAX_PARENT_IRQS] = { 0 };
-+      void __iomem *bases[MAX_PARENT_IRQS] = { NULL };
-+      int words = 0;
-+      int i;
-+
-+      num_irqs = of_irq_count(node);
-+
-+      if (num_irqs < 1 || num_irqs > MAX_PARENT_IRQS)
-+              return -EINVAL;
-+
-+      for (i = 0; i < num_irqs; i++) {
-+              resource_size_t size;
-+
-+              irqs[i] = irq_of_parse_and_map(node, i);
-+              if (!irqs[i])
-+                      goto out_unmap;
-+
-+              if (of_address_to_resource(node, i, &res)) {
-+                      goto out_unmap;
-+              }
-+
-+              size = resource_size(&res);
-+              switch (size) {
-+                      case 8:
-+                      case 16:
-+                      case 32:
-+                              size = size / 8;
-+                              break;
-+                      default:
-+                              goto out_unmap;
-+              }
-+
-+              if (words && words != size) {
-+                      ret = -EINVAL;
-+                      goto out_unmap;
-+              }
-+              words = size;
-+
-+              bases[i] = of_iomap(node, i);
-+              if (!bases[i]) {
-+                      ret = -ENOMEM;
-+                      goto out_unmap;
-+              }
-+      }
-+
-+      ret = __bcm6345_periph_intc_init(node, num_irqs, irqs, bases, words);
-+      if (!ret)
-+              return 0;
-+
-+out_unmap:
-+      for (i = 0; i < num_irqs; i++) {
-+              iounmap(bases[i]);
-+              irq_dispose_mapping(irqs[i]);
-+      }
-+
-+      return ret;
-+}
-+
-+IRQCHIP_DECLARE(bcm6345_periph_intc, "brcm,bcm6345-periph-intc",
-+              bcm6345_periph_of_init);
-+#endif
---- /dev/null
-+++ b/include/linux/irqchip/irq-bcm6345-periph.h
-@@ -0,0 +1,16 @@
-+/*
-+ * This file is subject to the terms and conditions of the GNU General Public
-+ * License.  See the file "COPYING" in the main directory of this archive
-+ * for more details.
-+ *
-+ * Copyright (C) 2008 Maxime Bizon <mbizon@freebox.fr>
-+ * Copyright (C) 2008 Nicolas Schichan <nschichan@freebox.fr>
-+ */
-+
-+#ifndef __INCLUDE_LINUX_IRQCHIP_IRQ_BCM6345_PERIPH_H
-+#define __INCLUDE_LINUX_IRQCHIP_IRQ_BCM6345_PERIPH_H
-+
-+void bcm6345_periph_intc_init(int num_blocks, int *irq, void __iomem **base,
-+                            int num_words);
-+
-+#endif /* __INCLUDE_LINUX_IRQCHIP_IRQ_BCM6345_PERIPH_H */
diff --git a/target/linux/brcm63xx/patches-3.14/321-irqchip-add-support-for-bcm6345-style-external-inter.patch b/target/linux/brcm63xx/patches-3.14/321-irqchip-add-support-for-bcm6345-style-external-inter.patch
deleted file mode 100644 (file)
index 964d9fc..0000000
+++ /dev/null
@@ -1,381 +0,0 @@
-From ac60253478d58fc73b4c0a390eb6229222460e8a Mon Sep 17 00:00:00 2001
-From: Jonas Gorski <jogo@openwrt.org>
-Date: Sun, 30 Nov 2014 14:54:27 +0100
-Subject: [PATCH 2/5] irqchip: add support for bcm6345-style external
- interrupt controller
-
-Signed-off-by: Jonas Gorski <jogo@openwrt.org>
----
- .../interrupt-controller/brcm,bcm6345-ext-intc.txt |   29 ++
- drivers/irqchip/Kconfig                            |    4 +
- drivers/irqchip/Makefile                           |    1 +
- drivers/irqchip/irq-bcm6345-ext.c                  |  286 ++++++++++++++++++++
- include/linux/irqchip/irq-bcm6345-ext.h            |   14 +
- 5 files changed, 334 insertions(+)
- create mode 100644 Documentation/devicetree/bindings/interrupt-controller/brcm,bcm6345-ext-intc.txt
- create mode 100644 drivers/irqchip/irq-bcm6345-ext.c
- create mode 100644 include/linux/irqchip/irq-bcm6345-ext.h
-
---- /dev/null
-+++ b/Documentation/devicetree/bindings/interrupt-controller/brcm,bcm6345-ext-intc.txt
-@@ -0,0 +1,29 @@
-+Broadcom BCM6345-style external interrupt controller
-+
-+Required properties:
-+
-+- compatible: Should be "brcm,bcm6345-l2-intc".
-+- reg: Specifies the base physical addresses and size of the registers. 
-+- interrupt-controller: identifies the node as an interrupt controller.
-+- #interrupt-cells: Specifies the number of cells needed to encode an interrupt
-+  source, Should be 2.
-+- interrupt-parent: Specifies the phandle to the parent interrupt controller
-+  this one is cascaded from.
-+- interrupts: Specifies the interrupt line(s) in the interrupt-parent controller
-+  node, valid values depend on the type of parent interrupt controller.
-+
-+Optional properties:
-+
-+- brcm,field-width: Size of each field (mask, clear, sense, ...) in bits in the
-+  register. Defaults to 4.
-+
-+Example:
-+
-+ext_intc: interrupt-controller@10000018 {
-+      compatible = "brcm,bcm6345-l2-intc";
-+      interrupt-parent = <&periph_intc>;
-+      #interrupt-cells = <2>;
-+      reg = <0x10000018 0x4>;
-+      interrupt-controller;
-+      interrupts = <24>, <25>, <26>, <27>;
-+};
---- a/drivers/irqchip/Kconfig
-+++ b/drivers/irqchip/Kconfig
-@@ -30,6 +30,10 @@ config ARM_VIC_NR
-         The maximum number of VICs available in the system, for
-         power management.
-+config BCM6345_EXT_IRQ
-+      bool
-+      select IRQ_DOMAIN
-+
- config BCM6345_PERIPH_IRQ
-       bool
-       select IRQ_DOMAIN
---- a/drivers/irqchip/Makefile
-+++ b/drivers/irqchip/Makefile
-@@ -6,6 +6,7 @@ obj-$(CONFIG_ARCH_MMP)                 += irq-mmp.o
- obj-$(CONFIG_ARCH_MVEBU)              += irq-armada-370-xp.o
- obj-$(CONFIG_ARCH_MXS)                        += irq-mxs.o
- obj-$(CONFIG_ARCH_S3C24XX)            += irq-s3c24xx.o
-+obj-$(CONFIG_BCM6345_EXT_IRQ)         += irq-bcm6345-ext.o
- obj-$(CONFIG_BCM6345_PERIPH_IRQ)      += irq-bcm6345-periph.o
- obj-$(CONFIG_DW_APB_ICTL)             += irq-dw-apb-ictl.o
- obj-$(CONFIG_METAG)                   += irq-metag-ext.o
---- /dev/null
-+++ b/drivers/irqchip/irq-bcm6345-ext.c
-@@ -0,0 +1,288 @@
-+/*
-+ * This file is subject to the terms and conditions of the GNU General Public
-+ * License.  See the file "COPYING" in the main directory of this archive
-+ * for more details.
-+ *
-+ * Copyright (C) 2014 Jonas Gorski <jogo@openwrt.org>
-+i */
-+
-+#include <linux/ioport.h>
-+#include <linux/irq.h>
-+#include <linux/irqchip/chained_irq.h>
-+#include <linux/irqchip/irq-bcm6345-ext.h>
-+#include <linux/kernel.h>
-+#include <linux/of.h>
-+#include <linux/of_irq.h>
-+#include <linux/of_address.h>
-+#include <linux/slab.h>
-+#include <linux/spinlock.h>
-+
-+#include "irqchip.h"
-+
-+#ifdef CONFIG_BCM63XX
-+#include <asm/mach-bcm63xx/bcm63xx_irq.h>
-+
-+#define VIRQ_BASE             IRQ_EXTERNAL_BASE
-+#else
-+#define VIRQ_BASE             0
-+#endif
-+
-+#define MAX_IRQS              4
-+
-+#define EXTIRQ_CFG_SENSE      0
-+#define EXTIRQ_CFG_STAT               1
-+#define EXTIRQ_CFG_CLEAR      2
-+#define EXTIRQ_CFG_MASK               3
-+#define EXTIRQ_CFG_BOTHEDGE   4
-+#define EXTIRQ_CFG_LEVELSENSE 5
-+
-+struct intc_data {
-+      struct irq_chip chip;
-+      struct irq_domain *domain;
-+      raw_spinlock_t lock;
-+
-+      int parent_irq[MAX_IRQS];
-+      void __iomem *reg;
-+      int shift;
-+};
-+
-+static void bcm6345_ext_intc_irq_handle(unsigned int irq, struct irq_desc *desc)
-+{
-+      struct intc_data *data = irq_desc_get_handler_data(desc);
-+      struct irq_chip *chip = irq_desc_get_chip(desc);
-+      unsigned int idx;
-+
-+      chained_irq_enter(chip, desc);
-+
-+      for (idx = 0; idx < MAX_IRQS; idx++) {
-+              if (data->parent_irq[idx] != irq)
-+                      continue;
-+
-+              generic_handle_irq(irq_find_mapping(data->domain, idx));
-+      }
-+
-+      chained_irq_exit(chip, desc);
-+}
-+
-+static void bcm6345_ext_intc_irq_ack(struct irq_data *data)
-+{
-+      struct intc_data *priv = data->domain->host_data;
-+      irq_hw_number_t hwirq = irqd_to_hwirq(data);
-+      u32 reg;
-+
-+      raw_spin_lock(&priv->lock);
-+      reg = __raw_readl(priv->reg);
-+      reg |= hwirq << (EXTIRQ_CFG_CLEAR * priv->shift);
-+      __raw_writel(reg, priv->reg);
-+      raw_spin_unlock(&priv->lock);
-+}
-+
-+static void bcm6345_ext_intc_irq_mask(struct irq_data *data)
-+{
-+      struct intc_data *priv = data->domain->host_data;
-+      irq_hw_number_t hwirq = irqd_to_hwirq(data);
-+      u32 reg;
-+
-+      raw_spin_lock(&priv->lock);
-+      reg = __raw_readl(priv->reg);
-+      reg &= ~(hwirq << (EXTIRQ_CFG_MASK * priv->shift));
-+      __raw_writel(reg, priv->reg);
-+      raw_spin_unlock(&priv->lock);
-+}
-+
-+static void bcm6345_ext_intc_irq_unmask(struct irq_data *data)
-+{
-+      struct intc_data *priv = data->domain->host_data;
-+      irq_hw_number_t hwirq = irqd_to_hwirq(data);
-+      u32 reg;
-+
-+      raw_spin_lock(&priv->lock);
-+      reg = __raw_readl(priv->reg);
-+      reg |= hwirq << (EXTIRQ_CFG_MASK * priv->shift);
-+      __raw_writel(reg, priv->reg);
-+      raw_spin_unlock(&priv->lock);
-+}
-+
-+static int bcm6345_ext_intc_set_type(struct irq_data *data,
-+                                   unsigned int flow_type)
-+{
-+      struct intc_data *priv = data->domain->host_data;
-+      irq_hw_number_t hwirq = irqd_to_hwirq(data);
-+      bool levelsense = 0, sense = 0, bothedge = 0;
-+      u32 reg;
-+
-+      flow_type &= IRQ_TYPE_SENSE_MASK;
-+
-+      if (flow_type == IRQ_TYPE_NONE)
-+              flow_type = IRQ_TYPE_LEVEL_LOW;
-+
-+      switch (flow_type) {
-+      case IRQ_TYPE_EDGE_BOTH:
-+              bothedge = 1;
-+              break;
-+
-+      case IRQ_TYPE_EDGE_RISING:
-+              break;
-+
-+      case IRQ_TYPE_EDGE_FALLING:
-+              sense = 1;
-+              break;
-+
-+      case IRQ_TYPE_LEVEL_HIGH:
-+              levelsense = 1;
-+              sense = 1;
-+              break;
-+
-+      case IRQ_TYPE_LEVEL_LOW:
-+              levelsense = 1;
-+              break;
-+
-+      default:
-+              pr_err("bogus flow type combination given!\n");
-+              return -EINVAL;
-+      }
-+
-+      raw_spin_lock(&priv->lock);
-+      reg = __raw_readl(priv->reg);
-+
-+      if (levelsense)
-+              reg |= hwirq << (EXTIRQ_CFG_LEVELSENSE * priv->shift);
-+      else
-+              reg &= ~(hwirq << (EXTIRQ_CFG_LEVELSENSE * priv->shift));
-+      if (sense)
-+              reg |= hwirq << (EXTIRQ_CFG_SENSE * priv->shift);
-+      else
-+              reg &= ~(hwirq << (EXTIRQ_CFG_SENSE * priv->shift));
-+      if (bothedge)
-+              reg |= hwirq << (EXTIRQ_CFG_BOTHEDGE * priv->shift);
-+      else
-+              reg &= ~(hwirq << (EXTIRQ_CFG_BOTHEDGE * priv->shift));
-+
-+      __raw_writel(reg, priv->reg);
-+      raw_spin_unlock(&priv->lock);
-+
-+      irqd_set_trigger_type(data, flow_type);
-+      if (flow_type & (IRQ_TYPE_LEVEL_LOW | IRQ_TYPE_LEVEL_HIGH))
-+              __irq_set_handler_locked(data->irq, handle_level_irq);
-+      else
-+              __irq_set_handler_locked(data->irq, handle_edge_irq);
-+
-+      return 0;
-+}
-+
-+static int bcm6345_ext_intc_map(struct irq_domain *d, unsigned int irq,
-+                        irq_hw_number_t hw)
-+{
-+      struct intc_data *priv = d->host_data;
-+
-+      irq_set_chip_and_handler(irq, &priv->chip, handle_level_irq);
-+
-+      return 0;
-+}
-+
-+
-+static const struct irq_domain_ops bcm6345_ext_domain_ops = {
-+      .xlate = irq_domain_xlate_twocell,
-+      .map = bcm6345_ext_intc_map,
-+};
-+
-+static int __init __bcm6345_ext_intc_init(struct device_node *node,
-+                                        int num_irqs, int *irqs,
-+                                        void __iomem *reg, int shift)
-+{
-+      struct intc_data *data;
-+      unsigned int i;
-+      int start = VIRQ_BASE;
-+
-+      data = kzalloc(sizeof(*data), GFP_KERNEL);
-+      if (!data)
-+              return -ENOMEM;
-+
-+      raw_spin_lock_init(&data->lock);
-+
-+      for (i = 0; i < num_irqs; i++) {
-+              data->parent_irq[i] = irqs[i];
-+
-+              irq_set_handler_data(irqs[i], data);
-+              irq_set_chained_handler(irqs[i], bcm6345_ext_intc_irq_handle);
-+      }
-+
-+      data->reg = reg;
-+
-+      data->chip.name = "bcm6345-ext-intc";
-+      data->chip.irq_ack = bcm6345_ext_intc_irq_ack;
-+      data->chip.irq_mask = bcm6345_ext_intc_irq_mask;
-+      data->chip.irq_unmask = bcm6345_ext_intc_irq_unmask;
-+      data->chip.irq_set_type = bcm6345_ext_intc_set_type;
-+
-+      /*
-+       * If we have less than 4 irqs, this is the second controller on
-+       * bcm63xx. So increase the VIRQ start to not overlap with the first
-+       * one, but only do so if we actually use a non-zero start.
-+       *
-+       * This can be removed when bcm63xx has no legacy users anymore.
-+       */
-+      if (start && num_irqs < 4)
-+              start += 4;
-+
-+      data->domain = irq_domain_add_simple(node, num_irqs, start,
-+                                           &bcm6345_ext_domain_ops, data);
-+      if (!data->domain) {
-+              kfree(data);
-+              return -ENOMEM;
-+      }
-+
-+      return 0;
-+}
-+
-+void __init bcm6345_ext_intc_init(int num_irqs, int *irqs, void __iomem *reg,
-+                                int shift)
-+{
-+      __bcm6345_ext_intc_init(NULL, num_irqs, irqs, reg, shift);
-+}
-+
-+#ifdef CONFIG_OF
-+static int __init bcm6345_ext_intc_of_init(struct device_node *node,
-+                                         struct device_node *parent)
-+{
-+      int num_irqs, ret = -EINVAL;
-+      unsigned i;
-+      void __iomem *base;
-+      int irqs[MAX_IRQS] = { 0 };
-+      u32 shift;
-+
-+      num_irqs = of_irq_count(node);
-+
-+      if (!num_irqs || num_irqs > MAX_IRQS)
-+              return -EINVAL;
-+
-+      if (of_property_read_u32(node, "brcm,field-width", &shift))
-+              shift = 4;
-+
-+      for (i = 0; i < num_irqs; i++) {
-+              irqs[i] = irq_of_parse_and_map(node, i);
-+              if (!irqs[i]) {
-+                      ret = -ENOMEM;
-+                      goto out_unmap;
-+              }
-+      }
-+
-+      base = of_iomap(node, 0);
-+      if (!base)
-+              goto out_unmap;
-+
-+      ret = __bcm6345_ext_intc_init(node, num_irqs, irqs, base, shift);
-+      if (!ret)
-+              return 0;
-+out_unmap:
-+      iounmap(base);
-+
-+      for (i = 0; i < num_irqs; i++)
-+              irq_dispose_mapping(irqs[i]);
-+
-+      return ret;
-+}
-+
-+IRQCHIP_DECLARE(bcm6345_ext_intc, "brcm,bcm6345-ext-intc",
-+              bcm6345_ext_intc_of_init);
-+#endif
---- /dev/null
-+++ b/include/linux/irqchip/irq-bcm6345-ext.h
-@@ -0,0 +1,14 @@
-+/*
-+ * This file is subject to the terms and conditions of the GNU General Public
-+ * License.  See the file "COPYING" in the main directory of this archive
-+ * for more details.
-+ *
-+ * Copyright (C) 2014 Jonas Gorski <jogo@openwrt.org>
-+ */
-+
-+#ifndef __INCLUDE_LINUX_IRQCHIP_IRQ_BCM6345_EXT_H
-+#define __INCLUDE_LINUX_IRQCHIP_IRQ_BCM6345_EXT_H
-+
-+void bcm6345_ext_intc_init(int n_irqs, int *irqs, void __iomem *reg, int shift);
-+
-+#endif /* __INCLUDE_LINUX_IRQCHIP_IRQ_BCM6345_EXT_H */
diff --git a/target/linux/brcm63xx/patches-3.14/322-MIPS-BCM63XX-switch-to-IRQ_DOMAIN.patch b/target/linux/brcm63xx/patches-3.14/322-MIPS-BCM63XX-switch-to-IRQ_DOMAIN.patch
deleted file mode 100644 (file)
index 7f3682c..0000000
+++ /dev/null
@@ -1,694 +0,0 @@
-From d93661c9e164ccc41820eeb4f1881e59a34a9e5c Mon Sep 17 00:00:00 2001
-From: Jonas Gorski <jogo@openwrt.org>
-Date: Sun, 30 Nov 2014 14:55:02 +0100
-Subject: [PATCH 19/20] MIPS: BCM63XX: switch to IRQ_DOMAIN
-
-Now that we have working IRQ_DOMAIN drivers for both interrupt controllers,
-switch to using them.
-
-Signed-off-by: Jonas Gorski <jogo@openwrt.org>
----
- arch/mips/Kconfig       |    3 +
- arch/mips/bcm63xx/irq.c |  608 ++++++++---------------------------------------
- 2 files changed, 108 insertions(+), 503 deletions(-)
-
---- a/arch/mips/Kconfig
-+++ b/arch/mips/Kconfig
-@@ -135,6 +135,9 @@ config BCM63XX
-       select SYNC_R4K
-       select DMA_NONCOHERENT
-       select IRQ_CPU
-+      select BCM6345_EXT_IRQ
-+      select BCM6345_PERIPH_IRQ
-+      select IRQ_DOMAIN
-       select SYS_SUPPORTS_32BIT_KERNEL
-       select SYS_SUPPORTS_BIG_ENDIAN
-       select SYS_HAS_EARLY_PRINTK
---- a/arch/mips/bcm63xx/irq.c
-+++ b/arch/mips/bcm63xx/irq.c
-@@ -12,7 +12,9 @@
- #include <linux/interrupt.h>
- #include <linux/module.h>
- #include <linux/irq.h>
--#include <linux/spinlock.h>
-+#include <linux/irqchip.h>
-+#include <linux/irqchip/irq-bcm6345-ext.h>
-+#include <linux/irqchip/irq-bcm6345-periph.h>
- #include <asm/irq_cpu.h>
- #include <asm/mipsregs.h>
- #include <bcm63xx_cpu.h>
-@@ -20,544 +22,144 @@
- #include <bcm63xx_io.h>
- #include <bcm63xx_irq.h>
--
--static DEFINE_SPINLOCK(ipic_lock);
--static DEFINE_SPINLOCK(epic_lock);
--
--static u32 irq_stat_addr[2];
--static u32 irq_mask_addr[2];
--static void (*dispatch_internal)(int cpu);
--static int is_ext_irq_cascaded;
--static unsigned int ext_irq_count;
--static unsigned int ext_irq_start, ext_irq_end;
--static unsigned int ext_irq_cfg_reg1, ext_irq_cfg_reg2;
--static void (*internal_irq_mask)(struct irq_data *d);
--static void (*internal_irq_unmask)(struct irq_data *d, const struct cpumask *m);
--
--
--static inline u32 get_ext_irq_perf_reg(int irq)
--{
--      if (irq < 4)
--              return ext_irq_cfg_reg1;
--      return ext_irq_cfg_reg2;
--}
--
--static inline void handle_internal(int intbit)
--{
--      if (is_ext_irq_cascaded &&
--          intbit >= ext_irq_start && intbit <= ext_irq_end)
--              do_IRQ(intbit - ext_irq_start + IRQ_EXTERNAL_BASE);
--      else
--              do_IRQ(intbit + IRQ_INTERNAL_BASE);
--}
--
--static inline int enable_irq_for_cpu(int cpu, struct irq_data *d,
--                                   const struct cpumask *m)
--{
--      bool enable = cpu_online(cpu);
--
--#ifdef CONFIG_SMP
--      if (m)
--              enable &= cpu_isset(cpu, *m);
--      else if (irqd_affinity_was_set(d))
--              enable &= cpu_isset(cpu, *d->affinity);
--#endif
--      return enable;
--}
--
--/*
-- * dispatch internal devices IRQ (uart, enet, watchdog, ...). do not
-- * prioritize any interrupt relatively to another. the static counter
-- * will resume the loop where it ended the last time we left this
-- * function.
-- */
--
--#define BUILD_IPIC_INTERNAL(width)                                    \
--void __dispatch_internal_##width(int cpu)                             \
--{                                                                     \
--      u32 pending[width / 32];                                        \
--      unsigned int src, tgt;                                          \
--      bool irqs_pending = false;                                      \
--      static unsigned int i[2];                                       \
--      unsigned int *next = &i[cpu];                                   \
--      unsigned long flags;                                            \
--                                                                      \
--      /* read registers in reverse order */                           \
--      spin_lock_irqsave(&ipic_lock, flags);                           \
--      for (src = 0, tgt = (width / 32); src < (width / 32); src++) {  \
--              u32 val;                                                \
--                                                                      \
--              val = bcm_readl(irq_stat_addr[cpu] + src * sizeof(u32)); \
--              val &= bcm_readl(irq_mask_addr[cpu] + src * sizeof(u32)); \
--              pending[--tgt] = val;                                   \
--                                                                      \
--              if (val)                                                \
--                      irqs_pending = true;                            \
--      }                                                               \
--      spin_unlock_irqrestore(&ipic_lock, flags);                      \
--                                                                      \
--      if (!irqs_pending)                                              \
--              return;                                                 \
--                                                                      \
--      while (1) {                                                     \
--              unsigned int to_call = *next;                           \
--                                                                      \
--              *next = (*next + 1) & (width - 1);                      \
--              if (pending[to_call / 32] & (1 << (to_call & 0x1f))) {  \
--                      handle_internal(to_call);                       \
--                      break;                                          \
--              }                                                       \
--      }                                                               \
--}                                                                     \
--                                                                      \
--static void __internal_irq_mask_##width(struct irq_data *d)           \
--{                                                                     \
--      u32 val;                                                        \
--      unsigned irq = d->irq - IRQ_INTERNAL_BASE;                      \
--      unsigned reg = (irq / 32) ^ (width/32 - 1);                     \
--      unsigned bit = irq & 0x1f;                                      \
--      unsigned long flags;                                            \
--      int cpu;                                                        \
--                                                                      \
--      spin_lock_irqsave(&ipic_lock, flags);                           \
--      for_each_present_cpu(cpu) {                                     \
--              if (!irq_mask_addr[cpu])                                \
--                      break;                                          \
--                                                                      \
--              val = bcm_readl(irq_mask_addr[cpu] + reg * sizeof(u32));\
--              val &= ~(1 << bit);                                     \
--              bcm_writel(val, irq_mask_addr[cpu] + reg * sizeof(u32));\
--      }                                                               \
--      spin_unlock_irqrestore(&ipic_lock, flags);                      \
--}                                                                     \
--                                                                      \
--static void __internal_irq_unmask_##width(struct irq_data *d,         \
--                                        const struct cpumask *m)      \
--{                                                                     \
--      u32 val;                                                        \
--      unsigned irq = d->irq - IRQ_INTERNAL_BASE;                      \
--      unsigned reg = (irq / 32) ^ (width/32 - 1);                     \
--      unsigned bit = irq & 0x1f;                                      \
--      unsigned long flags;                                            \
--      int cpu;                                                        \
--                                                                      \
--      spin_lock_irqsave(&ipic_lock, flags);                           \
--      for_each_present_cpu(cpu) {                                     \
--              if (!irq_mask_addr[cpu])                                \
--                      break;                                          \
--                                                                      \
--              val = bcm_readl(irq_mask_addr[cpu] + reg * sizeof(u32));\
--              if (enable_irq_for_cpu(cpu, d, m))                      \
--                      val |= (1 << bit);                              \
--              else                                                    \
--                      val &= ~(1 << bit);                             \
--              bcm_writel(val, irq_mask_addr[cpu] + reg * sizeof(u32));\
--      }                                                               \
--      spin_unlock_irqrestore(&ipic_lock, flags);                      \
--}
--
--BUILD_IPIC_INTERNAL(32);
--BUILD_IPIC_INTERNAL(64);
--
--asmlinkage void plat_irq_dispatch(void)
--{
--      u32 cause;
--
--      do {
--              cause = read_c0_cause() & read_c0_status() & ST0_IM;
--
--              if (!cause)
--                      break;
--
--              if (cause & CAUSEF_IP7)
--                      do_IRQ(7);
--              if (cause & CAUSEF_IP0)
--                      do_IRQ(0);
--              if (cause & CAUSEF_IP1)
--                      do_IRQ(1);
--              if (cause & CAUSEF_IP2)
--                      dispatch_internal(0);
--              if (is_ext_irq_cascaded) {
--                      if (cause & CAUSEF_IP3)
--                              dispatch_internal(1);
--              } else {
--                      if (cause & CAUSEF_IP3)
--                              do_IRQ(IRQ_EXT_0);
--                      if (cause & CAUSEF_IP4)
--                              do_IRQ(IRQ_EXT_1);
--                      if (cause & CAUSEF_IP5)
--                              do_IRQ(IRQ_EXT_2);
--                      if (cause & CAUSEF_IP6)
--                              do_IRQ(IRQ_EXT_3);
--              }
--      } while (1);
--}
--
--/*
-- * internal IRQs operations: only mask/unmask on PERF irq mask
-- * register.
-- */
--static void bcm63xx_internal_irq_mask(struct irq_data *d)
--{
--      internal_irq_mask(d);
--}
--
--static void bcm63xx_internal_irq_unmask(struct irq_data *d)
--{
--      internal_irq_unmask(d, NULL);
--}
--
--/*
-- * external IRQs operations: mask/unmask and clear on PERF external
-- * irq control register.
-- */
--static void bcm63xx_external_irq_mask(struct irq_data *d)
--{
--      unsigned int irq = d->irq - IRQ_EXTERNAL_BASE;
--      u32 reg, regaddr;
--      unsigned long flags;
--
--      regaddr = get_ext_irq_perf_reg(irq);
--      spin_lock_irqsave(&epic_lock, flags);
--      reg = bcm_perf_readl(regaddr);
--
--      if (BCMCPU_IS_6348())
--              reg &= ~EXTIRQ_CFG_MASK_6348(irq % 4);
--      else
--              reg &= ~EXTIRQ_CFG_MASK(irq % 4);
--
--      bcm_perf_writel(reg, regaddr);
--      spin_unlock_irqrestore(&epic_lock, flags);
--
--      if (is_ext_irq_cascaded)
--              internal_irq_mask(irq_get_irq_data(irq + ext_irq_start));
--}
--
--static void bcm63xx_external_irq_unmask(struct irq_data *d)
--{
--      unsigned int irq = d->irq - IRQ_EXTERNAL_BASE;
--      u32 reg, regaddr;
--      unsigned long flags;
--
--      regaddr = get_ext_irq_perf_reg(irq);
--      spin_lock_irqsave(&epic_lock, flags);
--      reg = bcm_perf_readl(regaddr);
--
--      if (BCMCPU_IS_6348())
--              reg |= EXTIRQ_CFG_MASK_6348(irq % 4);
--      else
--              reg |= EXTIRQ_CFG_MASK(irq % 4);
--
--      bcm_perf_writel(reg, regaddr);
--      spin_unlock_irqrestore(&epic_lock, flags);
--
--      if (is_ext_irq_cascaded)
--              internal_irq_unmask(irq_get_irq_data(irq + ext_irq_start),
--                                  NULL);
--}
--
--static void bcm63xx_external_irq_clear(struct irq_data *d)
--{
--      unsigned int irq = d->irq - IRQ_EXTERNAL_BASE;
--      u32 reg, regaddr;
--      unsigned long flags;
--
--      regaddr = get_ext_irq_perf_reg(irq);
--      spin_lock_irqsave(&epic_lock, flags);
--      reg = bcm_perf_readl(regaddr);
--
--      if (BCMCPU_IS_6348())
--              reg |= EXTIRQ_CFG_CLEAR_6348(irq % 4);
--      else
--              reg |= EXTIRQ_CFG_CLEAR(irq % 4);
--
--      bcm_perf_writel(reg, regaddr);
--      spin_unlock_irqrestore(&epic_lock, flags);
--}
--
--static int bcm63xx_external_irq_set_type(struct irq_data *d,
--                                       unsigned int flow_type)
--{
--      unsigned int irq = d->irq - IRQ_EXTERNAL_BASE;
--      u32 reg, regaddr;
--      int levelsense, sense, bothedge;
--      unsigned long flags;
--
--      flow_type &= IRQ_TYPE_SENSE_MASK;
--
--      if (flow_type == IRQ_TYPE_NONE)
--              flow_type = IRQ_TYPE_LEVEL_LOW;
--
--      levelsense = sense = bothedge = 0;
--      switch (flow_type) {
--      case IRQ_TYPE_EDGE_BOTH:
--              bothedge = 1;
--              break;
--
--      case IRQ_TYPE_EDGE_RISING:
--              sense = 1;
--              break;
--
--      case IRQ_TYPE_EDGE_FALLING:
--              break;
--
--      case IRQ_TYPE_LEVEL_HIGH:
--              levelsense = 1;
--              sense = 1;
--              break;
--
--      case IRQ_TYPE_LEVEL_LOW:
--              levelsense = 1;
--              break;
--
--      default:
--              printk(KERN_ERR "bogus flow type combination given !\n");
--              return -EINVAL;
--      }
--
--      regaddr = get_ext_irq_perf_reg(irq);
--      spin_lock_irqsave(&epic_lock, flags);
--      reg = bcm_perf_readl(regaddr);
--      irq %= 4;
--
--      switch (bcm63xx_get_cpu_id()) {
--      case BCM6348_CPU_ID:
--              if (levelsense)
--                      reg |= EXTIRQ_CFG_LEVELSENSE_6348(irq);
--              else
--                      reg &= ~EXTIRQ_CFG_LEVELSENSE_6348(irq);
--              if (sense)
--                      reg |= EXTIRQ_CFG_SENSE_6348(irq);
--              else
--                      reg &= ~EXTIRQ_CFG_SENSE_6348(irq);
--              if (bothedge)
--                      reg |= EXTIRQ_CFG_BOTHEDGE_6348(irq);
--              else
--                      reg &= ~EXTIRQ_CFG_BOTHEDGE_6348(irq);
--              break;
--
--      case BCM3368_CPU_ID:
--      case BCM6328_CPU_ID:
--      case BCM6338_CPU_ID:
--      case BCM6345_CPU_ID:
--      case BCM6358_CPU_ID:
--      case BCM6362_CPU_ID:
--      case BCM6368_CPU_ID:
--              if (levelsense)
--                      reg |= EXTIRQ_CFG_LEVELSENSE(irq);
--              else
--                      reg &= ~EXTIRQ_CFG_LEVELSENSE(irq);
--              if (sense)
--                      reg |= EXTIRQ_CFG_SENSE(irq);
--              else
--                      reg &= ~EXTIRQ_CFG_SENSE(irq);
--              if (bothedge)
--                      reg |= EXTIRQ_CFG_BOTHEDGE(irq);
--              else
--                      reg &= ~EXTIRQ_CFG_BOTHEDGE(irq);
--              break;
--      default:
--              BUG();
--      }
--
--      bcm_perf_writel(reg, regaddr);
--      spin_unlock_irqrestore(&epic_lock, flags);
--
--      irqd_set_trigger_type(d, flow_type);
--      if (flow_type & (IRQ_TYPE_LEVEL_LOW | IRQ_TYPE_LEVEL_HIGH))
--              __irq_set_handler_locked(d->irq, handle_level_irq);
--      else
--              __irq_set_handler_locked(d->irq, handle_edge_irq);
--
--      return IRQ_SET_MASK_OK_NOCOPY;
--}
--
--#ifdef CONFIG_SMP
--static int bcm63xx_internal_set_affinity(struct irq_data *data,
--                                       const struct cpumask *dest,
--                                       bool force)
--{
--      if (!irqd_irq_disabled(data))
--              internal_irq_unmask(data, dest);
--
--      return 0;
--}
--#endif
--
--static struct irq_chip bcm63xx_internal_irq_chip = {
--      .name           = "bcm63xx_ipic",
--      .irq_mask       = bcm63xx_internal_irq_mask,
--      .irq_unmask     = bcm63xx_internal_irq_unmask,
--};
--
--static struct irq_chip bcm63xx_external_irq_chip = {
--      .name           = "bcm63xx_epic",
--      .irq_ack        = bcm63xx_external_irq_clear,
--
--      .irq_mask       = bcm63xx_external_irq_mask,
--      .irq_unmask     = bcm63xx_external_irq_unmask,
--
--      .irq_set_type   = bcm63xx_external_irq_set_type,
--};
--
--static struct irqaction cpu_ip2_cascade_action = {
--      .handler        = no_action,
--      .name           = "cascade_ip2",
--      .flags          = IRQF_NO_THREAD,
--};
--
--#ifdef CONFIG_SMP
--static struct irqaction cpu_ip3_cascade_action = {
--      .handler        = no_action,
--      .name           = "cascade_ip3",
--      .flags          = IRQF_NO_THREAD,
--};
--#endif
--
--static struct irqaction cpu_ext_cascade_action = {
--      .handler        = no_action,
--      .name           = "cascade_extirq",
--      .flags          = IRQF_NO_THREAD,
--};
--
- static void bcm63xx_init_irq(void)
- {
--      int irq_bits;
--
--      irq_stat_addr[0] = bcm63xx_regset_address(RSET_PERF);
--      irq_mask_addr[0] = bcm63xx_regset_address(RSET_PERF);
--      irq_stat_addr[1] = bcm63xx_regset_address(RSET_PERF);
--      irq_mask_addr[1] = bcm63xx_regset_address(RSET_PERF);
-+      void __iomem *periph_bases[2];
-+      void __iomem *ext_intc_bases[2];
-+      int periph_irq_count, periph_width, ext_irq_count, ext_shift;
-+      int periph_irqs[2] = { 2, 3 };
-+      int ext_irqs[6];
-+
-+      periph_bases[0] = (void __iomem *)bcm63xx_regset_address(RSET_PERF);
-+      periph_bases[1] = (void __iomem *)bcm63xx_regset_address(RSET_PERF);
-+      ext_intc_bases[0] = (void __iomem *)bcm63xx_regset_address(RSET_PERF);
-+      ext_intc_bases[1] = (void __iomem *)bcm63xx_regset_address(RSET_PERF);
-       switch (bcm63xx_get_cpu_id()) {
-       case BCM3368_CPU_ID:
--              irq_stat_addr[0] += PERF_IRQSTAT_3368_REG;
--              irq_mask_addr[0] += PERF_IRQMASK_3368_REG;
--              irq_stat_addr[1] = 0;
--              irq_stat_addr[1] = 0;
--              irq_bits = 32;
--              ext_irq_count = 4;
--              ext_irq_cfg_reg1 = PERF_EXTIRQ_CFG_REG_3368;
-+              periph_bases[0] += PERF_IRQMASK_3368_REG;
-+              periph_irq_count = 1;
-+              periph_width = 1;
-+
-+              ext_intc_bases[0] += PERF_EXTIRQ_CFG_REG_3368;
-+              ext_irq_count = 4;
-+              ext_irqs[0] = BCM_3368_EXT_IRQ0;
-+              ext_irqs[1] = BCM_3368_EXT_IRQ1;
-+              ext_irqs[2] = BCM_3368_EXT_IRQ2;
-+              ext_irqs[3] = BCM_3368_EXT_IRQ3;
-+              ext_shift = 4;
-               break;
-       case BCM6328_CPU_ID:
--              irq_stat_addr[0] += PERF_IRQSTAT_6328_REG(0);
--              irq_mask_addr[0] += PERF_IRQMASK_6328_REG(0);
--              irq_stat_addr[1] += PERF_IRQSTAT_6328_REG(1);
--              irq_stat_addr[1] += PERF_IRQMASK_6328_REG(1);
--              irq_bits = 64;
--              ext_irq_count = 4;
--              is_ext_irq_cascaded = 1;
--              ext_irq_start = BCM_6328_EXT_IRQ0 - IRQ_INTERNAL_BASE;
--              ext_irq_end = BCM_6328_EXT_IRQ3 - IRQ_INTERNAL_BASE;
--              ext_irq_cfg_reg1 = PERF_EXTIRQ_CFG_REG_6328;
-+              periph_bases[0] += PERF_IRQMASK_6328_REG(0);
-+              periph_bases[1] += PERF_IRQMASK_6328_REG(1);
-+              periph_irq_count = 2;
-+              periph_width = 2;
-+
-+              ext_intc_bases[0] += PERF_EXTIRQ_CFG_REG_6328;
-+              ext_irq_count = 4;
-+              ext_irqs[0] = BCM_6328_EXT_IRQ0;
-+              ext_irqs[1] = BCM_6328_EXT_IRQ1;
-+              ext_irqs[2] = BCM_6328_EXT_IRQ2;
-+              ext_irqs[3] = BCM_6328_EXT_IRQ3;
-+              ext_shift = 4;
-               break;
-       case BCM6338_CPU_ID:
--              irq_stat_addr[0] += PERF_IRQSTAT_6338_REG;
--              irq_mask_addr[0] += PERF_IRQMASK_6338_REG;
--              irq_stat_addr[1] = 0;
--              irq_mask_addr[1] = 0;
--              irq_bits = 32;
--              ext_irq_count = 4;
--              ext_irq_cfg_reg1 = PERF_EXTIRQ_CFG_REG_6338;
-+              periph_bases[0] += PERF_IRQMASK_6338_REG;
-+              periph_irq_count = 1;
-+              periph_width = 1;
-+
-+              ext_intc_bases[0] += PERF_EXTIRQ_CFG_REG_6338;
-+              ext_irq_count = 4;
-+              ext_irqs[0] = 3;
-+              ext_irqs[1] = 4;
-+              ext_irqs[2] = 5;
-+              ext_irqs[3] = 6;
-+              ext_shift = 4;
-               break;
-       case BCM6345_CPU_ID:
--              irq_stat_addr[0] += PERF_IRQSTAT_6345_REG;
--              irq_mask_addr[0] += PERF_IRQMASK_6345_REG;
--              irq_stat_addr[1] = 0;
--              irq_mask_addr[1] = 0;
--              irq_bits = 32;
--              ext_irq_count = 4;
--              ext_irq_cfg_reg1 = PERF_EXTIRQ_CFG_REG_6345;
-+              periph_bases[0] += PERF_IRQMASK_6345_REG;
-+              periph_irq_count = 1;
-+              periph_width = 1;
-+
-+              ext_intc_bases[0] += PERF_EXTIRQ_CFG_REG_6345;
-+              ext_irq_count = 4;
-+              ext_irqs[0] = 3;
-+              ext_irqs[1] = 4;
-+              ext_irqs[2] = 5;
-+              ext_irqs[3] = 6;
-+              ext_shift = 4;
-               break;
-       case BCM6348_CPU_ID:
--              irq_stat_addr[0] += PERF_IRQSTAT_6348_REG;
--              irq_mask_addr[0] += PERF_IRQMASK_6348_REG;
--              irq_stat_addr[1] = 0;
--              irq_mask_addr[1] = 0;
--              irq_bits = 32;
--              ext_irq_count = 4;
--              ext_irq_cfg_reg1 = PERF_EXTIRQ_CFG_REG_6348;
-+              periph_bases[0] += PERF_IRQMASK_6348_REG;
-+              periph_irq_count = 1;
-+              periph_width = 1;
-+
-+              ext_intc_bases[0] += PERF_EXTIRQ_CFG_REG_6348;
-+              ext_irq_count = 4;
-+              ext_irqs[0] = 3;
-+              ext_irqs[1] = 4;
-+              ext_irqs[2] = 5;
-+              ext_irqs[3] = 6;
-+              ext_shift = 5;
-               break;
-       case BCM6358_CPU_ID:
--              irq_stat_addr[0] += PERF_IRQSTAT_6358_REG(0);
--              irq_mask_addr[0] += PERF_IRQMASK_6358_REG(0);
--              irq_stat_addr[1] += PERF_IRQSTAT_6358_REG(1);
--              irq_mask_addr[1] += PERF_IRQMASK_6358_REG(1);
--              irq_bits = 32;
--              ext_irq_count = 4;
--              is_ext_irq_cascaded = 1;
--              ext_irq_start = BCM_6358_EXT_IRQ0 - IRQ_INTERNAL_BASE;
--              ext_irq_end = BCM_6358_EXT_IRQ3 - IRQ_INTERNAL_BASE;
--              ext_irq_cfg_reg1 = PERF_EXTIRQ_CFG_REG_6358;
-+              periph_bases[0] += PERF_IRQMASK_6358_REG(0);
-+              periph_bases[1] += PERF_IRQMASK_6358_REG(1);
-+              periph_irq_count = 2;
-+              periph_width = 1;
-+
-+              ext_intc_bases[0] += PERF_EXTIRQ_CFG_REG_6358;
-+              ext_irq_count = 4;
-+              ext_irqs[0] = BCM_6358_EXT_IRQ0;
-+              ext_irqs[1] = BCM_6358_EXT_IRQ1;
-+              ext_irqs[2] = BCM_6358_EXT_IRQ2;
-+              ext_irqs[3] = BCM_6358_EXT_IRQ3;
-+              ext_shift = 4;
-               break;
-       case BCM6362_CPU_ID:
--              irq_stat_addr[0] += PERF_IRQSTAT_6362_REG(0);
--              irq_mask_addr[0] += PERF_IRQMASK_6362_REG(0);
--              irq_stat_addr[1] += PERF_IRQSTAT_6362_REG(1);
--              irq_mask_addr[1] += PERF_IRQMASK_6362_REG(1);
--              irq_bits = 64;
--              ext_irq_count = 4;
--              is_ext_irq_cascaded = 1;
--              ext_irq_start = BCM_6362_EXT_IRQ0 - IRQ_INTERNAL_BASE;
--              ext_irq_end = BCM_6362_EXT_IRQ3 - IRQ_INTERNAL_BASE;
--              ext_irq_cfg_reg1 = PERF_EXTIRQ_CFG_REG_6362;
-+              periph_bases[0] += PERF_IRQMASK_6362_REG(0);
-+              periph_bases[1] += PERF_IRQMASK_6362_REG(1);
-+              periph_irq_count = 2;
-+              periph_width = 2;
-+
-+              ext_intc_bases[0] += PERF_EXTIRQ_CFG_REG_6362;
-+              ext_irq_count = 4;
-+              ext_irqs[0] = BCM_6362_EXT_IRQ0;
-+              ext_irqs[1] = BCM_6362_EXT_IRQ1;
-+              ext_irqs[2] = BCM_6362_EXT_IRQ2;
-+              ext_irqs[3] = BCM_6362_EXT_IRQ3;
-+              ext_shift = 4;
-               break;
-       case BCM6368_CPU_ID:
--              irq_stat_addr[0] += PERF_IRQSTAT_6368_REG(0);
--              irq_mask_addr[0] += PERF_IRQMASK_6368_REG(0);
--              irq_stat_addr[1] += PERF_IRQSTAT_6368_REG(1);
--              irq_mask_addr[1] += PERF_IRQMASK_6368_REG(1);
--              irq_bits = 64;
-+              periph_bases[0] += PERF_IRQMASK_6368_REG(0);
-+              periph_bases[1] += PERF_IRQMASK_6368_REG(1);
-+              periph_irq_count = 2;
-+              periph_width = 2;
-+
-+              ext_intc_bases[0] += PERF_EXTIRQ_CFG_REG_6368;
-+              ext_intc_bases[1] += PERF_EXTIRQ_CFG_REG2_6368;
-               ext_irq_count = 6;
--              is_ext_irq_cascaded = 1;
--              ext_irq_start = BCM_6368_EXT_IRQ0 - IRQ_INTERNAL_BASE;
--              ext_irq_end = BCM_6368_EXT_IRQ5 - IRQ_INTERNAL_BASE;
--              ext_irq_cfg_reg1 = PERF_EXTIRQ_CFG_REG_6368;
--              ext_irq_cfg_reg2 = PERF_EXTIRQ_CFG_REG2_6368;
-+              ext_irqs[0] = BCM_6368_EXT_IRQ0;
-+              ext_irqs[1] = BCM_6368_EXT_IRQ1;
-+              ext_irqs[2] = BCM_6368_EXT_IRQ2;
-+              ext_irqs[3] = BCM_6368_EXT_IRQ3;
-+              ext_irqs[4] = BCM_6368_EXT_IRQ4;
-+              ext_irqs[5] = BCM_6368_EXT_IRQ5;
-+              ext_shift = 4;
-               break;
-       default:
-               BUG();
-       }
--      if (irq_bits == 32) {
--              dispatch_internal = __dispatch_internal_32;
--              internal_irq_mask = __internal_irq_mask_32;
--              internal_irq_unmask = __internal_irq_unmask_32;
--      } else {
--              dispatch_internal = __dispatch_internal_64;
--              internal_irq_mask = __internal_irq_mask_64;
--              internal_irq_unmask = __internal_irq_unmask_64;
--      }
-+      mips_cpu_irq_init();
-+      bcm6345_periph_intc_init(periph_irq_count, periph_irqs, periph_bases, periph_width);
-+      bcm6345_ext_intc_init(4, ext_irqs, ext_intc_bases[0], ext_shift);
-+      if (ext_irq_count > 4)
-+              bcm6345_ext_intc_init(2, &ext_irqs[4], ext_intc_bases[1],
-+                                    ext_shift);
- }
- void __init arch_init_irq(void)
- {
--      int i;
--
-       bcm63xx_init_irq();
--      mips_cpu_irq_init();
--      for (i = IRQ_INTERNAL_BASE; i < NR_IRQS; ++i)
--              irq_set_chip_and_handler(i, &bcm63xx_internal_irq_chip,
--                                       handle_level_irq);
--
--      for (i = IRQ_EXTERNAL_BASE; i < IRQ_EXTERNAL_BASE + ext_irq_count; ++i)
--              irq_set_chip_and_handler(i, &bcm63xx_external_irq_chip,
--                                       handle_edge_irq);
--
--      if (!is_ext_irq_cascaded) {
--              for (i = 3; i < 3 + ext_irq_count; ++i)
--                      setup_irq(MIPS_CPU_IRQ_BASE + i, &cpu_ext_cascade_action);
--      }
--
--      setup_irq(MIPS_CPU_IRQ_BASE + 2, &cpu_ip2_cascade_action);
--#ifdef CONFIG_SMP
--      if (is_ext_irq_cascaded) {
--              setup_irq(MIPS_CPU_IRQ_BASE + 3, &cpu_ip3_cascade_action);
--              bcm63xx_internal_irq_chip.irq_set_affinity =
--                      bcm63xx_internal_set_affinity;
--
--              cpumask_clear(irq_default_affinity);
--              cpumask_set_cpu(smp_processor_id(), irq_default_affinity);
--      }
--#endif
- }
diff --git a/target/linux/brcm63xx/patches-3.14/323-MIPS-BCM63XX-wire-up-BCM6358-s-external-interrupts-4.patch b/target/linux/brcm63xx/patches-3.14/323-MIPS-BCM63XX-wire-up-BCM6358-s-external-interrupts-4.patch
deleted file mode 100644 (file)
index 5d7371c..0000000
+++ /dev/null
@@ -1,57 +0,0 @@
-From fc8b863c38be9b2ccf805dd5ae17dbffb6bfbe87 Mon Sep 17 00:00:00 2001
-From: Jonas Gorski <jogo@openwrt.org>
-Date: Sun, 30 Nov 2014 20:20:30 +0100
-Subject: [PATCH 4/5] MIPS: BCM63XX: wire up BCM6358's external interrupts 4
- and 5
-
-Due to the external interrupts being non consecutive, the previous
-implementation did not support them. Now that we treat both registers
-as separate irq controllers, there is no such limitation anymore and
-we can expose them for drivers to use.
-
-Signed-off-by: Jonas Gorski <jogo@openwrt.org>
----
- arch/mips/bcm63xx/irq.c                           |    5 ++++-
- arch/mips/include/asm/mach-bcm63xx/bcm63xx_cpu.h  |    2 ++
- arch/mips/include/asm/mach-bcm63xx/bcm63xx_regs.h |    1 +
- 3 files changed, 7 insertions(+), 1 deletion(-)
-
---- a/arch/mips/bcm63xx/irq.c
-+++ b/arch/mips/bcm63xx/irq.c
-@@ -109,11 +109,14 @@ static void bcm63xx_init_irq(void)
-               periph_width = 1;
-               ext_intc_bases[0] += PERF_EXTIRQ_CFG_REG_6358;
--              ext_irq_count = 4;
-+              ext_intc_bases[1] += PERF_EXTIRQ_CFG_REG2_6358;
-+              ext_irq_count = 6;
-               ext_irqs[0] = BCM_6358_EXT_IRQ0;
-               ext_irqs[1] = BCM_6358_EXT_IRQ1;
-               ext_irqs[2] = BCM_6358_EXT_IRQ2;
-               ext_irqs[3] = BCM_6358_EXT_IRQ3;
-+              ext_irqs[4] = BCM_6358_EXT_IRQ4;
-+              ext_irqs[5] = BCM_6358_EXT_IRQ5;
-               ext_shift = 4;
-               break;
-       case BCM6362_CPU_ID:
---- a/arch/mips/include/asm/mach-bcm63xx/bcm63xx_cpu.h
-+++ b/arch/mips/include/asm/mach-bcm63xx/bcm63xx_cpu.h
-@@ -940,6 +940,8 @@ enum bcm63xx_irq {
- #define BCM_6358_EXT_IRQ1             (IRQ_INTERNAL_BASE + 26)
- #define BCM_6358_EXT_IRQ2             (IRQ_INTERNAL_BASE + 27)
- #define BCM_6358_EXT_IRQ3             (IRQ_INTERNAL_BASE + 28)
-+#define BCM_6358_EXT_IRQ4             (IRQ_INTERNAL_BASE + 20)
-+#define BCM_6358_EXT_IRQ5             (IRQ_INTERNAL_BASE + 21)
- /*
-  * 6362 irqs
---- a/arch/mips/include/asm/mach-bcm63xx/bcm63xx_regs.h
-+++ b/arch/mips/include/asm/mach-bcm63xx/bcm63xx_regs.h
-@@ -243,6 +243,7 @@
- #define PERF_EXTIRQ_CFG_REG_6362      0x18
- #define PERF_EXTIRQ_CFG_REG_6368      0x18
-+#define PERF_EXTIRQ_CFG_REG2_6358     0x1c
- #define PERF_EXTIRQ_CFG_REG2_6368     0x1c
- /* for 6348 only */
diff --git a/target/linux/brcm63xx/patches-3.14/330-MIPS-BCM63XX-add-a-new-cpu-variant-helper.patch b/target/linux/brcm63xx/patches-3.14/330-MIPS-BCM63XX-add-a-new-cpu-variant-helper.patch
deleted file mode 100644 (file)
index 3f24473..0000000
+++ /dev/null
@@ -1,77 +0,0 @@
-From c50acd37b425a8a907a6f7f93aa2e658256e79ce Mon Sep 17 00:00:00 2001
-From: Jonas Gorski <jogo@openwrt.org>
-Date: Sat, 7 Dec 2013 14:08:36 +0100
-Subject: [PATCH 40/53] MIPS: BCM63XX: add a new cpu variant helper
-
----
- arch/mips/bcm63xx/cpu.c                          | 10 ++++++++++
- arch/mips/include/asm/mach-bcm63xx/bcm63xx_cpu.h | 18 ++++++++++++++++++
- 2 files changed, 28 insertions(+)
-
---- a/arch/mips/bcm63xx/cpu.c
-+++ b/arch/mips/bcm63xx/cpu.c
-@@ -27,6 +27,8 @@ EXPORT_SYMBOL(bcm63xx_irqs);
- u16 bcm63xx_cpu_id __read_mostly;
- EXPORT_SYMBOL(bcm63xx_cpu_id);
-+static u32 bcm63xx_cpu_variant __read_mostly;
-+
- static u8 bcm63xx_cpu_rev;
- static unsigned int bcm63xx_cpu_freq;
- static unsigned int bcm63xx_memory_size;
-@@ -99,6 +101,13 @@ static const int bcm6368_irqs[] = {
- };
-+u32 bcm63xx_get_cpu_variant(void)
-+{
-+      return bcm63xx_cpu_variant;
-+}
-+
-+EXPORT_SYMBOL(bcm63xx_get_cpu_variant);
-+
- u8 bcm63xx_get_cpu_rev(void)
- {
-       return bcm63xx_cpu_rev;
-@@ -334,6 +343,7 @@ void __init bcm63xx_cpu_init(void)
-       /* read out CPU type */
-       tmp = bcm_readl(chipid_reg);
-       bcm63xx_cpu_id = (tmp & REV_CHIPID_MASK) >> REV_CHIPID_SHIFT;
-+      bcm63xx_cpu_variant = bcm63xx_cpu_id;
-       bcm63xx_cpu_rev = (tmp & REV_REVID_MASK) >> REV_REVID_SHIFT;
-       switch (bcm63xx_cpu_id) {
---- a/arch/mips/include/asm/mach-bcm63xx/bcm63xx_cpu.h
-+++ b/arch/mips/include/asm/mach-bcm63xx/bcm63xx_cpu.h
-@@ -19,6 +19,7 @@
- #define BCM6368_CPU_ID                0x6368
- void __init bcm63xx_cpu_init(void);
-+u32 bcm63xx_get_cpu_variant(void);
- u8 bcm63xx_get_cpu_rev(void);
- unsigned int bcm63xx_get_cpu_freq(void);
-@@ -82,6 +83,23 @@ static inline u16 __pure bcm63xx_get_cpu
- #define BCMCPU_IS_6362()      (bcm63xx_get_cpu_id() == BCM6362_CPU_ID)
- #define BCMCPU_IS_6368()      (bcm63xx_get_cpu_id() == BCM6368_CPU_ID)
-+#define BCMCPU_VARIANT_IS_3368() \
-+      (bcm63xx_get_cpu_variant() == BCM3368_CPU_ID)
-+#define BCMCPU_VARIANT_IS_6328() \
-+      (bcm63xx_get_cpu_variant() == BCM6328_CPU_ID)
-+#define BCMCPU_VARIANT_IS_6338() \
-+      (bcm63xx_get_cpu_variant() == BCM6338_CPU_ID)
-+#define BCMCPU_VARIANT_IS_6345() \
-+      (bcm63xx_get_cpu_variant() == BCM6345_CPU_ID)
-+#define BCMCPU_VARIANT_IS_6348() \
-+      (bcm63xx_get_cpu_variant() == BCM6348_CPU_ID)
-+#define BCMCPU_VARIANT_IS_6358() \
-+      (bcm63xx_get_cpu_cariant() == BCM6358_CPU_ID)
-+#define BCMCPU_VARIANT_IS_6362() \
-+      (bcm63xx_get_cpu_variant() == BCM6362_CPU_ID)
-+#define BCMCPU_VARIANT_IS_6368() \
-+      (bcm63xx_get_cpu_variant() == BCM6368_CPU_ID)
-+
- /*
-  * While registers sets are (mostly) the same across 63xx CPU, base
-  * address of these sets do change.
diff --git a/target/linux/brcm63xx/patches-3.14/331-MIPS-BCM63XX-define-variant-id-field.patch b/target/linux/brcm63xx/patches-3.14/331-MIPS-BCM63XX-define-variant-id-field.patch
deleted file mode 100644 (file)
index 2e21c65..0000000
+++ /dev/null
@@ -1,23 +0,0 @@
-From 3bd8e2535265f06f79ed9c0ad788405441e091dc Mon Sep 17 00:00:00 2001
-From: Jonas Gorski <jogo@openwrt.org>
-Date: Sat, 7 Dec 2013 14:22:41 +0100
-Subject: [PATCH 21/45] MIPS: BCM63XX: define variant id field
-
-Some SoC have a variant id field in the chip id register.
-
-Signed-off-by: Jonas Gorski <jogo@openwrt.org>
----
- arch/mips/include/asm/mach-bcm63xx/bcm63xx_regs.h | 2 ++
- 1 file changed, 2 insertions(+)
-
---- a/arch/mips/include/asm/mach-bcm63xx/bcm63xx_regs.h
-+++ b/arch/mips/include/asm/mach-bcm63xx/bcm63xx_regs.h
-@@ -9,6 +9,8 @@
- #define PERF_REV_REG                  0x0
- #define REV_CHIPID_SHIFT              16
- #define REV_CHIPID_MASK                       (0xffff << REV_CHIPID_SHIFT)
-+#define REV_VARID_SHIFT                       12
-+#define REV_VARID_MASK                        (0xf << REV_VARID_SHIFT)
- #define REV_REVID_SHIFT                       0
- #define REV_REVID_MASK                        (0xff << REV_REVID_SHIFT)
diff --git a/target/linux/brcm63xx/patches-3.14/332-MIPS-BCM63XX-detect-BCM6328-variants.patch b/target/linux/brcm63xx/patches-3.14/332-MIPS-BCM63XX-detect-BCM6328-variants.patch
deleted file mode 100644 (file)
index dc7fbfc..0000000
+++ /dev/null
@@ -1,68 +0,0 @@
-From d59120f23279ef62a48d9f94847254b061d0a8b6 Mon Sep 17 00:00:00 2001
-From: Jonas Gorski <jogo@openwrt.org>
-Date: Sat, 7 Dec 2013 14:30:59 +0100
-Subject: [PATCH 22/45] MIPS: BCM63XX: detect BCM6328 variants
-
-Signed-off-by: Jonas Gorski <jogo@openwrt.org>
----
- arch/mips/bcm63xx/cpu.c                          | 10 ++++++++++
- arch/mips/include/asm/mach-bcm63xx/bcm63xx_cpu.h |  8 ++++++--
- 2 files changed, 16 insertions(+), 2 deletions(-)
-
---- a/arch/mips/bcm63xx/cpu.c
-+++ b/arch/mips/bcm63xx/cpu.c
-@@ -306,6 +306,7 @@ void __init bcm63xx_cpu_init(void)
-       struct cpuinfo_mips *c = &current_cpu_data;
-       unsigned int cpu = smp_processor_id();
-       u32 chipid_reg;
-+      u8 __maybe_unused varid = 0;
-       /* soc registers location depends on cpu type */
-       chipid_reg = 0;
-@@ -345,6 +346,7 @@ void __init bcm63xx_cpu_init(void)
-       bcm63xx_cpu_id = (tmp & REV_CHIPID_MASK) >> REV_CHIPID_SHIFT;
-       bcm63xx_cpu_variant = bcm63xx_cpu_id;
-       bcm63xx_cpu_rev = (tmp & REV_REVID_MASK) >> REV_REVID_SHIFT;
-+      varid = (tmp & REV_VARID_MASK) >> REV_VARID_SHIFT;
-       switch (bcm63xx_cpu_id) {
-       case BCM3368_CPU_ID:
-@@ -354,6 +356,14 @@ void __init bcm63xx_cpu_init(void)
-       case BCM6328_CPU_ID:
-               bcm63xx_regs_base = bcm6328_regs_base;
-               bcm63xx_irqs = bcm6328_irqs;
-+
-+              if (varid == 1)
-+                      bcm63xx_cpu_variant = BCM63281_CPU_ID;
-+              else if (varid == 3)
-+                      bcm63xx_cpu_variant = BCM63283_CPU_ID;
-+              else
-+                      pr_warn("unknown BCM6328 variant: %x\n", varid);
-+
-               break;
-       case BCM6338_CPU_ID:
-               bcm63xx_regs_base = bcm6338_regs_base;
---- a/arch/mips/include/asm/mach-bcm63xx/bcm63xx_cpu.h
-+++ b/arch/mips/include/asm/mach-bcm63xx/bcm63xx_cpu.h
-@@ -11,6 +11,8 @@
-  */
- #define BCM3368_CPU_ID                0x3368
- #define BCM6328_CPU_ID                0x6328
-+#define BCM63281_CPU_ID               0x63281
-+#define BCM63283_CPU_ID               0x63283
- #define BCM6338_CPU_ID                0x6338
- #define BCM6345_CPU_ID                0x6345
- #define BCM6348_CPU_ID                0x6348
-@@ -85,8 +87,10 @@ static inline u16 __pure bcm63xx_get_cpu
- #define BCMCPU_VARIANT_IS_3368() \
-       (bcm63xx_get_cpu_variant() == BCM3368_CPU_ID)
--#define BCMCPU_VARIANT_IS_6328() \
--      (bcm63xx_get_cpu_variant() == BCM6328_CPU_ID)
-+#define BCMCPU_VARIANT_IS_63281() \
-+      (bcm63xx_get_cpu_variant() == BCM63281_CPU_ID)
-+#define BCMCPU_VARIANT_IS_63283() \
-+      (bcm63xx_get_cpu_variant() == BCM63283_CPU_ID)
- #define BCMCPU_VARIANT_IS_6338() \
-       (bcm63xx_get_cpu_variant() == BCM6338_CPU_ID)
- #define BCMCPU_VARIANT_IS_6345() \
diff --git a/target/linux/brcm63xx/patches-3.14/333-MIPS-BCM63XX-detect-BCM6362-variants.patch b/target/linux/brcm63xx/patches-3.14/333-MIPS-BCM63XX-detect-BCM6362-variants.patch
deleted file mode 100644 (file)
index f70c81c..0000000
+++ /dev/null
@@ -1,46 +0,0 @@
-From 04458c3db8eb79da21ecde40ab36a1dde52bef06 Mon Sep 17 00:00:00 2001
-From: Jonas Gorski <jogo@openwrt.org>
-Date: Sat, 7 Dec 2013 14:33:28 +0100
-Subject: [PATCH 23/45] MIPS: BCM63XX: detect BCM6362 variants
-
----
- arch/mips/bcm63xx/cpu.c                          | 8 ++++++++
- arch/mips/include/asm/mach-bcm63xx/bcm63xx_cpu.h | 3 +++
- 2 files changed, 11 insertions(+)
-
---- a/arch/mips/bcm63xx/cpu.c
-+++ b/arch/mips/bcm63xx/cpu.c
-@@ -384,6 +384,14 @@ void __init bcm63xx_cpu_init(void)
-       case BCM6362_CPU_ID:
-               bcm63xx_regs_base = bcm6362_regs_base;
-               bcm63xx_irqs = bcm6362_irqs;
-+
-+              if (varid == 1)
-+                      bcm63xx_cpu_variant = BCM6362_CPU_ID;
-+              else if (varid == 2)
-+                      bcm63xx_cpu_variant = BCM6361_CPU_ID;
-+              else
-+                      pr_warn("unknown BCM6362 variant: %x\n", varid);
-+
-               break;
-       case BCM6368_CPU_ID:
-               bcm63xx_regs_base = bcm6368_regs_base;
---- a/arch/mips/include/asm/mach-bcm63xx/bcm63xx_cpu.h
-+++ b/arch/mips/include/asm/mach-bcm63xx/bcm63xx_cpu.h
-@@ -17,6 +17,7 @@
- #define BCM6345_CPU_ID                0x6345
- #define BCM6348_CPU_ID                0x6348
- #define BCM6358_CPU_ID                0x6358
-+#define BCM6361_CPU_ID                0x6361
- #define BCM6362_CPU_ID                0x6362
- #define BCM6368_CPU_ID                0x6368
-@@ -99,6 +100,8 @@ static inline u16 __pure bcm63xx_get_cpu
-       (bcm63xx_get_cpu_variant() == BCM6348_CPU_ID)
- #define BCMCPU_VARIANT_IS_6358() \
-       (bcm63xx_get_cpu_cariant() == BCM6358_CPU_ID)
-+#define BCMCPU_VARIANT_IS_6361() \
-+      (bcm63xx_get_cpu_variant() == BCM6361_CPU_ID)
- #define BCMCPU_VARIANT_IS_6362() \
-       (bcm63xx_get_cpu_variant() == BCM6362_CPU_ID)
- #define BCMCPU_VARIANT_IS_6368() \
diff --git a/target/linux/brcm63xx/patches-3.14/334-MIPS-BCM63XX-detect-BCM6368-variants.patch b/target/linux/brcm63xx/patches-3.14/334-MIPS-BCM63XX-detect-BCM6368-variants.patch
deleted file mode 100644 (file)
index d4f1c5d..0000000
+++ /dev/null
@@ -1,48 +0,0 @@
-From 825cc67e56b5e624a05f6850a86d91508b786848 Mon Sep 17 00:00:00 2001
-From: Jonas Gorski <jogo@openwrt.org>
-Date: Sat, 7 Dec 2013 14:36:56 +0100
-Subject: [PATCH 24/44] MIPS: BCM63XX: detect BCM6368 variants
-
-The DSL-less BCM6368 variant BCM6367 uses a different chip id. Apart
-from missing DSL, there is no difference to BCM6368, so treat it such.
-
-Signed-off-by: Jonas Gorski <jogo@openwrt.org>
----
- arch/mips/bcm63xx/cpu.c                          | 4 ++++
- arch/mips/include/asm/mach-bcm63xx/bcm63xx_cpu.h | 3 +++
- 2 files changed, 7 insertions(+)
-
---- a/arch/mips/bcm63xx/cpu.c
-+++ b/arch/mips/bcm63xx/cpu.c
-@@ -394,8 +394,12 @@ void __init bcm63xx_cpu_init(void)
-               break;
-       case BCM6368_CPU_ID:
-+      case BCM6369_CPU_ID:
-               bcm63xx_regs_base = bcm6368_regs_base;
-               bcm63xx_irqs = bcm6368_irqs;
-+
-+              /* BCM6369 is a BCM6368 without xDSL, so treat it the same */
-+              bcm63xx_cpu_id = BCM6368_CPU_ID;
-               break;
-       default:
-               panic("unsupported broadcom CPU %x", bcm63xx_cpu_id);
---- a/arch/mips/include/asm/mach-bcm63xx/bcm63xx_cpu.h
-+++ b/arch/mips/include/asm/mach-bcm63xx/bcm63xx_cpu.h
-@@ -20,6 +20,7 @@
- #define BCM6361_CPU_ID                0x6361
- #define BCM6362_CPU_ID                0x6362
- #define BCM6368_CPU_ID                0x6368
-+#define BCM6369_CPU_ID                0x6369
- void __init bcm63xx_cpu_init(void);
- u32 bcm63xx_get_cpu_variant(void);
-@@ -106,6 +107,8 @@ static inline u16 __pure bcm63xx_get_cpu
-       (bcm63xx_get_cpu_variant() == BCM6362_CPU_ID)
- #define BCMCPU_VARIANT_IS_6368() \
-       (bcm63xx_get_cpu_variant() == BCM6368_CPU_ID)
-+#define BCMCPU_VARIANT_IS_6369() \
-+      (bcm63xx_get_cpu_variant() == BCM6369_CPU_ID)
- /*
-  * While registers sets are (mostly) the same across 63xx CPU, base
diff --git a/target/linux/brcm63xx/patches-3.14/335-MIPS-BCM63XX-fix-PCIe-memory-window-size.patch b/target/linux/brcm63xx/patches-3.14/335-MIPS-BCM63XX-fix-PCIe-memory-window-size.patch
deleted file mode 100644 (file)
index 3230add..0000000
+++ /dev/null
@@ -1,20 +0,0 @@
-From f67f8134b4537c8bbafe7e1975edfe808b813997 Mon Sep 17 00:00:00 2001
-From: Jonas Gorski <jogo@openwrt.org>
-Date: Sun, 8 Dec 2013 03:05:54 +0100
-Subject: [PATCH 45/53] MIPS: BCM63XX: fix PCIe memory window size
-
----
- arch/mips/include/asm/mach-bcm63xx/bcm63xx_io.h | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
---- a/arch/mips/include/asm/mach-bcm63xx/bcm63xx_io.h
-+++ b/arch/mips/include/asm/mach-bcm63xx/bcm63xx_io.h
-@@ -41,7 +41,7 @@
-                                       BCM_CB_MEM_SIZE - 1)
- #define BCM_PCIE_MEM_BASE_PA          0x10f00000
--#define BCM_PCIE_MEM_SIZE             (16 * 1024 * 1024)
-+#define BCM_PCIE_MEM_SIZE             (1 * 1024 * 1024)
- #define BCM_PCIE_MEM_END_PA           (BCM_PCIE_MEM_BASE_PA +         \
-                                       BCM_PCIE_MEM_SIZE - 1)
diff --git a/target/linux/brcm63xx/patches-3.14/336-MIPS-BCM63XX-dynamically-set-the-pcie-memory-windows.patch b/target/linux/brcm63xx/patches-3.14/336-MIPS-BCM63XX-dynamically-set-the-pcie-memory-windows.patch
deleted file mode 100644 (file)
index d6eb54d..0000000
+++ /dev/null
@@ -1,70 +0,0 @@
-From aa05464973bc176478af462ca7c53a9239c651d4 Mon Sep 17 00:00:00 2001
-From: Jonas Gorski <jogo@openwrt.org>
-Date: Sun, 8 Dec 2013 03:13:06 +0100
-Subject: [PATCH 46/53] MIPS: BCM63XX: dynamically set the pcie memory windows
-
-Different SoCs use different memory windows (and sizes), so don't
-hardcode it.
----
- arch/mips/include/asm/mach-bcm63xx/bcm63xx_io.h |  8 ++++----
- arch/mips/pci/pci-bcm63xx.c                     | 15 ++++++++++-----
- 2 files changed, 14 insertions(+), 9 deletions(-)
-
---- a/arch/mips/include/asm/mach-bcm63xx/bcm63xx_io.h
-+++ b/arch/mips/include/asm/mach-bcm63xx/bcm63xx_io.h
-@@ -40,10 +40,10 @@
- #define BCM_CB_MEM_END_PA             (BCM_CB_MEM_BASE_PA +           \
-                                       BCM_CB_MEM_SIZE - 1)
--#define BCM_PCIE_MEM_BASE_PA          0x10f00000
--#define BCM_PCIE_MEM_SIZE             (1 * 1024 * 1024)
--#define BCM_PCIE_MEM_END_PA           (BCM_PCIE_MEM_BASE_PA +         \
--                                      BCM_PCIE_MEM_SIZE - 1)
-+#define BCM_PCIE_MEM_BASE_PA_6328     0x10f00000
-+#define BCM_PCIE_MEM_SIZE_6328                (1 * 1024 * 1024)
-+#define BCM_PCIE_MEM_END_PA_6328      (BCM_PCIE_MEM_BASE_PA_6328 +    \
-+                                      BCM_PCIE_MEM_SIZE_6328 - 1)
- /*
-  * Internal registers are accessed through KSEG3
---- a/arch/mips/pci/pci-bcm63xx.c
-+++ b/arch/mips/pci/pci-bcm63xx.c
-@@ -77,8 +77,8 @@ struct pci_controller bcm63xx_cb_control
- static struct resource bcm_pcie_mem_resource = {
-       .name   = "bcm63xx PCIe memory space",
--      .start  = BCM_PCIE_MEM_BASE_PA,
--      .end    = BCM_PCIE_MEM_END_PA,
-+      .start  = 0,
-+      .end    = 0,
-       .flags  = IORESOURCE_MEM,
- };
-@@ -195,12 +195,12 @@ static int __init bcm63xx_register_pcie(
-       bcm_pcie_writel(val, PCIE_CONFIG2_REG);
-       /* set bar0 to little endian */
--      val = (BCM_PCIE_MEM_BASE_PA >> 20) << BASEMASK_BASE_SHIFT;
--      val |= (BCM_PCIE_MEM_BASE_PA >> 20) << BASEMASK_MASK_SHIFT;
-+      val = (bcm_pcie_mem_resource.start >> 20) << BASEMASK_BASE_SHIFT;
-+      val |= (bcm_pcie_mem_resource.end >> 20) << BASEMASK_MASK_SHIFT;
-       val |= BASEMASK_REMAP_EN;
-       bcm_pcie_writel(val, PCIE_BRIDGE_BAR0_BASEMASK_REG);
--      val = (BCM_PCIE_MEM_BASE_PA >> 20) << REBASE_ADDR_BASE_SHIFT;
-+      val = (bcm_pcie_mem_resource.start >> 20) << REBASE_ADDR_BASE_SHIFT;
-       bcm_pcie_writel(val, PCIE_BRIDGE_BAR0_REBASE_ADDR_REG);
-       register_pci_controller(&bcm63xx_pcie_controller);
-@@ -334,6 +334,11 @@ static int __init bcm63xx_pci_init(void)
-       if (!bcm63xx_pci_enabled)
-               return -ENODEV;
-+      if (BCMCPU_IS_6328() || BCMCPU_IS_6362()) {
-+              bcm_pcie_mem_resource.start = BCM_PCIE_MEM_BASE_PA_6328;
-+              bcm_pcie_mem_resource.end = BCM_PCIE_MEM_END_PA_6328;
-+      }
-+
-       switch (bcm63xx_get_cpu_id()) {
-       case BCM6328_CPU_ID:
-       case BCM6362_CPU_ID:
diff --git a/target/linux/brcm63xx/patches-3.14/337-MIPS-BCM63XX-widen-cpuid-field.patch b/target/linux/brcm63xx/patches-3.14/337-MIPS-BCM63XX-widen-cpuid-field.patch
deleted file mode 100644 (file)
index 0ead82e..0000000
+++ /dev/null
@@ -1,56 +0,0 @@
-From f1477f6e3551fd6beecfee5368fed1325dcd421f Mon Sep 17 00:00:00 2001
-From: Jonas Gorski <jogo@openwrt.org>
-Date: Sat, 7 Dec 2013 14:54:51 +0100
-Subject: [PATCH 47/53] MIPS: BCM63XX: widen cpuid field
-
----
- arch/mips/bcm63xx/cpu.c                          | 2 +-
- arch/mips/include/asm/mach-bcm63xx/bcm63xx_cpu.h | 8 ++++----
- 2 files changed, 5 insertions(+), 5 deletions(-)
-
---- a/arch/mips/bcm63xx/cpu.c
-+++ b/arch/mips/bcm63xx/cpu.c
-@@ -24,7 +24,7 @@ EXPORT_SYMBOL(bcm63xx_regs_base);
- const int *bcm63xx_irqs;
- EXPORT_SYMBOL(bcm63xx_irqs);
--u16 bcm63xx_cpu_id __read_mostly;
-+u32 bcm63xx_cpu_id __read_mostly;
- EXPORT_SYMBOL(bcm63xx_cpu_id);
- static u32 bcm63xx_cpu_variant __read_mostly;
-@@ -127,7 +127,7 @@ unsigned int bcm63xx_get_memory_size(voi
- static unsigned int detect_cpu_clock(void)
- {
--      u16 cpu_id = bcm63xx_get_cpu_id();
-+      u32 cpu_id = bcm63xx_get_cpu_id();
-       switch (cpu_id) {
-       case BCM3368_CPU_ID:
---- a/arch/mips/include/asm/mach-bcm63xx/bcm63xx_cpu.h
-+++ b/arch/mips/include/asm/mach-bcm63xx/bcm63xx_cpu.h
-@@ -27,7 +27,7 @@ u32 bcm63xx_get_cpu_variant(void);
- u8 bcm63xx_get_cpu_rev(void);
- unsigned int bcm63xx_get_cpu_freq(void);
--static inline u16 __pure __bcm63xx_get_cpu_id(const u16 cpu_id)
-+static inline u32 __pure __bcm63xx_get_cpu_id(const u32 cpu_id)
- {
-       switch (cpu_id) {
- #ifdef CONFIG_BCM63XX_CPU_3368
-@@ -69,11 +69,11 @@ static inline u16 __pure __bcm63xx_get_c
-       return cpu_id;
- }
--extern u16 bcm63xx_cpu_id;
-+extern u32 bcm63xx_cpu_id;