[linux-yocto] [PATCH 00/28] Resubmit LSI AXXIA updates to 3.4 standard/axxia/base
Sorry Bruce, those two patches appeared in my tree after a rebase. I will put the --cc-supress in my submittals Anders Berg (7): axxia: Fixed earlyprintk axxia: Define arch_is_coherent() ARM: 7465/1: Handle 4GB memory sizes in device tree and mem=size@start option ARM: LPAE: use phys_addr_t in alloc_init_pud() ARM: 7499/1: mm: Fix vmalloc overlap check for !HIGHMEM arm: mmu: Fixed checkpatch issues with mmu drivers/i2c-axxia: Support I2C_M_RECV_LEN David Mercado (2): LSI AXM55xx: Enable multi-cluster wfe/sev LSI AXM55XX: Add PMU support John Jacques (6): arch/arm/mach-axxi: Updated DDR Retention to Wokr from Interrupt Context arch/arm/mach-axxia: Clear MTC Errors During Initialization LSI: Fix Device Tree compatible fields powerpc/mpic: Disable preemption when calling mpic_processor_id() arm/mach-axxia: Same build for HW and simlation and DDR Retention Reset and clock init. axxia: Remove Wrapper Functions Michael Bringmann (1): LSI AXM55XX/rapidio: Stability and bug fix improvements , Correct boundary, Expand valid condition. Paul Butler (8): drivers/rapidio/devices: Initial Submittal of LSI rapidio drivers/rapidio: new files drivers/rapidio: modified files arm: rapidio updates powerpc: rapidio updates include: rapidio updates drivers: rapidio updates arm/mach-axxia: Updated PCIe driver to set PCIe SangeethaRao (3): arch/powerpc/sysdev: Fixed PCIe enumeration issue on AXM3500 emulation drivers/usb: USB driver/dts on PPC was broken. arch/arm/mach-axxia: added support for ncr_read/ncr_write ningligong (1): drivers/rapidio/lsi: squash a bunch rapidio stuff together and Cleanup arch/arm/Kconfig| 19 + arch/arm/Kconfig.debug |9 + arch/arm/Makefile |3 - arch/arm/boot/dts/axm-sim.dts | 403 arch/arm/boot/dts/axm55xx.dts | 50 +- arch/arm/boot/dts/axm55xxemu.dts| 21 +- arch/arm/boot/dts/axm55xxsim.dts| 94 +- arch/arm/boot/dts/axm55xxsim16.dts | 439 arch/arm/include/asm/axxia-rio.h| 135 ++ arch/arm/include/asm/rio.h | 37 + arch/arm/include/asm/setup.h| 14 +- arch/arm/include/asm/spinlock.h |4 + arch/arm/kernel/perf_event_v7.c |3 +- arch/arm/kernel/setup.c | 70 +- arch/arm/mach-axxia/Kconfig |3 - arch/arm/mach-axxia/Makefile|3 +- arch/arm/mach-axxia/axxia-gic.c | 25 +- arch/arm/mach-axxia/axxia.c | 123 +- arch/arm/mach-axxia/axxia.h |2 +- arch/arm/mach-axxia/clock.c | 185 +- arch/arm/mach-axxia/ddr_retention.c | 300 ++- arch/arm/mach-axxia/include/mach/debug-macro.S | 16 +- arch/arm/mach-axxia/include/mach/hardware.h | 25 +- arch/arm/mach-axxia/include/mach/irqs.h |1 + arch/arm/mach-axxia/include/mach/memory.h | 19 + arch/arm/mach-axxia/include/mach/ncr.h | 44 + arch/arm/mach-axxia/ncr.c | 597 + arch/arm/mach-axxia/pci.c |7 +- arch/arm/mach-axxia/platsmp.c | 155 +- arch/arm/mach-axxia/rapidio.c | 68 + arch/arm/mach-axxia/wrappers.c | 176 -- arch/arm/mm/mmu.c | 82 +- arch/powerpc/boot/dts/ACP344xV2.dts | 20 +- arch/powerpc/boot/dts/acp25xx.dts | 16 +- arch/powerpc/boot/dts/acp342x.dts | 21 +- arch/powerpc/boot/dts/acp344x.dts | 16 +- arch/powerpc/boot/dts/lsi_acp342x.dts | 317 +++ arch/powerpc/boot/dts/lsi_acp344x.dts | 355 +++ arch/powerpc/include/asm/axxia-rio.h| 107 + arch/powerpc/include/asm/rio.h | 46 + arch/powerpc/platforms/44x/Makefile |3 +- arch/powerpc/platforms/44x/acprio.c | 65 + arch/powerpc/platforms/44x/acpx1.c |1 + arch/powerpc/sysdev/Makefile|2 - arch/powerpc/sysdev/lsi_acp_wrappers.c | 132 -- arch/powerpc/sysdev/lsi_pci.c | 19 +- arch/powerpc/sysdev/mpic.c | 119 +- drivers/i2c/busses/i2c-axxia.c | 193 +- drivers/misc/Kconfig|2 +- drivers/misc/lsi-mtc.c |9 +- drivers/misc/lsi-ncr.c | 334 +-- drivers/misc/lsi-smmon.c| 374 ++-- drivers/net/ethernet/lsi/lsi_acp_net.c |9 +- drivers/net/rionet.c| 135 +- drivers/rapidio/Kconfig | 85 + drivers/rapidio/Makefile|4 +-
[linux-yocto] [PATCH 04/28] arm: rapidio updates
From: Paul Butler paul.but...@windriver.com - Added the RapidIO management options - Added the rio device to the axm55xx - Created the rio architecture support for arm - Added a file to support the RAPIDIO Bus registration Signed-off-by: Paul Butler paul.but...@windriver.com --- arch/arm/Kconfig | 18 + arch/arm/boot/dts/axm55xx.dts| 16 arch/arm/include/asm/axxia-rio.h | 82 ++ arch/arm/include/asm/rio.h | 33 +++ arch/arm/mach-axxia/Makefile |1 + arch/arm/mach-axxia/clock.c |5 +++ arch/arm/mach-axxia/rapidio.c| 44 7 files changed, 199 insertions(+) create mode 100644 arch/arm/include/asm/axxia-rio.h create mode 100644 arch/arm/include/asm/rio.h create mode 100644 arch/arm/mach-axxia/rapidio.c diff --git a/arch/arm/Kconfig b/arch/arm/Kconfig index 0b98e83..370eca8 100644 --- a/arch/arm/Kconfig +++ b/arch/arm/Kconfig @@ -344,6 +344,7 @@ config ARCH_AXXIA select PCI select PCI_DOMAINS if PCI select ARCH_SUPPORTS_MSI if PCI +select HAS_RAPIDIO if (!PREEMPT_RTB) help This enables support for the LSI Axxia boards. @@ -2358,3 +2359,20 @@ source security/Kconfig source crypto/Kconfig source lib/Kconfig + +menu RapidIO management options + +config HAS_RAPIDIO + bool + default n + +config RAPIDIO + bool RapidIO support + depends on HAS_RAPIDIO || PCI + help + If you say Y here, the kernel will include drivers and + infrastructure code to support RapidIO interconnect devices. + +source drivers/rapidio/Kconfig + +endmenu diff --git a/arch/arm/boot/dts/axm55xx.dts b/arch/arm/boot/dts/axm55xx.dts index aac791d..7ecb177 100644 --- a/arch/arm/boot/dts/axm55xx.dts +++ b/arch/arm/boot/dts/axm55xx.dts @@ -35,6 +35,7 @@ serial0 = axxia_serial0; timer = axxia_timers; ethernet0 = axxia_femac0; + rapidio0 = rio0; }; cpus { @@ -423,6 +424,21 @@ reg = 0x20 0x10098000 0 0x3000; interrupts = 0 45 4; }; + +rio0: rapidio { +index = 0; +status = disabled; +#address-cells = 2; +#size-cells = 2; +compatible = axxia,rapidio-delta; +device_type = rapidio; +reg = 0x0020 0x20142000 0x0 0x1000; /* SRIO Conf 0 region */ +ranges = 0x0 0x0 0x0031 0x 0x0 0x4000; +linkdown-reset = 0x0200 0x100 0x0020 0x1000 0x0 0x1; +interrupts = 0 89 4; +outb-dmes = 2 0x0003 1 0x; +}; + }; /* diff --git a/arch/arm/include/asm/axxia-rio.h b/arch/arm/include/asm/axxia-rio.h new file mode 100644 index 000..f244c85 --- /dev/null +++ b/arch/arm/include/asm/axxia-rio.h @@ -0,0 +1,82 @@ +/* + * RapidIO support for LSI Axxia parts + * + */ +#ifndef __ASM_AXXIA_RIO_H__ +#define __ASM_AXXIA_RIO_H__ + +/* Constants, Macros, etc. */ + +#define AXXIA_RIO_SMALL_SYSTEM + +#define AXXIA_RIO_SYSMEM_BARRIER() + +#define AXXIA_RIO_DISABLE_MACHINE_CHECK() +#define AXXIA_RIO_ENABLE_MACHINE_CHECK() +#define AXXIA_RIO_IF_MACHINE_CHECK(mcsr) (mcsr = 0) + +#define IN_SRIO8(a, v, ec) {v = inb((long unsigned int)a); ec = 0;} +#define IN_SRIO16(a, v, ec){v = inw((long unsigned int)a); ec = 0;} +#define IN_SRIO32(a, v, ec){v = inl((long unsigned int)a); ec = 0;} + +#define OUT_SRIO8(a, v)outb_p(v, (long unsigned int) a) +#define OUT_SRIO16(a, v) outw_p(v, (long unsigned int) a) +#define OUT_SRIO32(a, v) outl_p(v, (long unsigned int) a) + +#define _SWAP32(x) x) 0x00FF) 24) | (((x) 0xFF00) 8) | (((x) 0x00FF) 8) | (((x) 0xFF00) 24)) +#define CORRECT_GRIO(a)_SWAP32(a) +#define CORRECT_RAB(a) (a) + +/* ACP RIO board-specific stuff */ + +extern int axxia_rio_apio_enable(struct rio_mport *mport, u32 mask, u32 bits); +extern int axxia_rio_apio_disable(struct rio_mport *mport); +extern int axxia_rio_rpio_enable(struct rio_mport *mport, u32 mask, u32 bits); +extern int axxia_rio_rpio_disable(struct rio_mport *mport); + +extern int axxia_rapidio_board_init(void); + + +/*/ +/* ACP RIO operational stuff */ +/*/ + +/** + * CNTLZW - Count leading zeros word + * @val: value from which count number of leading zeros + * + * Return: number of zeros + */ +static inline u32 CNTLZW(u32 val) +{ + int n = 0; + if (val == 0) + return 32; + if ((val 0x) == 0) + n += 16; val = val 16; + /* + // 16 bits from left are zero! so we omit 16 left bits */ + if ((val 0xFF00) == 0) + n = n + 8; val = val 8; +
[linux-yocto] [PATCH 06/28] include: rapidio updates
From: Paul Butler paul.but...@windriver.com This patch adds the register definitions, support for PW messages, destination IDs, direct IO and driver support. Signed-off-by: Paul Butler paul.but...@windriver.com --- include/asm-generic/vmlinux.lds.h | 10 ++ include/linux/rio.h | 231 ++--- include/linux/rio_dio.h | 67 +++ include/linux/rio_drv.h | 202 +--- include/linux/rio_ids.h |7 ++ include/linux/rio_regs.h | 26 + include/linux/riopw.h | 30 + 7 files changed, 490 insertions(+), 83 deletions(-) create mode 100644 include/linux/rio_dio.h create mode 100644 include/linux/riopw.h diff --git a/include/asm-generic/vmlinux.lds.h b/include/asm-generic/vmlinux.lds.h index 5d2ca6f..290711d 100644 --- a/include/asm-generic/vmlinux.lds.h +++ b/include/asm-generic/vmlinux.lds.h @@ -274,6 +274,16 @@ } \ \ /* RapidIO route ops */ \ + .rio_dev_fixup : AT(ADDR(.rio_dev_fixup) - LOAD_OFFSET) { \ + VMLINUX_SYMBOL(__start_rio_dev_fixup_early) = .;\ + *(.rio_dev_fixup_early) \ + VMLINUX_SYMBOL(__end_rio_dev_fixup_early) = .; \ + VMLINUX_SYMBOL(__start_rio_dev_fixup_enable) = .; \ + *(.rio_dev_fixup_enable)\ + VMLINUX_SYMBOL(__end_rio_dev_fixup_enable) = .; \ + } \ + \ + /* RapidIO route ops */ \ .rio_ops: AT(ADDR(.rio_ops) - LOAD_OFFSET) {\ VMLINUX_SYMBOL(__start_rio_switch_ops) = .; \ *(.rio_switch_ops) \ diff --git a/include/linux/rio.h b/include/linux/rio.h index 4d50611..ef300e2 100644 --- a/include/linux/rio.h +++ b/include/linux/rio.h @@ -20,6 +20,8 @@ #include linux/errno.h #include linux/device.h #include linux/rio_regs.h +#include linux/radix-tree.h +#include asm/rio.h #define RIO_NO_HOPCOUNT-1 #define RIO_INVALID_DESTID 0x @@ -37,10 +39,14 @@ entry is invalid (no route exists for the device ID) */ +#define RIO_INVALID_ROUTE_WEIGHT 0xff /* Indicates that a route weight + entry is invalid (no route + exists for the device ID) */ + #define RIO_MAX_ROUTE_ENTRIES(size)(size ? (1 16) : (1 8)) #define RIO_ANY_DESTID(size) (size ? 0x : 0xff) -#define RIO_MAX_MBOX 4 +#define RIO_MAX_MBOX 8 #define RIO_MAX_MSG_SIZE 0x1000 /* @@ -77,6 +83,9 @@ #define RIO_CTAG_RESRVD0xfffe /* Reserved */ #define RIO_CTAG_UDEVID0x0001 /* Unique device identifier */ +#define RIO_DEVICE_INSERTION1 +#define RIO_DEVICE_EXTRACTION 2 + extern struct bus_type rio_bus_type; extern struct device rio_bus; extern struct list_head rio_devices; /* list of all devices */ @@ -85,6 +94,15 @@ struct rio_mport; struct rio_dev; union rio_pw_msg; +struct rio_switch_port { + struct rio_dev *rdev; +#ifdef CONFIG_RAPIDIO_DYNAMIC_ROUTES + u8 *route_weights_table; +#endif +}; + +#define NEW_STYLE 1 + /** * struct rio_switch - RIO switch info * @node: Node in global list of switches @@ -104,7 +122,12 @@ union rio_pw_msg; struct rio_switch { struct list_head node; u16 switchid; +#ifdef OLD_STYLE u8 *route_table; +#else + u32 port_init; + int update_lut; +#endif u32 port_ok; int (*add_entry) (struct rio_mport *mport, u16 destid, u8 hopcount, u16 table, u16 route_destid, u8 route_port); @@ -119,7 +142,9 @@ struct rio_switch { int (*em_init) (struct rio_dev *dev); int (*em_handle) (struct rio_dev *dev, u8 swport); int (*sw_sysfs) (struct rio_dev *dev, int create); - struct rio_dev *nextdev[0]; +#ifdef OLD_STYLE + struct rio_switch_port port[0]; +#endif }; /** @@ -151,10 +176,19 @@ struct rio_switch { * @prev: Previous RIO device connected to the current one * @rswitch: struct rio_switch (if valid for this device) */ +#ifdef NEW_STYLE +struct rio_dyn { + int prev_port; + u16 prev_destid; + u32 swpinfo; +}; +#endif + struct rio_dev { struct list_head global_list; /* node in list of all RIO devices */ struct list_head net_list; /* node in per net list */ -
[linux-yocto] [PATCH 05/28] powerpc: rapidio updates
From: Paul Butler paul.but...@windriver.com Add the rapidio device to the powerpc tree Add the rapidio support for the powerpc 44x lsi board Signed-off-by: Paul Butler paul.but...@windriver.com --- arch/powerpc/boot/dts/lsi_acp342x.dts | 317 + arch/powerpc/boot/dts/lsi_acp344x.dts | 355 + arch/powerpc/include/asm/axxia-rio.h | 103 ++ arch/powerpc/include/asm/rio.h| 41 arch/powerpc/platforms/44x/Makefile |3 +- arch/powerpc/platforms/44x/acprio.c | 65 ++ arch/powerpc/platforms/44x/acpx1.c|1 + 7 files changed, 884 insertions(+), 1 deletion(-) create mode 100644 arch/powerpc/boot/dts/lsi_acp342x.dts create mode 100644 arch/powerpc/boot/dts/lsi_acp344x.dts create mode 100644 arch/powerpc/include/asm/axxia-rio.h create mode 100644 arch/powerpc/platforms/44x/acprio.c diff --git a/arch/powerpc/boot/dts/lsi_acp342x.dts b/arch/powerpc/boot/dts/lsi_acp342x.dts new file mode 100644 index 000..da6066e --- /dev/null +++ b/arch/powerpc/boot/dts/lsi_acp342x.dts @@ -0,0 +1,317 @@ +/* + * Device Tree Source for IBM Embedded PPC 476 Platform + * + * Copyright 2009 Torez Smith, IBM Corporation. + * + * Based on earlier code: + * Copyright (c) 2006, 2007 IBM Corp. + * Josh Boyer jwbo...@linux.vnet.ibm.com, David Gibson d...@au1.ibm.com + * + * This file is licensed under the terms of the GNU General Public + * License version 2. This program is licensed as is without + * any warranty of any kind, whether express or implied. + */ + +/dts-v1/; + +/memreserve/ 0x 0x0040; + +/ { + #address-cells = 2; + #size-cells = 1; + model = ibm,acpx1-4xx; + compatible = ibm,acpx1-4xx,ibm,47x-AMP; + dcr-parent = {/cpus/cpu@0}; + + aliases { + serial0 = UART0; + serial1 = UART1; + rapidio0 = rio0; + ethernet0 = FEMAC; + }; + + cpus { + #address-cells = 1; + #size-cells = 0; + + cpu@0 { + device_type = cpu; + model = PowerPC,4xx; // real CPU changed in sim + reg = 0; +clock-frequency = 0x5f5e1000; +timebase-frequency = 0x5f5e1000; + i-cache-line-size = 32; + d-cache-line-size = 32; + i-cache-size = 32768; + d-cache-size = 32768; + dcr-controller; + dcr-access-method = native; + status = ok; + reset-type = 3; // 1=core, 2=chip, 3=system (default) + }; + cpu@1 { + device_type = cpu; + model = PowerPC,4xx; // real CPU changed in sim + reg = 1; +clock-frequency = 0x5f5e1000; +timebase-frequency = 0x5f5e1000; + i-cache-line-size = 32; + d-cache-line-size = 32; + i-cache-size = 32768; + d-cache-size = 32768; + dcr-controller; + dcr-access-method = native; + status = disabled; + enable-method = spin-table; + cpu-release-addr = 0 0x2040; + reset-type = 3; // 1=core, 2=chip, 3=system (default) + }; + }; + +memory@0 { +device_type = memory; +reg = 0x 0x 0x1000; +}; + +memory@8000 { +device_type = memory; +reg = 0x 0x 0x; +}; + + MPIC: interrupt-controller { + compatible = chrp,open-pic; + interrupt-controller; + dcr-reg = 0xffc0 0x0003; + #address-cells = 0; + #size-cells = 0; + #interrupt-cells = 2; + pic-no-reset; + }; + + plb { + /* Could be PLB6, doesn't matter */ + compatible = ibm,plb-4xx, ibm,plb4; + #address-cells = 2; + #size-cells = 1; + ranges; + clock-frequency = 0; // Filled in by zImage + + POB0: opb { + compatible = ibm,opb-4xx, ibm,opb; + #address-cells = 1; + #size-cells = 1; + /* Wish there was a nicer way of specifying a full 32-bit + range */ + ranges = 0x 0x0020 0x 0x8000 + 0x8000 0x0020 0x8000 0x8000; + clock-frequency = 0; // Filled in by zImage + UART0: serial@00404000 { +
[linux-yocto] [PATCH 08/28] axxia: Fixed earlyprintk
From: Anders Berg anders.b...@lsi.com Add static mapping of the UART registers for CONFIG_DEBUG_LL. Also depends on commit 2f409a to fix a bug with LPAE and static mappings. Signed-off-by: Anders Berg anders.b...@lsi.com --- arch/arm/Kconfig.debug |9 + arch/arm/mach-axxia/axxia.c| 13 arch/arm/mach-axxia/include/mach/debug-macro.S | 16 --- arch/arm/mach-axxia/include/mach/hardware.h| 25 +++- 4 files changed, 50 insertions(+), 13 deletions(-) diff --git a/arch/arm/Kconfig.debug b/arch/arm/Kconfig.debug index 85348a0..762903c 100644 --- a/arch/arm/Kconfig.debug +++ b/arch/arm/Kconfig.debug @@ -89,6 +89,15 @@ choice bool Kernel low-level debugging on 9263 and 9g45 depends on HAVE_AT91_DBGU1 + config AXXIA_DEBUG_LL_UART0 + bool Kernel low-level debugging via UART0 + depends on ARCH_AXXIA + help + This enables the low-level debugging via the UART0 + and should be used + with the + AXXIA hardware + config DEBUG_CLPS711X_UART1 bool Kernel low-level debugging messages via UART1 depends on ARCH_CLPS711X diff --git a/arch/arm/mach-axxia/axxia.c b/arch/arm/mach-axxia/axxia.c index df63dbd..7b725ef 100644 --- a/arch/arm/mach-axxia/axxia.c +++ b/arch/arm/mach-axxia/axxia.c @@ -46,6 +46,7 @@ #include asm/mach/time.h #include asm/hardware/cache-l2x0.h #include asm/hardware/gic.h +#include mach/hardware.h #include mach/timers.h #include mach/axxia-gic.h #include axxia.h @@ -62,8 +63,20 @@ static const char *axxia_dt_match[] __initconst = { static void __iomem *ssp_base; +static struct map_desc axxia_static_mappings[] __initdata = { +#ifdef CONFIG_DEBUG_LL + { + .virtual= AXXIA_DEBUG_UART_VIRT, + .pfn= __phys_to_pfn(AXXIA_DEBUG_UART_PHYS), + .length = SZ_4K, + .type = MT_DEVICE + }, +#endif +}; + void __init axxia_dt_map_io(void) { + iotable_init(axxia_static_mappings, ARRAY_SIZE(axxia_static_mappings)); } void __init axxia_dt_init_early(void) diff --git a/arch/arm/mach-axxia/include/mach/debug-macro.S b/arch/arm/mach-axxia/include/mach/debug-macro.S index 83d6670..3a3755b 100644 --- a/arch/arm/mach-axxia/include/mach/debug-macro.S +++ b/arch/arm/mach-axxia/include/mach/debug-macro.S @@ -10,6 +10,8 @@ * published by the Free Software Foundation. */ +#include mach/hardware.h + /* * -- NOTE -- * @@ -19,19 +21,9 @@ #error Axxia Peripherals Are Only Accessible Using the LPAE! #endif -#define UART0_PHYSICAL_ADDRESS 0x00201008ULL -#define UART1_PHYSICAL_ADDRESS 0x002010081000ULL -#define UART2_PHYSICAL_ADDRESS 0x002010082000ULL -#define UART3_PHYSICAL_ADDRESS 0x002010083000ULL - -#define UART0_VIRTUAL_ADDRESS 0xf008 -#define UART1_VIRTUAL_ADDRESS 0xf0081000 -#define UART2_VIRTUAL_ADDRESS 0xf0082000 -#define UART3_VIRTUAL_ADDRESS 0xf0083000 - .macro addruart, rp, rv, tmp - ldr \rp, =0x1008 - ldr \rv, =0xf008 + ldr \rp, =(AXXIA_DEBUG_UART_PHYS 0x) + ldr \rv, =AXXIA_DEBUG_UART_VIRT .endm #include asm/hardware/debug-pl01x.S diff --git a/arch/arm/mach-axxia/include/mach/hardware.h b/arch/arm/mach-axxia/include/mach/hardware.h index 40a8c17..ce3790f 100644 --- a/arch/arm/mach-axxia/include/mach/hardware.h +++ b/arch/arm/mach-axxia/include/mach/hardware.h @@ -1 +1,24 @@ -/* empty */ +/* + * arch/arm/mach-axxia/include/mach/hardware.h + * + * Copyright (c) 2013 LSI Corporation + * + * This program is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License as published by the + * Free Software Foundation; either version 2 of the License, or (at your + * option) any later version. + */ +#ifndef __MACH_HARDWARE_H +#define __MACH_HARDWARE_H + +#define AXXIA_UART0_PHYS 0x201008 +#define AXXIA_UART1_PHYS 0x2010081000 +#define AXXIA_UART2_PHYS 0x2010082000 +#define AXXIA_UART3_PHYS 0x2010083000 + +#ifdef CONFIG_AXXIA_DEBUG_LL_UART0 +#define AXXIA_DEBUG_UART_VIRT 0xf008 +#define AXXIA_DEBUG_UART_PHYS AXXIA_UART0_PHYS +#endif + +#endif -- 1.7.9.5 -- ___ linux-yocto mailing list linux-yocto@yoctoproject.org https://lists.yoctoproject.org/listinfo/linux-yocto
[linux-yocto] [PATCH 09/28] axxia: Define arch_is_coherent()
From: Anders Berg anders.b...@lsi.com By defining arch_is_coherent() == 1, we can avoid unnecessary cache maintenance operations and the dma_alloc_coherent() will return normal memory. Signed-off-by: Anders Berg anders.b...@lsi.com --- arch/arm/Kconfig |1 + arch/arm/mach-axxia/include/mach/memory.h | 19 +++ drivers/usb/host/ehci-ci13612.c | 12 ++-- 3 files changed, 26 insertions(+), 6 deletions(-) create mode 100644 arch/arm/mach-axxia/include/mach/memory.h diff --git a/arch/arm/Kconfig b/arch/arm/Kconfig index 370eca8..f763ad1 100644 --- a/arch/arm/Kconfig +++ b/arch/arm/Kconfig @@ -340,6 +340,7 @@ config ARCH_AXXIA select ARM_TIMER_SP804 select ICST select NEED_MACH_IO_H + select NEED_MACH_MEMORY_H select ZONE_DMA select PCI select PCI_DOMAINS if PCI diff --git a/arch/arm/mach-axxia/include/mach/memory.h b/arch/arm/mach-axxia/include/mach/memory.h new file mode 100644 index 000..9df2aaf --- /dev/null +++ b/arch/arm/mach-axxia/include/mach/memory.h @@ -0,0 +1,19 @@ +/* + * arch/arm/mach-axxia/include/mach/memory.h + * + * Copyright (c) 2013 LSI Corporation + * + * This program is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License as published by the + * Free Software Foundation; either version 2 of the License, or (at your + * option) any later version. + */ + +#ifndef __ASM_ARCH_MEMORY_H +#define __ASM_ARCH_MEMORY_H + +#include mach/hardware.h + +#define arch_is_coherent() 1 + +#endif diff --git a/drivers/usb/host/ehci-ci13612.c b/drivers/usb/host/ehci-ci13612.c index 2a30dab..b995a32 100644 --- a/drivers/usb/host/ehci-ci13612.c +++ b/drivers/usb/host/ehci-ci13612.c @@ -138,8 +138,7 @@ ci13612_fixup_usbcmd_rs(struct ehci_hcd *ehci) port_status = ehci_readl(ehci, ehci-regs-port_status[0]); pr_info(ehci-ci13612: port_status = 0x%x\n, port_status); if (port_status 0x100) { - pr_err(ehci-ci13612: USB port is in reset status, - not able to change HC status to run\n); + pr_err(ehci-ci13612: USB port is in reset status, not able to change HC status to run\n); return -EFAULT; } return 0; @@ -171,7 +170,7 @@ ci13612_fixup_txpburst(struct ehci_hcd *ehci) ehci_writel(ehci, burst_size, ehci-regs-reserved[1]); } #else -#define ci13612_fixup_txpburst(ehci) do { (void)ehci; } while(0) +#define ci13612_fixup_txpburst(ehci) do { (void)ehci; } while (0) #endif static int ci13612_ehci_run(struct usb_hcd *hcd) @@ -260,7 +259,8 @@ static int ci13612_ehci_probe(struct platform_device *pdev) pdev-dev.coherent_dma_mask = DMA_BIT_MASK(32); pdev-dev.dma_mask = pdev-dev.coherent_dma_mask; - hcd = usb_create_hcd(ci13612_hc_driver, pdev-dev, dev_name(pdev-dev)); + hcd = usb_create_hcd(ci13612_hc_driver, pdev-dev, + dev_name(pdev-dev)); if (!hcd) { retval = -ENOMEM; goto fail_create_hcd; @@ -285,8 +285,8 @@ static int ci13612_ehci_probe(struct platform_device *pdev) /* Set address bits [39:32] to zero */ writel(0x0, gpreg_base + 0x8); #ifndef CONFIG_LSI_USB_SW_WORKAROUND - /* hprot pass-through (let the controller drive hprot[0:3] */ - writel(0x100, gpreg_base + 0x74); + /* hprot cachable and bufferable */ + writel(0xc, gpreg_base + 0x74); #endif iounmap(gpreg_base); } -- 1.7.9.5 -- ___ linux-yocto mailing list linux-yocto@yoctoproject.org https://lists.yoctoproject.org/listinfo/linux-yocto
[linux-yocto] [PATCH 12/28] ARM: LPAE: use phys_addr_t in alloc_init_pud()
From: Anders Berg anders.b...@lsi.com commit 20d6956d8cd2452cec0889ff040f18afc03c2e6b upstream This patch fixes the alloc_init_pud() function to use phys_addr_t instead of unsigned long when passing in the phys argument. This is an extension to commit 97092e0 (ARM: pgtable: use phys_addr_t for physical addresses), which applied similar changes elsewhere in the ARM memory management code. Signed-off-by: Vitaly Andrianov vita...@ti.com Signed-off-by: Cyril Chemparathy cy...@ti.com Acked-by: Nicolas Pitre n...@linaro.org Acked-by: Catalin Marinas catalin.mari...@arm.com Tested-by: Santosh Shilimkar santosh.shilim...@ti.com Tested-by: Subash Patel subash...@samsung.com Signed-off-by: Will Deacon will.dea...@arm.comarm: mmu: Fix truncated 40-bit physaddr (LPAE) Signed-off-by: Anders Berg anders.b...@lsi.com --- arch/arm/mm/mmu.c |2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/arch/arm/mm/mmu.c b/arch/arm/mm/mmu.c index f117e1f..0acc475 100644 --- a/arch/arm/mm/mmu.c +++ b/arch/arm/mm/mmu.c @@ -628,7 +628,7 @@ static void __init alloc_init_section(pud_t *pud, unsigned long addr, } static void __init alloc_init_pud(pgd_t *pgd, unsigned long addr, - unsigned long end, unsigned long phys, const struct mem_type *type) + unsigned long end, phys_addr_t phys, const struct mem_type *type) { pud_t *pud = pud_offset(pgd, addr); unsigned long next; -- 1.7.9.5 -- ___ linux-yocto mailing list linux-yocto@yoctoproject.org https://lists.yoctoproject.org/listinfo/linux-yocto
[linux-yocto] [PATCH 17/28] arch/arm/mach-axxia: Clear MTC Errors During Initialization
From: John Jacques john.jacq...@lsi.com The MTC status registers are not cleared by a reset. So, clear them during driver initialization. Signed-off-by: John Jacques john.jacq...@lsi.com --- drivers/misc/lsi-mtc.c |9 - 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/drivers/misc/lsi-mtc.c b/drivers/misc/lsi-mtc.c index ebbdac8..8e1ae77 100644 --- a/drivers/misc/lsi-mtc.c +++ b/drivers/misc/lsi-mtc.c @@ -2731,6 +2731,7 @@ mtc_dev_ioctl(struct file *filp, unsigned int cmd, unsigned long arg) { struct ncp_axis_mtc_MTC_CONFIG0_REG_ADDR_r_t cfg0 = { 0 }; int start_stop; + if (copy_from_user ((void *)start_stop, (void *)arg, sizeof(int))) { printk(KERN_DEBUG MTC Error ioctl\n); @@ -2740,6 +2741,10 @@ mtc_dev_ioctl(struct file *filp, unsigned int cmd, unsigned long arg) if ((start_stop != 0) (start_stop != 1)) return -EINVAL; + /* clear interrupt status before hit start */ + if (start_stop == 1) + dev-regs-int_status = 0x7f; + cfg0 = *((struct ncp_axis_mtc_MTC_CONFIG0_REG_ADDR_r_t *) (dev-regs-config0)); @@ -3080,6 +3085,8 @@ static long _mtc_config(struct mtc_device *dev, struct lsi_mtc_cfg_t *pMTCCfg) dev-regs-config1, dev-regs-execute); #endif - /* test */ + /* clear ecc interrupt status */ + dev-regs-ecc_int_status = 0xf; + return 0; } -- 1.7.9.5 -- ___ linux-yocto mailing list linux-yocto@yoctoproject.org https://lists.yoctoproject.org/listinfo/linux-yocto
[linux-yocto] [PATCH 19/28] arm/mach-axxia: Updated PCIe driver to set PCIe
From: Paul Butler paul.but...@windriver.com BASE_ADDR1 register Updated PCIe driver to set PCIe BASE_ADDR1 register to 0x0 without which PCIe inbound access wasn't working and we were seeing several suprious PEI interrupts including BAR mismatch interrupt. Signed-off-by: SangeethaRao sangeetha@lsi.com Signed-off-by: Paul Butler paul.but...@windriver.com --- arch/arm/mach-axxia/pci.c |7 +-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/arch/arm/mach-axxia/pci.c b/arch/arm/mach-axxia/pci.c index 2600892..49565e8 100644 --- a/arch/arm/mach-axxia/pci.c +++ b/arch/arm/mach-axxia/pci.c @@ -667,20 +667,23 @@ static int axxia_pcie_setup(int portno, struct pci_sys_data *sys) /* Configure the inbound window size */ inbound_size = (u32) resource_size(port-inbound); - writel(inbound_size, port-regs + PCIE_RC_BAR0_SIZE); + writel(~(inbound_size-1), port-regs + PCIE_RC_BAR0_SIZE); /* Verify BAR0 size */ { u32 bar0_size; writel(~0, port-regs + PCI_BASE_ADDRESS_0); bar0_size = readl(port-regs + PCI_BASE_ADDRESS_0); - if ((bar0_size ~0xf) != inbound_size) + if ((bar0_size ~0xf) != ~(inbound_size-1)) pr_err(PCIE%d: Config BAR0 failed\n, port-index); } /* Set the BASE0 address to start of PCIe base */ writel(port-pci_bar, port-regs + PCI_BASE_ADDRESS_0); + /* Set the BASE1 address to 0x0 */ + writel(0x0, port-regs + PCI_BASE_ADDRESS_1); + /* Setup TPAGE registers for inbound mapping * * We set the MSB of each TPAGE to select 128-bit AXI access. For the -- 1.7.9.5 -- ___ linux-yocto mailing list linux-yocto@yoctoproject.org https://lists.yoctoproject.org/listinfo/linux-yocto
[linux-yocto] [PATCH 10/28] LSI AXM55xx: Enable multi-cluster wfe/sev
From: David Mercado david.merc...@windriver.com By default, the system does not enable the use of ARM wfe/sev instructions across clusters, which breaks things like arch_spin_lock. This patch enables this feature. LSI AXM55xx: Disable use of wfe/sev in arch_spin_lock By default, the system does not enable the use of ARM wfe/sev instructions across clusters, which breaks things like arch_spin_lock. The previous solution to enable wfe/sev to work across clusters still resulted in CPU stalls. This patch instead removes the use of wfe/sev in arch/arm/include/ asm/spinlock.h altogether. Signed-off-by: David Mercado david.merc...@windriver.com --- arch/arm/include/asm/spinlock.h |4 arch/arm/mach-axxia/axxia.c |1 + 2 files changed, 5 insertions(+) diff --git a/arch/arm/include/asm/spinlock.h b/arch/arm/include/asm/spinlock.h index 65fa3c8..022ef90 100644 --- a/arch/arm/include/asm/spinlock.h +++ b/arch/arm/include/asm/spinlock.h @@ -37,6 +37,10 @@ \ nop.w \ ) +#elif CONFIG_ARCH_AXXIA || CONFIG_ARCH_AXXIA_SIM +/* Disable use of wfe/sev in Axxia. */ +#define SEV +#define WFE(cond) #else #define SEVALT_SMP(sev, nop) #define WFE(cond) ALT_SMP(wfe cond, nop) diff --git a/arch/arm/mach-axxia/axxia.c b/arch/arm/mach-axxia/axxia.c index 7b725ef..d87bb61 100644 --- a/arch/arm/mach-axxia/axxia.c +++ b/arch/arm/mach-axxia/axxia.c @@ -253,6 +253,7 @@ l3_set_pstate(void __iomem *l3ctrl, unsigned int req, unsigned int act) void __init axxia_dt_init(void) { void __iomem *l3ctrl; + void __iomem *apb2ser3_base; int rc; /* Enable L3-cache */ -- 1.7.9.5 -- ___ linux-yocto mailing list linux-yocto@yoctoproject.org https://lists.yoctoproject.org/listinfo/linux-yocto
[linux-yocto] [PATCH 13/28] ARM: 7499/1: mm: Fix vmalloc overlap check for !HIGHMEM
From: Anders Berg anders.b...@lsi.com commit 36418c516b31bff4ff949c7c618430a1a514debe upstream With !HIGHMEM, sanity_check_meminfo checks for banks that completely or partially overlap the vmalloc region. The test for partial overlap checks __va(bank-start + bank-size) vmalloc_min. This is not appropriate if there is a non-linear translation between virtual and physical addresses, as bank-start + bank-size is actually in the bank following the one being interrogated. In most cases, even when using SPARSEMEM, this is not problematic as the subsequent bank will start at a higher va than the one in question. However if the physical to virtual address conversion is not monotonic increasing, the incorrect test could result in a bank not being truncated when it should be. This patch ensures we perform the va-pa conversion on memory from the bank we are interested in, not the following one. Reported-by: ??? (Steve) zhanzhe...@gmail.com Signed-off-by: Jonathan Austin jonathan.aus...@arm.com Acked-by: Nicolas Pitre n...@linaro.org Signed-off-by: Russell King rmk+ker...@arm.linux.org.ukarm/mmu: Fix detection of vmalloc area overlap Signed-off-by: Anders Berg anders.b...@lsi.com --- arch/arm/mm/mmu.c |4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/arch/arm/mm/mmu.c b/arch/arm/mm/mmu.c index 0acc475..571102e 100644 --- a/arch/arm/mm/mmu.c +++ b/arch/arm/mm/mmu.c @@ -967,8 +967,8 @@ void __init sanity_check_meminfo(void) * Check whether this memory bank would partially overlap * the vmalloc area. */ - if (__va(bank-start + bank-size) vmalloc_min || - __va(bank-start + bank-size) __va(bank-start)) { + if (__va(bank-start + bank-size - 1) = vmalloc_min || + __va(bank-start + bank-size - 1) = __va(bank-start)) { unsigned long newsize = vmalloc_min - __va(bank-start); printk(KERN_NOTICE Truncating RAM at %.8llx-%.8llx to -%.8llx (vmalloc region overlap).\n, -- 1.7.9.5 -- ___ linux-yocto mailing list linux-yocto@yoctoproject.org https://lists.yoctoproject.org/listinfo/linux-yocto
[linux-yocto] [PATCH 16/28] arch/powerpc/sysdev: Fixed PCIe enumeration issue on AXM3500 emulation
From: SangeethaRao sangeetha@lsi.com Signed-off-by: SangeethaRao sangeetha@lsi.com --- arch/powerpc/sysdev/lsi_pci.c | 19 ++- 1 file changed, 14 insertions(+), 5 deletions(-) diff --git a/arch/powerpc/sysdev/lsi_pci.c b/arch/powerpc/sysdev/lsi_pci.c index a25d396..75bdf53 100644 --- a/arch/powerpc/sysdev/lsi_pci.c +++ b/arch/powerpc/sysdev/lsi_pci.c @@ -20,6 +20,7 @@ #include mm/mmu_decl.h #include ppc4xx_pci.h +#include ../../../drivers/misc/lsi-ncr.h #include linux/interrupt.h @@ -70,6 +71,7 @@ fixup_acp_pci_bridge(struct pci_dev *dev) DECLARE_PCI_FIXUP_HEADER(0x1000, 0x5101, fixup_acp_pci_bridge); DECLARE_PCI_FIXUP_HEADER(0x1000, 0x5108, fixup_acp_pci_bridge); +DECLARE_PCI_FIXUP_HEADER(0x1000, 0x5102, fixup_acp_pci_bridge); static int __init acp_parse_dma_ranges(struct pci_controller *hose, void __iomem *reg, @@ -954,6 +956,7 @@ acp_pciex_port_setup_hose(struct pciex_port *port) u32 pci_status; u32 link_state; u32 pci_config; + u32 version; /* Check if primary bridge */ if (of_get_property(port-node, primary, NULL)) @@ -1060,6 +1063,17 @@ acp_pciex_port_setup_hose(struct pciex_port *port) } } + /* get the device version */ + if (0 != ncr_read(NCP_REGION_ID(0x16, 0xff), 0x0, 4, version)) { + printk(KERN_ERR Unable to detect ACP revision!\n); + goto fail; + } + + port-acpChipType = (version 0xff); + printk(KERN_INFO Using PEI register set for ACP chipType %d\n, + port-acpChipType); + + /* * Set bus numbers on our root port */ @@ -1171,11 +1185,6 @@ static void __init probe_acp_pciex_bridge(struct device_node *np) return; } - - port-acpChipType = 0x2; - printk(KERN_INFO Using PEI register set for ACP chipType %d\n, - port-acpChipType); - /* Check for the PLX work-around. */ field = of_get_property(np, plx, NULL); -- 1.7.9.5 -- ___ linux-yocto mailing list linux-yocto@yoctoproject.org https://lists.yoctoproject.org/listinfo/linux-yocto
[linux-yocto] [PATCH 20/28] LSI AXM55XX: Add PMU support
From: David Mercado david.merc...@windriver.com This patch adds PMU support to the Axxia AXM55xx platform. Note that on this platform, all PMU IRQ lines are OR'ed together into a single IRQ, and therefore, this implementation uses a rotating IRQ affinity scheme to deal with it. Signed-off-by: David Mercado david.merc...@windriver.com --- arch/arm/kernel/perf_event_v7.c |3 +- arch/arm/mach-axxia/axxia-gic.c | 25 -- arch/arm/mach-axxia/axxia.c | 55 +++ arch/arm/mach-axxia/include/mach/irqs.h |1 + 4 files changed, 81 insertions(+), 3 deletions(-) diff --git a/arch/arm/kernel/perf_event_v7.c b/arch/arm/kernel/perf_event_v7.c index 7deaa7f..ae7d9d8 100644 --- a/arch/arm/kernel/perf_event_v7.c +++ b/arch/arm/kernel/perf_event_v7.c @@ -95,6 +95,7 @@ enum armv7_a5_perf_types { /* ARMv7 Cortex-A15 specific event types */ enum armv7_a15_perf_types { + ARMV7_A15_PERFCTR_CPU_CYCLES= 0x11, ARMV7_A15_PERFCTR_L1_DCACHE_ACCESS_READ = 0x40, ARMV7_A15_PERFCTR_L1_DCACHE_ACCESS_WRITE= 0x41, ARMV7_A15_PERFCTR_L1_DCACHE_REFILL_READ = 0x42, @@ -489,7 +490,7 @@ static const unsigned armv7_a5_perf_cache_map[PERF_COUNT_HW_CACHE_MAX] * Cortex-A15 HW events mapping */ static const unsigned armv7_a15_perf_map[PERF_COUNT_HW_MAX] = { - [PERF_COUNT_HW_CPU_CYCLES] = ARMV7_PERFCTR_CPU_CYCLES, + [PERF_COUNT_HW_CPU_CYCLES] = ARMV7_A15_PERFCTR_CPU_CYCLES, [PERF_COUNT_HW_INSTRUCTIONS]= ARMV7_PERFCTR_INSTR_EXECUTED, [PERF_COUNT_HW_CACHE_REFERENCES]= ARMV7_PERFCTR_L1_DCACHE_ACCESS, [PERF_COUNT_HW_CACHE_MISSES]= ARMV7_PERFCTR_L1_DCACHE_REFILL, diff --git a/arch/arm/mach-axxia/axxia-gic.c b/arch/arm/mach-axxia/axxia-gic.c index e5ad304..8a8e8eb 100644 --- a/arch/arm/mach-axxia/axxia-gic.c +++ b/arch/arm/mach-axxia/axxia-gic.c @@ -283,6 +283,10 @@ static void gic_mask_irq(struct irq_data *d) if ((irqid = IPI0_CPU0) (irqid MAX_AXM_IPI_NUM)) return; + /* Don't mess with the PMU IRQ either. */ + if (irqid == IRQ_PMU) + return; + /* Deal with PPI interrupts directly. */ if ((irqid 16) (irqid 32)) { _gic_mask_irq(d); @@ -327,6 +331,10 @@ static void gic_unmask_irq(struct irq_data *d) if ((irqid = IPI0_CPU0) (irqid MAX_AXM_IPI_NUM)) return; + /* Don't mess with the PMU IRQ either. */ + if (irqid == IRQ_PMU) + return; + /* Deal with PPI interrupts directly. */ if ((irqid 15) (irqid 32)) { _gic_unmask_irq(d); @@ -565,8 +573,8 @@ static int gic_set_affinity(struct irq_data *d, * different than the prior cluster, remove the IRQ affinity * on the old cluster. */ - if ((cpu_logical_map(cpu) / CORES_PER_CLUSTER) != - (irq_cpuid[irqid] / CORES_PER_CLUSTER)) { + if ((irqid != IRQ_PMU) ((cpu_logical_map(cpu) / CORES_PER_CLUSTER) != + (irq_cpuid[irqid] / CORES_PER_CLUSTER))) { /* * If old cpu assignment falls within the same cluster as * the cpu we're currently running on, set the IRQ affinity @@ -775,6 +783,11 @@ static void __cpuinit gic_dist_init(struct gic_chip_data *gic) } /* +* Set the PMU IRQ to the first cpu in this cluster. +*/ + writeb_relaxed(0x01, base + GIC_DIST_TARGET + IRQ_PMU); + + /* * Set Axxia IPI interrupts to be edge triggered. */ for (i = IPI0_CPU0; i MAX_AXM_IPI_NUM; i++) { @@ -797,6 +810,14 @@ static void __cpuinit gic_dist_init(struct gic_chip_data *gic) base + GIC_DIST_ENABLE_SET + enableoff); } + /* +* Do the initial enable of the PMU IRQ here. +*/ + enablemask = 1 (IRQ_PMU % 32); + enableoff = (IRQ_PMU / 32) * 4; + writel_relaxed(enablemask, + base + GIC_DIST_ENABLE_SET + enableoff); + writel_relaxed(1, base + GIC_DIST_CTRL); } diff --git a/arch/arm/mach-axxia/axxia.c b/arch/arm/mach-axxia/axxia.c index 0e368a4..1c1f20e 100644 --- a/arch/arm/mach-axxia/axxia.c +++ b/arch/arm/mach-axxia/axxia.c @@ -46,6 +46,7 @@ #include asm/mach/time.h #include asm/hardware/cache-l2x0.h #include asm/hardware/gic.h +#include asm/pmu.h #include mach/hardware.h #include mach/timers.h #include mach/axxia-gic.h @@ -178,6 +179,58 @@ static struct of_dev_auxdata axxia_auxdata_lookup[] __initdata = { {} }; +static struct resource axxia_pmu_resources[] = { + [0] = { + .start = IRQ_PMU, + .end= IRQ_PMU, + .flags = IORESOURCE_IRQ, + }, +}; + +/* + * The PMU IRQ lines of four cores are wired together into a single interrupt. + * Bounce the interrupt
[linux-yocto] [PATCH 11/28] ARM: 7465/1: Handle 4GB memory sizes in device tree and mem=size@start option
From: Anders Berg anders.b...@lsi.com commit a5d5f7daa744b34477c4a12728bde0a1694a1707 upstream The memory regions which are passed to arm_add_memory() from device tree blobs via early_init_dt_add_memory_arch() can have sizes which are larger than will fit in a 32 bit integer, so switch to using a phys_addr_t to hold them, to avoid silently dropping the top 32 bits of the size. Similarly, use phys_addr_t in early_mem() so that mem=size@start command line options specifying more than 4GB behave sensibly. Acked-by: Will Deacon will.dea...@arm.com Signed-off-by: Peter Maydell peter.mayd...@linaro.org Signed-off-by: Russell King rmk+ker...@arm.linux.org.ukarm: Allow =4GB RAM to be configured Signed-off-by: Anders Berg anders.b...@lsi.com --- arch/arm/include/asm/setup.h | 14 - arch/arm/kernel/setup.c | 70 +- 2 files changed, 42 insertions(+), 42 deletions(-) diff --git a/arch/arm/include/asm/setup.h b/arch/arm/include/asm/setup.h index 23ebc0c..0fbe56d 100644 --- a/arch/arm/include/asm/setup.h +++ b/arch/arm/include/asm/setup.h @@ -173,14 +173,14 @@ struct tagtable { int (*parse)(const struct tag *); }; -#define tag_member_present(tag,member) \ +#define tag_member_present(tag, member)\ ((unsigned long)(((struct tag *)0L)-member + 1) \ = (tag)-hdr.size * 4) #define tag_next(t)((struct tag *)((__u32 *)(t) + (t)-hdr.size)) #define tag_size(type) ((sizeof(struct tag_header) + sizeof(struct type)) 2) -#define for_each_tag(t,base) \ +#define for_each_tag(t, base) \ for (t = base; t-hdr.size; t = tag_next(t)) #ifdef __KERNEL__ @@ -196,7 +196,7 @@ static const struct tagtable __tagtable_##fn __tag = { tag, fn } struct membank { phys_addr_t start; - unsigned long size; + phys_addr_t size; unsigned int highmem; }; @@ -207,17 +207,17 @@ struct meminfo { extern struct meminfo meminfo; -#define for_each_bank(iter,mi) \ +#define for_each_bank(iter, mi)\ for (iter = 0; iter (mi)-nr_banks; iter++) #define bank_pfn_start(bank) __phys_to_pfn((bank)-start) #define bank_pfn_end(bank) __phys_to_pfn((bank)-start + (bank)-size) #define bank_pfn_size(bank)((bank)-size PAGE_SHIFT) -#define bank_phys_start(bank) (bank)-start +#define bank_phys_start(bank) ((bank)-start) #define bank_phys_end(bank)((bank)-start + (bank)-size) -#define bank_phys_size(bank) (bank)-size +#define bank_phys_size(bank) ((bank)-size) -extern int arm_add_memory(phys_addr_t start, unsigned long size); +extern int arm_add_memory(phys_addr_t start, phys_addr_t size); extern void early_print(const char *str, ...); extern void dump_machine_table(void); diff --git a/arch/arm/kernel/setup.c b/arch/arm/kernel/setup.c index 467155b..ad28e29 100644 --- a/arch/arm/kernel/setup.c +++ b/arch/arm/kernel/setup.c @@ -328,7 +328,7 @@ static void __init cacheid_init(void) cacheid = CACHEID_VIVT; } - printk(CPU: %s data cache, %s instruction cache\n, + printk(KERN_INFO CPU: %s data cache, %s instruction cache\n, cache_is_vivt() ? VIVT : cache_is_vipt_aliasing() ? VIPT aliasing : cache_is_vipt_nonaliasing() ? PIPT / VIPT nonaliasing : unknown, @@ -358,7 +358,7 @@ void __init early_print(const char *str, ...) #ifdef CONFIG_DEBUG_LL printascii(buf); #endif - printk(%s, buf); + printk(KERN_INFO %s, buf); } static void __init feat_v6_fixup(void) @@ -419,13 +419,13 @@ void cpu_init(void) msrcpsr_c, %7 : : r (stk), - PLC (PSR_F_BIT | PSR_I_BIT | IRQ_MODE), + PLC(PSR_F_BIT | PSR_I_BIT | IRQ_MODE), I (offsetof(struct stack, irq[0])), - PLC (PSR_F_BIT | PSR_I_BIT | ABT_MODE), + PLC(PSR_F_BIT | PSR_I_BIT | ABT_MODE), I (offsetof(struct stack, abt[0])), - PLC (PSR_F_BIT | PSR_I_BIT | UND_MODE), + PLC(PSR_F_BIT | PSR_I_BIT | UND_MODE), I (offsetof(struct stack, und[0])), - PLC (PSR_F_BIT | PSR_I_BIT | SVC_MODE) + PLC(PSR_F_BIT | PSR_I_BIT | SVC_MODE) : r14); } @@ -454,9 +454,10 @@ static void __init setup_processor(void) */ list = lookup_processor_type(read_cpuid_id()); if (!list) { - printk(CPU configuration botched (ID %08x), unable - to continue.\n, read_cpuid_id()); - while (1); + printk(KERN_INFO CPU configuration botched (ID %08x), unable to continue.\n, + read_cpuid_id()); + while (1) + ; } cpu_name = list-cpu_name; @@ -475,7 +476,7 @@ static void __init setup_processor(void)
[linux-yocto] [PATCH 22/28] LSI: Fix Device Tree compatible fields
From: John Jacques john.jacq...@lsi.com The latest boot loader updates the frequency of the clocks in the device tree; it expects there to be a place to put them. Fix the device trees for ACP and AXM platforms such that the compatible field uses the form manufacturer,model. Signed-off-by: John Jacques john.jacq...@lsi.com Signed-off-by: David Mercado david.merc...@windriver.com Signed-off-by: Paul Butler paul.but...@windriver.com --- arch/arm/boot/dts/axm55xx.dts |4 ++-- arch/arm/boot/dts/axm55xxemu.dts| 21 +++-- arch/powerpc/boot/dts/ACP344xV2.dts | 20 ++-- arch/powerpc/boot/dts/acp25xx.dts | 16 arch/powerpc/boot/dts/acp342x.dts | 14 +++--- arch/powerpc/boot/dts/acp344x.dts | 16 6 files changed, 54 insertions(+), 37 deletions(-) diff --git a/arch/arm/boot/dts/axm55xx.dts b/arch/arm/boot/dts/axm55xx.dts index f18550b..f0b325d 100644 --- a/arch/arm/boot/dts/axm55xx.dts +++ b/arch/arm/boot/dts/axm55xx.dts @@ -232,7 +232,7 @@ }; axxia_femac0: femac@0x201012 { - compatible = acp-femac; + compatible = lsi,acp-femac; device_type = network; reg = 0x20 0x1012 0 0x1000, 0x20 0x10121000 0 0x1000, @@ -314,7 +314,7 @@ USB0: usb@004a4000 { device_type = usb; - compatible = acp-usb; + compatible = lsi,acp-usb; enabled = 0; reg = 0x20 0x1014 0x0 002, 0x20 0x10094000 0x0 0002000; diff --git a/arch/arm/boot/dts/axm55xxemu.dts b/arch/arm/boot/dts/axm55xxemu.dts index 99d7a70..1b22b33 100644 --- a/arch/arm/boot/dts/axm55xxemu.dts +++ b/arch/arm/boot/dts/axm55xxemu.dts @@ -1,5 +1,5 @@ /* - * arch/arm/boot/dts/axm5500-sim.dts + * arch/arm/boot/dts/axm55xxemu.dts * * Copyright (C) 2012 LSI * @@ -93,6 +93,23 @@ */ }; + clocks { + #address-cells = 1; + #size-cells = 0; + + cpu { + frequency = 0; /* Filled in by the boot loader. */ + }; + + peripheral { + frequency = 0; /* Filled in by the boot loader. */ + }; + + emmc { + frequency = 0; /* Filled in by the boot loader. */ + }; + }; + memory@ { device_type = memory; reg = 0 0x 0 0x1000; @@ -153,7 +170,7 @@ }; axxia_femac0: femac@0x201012 { -compatible = acp-femac; +compatible = lsi,acp-femac; device_type = network; reg = 0x20 0x1012 0 0x1000, 0x20 0x10121000 0 0x1000, diff --git a/arch/powerpc/boot/dts/ACP344xV2.dts b/arch/powerpc/boot/dts/ACP344xV2.dts index 1a4040f..72db6b4 100644 --- a/arch/powerpc/boot/dts/ACP344xV2.dts +++ b/arch/powerpc/boot/dts/ACP344xV2.dts @@ -135,7 +135,7 @@ clock-frequency = 0; // Filled in by zImage UART0: serial@00404000 { device_type = serial; -compatible = acp-uart0; +compatible = lsi,acp-uart0; enabled = 0; reg = 0x00404000 0x1000; clock-reg = 0x00408040 0x20; @@ -146,7 +146,7 @@ }; UART1: serial@00405000 { device_type = serial; -compatible = acp-uart1; +compatible = lsi,acp-uart1; enabled = 0; reg = 0x00405000 0x1000; clock-reg = 0x00408060 0x20; @@ -157,7 +157,7 @@ }; USB0: usb@004a4000 { device_type = usb; -compatible = acp-usb; +compatible = lsi,acp-usb; enabled = 0; reg = 0x004a 0x0002 0x0040c000 0x1000; @@ -167,7 +167,7 @@ I2C: i2c@00403000 { #address-cells = 1; #size-cells = 0; -compatible = acp-i2c; +compatible = lsi,acp-i2c; enabled = 0; reg = 0x403000 0x1000 0x408020 0x1000; interrupt-parent = MPIC; @@ -182,7 +182,7 @@ #address-cells = 1; #size-cells = 0;
[linux-yocto] [PATCH 18/28] drivers/usb: USB driver/dts on PPC was broken.
From: SangeethaRao sangeetha@lsi.com Fixed the DTS to have correct entries and updated USB driver to exclude 55xx relevant code from PPC build drivers/usb: added a new ehci halt function New halt function halts the EHCI controller. This is to be called during startup since spinlocks are not initialized at that point. Signed-off-by: SangeethaRao sangeetha@lsi.com --- arch/powerpc/boot/dts/acp342x.dts |7 --- drivers/usb/host/ehci-ci13612.c | 30 +- 2 files changed, 33 insertions(+), 4 deletions(-) diff --git a/arch/powerpc/boot/dts/acp342x.dts b/arch/powerpc/boot/dts/acp342x.dts index 4db67df..8e400e3 100644 --- a/arch/powerpc/boot/dts/acp342x.dts +++ b/arch/powerpc/boot/dts/acp342x.dts @@ -112,9 +112,10 @@ }; USB0: usb@004a4000 { device_type = usb; -compatible = acp-usb; -enabled = 0; -reg = 0x004a4000 0x0002; +compatible = lsi,acp-usb; +enabled = 1; + reg = 0x20 0x004A 0x0 002, + 0x20 0x0040C000 0x0 0001000; interrupt-parent = MPIC; interrupts = 31; }; diff --git a/drivers/usb/host/ehci-ci13612.c b/drivers/usb/host/ehci-ci13612.c index b995a32..3badbd8 100644 --- a/drivers/usb/host/ehci-ci13612.c +++ b/drivers/usb/host/ehci-ci13612.c @@ -32,6 +32,8 @@ #include ehci-ci13612.h +static int ci13612_ehci_halt(struct ehci_hcd *ehci); + #ifdef CONFIG_LSI_USB_SW_WORKAROUND static void ci13612_usb_setup(struct usb_hcd *hcd) { @@ -104,7 +106,7 @@ static int ci13612_ehci_init(struct usb_hcd *hcd) ehci-sbrn = 0x20; /* Reset is only allowed on a stopped controller */ - ehci_halt(ehci); + ci13612_ehci_halt(ehci); /* reset controller */ ehci_reset(ehci); @@ -183,8 +185,11 @@ static int ci13612_ehci_run(struct usb_hcd *hcd) if (retval) return retval; + +#ifndef CONFIG_LSI_USB_SW_WORKAROUND /* Setup AMBA interface to force INCR16 busts when possible */ writel(3, USB_SBUSCFG); +#endif retval = ehci_run(hcd); if (retval) @@ -192,10 +197,12 @@ static int ci13612_ehci_run(struct usb_hcd *hcd) ci13612_fixup_txpburst(ehci); +#ifndef CONFIG_LSI_USB_SW_WORKAROUND /* Set ITC (bits [23:16]) to zero for interrupt on every micro-frame */ tmp = ehci_readl(ehci, ehci-regs-command); tmp = 0x; ehci_writel(ehci, tmp 0x, ehci-regs-command); +#endif return retval; } @@ -238,6 +245,7 @@ static int ci13612_ehci_probe(struct platform_device *pdev) irq = platform_get_irq(pdev, 0); if (irq 0) { + dev_dbg(pdev-dev, error getting irq number\n); retval = irq; goto fail_create_hcd; } @@ -255,9 +263,12 @@ static int ci13612_ehci_probe(struct platform_device *pdev) return -ENODEV; } + +#ifndef CONFIG_LSI_USB_SW_WORKAROUND /* Device using 32-bit addressing */ pdev-dev.coherent_dma_mask = DMA_BIT_MASK(32); pdev-dev.dma_mask = pdev-dev.coherent_dma_mask; +#endif hcd = usb_create_hcd(ci13612_hc_driver, pdev-dev, dev_name(pdev-dev)); @@ -316,6 +327,18 @@ static int ci13612_ehci_remove(struct platform_device *pdev) return 0; } +static int ci13612_ehci_halt(struct ehci_hcd *ehci) +{ + u32 temp; + + temp = ehci_readl(ehci, ehci-regs-command); + temp = ~CMD_RUN; + ehci_writel(ehci, temp, ehci-regs-command); + + return handshake(ehci, ehci-regs-status, + STS_HALT, STS_HALT, 16 * 125); +} + MODULE_ALIAS(platform:ci13612-ehci); static struct of_device_id ci13612_match[] = { @@ -323,6 +346,10 @@ static struct of_device_id ci13612_match[] = { .type = usb, .compatible = lsi,acp-usb, }, + { + .type = usb, + .compatible = acp-usb, + }, {}, }; @@ -333,4 +360,5 @@ static struct platform_driver ci13612_ehci_driver = { .name = ci13612-ehci, .of_match_table = ci13612_match, }, + }; -- 1.7.9.5 -- ___ linux-yocto mailing list linux-yocto@yoctoproject.org https://lists.yoctoproject.org/listinfo/linux-yocto
[linux-yocto] [PATCH 23/28] powerpc/mpic: Disable preemption when calling mpic_processor_id()
From: John Jacques john.jacq...@lsi.com commit 32dda05f4ec2b854b594bd91590c46c5197d77e1 upstream Otherwise, we get a debug traceback due to the use of smp_processor_id() (or get_paca()) inside hard_smp_processor_id(). mpic_host_map() is just looking for a default CPU, so it doesn't matter if we migrate after getting the CPU ID. Signed-off-by: Scott Wood scottw...@freescale.com Signed-off-by: Benjamin Herrenschmidt b...@kernel.crashing.org Signed-off-by: John Jacques john.jacq...@lsi.com --- arch/powerpc/sysdev/mpic.c | 119 +--- 1 file changed, 68 insertions(+), 51 deletions(-) diff --git a/arch/powerpc/sysdev/mpic.c b/arch/powerpc/sysdev/mpic.c index 9ee7043..a3d7951 100644 --- a/arch/powerpc/sysdev/mpic.c +++ b/arch/powerpc/sysdev/mpic.c @@ -142,7 +142,7 @@ static u32 mpic_infos[][MPIC_IDX_END] = { }, }; -#define MPIC_INFO(name) mpic-hw_set[MPIC_IDX_##name] +#define MPIC_INFO(name) (mpic-hw_set[MPIC_IDX_##name]) #else /* CONFIG_MPIC_WEIRD */ @@ -169,7 +169,7 @@ static inline u32 _mpic_read(enum mpic_reg_type type, struct mpic_reg_bank *rb, unsigned int reg) { - switch(type) { + switch (type) { #ifdef CONFIG_PPC_DCR case mpic_access_dcr: return dcr_read(rb-dhost, reg); @@ -183,10 +183,10 @@ static inline u32 _mpic_read(enum mpic_reg_type type, } static inline void _mpic_write(enum mpic_reg_type type, - struct mpic_reg_bank *rb, - unsigned int reg, u32 value) + struct mpic_reg_bank *rb, + unsigned int reg, u32 value) { - switch(type) { + switch (type) { #ifdef CONFIG_PPC_DCR case mpic_access_dcr: dcr_write(rb-dhost, reg, value); @@ -213,7 +213,8 @@ static inline u32 _mpic_ipi_read(struct mpic *mpic, unsigned int ipi) return _mpic_read(type, mpic-gregs, offset); } -static inline void _mpic_ipi_write(struct mpic *mpic, unsigned int ipi, u32 value) +static inline void _mpic_ipi_write(struct mpic *mpic, + unsigned int ipi, u32 value) { unsigned int offset = MPIC_INFO(GREG_IPI_VECTOR_PRI_0) + (ipi * MPIC_INFO(GREG_IPI_STRIDE)); @@ -250,14 +251,16 @@ static inline u32 _mpic_cpu_read(struct mpic *mpic, unsigned int reg) return _mpic_read(mpic-reg_type, mpic-cpuregs[cpu], reg); } -static inline void _mpic_cpu_write(struct mpic *mpic, unsigned int reg, u32 value) +static inline void _mpic_cpu_write(struct mpic *mpic, + unsigned int reg, u32 value) { unsigned int cpu = mpic_processor_id(mpic); _mpic_write(mpic-reg_type, mpic-cpuregs[cpu], reg, value); } -static inline u32 _mpic_irq_read(struct mpic *mpic, unsigned int src_no, unsigned int reg) +static inline u32 _mpic_irq_read(struct mpic *mpic, + unsigned int src_no, unsigned int reg) { unsigned intisu = src_no mpic-isu_shift; unsigned intidx = src_no mpic-isu_mask; @@ -289,16 +292,16 @@ static inline void _mpic_irq_write(struct mpic *mpic, unsigned int src_no, #endif } -#define mpic_read(b,r) _mpic_read(mpic-reg_type,(b),(r)) -#define mpic_write(b,r,v) _mpic_write(mpic-reg_type,(b),(r),(v)) -#define mpic_ipi_read(i) _mpic_ipi_read(mpic,(i)) -#define mpic_ipi_write(i,v)_mpic_ipi_write(mpic,(i),(v)) -#define mpic_tm_read(i)_mpic_tm_read(mpic,(i)) -#define mpic_tm_write(i,v) _mpic_tm_write(mpic,(i),(v)) -#define mpic_cpu_read(i) _mpic_cpu_read(mpic,(i)) -#define mpic_cpu_write(i,v)_mpic_cpu_write(mpic,(i),(v)) -#define mpic_irq_read(s,r) _mpic_irq_read(mpic,(s),(r)) -#define mpic_irq_write(s,r,v) _mpic_irq_write(mpic,(s),(r),(v)) +#define mpic_read(b, r)_mpic_read(mpic-reg_type, (b), (r)) +#define mpic_write(b, r, v)_mpic_write(mpic-reg_type, (b), (r), (v)) +#define mpic_ipi_read(i) _mpic_ipi_read(mpic, (i)) +#define mpic_ipi_write(i, v) _mpic_ipi_write(mpic, (i), (v)) +#define mpic_tm_read(i)_mpic_tm_read(mpic, (i)) +#define mpic_tm_write(i, v)_mpic_tm_write(mpic, (i), (v)) +#define mpic_cpu_read(i) _mpic_cpu_read(mpic, (i)) +#define mpic_cpu_write(i, v) _mpic_cpu_write(mpic, (i), (v)) +#define mpic_irq_read(s, r)_mpic_irq_read(mpic, (s), (r)) +#define mpic_irq_write(s, r, v)_mpic_irq_write(mpic, (s), (r), (v)) /* @@ -333,7 +336,7 @@ static inline void mpic_map(struct mpic *mpic, _mpic_map_mmio(mpic, phys_addr, rb, offset, size); } #else /* CONFIG_PPC_DCR */ -#define mpic_map(m,p,b,o,s)_mpic_map_mmio(m,p,b,o,s) +#define mpic_map(m, p, b, o, s)_mpic_map_mmio(m, p, b, o, s) #endif /* !CONFIG_PPC_DCR */ @@ -345,7 +348,8 @@ static void __init mpic_test_broken_ipi(struct mpic *mpic) { u32 r; -
[linux-yocto] [PATCH 25/28] drivers/i2c-axxia: Support I2C_M_RECV_LEN
From: Anders Berg anders.b...@lsi.com Add support for the I2C_M_RECV_LEN flag to enable SMBus block data transfers. scripts/setlocalversion strips out the tag if there is a match since the Linux version is in Makefile. Without the tag information, there is no way to get back to the specific tag used in defect reports etc. This patch adds, in the LSI Axxia case, the lsi tag. Add a timeout condition to the soft reset code. Currently this will time out when running on simulator since it fails to clear the soft reset bit. Signed-off-by: John Jacques john.jacq...@lsi.com Signed-off-by: Anders Berg anders.b...@lsi.com --- drivers/i2c/busses/i2c-axxia.c | 193 +--- scripts/setlocalversion|8 ++ 2 files changed, 130 insertions(+), 71 deletions(-) diff --git a/drivers/i2c/busses/i2c-axxia.c b/drivers/i2c/busses/i2c-axxia.c index 8061998..519cda7 100644 --- a/drivers/i2c/busses/i2c-axxia.c +++ b/drivers/i2c/busses/i2c-axxia.c @@ -27,7 +27,8 @@ #include linux/module.h #define SCL_WAIT_TIMEOUT_NS 2500 -#define I2C_TIMEOUT (msecs_to_jiffies(1000)) +#define I2C_XFER_TIMEOUT(msecs_to_jiffies(500)) +#define I2C_STOP_TIMEOUT(msecs_to_jiffies(100)) #define TX_FIFO_SIZE8 #define RX_FIFO_SIZE8 @@ -123,12 +124,10 @@ struct axxia_i2c_dev { int irq; /* xfer completion object */ struct completion msg_complete; - /* pointer to current message data */ - u8 *msg_buf; - /* size of unsent data in the message buffer */ - size_t msg_buf_remaining; - /* identifies read transfers */ - int msg_read; + /* pointer to current message */ + struct i2c_msg *msg; + /* number of bytes transferred in msg */ + size_t msg_xfrd; /* error code for completed message */ int msg_err; /* current i2c bus clock rate */ @@ -168,10 +167,21 @@ axxia_i2c_init(struct axxia_i2c_dev *idev) u32 t_setup; u32 tmo_clk; u32 prescale; + unsigned long timeout; dev_dbg(idev-dev, rate=%uHz per_clk=%uMHz - ratio=1:%u\n, idev-bus_clk_rate, clk_mhz, divisor); + /* Reset controller */ + writel(0x01, idev-regs-soft_reset); + timeout = jiffies + msecs_to_jiffies(100); + while (readl(idev-regs-soft_reset) 1) { + if (time_after(jiffies, timeout)) { + dev_warn(idev-dev, Soft reset failed\n); + break; + } + } + /* Enable Master Mode */ writel(0x1, idev-regs-global_control); @@ -186,8 +196,8 @@ axxia_i2c_init(struct axxia_i2c_dev *idev) /* SDA Setup Time */ writel(t_setup, idev-regs-sda_setup_time); - /* SDA Hold Time, 5ns */ - writel(ns_to_clk(5, clk_mhz), idev-regs-sda_hold_time); + /* SDA Hold Time, 300ns */ + writel(ns_to_clk(300, clk_mhz), idev-regs-sda_hold_time); /* Filter 50ns spikes */ writel(ns_to_clk(50, clk_mhz), idev-regs-spike_fltr_len); @@ -228,15 +238,40 @@ axxia_i2c_init(struct axxia_i2c_dev *idev) } static int -axxia_i2c_empty_rx_fifo(struct axxia_i2c_dev *idev) +i2c_m_rd(const struct i2c_msg *msg) { - size_t rx_fifo_avail = readl(idev-regs-mst_rx_fifo); - int bytes_to_transfer = min(rx_fifo_avail, idev-msg_buf_remaining); + return (msg-flags I2C_M_RD) != 0; +} - idev-msg_buf_remaining -= bytes_to_transfer; +static int +i2c_m_recv_len(const struct i2c_msg *msg) +{ + return (msg-flags I2C_M_RECV_LEN) != 0; +} - while (0 bytes_to_transfer--) - *idev-msg_buf++ = readl(idev-regs-mst_data); +static int +axxia_i2c_empty_rx_fifo(struct axxia_i2c_dev *idev) +{ + struct i2c_msg *msg = idev-msg; + size_t rx_fifo_avail = readl(idev-regs-mst_rx_fifo); + int bytes_to_transfer = min(rx_fifo_avail, msg-len - idev-msg_xfrd); + + while (0 bytes_to_transfer--) { + int c = readl(idev-regs-mst_data); + if (idev-msg_xfrd == 0 i2c_m_recv_len(msg)) { + if (c == 0 || c I2C_SMBUS_BLOCK_MAX) { + idev-msg_err = -EPROTO; + i2c_int_disable(idev, ~0); + dev_err(idev-dev, + invalid SMBus block size (%d)\n, c); + complete(idev-msg_complete); + break; + } + msg-len += c; + writel(msg-len, idev-regs-mst_rx_xfer); + } + msg-buf[idev-msg_xfrd++] = c; + } return 0; } @@ -244,18 +279,16 @@ axxia_i2c_empty_rx_fifo(struct axxia_i2c_dev *idev) static int axxia_i2c_fill_tx_fifo(struct axxia_i2c_dev *idev) { + struct i2c_msg *msg = idev-msg; size_t tx_fifo_avail = TX_FIFO_SIZE - readl(idev-regs-mst_tx_fifo); - int
[linux-yocto] [PATCH 28/28] axxia: Remove Wrapper Functions
From: John Jacques john.jacq...@lsi.com These functions were temporary. They were added to allow development to continue on an external module that was not, at the time, released under the GPL. Signed-off-by: John Jacques john.jacq...@lsi.com Signed-off-by: Paul Butler paul.but...@windriver.com --- arch/arm/mach-axxia/Makefile |1 - arch/arm/mach-axxia/wrappers.c | 140 arch/powerpc/sysdev/Makefile |2 - arch/powerpc/sysdev/lsi_acp_wrappers.c | 132 -- 4 files changed, 275 deletions(-) delete mode 100644 arch/arm/mach-axxia/wrappers.c delete mode 100644 arch/powerpc/sysdev/lsi_acp_wrappers.c diff --git a/arch/arm/mach-axxia/Makefile b/arch/arm/mach-axxia/Makefile index 85cee8f..47e386b 100644 --- a/arch/arm/mach-axxia/Makefile +++ b/arch/arm/mach-axxia/Makefile @@ -1,7 +1,6 @@ # # Makefile for the linux kernel. # -obj-y += wrappers.o obj-y += axxia.o obj-y += clock.o obj-y += io.o diff --git a/arch/arm/mach-axxia/wrappers.c b/arch/arm/mach-axxia/wrappers.c deleted file mode 100644 index 4d49825..000 --- a/arch/arm/mach-axxia/wrappers.c +++ /dev/null @@ -1,140 +0,0 @@ -/* - * arch/arm/mach-axxia/wrappers.c - * - * Copyright (C) 2013 LSI - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - */ - -#include linux/module.h -#include asm/irq.h -#include linux/io.h -#include linux/irqdomain.h -#include linux/skbuff.h -#include linux/platform_device.h - -/* - == - == - MDIO - == - == -*/ - -/* - == - == - Platform Device Registration - == - == -*/ - -/* - -- - acp_platform_device_register -*/ - -int -acp_platform_device_register(struct platform_device *pdev) -{ - return platform_device_register(pdev); -} -EXPORT_SYMBOL(acp_platform_device_register); - -/* - -- - acp_platform_device_unregister -*/ - -void -acp_platform_device_unregister(struct platform_device *pdev) -{ - platform_device_unregister(pdev); - - return; -} -EXPORT_SYMBOL(acp_platform_device_unregister); - -/* - - - SKB - - -*/ - -/* - - acp_skb_tstamp_tx -*/ - -void -acp_skb_tstamp_tx(struct sk_buff *orig_skb, - struct skb_shared_hwtstamps *hwtstamps) { - skb_tstamp_tx(orig_skb, hwtstamps); -} -EXPORT_SYMBOL(acp_skb_tstamp_tx); - -/* - - - Interrupts - - -*/ - -/* - * - - * acp_irq_create_mapping - */ -unsigned int acp_irq_create_mapping(struct irq_domain *host, - irq_hw_number_t hwirq) -{ - unsigned int mapped_irq; - - preempt_disable(); - mapped_irq = irq_create_mapping(host, hwirq); -
[linux-yocto] [PATCH 27/28] LSI AXM55XX/rapidio: Stability and bug fix improvements , Correct boundary, Expand valid condition.
From: Michael Bringmann michael.bringm...@lsi.com Add additional spinlocks/mutexes to each controller state to increase concurrency and performance. Fix some bound checks for full outbound DME descriptor chains, correct a lockup/delay issue with errors in the outbound DME chains, and remove a delay loop. rapidio/LSI AXM55xx: Correct some boundary checks for argument values. Also correct formatting of platform-specific function code. LSI AXM55xx: Expand valid condition checks for inbound message DME chains. Signed-off-by: Michael Bringmann michael.bringm...@lsi.com --- arch/arm/include/asm/axxia-rio.h| 31 -- drivers/rapidio/devices/lsi/axxia-rio-ds.c | 22 ++-- drivers/rapidio/devices/lsi/axxia-rio-irq.c | 156 --- drivers/rapidio/devices/lsi/axxia-rio-irq.h | 13 +-- drivers/rapidio/devices/lsi/axxia-rio.c |3 +- drivers/rapidio/devices/lsi/axxia-rio.h | 16 ++- 6 files changed, 101 insertions(+), 140 deletions(-) diff --git a/arch/arm/include/asm/axxia-rio.h b/arch/arm/include/asm/axxia-rio.h index e01d6a3..492d476 100644 --- a/arch/arm/include/asm/axxia-rio.h +++ b/arch/arm/include/asm/axxia-rio.h @@ -94,21 +94,32 @@ static inline u32 CNTLZW(u32 val) int n = 0; if (val == 0) return 32; - if ((val 0x) == 0) - n += 16; val = val 16; + + if ((val 0x) == 0) { + n += 16; + val = val 16; + } /* // 16 bits from left are zero! so we omit 16 left bits */ - if ((val 0xFF00) == 0) - n = n + 8; val = val 8; + if ((val 0xFF00) == 0) { + n = n + 8; + val = val 8; + } /* 8 left bits are 0 */ - if ((val 0xF000) == 0) - n = n + 4; val = val 4; + if ((val 0xF000) == 0) { + n = n + 4; + val = val 4; + } /* 4 left bits are 0 */ - if ((val 0xC000) == 0) - n = n + 2, val = val 2; + if ((val 0xC000) == 0) { + n = n + 2; + val = val 2; + } /* 110 2 left bits are zero */ - if ((val 0x8000) == 0) - n = n + 1, val = val 1; + if ((val 0x8000) == 0) { + n = n + 1; + val = val 1; + } /* first left bit is zero */ return n; } diff --git a/drivers/rapidio/devices/lsi/axxia-rio-ds.c b/drivers/rapidio/devices/lsi/axxia-rio-ds.c index f4f44a6..02d3751 100755 --- a/drivers/rapidio/devices/lsi/axxia-rio-ds.c +++ b/drivers/rapidio/devices/lsi/axxia-rio-ds.c @@ -240,9 +240,10 @@ int axxia_open_ob_data_stream( int num_header_entries, int num_data_entries) { + struct rio_priv *priv = mport-priv; int rc = 0; - axxia_api_lock(); + axxia_api_lock(priv); rc = open_ob_data_stream(mport, dev_id, @@ -250,7 +251,7 @@ int axxia_open_ob_data_stream( num_header_entries, num_data_entries); - axxia_api_unlock(); + axxia_api_unlock(priv); return rc; } @@ -747,12 +748,12 @@ int axxia_close_ob_data_stream( struct rio_ds_hdr_desc *ptr_hdr_desc; u32dse_ctrl, i; - axxia_api_lock(); + axxia_api_lock(priv); ptr_dse_cfg = (ptr_ds_priv-obds_dse_cfg[dse_id]); if (ptr_dse_cfg-in_use == RIO_DS_FALSE) { - axxia_api_unlock(); + axxia_api_unlock(priv); return 0; } @@ -791,7 +792,7 @@ int axxia_close_ob_data_stream( /* release the IRQ handler */ release_irq_handler((ptr_ds_priv-ob_dse_irq[dse_id])); - axxia_api_unlock(); + axxia_api_unlock(priv); return 0; } @@ -830,9 +831,10 @@ int axxia_open_ib_data_stream( int desc_dbuf_size, int num_entries) { + struct rio_priv *priv = mport-priv; int rc = 0; - axxia_api_lock(); + axxia_api_lock(priv); rc = open_ib_data_stream(mport, dev_id, @@ -840,7 +842,7 @@ int axxia_open_ib_data_stream( cos, desc_dbuf_size, num_entries); - axxia_api_unlock(); + axxia_api_unlock(priv); return rc; } @@ -1522,7 +1524,7 @@ int axxia_close_ib_data_stream( struct rio_ids_data_desc *ptr_data_desc; u8 virt_vsid; - axxia_api_lock(); + axxia_api_lock(priv); for (i = 0; i (ptr_ds_priv-num_ibds_virtual_m); i++) { ptr_virt_m_cfg = (ptr_ds_priv-ibds_vsid_m_cfg[i]); @@
[linux-yocto] [PATCH 20/28] LSI sysdev/pci: Removing the power of 2 size restriction
From: SangeethaRao sangeetha@lsi.com This patch removes the power of 2 size restriction for PCIe inbound mapping in LSI PCIe driver Signed-off-by: SangeethaRao sangeetha@lsi.com --- arch/powerpc/sysdev/lsi_pci.c | 16 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/arch/powerpc/sysdev/lsi_pci.c b/arch/powerpc/sysdev/lsi_pci.c index 75bdf53..f485343 100644 --- a/arch/powerpc/sysdev/lsi_pci.c +++ b/arch/powerpc/sysdev/lsi_pci.c @@ -114,8 +114,9 @@ static int __init acp_parse_dma_ranges(struct pci_controller *hose, * within 32 bits space */ if (cpu_addr != 0 || pci_addr 0x) { - printk(KERN_WARNING %s: Ignored unsupported dma range - 0x%016llx...0x%016llx - 0x%016llx\n, + printk(KERN_WARNING %s: Ignored unsupported \ + dma range\ + 0x%016llx...0x%016llx - 0x%016llx\n,\ hose-dn-full_name, pci_addr, pci_addr + size - 1, cpu_addr); continue; @@ -148,15 +149,14 @@ static int __init acp_parse_dma_ranges(struct pci_controller *hose, * DMA bounce buffers */ if (size total_memory) { - printk(KERN_ERR %s: dma-ranges too small - (size=%llx total_memory=%llx)\n, + printk(KERN_ERR %s: dma-ranges too small \ + (size=%llx total_memory=%llx)\n,\ hose-dn-full_name, size, (u64)total_memory); return -ENXIO; } - /* Check we are a power of 2 size and that base is a multiple of size*/ - if ((size (size - 1)) != 0 || - (res-start (size - 1)) != 0) { + /* Check that base is a multiple of size*/ + if ((res-start (size - 1)) != 0) { printk(KERN_ERR %s: dma-ranges unaligned\n, hose-dn-full_name); return -ENXIO; @@ -288,7 +288,7 @@ static int acp_pciex_validate_bdf(struct pciex_port *port, /* Check we are within the mapped range */ if (bus-number port-hose-last_busno) { if (!message) { - printk(KERN_WARNING Warning! Probing bus %u + printk(KERN_WARNING Warning! Probing bus %u\ out of range !\n, bus-number); message++; } -- 1.7.9.5 -- ___ linux-yocto mailing list linux-yocto@yoctoproject.org https://lists.yoctoproject.org/listinfo/linux-yocto
[linux-yocto] [PATCH 22/28] arch/powerpc: Updated the UART Driver to Support 3500
From: John Jacques john.jacq...@lsi.com Added code to support the UART on the 3500 board Signed-off-by: John Jacques john.jacq...@lsi.com --- drivers/tty/serial/lsi_acp_serial.c | 94 +++ 1 file changed, 51 insertions(+), 43 deletions(-) diff --git a/drivers/tty/serial/lsi_acp_serial.c b/drivers/tty/serial/lsi_acp_serial.c index a41eab2..0f9f7ce 100644 --- a/drivers/tty/serial/lsi_acp_serial.c +++ b/drivers/tty/serial/lsi_acp_serial.c @@ -81,9 +81,8 @@ struct uart_acp_port { unsigned int interrupt_mask; unsigned int old_status; void *timer_base; - unsigned long divisor; - unsigned char ibrd; - unsigned char fbrd; + unsigned short ibrd; + unsigned short fbrd; }; /* @@ -119,25 +118,10 @@ struct uart_acp_port { static int get_clock_stuff(struct uart_acp_port *port, int baud_rate) { - unsigned long divisor; unsigned long ibrd; unsigned long fbrd; - /* - Since the IBDR (integer part of the baud rate - divisor) is a 16 bit quatity, find the minimum load - value that will let the IBDR/FBDR result in the - desired baud rate. - */ - - if (100 per_clock) { - divisor = per_clock / 2500; - ibrd = 2500 / (16 * baud_rate); - } else { - /* Emulation is much slower... */ - divisor = per_clock / 325; - ibrd = 325 / (16 * baud_rate); - } + ibrd = per_clock / (16 * baud_rate); /* * The following formula is from the ARM document (ARM DDI 0183E). @@ -164,36 +148,15 @@ get_clock_stuff(struct uart_acp_port *port, int baud_rate) * 2 * (16 * baud_rate) */ - port-port.uartclk = (per_clock / divisor); + port-port.uartclk = per_clock; fbrd = port-port.uartclk % (16 * baud_rate); fbrd *= 128; fbrd += (16 * baud_rate); fbrd /= (2 * (16 * baud_rate)); - port-divisor = (divisor - 1); - port-ibrd = (unsigned char) ibrd; - port-fbrd = (unsigned char) fbrd; - - if (port-divisor != in_le32(port-timer_base + TIMER_LOAD)) { - while (0 == - (in_le32((const volatile unsigned *) - (port-port.membase + UART01x_FR)) - UART011_FR_TXFE)) - ; - - while (0 != - (in_le32((const volatile unsigned *) - (port-port.membase + UART01x_FR)) - UART01x_FR_BUSY)) - ; - - out_le32((port-timer_base + TIMER_CONTROL), 0); - out_le32((port-timer_base + TIMER_LOAD), port-divisor); - out_le32((port-timer_base + TIMER_CONTROL), -(TIMER_CONTROL_ENABLE | - TIMER_CONTROL_MODE)); - } + port-ibrd = (unsigned short) ibrd; + port-fbrd = (unsigned short) fbrd; return 0; } @@ -1135,6 +1098,51 @@ acp_serial_add_ports(struct uart_driver *driver) ret = -ENOMEM; } + np = of_find_compatible_node(NULL, NULL, lsi,acp3500); + + if (NULL == np) { + unsigned long divisor; + + /* + In the 3500 case, the peripheral clock is connected + directly to the UART. If this isn't 3500, set up + the second timer (which is in between the peripheral + clock and the UART) and adjust per_clock + accordingly. + */ + + if (100 per_clock) { + divisor = per_clock / 2500; + per_clock = 2500; + } else { + /* Emulation is much slower... */ + divisor = per_clock / 325; + per_clock = 325; + } + + --divisor; + + if (divisor != in_le32(uap-timer_base + TIMER_LOAD)) { + while (0 == + (in_le32((const volatile unsigned *) + (uap-port.membase + UART01x_FR)) + UART011_FR_TXFE)) + ; + + while (0 != + (in_le32((const volatile unsigned *) + (uap-port.membase + UART01x_FR)) + UART01x_FR_BUSY)) + ; + + out_le32((uap-timer_base + TIMER_CONTROL), 0); + out_le32((uap-timer_base + TIMER_LOAD), divisor); + out_le32((uap-timer_base + TIMER_CONTROL), +(TIMER_CONTROL_ENABLE | + TIMER_CONTROL_MODE)); + }
[linux-yocto] [PATCH 18/28] kernel/irq/manage.c: Fix irq_set_affinity to allow use with buslocks
From: David Mercado david.merc...@windriver.com Fix irq_set_affinity() to allow usage of buslocks with slow bus IRQ controllers, such as the LSI Axxia GIC. Signed-off-by: David Mercado david.merc...@windriver.com --- kernel/irq/manage.c |6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/kernel/irq/manage.c b/kernel/irq/manage.c index c891fe3..4291484 100644 --- a/kernel/irq/manage.c +++ b/kernel/irq/manage.c @@ -180,16 +180,16 @@ int __irq_set_affinity_locked(struct irq_data *data, const struct cpumask *mask) */ int irq_set_affinity(unsigned int irq, const struct cpumask *mask) { - struct irq_desc *desc = irq_to_desc(irq); unsigned long flags; + struct irq_desc *desc = irq_get_desc_buslock(irq, flags, +IRQ_GET_DESC_CHECK_GLOBAL); int ret; if (!desc) return -EINVAL; - raw_spin_lock_irqsave(desc-lock, flags); ret = __irq_set_affinity_locked(irq_desc_get_irq_data(desc), mask); - raw_spin_unlock_irqrestore(desc-lock, flags); + irq_put_desc_busunlock(desc, flags); return ret; } -- 1.7.9.5 -- ___ linux-yocto mailing list linux-yocto@yoctoproject.org https://lists.yoctoproject.org/listinfo/linux-yocto
[linux-yocto] [PATCH 21/28] axxia: Fix a Size Warning in the SRIO Section of the Device Trees
From: John Jacques john.jacq...@lsi.com Signed-off-by: John Jacques john.jacq...@lsi.com --- arch/powerpc/boot/dts/acp25xx.dts |2 +- arch/powerpc/boot/dts/acp342x.dts |2 +- arch/powerpc/boot/dts/acp344x.dts |2 +- arch/powerpc/boot/dts/acp35xx.dts |2 +- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/arch/powerpc/boot/dts/acp25xx.dts b/arch/powerpc/boot/dts/acp25xx.dts index b5463c5..9893cf9 100644 --- a/arch/powerpc/boot/dts/acp25xx.dts +++ b/arch/powerpc/boot/dts/acp25xx.dts @@ -290,7 +290,7 @@ #size-cells = 2; compatible = axxia,rapidio-delta; device_type = rapidio; -reg = 0x0020 0x0056 0x0 0x1000; /* SRIO Conf 0 region */ +reg = 0x0020 0x0056 0x1000; /* SRIO Conf 0 region */ ranges = 0x0 0x0 0x0021 0x 0x0 0x4000; /* linkdown-reset = 0x0200 0x100 0x0020 0x0043 0x0 0x1; diff --git a/arch/powerpc/boot/dts/acp342x.dts b/arch/powerpc/boot/dts/acp342x.dts index 99d2858..6e02a8c 100644 --- a/arch/powerpc/boot/dts/acp342x.dts +++ b/arch/powerpc/boot/dts/acp342x.dts @@ -291,7 +291,7 @@ #size-cells = 2; compatible = axxia,rapidio-delta; device_type = rapidio; -reg = 0x0020 0x0042 0x0 0x1000; /* SRIO Conf 0 region */ +reg = 0x0020 0x0042 0x1000; /* SRIO Conf 0 region */ ranges = 0x0 0x0 0x0020 0x8000 0x0 0x4000; /* linkdown-reset = 0x0200 0x100 0x0020 0x0043 0x0 0x1; diff --git a/arch/powerpc/boot/dts/acp344x.dts b/arch/powerpc/boot/dts/acp344x.dts index 51fa547..2c25007 100644 --- a/arch/powerpc/boot/dts/acp344x.dts +++ b/arch/powerpc/boot/dts/acp344x.dts @@ -290,7 +290,7 @@ #size-cells = 2; compatible = axxia,rapidio-delta; device_type = rapidio; -reg = 0x0020 0x0042 0x0 0x1000; /* SRIO Conf 0 region */ +reg = 0x0020 0x0042 0x1000; /* SRIO Conf 0 region */ ranges = 0x0 0x0 0x0020 0x8000 0x0 0x4000; /* linkdown-reset = 0x0200 0x100 0x0020 0x0043 0x0 0x1; diff --git a/arch/powerpc/boot/dts/acp35xx.dts b/arch/powerpc/boot/dts/acp35xx.dts index 8fd366f..0bf153f 100644 --- a/arch/powerpc/boot/dts/acp35xx.dts +++ b/arch/powerpc/boot/dts/acp35xx.dts @@ -401,7 +401,7 @@ #size-cells = 2; compatible = axxia,rapidio-delta; device_type = rapidio; -reg = 0x0020 0x0056 0x0 0x1000; /* SRIO Conf 0 region */ +reg = 0x0020 0x0056 0x1000; /* SRIO Conf 0 region */ ranges = 0x0 0x0 0x0021 0x 0x0 0x4000; /* linkdown-reset = 0x0200 0x100 0x0020 0x0040A000 0x0 0x1; -- 1.7.9.5 -- ___ linux-yocto mailing list linux-yocto@yoctoproject.org https://lists.yoctoproject.org/listinfo/linux-yocto
[linux-yocto] [PATCH 25/28] arch/powerpc: Don't Try to Use NAND on Axxia 3500
From: John Jacques john.jacq...@lsi.com If NAND is enabled and the board is 3500 then gracefully exit with the error message NAND not compatible with 3500 Signed-off-by: John Jacques john.jacq...@lsi.com --- drivers/mtd/nand/lsi_acp_nand.c |9 - 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/drivers/mtd/nand/lsi_acp_nand.c b/drivers/mtd/nand/lsi_acp_nand.c index c3165d9..1cac342 100644 --- a/drivers/mtd/nand/lsi_acp_nand.c +++ b/drivers/mtd/nand/lsi_acp_nand.c @@ -3471,6 +3471,13 @@ lsi_nand_init(void) static const char *part_probe_types[] = { cmdlinepart, ofpart, NULL }; + np = of_find_compatible_node(NULL, NULL, lsi,acp3500); + + if (NULL != np) { + printk(KERN_ERR NAND Support is Not Yet Available on 3500\n); + return -1; + } + memset(ppdata, 0, sizeof(ppdata)); np = of_find_node_by_type(np, nand); @@ -3490,7 +3497,7 @@ lsi_nand_init(void) enabled = of_get_property(np, enabled, NULL); if (!enabled || (enabled (0 == *enabled))) { - printk(ACP NAND Controller Isn't Enabled.\n); + printk(KERN_INFO ACP NAND Controller Isn't Enabled.\n); return -ENODEV; } -- 1.7.9.5 -- ___ linux-yocto mailing list linux-yocto@yoctoproject.org https://lists.yoctoproject.org/listinfo/linux-yocto
[linux-yocto] [PATCH 27/28] LSI AXM55xx i2c: Adding support for AXM3500 I2C driver
From: SangeethaRao sangeetha@lsi.com This patch adds i2c support for the 3500 board Signed-off-by: SangeethaRao sangeetha@lsi.com --- drivers/i2c/busses/i2c-axxia.c | 11 +-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/drivers/i2c/busses/i2c-axxia.c b/drivers/i2c/busses/i2c-axxia.c index 43b433b..b2cdbba 100644 --- a/drivers/i2c/busses/i2c-axxia.c +++ b/drivers/i2c/busses/i2c-axxia.c @@ -14,7 +14,6 @@ #include linux/init.h #include linux/platform_device.h #include linux/clk.h -#include linux/clkdev.h #include linux/err.h #include linux/i2c.h #include linux/io.h @@ -501,6 +500,10 @@ axxia_i2c_probe(struct platform_device *pdev) u32 bus = pdev-id; int irq = 0; int ret = 0; + int speed_property = 0; + + speed_property = of_find_compatible_node(NULL, NULL, + lsi,axxia35xx) != NULL; base = of_iomap(np, 0); if (!base) { @@ -537,7 +540,11 @@ axxia_i2c_probe(struct platform_device *pdev) of_property_read_u32(np, bus, bus); - of_property_read_u32(np, clock-frequency, idev-bus_clk_rate); + if (speed_property) + of_property_read_u32(np, speed, idev-bus_clk_rate); + else + of_property_read_u32(np, clock-frequency, +idev-bus_clk_rate); if (idev-bus_clk_rate == 0) idev-bus_clk_rate = 10; /* default clock rate */ -- 1.7.9.5 -- ___ linux-yocto mailing list linux-yocto@yoctoproject.org https://lists.yoctoproject.org/listinfo/linux-yocto
[linux-yocto] [PATCH 23/28] i2c-axxia: Fixed i2c device minor numbers
From: Anders Berg anders.b...@lsi.com Added missing 'bus' property to the I2C device tree nodes (simulation dts files). This is needed to get the I2C adapters numbered starting with 0. Signed-off-by: Anders Berg anders.b...@lsi.com --- arch/arm/boot/dts/axm55xxsim.dts | 24 arch/arm/boot/dts/axm55xxsim16.dts | 24 2 files changed, 16 insertions(+), 32 deletions(-) diff --git a/arch/arm/boot/dts/axm55xxsim.dts b/arch/arm/boot/dts/axm55xxsim.dts index b20b09a..511defa 100644 --- a/arch/arm/boot/dts/axm55xxsim.dts +++ b/arch/arm/boot/dts/axm55xxsim.dts @@ -306,45 +306,37 @@ I2C0: i2c@0x02010084000 { compatible = lsi,api2c; device_type = i2c; -enabled = 0; -port = 0; -/* bus_name = auto; */ -/* bus = 2; */ reg = 0x20 0x10084000 0x00 0x1000; interrupts = 0 19 4; +bus = 0; +enabled = 0; }; I2C1: i2c@0x02010085000 { compatible = lsi,api2c; device_type = i2c; -enabled = 0; -port = 1; -/* bus_name = auto; */ -/* bus = 3; */ reg = 0x20 0x10085000 0x00 0x1000; interrupts = 0 20 4; +bus = 1; +enabled = 0; }; I2C2: i2c@0x02010086000 { compatible = lsi,api2c; device_type = i2c; -enabled = 0; -port = 2; -/* bus_name = auto; */ -/* bus = 4; */ reg = 0x20 0x10086000 0x00 0x1000; interrupts = 0 21 4; +bus = 2; +enabled = 0; }; SMB: i2c@0x02010087000 { compatible = lsi,api2c; device_type = i2c; -enabled = 0; -port = 3; -bus_name = smb; -/* bus = 5; */ reg = 0x20 0x10087000 0x00 0x1000; interrupts = 0 22 4; +bus = 3; +enabled = 0; }; }; diff --git a/arch/arm/boot/dts/axm55xxsim16.dts b/arch/arm/boot/dts/axm55xxsim16.dts index 0ce2ff4..1ddba7c 100644 --- a/arch/arm/boot/dts/axm55xxsim16.dts +++ b/arch/arm/boot/dts/axm55xxsim16.dts @@ -390,45 +390,37 @@ I2C0: i2c@0x02010084000 { compatible = lsi,api2c; device_type = i2c; -enabled = 0; -port = 0; -/* bus_name = auto; */ -/* bus = 2; */ reg = 0x20 0x10084000 0x00 0x1000; interrupts = 0 19 4; +bus = 0; +enabled = 0; }; I2C1: i2c@0x02010085000 { compatible = lsi,api2c; device_type = i2c; -enabled = 0; -port = 1; -/* bus_name = auto; */ -/* bus = 3; */ reg = 0x20 0x10085000 0x00 0x1000; interrupts = 0 20 4; +bus = 1; +enabled = 0; }; I2C2: i2c@0x02010086000 { compatible = lsi,api2c; device_type = i2c; -enabled = 0; -port = 2; -/* bus_name = auto; */ -/* bus = 4; */ reg = 0x20 0x10086000 0x00 0x1000; interrupts = 0 21 4; +bus = 2; +enabled = 0; }; SMB: i2c@0x02010087000 { compatible = lsi,api2c; device_type = i2c; -enabled = 0; -port = 3; -bus_name = smb; -/* bus = 5; */ reg = 0x20 0x10087000 0x00 0x1000; interrupts = 0 22 4; +bus = 3; +enabled = 0; }; }; -- 1.7.9.5 -- ___ linux-yocto mailing list linux-yocto@yoctoproject.org https://lists.yoctoproject.org/listinfo/linux-yocto
[linux-yocto] [PATCH 26/28] LSI AXM55xx: Fix PMU handler issue
From: David Mercado david.merc...@windriver.com The AXM55xx has the PMU IRQ lines from each core in a cluster OR'ed together. As a workaround for this, a PMU handler extension was created in the BSP to dynamically call irq_set_affinity() to rotate the PMU IRQ assignment as needed, in order to maintain perf accuracy. However, with the introduction of the Axxia GIC driver slow bus implementation, irq_set_affinity() cannot be called directly from interrupt context. Instead, the PMU IRQ handler extension is removed from the BSP and the rotation of IRQ affinity is performed directly within the Axxia GIC driver. Signed-off-by: David Mercado david.merc...@windriver.com --- arch/arm/mach-axxia/axxia-gic.c | 25 + arch/arm/mach-axxia/axxia.c | 37 - 2 files changed, 25 insertions(+), 37 deletions(-) diff --git a/arch/arm/mach-axxia/axxia-gic.c b/arch/arm/mach-axxia/axxia-gic.c index 701d65f..c716dc9 100644 --- a/arch/arm/mach-axxia/axxia-gic.c +++ b/arch/arm/mach-axxia/axxia-gic.c @@ -907,6 +907,10 @@ asmlinkage void __exception_irq_entry axxia_gic_handle_irq(struct pt_regs *regs) u32 irqstat, irqnr; struct gic_chip_data *gic = gic_data; void __iomem *cpu_base = gic_data_cpu_base(gic); + void __iomem *dist_base = gic_data_dist_base(gic); + u32 pcpu = cpu_logical_map(smp_processor_id()); + u32 cluster = pcpu / CORES_PER_CLUSTER; + u32 next, mask; do { irqstat = readl_relaxed(cpu_base + GIC_CPU_INTACK); @@ -967,6 +971,27 @@ asmlinkage void __exception_irq_entry axxia_gic_handle_irq(struct pt_regs *regs) writel_relaxed(irqnr, cpu_base + GIC_CPU_EOI); break; + case IRQ_PMU: + /* +* The PMU IRQ line is OR'ed among all cores +* within a cluster, so no way to tell which +* core actually generated this interrupt. +* Therefore, rotate PMU IRQ affinity to allow +* perf to work as accurately as possible. Skip +* over offline cpus. +*/ + do { + next = (++pcpu % CORES_PER_CLUSTER) + + (cluster * CORES_PER_CLUSTER); + } while (!cpu_online(next)); + + mask = 0x01 (next % CORES_PER_CLUSTER); + raw_spin_lock(irq_controller_lock); + writeb_relaxed(mask, dist_base + + GIC_DIST_TARGET + IRQ_PMU); + raw_spin_unlock(irq_controller_lock); + /* Fall through ... */ + default: /* External interrupt */ handle_IRQ(irqnr, regs); diff --git a/arch/arm/mach-axxia/axxia.c b/arch/arm/mach-axxia/axxia.c index af85305..81d39d1 100644 --- a/arch/arm/mach-axxia/axxia.c +++ b/arch/arm/mach-axxia/axxia.c @@ -192,48 +192,11 @@ static struct resource axxia_pmu_resources[] = { }, }; -/* - * The PMU IRQ lines of four cores are wired together into a single interrupt. - * Bounce the interrupt to other cores if it's not ours. - */ -#define CORES_PER_CLUSTER 4 -static irqreturn_t axxia_pmu_handler(int irq, void *dev, irq_handler_t handler) -{ - irqreturn_t ret = handler(irq, dev); - int cpu = smp_processor_id(); - int cluster = cpu / CORES_PER_CLUSTER; - int other; - - if (ret == IRQ_NONE) { - - /* Look until we find another cpu that's online. */ - do { - other = (++cpu % CORES_PER_CLUSTER) + - (cluster * CORES_PER_CLUSTER); - } while (!cpu_online(other)); - - irq_set_affinity(irq, cpumask_of(other)); - } - - /* -* We should be able to get away with the amount of IRQ_NONEs we give, -* while still having the spurious IRQ detection code kick in if the -* interrupt really starts hitting spuriously. -*/ - return ret; -} - -static struct arm_pmu_platdata axxia_pmu_platdata = { - .handle_irq = axxia_pmu_handler, -}; - - static struct platform_device pmu_device = { .name = arm-pmu, .id = ARM_PMU_DEVICE_CPU, .num_resources = ARRAY_SIZE(axxia_pmu_resources), .resource = axxia_pmu_resources, - .dev.platform_data = axxia_pmu_platdata, }; static inline void -- 1.7.9.5 -- ___ linux-yocto mailing list
Re: [linux-yocto] [PATCH 04/28] LSI AXM55xx: Fixed inbound data streaming ISR handling
On 14-05-02 03:16 PM, Charlie Paul wrote: From: ningligong ning...@lsi.com 1. Fixed inbound data stream interrupt service routine to properly handle packets received by all virtual VSID. I don't think that we necessarily need it fixed for this commit, but as a learning exercise, this commit has two issues. - We should have a description of what the improper handling was, and what the symptoms were: device didn't work, device performance as low .. etc. - When you have a list of changes in a commit, it is a sign that it really should have been two commits. It means that if there's an issue with one of the changes, they all get dropped, and since we are not familiar with the code we can't really tell what is what. Please pass the feedback along to the developer, and if you can get a quick turn around, an updated commit header would be ideal. Bruce 2. Moved checking for vsid_in_use of an inbound DSE, the vsid_in_use is only valid when other two bits are set. Signed-off-by: ningligong ning...@lsi.com --- drivers/rapidio/devices/lsi/axxia-rio-ds.c | 226 1 file changed, 131 insertions(+), 95 deletions(-) diff --git a/drivers/rapidio/devices/lsi/axxia-rio-ds.c b/drivers/rapidio/devices/lsi/axxia-rio-ds.c index 02d3751..4e55ed7 100755 --- a/drivers/rapidio/devices/lsi/axxia-rio-ds.c +++ b/drivers/rapidio/devices/lsi/axxia-rio-ds.c @@ -242,6 +242,7 @@ int axxia_open_ob_data_stream( { struct rio_priv *priv = mport-priv; int rc = 0; + struct rio_priv *priv = mport-priv; axxia_api_lock(priv); @@ -379,7 +380,6 @@ int open_ob_data_stream( __rio_local_write_config_32(mport, RAB_OBDSE_DESC_ADDR(dse_id), des_chain_start_addr_phy_low); - h = (ptr_ds_priv-ob_dse_irq[dse_id]); sprintf(ptr_dse_cfg-name, obds-%d, dse_id); @@ -451,7 +451,6 @@ int axxia_add_ob_data_stream( int rc = 0; /* sanity check - TBD */ - ptr_ds_priv = (priv-ds_priv_data); /* @@ -693,8 +692,10 @@ void ob_dse_irq_handler(struct rio_irq_handler *h, u32 state) ptr_hdr_desc-dw0); /* free the buffer */ - kfree((void *)ptr_hdr_desc-virt_data_buf); - ptr_hdr_desc-buf_status = DS_DBUF_FREED; + if (ptr_hdr_desc-buf_status != DS_DBUF_FREED) { + kfree((void *)ptr_hdr_desc-virt_data_buf); + ptr_hdr_desc-buf_status = DS_DBUF_FREED; + } if (ptr_dse_cfg-hdr_read_ptr == (ptr_dse_cfg-max_num_hdr_desc - 1)) { @@ -725,6 +726,7 @@ void ob_dse_irq_handler(struct rio_irq_handler *h, u32 state) (dse_stat 0x3F)); spin_unlock_irqrestore(ptr_dse_cfg-lock, flags); + return; } @@ -831,8 +833,8 @@ int axxia_open_ib_data_stream( int desc_dbuf_size, int num_entries) { - struct rio_priv *priv = mport-priv; int rc = 0; + struct rio_priv *priv = mport-priv; axxia_api_lock(priv); @@ -1050,6 +1052,7 @@ int open_ib_data_stream( ptr_virt_m_cfg-cos = cos; ptr_virt_m_cfg-source_id = source_id; ptr_virt_m_cfg-desc_dbuf_size = desc_dbuf_size; + ptr_virt_m_cfg-virt_vsid = virt_vsid; desc_chain_start_addr_phy = virt_to_phys((void *) @@ -1125,6 +1128,10 @@ int axxia_add_ibds_buffer( u32 m_id; u8 found_one = RIO_DS_FALSE; u32 vsid_addr_reg; + u32 vsid; + u16 virt_vsid; + u32 alias_reg; + u32 vsid_m_stats; unsigned long data_addr_phy; u32 data_addr_hi; @@ -1136,11 +1143,20 @@ int axxia_add_ibds_buffer( /* search through the virtual M table to find the one that has ** the same source_id and cos */ + /* find the mapping between incoming VSID and internal VSID */ + __rio_local_read_config_32(mport, RAB_IBDS_VSID_ALIAS, alias_reg); + + /* VSID = {16'b SourceID, 8'bCOS} */ + vsid = ((source_id 0x) 16) | (cos 0xFF); + + /* calculate the virtual M index */ + (void)axxio_virt_vsid_convert(vsid, alias_reg, virt_vsid); + + for (m_id = 0; m_id RIO_MAX_NUM_IBDS_VSID_M; m_id++) { ptr_virt_m_cfg = (ptr_ds_priv-ibds_vsid_m_cfg[m_id]); - if ((ptr_virt_m_cfg-source_id == source_id) - (ptr_virt_m_cfg-cos == cos) + if ((ptr_virt_m_cfg-virt_vsid == virt_vsid) (ptr_virt_m_cfg-in_use == RIO_DS_TRUE)) { found_one = RIO_DS_TRUE; break; @@ -1207,7 +1223,13 @@ int
Re: [linux-yocto] [PATCH 05/28] LSI AXM55xx: Fixes for mailbox open bounds checks.
The same comments apply here. We should always describe the symptom of what we are fixing. What was broken before this change ? Bruce On 14-05-02 03:16 PM, Charlie Paul wrote: From: Michael Bringmann michael.bringm...@lsi.com Signed-off-by: Michael Bringmann michael.bringm...@lsi.com --- drivers/rapidio/devices/lsi/axxia-rio-irq.c |6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/drivers/rapidio/devices/lsi/axxia-rio-irq.c b/drivers/rapidio/devices/lsi/axxia-rio-irq.c index 2ffa34b..cb16281 100644 --- a/drivers/rapidio/devices/lsi/axxia-rio-irq.c +++ b/drivers/rapidio/devices/lsi/axxia-rio-irq.c @@ -1013,7 +1013,7 @@ static inline int choose_ob_dme( if (len sz) continue; - if (dme-entries = (dme-entries_in_use+1)) { + if (dme-entries (dme-entries_in_use+1)) { (*ob_dme) = dme; (*buf_sz) = sz; return ret + i; @@ -1290,7 +1290,7 @@ static int open_outb_mbox(struct rio_mport *mport, void *dev_id, int dme_no, u64 descChainStart, descAddr; int buf_sz = 0; - if ((entries = 0) || (entries priv-desc_max_entries)) + if ((entries 2) || (entries priv-desc_max_entries)) return -EINVAL; if (test_bit(RIO_IRQ_ENABLED, h-state)) @@ -1648,7 +1648,7 @@ static int open_inb_mbox(struct rio_mport *mport, void *dev_id, if ((mbox 0) || (mbox = RIO_MAX_RX_MBOX)) return -EINVAL; - if ((entries = 0) || (entries priv-desc_max_entries)) + if ((entries 2) || (entries priv-desc_max_entries)) return -EINVAL; h = priv-ib_dme_irq[mbox]; -- ___ linux-yocto mailing list linux-yocto@yoctoproject.org https://lists.yoctoproject.org/listinfo/linux-yocto
Re: [linux-yocto] [PATCH 07/28] LSI AXM55xx: Fix concurrency issue for variable.
On 14-05-02 03:16 PM, Charlie Paul wrote: From: Michael Bringmann michael.bringm...@lsi.com Used 'atomic' counter to track available inbound messages between interrupt and foreground code. Also, enable both SRIO modules by default with check for SRIO link ready status to validated the accesses. Are these two changes related ? There's only a tenuous linkage between the two. As such, they should be two commits. Bruce Signed-off-by: Michael Bringmann michael.bringm...@lsi.com --- arch/arm/boot/dts/axm55xx.dts |4 ++-- drivers/rapidio/devices/lsi/axxia-rio-irq.c | 18 -- drivers/rapidio/devices/lsi/axxia-rio-irq.h |2 +- 3 files changed, 15 insertions(+), 9 deletions(-) diff --git a/arch/arm/boot/dts/axm55xx.dts b/arch/arm/boot/dts/axm55xx.dts index 1cba111..826a6e6 100644 --- a/arch/arm/boot/dts/axm55xx.dts +++ b/arch/arm/boot/dts/axm55xx.dts @@ -439,7 +439,7 @@ rio0: rapidio@0x31 { index = 0; -status = disabled; +status = okay; #address-cells = 2; #size-cells = 2; compatible = axxia,rapidio-delta; @@ -454,7 +454,7 @@ rio1: rapidio@0x314000 { index = 1; -status = disabled; +status = okay; #address-cells = 2; #size-cells = 2; compatible = axxia,rapidio-delta; diff --git a/drivers/rapidio/devices/lsi/axxia-rio-irq.c b/drivers/rapidio/devices/lsi/axxia-rio-irq.c index 9879b7e..73b5a4c 100644 --- a/drivers/rapidio/devices/lsi/axxia-rio-irq.c +++ b/drivers/rapidio/devices/lsi/axxia-rio-irq.c @@ -1115,7 +1115,7 @@ static struct rio_msg_dme *alloc_message_engine(struct rio_mport *mport, me-entries_in_use = 0; me-write_idx = 0; me-read_idx = 0; - me-pending = 0; + atomic_set(me-pending, 0); me-tx_dme_tmo = 0; me-dme_no = dme_no; @@ -1474,6 +1474,7 @@ static void ib_dme_irq_handler(struct rio_irq_handler *h, u32 state) u32 dw0; int dme_no = 31 - CNTLZW(dme_mask); int num_new; + int nPending; dme_mask ^= (1 dme_no); while (mb-me[letter]-dme_no != dme_no) @@ -1550,7 +1551,7 @@ static void ib_dme_irq_handler(struct rio_irq_handler *h, u32 state) me-write_idx = (me-write_idx + 1) % me-entries; num_new++; - me-pending++; + atomic_inc(me-pending); if (num_new == me-entries) break; } @@ -1564,7 +1565,8 @@ static void ib_dme_irq_handler(struct rio_irq_handler *h, u32 state) __ib_dme_event_dbg(priv, dme_no, 1 RIO_IB_DME_RX_RING_FULL); - if (me-pending + nPending = atomic_read(me-pending); + if (nPending mport-inb_msg[mbox_no].mcback) { mport-inb_msg[mbox_no].mcback(mport, @@ -2345,6 +2347,7 @@ void *axxia_get_inb_message(struct rio_mport *mport, int mbox, int letter, struct rio_rx_mbox *mb; struct rio_msg_dme *me; unsigned long iflags; + int nPending; void *buf = NULL; if ((mbox 0) || (mbox = RIO_MAX_RX_MBOX)) @@ -2371,7 +2374,8 @@ void *axxia_get_inb_message(struct rio_mport *mport, int mbox, int letter, __rio_local_write_config_32(mport, RAB_INTR_ENAB_IDME, intr); } - while (me-pending) { + nPending = atomic_read(me-pending); + while (nPending) { struct rio_msg_desc *desc = me-desc[me-read_idx]; u32 dw0, dw1; @@ -2399,7 +2403,8 @@ void *axxia_get_inb_message(struct rio_mport *mport, int mbox, int letter, (dw0 0xff) | DME_DESC_DW0_VALID); } me-read_idx = (me-read_idx + 1) % me-entries; - me-pending--; + atomic_dec(me-pending); + nPending--; __ib_dme_event_dbg(priv, me-dme_no, 1 RIO_IB_DME_DESC_ERR); } else { @@ -2447,7 +2452,8 @@ void *axxia_get_inb_message(struct rio_mport *mport, int mbox, int letter, mb-next_rx_slot = (mb-next_rx_slot + 1) % mb-ring_size; me-read_idx = (me-read_idx + 1) % me-entries; - me-pending--; + atomic_dec(me-pending); + nPending--; goto done; } } diff --git
Re: [linux-yocto] [PATCH 24/28] LSI AXM55xx: DDR retention fixes
On 14-05-02 03:17 PM, Charlie Paul wrote: From: Gary McGee gary.mc...@lsi.com Added the functions to support the DDR shutdown Fixed the quiesce TODO and added the vp engine calls Added the calls to the DDR shutdown Another list of changes .. this says three commits to me. Bruce Signed-off-by: Gary McGee gary.mc...@lsi.com --- arch/arm/mach-axxia/Makefile|2 +- arch/arm/mach-axxia/ddr_retention.c | 231 arch/arm/mach-axxia/ddr_shutdown.c | 332 +++ 3 files changed, 446 insertions(+), 119 deletions(-) create mode 100644 arch/arm/mach-axxia/ddr_shutdown.c diff --git a/arch/arm/mach-axxia/Makefile b/arch/arm/mach-axxia/Makefile index 47e386b..1352c37d 100644 --- a/arch/arm/mach-axxia/Makefile +++ b/arch/arm/mach-axxia/Makefile @@ -7,7 +7,7 @@ obj-y += io.o obj-y += ncr.o obj-y += timers.o obj-y += pci.o -obj-y += ddr_retention.o +obj-y += ddr_retention.o ddr_shutdown.o obj-$(CONFIG_I2C) += i2c.o obj-$(CONFIG_AXXIA_RIO) += rapidio.o obj-$(CONFIG_SMP) += platsmp.o headsmp.o diff --git a/arch/arm/mach-axxia/ddr_retention.c b/arch/arm/mach-axxia/ddr_retention.c index 7e4687d..6429151 100644 --- a/arch/arm/mach-axxia/ddr_retention.c +++ b/arch/arm/mach-axxia/ddr_retention.c @@ -26,7 +26,9 @@ #include linux/syscore_ops.h #include linux/proc_fs.h #include linux/delay.h +#include linux/prefetch.h #include linux/of.h + #include asm/io.h #include asm/cacheflush.h #include mach/ncr.h @@ -36,7 +38,13 @@ static void __iomem *apb; static void __iomem *dickens; static int ddr_retention_enabled; -unsigned long ncp_caal_regions_acp55xx[] = { +enum { + AXXIA_ENGINE_CAAL, + AXXIA_ENGINE_CNAL +}; + +unsigned long +ncp_caal_regions_acp55xx[] = { NCP_REGION_ID(0x0b, 0x05), /* SPPV2 */ NCP_REGION_ID(0x0c, 0x05), /* SED */ NCP_REGION_ID(0x0e, 0x05), /* DPI_HFA */ @@ -54,16 +62,22 @@ unsigned long ncp_caal_regions_acp55xx[] = { NCP_REGION_ID(0x1c, 0x05), /* PAB */ NCP_REGION_ID(0x1f, 0x05), /* EIOAM0 */ NCP_REGION_ID(0x31, 0x05), /* ISB */ - NCP_REGION_ID(0x28, 0x05), /* EIOASM0 */ - NCP_REGION_ID(0x29, 0x05), /* EIOASM1 */ - NCP_REGION_ID(0x2a, 0x05), /* EIOAS2 */ - NCP_REGION_ID(0x2b, 0x05), /* EIOAS3 */ - NCP_REGION_ID(0x2c, 0x05), /* EIOAS4 */ - NCP_REGION_ID(0x2d, 0x05), /* EIOAS5 */ - NCP_REGION_ID(0x32, 0x05), /* ISBS*/ NCP_REGION_ID(0xff, 0xff) }; +unsigned long +ncp_cnal_regions_acp55xx[] = { + NCP_REGION_ID(0x28, 0x05), /* EIOASM0 */ + NCP_REGION_ID(0x29, 0x05), /* EIOASM1 */ + NCP_REGION_ID(0x2a, 0x05), /* EIOAS2 */ + NCP_REGION_ID(0x2b, 0x05), /* EIOAS3 */ + NCP_REGION_ID(0x2c, 0x05), /* EIOAS4 */ + NCP_REGION_ID(0x2d, 0x05), /* EIOAS5 */ + NCP_REGION_ID(0x32, 0x05), /* ISBS*/ + NCP_REGION_ID(0xff, 0xff) +}; + + /* -- flush_l3 @@ -120,23 +134,41 @@ flush_l3(void) } asm volatile (dsb : : : memory); - asm volatile (dmb : : : memory); return; } static void -quiesce_vp_engine(void) +quiesce_vp_engine(int engineType) { - unsigned long *pCnalRegions = ncp_caal_regions_acp55xx; + unsigned long *pEngineRegions; unsigned long *pRegion; + unsigned longortOff, owtOff; unsigned ort, owt; unsigned long buf = 0; unsigned short node, target; int loop; printk(KERN_INFO quiescing VP engines...\n); - pRegion = pCnalRegions; + + switch (engineType) { + case AXXIA_ENGINE_CNAL: + pEngineRegions = ncp_cnal_regions_acp55xx; + ortOff = 0x1c0; + owtOff = 0x1c4; + break; + + case AXXIA_ENGINE_CAAL: + pEngineRegions = ncp_caal_regions_acp55xx; + ortOff = 0xf8; + owtOff = 0xfc; + break; + + default: + return; + } + + pRegion = pEngineRegions; while (*pRegion != NCP_REGION_ID(0xff, 0xff)) { /* set read/write transaction limits to zero */ @@ -145,15 +177,15 @@ quiesce_vp_engine(void) pRegion++; } - pRegion = pCnalRegions; + pRegion = pEngineRegions; loop = 0; while (*pRegion != NCP_REGION_ID(0xff, 0xff)) { node = (*pRegion 0x) 16; target = *pRegion 0x; /* read the number of outstanding read/write
Re: [linux-yocto] [PULL REQUEST] Kernel: 3.4 Branch: standard/axxia/base
On 14-05-02 04:16 PM, Paul, Charlie wrote: The following changes since commit e1374b95f2b2474b37f250b61a12eb7d4c8002c8: Merge branch 'standard/base' into standard/axxia/base (2014-04-29 13:10:33 -0400) are available in the git repository at: g...@github.com:butlerpaul/lsikernel sab-next for you to fetch changes up to 6b4b2cce1391ea3480b0170be8aa912c5cc5426d: merged. Bruce axxia: Remove Wrapper Functions (2014-05-02 09:07:28 -0700) Anders Berg (7): axxia: Fixed earlyprintk axxia: Define arch_is_coherent() ARM: 7465/1: Handle 4GB memory sizes in device tree and mem=size@start option ARM: LPAE: use phys_addr_t in alloc_init_pud() ARM: 7499/1: mm: Fix vmalloc overlap check for !HIGHMEM arm: mmu: Fixed checkpatch issues with mmu drivers/i2c-axxia: Support I2C_M_RECV_LEN David Mercado (2): LSI AXM55xx: Enable multi-cluster wfe/sev LSI AXM55XX: Add PMU support John Jacques (6): arch/arm/mach-axxi: Updated DDR Retention to Wokr from Interrupt Context arch/arm/mach-axxia: Clear MTC Errors During Initialization LSI: Fix Device Tree compatible fields powerpc/mpic: Disable preemption when calling mpic_processor_id() arm/mach-axxia: Same build for HW and simlation and DDR Retention Reset and clock init. axxia: Remove Wrapper Functions Michael Bringmann (1): LSI AXM55XX/rapidio: Stability and bug fix improvements , Correct boundary, Expand valid condition. Paul Butler (8): drivers/rapidio/devices: Initial Submittal of LSI rapidio drivers/rapidio: new files drivers/rapidio: modified files arm: rapidio updates powerpc: rapidio updates include: rapidio updates drivers: rapidio updates arm/mach-axxia: Updated PCIe driver to set PCIe SangeethaRao (3): arch/powerpc/sysdev: Fixed PCIe enumeration issue on AXM3500 emulation drivers/usb: USB driver/dts on PPC was broken. arch/arm/mach-axxia: added support for ncr_read/ncr_write ningligong (1): drivers/rapidio/lsi: squash a bunch rapidio stuff together and Cleanup arch/arm/Kconfig | 19 + arch/arm/Kconfig.debug |9 + arch/arm/Makefile |3 - arch/arm/boot/dts/axm55xx.dts | 50 +- arch/arm/boot/dts/axm55xxemu.dts | 21 +- arch/arm/boot/dts/axm55xxsim.dts | 94 +- .../arm/boot/dts/{axm-sim.dts = axm55xxsim16.dts} | 208 +- arch/arm/include/asm/axxia-rio.h | 135 + arch/arm/include/asm/rio.h | 37 + arch/arm/include/asm/setup.h | 14 +- arch/arm/include/asm/spinlock.h|4 + arch/arm/kernel/perf_event_v7.c|3 +- arch/arm/kernel/setup.c| 70 +- arch/arm/mach-axxia/Kconfig|3 - arch/arm/mach-axxia/Makefile |3 +- arch/arm/mach-axxia/axxia-gic.c| 25 +- arch/arm/mach-axxia/axxia.c| 123 +- arch/arm/mach-axxia/axxia.h|2 +- arch/arm/mach-axxia/clock.c| 185 +- arch/arm/mach-axxia/ddr_retention.c| 300 ++- arch/arm/mach-axxia/include/mach/debug-macro.S | 16 +- arch/arm/mach-axxia/include/mach/hardware.h| 25 +- arch/arm/mach-axxia/include/mach/irqs.h|1 + arch/arm/mach-axxia/include/mach/memory.h | 19 + arch/arm/mach-axxia/include/mach/ncr.h | 44 + arch/arm/mach-axxia/ncr.c | 597 + arch/arm/mach-axxia/pci.c |7 +- arch/arm/mach-axxia/platsmp.c | 155 +- arch/arm/mach-axxia/rapidio.c | 68 + arch/arm/mach-axxia/wrappers.c | 176 -- arch/arm/mm/mmu.c | 82 +- arch/powerpc/boot/dts/ACP344xV2.dts| 20 +- arch/powerpc/boot/dts/acp25xx.dts | 16 +- arch/powerpc/boot/dts/acp342x.dts | 21 +- arch/powerpc/boot/dts/acp344x.dts | 16 +- arch/powerpc/boot/dts/lsi_acp342x.dts | 317 +++ arch/powerpc/boot/dts/lsi_acp344x.dts | 355 +++ arch/powerpc/include/asm/axxia-rio.h | 107 + arch/powerpc/include/asm/rio.h | 46 + arch/powerpc/platforms/44x/Makefile|3 +- arch/powerpc/platforms/44x/acprio.c| 65 + arch/powerpc/platforms/44x/acpx1.c |1 + arch/powerpc/sysdev/Makefile |2 - arch/powerpc/sysdev/lsi_acp_wrappers.c | 132 - arch/powerpc/sysdev/lsi_pci.c
[linux-yocto] [PULL REQUEST] Kernel: 3.4 Branch: standard/axxia/base
The following changes since commit e1374b95f2b2474b37f250b61a12eb7d4c8002c8: Merge branch 'standard/base' into standard/axxia/base (2014-04-29 13:10:33 -0400) are available in the git repository at: g...@github.com:butlerpaul/lsikernel sab-next for you to fetch changes up to 6b4b2cce1391ea3480b0170be8aa912c5cc5426d: axxia: Remove Wrapper Functions (2014-05-02 09:07:28 -0700) Anders Berg (7): axxia: Fixed earlyprintk axxia: Define arch_is_coherent() ARM: 7465/1: Handle 4GB memory sizes in device tree and mem=size@start option ARM: LPAE: use phys_addr_t in alloc_init_pud() ARM: 7499/1: mm: Fix vmalloc overlap check for !HIGHMEM arm: mmu: Fixed checkpatch issues with mmu drivers/i2c-axxia: Support I2C_M_RECV_LEN David Mercado (2): LSI AXM55xx: Enable multi-cluster wfe/sev LSI AXM55XX: Add PMU support John Jacques (6): arch/arm/mach-axxi: Updated DDR Retention to Wokr from Interrupt Context arch/arm/mach-axxia: Clear MTC Errors During Initialization LSI: Fix Device Tree compatible fields powerpc/mpic: Disable preemption when calling mpic_processor_id() arm/mach-axxia: Same build for HW and simlation and DDR Retention Reset and clock init. axxia: Remove Wrapper Functions Michael Bringmann (1): LSI AXM55XX/rapidio: Stability and bug fix improvements , Correct boundary, Expand valid condition. Paul Butler (8): drivers/rapidio/devices: Initial Submittal of LSI rapidio drivers/rapidio: new files drivers/rapidio: modified files arm: rapidio updates powerpc: rapidio updates include: rapidio updates drivers: rapidio updates arm/mach-axxia: Updated PCIe driver to set PCIe SangeethaRao (3): arch/powerpc/sysdev: Fixed PCIe enumeration issue on AXM3500 emulation drivers/usb: USB driver/dts on PPC was broken. arch/arm/mach-axxia: added support for ncr_read/ncr_write ningligong (1): drivers/rapidio/lsi: squash a bunch rapidio stuff together and Cleanup arch/arm/Kconfig | 19 + arch/arm/Kconfig.debug |9 + arch/arm/Makefile |3 - arch/arm/boot/dts/axm55xx.dts | 50 +- arch/arm/boot/dts/axm55xxemu.dts | 21 +- arch/arm/boot/dts/axm55xxsim.dts | 94 +- .../arm/boot/dts/{axm-sim.dts = axm55xxsim16.dts} | 208 +- arch/arm/include/asm/axxia-rio.h | 135 + arch/arm/include/asm/rio.h | 37 + arch/arm/include/asm/setup.h | 14 +- arch/arm/include/asm/spinlock.h|4 + arch/arm/kernel/perf_event_v7.c|3 +- arch/arm/kernel/setup.c| 70 +- arch/arm/mach-axxia/Kconfig|3 - arch/arm/mach-axxia/Makefile |3 +- arch/arm/mach-axxia/axxia-gic.c| 25 +- arch/arm/mach-axxia/axxia.c| 123 +- arch/arm/mach-axxia/axxia.h|2 +- arch/arm/mach-axxia/clock.c| 185 +- arch/arm/mach-axxia/ddr_retention.c| 300 ++- arch/arm/mach-axxia/include/mach/debug-macro.S | 16 +- arch/arm/mach-axxia/include/mach/hardware.h| 25 +- arch/arm/mach-axxia/include/mach/irqs.h|1 + arch/arm/mach-axxia/include/mach/memory.h | 19 + arch/arm/mach-axxia/include/mach/ncr.h | 44 + arch/arm/mach-axxia/ncr.c | 597 + arch/arm/mach-axxia/pci.c |7 +- arch/arm/mach-axxia/platsmp.c | 155 +- arch/arm/mach-axxia/rapidio.c | 68 + arch/arm/mach-axxia/wrappers.c | 176 -- arch/arm/mm/mmu.c | 82 +- arch/powerpc/boot/dts/ACP344xV2.dts| 20 +- arch/powerpc/boot/dts/acp25xx.dts | 16 +- arch/powerpc/boot/dts/acp342x.dts | 21 +- arch/powerpc/boot/dts/acp344x.dts | 16 +- arch/powerpc/boot/dts/lsi_acp342x.dts | 317 +++ arch/powerpc/boot/dts/lsi_acp344x.dts | 355 +++ arch/powerpc/include/asm/axxia-rio.h | 107 + arch/powerpc/include/asm/rio.h | 46 + arch/powerpc/platforms/44x/Makefile|3 +- arch/powerpc/platforms/44x/acprio.c| 65 + arch/powerpc/platforms/44x/acpx1.c |1 + arch/powerpc/sysdev/Makefile |2 - arch/powerpc/sysdev/lsi_acp_wrappers.c | 132 - arch/powerpc/sysdev/lsi_pci.c | 19 +- arch/powerpc/sysdev/mpic.c | 119 +- drivers/i2c/busses/i2c-axxia.c | 193 +-
Re: [linux-yocto] [PATCH 1/1] mei.cfg: enable Intel chipsets
On 4/25/2014 8:51 AM, Hart, Darren wrote: On 4/24/14, 18:42, Kamble, Nitin A nitin.a.kam...@intel.com wrote: From: Nitin A Kamble nitin.a.kam...@intel.com Enable Intel Chipsets in the AMT/MEI driver. Signed-off-by: Nitin A Kamble nitin.a.kam...@intel.com Acked-by: Darren Hart dvh...@linux.intel.com Hi Bruce, Can you pull this fix in the v3.10 kernel repository as well? Thanks, Nitin --- meta/cfg/kernel-cache/features/amt/mei/mei.cfg | 1 + 1 file changed, 1 insertion(+) diff --git a/meta/cfg/kernel-cache/features/amt/mei/mei.cfg b/meta/cfg/kernel-cache/features/amt/mei/mei.cfg index c1c2ace..313084b 100644 --- a/meta/cfg/kernel-cache/features/amt/mei/mei.cfg +++ b/meta/cfg/kernel-cache/features/amt/mei/mei.cfg @@ -1,3 +1,4 @@ CONFIG_STAGING=y CONFIG_WATCHDOG_CORE=y CONFIG_INTEL_MEI=y +CONFIG_INTEL_MEI_ME=y -- 1.8.1.4 -- ___ linux-yocto mailing list linux-yocto@yoctoproject.org https://lists.yoctoproject.org/listinfo/linux-yocto