16 Nov, 2017

1 commit

  • Pull MIPS updates from James Hogan:
    "These are the main MIPS changes for 4.15.

    Fixes:
    - ralink: Fix MT7620 PCI build issues (4.5)
    - Disable cmpxchg64() and HAVE_VIRT_CPU_ACCOUNTING_GEN for 32-bit SMP
    (4.1)
    - Fix MIPS64 FP save/restore on 32-bit kernels (4.0)
    - ptrace: Pick up ptrace/seccomp changed syscall numbers (3.19)
    - ralink: Fix MT7628 pinmux (3.19)
    - BCM47XX: Fix LED inversion on WRT54GSv1 (3.17)
    - Fix n32 core dumping as o32 since regset support (3.13)
    - ralink: Drop obsolete USB_ARCH_HAS_HCD select

    Build system:
    - Default to "generic" (multiplatform) system type instead of IP22
    - Use generic little endian MIPS32 r2 configuration as default
    defconfig instead of ip22_defconfig

    FPU emulation:
    - Fix exception generation for certain R6 FPU instructions

    SMP:
    - Allow __cpu_number_map to be larger than NR_CPUS for sparse CPU id
    spaces

    Miscellaneous:
    - Add iomem resource for kernel bss section for kexec/kdump
    - Atomics: Nudge writes on bit unlock
    - DT files: Standardise "ok" -> "okay"

    Minor cleanups:
    - Define virt_to_pfn()
    - Make thread_saved_pc static
    - Simplify 32-bit sign extension in __read_64bit_c0_split()
    - DMA: Use vma_pages() helper
    - FPU emulation: Replace unsigned with unsigned int
    - MM: Removed unused lastpfn
    - Alchemy: Make clk_ops const
    - Lasat: Use setup_timer() helper
    - ralink: Use BIT() in MT7620 PCI driver

    Platform support:

    BMIPS:
    - Enable HARDIRQS_SW_RESEND

    Broadcom BCM63XX:
    - Add clkdev lookup support
    - Update clk driver, UART driver, DTs to handle named refclk from DTs
    - Split apart various clocks to more closely match hardware
    - Add ethernet clocks

    Cavium Octeon:
    - Remove usage of cvmx_wait() in favour of __delay()

    ImgTec Pistachio:
    - DT: Drop deprecated dwmmc num-slots property

    Ingenic JZ4780:
    - Add NFS root to Ci20 defconfig
    - Add watchdog to Ci20 DT & defconfig, and allow building of watchdog
    driver with this SoC

    Generic (multiplatform):
    - Migrate xilfpga (MIPSfpga) platform to the generic platform

    Lantiq xway:
    - Fix ASC0/ASC1 clocks"

    * tag 'mips_4.15' of git://git.kernel.org/pub/scm/linux/kernel/git/jhogan/mips: (46 commits)
    MIPS: Add iomem resource for kernel bss section.
    MIPS: cmpxchg64() and HAVE_VIRT_CPU_ACCOUNTING_GEN don't work for 32-bit SMP
    MIPS: BMIPS: Enable HARDIRQS_SW_RESEND
    MIPS: pci: Make use of the BIT() macro inside the mt7620 driver
    MIPS: pci: Remove KERN_WARN instance inside the mt7620 driver
    MIPS: pci: Remove duplicate define in mt7620 driver
    MIPS: ralink: Fix typo in mt7628 pinmux function
    MIPS: ralink: Fix MT7628 pinmux
    MIPS: Fix odd fp register warnings with MIPS64r2
    watchdog: jz4780: Allow selection of jz4740-wdt driver
    MIPS/ptrace: Update syscall nr on register changes
    MIPS/ptrace: Pick up ptrace/seccomp changed syscalls
    MIPS: Fix an n32 core file generation regset support regression
    MIPS: Fix MIPS64 FP save/restore on 32-bit kernels
    MIPS: page.h: Define virt_to_pfn()
    MIPS: Xilfpga: Switch to using generic defconfigs
    MIPS: generic: Add support for MIPSfpga
    MIPS: Set defconfig target to a generic system for 32r2el
    MIPS: Kconfig: Set default MIPS system type as generic
    MIPS: DTS: Remove num-slots from Pistachio SoC
    ...

    Linus Torvalds
     

08 Nov, 2017

5 commits

  • Make the secondary switch clocks their own clocks. This allows proper
    enable reference counting between SAR/XTM and the main switch clocks,
    and controlling them individually from drivers.

    Signed-off-by: Jonas Gorski
    Cc: Greg Kroah-Hartman
    Cc: Rob Herring
    Cc: Mark Rutland
    Cc: Florian Fainelli
    Cc: Kevin Cernekee
    Cc: Russell King
    Cc: linux-mips@linux-mips.org
    Cc: linux-arm-kernel@lists.infradead.org
    Cc: linux-serial@vger.kernel.org
    Cc: devicetree@vger.kernel.org
    Cc: bcm-kernel-feedback-list@broadcom.com
    Patchwork: https://patchwork.linux-mips.org/patch/17332/
    Signed-off-by: Ralf Baechle
    Signed-off-by: James Hogan

    Jonas Gorski
     
  • Add lookups to provide the appropriate enetX clocks as just "enet" to
    the ethernet devices.

    Reviewed-by: Florian Fainelli
    Signed-off-by: Jonas Gorski
    Cc: Greg Kroah-Hartman
    Cc: Rob Herring
    Cc: Mark Rutland
    Cc: Kevin Cernekee
    Cc: Russell King
    Cc: linux-mips@linux-mips.org
    Cc: linux-arm-kernel@lists.infradead.org
    Cc: linux-serial@vger.kernel.org
    Cc: devicetree@vger.kernel.org
    Cc: bcm-kernel-feedback-list@broadcom.com
    Patchwork: https://patchwork.linux-mips.org/patch/17331/
    Signed-off-by: Ralf Baechle
    Signed-off-by: James Hogan

    Jonas Gorski
     
  • Split up the HSSPL clock into rate and a gate clock, to more closely
    match the actual hardware.

    Reviewed-by: Florian Fainelli
    Signed-off-by: Jonas Gorski
    Cc: Greg Kroah-Hartman
    Cc: Rob Herring
    Cc: Mark Rutland
    Cc: Kevin Cernekee
    Cc: Russell King
    Cc: linux-mips@linux-mips.org
    Cc: linux-arm-kernel@lists.infradead.org
    Cc: linux-serial@vger.kernel.org
    Cc: devicetree@vger.kernel.org
    Cc: bcm-kernel-feedback-list@broadcom.com
    Patchwork: https://patchwork.linux-mips.org/patch/17330/
    Signed-off-by: Ralf Baechle
    Signed-off-by: James Hogan

    Jonas Gorski
     
  • Add a lookup as "refclk" to describe its function for the uarts.

    Reviewed-by: Florian Fainelli
    Signed-off-by: Jonas Gorski
    Cc: Greg Kroah-Hartman
    Cc: Rob Herring
    Cc: Mark Rutland
    Cc: Kevin Cernekee
    Cc: Russell King
    Cc: linux-mips@linux-mips.org
    Cc: linux-arm-kernel@lists.infradead.org
    Cc: linux-serial@vger.kernel.org
    Cc: devicetree@vger.kernel.org
    Cc: bcm-kernel-feedback-list@broadcom.com
    Patchwork: https://patchwork.linux-mips.org/patch/17326/
    Signed-off-by: Ralf Baechle
    Signed-off-by: James Hogan

    Jonas Gorski
     
  • Enable clkdev lookup support to allow us providing clocks under
    different names to devices more easily, so we don't need to care
    about clock name clashes anymore.

    Reviewed-by: Florian Fainelli
    Signed-off-by: Jonas Gorski
    Cc: Greg Kroah-Hartman
    Cc: Rob Herring
    Cc: Mark Rutland
    Cc: Kevin Cernekee
    Cc: Russell King
    Cc: linux-mips@linux-mips.org
    Cc: linux-arm-kernel@lists.infradead.org
    Cc: linux-serial@vger.kernel.org
    Cc: devicetree@vger.kernel.org
    Cc: bcm-kernel-feedback-list@broadcom.com
    Patchwork: https://patchwork.linux-mips.org/patch/17325/
    Signed-off-by: Ralf Baechle
    Signed-off-by: James Hogan

    Jonas Gorski
     

02 Nov, 2017

1 commit

  • Many source files in the tree are missing licensing information, which
    makes it harder for compliance tools to determine the correct license.

    By default all files without license information are under the default
    license of the kernel, which is GPL version 2.

    Update the files which contain no license information with the 'GPL-2.0'
    SPDX license identifier. The SPDX identifier is a legally binding
    shorthand, which can be used instead of the full boiler plate text.

    This patch is based on work done by Thomas Gleixner and Kate Stewart and
    Philippe Ombredanne.

    How this work was done:

    Patches were generated and checked against linux-4.14-rc6 for a subset of
    the use cases:
    - file had no licensing information it it.
    - file was a */uapi/* one with no licensing information in it,
    - file was a */uapi/* one with existing licensing information,

    Further patches will be generated in subsequent months to fix up cases
    where non-standard license headers were used, and references to license
    had to be inferred by heuristics based on keywords.

    The analysis to determine which SPDX License Identifier to be applied to
    a file was done in a spreadsheet of side by side results from of the
    output of two independent scanners (ScanCode & Windriver) producing SPDX
    tag:value files created by Philippe Ombredanne. Philippe prepared the
    base worksheet, and did an initial spot review of a few 1000 files.

    The 4.13 kernel was the starting point of the analysis with 60,537 files
    assessed. Kate Stewart did a file by file comparison of the scanner
    results in the spreadsheet to determine which SPDX license identifier(s)
    to be applied to the file. She confirmed any determination that was not
    immediately clear with lawyers working with the Linux Foundation.

    Criteria used to select files for SPDX license identifier tagging was:
    - Files considered eligible had to be source code files.
    - Make and config files were included as candidates if they contained >5
    lines of source
    - File already had some variant of a license header in it (even if
    Reviewed-by: Philippe Ombredanne
    Reviewed-by: Thomas Gleixner
    Signed-off-by: Greg Kroah-Hartman

    Greg Kroah-Hartman
     

06 Sep, 2017

1 commit

  • Make the behaviour of clk_get_rate consistent with common clk's
    clk_get_rate by accepting NULL clocks as parameter. Some device
    drivers rely on this, and will cause an OOPS otherwise.

    Fixes: e7300d04bd08 ("MIPS: BCM63xx: Add support for the Broadcom BCM63xx family of SOCs.")
    Reported-by: Mathias Kresin
    Signed-off-by: Jonas Gorski
    Reviewed-by: Florian Fainelli
    Cc: bcm-kernel-feedback-list@broadcom.com
    Cc: James Hogan
    Cc: linux-mips@linux-mips.org
    Cc: linux-kernel@vger.kernel.org
    Patchwork: https://patchwork.linux-mips.org/patch/16776/
    Signed-off-by: Ralf Baechle

    Jonas Gorski
     

14 Feb, 2017

1 commit

  • Historically a lot of these existed because we did not have
    a distinction between what was modular code and what was providing
    support to modules via EXPORT_SYMBOL and friends. That changed
    when we forked out support for the latter into the export.h file.

    This means we should be able to reduce the usage of module.h
    in code that is obj-y Makefile or bool Kconfig. In the case of
    some code where it is modular, we can extend that to also include
    files that are building basic support functionality but not related
    to loading or registering the final module; such files also have
    no need whatsoever for module.h

    The advantage in removing such instances is that module.h itself
    sources about 15 other headers; adding significantly to what we feed
    cpp, and it can obscure what headers we are effectively using.

    Since module.h might have been the implicit source for init.h
    (for __init) and for export.h (for EXPORT_SYMBOL) we consider each
    instance for the presence of either and replace/add as needed.

    Also note that MODULE_DEVICE_TABLE is a no-op for non-modular code.

    Build coverage of all the mips defconfigs revealed the module.h
    header was masking a couple of implicit include instances, so
    we add the appropriate headers there.

    Signed-off-by: Paul Gortmaker
    Cc: David Daney
    Cc: John Crispin
    Cc: Ralf Baechle
    Cc: "Steven J. Hill"
    Cc: linux-mips@linux-mips.org
    Patchwork: https://patchwork.linux-mips.org/patch/15131/
    [james.hogan@imgtec.com: Preserve sort order where it already exists]
    Signed-off-by: James Hogan

    Paul Gortmaker
     

04 Oct, 2016

1 commit

  • In many of clk_disable() implementations, it is a no-op for a NULL
    pointer input, but this is one of the exceptions.

    Making it treewide consistent will allow clock consumers to call
    clk_disable() without NULL pointer check.

    Signed-off-by: Masahiro Yamada
    Acked-by: Florian Fainelli
    Cc: Stephen Boyd
    Cc: Michael Turquette
    Cc: linux-mips@linux-mips.org
    Cc: linux-kernel@vger.kernel.org
    Cc: bcm-kernel-feedback-list@broadcom.com
    Cc: linux-arm-kernel@lists.infradead.org
    Patchwork: https://patchwork.linux-mips.org/patch/14264/
    Signed-off-by: Ralf Baechle

    Masahiro Yamada
     

09 Mar, 2016

1 commit


19 Feb, 2016

1 commit


28 Jan, 2016

1 commit

  • This reverts commit 5bdb102b3f9785cb88467bc7c75fa0f5cacc8dc5.

    Brian Norris is reporting:

    Ralf,

    Please revert this and send it to Linus (or else, I can send it myself).
    This is causing build failures, because I didn't take the rest of
    Simon's series yet.

    drivers/mtd/bcm63xxpart.c: In function 'bcm63xx_parse_cfe_partitions':
    drivers/mtd/bcm63xxpart.c:93:2: error: implicit declaration of function
    'bcm63xx_nvram_get_psi_size' [-Werror=implicit-function-declaration]

    Signed-off-by: Ralf Baechle
    References: https://www.linux-mips.org/cgi-bin/mesg.cgi?a=linux-mips&i=20160126191607.GA111152%40google.com

    Ralf Baechle
     

24 Jan, 2016

2 commits

  • Remove bcm63xx_nvram_get_psi_size() as it now has no users.

    Signed-off-by: Simon Arlott
    Cc: David Woodhouse
    Cc: Brian Norris
    Cc: Kevin Cernekee
    Cc: Florian Fainelli
    Cc: Jonas Gorski
    Cc: Linux Kernel Mailing List
    Cc: MIPS Mailing List
    Cc: MTD Maling List
    Patchwork: https://patchwork.linux-mips.org/patch/11836/
    Signed-off-by: Ralf Baechle

    Simon Arlott
     
  • Use the common definition of the nvram structure from the header file
    include/linux/bcm963xx_nvram.h instead of maintaining a separate copy.

    Read the version 5 size of nvram data from memory and then call the
    new checksum verification function from the header file.

    Signed-off-by: Simon Arlott
    Cc: David Woodhouse
    Cc: Brian Norris
    Cc: Kevin Cernekee
    Cc: Florian Fainelli
    Cc: Jonas Gorski
    Cc: Linux Kernel Mailing List
    Cc: MIPS Mailing List
    Cc: MTD Maling List
    Patchwork: https://patchwork.linux-mips.org/patch/11831/
    Signed-off-by: Ralf Baechle

    Simon Arlott
     

16 Nov, 2015

1 commit

  • Pull MIPS updates from Ralf Baechle:
    "These are the highlists of the main MIPS pull request for 4.4:

    - Add latencytop support
    - Support appended DTBs
    - VDSO support and initially use it for gettimeofday.
    - Drop the .MIPS.abiflags and ELF NOTE sections from vmlinux
    - Support for the 5KE, an internal test core.
    - Switch all MIPS platfroms to libata drivers.
    - Improved support, cleanups for ralink and Lantiq platforms.
    - Support for the new xilfpga platform.
    - A number of DTB improvments for BMIPS.
    - Improved support for CM and CPS.
    - Minor JZ4740 and BCM47xx enhancements"

    * 'upstream' of git://git.linux-mips.org/pub/scm/ralf/upstream-linus: (120 commits)
    MIPS: idle: add case for CPU_5KE
    MIPS: Octeon: Support APPENDED_DTB
    MIPS: vmlinux: create a section for appended DTB
    MIPS: Clean up compat_siginfo_t
    MIPS: Fix PAGE_MASK definition
    MIPS: BMIPS: Enable GZIP ramdisk and timed printks
    MIPS: Add xilfpga defconfig
    MIPS: xilfpga: Add mipsfpga platform code
    MIPS: xilfpga: Add xilfpga device tree files.
    dt-bindings: MIPS: Document xilfpga bindings and boot style
    MIPS: Make MIPS_CMDLINE_DTB default
    MIPS: Make the kernel arguments from dtb available
    MIPS: Use USE_OF as the guard for appended dtb
    MIPS: BCM63XX: Use pr_* instead of printk
    MIPS: Loongson: Cleanup CONFIG_LOONGSON_SUSPEND.
    MIPS: lantiq: Disable xbar fpi burst mode
    MIPS: lantiq: Force the crossbar to big endian
    MIPS: lantiq: Initialize the USB core on boot
    MIPS: lantiq: Return correct value for fpi clock on ar9
    MIPS: ralink: Add missing clock on rt305x
    ...

    Linus Torvalds
     

11 Nov, 2015

1 commit

  • Signed-off-by: Gregory Fong
    Cc: Florian Fainelli
    Cc: Jonas Gorski
    Cc: Joe Perches
    Cc: Rusty Russell
    Cc: Nicolas Schichan
    Cc: linux-mips@linux-mips.org
    Cc: linux-kernel@vger.kernel.org
    Patchwork: https://patchwork.linux-mips.org/patch/11300/
    Signed-off-by: Ralf Baechle

    Gregory Fong
     

23 Oct, 2015

1 commit

  • Move all register definitions and structs into the driver. This allows
    us dropping the platform_data struct and drop any arch specific
    includes. Make use of different device names to identify the version of
    the block we have.

    Since we now have full control over the message width, we can drop the
    size check, which was broken anyway, since it never set ret to any error
    code.

    Also since we now have no arch depedendent resources, we can now allow
    compiling it for any arch, hidden behind COMPILE_TEST.

    Signed-off-by: Jonas Gorski
    Signed-off-by: Mark Brown

    Jonas Gorski
     

13 Oct, 2015

1 commit


26 Aug, 2015

2 commits

  • Use irq_set_handler_locked() as it avoids a redundant lookup of the
    irq descriptor.

    Search and replacement was done with coccinelle.

    Signed-off-by: Thomas Gleixner
    Cc: Jiang Liu
    Cc: Julia Lawall
    Cc: Ralf Baechle
    Cc: linux-mips@linux-mips.org
    Cc: LKML
    Patchwork: https://patchwork.linux-mips.org/patch/10701/
    Signed-off-by: Ralf Baechle

    Thomas Gleixner
     
  • This is a preparatory patch for moving irq_data struct members.

    Signed-off-by: Jiang Liu
    Signed-off-by: Thomas Gleixner
    Cc: linux-mips@linux-mips.org
    Cc: LKML
    Patchwork: https://patchwork.linux-mips.org/patch/10699/
    Signed-off-by: Ralf Baechle

    Jiang Liu
     

21 Apr, 2015

1 commit

  • Pull final removal of deprecated cpus_* cpumask functions from Rusty Russell:
    "This is the final removal (after several years!) of the obsolete
    cpus_* functions, prompted by their mis-use in staging.

    With these function removed, all cpu functions should only iterate to
    nr_cpu_ids, so we finally only allocate that many bits when cpumasks
    are allocated offstack"

    * tag 'cpumask-next-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/rusty/linux: (25 commits)
    cpumask: remove __first_cpu / __next_cpu
    cpumask: resurrect CPU_MASK_CPU0
    linux/cpumask.h: add typechecking to cpumask_test_cpu
    cpumask: only allocate nr_cpumask_bits.
    Fix weird uses of num_online_cpus().
    cpumask: remove deprecated functions.
    mips: fix obsolete cpumask_of_cpu usage.
    x86: fix more deprecated cpu function usage.
    ia64: remove deprecated cpus_ usage.
    powerpc: fix deprecated CPU_MASK_CPU0 usage.
    CPU_MASK_ALL/CPU_MASK_NONE: remove from deprecated region.
    staging/lustre/o2iblnd: Don't use cpus_weight
    staging/lustre/libcfs: replace deprecated cpus_ calls with cpumask_
    staging/lustre/ptlrpc: Do not use deprecated cpus_* functions
    blackfin: fix up obsolete cpu function usage.
    parisc: fix up obsolete cpu function usage.
    tile: fix up obsolete cpu function usage.
    arm64: fix up obsolete cpu function usage.
    mips: fix up obsolete cpu function usage.
    x86: fix up obsolete cpu function usage.
    ...

    Linus Torvalds
     

25 Mar, 2015

1 commit

  • When called from prom init code, bcm63xx_gpio_init() will fail as it
    will call gpiochip_add() which relies on a working kmalloc() to alloc
    the gpio_desc array and kmalloc is not useable yet at prom init time.

    Move bcm63xx_gpio_init() to bcm63xx_register_devices() (an
    arch_initcall) where kmalloc works.

    Fixes: 14e85c0e69d5 ("gpio: remove gpio_descs global array")

    Signed-off-by: Nicolas Schichan
    Cc: linux-mips@linux-mips.org
    Cc: linux-kernel@vger.kernel.org
    Cc: Alexandre Courbot
    Patchwork: https://patchwork.linux-mips.org/patch/9530/
    Signed-off-by: Ralf Baechle

    Nicolas Schichan
     

05 Mar, 2015

1 commit


24 Nov, 2014

1 commit

  • Based on the spatch

    @@
    expression e;
    @@
    - return (e);
    + return e;

    with heavy hand editing because some of the changes are either whitespace
    or identation only or result in excessivly long lines.

    Signed-off-by: Ralf Baechle

    Ralf Baechle
     

26 Aug, 2014

1 commit

  • Delete successive assignments to the same location. In each case, the
    duplicated assignment is modified to be in line with other nearby code.

    A simplified version of the semantic match that finds this problem is as
    follows: (http://coccinelle.lip6.fr/)

    //
    @@
    expression i;
    @@

    *i = ...;
    i = ...;
    //

    Signed-off-by: Julia Lawall
    Cc: joe@perches.com
    Cc: kernel-janitors@vger.kernel.org
    Cc: linux-mips@linux-mips.org
    Cc: linux-kernel@vger.kernel.org
    Patchwork: https://patchwork.linux-mips.org/patch/7565/
    Signed-off-by: Ralf Baechle

    Julia Lawall
     

30 Jul, 2014

14 commits

  • Wire up the set_affinity call for the internal PIC if booting on
    a cpu supporting it.
    Affinity is kept to boot cpu as default.

    Signed-off-by: Jonas Gorski
    Cc: linux-mips@linux-mips.org
    Cc: John Crispin
    Cc: Maxime Bizon
    Cc: Florian Fainelli
    Cc: Kevin Cernekee
    Cc: Gregory Fong
    Patchwork: https://patchwork.linux-mips.org/patch/7323/
    Signed-off-by: Ralf Baechle

    Jonas Gorski
     
  • In preparation for applying affinity, use the irq descriptor as the
    argument for (un)mask.

    Signed-off-by: Jonas Gorski
    Cc: linux-mips@linux-mips.org
    Cc: John Crispin
    Cc: Maxime Bizon
    Cc: Florian Fainelli
    Cc: Kevin Cernekee
    Cc: Gregory Fong
    Patchwork: https://patchwork.linux-mips.org/patch/7317/
    Signed-off-by: Ralf Baechle

    Jonas Gorski
     
  • Signed-off-by: Jonas Gorski
    Cc: linux-mips@linux-mips.org
    Cc: John Crispin
    Cc: Maxime Bizon
    Cc: Florian Fainelli
    Cc: Kevin Cernekee
    Cc: Gregory Fong
    Patchwork: https://patchwork.linux-mips.org/patch/7322/
    Signed-off-by: Ralf Baechle

    Jonas Gorski
     
  • Since we will have the chance of accessing the registers concurrently,
    protect any accesses through a spinlock.

    Signed-off-by: Jonas Gorski
    Cc: linux-mips@linux-mips.org
    Cc: John Crispin
    Cc: Maxime Bizon
    Cc: Florian Fainelli
    Cc: Kevin Cernekee
    Cc: Gregory Fong
    Patchwork: https://patchwork.linux-mips.org/patch/7321/
    Signed-off-by: Ralf Baechle

    Jonas Gorski
     
  • Signed-off-by: Jonas Gorski
    Cc: linux-mips@linux-mips.org
    Cc: John Crispin
    Cc: Maxime Bizon
    Cc: Florian Fainelli
    Cc: Kevin Cernekee
    Cc: Gregory Fong
    Patchwork: https://patchwork.linux-mips.org/patch/7320/
    Signed-off-by: Ralf Baechle

    Jonas Gorski
     
  • Set it to zero if there is no second set.

    Signed-off-by: Jonas Gorski
    Cc: linux-mips@linux-mips.org
    Cc: John Crispin
    Cc: Maxime Bizon
    Cc: Florian Fainelli
    Cc: Kevin Cernekee
    Cc: Gregory Fong
    Patchwork: https://patchwork.linux-mips.org/patch/7319/
    Signed-off-by: Ralf Baechle

    Jonas Gorski
     
  • The SMP capable irq controllers have two interrupt output pins which are
    controlled through separate registers, so make the variables arrays.

    Signed-off-by: Jonas Gorski
    Cc: linux-mips@linux-mips.org
    Cc: John Crispin
    Cc: Maxime Bizon
    Cc: Florian Fainelli
    Cc: Kevin Cernekee
    Cc: Gregory Fong
    Patchwork: https://patchwork.linux-mips.org/patch/7318/
    Signed-off-by: Ralf Baechle

    Jonas Gorski
     
  • The generic version uses a variable length of u32 registers instead of u32/u64.
    This allows easier support for "wider" registers without having to rewrite
    everything.

    This "generic" version is as fast as the old version in the best case
    (i == next set bit), and twice as fast in the worst case in 64 bits.

    Using a macro was chosen over a (forced) inline version because gcc generated
    more compact code with the macro.

    The change from (signed) int to unsigned int for i and to_call was intentional
    as the value can be only between 0 and (width - 1) anyway, and allowed gcc to
    optimise the code a bit further.

    Signed-off-by: Jonas Gorski
    Cc: linux-mips@linux-mips.org
    Cc: John Crispin
    Cc: Maxime Bizon
    Cc: Florian Fainelli
    Cc: Kevin Cernekee
    Cc: Gregory Fong
    Patchwork: https://patchwork.linux-mips.org/patch/7316/
    Signed-off-by: Ralf Baechle

    Jonas Gorski
     
  • Allows up to drop the prototypes from the top.

    Signed-off-by: Jonas Gorski
    Cc: linux-mips@linux-mips.org
    Cc: John Crispin
    Cc: Maxime Bizon
    Cc: Florian Fainelli
    Cc: Kevin Cernekee
    Cc: Gregory Fong
    Patchwork: https://patchwork.linux-mips.org/patch/7315/
    Signed-off-by: Ralf Baechle

    Jonas Gorski
     
  • Make it follow the same naming convention as the other functions.

    Signed-off-by: Jonas Gorski
    Cc: linux-mips@linux-mips.org
    Cc: John Crispin
    Cc: Maxime Bizon
    Cc: Florian Fainelli
    Cc: Kevin Cernekee
    Cc: Gregory Fong
    Patchwork: https://patchwork.linux-mips.org/patch/7314/
    Signed-off-by: Ralf Baechle

    Jonas Gorski
     
  • Use the same pattern as with get_*_cpu_type() to allow the compiler
    to remove code for non enabled SoC types.

    Signed-off-by: Jonas Gorski
    Cc: linux-mips@linux-mips.org
    Cc: John Crispin
    Cc: Maxime Bizon
    Cc: Florian Fainelli
    Cc: Kevin Cernekee
    Patchwork: https://patchwork.linux-mips.org/patch/7273/
    Signed-off-by: Ralf Baechle

    Jonas Gorski
     
  • Cc: linux-mips@linux-mips.org
    Cc: John Crispin
    Cc: Maxime Bizon
    Cc: Florian Fainelli
    Cc: Kevin Cernekee
    Patchwork: https://patchwork.linux-mips.org/patch/7270/
    Signed-off-by: Ralf Baechle

    Jonas Gorski
     
  • Signed-off-by: Jonas Gorski
    Cc: linux-mips@linux-mips.org
    Cc: John Crispin
    Cc: Maxime Bizon
    Cc: Florian Fainelli
    Cc: Kevin Cernekee
    Patchwork: https://patchwork.linux-mips.org/patch/7271/
    Signed-off-by: Ralf Baechle

    Jonas Gorski
     
  • Signed-off-by: Jonas Gorski
    Cc: linux-mips@linux-mips.org
    Cc: John Crispin
    Cc: Maxime Bizon
    Cc: Florian Fainelli
    Cc: Kevin Cernekee
    Patchwork: https://patchwork.linux-mips.org/patch/7269/
    Signed-off-by: Ralf Baechle

    Jonas Gorski